agentleFS
aashahinaashahin/claude-codex-delegate/skills/codex-delegate/SKILL.md

codex-delegate

Skill1 starsChanged 2 months agoMITView on GitHub

Delegate coding or analysis work to an OpenAI model through the Codex CLI (GPT-6 Sol, Astra, Luna, GPT-5.6 Terra… anything `list_models` shows) while Claude stays the orchestrator. Use when the user says things like "use sol 6 to implement X", "have codex do it", "delegate this to gpt-6", "let sol write it and you review", "get a second opinion from codex", or asks to run/compare several Codex models, including from subagents and workflows.

17 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use delegate-setup, agy-delegate and 1 more.

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.
  • amElnagdySkill

    delegate-setup

    Configure delegation fleet lanes: which implementer CLI handles which kind of work, with optional model and effort (or variant) dials. Discovers installed CLIs, proposes a lane map for user approval, and writes global or project config only after explicit yes. Use when the user asks to set up, configure, or reconfigure delegation lanes, a fleet of lanes, or which implementer handles feature/tests/ui work — not for dispatching a coding task to an implementer.

    Also in 3 projects that use this

  • amElnagdySkill

    agy-delegate

    Delegate a coding task to the Google Antigravity CLI (`agy`) as a background implementer, then review its diff and land it yourself. Use this whenever the user wants to hand implementation work to Antigravity or agy - phrasings like "have Antigravity do X", "delegate this to agy", "run it through agy", or "use Antigravity to implement/fix/refactor" - or wants to run a queue of coding tasks through agy while staying the reviewer. DO NOT USE for tasks small enough to do inline, or when the user wants the code written directly without delegating.

    Also in 3 projects that use this

  • StoicEnsoSkill

    claude-delegate

    Give Claude back to OpenClaw through a local Claude Code delegation lane with dispatch, poll, result, resume, and an optional non-root bypassPermissions runner. Use when: you want Claude subscription access available to OpenClaw agents through a stable local worker lane, need resume/monitoring in a bounded workspace, or need Claude auth separate from OpenClaw providers. Don't use when: the user explicitly wants an ACP chat harness or thread, use acp-router plus sessions_spawn(runtime: \"acp\"); the task is a simple edit or shell command, use edit/exec directly; or the local Claude runner is not set up yet, read references/setup.md first.

    Also in 3 projects that use this

The file

We split this skill into the rules it gives an agent

7 rules. 0 are common, 3 are distinctive, and 4 are very specific to this project.

  • 0

    Common

    Most of the 12 edited versions we read keep these.

  • 3

    Distinctive

    This author's own choices. Worth a look.

  • 4

    Very specific

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

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    If the user names no model, omit model.

    line 33
  2. Distinctive:

    Report: ask for a short summary of the changes and anything left undone.

    line 45
  3. Very specific:

    Keep cwd at the project root unless the task is scoped to a subdirectory.

    line 47
  4. Very specific:

    If a run fails because it couldn't install a dependency or reach the network, install it yourself or re-run with danger-full-access.

    line 58
  5. Distinctive:

    Read the diff (git diff, or read the new files) for the files it lists.

    line 66
  6. Distinctive:

    Run the tests or build yourself.

    line 67
  7. Very specific:

    Fan out: call delegate_async once per subtask, then task_result with wait_s for each.

    line 74

“Common” is measured: kept by at least 6 in 10 of the 12 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

Delegating to Codex models

The codex MCP server runs tasks with codex exec in the user's project. The delegated model has Codex's own tools (shell, apply_patch), so it can implement code, not just answer. You stay the orchestrator: you plan, write the brief, and review what comes back.

Tools

ToolUse
list_models (filter?)See model slugs and the reasoning efforts each supports.
delegateRun a task and wait for the result.
delegate_async → task_result (wait_s)Long tasks, or several runs in parallel. Also task_list, task_cancel.
list_sessionsFind a session_id to continue.

In a plugin install the tools are named like mcp__plugin_codex-delegate_codex__delegate. With a manual install they are mcp__codex__delegate.

Picking the model and effort

  • Pass what the user said: model: "sol 6", "gpt 6 luna", "5.6 terra". The server matches loose names against the account's model list. A name without a version picks the newest family ("sol" → gpt-6.1-sol). "gpt 6" alone is ambiguous: pick from the candidates, or ask the user if their intent is unclear.
  • Reasoning effort: effort: "high", or a suffix, "sol 6#high". Levels are low, medium, high, xhigh and max, plus ultra on some models. If the user doesn't ask for one, omit it and Codex's configured default applies. Use low for trivial, mechanical edits.
  • If the user names no model, omit model. Codex then uses the model from ~/.codex/config.toml (list_models marks it (default)).
  • Speed: fast: true uses the Fast (priority) tier, which is quicker but uses more of the user's allowance. fast: false forces the normal tier. Omit it to inherit service_tier from config.toml. Use it when the user asks for fast or for normal speed.
  • On a follow-up with session_id, omit model to keep the session's model.

Writing the brief (prompt)

The delegated model cannot see this conversation. Write a self-contained brief:

  1. Goal: what to build or fix, and why.
  2. Context: the relevant files and paths, the existing patterns to follow, and the commands to build and test.
  3. Constraints: what not to touch, and the style to follow. Tell it not to commit unless you want a commit.
  4. Done when: the acceptance criteria, e.g. "bun test passes" or "prints X".
  5. Report: ask for a short summary of the changes and anything left undone.

Keep cwd at the project root unless the task is scoped to a subdirectory. Use images for screenshots or mockups.

Sandbox

sandboxCan do
workspace-write (default)Edit files under cwd and run commands. No network.
read-only (or auto: false)Read and run read-only commands. Use it for reviews, questions and second opinions.
danger-full-accessAnything, including installing packages and using the network. Use it only when the task needs that, and say so in your reply.

If a run fails because it couldn't install a dependency or reach the network, install it yourself or re-run with danger-full-access.

After it returns: review, don't trust blindly

The result reports status, session_id, token usage, the tools used, files edited by codex (every file it patched) and git changes (the new porcelain entries).

  1. Read the diff (git diff, or read the new files) for the files it lists.
  2. Run the tests or build yourself.
  3. To fix something, either continue the same session with delegate and session_id, giving precise feedback, or fix it yourself if that's quicker.
  4. Tell the user which model did what, and your verdict on it.

Parallel and multi-model patterns

  • Fan out: call delegate_async once per subtask, then task_result with wait_s for each. Parallel tasks that edit files must use separate git worktrees (git worktree add) or non-overlapping files, because they share the directory.
  • Compare: give the same brief to 2–3 models (e.g. sol 6 and 5.6 terra) in separate worktrees, then diff the results and pick or merge the best one.
  • Second opinion: sandbox: "read-only" with a prompt like "review this diff for bugs: …".
  • Subagents / workflows: the codex-worker agent wraps this loop. Spawn it with the model and task in its prompt, e.g. "Use codex model sol 6 to add tests for src/foo.ts".

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.