Perform a non-destructive cross-artifact consistency and quality analysis across spec.md, plan.md, and tasks.md after task generation.
Analyzes cross-artifact consistency between spec, plan, and tasks after task generation. Identifies contradictions, coverage gaps, and constitution violations before implementation.
/plugin marketplace add nprbst/speck-market/plugin install nprbst-speck-speck@nprbst/speck-market$ARGUMENTS
You MUST consider the user input before proceeding (if not empty).
Identify inconsistencies, duplications, ambiguities, and underspecified items across the three core artifacts (spec.md, plan.md, tasks.md) before implementation. This command MUST run only after /speck:tasks has successfully produced a complete tasks.md.
STRICTLY READ-ONLY: Do not modify any files. Output a structured analysis report. Offer an optional remediation plan (user must explicitly approve before any follow-up editing commands would be invoked manually).
Constitution Authority: The project constitution (.speck/memory/constitution.md) is non-negotiable within this analysis scope. Constitution conflicts are automatically CRITICAL and require adjustment of the spec, plan, or tasks—not dilution, reinterpretation, or silent ignoring of the principle. If a principle itself needs to change, that must occur in a separate, explicit constitution update outside /speck:analyze.
Extract prerequisite context from the auto-injected comment in the prompt:
<!-- SPECK_PREREQ_CONTEXT
{"MODE":"single-repo","FEATURE_DIR":"/path/to/specs/010-feature","AVAILABLE_DOCS":["specs/010-feature/spec.md","specs/010-feature/plan.md","specs/010-feature/tasks.md",".speck/memory/constitution.md"]}
-->
Use FEATURE_DIR and AVAILABLE_DOCS from this JSON.
Fallback: If the comment is not present (VSCode hook bug), run:
speck check-prerequisites --json --require-tasks --include-tasks
Parse JSON output to extract FEATURE_DIR and AVAILABLE_DOCS.
IMPORTANT: Do NOT invent or guess CLI paths. Use ONLY the path above.
Abort with an error message if any required file is missing (instruct the user to run missing prerequisite command).
Use Read tool to load files from paths in AVAILABLE_DOCS. Load only the minimal necessary context from each artifact:
From spec.md:
From plan.md:
From tasks.md:
From constitution.md:
Create internal representations (do not include raw artifacts in output):
user-can-upload-file)Focus on high-signal findings. Limit to 50 findings total; aggregate remainder in overflow summary.
<placeholder>, etc.)Use this heuristic to prioritize findings:
Output a Markdown report (no file writes) with the following structure:
| ID | Category | Severity | Location(s) | Summary | Recommendation |
|---|---|---|---|---|---|
| A1 | Duplication | HIGH | spec.md:L120-134 | Two similar requirements ... | Merge phrasing; keep clearer version |
(Add one row per finding; generate stable IDs prefixed by category initial.)
Coverage Summary Table:
| Requirement Key | Has Task? | Task IDs | Notes |
|---|
Constitution Alignment Issues: (if any)
Unmapped Tasks: (if any)
Metrics:
At end of report, output a concise Next Actions block:
/speck:implementAsk the user: "Would you like me to suggest concrete remediation edits for the top N issues?" (Do NOT apply them automatically.)
CRITICAL: If remediation edits are approved and applied, any tasks that are modified with new requirements MUST be unchecked (changed from [X] to [ ]) in tasks.md so they will be re-implemented with the updated requirements.
$ARGUMENTS