Delegate specialized tasks to AI sub-agents with fine-grained permissions:
# Single agent execution
codex delegate code-reviewer --scope ./src --budget 40000
# Parallel execution (NEW!)
codex delegate-parallel code-reviewer,test-gen,sec-audit \
--goals "Review code,Generate tests,Security audit" \
--scopes ./src,./tests,./package.json \
--budgets 40000,30000,20000
# Custom agent from prompt (NEW!)
codex agent-create "Find all TODO comments and create a summary report" \
--budget 50000| Agent | Purpose | Token Budget |
|---|---|---|
code-reviewer |
Security, performance, best practices analysis | 40,000 |
test-gen |
Unit/Integration/E2E test generation (80%+ coverage) | 30,000 |
sec-audit |
CVE scanning, dependency audit, patch recommendations | 50,000 |
researcher |
Deep research with citations and cross-validation | 60,000 |
- Parallel Execution: Run multiple agents simultaneously for 3x faster completion
- Custom Agents: Create agents from natural language prompts with LLM-powered generation
- Process Isolation: Each agent runs in a separate process for enhanced security
Quick Start: See SUBAGENTS_QUICKSTART.md and PARALLEL_CUSTOM_AGENT_GUIDE.md
Multi-source research with citation and contradiction detection:
codex research "Rust async programming best practices" --depth 3Features:
- DuckDuckGo HTML scraping (no API key required)
- Smart sub-query generation
- Cross-source validation
- Cited reports with confidence scores
New: Codex itself as an MCP server for sub-agents!
# .codex/agents/my-agent.yaml
tools:
mcp:
- codex_read_file # Full Codex file reading
- codex_grep # Full Codex grep
- codex_codebase_search # Semantic searchStatus: ๐ง Implementation in progress Design: _docs/2025-10-11_CodexMCPๅ่จญ่จๆธ.md
This fork maintains dual compatibility with:
- โ OpenAI official repository
- โ zapabob enhancements
Development Guide: .codex/META_PROMPT_CONTINUOUS_IMPROVEMENT.md
-
Continuous Integration: Automated testing on every PR
- 3 platforms (Ubuntu, Windows, macOS)
- Clippy lint + Rustfmt check
- Agent definition validation
- Integration tests (Deep Research + Sub-Agent)
- Security audit (cargo-audit)
-
Continuous Delivery: Automated releases on tag push
- Multi-platform binaries (Linux x64, Windows x64, macOS x64/ARM64)
- npm package generation
- GitHub Release creation
- Auto-generated release notes
CI/CD Guide: CI_CD_SETUP_GUIDE.md
Codex is an AI-powered coding assistant that runs in your terminal. It helps you write, understand, and improve code through natural conversation.
- Interactive Chat: Natural language conversations about your code
- Code Understanding: Analyze, explain, and refactor existing code
- File Operations: Read, write, and modify files with AI assistance
- Shell Integration: Execute commands safely with sandboxing
- MCP Support: Extensible via Model Context Protocol
- Multi-Model: Support for GPT-4, Claude, and local models
npm install -g @openai/codexgit clone https://github.com/zapabob/codex.git
cd codex/codex-rs
cargo build --release -p codex-cli
npm install -g ./codex-cliImportant: If you're building on Apple Silicon (ARM64) Macs, follow these additional steps:
Issue: The default configuration in codex-rs/.cargo/config.toml forces target-cpu=x86-64 globally, causing build errors on ARM64 Macs:
error: 'x86-64' is not a recognized processor for this target (ignoring processor)
Complete Build Steps for Apple Silicon:
- Edit the config file: Remove or comment out the
[build]section incodex-rs/.cargo/config.toml:
# Remove or comment out these lines:
# [build]
# # Use generic x86-64 instruction set to avoid ILLEGAL_INSTRUCTION errors
# rustflags = ["-C", "target-cpu=x86-64"]- Build the project:
cd codex/codex-rs
cargo build --release -p codex-cli- Copy binary to npm vendor directory:
cd ..
mkdir -p codex-cli/vendor/aarch64-apple-darwin/codex
cp codex-rs/target/release/codex codex-cli/vendor/aarch64-apple-darwin/codex/codex
chmod +x codex-cli/vendor/aarch64-apple-darwin/codex/codex- Install globally:
npm install -g ./codex-cli- Verify installation:
codex --version# Start interactive session
codex
# Non-interactive execution
codex exec "Add error handling to main.rs"
# Deep research
codex research "Topic to research"
# Delegate to sub-agent
codex delegate code-reviewer --scope ./src
# Resume previous session
codex resume# Login
codex login
# View status
codex login status
# Configure model
codex -c model="gpt-4" "Your prompt"โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ Codex CLI (Node.js) โ
โ codex, codex exec, codex delegate โ
โโโโโโโโโโโโโโโโโโโโฌโโโโโโโโโโโโโโโโโโโโโโโ
โ
โโโโโโโโโโโโโโโโโโโโผโโโโโโโโโโโโโโโโโโโโโโโ
โ Codex Core (Rust) โ
โ โโโโโโโโโโโโโโโโ โโโโโโโโโโโโโโโโโโโ โ
โ โ AgentRuntime โ โ ModelClient โ โ
โ โ Sub-Agents โ โ LLM Interface โ โ
โ โโโโโโโโโโโโโโโโ โโโโโโโโโโโโโโโโโโโ โ
โ โโโโโโโโโโโโโโโโ โโโโโโโโโโโโโโโโโโโ โ
โ โ Deep Researchโ โ MCP Integration โ โ
โ โโโโโโโโโโโโโโโโ โโโโโโโโโโโโโโโโโโโ โ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
We welcome contributions! Please see:
This project is licensed under the Apache License 2.0 - see the LICENSE file for details.
- OpenAI - Original Codex project
- Anthropic - Claude model support
- Contributors - All contributors to the project
- Issues: GitHub Issues
- Discussions: GitHub Discussions
- Twitter: @zapabob
Made with โค๏ธ by the Codex community
Version: 0.47.0-alpha.1
Last Updated: 2025-10-11