Claudex-Loop
by Chase AI
“Two AI models harden your plan before a line of code exists — then swap jobs to build it.” A Claude Code skill that puts OpenAI Codex in the role of adversarial reviewer against Claude’s plan, on the principle that whoever built the thing never grades it.
See https://github.com/chaseai-yt/claudex-loop
Licence — confirmed
MIT, Copyright (c) 2026 Chase AI. Verified in LICENSE — plain MIT with no appended scope note or carve-out, despite GitHub’s API reporting None.
What it is
Not an app — a Claude Code skill plus plugin, distributed as markdown. The repo is small (~400 KB: skills/, legacy/, assets/, README, LICENSE), because the deliverable is a workflow, not a binary.
The thesis is that AI-assisted coding fails in two gaps: between you and Claude (do we agree what to build?) and between Claude and its own output (is the plan correct, and how would you know?). A model cannot be trusted to grade its own plan — that is an echo chamber. So a rival, cross-provider model attacks it.
The four phases
| Phase | What happens |
|---|---|
| 0 — RECON | Claude scouts before asking anything: explores the codebase and docs, or researches prior art on greenfield. Opens with an Assumptions Ledger you batch-confirm, so the interview never asks what the code already answered |
| 1 — INTERROGATE | A decision map splits open decisions into load-bearing (asked one at a time) and cosmetic (batched, veto-by-exception). Every question must justify itself with why it matters, a committed recommendation, and what breaks if we guess wrong |
| 2 — REVIEW | Codex reviews PLAN.md in a read-only sandbox → VERDICT: APPROVED or REVISE with concrete flaws. Claude arbitrates, rejecting bad critiques with logged reasons, revises, and resumes the same Codex session so the reviewer remembers its prior findings and attacks its own accepted fixes. Bounded by MAX_ROUNDS |
| 3 — BUILD (optional) | Whoever did not write the code inspects it. Codex builds → Claude reads the whole diff like a contributor PR. Claude builds → a fresh read-only Codex session cross-inspects against the plan. Skipping requires an explicit, logged opt-out |
The invariant: whoever made the thing never checks the thing. Plan by Claude → attacked by Codex. Code by Codex → reviewed by Claude. Code by Claude → inspected by Codex.
You enter at exactly four points: confirming the ledger, answering the interview, signing off the converged plan, and approving the final diff. Codex is read-only throughout review and never touches a file.
Every run produces two artifacts: PLAN.md (the what) and PLAN-REVIEW-LOG.md (the round-by-round argument — the why).
Reported results
The README publishes numbers from its first end-to-end greenfield run (a solo-creator CRM): 55 findings across 5 rounds, converging 26 → 15 → 12 → 2 → 0, including one architecture that could not be built as written and roughly six models that would have shipped and corrupted data later.
Treat this as the author’s own single-run report, not an independent benchmark. The convergence shape is the interesting part — it is what you would expect from a working adversarial loop, and it is falsifiable if you run it yourself.
Superpowers
The design insight worth stealing even if you never install this: a reviewer with session memory is categorically better than a fresh one. Because Claudex-loop resumes the same Codex session across rounds, the reviewer attacks fixes it previously accepted — which is exactly where a naive one-shot review misses regressions.
The second is that MAX_ROUNDS produces a flagged deadlock rather than a fake approval. Most review loops are tuned to terminate in agreement; this one treats “we could not converge” as a legitimate, surfaced outcome. That is the honest engineering choice and the harder one to ship.
Best for planning work where being wrong is expensive — schema design, access paths, migrations — rather than routine changes where the ceremony would dominate.
Caveats
- Requires two paid model subscriptions — Claude Code and OpenAI Codex. Cross-provider adversarialism is the whole point, so it cannot be run single-vendor.
- Ceremony has a cost. Four phases, an interview and multi-round review is heavy for small changes; the value is concentrated in high-stakes planning.
- Evidence is self-reported from one run, as above.
- A
legacy/directory sits alongside the current skill, so check you are following the current entry point rather than superseded instructions.
Pricing
Free and open source under MIT. You pay for the two underlying model subscriptions.
Related
- Claude Code — the host; this ships as a skill plus plugin
- Codex — the adversarial reviewer
- Claude Code agents convention — related conventions for extending Claude Code
- Multi-Agent Systems — the supervisor/critic pattern this instantiates