{"id":"speckit-workflow","name":"speckit-workflow","summary":"スペックキットの手法を包括的に理解すること。仕様、計画、タスク、実装の各段階を含む構成駆動型の機能開発。","body":"# SpecKit Workflow\n\nThe SpecKit methodology is a constitution-driven approach to feature development. It ensures consistency across features by grounding all decisions in project principles.\n\n## Core Philosophy\n\n**Constitution First**: Every feature is designed against the project's constitution - a living document of principles, constraints, and standards.\n\n**Governance Over Convention**: Rather than implicit patterns, SpecKit makes governance explicit through:\n- Constitution principles (MUST, SHOULD, MAY)\n- Feature specifications tied to principles\n- Quality checklists as \"unit tests for requirements\"\n- Consistency analysis across artifacts\n\n## Directory Structure\n\n```text\n.specify/\n├── memory/\n│   └── constitution.md       # Project principles and standards\n├── .current-feature          # Active feature pointer\n├── templates/                # Artifact templates\n│   ├── spec-template.md\n│   ├── plan-template.md\n│   ├── tasks-template.md\n│   └── checklist-template.md\n└── specs/\n    └── <id>-<name>/          # Feature directories\n        ├── .speckit-state.json\n        ├── .progress.md\n        ├── .coordinator-prompt.md\n        ├── spec.md           # Feature specification\n        ├── plan.md           # Technical design\n        ├── tasks.md          # Implementation tasks\n        ├── research.md       # Research findings (optional)\n        ├── data-model.md     # Entity definitions (optional)\n        ├── contracts/        # API contracts (optional)\n        └── checklists/       # Quality checklists\n```\n\n## Feature ID System\n\nFeatures use auto-incremented 3-digit IDs:\n- `001-user-auth`\n- `002-payment-gateway`\n- `003-notification-system`\n\nBenefits:\n- Natural ordering in filesystem\n- Easy reference in commits/PRs\n- Prevents naming conflicts\n\n## Workflow Phases\n\n### Phase 1: Constitution (`/speckit:constitution`)\n\nEstablish or update project-wide principles.\n\n**Inputs**: Project context, team preferences\n**Outputs**: `.specify/memory/constitution.md`\n\nConstitution sections:\n- **Identity**: Project name, purpose, core domain\n- **Principles**: MUST/SHOULD/MAY rules\n- **Technology Stack**: Languages, frameworks, tools\n- **Patterns**: Architecture, naming, error handling\n- **Quality Standards**: Testing, performance, security\n\n### Phase 2: Specify (`/speckit:specify`)\n\nDefine the feature specification against constitution.\n\n**Inputs**: Feature goal, constitution reference\n**Outputs**: `spec.md`\n\nSpecification contains:\n- Feature overview and goals\n- User stories with acceptance criteria\n- Constitution alignment markers\n- Out of scope items\n- Dependencies and risks\n\n### Phase 3: Clarify (`/speckit:clarify`) - Optional\n\nResolve ambiguities through structured Q&A.\n\n**Inputs**: `spec.md` with ambiguities\n**Outputs**: Updated `spec.md` with clarifications\n\nRules:\n- Maximum 5 clarifying questions per session\n- Each question has 2-4 options + \"Other\"\n- Recommendations marked when applicable\n- Clarifications appended to spec\n\n### Phase 4: Plan (`/speckit:plan`)\n\nGenerate technical design from specification.\n\n**Inputs**: `spec.md`, constitution, codebase context\n**Outputs**: `plan.md`, optionally `data-model.md`, `contracts/`\n\nPlan contains:\n- Architecture overview\n- Component breakdown\n- Data flow diagrams\n- API contracts\n- Integration points\n- Risk mitigation\n\n### Phase 5: Tasks (`/speckit:tasks`)\n\nBreak plan into dependency-ordered implementation tasks.\n\n**Inputs**: `plan.md`, `spec.md`\n**Outputs**: `tasks.md`\n\nTask format:\n```markdown\n- [ ] T001 [P] [US1] Task description `path/to/file.ts`\n```\n\nComponents:\n- `T001`: Sequential task ID\n- `[P]`: Parallel marker (optional)\n- `[US1]`: User story reference (optional)\n- Description with file path\n\nTask phases:\n1. **Setup**: Environment, dependencies, scaffolding\n2. **Core**: Main implementation tasks\n3. **Integration**: Connect components\n4. **Polish**: Error handling, edge cases\n5. **Verification**: Quality checkpoints\n\n### Phase 6: Implement (`/speckit:implement`)\n\nExecute tasks via Ralph Wiggum loop.\n\n**Inputs**: `tasks.md`, state file\n**Outputs**: Code changes, commits, updated progress\n\nExecution model:\n- Coordinator reads state, delegates to executor\n- 4-layer verification before advancing\n- Parallel execution for [P] marked tasks\n- Fresh context per task\n\n## State Management\n\n### State File (`.speckit-state.json`)\n\n```json\n{\n  \"featureId\": \"001\",\n  \"name\": \"user-auth\",\n  \"basePath\": \".specify/specs/001-user-auth\",\n  \"phase\": \"execution\",\n  \"taskIndex\": 0,\n  \"totalTasks\": 15,\n  \"taskIteration\": 1,\n  \"maxTaskIterations\": 5,\n  \"globalIteration\": 1,\n  \"maxGlobalIterations\": 100,\n  \"awaitingApproval\": false\n}\n```\n\n### Progress File (`.progress.md`)\n\nTracks:\n- Completed tasks with commit hashes\n- Learnings and context for future tasks\n- Blockers and resolutions\n- Cross-task dependencies\n\n## Quality Assurance\n\n### Checklists (`/speckit:checklist`)\n\nDomain-specific quality checklists:\n- UX checklist\n- API checklist\n- Security checklist\n- Performance checklist\n- Accessibility checklist\n\nChecklists are \"unit tests for requirements\" - verifiable criteria before implementation.\n\n### Analyze (`/speckit:analyze`)\n\nCross-artifact consistency analysis:\n- Spec ↔ Constitution alignment\n- Plan ↔ Spec coverage\n- Tasks ↔ Plan traceability\n- Identifies gaps, conflicts, ambiguities\n\n## Command Reference\n\n| Command | Purpose | Phase |\n|---------|---------|-------|\n| `/speckit:start <name>` | Create or resume feature | Entry |\n| `/speckit:constitution` | Create/update project principles | 1 |\n| `/speckit:specify` | Define feature specification | 2 |\n| `/speckit:clarify` | Resolve spec ambiguities | 3 |\n| `/speckit:plan` | Generate technical design | 4 |\n| `/speckit:tasks` | Break plan into tasks | 5 |\n| `/speckit:implement` | Execute tasks | 6 |\n| `/speckit:analyze` | Check consistency | Any |\n| `/speckit:checklist` | Generate quality checklist | Any |\n| `/speckit:status` | Show current state | Any |\n| `/speckit:switch <id>` | Change active feature | Any |\n| `/speckit:cancel` | Stop execution, cleanup | Any |\n\n## Agent Ecosystem\n\n| Agent | Purpose | Used By |\n|-------|---------|---------|\n| `constitution-architect` | Create/update constitution | constitution |\n| `spec-analyst` | Generate specifications | specify |\n| `plan-architect` | Technical design | plan |\n| `task-planner` | Task breakdown | tasks |\n| `spec-executor` | Execute single task | implement |\n| `qa-engineer` | Verification tasks | implement |\n\n## Constitution Integration\n\nAll phases reference the constitution:\n\n1. **Specify**: Maps features to constitution principles\n2. **Plan**: Architecture follows constitution patterns\n3. **Tasks**: Quality checkpoints enforce constitution\n4. **Implement**: Executor validates against standards\n\nConstitution markers in artifacts:\n- `[C§3.1]`: References constitution section 3.1\n- `[MUST]`: Required by constitution\n- `[SHOULD]`: Recommended by constitution\n- `[MAY]`: Optional per constitution\n\n## Best Practices\n\n### Starting New Features\n\n1. Ensure constitution exists and is current\n2. Use descriptive feature names (kebab-case)\n3. Include clear success criteria in spec\n4. Reference related features if applicable\n\n### During Implementation\n\n1. Follow task order (dependencies matter)\n2. Commit after each task\n3. Update progress with learnings\n4. Run verification checkpoints\n\n### Maintaining Constitution\n\n1. Version constitution changes semantically\n2. Run sync impact analysis after updates\n3. Update affected features if needed\n4. Document rationale for changes","author":"@tzachbon","ownerProfile":null,"authorContacts":null,"sourceUrl":"https://github.com/tzachbon/smart-ralph/tree/main/plugins/ralph-speckit/skills/speckit-workflow","license":"MIT","category":"document","lang":"en","tokens":1811,"stars":0,"calls30d":1,"claimed":false,"visibility":"public","origin":"crawler","version":"0.1.0","createdAt":"2026-08-22","updatedAt":"2026-08-22","files":[],"requires":{"mcp":[],"tools":[]},"safety":{"flags":[],"scannedAt":"2026-08-22","hasScripts":false,"networkEndpoints":[]}}