docs(cli): populate --help text for every command and flag across all CLI modules - #55
Merged
Conversation
β¦ html-tag lint Wrap the forgetting curves store path in an inline code span in infer.rs and selflearn.rs so rustdoc's invalid_html_tags lint stops treating <state-dir> as an unclosed HTML tag; cargo doc -D warnings now passes.
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.
Summary
Before this PR, running
aarambh-studio --helplisted 7 of 10 subcommandswith blank descriptions (
train,infer,eval,quantise,convert,distill,finetune,selflearn), and most flags across the CLI showed nodescription at all in their
--helpoutput. The only commands with help textwere
agent(added in Phase 47) andserve, and the Phase 46finetune rlaifsubcommand.
This PR adds human-readable
help = "..."text and///doc comments (whichclap renders as
about) to every command struct and every flag acrossall 9 CLI command modules, so
<command> --helpis now self-explanatory β a newuser can run any
--helpand understand what the command does and what eachflag means, without reading separate docs.
No behavior, flag names, types, defaults, or logic changed. This is a
documentation/UX-only change to the clap definitions.
What changed
All edits are under
aarambh-studio/aarambh-studio/src/cmd/. Each file got a///doc comment on its command struct (rendered as the commandabout) and ahelp = "..."string on every#[arg(...)]:cmd/train.rsTrainArgsabout +--confighelpcmd/infer.rsInferArgsabout + help on all ~40 flags (config, model, tokenizer, image/video/document/audio, pages, dpi, frames, frame-sampling, prompt, sampling, thinking, speculative, tools, safety, self-learn, forgetting, best-of-N, selection, ground-truth, β¦)cmd/eval.rsEvalArgsabout + help on all ~20 flags (tasks, limit, kv-cache-report, forgetting-*, β¦)cmd/quantise.rsQuantiseArgsabout + help on all 8 flags (format, output, calibration-samples, group-size, β¦)cmd/convert.rsConvertArgsabout + help on all 10 flags (from/to layouts, tokenizer, β¦)cmd/serve.rsaboutwas already presentcmd/distill.rsDistillArgsabout + help on every flag ofTrainArgs/PrepareOfflineArgs/TrainOfflineArgs/EvaluateArgscmd/finetune.rsFinetuneArgsabout + doc comments on all 18FinetuneCommandvariants + help on every flag ofFinetuneRunArgs/MergeArgs/GrpoArgs/DpoArgs/VlmFinetuneArgs(Phase 46rlaifhelp left as-is)cmd/selflearn.rsSelflearnArgsabout + doc comments on all 6SelflearnCommandvariants + help on every flag ofStartArgs/SelflearnRunArgs/StatsArgs/ResetArgs/ForgettingReportArgs/ForgettingArgscmd/agent.rswas already complete (Phase 47) β verified and left untouched.main.rswas not modified: clap already inherits each subcommand'saboutfrom the wrapped Args struct's doc comment (the existing pattern), so
populating the Args struct doc comments in
cmd/*.rsis sufficient to surfaceevery subcommand in the top-level
--helplist.The verbatim
--helpreference snapshot atdocs/cli-commands-raw-help.txtwasregenerated from the rebuilt binary (1130 β 1946 lines, reflecting the newly
populated descriptions).
Style followed (matches the existing
agentcommand)help=(clap appends[default: ...]automatically β not duplicated).Thinking budget: none, low, medium, high, or max.(repeatable).best-of-nβ "(Phase 45)").TODO/FIXME/HACK/todo!()/unimplemented!()markers added (release-audit clean).Proof it renders
Top-level
--help(every subcommand now described; previously 7 were blank):train --help(was blank):infer --helpnow describes every one of its ~40 flags, e.g.:Verification
cargo fmt --all --checkβ cleancargo check -p aarambh-studio --all-targets --lockedβ passescargo clippy -p aarambh-studio --all-targets --locked -- -D warnings -D clippy::undocumented_unsafe_blocksβ zero warnings--helpfor every command and subcommand; previously-blank descriptions are now populated.Scope/non-goals
--execute-tools,--allow-tool,--exec-*) already had help text and are unchanged here.finetune rlaifhelp text was already complete and is unchanged.Related
feat: Phase 47 β sandboxed tool execution) which established the help-text style incmd/agent.rs.docs/cli-commands-raw-help.txt(regenerated for4.0.0-alpha.7).