spec-review
Skill3 starsChanged 10 days agoMITView on GitHub
Structured code review against review_rules.md and coding-rules.md.
47 other projects use a version of this.
Adopted by
Most recently taken up by
- utopia-rise/fmod-gdextensiontheir own version, first seen Nov 9, 2026
- crsmithdev/alephtheir own version, first seen Nov 8, 2026
- maxatwork/skillstheir own version, first seen Nov 8, 2026
- salasebas/skillstheir own version, first seen Nov 8, 2026
- komluk/scaffoldingtheir own version, first seen Nov 7, 2026
- rioffe/specchecktheir own version, first seen Nov 6, 2026
Used with
Projects with it also use get-pr-reviews, push-everything and 10 more.
Other files people use alongside this one.
Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
saffron-healthSkillget-pr-reviews
Get nicely formatted output of the last review comments on a PR. Used internally by other skills.
Also in 3 projects that use this
saffron-healthSkillpush-everything
Stage ALL changes in the repository (not just session changes), commit, and push. Use when you need to commit all pending changes.
Also in 3 projects that use this
NVIDIASkillgenerate-spec
Produce a feature specification covering API changes, backward compatibility, cross-language impact, performance, and a file-level change plan. Use when designing a new feature, planning a significant change, or the user asks to spec something out.
Also in 3 projects that use this
telefrekSkillspec-init
Bootstrap the spec corpus for this project
Also in 3 projects that use this
AWSSkillimplement-spec
Implement the result of /to-spec and /to-tickets in code.
Also in 8 projects that use this
ArvorCoSkillspecify
Create feature specification from natural language description. Use when starting a new feature or creating a spec. Triggers on: create spec, specify feature, new feature spec.
Also in 3 projects that use this
- +2 more from saffron-health
Other versions47 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 47
- microsoft/winappCli★ 1.4ksame name
- utopia-rise/godot-kotlin-jvm★ 995same name
- utopia-rise/fmod-gdextension★ 954same name
- cashew-labs/libretto★ 898same name
- saffron-health/libretto★ 883same name
- liza-mas/liza★ 418same name
- HHU3637kr/skills★ 146same name
- saffron-health/opencode-gui★ 59same name
- agent-ix/quoin★ 20same name
- microsoft/WinAppVSCE★ 18same name
37 more not listed
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository24 other files it gives its agents.
- AGENTS.mdAGENTS.md
- agent-delegateSkill
- cmux-delegateSkill
- cmux-forkSkill
- cmux-second-opinionSkill
- handoverSkill
- harness-initSkill
- harness-loopSkill
- harness-planSkill
- ja-humanizerSkill
- magiSkill
- mcp-convertSkill
- skill-suggestSkill
- spec-codeSkill
- spec-evaluateSkill
- spec-generatorSkill
- spec-implementSkill
- spec-inspectSkill
- spec-orchestrateSkill
- spec-rules-initSkill
- spec-testSkill
- spec-to-issueSkill
- spec-workflow-initSkill
- spec-writingSkill
The file
We split this skill into the rules it gives an agent
7 rules. 0 are common, 3 are distinctive, and 4 are very specific to this project.
0
Common
Most of the 43 edited versions we read keep these.
3
Distinctive
This author's own choices. Worth a look.
4
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 67
If no rules files found, use minimal defaults: security (no secrets, no injection), correctness (no obvious bugs), and style (consistent …
- Distinctive: line 89
If diff is empty → stop with: "No changes to review." / "レビュー対象の変更がありません。"
- Very specific: line 108
Test rules → *.test.*, *.spec.* files
- Very specific: line 114
If --spec is provided:
- Very specific: line 115
Read design.md section referenced by the task
- Distinctive: line 143
If (2) cannot be stated, tag the earliest milestone that can be defended.
- Very specific: line 147
Do not add any further gating axis (no blocking: flag or similar).
“Common” is measured: kept by at least 6 in 10 of the 43 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
spec-review — Structured Code Review
Review code changes against project rules using a systematic rule × file matrix approach.
Language Rules
- Auto-detect input language → output in the same language
- Japanese input → Japanese output, use
references/review-guide.ja.md - English input → English output, use
references/review-guide.md - Explicit override takes priority
Options
| Option | Description |
--task {task-id} | Review changes for a specific task (auto-detect diff) |
--base-commit {sha} | Base commit for task-scoped diff (recommended with --task) |
--diff {file} | Review a specific diff file (standalone use) |
--spec {path} | Path to .specs/ directory (for design consistency check) |
--rules {path} | Path to review_rules.md (auto-search if omitted) |
--output {path} | Output path for review file (default: .specs/{feature}/review-{task-id}.md) |
Execution Flow
Step 0: Context Loading (Phase A / Phase B)
Same as spec-code §Step 0, but identify your role as reviewer.
Phase B applies when re-reviewing after a fix: load only the updated diff and
previous review findings. On a re-review, read only the unresolved findings,
the parts changed by the fixes, and the code that directly uses those parts —
do not re-scan the whole diff hunting for fresh ground. Do not re-raise
findings already recorded with fix_before: trial / required_check /
follow_up; the caller carries them forward. A new finding unrelated to
the fixes may be tagged implementation only for secret leak, data loss, a
bypass of a merge condition, or an infeasibility; any other new finding is
follow_up.
Step 1: Collect Rules
- Locate review_rules.md (search:
docs/development/→docs/→ find) - Locate coding-rules.md (same search order)
- Parse all rules into a structured list:
rule_list: [
{ id: "RR-001", severity: "Critical", description: "No SQL injection", category: "security" },
{ id: "CR-MUST-001", severity: "MUST", description: "Use strict TypeScript", category: "typescript" },
...
]If no rules files found, use minimal defaults: security (no secrets, no injection), correctness (no obvious bugs), and style (consistent formatting).
Step 2: Collect Changed Files
Diff acquisition based on context:
| Context | Diff Command |
--task {id} + --base-commit {sha} | git diff {sha}...HEAD |
--task {id} only | Auto-detect task start commit; if ambiguous, require --base-commit |
--diff {file} specified | Read the provided diff file directly |
| Standalone (no options) | git diff --cached first; if empty, git diff (working tree) |
| PR context | git diff {base}...HEAD |
Parse the diff to extract:
changed_files: [
{ path: "src/auth/service.ts", added_lines: [45-60, 102-110], removed_lines: [48-52] },
...
]If diff is empty → stop with: "No changes to review." / "レビュー対象の変更がありません。"
Step 3: Matrix Review (Rule × File)
This is the core review step. Do NOT skip or abbreviate.
for each rule in rule_list:
for each file in changed_files:
if rule.category is relevant to this file type:
read the changed lines in context
check if any added/modified line violates this rule
if violation found:
record: { rule.id, file.path, line_number, description, severity }Relevance matching:
- Security rules → all files
- TypeScript rules →
.ts,.tsxfiles - Test rules →
*.test.*,*.spec.*files - Style rules → all source files
- API rules → controller/route files
Step 4: Design Consistency Check
If --spec is provided:
- Read
design.mdsection referenced by the task - Compare implementation against design:
- Are the specified interfaces implemented?
- Does the data model match?
- Are the architecture decisions followed?
- Record any deviations as "Improvement" severity
Step 4.5: Tag Each Finding with fix_before
Severity (Critical / Improvement / Minor) is for human reading and
prioritization. The Gate is decided by a second axis, fix_before — the
milestone before which the defect must be fixed. Tag every Critical and
Improvement finding with one of, in milestone order:
- implementation — must be fixed before this work lands: infeasible as written, or breaks for its users the moment it is used.
- trial — must be fixed before the change is exercised in trial operation; does not block landing.
- required_check — must be fixed before the change becomes an enforced gate or a dependency others rely on.
- follow_up — worth fixing in a follow-up issue.
Rules of evidence:
- The default is
follow_up. The burden of proof is on escalation. - To tag
implementation, the finding description MUST state both: (1) who triggers it, by what operation, and what breaks; and (2) from which milestone on that failure first becomes possible. If (2) cannot be stated, tag the earliest milestone that can be defended. - Exception: a defect that makes the change not work at all as written
(infeasible) is always
implementation. - Minor findings take no
fix_beforetag (implicitlyfollow_up). - Do not add any further gating axis (no
blocking:flag or similar); whether the Gate stops is derived fromfix_beforealone.
Step 5: Write Review File
Output to --output path (default: .specs/{feature}/review-{task-id}.md):
# Review: {task-id}
type: review
## Meta
- Reviewer: spec-review
- Date: {ISO 8601}
- Iteration: {n}
- Rules checked: {count} rules across {count} files
- Diff basis: {diff command used}
## Findings
### Critical
- [ ] **{rule-id}** `{file}:{line}` — fix_before: {implementation|trial|required_check|follow_up} — {what violates and why}
### Improvement
- [ ] **{rule-id}** `{file}:{line}` — fix_before: {implementation|trial|required_check|follow_up} — {suggestion and reasoning}
### Minor
- {rule-id} `{file}:{line}` — {note}
## Summary
- Critical: {n} | Improvement: {n} | Minor: {n}
- Fix before implementation: {n}
- Gate: PASS / FAILGate logic (mechanical, from fix_before alone — severity does not enter
the decision):
- Any finding tagged
fix_before: implementation→ FAIL - Otherwise (only trial / required_check / follow_up / Minor, or no findings) → PASS (deferred findings are recorded and carried forward, never silently dropped)
Error Handling
| Situation | Response |
| No diff available | Error: no changes to review |
--task without resolvable base commit | Error: ask for --base-commit {sha} |
| No rules files found | Warning: use minimal defaults, proceed |
--spec provided but design.md missing | Warning: skip design consistency check |
--output directory doesn't exist | Create the directory |
Usage Examples
# Review a specific task's changes
/spec-review --task T-007 --base-commit abc1234 --spec .specs/did-deactivation/
# Standalone review of current staged changes
/spec-review
# Review a PR diff
/spec-review --diff pr-diff.patch --rules docs/review_rules.md
# Review with custom output
/spec-review --task T-003 --output /tmp/review-T-003.mdDoes 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.

