Codex Workers MCP

Software · Case study

A durable local service that lets Claude Code plan work and hand it to parallel Codex coding agents, each isolated in its own Git worktree, with crash-safe job queues, cancellation and automatic quality checks.

Tech

  • JavaScript
  • Node.js
  • MCP
  • SQLite
  • Git
  • Codex SDK

Overview

Claude Code is good at planning and reviewing; Codex is good at implementing. This project connects them: Claude plans a change and dispatches tasks through MCP tools, Codex “workers” implement them in parallel, and a local service tracks every job, runs the repository’s checks on the result and reports a verdict before anything is merged.

The engineering challenge

AI coding agents are long-running, can fail halfway, and must not trample each other’s files or the developer’s working tree. Running several at once needs the same things as any job system: durable state, a scheduler, cancellation that actually stops work, recovery after a crash, and safe retries.

Architecture

Key decisions

Verification

Backend behaviour (thread creation, resume after a fresh process, streaming, cancellation mid-command) was verified with spike scripts before the design was fixed. The test suite covers worker lifecycle, integration, the MCP surface, model policy, quotas, gate baselines and profiles.

What I’d do next

Reattaching to a running turn after a service crash (the SDK doesn’t support it yet), and a fork operation for branching a worker’s conversation.

Settings

Sound
Music

Destiny 2 orbit music, streamed from YouTube after your first click. Destiny music © Bungie, Inc.

Motion
Effects

Light uses simpler glass, stars and orb effects. Auto picks it on phones and slower devices.

Pointer

Saved in this browser only.