This template applies to both:
- Codex Web
- Codex App (Desktop)
To avoid procedural complexity, all three platforms share the same canonical Skill body and compact metadata stub:
- Canonical Skill body:
.agents/skills/<skill>/SKILL.md(shared standards-compatible path for supported hosts). - Compact Agentic OS metadata stub:
.agent/skills/<skill>(flat file; points to the canonical body and carries phase/trigger metadata). - Platform Workflow Files:
.agent/workflows/*.mdand.agent/rules/*.md(No duplication).
Minimum Check Recommendations:
- Run
./.agentcortex/bin/validate.sh. - Confirm
AGENTS.mdstill declares both.agent/skillsand.agents/skills.
Use the canonical state machine:
Ref: .agent/rules/state_machine.md
/help,/commands,/test-skeleton, and/handoffare Read-Only commands./shipis allowed only afterTESTEDstate.
- Provide target, target files, constraints, and acceptance criteria (AC) at the start of a task.
- Run
/bootstrapfirst, then/plan; only run/implementonce the quality gate has passed. - Run
/reviewand/testafter every implementation. - Run
./.agentcortex/bin/validate.shbefore submission.
GitHub repository Contributors are derived from commit attribution on the default branch, not from repository collaborator invitations. If a project wants Codex-authored work to appear as codex in the Contributors panel, keep at least one merged commit authored or co-authored with the GitHub-linked no-reply address for the codex account.
Recommended author identity for Codex App/Web-authored commits:
Codex <267193182+codex@users.noreply.github.com>
When merging a Codex-authored PR, prefer a merge or rebase merge that preserves individual commit authors. If using squash merge, preserve a Co-authored-by: Codex <267193182+codex@users.noreply.github.com> trailer in the final squash commit.
Before /ship, you must have a /handoff. Minimum reference requirements:
- At least 1
docs/artifact. - At least 1 code file path.
- Corresponding work log:
.agentcortex/context/work/<worklog-key>.md. Resolve<worklog-key>from the branch using a filesystem-safe name; if the active log is missing but recoverable, recreate it before rejecting/ship.
If unsatisfied, you must reject /ship and list the missing items.
On Codex Web there is no file-write capability. Gate receipts MUST still be recorded for validator compliance. Protocol:
- At each phase completion, output the gate receipt as a fenced block in chat:
## Gate Evidence - Gate: <phase> | Verdict: PASS | Classification: <tier> | Timestamp: <ISO> - Instruct the user: "Paste the block above into
.agentcortex/context/work/<worklog-key>.mdunder## Gate Evidence." - Do NOT proceed to the next phase until the user confirms the paste is done (or acknowledges they will do it before
/ship). - At
/ship, the Gate Receipt Audit checks the Work Log — if receipts are missing because the user did not paste them,/shipMUST fail withmissing: [<phase> receipt].
This ensures Codex Web-authored Work Logs remain validator-compliant even without direct file access.
Handoff timing follows the cross-platform SSoT — AGENTS.md §Context Pruning (context occupancy + phase boundary, not turn-count). Codex nuance (.agentcortex/docs/guides/token-governance.md §6.1): automatic prompt caching is active (0.1×, prefix ≥1024 tok; 24 h extended on GPT-5.1), and auto-compaction fires late (~95% capacity) and can derail mid-task — so prefer handing off at a clean phase boundary before that.
- Use one thread per requirement to avoid context pollution.
- Before pausing a long task, output
/handoffand remind the human to save it.
- Run
deploy_brain.shand validation scripts locally. - Update the work log after every submodule completion to reduce context reconstruction costs.
-
/bootstrapcompleted -
/planpassed quality gate -
/implementexecuted inIMPLEMENTABLEstate -
/reviewand/testcompleted -
/handoffcompleted for non-tiny-fix tasks -
validate.shpassed