codex-agent

codex-agent is a skill for Claude Code, Codex from majiayu000/spellbook. It costs 45 tokens per session (1,886 once invoked), scanned A, original, MIT.

A skill for asking the Codex command-line agent for a second opinion on code, debugging, or possible implementations. It requires an installed and authenticated Codex CLI.

In plain words
What is it for?
Use it to review files or directories, cross-check another agent's work, investigate failures, and receive feedback with file paths and line numbers.
Why use it?
It gives a separate read-only review that can reveal security issues, bugs, performance problems, or alternative approaches before changes are made.

Skill for Claude CodeCodex

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add skills/majiayu000/spellbook/codex-agent
Any agent
npx skills add majiayu000/spellbook --skill codex-agent
Clone the repo
git clone --depth 1 https://github.com/majiayu000/spellbook

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for codex-agent

README.md
[![agentmods](https://agentmods.dev/badge/skills/majiayu000/spellbook/codex-agent.svg)](https://agentmods.dev/skills/majiayu000/spellbook/codex-agent)
Your own site
<a href="https://agentmods.dev/skills/majiayu000/spellbook/codex-agent"><img src="https://agentmods.dev/badge/skills/majiayu000/spellbook/codex-agent.svg" alt="Measured on agentmods" height="20"></a>
Per session 45 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,886 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00045 $0.01886
Opus 5 $0.00023 $0.00943
Sonnet 5 $0.00009 $0.00377
Haiku 4.5 $0.00005 $0.00189

Measured 6d ago against content hash 2d485f33a824, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-05, from the pricing page.

Security

Grade A, and why

codex-agent scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 6d ago.

The scan reads SKILL.md. This mod also ships 2 executable files (scripts/check-codex.sh, scripts/codex-wrapper.sh), listed below but not scanned — reading those needs a real analyzer, not pattern matching.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

skills/codex-agent/SKILL.md · 264 lines

How it starts

The opening of the file, as written. The whole thing — 264 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Codex Agent Collaboration Skill

This skill enables Claude Code to collaborate with OpenAI's Codex CLI agent for second-opinion review, cross-verification, debugging analysis, and alternative implementation proposals.

Default posture: Codex reviews in read-only; the primary agent applies changes only when the user asked for fixes or approved them after reading the review.

Optional Codex Review Workflow

Use this workflow when the user asks for Codex review, wants a second opinion, or needs cross-verification from a separate coding agent.

Step 1: Call Codex and Read Feedback

REPORT="$(mktemp -t codex-review.XXXXXX.md)"
codex exec -C <project_path> -s read-only -o "$REPORT" \
  "Review the code in <file_or_directory>. Check for:
   - Security vulnerabilities
   - Performance issues
   - Code quality and best practices
   - Potential bugs and edge cases
   - Naming and readability
   Provide specific, actionable feedback with file paths and line numbers."

cat "$REPORT"

Keep the write and read in the same Bash call, or pass a concrete report path between calls; shell variables do not persist across tool calls.

Step 2: Apply Fixes Based on Codex Feedback

When the user asked to apply fixes, handle each issue identified by Codex:

  1. Read the relevant file
  2. Apply the fix using Edit tool
  3. Verify the fix addresses Codex's concern

If the user only asked for a review or second opinion, report findings without editing files.

Step 3: Re-verify with Codex (Optional)

codex exec -C <project_path> -s read-only \
  "Verify the fixes applied to <files>. Confirm issues are resolved."

Workflow Examples

Example 1: Review and Fix a Single File

# Step 1: Get Codex review
REPORT="$(mktemp -t codex-review.XXXXXX.md)"
codex exec -C /project -s read-only -o "$REPORT" \
  "Review src/auth/login.ts for security vulnerabilities and code quality issues. Provide specific line numbers and fixes."

# Step 2: Read the feedback
cat "$REPORT"

Read the full file on GitHub · 264 lines

Files

What ships with it

6 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 6d ago First seen · 264 lines · 45 tokens per session scan A 2d485f33a824

Subscribe to this mod's changes

codex-agent is a skill published in the GitHub repository majiayu000/spellbook (265 stars, last pushed today), licensed MIT. It adds 45 tokens to every session and 1,886 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other skills, from other repositories

cao-session-management

Interact with CAO (CLI Agent Orchestrator) — launch multi-agent sessions, check status, send follow-up instructions, unblock stuck terminals, or shut down sessions. Use when working with CAO sessions in any capacity.

awslabs/cli-agent-orchestrator · 49 tokens

session-share

Share Claude Code sessions between developers. Use when user mentions "share session", "export session", "import session", "send session to", "continue from colleague", or needs to (1) export current session to file, (2) import session from another developer, (3) hand off work context. Enables private, secure session…

asheshgoplani/agent-deck · 76 tokens

workflow

Skill "workflow" from zhinkgit/embeddedskills, covering workflow 编排层, 命令, 配置说明, 配置结构 and 参数解析顺序.

zhinkgit/embeddedskills · 88 tokens

pneuma-session

Rewrite the active Pneuma session's UI title + one-line summary so the launcher and ProjectPanel rows reflect what the session is actually about. Use this skill whenever the user asks to "整理 / 概括 / refresh / re-title / summarize this session", whenever the conversation has produced substantive work and the default…

pandazki/pneuma-skills · 127 tokens

fast-resume

Search local coding-agent session history and identify safe resume commands. Use when the user asks to find, inspect, continue, or recover previous work from Claude Code, Codex, Pi, or another agent indexed by fast-resume.

angristan/fast-resume · 50 tokens

lov-finder-action

Generate Mac Finder right-click menu actions. Two modes: (A) Automator Quick Action for file/folder context menus, (B) Finder Sync Extension (Swift + xcodegen) for blank-space context menus. Automatically selects mode based on user intent. Trigger when user mentions "Finder右键", "右键菜单", "Quick Action", "Finder…

lovstudio/skills · 104 tokens