9thlevelsoftware/legion/review-loop
- community
Checking that the SKILL.md file is still in the repository.
Dev-QA loop engine with structured feedback, fix routing, and user escalation for /legion:review
Install
npx vskill@latest install 9thlevelsoftware/legion/review-loopSKILL.md
Review Loop
Engine for /legion:review. Takes the output of a completed /legion:build phase and drives it through a structured dev-QA cycle: personality-injected review agents evaluate artifacts, findings are triaged by severity, fix agents resolve issues, and the cycle repeats up to the configured maximum (settings.review.max_cycles, default 3). A phase is never marked complete by exhaustion — only by reviewer approval.
Section 1: Review Principles
These rules govern all review decisions. Do not deviate from them.
MANDATORY: Follow the active CLI adapter's Execution Protocol.Before spawning any review or fix agents, load the active adapter (see workflow-common CLI Detection Protocol).The adapter defines how agents are spawned, coordinated, and cleaned up.If adapter.parallel_execution is true AND adapter.structured_messaging is true (e.g., Claude Code):Use the adapter's full coordination lifecycle for the review Team.On Claude Code specifically:CLAUDE_CODE_EXPERIMENTAL_AGENT_TEAMSmust be enabled.If adapter.parallel_execution is false (e.g., Codex CLI, Aider):Execute review and fix agents sequentially. Collect results via adapter.collect_results.Always follow the adapter protocol. Do not hardcode CLI-specific tool calls.
Section 1.1: Adapter Resolution Protocol (precondition for all sections)
Before entering Section 2, review-loop MUST fully resolve the active adapter.
- Run workflow-common CLI Detection Protocol to identify the active adapter.
- Load the adapter completely (not just the keys named above).
- Verify required adapter keys are present. Missing required keys → FAIL FAST with
error: "Adapter {adapter_name} is missing required key(s): {list}. Review cannot proceed." Do NOT silently default missing keys — that masks adapter drift.
Required keys (all must be present):
parallel_execution(boolean)structured_messaging(boolean)spawn_agent_personality(method spec)collect_results(method spec)model_execution(string — model identifier)commit_signature(string)
Optional keys (defaults applied silently if absent):
shutdown_agents— default: no-op (skip graceful termination)cleanup_coordination— default: no-opcoordinate_parallel— default: no-op ifparallel_execution == false; required ifparallel_execution == truetimeout_ms— default: 600000 (10 min)
- Adapter conformance is also validated by the lint_commands declared in the adapter.
If available, run those as part of CI before review — catches drift pre-runtime.
- Review the output, not the plan — review agents evaluate files created/modified during
/legion:build, not the plan documents themselves. The plan is the specification; the output is what gets reviewed. - Full personality injection — each review agent receives the ENTIRE contents of its assigned
.mdfile as system instructions. No summaries, no excerpts, no paraphrasing. - Structured feedback only — review agents must use the exact Finding format defined in Section 3. Vague assessments like "looks good" or letter grades are rejected.
- Max cycle count comes from settings — use
settings.review.max_cycles(default: 3). The loop is: review → collect findings → fix → re-review. If blockers remain after that many full cycles, escalate to the user (Section 8). - Adapter model for all agents — review agents and fix agents both use
adapter.model_execution. This matches the Cost Profile Convention fromworkflow-common.md. - Approval required, not exhaustion — a phase is NOT marked complete when cycles run out. It is marked complete only when review agents give a PASS verdict with no remaining BLOCKERs or WARNINGs.
- Skeptical by default — "no issues found" on a first review is a yellow flag. Review agents should expect to find at least something on an initial pass. If a reviewer returns PASS on cycle 1, their reasoning must explain what was checked and why confidence is warranted.
- Confidence-gated reporting — every finding must include a confidence level: HIGH (80-100%), MEDIUM (50-79%), or LOW (<50%). Only HIGH-confidence findings appear in the default report. MEDIUM findings are collected but only surfaced if the user explicitly requests the full report. LOW findings are discarded — if you are not at least 50% confident, it is not a finding.
- Do not auto-proceed after escalation — if the configured cycle budget is exhausted, stop and wait for user decision. Do NOT mark the phase complete or advance to the next phase without explicit user confirmation.
Section 1.2: Settings Input
Before starting cycle 1, resolve review limits from settings.json:
- Try Read
settings.json - If present, use
review.max_cyclesas{max_cycles} - If missing or invalid, set
{max_cycles} = 3 - Use
{max_cycles}for every loop boundary, status message, and escalation check
Section 2: Review Agent Selection
How to choose the right review agents for a phase before spawning.
Reviewer Confirmation Display
Before spawning review agents, show this to the user and wait for confirmation:
Section 3: Review Prompt Construction
How to build the prompt that each review agent receives.
Structured Review Request
When the review-loop is invoked after a build phase, it auto-constructs a structured review request from the phase's SUMMARY.md files. This gives reviewers complete context without manual assembly.
Auto-population sources:
- Scope: Git diff range from SUMMARY.md "Files Modified" sections
- Requirements: REQ-* references from the plan's YAML frontmatter
- Implementation summary: "Completed Tasks" sections from all SUMMARY.md files in the phase
- Known risks: "Open Questions" or escalation blocks from SUMMARY.md handoff context
- Verification results: Output of
verification_commandsfrom the plan (captured during build)
Injected into reviewer prompt as:
~~~
Review Context (auto-populated)
- Scope: {file list from SUMMARY.md Files Modified sections}
- Requirements addressed: {REQ-* list from plan frontmatter}
- What was built: {merged Completed Tasks from SUMMARY.md files}
- Known risks: {Open Questions and unresolved escalations}
- Verification: {verification command outputs, PASS/FAIL for each}
~~~
If SUMMARY.md files are not available (e.g., manual review without a prior build phase), skip auto-population and rely on the reviewer's own file discovery.
This is the start of the file. Read the full SKILL.md on GitHub.
Security
- Security scanPassed, 93 of 100Pattern checks on the skill's files.
- Model reviewNot runA model review is scheduled for the next rescan.
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryCheckingskills/review-loop/SKILL.md
Popularity
- Repository stars
- 62
- Repository forks
- 7
- 7-day trend score
- 21
Stars and forks are for the whole GitHub repository, not this skill alone. Not refreshed yet.
Works with
Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.
- Claude Code
- Cursor
- GitHub Copilot
- Windsurf
- Codex
- Gemini CLI
- Cline
- Amp
- Roo Code
- Goose
- Continue
- Kilo Code
- Junie
- Trae
- OpenHands
- Qwen Code
- AI Agent
- Tabnine Chat
- Sourcegraph Cody
- Amazon Q
- Firebase Genkit
- Sweep
- Devin
- Phind
- Mentat
- Claude Desktop
- Aider
- GPT Pilot
- Plandex
- bolt.new
- v0
- Replit Agent
- Anse
- TypingMind
- BetterChatGPT
- LibreChat
- Warp AI
- Pieces
- Fig AI
Embed badge
[](https://verified-skill.com/skills/9thlevelsoftware/legion/review-loop)