Builder Reviewer Loop

Passes code between a builder and an independent reviewer subagent until the review has no blocking findings and tests pass.

WorkflowengineeringMIT1 source files

Before you use this component

This is a third-party source bundle, not an installation into your account. UI Discovery has checked the available redistribution license evidence; runtime behavior has not been tested. Review all files, use a disposable project first, and do not enable scripts or hooks until you understand their permissions.

Some integrations require separately installed software, API keys or paid services. Credentials and subscriptions are not included. These are Claude Code resources; other clients may require adaptation.

Extract the ZIP into a temporary folder, inspect its entry file and supporting resources, then follow the original instructions. Do not overwrite an existing project configuration blindly. Keep the bundled license and attribution notices.

Source publisher
Claude Code Templates
Creator supplied by source
Not listed in source
Pinned source version
a344359459263d73d8948651c789244093c02e4e
License evidence
LICENSE

Source preview

cli-tool/components/loops/engineering/builder-reviewer-loop.md

---
name: builder-reviewer-loop
description: Passes code between a builder and an independent reviewer subagent until the review has no blocking findings and tests pass.
category: engineering
interval: 15m
stop-condition: The reviewer reports zero blocking findings and the full test suite passes.
components: [agent:expert-advisors/architect-review, agent:development-team/test-runner, command:git-workflow/pr-review]
tags: [code-review, subagents, quality, loop]
---

# Builder–Reviewer Loop

> **Loop Engineering** — separate the *builder* from the *reviewer* so the agent doesn't grade its own work. Code bounces between them until it genuinely passes.

## 🎯 Goal
Implement a change, then have an **independent reviewer subagent** critique it; iterate on the findings until the review is clean and tests are green.

## ⏱️ Schedule
Suggested interval: `15m` (or run until done on a single feature).

## ▶️ Run it
```
/loop 15m "Implement the next slice of the feature. Then hand it to an independent reviewer subagent for an adversarial review. Address every blocking finding and re-run tests. Continue until the reviewer has no blocking findings and the suite passes."
```

## 🔁 Iteration steps
1. **Build** — implement the next slice of work.
2. **Review** — the `architect-review` agent inspects the diff for correctness, design and risk.
3. **Plan** — collect blocking findings into a fix list.
4. **Act** — address each finding; re-run the suite with `test-runner`.
5. **Observe** — re-review with `/pr-review`; if blocking findings remain, loop again.

## 🛑 Stopping condition
Reviewer reports zero blocking findings **and** all tests pass.

## 🧩 Referenced components
- `agent:expert-advisors/architect-review` — the independent reviewer (no self-grading).
- `agent:development-team/test-runner` — runs the suite each pass.
- `command:git-workflow/pr-review` — structured review checklist.

## 💡 Example
The builder ships a new caching layer; the reviewer flags a race condition and a missing eviction test. The loop fixes both, re-reviews, and exits clean.

Preview capped at 60,000 characters. Download the bundle for every original file and notice.

Read the redistribution license
MIT License

Copyright (c) 2025 Daniel (San) Ávila

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.

Bundle SHA-256: f3e21c5a14544a52ae79cf7f6ebaf6d3226d0797504884a105a2a0c04b15a5e1. Files are served as downloads and are never executed by this page.