Skip to content

Model selection

The MCP server normally omits --model, so Codex CLI selects the model from your account and $CODEX_HOME/config.toml. Pass model only when a task needs a deliberate override.

This list was verified against Codex CLI 0.144.3 and its model cache on 2026-07-13. Availability still depends on account, workspace, and rollout.

ModelBest forGuidance
gpt-5.6-solComplex, open-ended, high-value workStrongest default when quality matters
gpt-5.6-terraEveryday coding and tool useBalanced capability and cost
gpt-5.6-lunaClear, repeatable, high-volume workFastest and most affordable GPT-5.6 option
gpt-5.5Previous-generation frontier workCompatibility fallback
gpt-5.4Professional coding workflowsCompatibility fallback
gpt-5.4-miniSmall, well-scoped tasksLow-cost compatibility fallback

The official Codex guidance is to start with Sol when unsure, use Terra as the everyday workhorse, and use Luna when the task is specific and success is easy to verify.

Reasoning effort

Supported MCP values are low, medium, high, xhigh, max, and ultra. The selected model and account determine which values are actually available.

  • Start with medium.
  • Use low for quick, tightly scoped tasks.
  • Use high or xhigh for difficult multi-step work.
  • Use max only for the hardest single-agent problems where latency matters less.
  • Use ultra only when the task can benefit from automatic delegation to subagents.

Most tasks do not need max or ultra. In the verified CLI cache, Sol and Terra expose both; Luna exposes max but not ultra.

Examples

Direct CLI:

bash
codex exec -m gpt-5.6-sol "Review the current changes"
codex exec -m gpt-5.6-terra "Refactor the request parser"
codex exec -m gpt-5.6-luna "Classify these build errors"

MCP invocation:

json
{
  "prompt": "Audit @src for command-building regressions",
  "model": "gpt-5.6-sol",
  "reasoningEffort": "high"
}

For the default model, omit model:

json
{
  "prompt": "Explain @src/utils/codexCommandBuilder.ts"
}

Set a persistent default in $CODEX_HOME/config.toml:

toml
model = "gpt-5.6-sol"
model_reasoning_effort = "medium"

Local models

Local provider model names are passed through without OpenAI model validation:

json
{
  "prompt": "Explain @src",
  "localProvider": "ollama",
  "model": "qwen3:8b"
}

There is no MCP-side automatic fallback chain. When no override is supplied, Codex CLI remains the source of truth. An unknown explicit model is passed through so newer rollouts and local providers are not blocked by this package.

See the official Codex model guide for current availability and recommendations.

Released under the MIT License.