This page documents the .omx-config.json keys that current oh-my-codex code recognizes, with extra detail for model and environment routing. Feature-owned settings such as notifications and OpenClaw remain documented near those features, but their supported key shapes are summarized here so this page can act as a safe schema map.
Do not add or edit keys unless your installed OMX version recognizes them. Unknown keys are not a stable extension point, and malformed JSON or wrong-shaped sections may be ignored or may fail closed for the feature reading them.
Most .omx-config.json readers resolve through the active Codex home:
| Setup shape | Config file | Notes |
|---|---|---|
| User scope | ${CODEX_HOME:-~/.codex}/.omx-config.json |
Default setup shape. CODEX_HOME wins when set. |
| Project scope | ./.codex/.omx-config.json |
Used by OMX launch paths when ./.omx/setup-scope.json says project and CODEX_HOME is not already set. |
Project-scoped setup also writes ./.codex/config.toml, ./.codex/hooks.json, and project-local skills/prompts/agents. User-scoped setup writes the corresponding files under ${CODEX_HOME:-~/.codex}.
The wiki lifecycle reader is a project-root exception because it runs from hook payload cwd: it checks <root>/.omx-config.json first, then ${CODEX_HOME:-~/.codex}/.omx-config.json, and falls back to built-in wiki defaults if neither file has a valid wiki object. The project-scope Codex-home file ./.codex/.omx-config.json still applies when CODEX_HOME resolves to ./.codex; it is not an extra wiki-only lookup path.
omx setup --scope project persists the project-scope choice in ./.omx/setup-scope.json; omx doctor prints the resolved setup scope and the Codex home/config paths it is checking.
Current code recognizes these top-level .omx-config.json keys:
| Top-level key | Supported shape | Primary use |
|---|---|---|
env |
Object of non-empty string values | Fallback environment values for model routing and helper launch paths. Model-related supported keys are listed below. |
models |
Object of non-empty string values | Mode defaults and low-complexity model aliases. Supported model-routing keys are listed below. |
notifications |
Object | Notification transports, profiles, templates, cooldowns, replies, and OpenClaw/custom aliases. See the notification summary below and the OpenClaw guide for full examples. |
stopHookCallbacks |
Legacy object | Backward-compatible legacy session-end notification config for telegram and discord; prefer notifications. |
promptRouting |
{ "triage": { "enabled": boolean } } |
Enables/disables advisory triage prompt routing. Missing key defaults to enabled; malformed shape fails closed to disabled. |
autoNudge |
Object | Native auto-continuation settings for matched permission/stall prompts. Supported keys: enabled, patterns, response, delaySec, stallMs, ttlMs, and legacy cooldownMs. This is not the deprecated team worker stall/progress nudge path; do not add OMX_TEAM_PROGRESS_STALL_MS or OMX_TEAM_WORKER_TURN_STALL_MS as operator tuning guidance. |
wiki |
Object | Project wiki lifecycle settings. Supported keys: enabled, autoCapture, maxContextLines, staleDays, maxPageSize, feedProjectMemoryOnStart. |
notifications supports the following current shapes:
- Global fields:
enabled,verbosity(verbose,agent,session, orminimal),defaultProfile,profiles,events,hookTemplates,reply,dispatchCooldownSeconds, andidleCooldownSeconds. - Platform fields:
discord,discord-bot,telegram,slack,webhook. - OpenClaw/custom transport fields:
openclaw,custom_webhook_command, andcustom_cli_command. - Event keys under
events:session-start,session-stop,session-end,session-idle, andask-user-question. Each event can setenabled,messageTemplate, and platform overrides. hookTemplatessupportsversion,enabled,events, anddefaultTemplate; per-event template config supportsenabled,template, and platform template overrides.replysupportsenabled,authorizedDiscordUserIds,pollIntervalMs,rateLimitPerMinute,maxMessageLength, andincludePrefix.notifications.openclawsupportsenabled,gateways, andhooks. Gateway entries are HTTP (type,url,headers,method,timeout) or command (type,command,timeout). Hook entries usegateway,instruction, andenabled.
Use docs/discord-integration.md for Discord webhook-vs-bot setup and docs/openclaw-integration.md for full notification/OpenClaw examples. Keep credentials in environment variables where possible.
The model-routing reader supports two top-level objects: env and models.
{
"env": {
"OMX_DEFAULT_FRONTIER_MODEL": "gpt-5.5",
"OMX_DEFAULT_STANDARD_MODEL": "gpt-5.4-mini",
"OMX_DEFAULT_SPARK_MODEL": "gpt-5.3-codex-spark"
},
"models": {
"default": "gpt-5.5",
"team": "gpt-5.5",
"team_low_complexity": "gpt-5.3-codex-spark"
}
}env provides fallback environment values when the real shell environment did not set them. Shell environment variables still win.
Supported model-related keys:
| Key | Purpose |
|---|---|
OMX_DEFAULT_FRONTIER_MODEL |
Main/frontier default used by leaders and frontier-class roles when no stronger config wins. |
OMX_DEFAULT_STANDARD_MODEL |
Optional standard-lane override. If omitted, standard agents inherit the main/frontier default. |
OMX_DEFAULT_SPARK_MODEL |
Spark/fast-lane default for low-cost exploration and low-complexity workers. |
OMX_SPARK_MODEL |
Legacy spark fallback; prefer OMX_DEFAULT_SPARK_MODEL for new config. |
OMX_TEAM_CHILD_MODEL |
Default child model for specific team-child paths that read this setting directly. |
readConfiguredEnvOverrides() also passes through other non-empty string values from env for launch helpers such as omx explore and omx sparkshell. Treat those as advanced environment overrides, not a schema for per-role model routing.
models maps mode names to explicit model overrides. Values must be non-empty strings.
Supported model-routing keys:
| Key shape | Purpose |
|---|---|
default |
Fallback for getModelForMode(mode) when the requested mode has no explicit key. |
Any mode key, for example team, autopilot, ralph |
Explicit model for that mode when code calls getModelForMode("mode"). |
team_low_complexity |
Low-complexity team/spark model override. |
team-low-complexity |
Alias for team_low_complexity. |
teamLowComplexity |
Alias for team_low_complexity. |
Do not invent per-role maps such as models.executor, models.architect, or models.roles unless your installed version documents that exact key. Current role routing is based on agent definitions and model class, not arbitrary per-role JSON maps.
The main default resolves in this order:
- Shell
OMX_DEFAULT_FRONTIER_MODEL .omx-config.jsonenv.OMX_DEFAULT_FRONTIER_MODEL- Active Codex
config.tomlrootmodel - Built-in default:
gpt-5.5
When code asks for getModelForMode(mode), the mode model resolves in this order:
.omx-config.jsonmodels[mode].omx-config.jsonmodels.default- Main/frontier default above
Example: with models.team = "gpt-5.5" and models.default = "gpt-5.4-mini", team uses gpt-5.5; a mode without its own key uses gpt-5.4-mini.
Standard-lane agents resolve in this order:
- Shell
OMX_DEFAULT_STANDARD_MODEL .omx-config.jsonenv.OMX_DEFAULT_STANDARD_MODEL- Main/frontier default
This means standard agents inherit the leader/frontier model unless you opt into a standard-lane override.
Spark/fast defaults resolve in this order:
- Shell
OMX_DEFAULT_SPARK_MODEL - Shell legacy
OMX_SPARK_MODEL .omx-config.jsonenv.OMX_DEFAULT_SPARK_MODEL.omx-config.jsonlegacyenv.OMX_SPARK_MODEL.omx-config.jsonmodels.team_low_complexity,models.team-low-complexity, ormodels.teamLowComplexity- Built-in default:
gpt-5.3-codex-spark
For team low-complexity helpers, the exact order depends on the call path: getSparkDefaultModel() checks spark env/config values before low-complexity aliases, while getTeamLowComplexityModel() checks low-complexity aliases before falling back to the spark default.
Native agent TOML generation and team model-contract logic use agent definitions with modelClass and reasoningEffort metadata. Native-agent generation has one important frontier-lane precedence detail: for frontier roles and the executor special case, it reads the active Codex config.toml root model first, then falls back to getMainDefaultModel() if that root model is absent. Because getMainDefaultModel() is only the fallback in this path, .omx-config.json env.OMX_DEFAULT_FRONTIER_MODEL does not override an explicit config.toml root model for generated native-agent TOML.
Examples:
| Role/category | Examples | Model class behavior |
|---|---|---|
| Frontier orchestration | planner, architect, critic, code-reviewer, security-reviewer, team-executor, vision |
Native-agent generation uses active config.toml root model first, then the main/frontier default fallback. |
| Standard worker/review | debugger, quality-reviewer, api-reviewer, performance-reviewer, dependency-expert, writer, researcher |
Uses the standard-lane default, which inherits main/frontier unless OMX_DEFAULT_STANDARD_MODEL is set. |
| Fast/low-complexity | explore, style-reviewer |
Uses the spark/low-complexity default. |
| Executor special case | executor |
Native-agent generation uses active config.toml root model first, then the main/frontier default fallback; team fallback routing keeps it on the frontier lane. |
Team worker launches add another layer:
- Explicit
--model ...insideOMX_TEAM_WORKER_LAUNCH_ARGSwins. - Inheritable leader launch model args can be passed through to workers.
- If no explicit/inherited model is present, the worker role's default model class selects the fallback model.
- Fast roles such as
exploreand role names ending in-lowuse the low-complexity/spark fallback.
Use omx team status <team-name> --model-inspect when you need inspect hints for a running team; the regular status path avoids spending model quota on summaries.
.omx-config.json is not the general place to configure model_reasoning_effort. Do not add keys such as reasoningEffort, modelReasoningEffort, reasoning, or per-role reasoning maps to .omx-config.json.
Supported reasoning-effort surfaces are:
- Active Codex
config.tomlroot key:model_reasoning_effort = "medium". omx reasoning <low|medium|high|xhigh>, which edits the active Codexconfig.toml.omx --highandomx --xhigh, which pass-c model_reasoning_effort="high|xhigh"to Codex launch.- Generated native agent TOML files, where OMX writes each role's built-in
reasoningEffortmetadata. - Team worker launch args, for example:
OMX_TEAM_WORKER_LAUNCH_ARGS='-c model_reasoning_effort="low" --model gpt-5.3-codex-spark' \
omx team 3:explore "map the config surfaces"Team runtime can also inject role-default reasoning for Codex workers when no explicit reasoning override is present. Explicit launch args win.
JSON does not allow comments, so copy only the JSON blocks.
This keeps orchestration on the frontier default, routes standard workers to a cheaper standard model, and uses the spark lane for exploration/low-complexity work.
{
"env": {
"OMX_DEFAULT_FRONTIER_MODEL": "gpt-5.5",
"OMX_DEFAULT_STANDARD_MODEL": "gpt-5.4-mini",
"OMX_DEFAULT_SPARK_MODEL": "gpt-5.3-codex-spark"
},
"models": {
"default": "gpt-5.4-mini",
"team": "gpt-5.5",
"team_low_complexity": "gpt-5.3-codex-spark"
}
}This keeps standard agents inheriting the frontier model by omitting OMX_DEFAULT_STANDARD_MODEL, while still preserving a fast spark lane for explicit low-complexity routing.
{
"env": {
"OMX_DEFAULT_FRONTIER_MODEL": "gpt-5.5",
"OMX_DEFAULT_SPARK_MODEL": "gpt-5.3-codex-spark"
},
"models": {
"default": "gpt-5.5",
"team": "gpt-5.5",
"autopilot": "gpt-5.5",
"ralph": "gpt-5.5",
"team_low_complexity": "gpt-5.3-codex-spark"
}
}After editing .omx-config.json or config.toml, run setup/doctor from the same shell and project shape that will launch OMX:
omx setup
omx doctoromx doctor reports the resolved setup scope, Codex home, config path, hook coverage, prompt/skill/agent availability, and selected prompt-routing status. This verifies install wiring and which config tree OMX is checking.
A green omx doctor is not proof that the active Codex profile can authenticate or run the selected model. For that, use the same shell/profile/project and run:
codex login status
omx exec --skip-git-repo-check -C . "Reply with exactly OMX-EXEC-OK"If behavior does not match your config, first confirm whether you are in user or project scope and whether CODEX_HOME is overriding the expected Codex home.
- Notification and OpenClaw config:
docs/openclaw-integration.md - Project wiki config:
docs/reference/project-wiki.md - Model routing source:
src/config/models.ts - Notification config source:
src/notifications/config.ts,src/notifications/types.ts,src/notifications/hook-config-types.ts - OpenClaw config source:
src/openclaw/types.ts,src/openclaw/config.ts - Prompt-routing config source:
src/hooks/triage-config.ts - Auto-nudge config source:
src/scripts/notify-hook/auto-nudge.ts - Wiki lifecycle config source:
src/wiki/types.ts,src/wiki/lifecycle.ts - Agent role definitions:
src/agents/definitions.ts - Native agent TOML generation:
src/agents/native-config.ts - Team model contract:
src/team/model-contract.ts - Scope/Codex home launch resolution:
src/cli/codex-home.ts