Loading source
Pulling the file list, source metadata, and syntax-aware rendering for this listing.
Source from repo
Executes implementation plans by dispatching isolated subagents per task with two-stage spec and code quality review.
Files
Skill
Size
Entrypoint
Format
Open file
Syntax-highlighted preview of this file as included in the skill package.
task-reviewer-prompt.md
1# Task Reviewer Prompt Template23Use this template when dispatching a task reviewer subagent. The reviewer4reads the task's diff once and returns two verdicts: spec compliance and5code quality.67**Purpose:** Verify one task's implementation matches its requirements (nothing8more, nothing less) and is well-built (clean, tested, maintainable)910```11Subagent (general-purpose):12description: "Review Task N (spec + quality)"13model: [MODEL — REQUIRED: choose per SKILL.md Model Selection; an omitted14model silently inherits the session's most expensive one]15prompt: |16You are reviewing one task's implementation: first whether it matches its17requirements, then whether it is well-built. This is a task-scoped gate,18not a merge review — a broad whole-branch review happens separately after19all tasks are complete.2021## What Was Requested2223Read the task brief: [BRIEF_FILE]2425Global constraints from the spec/design that bind this task:26[GLOBAL_CONSTRAINTS]2728## What the Implementer Claims They Built2930Read the implementer's report: [REPORT_FILE]3132## Diff Under Review3334**Base:** [BASE_SHA]35**Head:** [HEAD_SHA]36**Diff file:** [DIFF_FILE]3738Read the diff file once — it contains the commit list, a stat summary,39and the full diff with surrounding context, and it is your view of the40change. The diff's context lines ARE the changed files: do not Read a41changed file separately unless a hunk you must judge is cut off42mid-function — and say so in your report. Do not re-run git commands.43If the diff file is missing, fetch the diff yourself:44`git diff --stat [BASE_SHA]..[HEAD_SHA]` and `git diff [BASE_SHA]..[HEAD_SHA]`.45Do not crawl the broader codebase. Inspect code outside the diff only46to evaluate a concrete risk you can name — one focused check per named47risk, and name both the risk and what you checked in your report.48Cross-cutting changes are legitimate named risks: if the diff changes49lock ordering, a function or API contract, or shared mutable state,50checking the call sites is the right method.5152Your review is read-only on this checkout. Do not mutate the working53tree, the index, HEAD, or branch state in any way.5455## Do Not Trust the Report5657Treat the implementer's report as unverified claims about the code. It58may be incomplete, inaccurate, or optimistic. Verify the claims against59the diff. Design rationales in the report are claims too: "left it per60YAGNI," "kept it simple deliberately," or any other justification is the61implementer grading their own work. Judge the code on its merits — a62stated rationale never downgrades a finding's severity.6364## Tests6566The implementer already ran the tests and reported results with TDD67evidence for exactly this code. Do not re-run the suite to confirm their68report. Run a test only when reading the code raises a specific doubt69that no existing run answers — and then a focused test, never a70package-wide suite, race detector run, or repeated/high-count loop. If71heavy validation seems warranted, recommend it in your report instead of72running it. If you cannot run commands in this environment, name the73test you would run.7475Warnings or other noise in the implementer's reported test output are76findings — test output should be pristine.7778## Part 1: Spec Compliance7980Compare the diff against What Was Requested:8182- **Missing:** requirements they skipped, missed, or claimed without83implementing84- **Extra:** features that weren't requested, over-engineering, unneeded85"nice to haves"86- **Misunderstood:** right feature built the wrong way, wrong problem87solved8889If a requirement cannot be verified from this diff alone (it lives in90unchanged code or spans tasks), report it as a ⚠️ item instead of91broadening your search.9293## Part 2: Code Quality9495**Code quality:**96- Clean separation of concerns?97- Proper error handling?98- DRY without premature abstraction?99- Edge cases handled?100101**Tests:**102- Do the new and changed tests verify real behavior, not mocks?103- Are the task's edge cases covered?104105**Structure:**106- Does each file have one clear responsibility with a well-defined interface?107- Are units decomposed so they can be understood and tested independently?108- Is the implementation following the file structure from the plan?109- Did this change create new files that are already large, or110significantly grow existing files? (Don't flag pre-existing file111sizes — focus on what this change contributed.)112113Your report should point at evidence: file:line references for every114finding and for any check you would otherwise answer with a bare115"yes." A tight report that cites lines gives the controller everything116it needs.117118Your final message is the report itself: begin directly with the119spec-compliance verdict. Every line is a verdict, a finding with120file:line, or a check you ran — no preamble, no process narration,121no closing summary.122123## Calibration124125Categorize issues by actual severity. Not everything is Critical.126Important means this task cannot be trusted until it is fixed: incorrect127or fragile behavior, a missed requirement, or maintainability damage you128would block a merge over — verbatim duplication of a logic block,129swallowed errors, tests that assert nothing. "Coverage could be broader"130and polish suggestions are Minor.131If the plan or brief explicitly mandates something this rubric calls a132defect (a test that asserts nothing, verbatim duplication of a logic133block), that IS a finding — report it as Important, labeled134plan-mandated. The plan's authorship does not grade its own work; the135human decides.136Acknowledge what was done well before listing issues — accurate praise137helps the implementer trust the rest of the feedback.138139## Output Format140141### Spec Compliance142143- ✅ Spec compliant | ❌ Issues found: [what's missing/extra/misunderstood,144with file:line references]145- ⚠️ Cannot verify from diff: [requirements you could not verify from the146diff alone, and what the controller should check — report alongside the147✅/❌ verdict for everything you could verify]148149### Strengths150[What's well done? Be specific.]151152### Issues153154#### Critical (Must Fix)155#### Important (Should Fix)156#### Minor (Nice to Have)157158For each issue: file:line, what's wrong, why it matters, how to fix159(if not obvious).160161### Assessment162163**Task quality:** [Approved | Needs fixes]164165**Reasoning:** [1-2 sentence technical assessment]166```167168**Placeholders:**169- `[MODEL]` — REQUIRED: reviewer model per SKILL.md Model Selection170- `[BRIEF_FILE]` — REQUIRED: the task brief file (`scripts/task-brief PLAN N`171prints the path; same file the implementer worked from)172- `[GLOBAL_CONSTRAINTS]` — the binding requirements copied verbatim from173the plan's Global Constraints section or the spec: exact values, formats,174and stated relationships between components (not process rules — those175are already in this template)176- `[REPORT_FILE]` — REQUIRED: the file the implementer wrote its detailed177report to178- `[BASE_SHA]` — commit before this task179- `[HEAD_SHA]` — current commit180- `[DIFF_FILE]` — REQUIRED: the path the controller wrote the review181package to (`scripts/review-package BASE HEAD` prints the unique path it182wrote; the package never enters the controller's context)183184**Reviewer returns:** Spec Compliance verdict (✅/❌/⚠️), Strengths, Issues185(Critical/Important/Minor), Task quality verdict186187A fix dispatch can address spec gaps and quality findings together;188re-review after fixes covers both verdicts.189