agentleFS
xmtplabsxmtplabs/code-factory/skills/codex-cli/SKILL.md

codex-cli

Skill1 starsChanged 6 months agoMITView on GitHub

Use when a code-factory skill or workflow drives OpenAI Codex — choosing a model and effort, scoping a session to the right checkout, or getting a cross-model adversarial review. Covers only the choices code-factory makes; the codex plugin owns the command surface.

15 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use antigravity-cli.

Other files people use alongside this one.

Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
  • yu-iskwSkill

    antigravity-cli

    Executes coding, review, research, and automation tasks using Google Antigravity CLI (`agy`). Uses Antigravity's native fine-grained allow/ask/deny permissions instead of Gemini CLI approval modes.

    Also in 3 projects that use this

The file

We split this skill into the rules it gives an agent

3 rules. 0 are common, 1 is distinctive, and 2 are very specific to this project.

  • 0

    Common

    Most of the 14 edited versions we read keep these.

  • 1

    Distinctive

    This author's own choices. Worth a look.

  • 2

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Don't restate either here.

    line 13
  2. Very specific:

    cwd is the checkout the session owns: Run the command from that directory.

    line 22
  3. Very specific:

    Call the companion script directly from a Bash step, from the owning checkout.

    line 67

“Common” is measured: kept by at least 6 in 10 of the 14 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Codex CLI

Codex is driven through the codex Claude Code plugin — /codex:rescue to delegate work, /codex:review and /codex:adversarial-review to review, /codex:setup to check the install. The plugin's own skills document the commands and flags; running the companion script bare (node "${CLAUDE_PLUGIN_ROOT}/scripts/codex-companion.mjs") prints its usage. Don't restate either here.

There is no mcp__codex__* tool surface. Don't ToolSearch for Codex tools, and don't build relay subagents whose only job is to forward a prompt.

This skill covers the calls code-factory makes on top of that.

Session scope

  • cwd is the checkout the session owns. Run the command from that directory. In worktree fan-outs that's the task's worktree, never the orchestrator's repo root — a session in the wrong directory edits the wrong checkout and reports success.
  • One thread per task per checkout. Resume within a task (review-fix cycles, follow-ups to a reviewer about its own findings). Start fresh for a new task or a new checkout: the thread's context describes paths that no longer match.
  • A reviewer never fixes its own findings. Reviews are review-only; findings go to a separate implementer session. Adversarial review needs a clean context per subject.

Model and effort

Verified against codex debug models on 2026-09-17.

JobModelEffort
Mechanical edit, rename, config changegpt-5.6-lunalow
Typical implementation taskgpt-6-astralow
Subtle implementation, tricky fixgpt-6-astrahigh
Adversarial review, plan review, final sweepgpt-6-astrahigh

Both Astra tiers use the identifier gpt-6-astra; set the tier with --effort. Astra defaults to medium, and also accepts xhigh, max, and ultra — use those only when a task explicitly calls for more than the flagship default. Don't use none or minimal with Astra. Fallbacks: gpt-5.6-sol, gpt-5.6-terra, gpt-5.5.

A bad model name fails instantly with a 400 ("not supported when using Codex with a ChatGPT account"); fix the name, nothing else is wrong.

Reviews

Cross-model review only counts when the author used a different model. Give the reviewer only the artifact and repo access — no drafting history, no author rationale.

Map Codex's output honestly: if it's ambiguous about whether an issue is real, it's a finding; never infer a PASS Codex didn't state. When a caller needs structure, report verdict PASS|ISSUES plus one entry per defect (severity, file, summary, concrete failure scenario).

In workflow scripts

Call the companion script directly from a Bash step, from the owning checkout. Keep a run log: the config used, the prompt verbatim, and Codex's complete final response verbatim — not a summary. The thread id in the output points into ~/.codex/sessions/ for the full transcript.

Map Codex's self-reported outcome honestly — "could not finish" is BLOCKED, not DONE. Treat its report as advisory and verify claims against the diff and tests.

Gotchas

SymptomFix
codex (CONNECTION_CLOSED) at session startRemove the mcpServers.codex entry: claude mcp remove codex --scope user. The plugin needs no MCP server.
Codex reports edits it didn't maketask is read-only without --write
A turn consumed by a flag--help after a subcommand is sent as a prompt; run the script bare for usage

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.