Docs
Adding a leg
A leg is one named model behind one runtime. Legs are data, not code. Bare prompts still route via captain.
Built-in legs
Compiled defaults, in rough cold-start quality order. Overlay entries and environment pins can change provider or model without a rebuild.
| Leg | Runtime | Typical source | Notes |
|---|---|---|---|
/claude | claude -p | Claude Max subscription | Strongest default; /frontier is Claude at max effort |
/codex-cli | codex exec | ChatGPT / Codex CLI login | Frontier-class native Codex path |
/cursor | cursor-agent -p | Cursor subscription | Composer via Cursor’s headless agent |
/grok | OpenCode → xAI | SuperGrok subscription | Default director; burn-first coding worker |
/grok-max | OpenCode → xAI | SuperGrok subscription | Frontier-class Grok 4.6 |
/codex | OpenCode → OpenAI | ChatGPT subscription OAuth | Fast Codex spark path inside OpenCode |
/glm | OpenCode → OpenRouter | OpenRouter API key | Best open-weights default in the roster |
/deepseek | OpenCode → OpenRouter | OpenRouter API key | Long-context cheap coder |
/gemini | OpenCode → OpenRouter | OpenRouter API key | Vision + long context |
/qwen | OpenCode → OpenRouter | OpenRouter API key | Routine edits and refactors |
/kimi | OpenCode → NIM | NVIDIA API key | Strong NIM-hosted flagship |
/minimax | OpenCode → OpenRouter | OpenRouter API key | Overflow lane when subs cool down |
/gpt-oss | OpenCode → OpenRouter | OpenRouter API key | Open weights, Cerebras-served; the /deterministic pick |
/free | OpenCode → Zen | OpenCode free roster | Zero-cost rotating models |
List what is active on your machine with captain legs. Doctor reports ready, blocked, or skipped. The full roster, with models, prices, windows and roles, is on the models page.
Not every registered leg takes a task. jev is a decision leg on the system-one transport: it answers typed questions with calibrated probabilities and never generates text, so it is never a worker rung, a model in the picker, a forcing command or a workflow stage. See decision leg configuration.
Local CLI agent
Authenticate the vendor CLI first, then confirm with captain doctor:
- Claude Code →
claude -p - Codex CLI →
codex exec - Cursor →
cursor-agent -p
OpenRouter model
Remote models ride a local opencode serve session. Authenticate with opencode auth login or an API key, then register the model. The first slash splits the provider; the rest is the model id (OpenRouter ids often contain another slash).
captain legs add muse openrouter/meta/muse-spark-1.3 --prior 7.9 \
--note "strong prose; verify on multi-step architecture"
captain doctorWhen the provider is openrouter, Captain fetches price and context from the public catalog when you omit them. Restart the brain and relaunch the terminal afterwards.
NVIDIA NIM model
NIM and NVIDIA share the Integrate API endpoint (https://integrate.api.nvidia.com). Use the nim/ provider prefix:
captain legs add kimi-flash nim/moonshotai/kimi-k2-thinking --prior 7.5 \
--note "NIM thinking variant; probe once before trusting"
export NVIDIA_API_KEY=… # or the key captain init expects for nim
captain doctorCompiled legs already use NIM for /kimi and /minimax. To repoint an existing leg without losing its scorecard:
export CAPTAIN_GLM_PROVIDER=openrouter
export CAPTAIN_GLM_MODEL=z-ai/glm-5.3Hugging Face model
Captain ships /step (Step 3.5 Flash) and /ds4-flash (DeepSeek V4 Flash) on the Hugging Face router. Add more with the huggingface/ provider prefix. They count as open weights, so they join the /oss pool:
captain legs add ds-r1 huggingface/deepseek-ai/DeepSeek-R1 --prior 7.0 \
--note "HF router; probe once before trusting"
captain doctorRestart the brain and relaunch the terminal afterwards. Force with /step … or /ds4-flash …, or leave bare prompts to captain. Set HF_TOKEN for the router.
Forced legs and chains
Prefix a prompt with a leg name to force it for one turn: /grok, /frontier, /codex-cli. Use /btw mid-run on supported legs; /captain switches director. Chains use > and +:
/grok draft the migration > /cursor review it + /claude red-team it
Forced syntax bypasses the director for that turn only. Bare prompts stay on captain. See Workflows.
What doctor checks
Doctor reports which legs are ready, blocked, or skipped. Blocked lines include the one command that unblocks them. Doctor reads auth store keys only, never credential values. Always invoke a new leg once with a real prompt before trusting catalogue metadata.