spec-review
Skill1 starsChanged 2 months agoMITView on GitHub
Reviews and enriches story specifications with codebase-verified technical sub-tasks, architecture alignment checks, design simplification suggestions, and API test plans. Dynamically discovers project architecture at runtime. Use when: (1) a new story spec needs review before implementation, (2) a spec has high-level tasks but lacks implementation-ready detail, (3) need to verify spec assumptions against actual codebase, (4) a spec references API changes but has no test plan, (5) reviewing specs that reference data shapes or pipeline ordering, (6) spec subtasks mention add field X to object Y or call function at line N.
18 other projects use a version of this.
Adopted by
Most recently taken up by
- komluk/scaffoldingtheir own version, first seen Sep 28, 2026
- markkj/skillstheir own version, first seen Sep 26, 2026
- FooJiaYin/dev-skillstheir own version, first seen Sep 24, 2026
- VerusK/claude-skillstheir own version, first seen Sep 22, 2026
- HHU3637kr/skillstheir own version, first seen Sep 22, 2026
- microsoft/winappClitheir own version, first seen Sep 21, 2026
Used with
Projects with it also use plan-review, implement-spec and 2 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.
longranger2Skillplan-review
Use when the user says "/plan-review", "plan review", or "PRD review" and provides a plan file path that needs critical review and iterative refinement with Codex.
Also in 3 projects that use this
AWSSkillimplement-spec
Implement the result of /to-spec and /to-tickets in code.
Also in 3 projects that use this
AICreator-WindSkilldesign-review
编码设计师工具。设计审计和修复。
Also in 3 projects that use this
GoogleSkillcode-review
Adversarial systems, concurrency, memory-model, and architecture code review protocol. Use this skill whenever asked to review code, PRs, diffs, or branches in Filament.
Also in 5 projects that use this
Other versions18 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 18
- microsoft/winappCli★ 1.3ksame name
- cashew-labs/libretto★ 904same name
- HHU3637kr/skills★ 145same name
- agent-ix/quoin★ 20same name
- azents/azents★ 16same name
- komluk/scaffolding★ 15same name
- markkj/skills★ 4same name
- RizwanZafaris/product-manager-OS★ 4same name
- aictrl-dev/skills★ 2same name
- anyoneanderson/agent-skills★ 2same name
8 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 repository11 other files it gives its agents.
- CLAUDE.mdCLAUDE.md
- changelog-keeperSkill
- claudeceptionSkill
- context-shieldSkill
- conversation-searchSkill
- deep-reviewSkill
- figma-ui-designerSkill
- skill-authoringSkill
- spec-creatorSkill
- spec-implementSkill
- worktreeSkill
The file
We split this skill into the rules it gives an agent
10 rules. 0 are common, 6 are distinctive, and 4 are very specific to this project.
0
Common
Most of the 17 edited versions we read keep these.
6
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 86
After applying the checklist, the spec should have:
- Distinctive: line 92
No unnecessary wrapper functions
- Very specific: line 116
Before starting a full review, create the task checklist from ./scripts/task-manifest.sh full-review:
- Very specific: line 130
If any task fails, keep it as in_progress and report the error
- Very specific: line 298
When CLAUDE_CODE_EXPERIMENTAL_AGENT_TEAMS is enabled, Phase 2 can use a team instead of 4 parallel Agent calls.
- Distinctive: line 302
Iterative refinement: If Design Simplifier identifies a simplification that affects the Test Plan, the Test Plan Extractor adjusts in …
- Distinctive: line 307
Create 4 tasks (one per analysis dimension)
- Distinctive: line 317
After all agents return, synthesize findings into spec enrichments.
- Distinctive: line 371
Ask the user whether to:
- Very specific: line 385
Always verify spec claims with grep/read — never trust assumed file paths.
“Common” is measured: kept by at least 6 in 10 of the 17 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
Path convention:
./scripts/…and./references/…below are relative to this skill's own base directory — announced as "Base directory for this skill" when the skill is invoked. A Bash tool call's working directory is the user's project, not the skill directory, so prefix these with that base directory when running them. Paths written without the leading./(for examplescripts/ortests/inside a search over the codebase) refer to the target project being worked on, not to this skill.
Comprehensive spec review combining codebase verification and implementation planning. Discovers project architecture at runtime — works with any codebase structure.
- Codebase Verification — 8-category checklist for verifying spec sub-tasks against code
- Full Planning Workflow — 4-phase parallel analysis producing enriched specs
Part 1: Codebase Verification Checklist
Problem
Story specs with technical subtasks frequently contain incorrect assumptions about the codebase — fields on the wrong object, wrong data shapes, incorrect pipeline ordering, unnecessary wrapper functions. These look plausible but cause confusion during implementation.
Pre-Commit Verification Checklist
For every spec subtask that references code, verify these 8 categories:
1. Field Location — "Which object actually has this field?"
# Don't assume a field is on the object you expect
grep -rn "fieldName" <service-directory> --include="*.ts" --include="*.js"Common trap: Enrichment/transform services copy SOME fields from source items but not ALL.
2. Data Shape — "What type is this field really?"
grep -A5 "fieldName" <service-file>
# May reveal { value: number, unit: string } not just a numberCommon trap: Duration/time fields are often objects {value, unit} not plain numbers.
3. Pipeline Ordering — "What data is available at this point?"
# Trace the processing pipeline to verify what data exists at each stage
grep -n "extract\|enrich\|transform\|validate\|process" <orchestrator-file>Common trap: Integration points may be BEFORE enrichment/transform runs.
4. Function Signatures — "What params does this actually take?"
grep -A3 "function targetFunction\|const targetFunction" <file>Common trap: Functions may infer values from their inputs rather than accepting explicit params.
5. Conditional Fields — "Is this field always present?"
grep -B2 -A2 "fieldName =" <config-or-service-file>
# May reveal: field only set under certain conditions6. Existing Delegation — "Does a wrapper already handle this?"
grep -n "buildDynamic\|delegate\|dispatch\|forward" <relevant-files>7. Automation Integration — "Will this run during CI/maintenance?"
# Find pipeline agents/scripts that run build/enrichment steps
grep -rn "script-name\|task-name" .claude/agents/ scripts/ .github/8. ID/Data Contract Consistency — "Do producer and consumer use the same resolution?"
# When spec says "function A returns IDs that function B uses for lookup"
# Verify both use the same ID resolution/normalization
grep -A10 "function producer\|function consumer" <service-files>Common trap: A producer resolves IDs to canonical form but the consumer expects raw values.
Verification Output
After applying the checklist, the spec should have:
- Exact function signatures with parameter types and return types
- Correct file paths and line numbers (verified by reading the file)
- Accurate data shapes (object vs primitive, with field names)
- Correct pipeline ordering (verified by reading the orchestration code)
- Conditional field handling noted where fields may be absent
- No unnecessary wrapper functions
- ID resolution consistency verified between producer and consumer functions
Part 2: Full Planning Workflow
Quick Check
# Discover project architecture (layers, services, test tools)
./scripts/discover-project-architecture.sh "$(git rev-parse --show-toplevel)"
./scripts/discover-project-architecture.sh "$(git rev-parse --show-toplevel)" --json
# Extract spec sections for analysis
./scripts/extract-spec-sections.sh <spec-file>
./scripts/extract-spec-sections.sh <spec-file> --json
# Task checklist for full review
./scripts/task-manifest.sh full-reviewProgress Tracking (MANDATORY)
Before starting a full review, create the task checklist from ./scripts/task-manifest.sh full-review:
| # | subject | activeForm |
| 1 | Discover architecture and extract spec | Discovering project architecture |
| 2 | Launch 4 parallel analysis agents | Analyzing spec with 4 parallel agents |
| 3 | Synthesize findings into enrichments | Synthesizing review findings |
| 4 | Calculate readiness score | Calculating implementation readiness |
| 5 | Present report and apply enrichments | Presenting review report |
Update rules:
- Mark each task
in_progress(TaskUpdate) immediately before starting it - Mark each task
completedimmediately after it succeeds - Task 2 launches 4 parallel agents — mark
completedafter ALL agents return - If any task fails, keep it as
in_progressand report the error - On abort, mark remaining tasks as
deleted
Phase 1: Discover and Extract (Scripts)
1.1 Discover project architecture:
PROJECT_ROOT="$(git rev-parse --show-toplevel)"
ARCH=$(./scripts/discover-project-architecture.sh "$PROJECT_ROOT" --json)This returns: packages with layer classification (frontend/backend/mcp/tooling), frameworks per package, test frameworks, API test tools, Bruno folders (if any), E2E framework, data flow patterns, i18n approach, and security patterns.
1.2 Extract spec sections:
SPEC_DATA=$(./scripts/extract-spec-sections.sh "$SPEC_FILE" --json)This returns: title, acceptance criteria counts, referenced files and endpoints, sub-task count, and gap detection (missing codebase state, missing test plan).
1.3 Read CLAUDE.md and architecture docs from the project root. Look for:
CLAUDE.md— project-level development rules and conventionsdocs/development/ARCHITECTURE.mdor similar — architecture documentationdocs/development/TESTING.mdor similar — test strategy documentation
These provide project-specific context that the discovery script can't capture (business rules, data flow conventions, layer responsibility definitions).
Phase 2: Parallel Analysis (4 Agents)
Launch ALL four agents in a SINGLE Task tool message.
The
feature-dev:*agent types below require the separately-installedfeature-devplugin. If it is not available, dispatchgeneral-purposeinstead and note the substitution in your output.
| Agent | Type | Purpose | Key Output |
| Codebase Verifier | feature-dev:code-explorer | Verify every file path, function name, and data shape | Verified/corrected paths, signatures, shapes |
| Architecture Reviewer | feature-dev:code-explorer | Map spec to discovered architecture, identify boundary violations | Architecture alignment report |
| Design Simplifier | feature-dev:code-architect | Analyze for over-engineering, suggest simpler approaches | Simplification recommendations |
| Test Plan Extractor | general-purpose | Extract testable scenarios, design API/E2E test plan | Test plan using project's discovered test tools |
Agent Prompt Templates
Codebase Verifier — Provide the spec's referenced files/functions/fields and ask:
You are verifying a story specification against the actual codebase.
SPEC TITLE: [title]
SPEC FILE: [path]
FILES REFERENCED IN SPEC:
[list from extraction]
FUNCTIONS REFERENCED:
[list of function names and claimed signatures]
YOUR TASK:
1. Verify each referenced file EXISTS at the claimed path
2. Verify each function has the claimed SIGNATURE
3. Verify each data shape matches reality (field names, types, nesting)
4. Check line number references are still accurate
5. Report DISCREPANCIES between spec claims and actual codebase
OUTPUT FORMAT:
- VERIFIED: [path/function] — matches spec
- CORRECTED: [path/function] — spec says X, actual is Y
- MISSING: [path/function] — does not exist in codebaseArchitecture Reviewer — Inject discovered architecture into the prompt:
You are reviewing a story specification for architecture alignment.
SPEC TITLE: [title]
SOLUTION OVERVIEW: [paste solution section]
SUB-TASKS: [paste sub-task list]
PROJECT ARCHITECTURE (discovered at runtime):
[Paste the ARCH JSON from Phase 1 — layers, services, frameworks]
PROJECT RULES (from CLAUDE.md):
[Paste relevant architecture rules from CLAUDE.md]
YOUR TASK:
1. Identify the project's layer boundaries from the discovered architecture
2. Check each sub-task respects layer boundaries
3. Map spec requirements to EXISTING services that already handle similar work
4. Flag missing cross-cutting concerns (CSRF, caching, i18n — based on discovered patterns)
5. Check if data flow follows the project's established direction
OUTPUT FORMAT:
- ALIGNED: [sub-task] — correctly uses [layer/service]
- VIOLATION: [sub-task] — [description of violation and fix]
- REUSE: [sub-task] — existing [service/function] already handles this
- MISSING: [concern] — spec should address [security/cache/i18n/etc.]Design Simplifier — Provide the spec's technical design:
You are reviewing a story specification for over-engineering.
SPEC TITLE: [title]
TECHNICAL DESIGN: [paste design section]
SUB-TASKS: [paste all sub-tasks with details]
SUB-TASK COUNT: [N]
NEW FILES PROPOSED: [list]
SIMPLIFICATION PATTERNS:
[Paste the full contents of ./references/design-simplification-checklist.md here — inline the content; do not pass the file path to the sub-agent]
YOUR TASK:
1. For each sub-task, ask: "Can this be done more simply?"
2. Check for unnecessary abstractions (wrappers, managers, helpers used once)
3. Check for redundant infrastructure (new cache when upstream caches exist)
4. Check for over-scoped changes (refactoring, observability, feature flags)
5. Propose concrete simplifications with rationale
OUTPUT FORMAT:
- KEEP: [sub-task] — appropriately scoped
- SIMPLIFY: [sub-task] — [current approach] → [simpler approach] because [reason]
- REMOVE: [sub-task] — unnecessary because [reason]
- MERGE: [sub-tasks X+Y] → single sub-task because [reason]Test Plan Extractor — Use discovered test tools:
You are extracting testable use cases from a story specification.
SPEC TITLE: [title]
ACCEPTANCE CRITERIA: [paste all ACs]
ENDPOINTS AFFECTED: [list of API routes/tools]
PROJECT TEST INFRASTRUCTURE (discovered):
- API Test Tool: [e.g., Bruno, Postman, HTTP Client, or none]
- API Test Folders: [list from discovery, or "none detected"]
- Unit Test Framework: [e.g., Jest, Vitest, pytest per package]
- E2E Framework: [e.g., Playwright, Cypress, or none]
SCENARIO CATEGORIES:
HP (Happy Path, P0) | VAL (Validation, P0) | EDGE (Edge Cases, P1)
DC (Data Contract, P0) | REG (Regression, P1) | LOC (Localization, P1) | PERF (Performance, P2)
YOUR TASK:
1. For each acceptance criterion, identify testable API scenarios
2. Classify each scenario (HP/VAL/EDGE/DC/REG/LOC/PERF)
3. Determine the correct test location based on discovered folder structure
4. Identify shared fixtures/sessions that can be reused
5. Define key assertions for each test
6. Check for existing tests that might already cover scenarios
7. Note scenarios better suited for unit tests or E2E
OUTPUT FORMAT:
## API Test Plan
### Test Summary
| ID | Scenario | Category | File | Folder | Priority |
### Coverage Matrix
| Acceptance Criterion | Test(s) | Gap? |
### Test Specifications
1. **TEST.1** Create [folder/file] — [description with key assertions]Team Mode (Optional)
When CLAUDE_CODE_EXPERIMENTAL_AGENT_TEAMS is enabled, Phase 2 can use a team instead
of 4 parallel Agent calls. Benefits:
- Cross-pollination: Codebase Verifier can alert Architecture Reviewer about missing files mid-review (via SendMessage), rather than discovering mismatches only during synthesis
- Iterative refinement: If Design Simplifier identifies a simplification that affects the Test Plan, the Test Plan Extractor adjusts in real-time
Team workflow:
TeamCreate("spec-review-{spec-name}")- Create 4 tasks (one per analysis dimension)
- Spawn 4 teammates with specialized prompts
- Teammates claim tasks, work independently, message each other with findings
- Lead synthesizes all findings in Phase 3
TeamDeletecleanup
Default: Sub-agent mode (no teams). Teams are opt-in when enabled.
Phase 3: Synthesize and Generate Enrichments
After all agents return, synthesize findings into spec enrichments.
3.1 Current Codebase State Section
## Current Codebase State
**What EXISTS (verified):**
- `exact/path/to/file.ext` — functionName(params): ReturnType (line XX)
**What needs to be MODIFIED:**
- `exact/path/to/file.ext` — [specific change description]
**What needs to be CREATED:**
- `exact/path/to/new-file.ext` — [purpose and responsibility]3.2 Design Simplification Notes
## Design Simplification Notes
1. **[Sub-task X]**: [Current approach] → [Simpler approach] — [rationale]3.3 Detailed Technical Sub-Tasks
Each sub-task must have: File, Function, Change, Verification command, Dependencies, Estimated complexity (S/M/L).
3.4 API Test Plan
Formatted using the project's discovered test tool conventions (Bruno .bru files,
Postman collections, plain HTTP files, or unit test specifications).
3.5 Implementation Readiness Score
| Dimension | Score (1-5) | Notes |
| Codebase Accuracy | X | How many refs were correct vs corrected |
| Architecture Alignment | X | How many violations found |
| Design Simplicity | X | Complexity score from simplifier |
| Test Coverage | X | % of ACs mapped to tests |
| Sub-Task Completeness | X | Are all sub-tasks implementation-ready? |
| Overall Readiness | X/25 |
Readiness levels:
- 20-25: Ready for implementation
- 15-19: Minor gaps, review enrichments and proceed
- 10-14: Significant gaps, iterate on spec before implementing
- Below 10: Major rework needed
Phase 4: Present Report
Present findings as a structured report with:
- Summary of issues found (Critical / Important / Suggestions)
- Enriched sections ready to insert into the spec
- Implementation readiness score
- Recommended next steps
Ask the user whether to:
- Update the spec file with enrichments (recommended)
- Save as a companion document (e.g.,
specs/reviews/review-X.Y.md) - Just report without modifying files
Notes
- This skill is a PRE-implementation review. It enriches specs, not code.
- Feature-dev's code-explorer agents are reused for codebase verification when the
feature-devplugin is installed; otherwisegeneral-purposeagents are substituted. - Feature-dev's code-architect agents are reused for design analysis when the
feature-devplugin is installed; otherwisegeneral-purposeagents are substituted. - The test plan produced here is a SPECIFICATION — use appropriate tooling during implementation to create actual test files.
- Always verify spec claims with
grep/read— never trust assumed file paths. - The most common failure mode is field-on-wrong-object: a field exists in the codebase but on a different layer's object than the spec assumes.
- For multi-path systems (e.g., sync + async + streaming code paths), ensure the spec addresses ALL paths consistently.
See Also
spec-creator— generates story specs (this skill reviews them)context-shield— use when a spec references many external docs that need reading
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.

