AGENT SKILL

review

暂无简介

License 许可
Apache-2.0
最近更新
2026-11-15
Stars
★ 3
Forks
0

03 SKILL.md 正文

Review — the reviewing craft: adversarial, confidence-filtered, honest

The kit's own code-review skill: how to review a change well. The Reviewer seat's craft (the security-reviewer applies the same craft through a security lens). Replaces (does not depend on) superpowers requesting-code-review. The requesting/dispatch side (convening a reviewer) is the Orchestrator's job, not this skill.

<!-- The frontmatter and discipline headings below are conformance-load-bearing: conformance/orchestrator-loop-wired.sh greps this file for kit-distinctive markers (name: review, ## When to use, Confidence, adversarial, builder, NEEDS-FIXES). conformance/doc-markers.sh validation-terminal-state additionally greps for the third terminal state (FAITHFUL-FAILURE) + its cross-surface markers. Edits that drop or rename them can turn the skill-spine lock RED. -->

When to use

After each task in subagent-driven development, after a feature, and always before merge to main. Review early, review often — catching an issue early beats debugging a cascade later. XS/S ordinary work does not owe a design doc, a plan file or a review record: the design note and task brief ride the PR body, one reviewer, security once on the built diff, nits accepted in the PR rather than a new round (on a tracker backend review-lane cannot read the size, so every non-docs ordinary PR owes a plan and a record until a later change reads it from the tracker); M, Sensitive and Control-plane owe them as before, except the small control-plane lane: a control-plane slice under about 50 non-test lines that adds no mechanism may commit its own new short design file (the design note and the twelve-row lens table) as its design GO's only basis, and skip the long-form design and the independent lens seat; the plan file, the review record and the security pass are still owed. Say in the PR that the slice uses this lane.

The craft (the proven spine)

  1. Review a crafted diff, not the author's history. Look at the change (the diff + the requirements it claims to meet) with fresh eyes — you did not write it.
  2. Judge against the rubric: correctness + unhandled edge/error cases; DEVELOPMENT-STANDARDS §2 (security) and §5 (code quality); the §14 CI gates; tests that cover the change and assert behaviour, not implementation.
  3. Group findings by severity — Critical / Important / Minor — each with file:line and a concrete fix.
  4. Emit one honest verdict — APPROVE or NEEDS-FIXES. Fix Critical/Important before proceeding; note Minor.

The kit's review disciplines (what makes this MORE than generic code review — apply to EVERY review)

  • Adversarially verify each finding before you report it. Try to refute it: does the bug actually reproduce, is the file:line real, would the fix matter? A finding you cannot substantiate is noise — drop it or downgrade it. This is the kit's non-vacuity law at the review level: a finding that cannot be made to fail is not a finding. Honest adversarial verification is the heart of the craft.
  • Confidence-based filtering — signal over nitpicks. Report only what you are confident matters. A review buried in style Minors hides the one Critical. Bikeshedding is a failure mode, not thoroughness.
  • The builder is never the reviewer. Independence is the point — the builder never reviews-and-merges its own work (DEVELOPMENT-PROCESS §12). Two lenses review in parallel: the Reviewer (correctness/standards) and the security-reviewer (the §7 security gate).
  • Review behaviour, scoped to the diff. Assert behaviour, not implementation detail; do not expand scope beyond the change; do not re-litigate decisions the plan already made — raise them as findings and let the owner adjudicate.
  • Check one load-bearing negative per control, not one per leg. For each control the change promises (a row of the design's "Design-promised controls" table, carried into the review record, or, for a slice with none, each behaviour the PR claims), confirm one test that fails if the control is removed. The reviewer seat does not ask for a negative on every leg or for mutants per test; the security seat keeps asking for coverage of every input, and security controls (the guard, secret-scan, authN/Z, fail-closed boundaries, credential handling, input validation / injection escaping, PII redaction, AI runtime guards (prompt-injection, output validation)) keep one negative per attack shape or input class (when unsure whether a control is a security control, it is one; the security seat decides, not the builder); conformance/review-lane.sh rule 6 already grades one test per design-promised control (skills/tdd).
  • Grade the operator-facing prose of a gate with the gate. Check-run text, refusal messages, and recording instructions are part of the mechanism — a gate whose prose instructs a retired workaround fails on its first live subject.
  • Fix the class, not the instance. Every fix has twins: the sibling function, the sibling profile, the sibling selftest, the sibling doc. Ask of each fix "which one is this fix's twin?" — then name the twin and grade it, or state why there is none. A fix applied at one site while its twins keep the defect is how a closed row reopens under a new number (this is why the sweep found the same broken SBOM command in three profiles when the row named two).
  • Propagate, or carry. Every 'stated in <shipped doc>' or 'owed after the merge' line in a design or a record is either present in that shipped doc at merge, or carried as a card with an owner and a by-when. A promise that lives only in the record is the defect a meta-control panel found in every material finding.
  • Honest verdict — never rubber-stamp. NEEDS-FIXES on any real Critical or Important. An APPROVE means you would stake the merge on it.

Rounds and the security seat

  • One review round plus one security pass is the norm. A security re-review is owed when the fix touches the flagged control, any path on the security-control list (guard, auth, secrets, CI security gates), or adds untrusted input or a new permission; when unsure, re-review. The security seat decides, not the builder. Only the reviewer's NEEDS-FIXES rounds count; at reviewer round N (default 3, a project setting) the conductor notifies the owner and continues. That notification is conduct, not enforced, and no per-slice token or time stop binds the conductor path today.
  • A separate security seat on the built diff is the default (conduct, not enforced). A combined review-and-security seat is allowed only for a change a script derives as non-security (the derived change class plus a closed list of security-control paths: the guard, auth, secrets, CI security gates), never self-asserted by the builder, the reviewer or the conductor. That script has not landed, so the combined seat is unavailable until it does.
  • The security verdict lives in the review record's ## Security review section, not in the PR body. Waivers are counted in the slice retro, from those sections. The gap, stated honestly: an XS/S ordinary PR owes no review record, so its security pass is unrecorded and its waivers are uncounted.
  • Records stay light (conduct, not enforced). A fix round owes at most one confirm row: the reviewer's re-read is that round's Rounds row, with no separate confirm-glance rows. A record that nears review-lane's size cap is trimmed, not overflowed: cut prose, never a graded row, a finding's statement, a relayed GO or a high-risk acknowledgment, and write no companion file; if what must stay still exceeds the cap, escalate to the owner. A guard refusal goes in a record only when it changed the work (agents/orchestrator.agent.md, C11).

Push back

If a finding is wrong, the author pushes back with technical reasoning (code or tests that prove it works) and the reviewer adjudicates. A finding that contradicts what the plan mandates is the owner's call — surface it; do not silently drop or enforce it.

Terminal state

A file, not only a message. The review record docs/reviews/<date>-<row-slug>.md (from templates/REVIEW-RECORD-TEMPLATE.md), appended per round — one Rounds row per round naming the commit reviewed, the seat (its cell opens with the role reviewer; the security line names seat security, both roles from agents/*.agent.md), the verdict and the finding count — plus the severity-grouped findings list (each file:line + concrete fix) and one verdict — APPROVE or NEEDS-FIXES — returned to the Orchestrator for routing. For a Sensitive, Control-plane or M-or-larger (or size-unknown) change the file is owed and graded (an XS/S ordinary PR owes none — the forge Approve is then the only graded evidence of review): conformance/review-lane.sh refuses a record whose Builder equals its Reviewer, whose rounds cite commits outside the PR, whose last round is not APPROVE (an open NEEDS-FIXES round; a non-docs or out-of-allowlist commit after the approving round only WARNs, since the forge's dismiss_stale_reviews re-gates it), whose findings lack a disposition in the grammar (fixed <sha> · accepted — <reason> · waived — WAIVER-<id>) — and a fixed <sha> must name a commit inside this PR, or it is refused (RL-FIX-OUTSIDE): a fix outside the PR is a fix this PR does not carry — whose design-promised controls do not resolve to an executable path::test-name, or which carries no security-review verdict. The record alone is self-attested — what makes it evidence is a non-author Approve on the graded head. The approver types nothing, and it is branch protection, not review-lane, that enforces it: dismiss_stale_reviews means an approval carried across a fix push does not count, and require_last_push_approval means the pusher cannot approve their own push. The reviewer reports; it never merges. Prose never says 'one round' when the Rounds table holds two or more NEEDS-FIXES rows. Before the human Go/No-Go, if the change carries a taste-surface, ensure the increment was demonstrated for the human's taste judgment (skills/demonstrate) and its verdict recorded — correctness review alone does not answer whether it is good. The reviewer's verdict is a basis: input to the human GO; it never ratifies — builder ≠ ratifier (peer to builder ≠ reviewer), and actuation follows approve→execute→log (execute + log + verify shipped == approved).

Validation-task terminal state — FAITHFUL-FAILURE (the third verdict)

A third terminal state, available ONLY when the task under review declares its class in its Task Context Contract (§12). That declared class must be validation / field-test. For an ordinary implementation task the APPROVE / NEEDS-FIXES binary above is unchanged — FAITHFUL-FAILURE is opt-in and never the default.

  • FAITHFUL-FAILURE — the validation task was executed faithfully (methodology correct, cold-integrity held) AND it surfaced a real defect in the subject-under-test. The test succeeded; the subject failed — this is NOT an implementation failure and NOT NEEDS-FIXES.
    • Requires: the discovered defect(s) are routed to the originating backlog — logged out-of-band, not lost.
    • Forbids (cold-integrity): the reviewer must NOT prescribe or perform a repair of the subject-under-test inside the vehicle — a repair in the vehicle contaminates the evidence and voids the test. Route it out; never fix it in place.
    • faithful methodology is the precondition — a validation task run unfaithfully, or one that repaired what it was exercising, is NEEDS-FIXES as usual, so the verdict cannot be used to dodge a real fix.

Honest ceiling: this doctrine is documented and locked for coherence; whether a live reviewer applies it correctly is un-gateable (as with skills/using-skills' auto-load convention).

04 同仓库更多 Skills

SeaBrad72
SeaBrad72/sparkwright

inception-from-code

Use when adopting the kit into an EXISTING repository (brownfield), to draft the Inception artifacts from the code instead of from blank templates. The agent reads the repository and writes five drafts, only under docs/inception-draft/, each tagged by how each fact is known; a person reviews them and moves what is right into place. Agents propose, humans ratify.

★ 3
SeaBrad72
SeaBrad72/sparkwright

worktrees

Use BEFORE fanning out parallel Engineers or starting isolated feature work — the kit's own isolation skill (replaces, does not depend on, superpowers using-git-worktrees). The isolation craft, wired to the Orchestrator seat — detect-existing-first, native tools first, the kit's disjoint-set parallel-safety rule, and conflict-safe integration.

★ 3
SeaBrad72
SeaBrad72/sparkwright

verification

暂无简介

★ 3
SeaBrad72
SeaBrad72/sparkwright

using-skills

Use at the START of any task, before any response or action — the kit's own discovery keystone (replaces, does not depend on, superpowers using-superpowers). How the kit's skills are found and invoked (invoke by reading), the discipline of checking for a relevant skill before acting, instruction priority, and the index of the kit's own spine skills.

★ 3
SeaBrad72
SeaBrad72/sparkwright

tdd

Use when implementing any feature, bug fix, refactor, or behaviour change — BEFORE writing production code. The kit's own test-driven-development skill (replaces, does not depend on, superpowers test-driven-development). Red-green-refactor framed as the kit's non-vacuity law, plus coverage, testing-pyramid, and AI-eval disciplines.

★ 3
SeaBrad72
SeaBrad72/sparkwright

plan

Use AFTER a design is owner-approved and BEFORE any build — turning an approved design/spec into an INVEST-sliced, TDD, build-ready implementation plan. The kit's own planning skill (replaces, does not depend on, superpowers writing-plans). Produces bite-sized tasks an engineer with zero codebase context can execute.

★ 3