Skip to content

#519 [docs] スラッシュコマンド・provider・排他関係・環境変数の文書を実装に合わせる - #651

Merged
Kewton merged 1 commit into
developfrom
feature/issue-519-docs-provider
Oct 10, 2026
Merged

Kewton merged 1 commit into
developfrom
feature/issue-519-docs-provider

Conversation

@Kewton

@Kewton Kewton commented Oct 10, 2026

Copy link
Copy Markdown
Owner

概要

スラッシュコマンド・provider・排他関係・環境変数について、日英の文書の記述を実装に合わせます。実装を変えるのは、Clap が不正な provider の値を拒否するときの候補表示(src/provider_cli.rs)だけです。

変更

  • provider の候補と REPL(FIN-032)
    • src/provider_cli.rs:拒否のエラーに出る候補の一覧に openai-compatible を足します(augment_possible_values)。受理する値、ErrorKind(InvalidValue)、exit 2、出力先は変えていません。
    • 日英の文書に「/provider で選べるのは組み込みの 4 つだけ」と書きました。
  • 排他と依存(FIN-033)
    • 日英の呼び出し方に --workflow を足しました。
    • 拒否の経路を次の 3 つに分けて書きました:
      • Clap の拒否(例:--doctor --runs)
      • 解析の後の Config の拒否(例:--prompt x --ux-demo)
      • doctor の例外(--ux-demo --doctor --json が exit 1 と JSON の report を返す)
    • あわせて次も書きました:--json の 3 つの対象、workflow と origin の両方向の依存、汎用 provider の base URL。
  • Gate 専用のコマンド(FIN-034)
    • 日英のスラッシュコマンドのガイドに「Gate 3/4 専用」の節を設けました(/directive <instruction>・/confirm-directive <hash>)。一般の表とは分けています。
    • 目次の「全 24 名」に、一般のレジストリの数であることと、Gate 専用の 2 つが別にあることを書き足しました。
    • help の表示・レジストリ・dispatch・Gate の判定は変えていません。
  • alias と環境変数(FIN-035)
    • gpt-5.6 を拒否する範囲を executor・planner・classifier の 3 つの役割と書きました。汎用の互換サーバーには当てはまりません。
    • 日英の configuration に、次の 6 変数 を足しました:
      • COMMANDAGENT_STEP_WALL_CLOCK_CAP_MS
      • pack の内部の 4 変数
      • COMMANDAGENT_UX_DEMO_FAST
    • Issue の本文の「7 変数」は誤記と判断し、列挙されている 6 変数を正としました。
  • 対象ファイル:変えたのは「## 対象ファイル」の 13 本だけです。
    • docs/guide/README.md
    • docs/guide/{en,ja}/ の cli-reference.md・configuration.md・providers.md・slash-commands.md・troubleshooting.md
    • src/provider_cli.rs
    • tests/issue519_docs_runtime_alignment.rs(新規)

検証

  • commandmate verify の 15 ゲート(fmt・clippy -D warnings・cargo test の全体を含む)は、develop c98bdc7c の上の HEAD 1e73f721 で 15/15 pass でした。既存の tests/doc_drift.rs も pass しています。
  • 新しい結合テスト(10 本):
    • 子プロセスは env_clear で、一時の HOME・XDG_STATE_HOME と一時の workspace だけで動かします。
    • 実 provider には接続しません。
  • 二点測定:develop c98bdc7c のコードと文書に、新しいテストのファイルだけを置いて実行しました。10 本中 3 本が FAIL しました。
    • 候補に openai-compatible がない
    • 呼び出し方に --workflow がない
    • Gate 3/4 の節など、文書の目印がない
    • develop でも pass する 7 本は、今の挙動を固定するテストです。HEAD では 10 本とも pass します。
  • 成長上限の対象(runner.rs・loop_run.rs・baseline)は変えていません。

確かめてほしい点

文書のテストは目印の部分一致で確かめるので、文の意味が正しいことまでは保証しません。次の 2 つの節は、日英の本文を読んで確かめてください:cli-reference の排他・依存、slash-commands の Gate 3/4。

レビュー

文書とテストの変更なので、merge 前レビューは行いません(利用者承認済み)。

Refs #519

🤖 Generated with Claude Code

Resolve the four documented drifts (FIN-032..FIN-035) against the shipped
runtime and add a dedicated regression test.

- src/provider_cli.rs: report `openai-compatible` in the invalid `--provider`
  and `--planner-provider` candidate lists. Accepted values, the sentinel
  mapping, ErrorKind, and exit code 2 are unchanged.
- slash-commands (en/ja): document that REPL `/provider` accepts only the four
  built-in providers, and add the Gate 3/4-only `/directive` and
  `/confirm-directive` section that stays outside the general registry.
- cli-reference (en/ja): add `--workflow` to the action list, separate
  Clap-level conflicts from resolved-configuration rejections, fix the `--json`
  targets, and record the doctor Configuration-failure exit `1` exception.
- providers and troubleshooting (en/ja): scope the `gpt-5.6` alias rejection to
  the executor, planner, and classifier OpenAI roles and keep it off the generic
  `openai-compatible` transport.
- configuration (en/ja): document the step wall-clock cap, the internal pack
  handoff variables, and the UX demo fast variable, including the pack
  variables' missing ANVIL_* fallback.
- tests/issue519_docs_runtime_alignment.rs: new integration test pinning the
  four drifts without calling a real provider.

判断: 環境変数の不足分は本文が列挙した 6 名(step cap、pack 4 変数、UX demo
  fast)と旧名 2 つ(ANVIL_STEP_WALL_CLOCK_CAP_MS、ANVIL_UX_DEMO_FAST)を
  記載した。本文末尾の「7 変数」は列挙の内訳(2+4=6)と一致しないため、列挙を正とした。
判断: help とリファレンスの自動チェックが扱う範囲(公開フラグ集合・説明・件数、
  コマンドレジストリ、リンク/アンカー、en/ja 構造)は既存 tests/doc_drift.rs が
  引き続き担い、専用の parser・Gate・環境変数文書の検査は新規
  tests/issue519_docs_runtime_alignment.rs が担う。汎用的な CI 拡張は追加していない。

Co-authored-by: CommandCodeBot <noreply@commandcode.ai>
@Kewton
Kewton merged commit dd2aa12 into develop Oct 10, 2026
5 checks passed
@Kewton
Kewton deleted the feature/issue-519-docs-provider branch October 10, 2026 16:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant