# Multi-agent code review: prompt pack

A code review run by a panel of narrow AI agents instead of one generalist. An orchestrator
resolves what to review, runs your existing checks, sends the change to several single-purpose
"lens" agents in parallel, has a separate verifier try to disprove every finding, then ranks what
survives into one report with a SHIP / SHIP WITH FIXES / DO NOT SHIP verdict. An optional fix loop
applies the confirmed findings one at a time and re-reviews the fixes.

Free to copy, adapt and share. No attribution needed. Provided as is, with no warranty of any kind.

## Why a panel

- Recall: one agent asked to "review this" skims everything. A lens asked one question
  ("what happens when this fails halfway?") goes deep on it.
- Precision: lenses over-report. Nothing reaches you unless a verifier that did not write the
  finding tried to refute it and could not.

## Files

| File | Role | Status |
|---|---|---|
| `orchestrator.md` | The skill / command you run. Never reviews code itself | required |
| `finding-format.md` | The one output format every lens and the verifier share | required |
| `lens-correctness.md` | Bug hunt, edge inputs, intent check | required |
| `lens-security.md` | What an attacker could actually use | required |
| `lens-tests.md` | Would a test fail if this change broke? | required |
| `lens-architecture.md` | Contracts, boundaries, cost of change | required |
| `lens-resilience.md` | Partial failure, retries, races, timeouts, growth | required |
| `lens-rules.md` | Mechanical compliance with your written rules | required |
| `verifier.md` | Tries to refute each finding; CONFIRMED / PLAUSIBLE / REFUTED | required |
| `review-profile.md` | Per-project calibration file (accepted risks, hot paths) | recommended |
| `pack-template.md` | Template for a stack "pack" of known traps | recommended |
| `lens-history.md` | Does this change forget something the project already learned? | optional |
| `fixer.md` | Applies exactly one confirmed finding (the `--fix` loop) | optional |
| `lens-performance.md` | Hot paths, N+1, payload size, render cost | optional |
| `lens-accessibility.md` | Keyboard, screen reader, contrast, motion | optional |
| `lens-dependencies.md` | New or changed packages, licenses, supply chain | optional |
| `lens-data-migrations.md` | Schema and data changes, rollback, backfill | optional |
| `lens-api-compat.md` | Breaking changes for clients you do not control | optional |
| `lens-privacy-observability.md` | Personal data in logs, and whether failures are visible | optional |
| `lens-docs.md` | Docs, comments and examples the change made false | optional |

## Install (Claude Code)

```
.claude/
  skills/multi-agent-review/
    SKILL.md            <- orchestrator.md
    finding-format.md
    packs/              <- your stack packs (from pack-template.md)
  agents/
    review-correctness.md   review-resilience.md   review-architecture.md
    review-security.md      review-tests.md        review-rules.md
    review-history.md       review-verifier.md     review-fixer.md
    review-performance.md   (and any other optional lens you want)
.review/profile.md       <- review-profile.md, filled in for this project (optional)
```

- Rename each `lens-*.md` to the agent name in its front matter (`review-correctness.md` and so
  on). Put them in `~/.claude/` instead of the project to use them in every repository.
- Keep the front matter block at the top of every file when you rename or move it. `SKILL.md`
  needs `name` and `description` (orchestrator.md already has both), and so does every agent file.
  Lose them and the skill or agent stops loading.
- The front matter also holds a `metadata:` block (author, source, version, updated, terms). It is credit
  and version information only: Claude Code does not act on it, it is not part of the prompt, and
  the prompts behave the same with or without it. Compare `version` and `updated` with the source
  page to see whether your copy is current.
- Run `/multi-agent-review` (or `/multi-agent-review --pr 123`, `--quick`, `--deep`, `--fix`).

**Run `--fix` on a clean branch.** The fixer edits files. Commit or stash your own work first,
then review the diff the fix loop leaves and commit it yourself.

## Other tools

Nothing here depends on one vendor. Any agent tool that can (1) run sub-agents in parallel with
their own instructions, (2) restrict a sub-agent to read-only tools, and (3) let the main agent
read their results can run this. Map:

- the orchestrator -> your tool's main prompt, command or workflow file
- each lens and the verifier -> a sub-agent / assistant / task definition
- the front matter `model:` -> your tool's model setting (strongest model for correctness,
  security, architecture, resilience and the verifier; a faster one is fine for rules and history)
- `disallowedTools` -> whatever your tool uses to make an agent read-only

## Cost

A full panel is several agents, each reading the change and the files around it, so it costs
several times a single review. Use `--quick` (one combined agent, no verifier) for small or
low-risk changes, the full panel before merging anything that matters, and `--deep` before a
release or on code where a bug is expensive.

---

Author: RJ Lindelof (https://rjl.dev/). Source: https://techdebt.guru/multi-agent-code-review/. Version 1.0, updated 2026-12-05. (c) 2026 RJ Lindelof.
