Fix docstring Args entries that name a parameter the function does not take - #8223
Open
darkdi wants to merge 1 commit into
Open
Fix docstring Args entries that name a parameter the function does not take#8223darkdi wants to merge 1 commit into
darkdi wants to merge 1 commit into
Conversation
…t take Signed-off-by: darkdi <rantovov5@gmail.com>
darkdi
requested review from
hwchen2017,
loadams,
tjruwase and
tohtana
as code owners
August 6, 2026 05:16
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: b77c08eeda
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
|
|
||
| Args: | ||
| finished_experiments (dcit): a dictionary of experiment id and experiment description. | ||
| metric (str): the key to read from each experiment's metrics file when |
There was a problem hiding this comment.
Add the required sign-off trailer
This is a non-merge commit, but its message contains no Signed-off-by trailer, so it does not satisfy the repository's commit policy. Recreate the commit with --signoff using the configured Git identity.
AGENTS.md reference: AGENTS.md:L8-L8
Useful? React with 👍 / 👎.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Forty-one
Args:entries name a parameter the function does not take. Docstrings only — no signature, no behaviour, no test touched.Twenty are renames where the docstring kept the old name. The ones that stand out:
RaggedUnembed.forwardraged_metadataragged_metadata(typo)FlopsProfilerobjectmodelattn_out_in_featuresin_featuresout_featuresRaggedTopKGating.__call__expert_assignment,expert_offsetassignments,offsetsMoEScatter.__call__hidden_statesactivationsRaggedEmbeddingKernel.__init__fp_dtypeembed_dtypeInferenceEngineV2.queryn_tokensmax_request_tokensInferenceEngineV2.serializepathsave_pathBlockedKVCache.__init__config,enable_offloadconfigs,offloadMOELayerexpertexpertsDeepSpeedCPULion.__init__full_precision_optimizer_statesfp32_optimizer_statesBertSparseSelfAttention.forwardattn_maskattention_maskget_grad_norm_direct(stage 3 and stages 1/2)parametersparamsapply_to_tensors_onlyfunctionalfunction_create_model_parallelmodel_parallel_sizemodel_parallel_size_prune_configconfigsconfigWhere the position in the
Args:block lined up with the position in the signature, that is what I used to decide the mapping — for example inRaggedTopKGating.__call__the third and fourth documented names sit against the third and fourth parameters.Two needed a description rather than a rename, because the old text described something that is gone:
PipelineEngine.load_module_state_dictdocumentedstate_dict (str, None): unused. The argument ischeckpoint, and it is used on the very next line.ResourceManager.parse_resultsdocumentedfinished_experiments, which isself.finished_experiments. The argument ismetric, the key read out of each experiment's metrics file.The remaining entries document something that is not an argument at all:
layer_idonDeepSpeedTransformerInference,DeepSpeedDiffusersAttentionandDeepSpeedMoEInference(it is a class attribute);betaonCUDARMSPreNorm.__call__;q_ratioonBlockedRotaryEmbeddings.__init__;slackandblocksonBlockedKVCache.__init__;block_sizeonDSStateManager.__init__;key_padding_mask_modeandattn_mask_modeonSparseSelfAttention.forward(both are constructor arguments);seq_lenonDenseSparsityConfig.__init__, whose description was a copy of the one above it;num_global_blocksonBSLongformerSparsityConfig.__init__;scale_factoronDynamicLossScaler;scaleon the one-bitAdam.stepandZeroOneAdam.step;max_normon bothget_grad_norm_direct; andparamandparam_idon_process_selected_fp32_groups_grad.One was a formatting slip rather than a wrong name:
quantize_transformer_layerhad aNote:line indented inside itsArgs:block, so Doxygen-style readers and tooling see a parameter calledNote. Moved out.Every entry was opened and read against its signature.
yapfproduces no diff andflake8is clean on all thirty-one files, using the pinnedyapf==0.40.0andflake8==5.0.4from.pre-commit-config.yaml.