| name | init-project |
| description | AGENTS.md policies, .agents-mode.yaml bootstrap. |
Init Project
Guide the user through first-time Codex project bootstrap for project policies and operator mode state.
Continuity contract
- Use one primary in-progress task at a time.
- Side requests may temporarily interrupt that task, but they do not replace it unless the user explicitly reprioritizes, cancels, or parks it.
- After any side request, explicitly resume the primary task and state the next concrete step.
- After an accepted phase or completed batch, continue to the next clear step unless a real gate blocks progression.
- Before claiming completion, reconcile the current result against the original request and any still-open required follow-up inside the same task.
- If a required next action is already known and still inside the current task, keep the task open instead of stopping at a partial batch.
Preset expansion table
Presets are init-time shortcuts only. They expand into canonical agents-mode keys. The preset name is NOT persisted in the file.
| Key | default (safe-init) | absolute-balance (everyday center) | external-aggressive (aggressive external use) | correctness-first (no-time-limit correctness) | power-mode (hardest-task maximum result) | max-speed (speed-first) |
|---|
consultantMode | disabled | internal | external | external | external | disabled |
delegationMode | auto | auto | force | force | force | auto |
parallelMode | auto | auto | force | auto | force | force |
mcpMode | auto | auto | auto | force | force | auto |
preferExternalWorker | false | false | true | true | true | false |
preferExternalReviewer | false | true | true | true | true | false |
externalProvider | auto | auto | auto | auto | auto | auto |
externalPriorityProfile | balanced | balanced | balanced | balanced | quality-first | balanced |
reserveResolver | claude-sonnet | claude-sonnet | claude-sonnet | claude-sonnet | claude-sonnet | claude-sonnet |
externalPriorityProfiles | shipped as-is | shipped as-is | shipped as-is | shipped as-is | shipped as-is | shipped as-is |
externalOpinionCounts | all 1 | all 1 | all 1 | advisory+review lanes 2, others 1 | advisory+review lanes 2, others 1 | all 1 |
externalCodexWorkdirMode | neutral | neutral | neutral | neutral | neutral | project |
externalClaudeWorkdirMode | neutral | neutral | neutral | neutral | neutral | project |
externalModelMode | runtime-default | runtime-default | runtime-default | pinned-top-pro | pinned-top-pro | runtime-default |
externalCodexProfile | gpt-5.6-sol-xhigh | default | default | gpt-5.6-sol-xhigh | gpt-5.6-sol-xhigh | gpt-5.6-terra |
externalClaudeProfile | opus-xhigh | sonnet-high | sonnet-high | opus-max | opus-max | sonnet-high |
correctness-first and power-mode lane-specific opinion counts:
advisory.repo-understanding: 2
advisory.design-adr: 2
review.pre-pr: 2
review.security: 2
review.performance-architecture: 2
review.ui-visual-correctness: 2
- all other lanes:
1
Routing conventions (not persisted as keys):
- same-host fast-path: under
external-aggressive and max-speed, when neutral isolation is not required, allow per-invocation explicit self-provider override. Keep the stored file canonical; this is a routing rule, not a persisted key.
- overflow means spill, not serialize: under
external-aggressive, internal slot saturation pushes independent eligible lanes into $external-worker, $external-reviewer, or $external-brigade by default.
- power-mode means hardest-task maximum useful result: start from the
quality-first provider-priority profile, then combine correctness-first validation density with external-aggressive fan-out, while keeping neutral workdirs and production-only auto routing so the extra power does not become a hidden project-state or example-provider shortcut.
Steps
-
Read current state.
- Read the project's root
AGENTS.md and check whether a ## Project policies section already exists.
- Read
.agents/.agents-mode.yaml first.
- If it is missing, read legacy
.agents/.agents-mode as compatibility input only.
- If both local files are missing, fall back through pack-local global
~/.codex/.agents-mode.yaml, pack-local global legacy ~/.codex/.agents-mode, then the shared cross-pack global ~/.agents-mode.yaml (alongside ~/.claude.json), before applying built-in defaults. Each key resolves to the highest layer that defines it; layers compose, they do not replace each other wholesale.
- If either file exists, normalize it to the current canonical format before presenting or trusting the current values.
- If any file exists, normalize the effective file to the current canonical format before presenting or trusting the current values.
- Normalize whichever file supplied the effective config into the canonical
.yaml path in the same scope and do not recreate any legacy file. If the effective config came from the global scope, use it as the starting point for the project-local review instead of pretending there was no prior state.
- If either surface already exists, show the current values and ask whether to keep them, review them, or start fresh.
-
Read the installed canonical sources.
- Read the installed policy catalog from
../lead/policies-catalog.md.
- Read the installed Codex dispatch contract from
../lead/external-dispatch.md.
- Use those two files as the canonical source for policy choices, allowed
agents-mode values, and write rules instead of inventing parallel semantics.
-
Configure project policies.
- Walk through each policy area from the catalog one at a time.
- For each area:
- state the policy name and question
- list the allowed options with concise descriptions
- show the default
- accept shorthand answers or the default
- If the user says "defaults for the rest" or similar, apply defaults to all remaining policy areas.
-
Select a preset (optional).
- Ask the user if they want to start from a preset: , , , , , or .
Rules
- Be concise; the catalog and dispatch contract hold the details.
- Do not invent extra policy keys or extra
agents-mode keys.
- Preserve unknown keys in
.agents/.agents-mode.yaml when updating.
- Any read of
.agents/.agents-mode.yaml that drives a decision should normalize the file to the current canonical format before trusting the flags.
- Any read of the effective Codex overlay that drives a decision should normalize that file to the current canonical format before trusting the flags.
- Any read that drives a decision should prefer local
.agents/.agents-mode.yaml, then local legacy .agents/.agents-mode, then global ~/.codex/.agents-mode.yaml, then global legacy ~/.codex/.agents-mode, then the shared cross-pack global ~/.agents-mode.yaml; normalize whichever file supplied the effective config in the same scope and do not recreate any legacy file.
- Do not modify any other section of
AGENTS.md.
- Treat root
AGENTS.md as the project-runtime target, not the Orchestrarium monorepo maintenance overlay.