GPT WORLD / INDEPENDENT CODEX FIELD MANUAL 來源檢視 · 2026-07-31

實作指南 / 10 分鐘

診斷 Codex、檢視 features 並產生 completions

修改設定或 shell startup 前,先讀取可觀察 inventory。

軌道
Codex CLI 核心
程度
營運
成熟度
Runtime-confirmed in Codex 0.147.0

Codex 的 doctor 檢查 installation/runtime layers,features 顯示 feature stage/effective state,completion 產生 shell integration,debug utilities 則提供特定 evidence,例如 bundled model catalog。應先 read-only inspection,保留 version context,並在放進 ticket 或 startup file 前 review output。

CLI

已驗證 Terminal Sequence

TERMINAL / 刻意複製
  1. $codex doctor --summary
  2. $codex features list
  3. $codex completion zsh > /tmp/_codex
  4. $codex debug models --bundled
A

工作原則

01

先記錄 release

Feature stages、output fields、supported shells 會變;每份 diagnostic 都要配 codex --version。

02

先 inspect 再 mutate

Enable/disable 前列 effective feature state,source 前檢查 completion output。

03

小心分享 diagnostics

Report 可能含 paths、repo names 與 config clues;外傳前 review/redact。

B

實地程序

  1. 01

    確認 identity

    解析 active executable/version,避免報告和另一個 installation 混淆。

  2. 02

    執行分層診斷

    先 doctor summary,再處理第一個 failing installation/auth/config/Git/runtime/terminal/thread layer。

  3. 03

    檢視 feature state

    features list,變更前記錄 stage/effective value。

  4. 04

    產生 shell completion

    選 bash/elvish/fish/powershell/zsh,先寫 temporary file、檢查,再依 shell 整合。

  5. 05

    窄用 debug

    只跑需要 evidence 的 debug subcommand,不預設公開 broad dump。

PASS / FAIL

驗收清單

  • Version/executable 有記錄。
  • 先處理第一個 failing layer。
  • Feature change 指向一個 exact feature。
  • Completion 符合 active shell。
  • Shared reports 已檢查敏感 paths。

WATCH / REJECT

失敗模式

  • 未讀 doctor 就改多層 config。
  • 猜測並啟用 experimental feature。
  • 未檢查就 append generated shell code。