sw-review
Skill164 starsChanged 13 months agoMITView on GitHub
Adversarial fresh-context review and risk check of an increment before it ships; every finding cites path:line and is re-verified. Use for "review", "qa", "quality check", "critique this".
In this repository12 other files it gives its agents.
- AGENTS.mdAGENTS.md
- CLAUDE.mdCLAUDE.md
- sw-autoSkill
- sw-brainstormSkill
- sw-doneSkill
- sw-doSkill
- sw-handoffSkill
- sw-incrementSkill
- sw-jevSkill
- sw-projectSkill
- sw-syncSkill
- sw-teamSkill
The file
We split this skill into the rules it gives an agent
1 rule. About 0 are common, 0 are distinctive, and 1 is very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈0
Distinctive · estimate
This author's own choices. Worth a look.
1
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 29
Scope: Read spec.md (ACs, Approach, the tasks' Files) and review that diff, not the repository: git diff $(git merge-base HEAD …
≈ “Common” is an estimate: at least 1 in 5 of the 213,897 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
sw-review: adversarial review with citations
A fresh reader hunts for real failures in the increment's diff, cites path:line for
each, re-checks every claim, and writes .specweave/increments/<id>/reports/review.md.
This is also the quality check: its verdict says whether the increment is ready.
Non-negotiables
- Fresh context. The session that wrote the code never approves it. Use a new session, or a subagent if your tool supports them. If you wrote this code here and cannot get a fresh context, say so in the report.
- Every finding cites
path:lineand a concrete failure: input or state leads to wrong output, a crash, a hang, data loss or a leak. "Consider refactoring" is not one. - Re-verify. Re-open the lines and, where a test can show it, run one. Drop what
does not survive; mark what you could not prove as
plausible. - Severity is critical, high, medium or low. Critical and high block the close.
- At most 5 nits, in one line at the end.
Steps
- Evidence first.
specweave verify(or its existingreports/verify.md): red tests, lint or build are findings before any reading. - Scope. Read spec.md (ACs, Approach, the tasks'
Files) and review that diff, not the repository:git diff $(git merge-base HEAD origin/HEAD)...HEAD -- <Files>. - Pass, in this order: correctness (logic, error paths, races, off-by-one) →
security (injection, path traversal, secrets, unsafe exec) → spec compliance (ACs
claimed but not implemented, tests that assert nothing or mock the subject) →
portability (bash-only commands,
\paths, BOMs,>>in PowerShell).--full: run the three lenses correctness, security and spec compliance separately (in parallel if your tool has subagents) and merge, dropping duplicates. - Report in the shape below. Optional machine form,
reports/review.json:{"ok":false,"findings":[{"severity":"high","file":"src/a.ts","line":88,"summary":"..."}]}. - Hand back. Each critical or high finding becomes a task in spec.md
(
### T-09 Fix empty evidence+- AC: AC-02 | Files: ... | Test: ...) for sw-do, or is fixed and re-tested now. Then verify again and close with sw-done.
reports/review.md
# Review: 0042 Ledger fold
Verdict: fix first · risk: high · 6 files · 2 findings (1 critical, 1 high)
Reviewer context: new session
## [critical] src/core/tasks/ledger.ts:142 lost claim under equal timestamps
Two agents claim T-01 in the same second; the fold sorts only by `at`, so both read
themselves as owner. Fix: break ties by `by`, then file order.
Nits: naming in ledger.ts:31.Verdict is fix first while any critical or high finding survives, else ship.
Manual path (no CLI)
Nothing changes: git diff and the project's own test runner are the whole toolchain,
and you write reports/review.md yourself.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

