Skip to main content

Spec, plan and build, with independent review.

A test-driven development loop for Claude Code and Codex. Review agents check the plan before coding and the diff before commit.

Free and open source. Markdown skills and agents, no runtime.

/plugin marketplace add OneKashLabs/devloop
/plugin install devloop@onekashlabs

In Claude Code. Codex steps are below.

Reviewed by agents that didn’t write the code.

The plan review and the code review run in a context that did not write the plan or the code. You approve the result at two checkpoints.

How the loop works​

  1. /spec

    Clarify what to build: user stories and acceptance criteria. Or check an existing design doc.

  2. /plan

    Plan how to build it: chunks, dependencies and a JSON tracker. A bug fix starts with a proof: a failing test or a probe.

  3. review-plan

    An independent agent reviews the plan. Review, fix and re-review run unattended, up to 3 rounds by default.

  4. Checkpoint 1

    You approve the reviewed plan and every decision it made.

  5. /implement

    Build it with TDD, chunk by chunk: a failing test, the code, a passing test.

  6. review-impl

    An independent agent reviews the diff through conformance, correctness and cleanup lenses.

  7. Checkpoint 2

    You approve the findings and fixes. Then the finish steps run.

Small fixes take the fast lane

One production file plus its tests, with no new behavior beyond the fix, skips the tracker: the failing test, the fix, then the code review. /plan checks the size and takes it itself.

A wrong plan gets corrected

If a code-review finding shows the plan was wrong, /implement adds corrective chunks, has them reviewed and builds them, without asking by default. A finding that the spec was wrong always comes to you.

Why not a single prompt?

A coding agent can build a feature from one prompt. One prompt doesn’t give you the steps around the code.

One pass decides everything

What to build, how, and the code come out at once. A misread requirement is written as code, where it costs the most to undo.

The author grades its own work

“I verified it works,” from the context that wrote the code, is a self-report.

Long sessions lose the plan

A long session degrades and a resumed one starts cold, so the plan and the reasoning behind it are lost.

No hard gate

An agent can report “done” without a test that proves it.

Prompts don’t persist

They live in your head and drift from run to run and project to project.

The code review: three lenses​

review-impl reads the diff in a fresh context, read-only. Both reviews use one list of six concerns: does the change do what was asked, does it hold up, and can it be maintained.

Conformance

The change does what the plan says. Each acceptance criterion is confirmed by a quoted test, plausible (code, no test), or refuted.

Correctness, 5 angles

Line-by-line diff scan, removed-behavior auditor, cross-file caller and callee tracer, language-pitfall specialist, wrapper and proxy correctness.

Cleanup, 5 angles

Reuse, simplification, efficiency, altitude, and maintainability: stale docs, hard-coded environment values, dependency and versioning rules, error messages.

Conventions, in every lens

Reads your CLAUDE.md or AGENTS.md and .devloop/config.md, and flags only rules it can quote. A violation with a real fault fails the gate like a bug.

  • The correctness lens lists every candidate defect, then a verify pass keeps the CONFIRMED and PLAUSIBLE ones.
  • Each finding says whether the change introduced it. A pre-existing bug is reported and never fails the gate on its own.
  • Each report ends with one JSON list of findings.
  • A small diff gets one reviewer with every lens; a larger one gets one agent per lens.

To review a diff with no plan, such as a hotfix or someone else’s branch, give review-impl the diff range and say there is no tracker.

Install​

  1. Add the plugin

    /plugin marketplace add OneKashLabs/devloop
    /plugin install devloop@onekashlabs

    Claude Code finds the three skills and the two review agents.

  2. Give the loop your project’s context

    Put a .devloop/ folder at your project root. The fastest start is to copy the closest stack example (TypeScript and Node, Python, Rust, Android and Kotlin) and adapt it.

    .devloop/
    config.md # build, test and lint commands, architecture, standards,
    # blindspots, commit conventions, spec and tracker folders
    domain.md # domain context and domain-specific concerns, read by /spec
    trackers/ # impl-tracker-<feature>.json, written by /plan

    Commit config.md and domain.md so the team shares one context. Without .devloop/ the loop still runs, with less insight into your project.

  3. Start with a command

    Run /spec, /plan or /implement with your feature. You start each command yourself.

Choose how much it does without asking​

An optional ## Autonomy section in config.md tunes the stretches between the two checkpoints: review rounds per gate (default 3), whether plan corrections run on their own, the finish steps after the second checkpoint (default none), and extra stop conditions.

## Autonomy

- Review rounds: 3
- Convergence: auto
- Finish steps:
1. Run the full test suite and lint
2. Commit (see Commit Conventions)
- Stop and ask on: anything that publishes outside this repository

The config can also list pre-review checks, a verify recipe that runs the change end to end before the second checkpoint, and what happens to a finished tracker. See the full reference.