Feature Lifecycle Skill
Phase-gated feature workflow: DESIGN > PLAN > IMPLEMENT > VALIDATE > RELEASE. Each phase must pass its gate before the next begins.
Phase Routing
Determine which phase to execute based on feature state:
If .feature/ exists, check current phase:
python3 ~/.claude/scripts/feature-state.py status
Route to the phase indicated by the state machine.
If no feature state exists, determine entry point from user intent:
- Validated
Architecture Change Handoff targeting feature-lifecycle -> DESIGN; the design phase adopts it before approach work
- "design", "think through", "explore approaches" -> DESIGN
- "plan", "break down", "create tasks" -> PLAN (requires completed design)
- "implement", "execute plan", "start building" -> IMPLEMENT (requires completed plan)
- "validate", "quality gates", "check feature" -> VALIDATE (requires completed implementation)
- "release", "merge", "ship it" -> RELEASE (requires passed validation)
- "end to end", "full lifecycle", "from scratch" -> DESIGN (start from beginning)
Load the phase reference for the current phase:
- DESIGN: Read
references/design.md
- PLAN: Read
references/plan.md
- IMPLEMENT: Read
references/implement.md
- VALIDATE: Read
references/validate.md — run quality gate commands, do not reason about whether they would pass. Paste exit codes and output.
- RELEASE: Read
references/release.md
- END-TO-END: Read
references/pipeline.md
Follow the loaded reference exactly. Each reference contains the full phase instructions, gates, and checkpoints.
State Conventions
Read references/shared.md for directory structure, state management commands, context loading rules, and naming conventions. All state operations go through python3 ~/.claude/scripts/feature-state.py -- never manipulate state files directly.
Phase Ordering
DESIGN -> PLAN -> IMPLEMENT -> VALIDATE -> RELEASE
| | | | |
v v v v v
design.md plan.md impl.md report.md PR merged
Each phase produces an artifact consumed by the next. Skipping phases is not supported because downstream phases depend on artifacts from earlier phases.
Reference Loading Table
| Signal |
Load These Files |
Why |
| Phase 1 DESIGN: idea to design document |
design.md |
Loads detailed guidance from design.md. |
| Architecture Change Handoff targets feature-lifecycle |
design.md |
Validate and adopt architecture scope/interface/migration; create/register the feature ADR in DESIGN. |
| errors, error handling |
error-handling.md |
Loads detailed guidance from error-handling.md. |
| Phase 3 IMPLEMENT: dispatching task waves to domain agents |
implement.md |
Loads detailed guidance from implement.md. |
| running the full design-to-release pipeline |
pipeline.md |
Loads detailed guidance from pipeline.md. |
| Phase 2 PLAN: decomposing design into wave-ordered tasks |
plan.md |
Loads detailed guidance from plan.md. |
| Phase 5 RELEASE: PR merge, tagging, worktree cleanup |
release.md |
Loads detailed guidance from release.md. |
| feature state directory layout, naming, write protection |
shared.md |
Loads detailed guidance from shared.md. |
| Phase 4 VALIDATE: running quality gates |
validate.md |
Loads detailed guidance from validate.md. |
Error Handling
| Error |
Cause |
Solution |
| Phase mismatch |
User requests phase N but state is at phase M |
Report current state, suggest correct next phase |
| Missing artifact |
Previous phase did not produce expected output |
Route back to previous phase |
| Gate failure |
Phase requirements not met |
Report what failed, suggest fixes |
References
| Task Signal |
Load |
| Phase routing (design/plan/implement/validate/release) |
Phase reference (design.md, plan.md, implement.md, validate.md, release.md) |
| End-to-end or full pipeline |
references/pipeline.md |
| State commands, directory structure, naming |
references/shared.md |
| Error, failure, blocked, gate fail, retry, deviation |
references/error-handling.md |
references/design.md -- Design phase: explore requirements, discuss trade-offs
references/plan.md -- Plan phase: break design into wave-ordered tasks
references/implement.md -- Implement phase: dispatch tasks to domain agents
references/validate.md -- Validate phase: run quality gates
references/release.md -- Release phase: merge, tag, cleanup
references/pipeline.md -- End-to-end orchestration across all phases
references/shared.md -- State conventions shared across all phases
references/error-handling.md -- Recovery patterns for phase errors, gate failures, agent dispatch failures
1---2name: feature-lifecycle3description: |4 Feature lifecycle: design, plan, implement, validate, release. Phase-gated workflow.5user-invocable: false6command: /feature-lifecycle7allowed-tools:8 - Read9 - Write10 - Bash11 - Grep12 - Glob13 - Edit14 - Agent15 - Task16routing:17 force_route: true18 not_for: "small bug fixes (use quick), code reviews, refactoring single files, content writing — only for new feature work spanning design → plan → implement → validate → release"19 triggers:20 - feature design21 - design feature22 - think through23 - explore approaches24 - design first25 - feature plan26 - plan feature27 - break down design28 - create tasks29 - feature implement30 - implement feature31 - execute plan32 - start building33 - feature validate34 - validate feature35 - run feature quality gates36 - check feature37 - feature release38 - release feature39 - merge feature40 - build feature end to end41 - full feature lifecycle42 - feature from scratch43 - design to release44 - complete feature pipeline45 - feature pipeline46 pairs_with:47 - workflow48 - subagent-driven-development49 - pr-workflow50 - verification-before-completion51 - universal-quality-gate52 - adr-consultation53 - planning54 complexity: Complex55 category: process56---5758# Feature Lifecycle Skill5960Phase-gated feature workflow: DESIGN > PLAN > IMPLEMENT > VALIDATE > RELEASE. Each phase must pass its gate before the next begins.6162## Phase Routing6364Determine which phase to execute based on feature state:65661. **If `.feature/` exists**, check current phase:67 ```bash68 python3 ~/.claude/scripts/feature-state.py status69 ```70 Route to the phase indicated by the state machine.71722. **If no feature state exists**, determine entry point from user intent:73 - Validated `Architecture Change Handoff` targeting `feature-lifecycle` -> DESIGN; the design phase adopts it before approach work74 - "design", "think through", "explore approaches" -> DESIGN75 - "plan", "break down", "create tasks" -> PLAN (requires completed design)76 - "implement", "execute plan", "start building" -> IMPLEMENT (requires completed plan)77 - "validate", "quality gates", "check feature" -> VALIDATE (requires completed implementation)78 - "release", "merge", "ship it" -> RELEASE (requires passed validation)79 - "end to end", "full lifecycle", "from scratch" -> DESIGN (start from beginning)80813. **Load the phase reference** for the current phase:82 - DESIGN: Read `references/design.md`83 - PLAN: Read `references/plan.md`84 - IMPLEMENT: Read `references/implement.md`85 - VALIDATE: Read `references/validate.md` — **run quality gate commands, do not reason about whether they would pass. Paste exit codes and output.**86 - RELEASE: Read `references/release.md`87 - END-TO-END: Read `references/pipeline.md`88894. **Follow the loaded reference** exactly. Each reference contains the full phase instructions, gates, and checkpoints.9091## State Conventions9293Read `references/shared.md` for directory structure, state management commands, context loading rules, and naming conventions. All state operations go through `python3 ~/.claude/scripts/feature-state.py` -- never manipulate state files directly.9495## Phase Ordering9697```98DESIGN -> PLAN -> IMPLEMENT -> VALIDATE -> RELEASE99 | | | | |100 v v v v v101design.md plan.md impl.md report.md PR merged102```103104Each phase produces an artifact consumed by the next. Skipping phases is not supported because downstream phases depend on artifacts from earlier phases.105106## Reference Loading Table107108| Signal | Load These Files | Why |109|---|---|---|110| Phase 1 DESIGN: idea to design document | `design.md` | Loads detailed guidance from `design.md`. |111| Architecture Change Handoff targets feature-lifecycle | `design.md` | Validate and adopt architecture scope/interface/migration; create/register the feature ADR in DESIGN. |112| errors, error handling | `error-handling.md` | Loads detailed guidance from `error-handling.md`. |113| Phase 3 IMPLEMENT: dispatching task waves to domain agents | `implement.md` | Loads detailed guidance from `implement.md`. |114| running the full design-to-release pipeline | `pipeline.md` | Loads detailed guidance from `pipeline.md`. |115| Phase 2 PLAN: decomposing design into wave-ordered tasks | `plan.md` | Loads detailed guidance from `plan.md`. |116| Phase 5 RELEASE: PR merge, tagging, worktree cleanup | `release.md` | Loads detailed guidance from `release.md`. |117| feature state directory layout, naming, write protection | `shared.md` | Loads detailed guidance from `shared.md`. |118| Phase 4 VALIDATE: running quality gates | `validate.md` | Loads detailed guidance from `validate.md`. |119120## Error Handling121122| Error | Cause | Solution |123|-------|-------|----------|124| Phase mismatch | User requests phase N but state is at phase M | Report current state, suggest correct next phase |125| Missing artifact | Previous phase did not produce expected output | Route back to previous phase |126| Gate failure | Phase requirements not met | Report what failed, suggest fixes |127128## References129130| Task Signal | Load |131|-------------|------|132| Phase routing (design/plan/implement/validate/release) | Phase reference (design.md, plan.md, implement.md, validate.md, release.md) |133| End-to-end or full pipeline | `references/pipeline.md` |134| State commands, directory structure, naming | `references/shared.md` |135| Error, failure, blocked, gate fail, retry, deviation | `references/error-handling.md` |136137- `references/design.md` -- Design phase: explore requirements, discuss trade-offs138- `references/plan.md` -- Plan phase: break design into wave-ordered tasks139- `references/implement.md` -- Implement phase: dispatch tasks to domain agents140- `references/validate.md` -- Validate phase: run quality gates141- `references/release.md` -- Release phase: merge, tag, cleanup142- `references/pipeline.md` -- End-to-end orchestration across all phases143- `references/shared.md` -- State conventions shared across all phases144- `references/error-handling.md` -- Recovery patterns for phase errors, gate failures, agent dispatch failures