This directory contains the official OpenCode config templates for oc-codex-multi-auth.
| File | OpenCode version | Description |
|---|---|---|
opencode-modern.json |
v1.0.210+ | Variant-based config: 9 base models with 34 total presets |
opencode-legacy.json |
v1.0.209 and below | Legacy explicit entries: 34 individual model definitions |
The installer currently uses a merged full-catalog mode by default so users get both the modern base entries and the explicit preset entries without having to hand-edit opencode.json.
If your OpenCode version is v1.0.210 or newer:
cp config/opencode-modern.json ~/.config/opencode/opencode.jsonIf your OpenCode version is v1.0.209 or older:
cp config/opencode-legacy.json ~/.config/opencode/opencode.jsonCheck your version with:
opencode --versionOpenCode v1.0.210+ added model variants, so one model entry can expose multiple reasoning levels. That keeps modern config much smaller while preserving the same effective presets.
Both templates include:
- GPT-5.4, GPT-5.4 Pro, GPT-5.4 Mini, GPT-5.4 Nano, GPT-5 Codex, GPT-5.1, GPT-5.1 Codex, GPT-5.1 Codex Max, GPT-5.1 Codex Mini
- Reasoning variants per model family
store: falseandinclude: ["reasoning.encrypted_content"]- Context metadata (
gpt-5.4/gpt-5.4-pro: 1,050,000;gpt-5.4-mini/gpt-5.4-nano/Codex models: 400,000;gpt-5.1: 272,000; all output: 128,000)
Use opencode debug config to verify that these template entries were merged into your effective config. opencode models openai currently shows OpenCode's built-in provider catalog and can omit config-defined entries such as gpt-5.4-mini.
If your OpenCode runtime supports global compaction tuning, you can also set:
model_context_window = 1050000model_auto_compact_token_limit = 950000
The templates intentionally do not include gpt-5.3-codex-spark by default. Spark is often entitlement-gated at the account/workspace level, so shipping it by default causes avoidable startup failures for many users.
If your workspace is entitled, you can add Spark model IDs manually.
Modern template (v1.0.210+):
opencode run "task" --model=openai/gpt-5.4 --variant=medium
opencode run "task" --model=openai/gpt-5-codex --variant=highLegacy template (v1.0.209 and below):
opencode run "task" --model=openai/gpt-5.4-medium
opencode run "task" --model=openai/gpt-5-codex-highA barebones debug template is available at minimal-opencode.json. It omits the full preset catalog.
Current defaults are strict entitlement handling:
unsupportedCodexPolicy: "strict"returns entitlement errors directly- set
unsupportedCodexPolicy: "fallback"(orCODEX_AUTH_UNSUPPORTED_MODEL_POLICY=fallback) to enable automatic fallback retries fallbackToGpt52OnUnsupportedGpt53: truekeeps the legacygpt-5.3-codex -> gpt-5.2-codexedge inside fallback modegpt-5.4-pro -> gpt-5.4is included by default in fallback mode (relevant only if you addgpt-5.4-promanually)unsupportedCodexFallbackChainlets you override fallback order per model
Default fallback chain (when policy is fallback):
gpt-5.4-pro -> gpt-5.4(if you manually selectgpt-5.4-pro)gpt-5.3-codex -> gpt-5-codex -> gpt-5.2-codexgpt-5.3-codex-spark -> gpt-5-codex -> gpt-5.3-codex -> gpt-5.2-codex(only relevant if Spark IDs are added manually)gpt-5.2-codex -> gpt-5-codexgpt-5.1-codex -> gpt-5-codex
- Main config reference:
docs/configuration.md - Getting started:
docs/getting-started.md - Troubleshooting:
docs/troubleshooting.md