spec-analyze
Spec-Analyze
Cross-artifact consistency analysis - READ-ONLY, no file modifications.
Prerequisites: tasks.md must exist (run /spec-tasks first).
Workflow
- Initialize - Run
.specify/scripts/bash/check-prerequisites.sh --json --require-tasks --include-tasks - Load artifacts - spec.md, plan.md, tasks.md, constitution.md
- Build semantic models - Requirements inventory, task mapping
- Detection passes - 6 analysis categories
- Assign severity - CRITICAL/HIGH/MEDIUM/LOW
- Produce report - Markdown table with findings
- Offer remediation - Ask before any edits
Detection Categories
A. Duplication Detection
- Near-duplicate requirements
- Mark lower-quality for consolidation
B. Ambiguity Detection
- Vague adjectives (fast, scalable, intuitive)
- Unresolved placeholders (TODO, ???)
C. Underspecification
- Verbs without measurable outcomes
- Missing acceptance criteria
- Tasks referencing undefined components
D. Constitution Alignment
- MUST principle violations → CRITICAL
- Missing mandated sections
E. Coverage Gaps
- Requirements with zero tasks
- Tasks with no mapped requirement
- Non-functional requirements not in tasks
F. Inconsistency
- Terminology drift
- Missing data entities
- Task ordering contradictions
- Conflicting requirements
Severity Levels
| Level | Criteria |
|---|---|
| CRITICAL | Constitution violation, missing core artifact, baseline blocker |
| HIGH | Duplicate/conflicting requirement, untestable criterion |
| MEDIUM | Terminology drift, missing NFR coverage |
| LOW | Style/wording, minor redundancy |
Report Format
## Specification Analysis Report
| ID | Category | Severity | Location(s) | Summary | Recommendation |
|----|----------|----------|-------------|---------|----------------|
| A1 | Duplication | HIGH | spec.md:L120 | Similar requirements | Merge phrasing |
**Coverage Summary:**
| Requirement | Has Task? | Task IDs |
|-------------|-----------|----------|
**Metrics:**
- Total Requirements: X
- Coverage %: Y%
- Critical Issues: Z
Operating Constraints
- STRICTLY READ-ONLY - No file modifications
- Constitution is non-negotiable - Violations are CRITICAL
- Max 50 findings (aggregate overflow)
- Deterministic results on rerun
Next Actions
- CRITICAL issues → Resolve before
/spec-implement - LOW/MEDIUM only → May proceed with suggestions
Next Steps
After /spec-analyze:
- Fix identified issues
/spec-implement- Execute implementation
More from xfstudio/skills
baoyu-post-to-wechat
Posts content to WeChat Official Account (微信公众号) via Chrome CDP automation. Supports article posting (文章) with full markdown formatting and image-text posting (图文) with multiple images. Use when user mentions "发布公众号", "post to wechat", "微信公众号", or "图文/文章".
22last30days
Research a topic from the last 30 days on Reddit + X + Web, become an expert, and write copy-paste-ready prompts for the user's target tool.
15ui-ux-pro-max
UI/UX design intelligence. 50 styles, 21 palettes, 50 font pairings, 20 charts, 9 stacks (React, Next.js, Vue, Svelte, SwiftUI, React Native, Flutter, Tailwind, shadcn/ui). Actions: plan, build, create, design, implement, review, fix, improve, optimize, enhance, refactor, check UI/UX code. Projects: website, landing page, dashboard, admin panel, e-commerce, SaaS, portfolio, blog, mobile app, .html, .tsx, .vue, .svelte. Elements: button, modal, navbar, sidebar, card, table, form, chart. Styles: glassmorphism, claymorphism, minimalism, brutalism, neumorphism, bento grid, dark mode, responsive, skeuomorphism, flat design. Topics: color palette, accessibility, animation, layout, typography, font pairing, spacing, hover, shadow, gradient. Integrations: shadcn/ui MCP for component search and examples.
133d-web-experience
Expert in building 3D experiences for the web - Three.js, React Three Fiber, Spline, WebGL, and interactive 3D scenes. Covers product configurators, 3D portfolios, immersive websites, and bringing depth to web experiences. Use when: 3D website, three.js, WebGL, react three fiber, 3D experience.
12tailwind-design-system
Build scalable design systems with Tailwind CSS, design tokens, component libraries, and responsive patterns. Use when creating component libraries, implementing design systems, or standardizing UI patterns.
11frontend-design
Create distinctive, production-grade frontend interfaces with intentional aesthetics, high craft, and non-generic visual identity. Use when building or styling web UIs, components, pages, dashboards, or frontend applications.
11