@leeovery/claude-technical-workflows 2.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/README.md +283 -0
- package/agents/chain-verifier.md +129 -0
- package/commands/interview.md +54 -0
- package/commands/start-discussion.md +36 -0
- package/commands/start-implementation.md +107 -0
- package/commands/start-planning.md +92 -0
- package/commands/start-research.md +21 -0
- package/commands/start-specification.md +89 -0
- package/package.json +24 -0
- package/skills/.gitkeep +0 -0
- package/skills/technical-discussion/SKILL.md +68 -0
- package/skills/technical-discussion/references/guidelines.md +86 -0
- package/skills/technical-discussion/references/meeting-assistant.md +102 -0
- package/skills/technical-discussion/references/template.md +127 -0
- package/skills/technical-implementation/SKILL.md +167 -0
- package/skills/technical-implementation/references/code-quality.md +41 -0
- package/skills/technical-implementation/references/environment-setup.md +97 -0
- package/skills/technical-implementation/references/plan-execution.md +49 -0
- package/skills/technical-implementation/references/tdd-workflow.md +63 -0
- package/skills/technical-planning/SKILL.md +46 -0
- package/skills/technical-planning/references/formal-planning.md +118 -0
- package/skills/technical-planning/references/output-backlog-md.md +227 -0
- package/skills/technical-planning/references/output-beads.md +302 -0
- package/skills/technical-planning/references/output-formats.md +14 -0
- package/skills/technical-planning/references/output-linear.md +211 -0
- package/skills/technical-planning/references/output-local-markdown.md +185 -0
- package/skills/technical-research/SKILL.md +81 -0
- package/skills/technical-review/SKILL.md +107 -0
- package/skills/technical-review/references/review-checklist.md +155 -0
- package/skills/technical-review/references/template.md +46 -0
- package/skills/technical-specification/SKILL.md +51 -0
- package/skills/technical-specification/references/specification-guide.md +170 -0
|
@@ -0,0 +1,167 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: technical-implementation
|
|
3
|
+
description: "Execute implementation plans using strict TDD workflow with quality gates. Fifth phase of research-discussion-specification-plan-implement-review workflow. Use when: (1) Implementing a plan from docs/workflow/planning/{topic}.md, (2) User says 'implement', 'build', or 'code this' after planning, (3) Ad hoc coding that should follow TDD and quality standards, (4) Bug fixes or features benefiting from structured implementation. Writes tests first, implements to pass, commits frequently, stops for user approval between phases."
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# Technical Implementation
|
|
7
|
+
|
|
8
|
+
Act as **expert senior developer** who builds quality software through disciplined TDD. Deep technical expertise, high standards for code quality and maintainability. Follow project-specific skills for language/framework conventions.
|
|
9
|
+
|
|
10
|
+
Execute plans through strict TDD. Write tests first, then code to pass them.
|
|
11
|
+
|
|
12
|
+
## Six-Phase Workflow
|
|
13
|
+
|
|
14
|
+
1. **Research** (previous): EXPLORE - ideas, feasibility, market, business, learning
|
|
15
|
+
2. **Discussion** (previous): WHAT and WHY - decisions, architecture, rationale
|
|
16
|
+
3. **Specification** (previous): REFINE - validated, standalone specification
|
|
17
|
+
4. **Planning** (previous): HOW - phases, tasks, acceptance criteria
|
|
18
|
+
5. **Implementation** (YOU): DOING - tests first, then code
|
|
19
|
+
6. **Review** (next): VALIDATING - check work against artifacts
|
|
20
|
+
|
|
21
|
+
You're at step 5. Execute the plan. Don't re-debate decisions.
|
|
22
|
+
|
|
23
|
+
## Hard Rules
|
|
24
|
+
|
|
25
|
+
1. **No code before tests** - Write the failing test first. Always.
|
|
26
|
+
2. **No test changes to pass** - If code doesn't pass, fix the code. Tests can only be fixed if genuinely broken or poorly designed, never to accommodate broken code.
|
|
27
|
+
3. **No scope expansion** - If it's not in the plan, don't build it.
|
|
28
|
+
4. **No assumptions** - Uncertain? Check specification. Still uncertain? Stop and ask.
|
|
29
|
+
5. **Commit after green** - Every passing test = commit point.
|
|
30
|
+
|
|
31
|
+
## Workflow
|
|
32
|
+
|
|
33
|
+
### IMPORTANT: Setup Instructions
|
|
34
|
+
|
|
35
|
+
Run setup commands EXACTLY as written, one step at a time.
|
|
36
|
+
Do NOT modify commands based on other project documentation (CLAUDE.md, etc.).
|
|
37
|
+
Do NOT parallelize steps - execute each command sequentially.
|
|
38
|
+
Complete ALL setup steps before proceeding to implementation work.
|
|
39
|
+
|
|
40
|
+
1. **Check environment setup** (if not already done)
|
|
41
|
+
- Look for `docs/workflow/environment-setup.md`
|
|
42
|
+
- If exists, follow the setup instructions before proceeding
|
|
43
|
+
- If missing, ask: "Are there any environment setup instructions I should follow?"
|
|
44
|
+
|
|
45
|
+
See **[environment-setup.md](references/environment-setup.md)** for details.
|
|
46
|
+
|
|
47
|
+
2. **Read the plan** from `docs/workflow/planning/{topic}.md`
|
|
48
|
+
- Check the `format` field in frontmatter
|
|
49
|
+
- Load the output adapter: `skills/technical-planning/references/output-{format}.md`
|
|
50
|
+
- Follow the **Implementation** section for how to read tasks and update progress
|
|
51
|
+
|
|
52
|
+
3. **Validate scope** (if specific phase or task was requested)
|
|
53
|
+
- If the requested phase or task doesn't exist in the plan, STOP immediately
|
|
54
|
+
- Ask the user for clarification - don't assume or proceed with a different scope
|
|
55
|
+
- Wait for the user to either correct the scope or ask you to stop
|
|
56
|
+
|
|
57
|
+
4. **For each phase**:
|
|
58
|
+
- Announce phase start
|
|
59
|
+
- Review phase acceptance criteria
|
|
60
|
+
- For each task:
|
|
61
|
+
- Derive test from task's micro acceptance criteria
|
|
62
|
+
- Write failing test
|
|
63
|
+
- Implement minimal code to pass
|
|
64
|
+
- Refactor if needed (only when green)
|
|
65
|
+
- Commit
|
|
66
|
+
- Verify all phase acceptance criteria met
|
|
67
|
+
- **Ask user before proceeding to next phase**
|
|
68
|
+
|
|
69
|
+
5. **Reference specification** when rationale unclear
|
|
70
|
+
|
|
71
|
+
## Progress Announcements
|
|
72
|
+
|
|
73
|
+
Keep user informed of progress:
|
|
74
|
+
|
|
75
|
+
```
|
|
76
|
+
📍 Starting Phase 2: Core Cache Functionality
|
|
77
|
+
📝 Task 1: Implement CacheManager.get()
|
|
78
|
+
🔴 Writing test: test_get_returns_cached_value
|
|
79
|
+
🟢 Test passing, committing...
|
|
80
|
+
✅ Phase 2 complete. Ready for Phase 3?
|
|
81
|
+
```
|
|
82
|
+
|
|
83
|
+
## When to Reference Specification
|
|
84
|
+
|
|
85
|
+
Check the specification (`docs/workflow/specification/{topic}.md`) when:
|
|
86
|
+
|
|
87
|
+
- Task rationale is unclear
|
|
88
|
+
- Multiple valid approaches exist
|
|
89
|
+
- Edge case handling not specified in plan
|
|
90
|
+
- You need the "why" behind a decision
|
|
91
|
+
|
|
92
|
+
The specification is the source of truth. Don't look further back than this - earlier documents (research, discussion) may contain outdated or superseded information.
|
|
93
|
+
|
|
94
|
+
## Project-Specific Conventions
|
|
95
|
+
|
|
96
|
+
Follow project-specific coding skills in `.claude/skills/` for:
|
|
97
|
+
|
|
98
|
+
- Framework patterns (Laravel, Vue, Python, etc.)
|
|
99
|
+
- Code style and formatting
|
|
100
|
+
- Architecture conventions
|
|
101
|
+
- Testing conventions
|
|
102
|
+
|
|
103
|
+
This skill provides the implementation **process**. Project skills provide the **style**.
|
|
104
|
+
|
|
105
|
+
## Handling Problems
|
|
106
|
+
|
|
107
|
+
### Plan is Incomplete
|
|
108
|
+
|
|
109
|
+
Stop and escalate:
|
|
110
|
+
> "Task X requires Y, but the plan doesn't specify how to handle it. Options: (A) ... (B) ... Which approach?"
|
|
111
|
+
|
|
112
|
+
### Plan Seems Wrong
|
|
113
|
+
|
|
114
|
+
Stop and escalate:
|
|
115
|
+
> "The plan says X, but during implementation I discovered Y. This affects Z. Should I continue as planned or revise?"
|
|
116
|
+
|
|
117
|
+
### Test Reveals Design Flaw
|
|
118
|
+
|
|
119
|
+
Stop and escalate:
|
|
120
|
+
> "Writing tests for X revealed that the approach won't work because Y. Need to revisit the design."
|
|
121
|
+
|
|
122
|
+
Never silently deviate from the plan.
|
|
123
|
+
|
|
124
|
+
## Quality Standards
|
|
125
|
+
|
|
126
|
+
See [code-quality.md](references/code-quality.md) for:
|
|
127
|
+
|
|
128
|
+
- DRY (without premature abstraction)
|
|
129
|
+
- SOLID principles
|
|
130
|
+
- Cyclomatic complexity
|
|
131
|
+
- YAGNI enforcement
|
|
132
|
+
|
|
133
|
+
## Phase Completion Checklist
|
|
134
|
+
|
|
135
|
+
Before marking a phase complete:
|
|
136
|
+
|
|
137
|
+
- [ ] All phase tasks implemented
|
|
138
|
+
- [ ] All tests passing
|
|
139
|
+
- [ ] Tests cover task acceptance criteria
|
|
140
|
+
- [ ] No skipped edge cases from plan
|
|
141
|
+
- [ ] Code committed
|
|
142
|
+
- [ ] Manual verification steps completed (if specified in plan)
|
|
143
|
+
|
|
144
|
+
## Commit Practices
|
|
145
|
+
|
|
146
|
+
- Commit after each passing test
|
|
147
|
+
- Use descriptive commit messages referencing the task
|
|
148
|
+
- Commits can be squashed before PR if desired
|
|
149
|
+
- Never commit failing tests (except intentional red phase in TDD)
|
|
150
|
+
|
|
151
|
+
Example commit message:
|
|
152
|
+
```
|
|
153
|
+
feat(cache): implement CacheManager.get() with TTL support
|
|
154
|
+
|
|
155
|
+
- Returns cached value if exists and not expired
|
|
156
|
+
- Falls back to DB on cache miss
|
|
157
|
+
- Handles connection failures gracefully
|
|
158
|
+
|
|
159
|
+
Task: Phase 2, Task 1
|
|
160
|
+
```
|
|
161
|
+
|
|
162
|
+
## References
|
|
163
|
+
|
|
164
|
+
- **[environment-setup.md](references/environment-setup.md)** - Environment setup before implementation
|
|
165
|
+
- **[plan-execution.md](references/plan-execution.md)** - Following plans, phase verification, hierarchy
|
|
166
|
+
- **[tdd-workflow.md](references/tdd-workflow.md)** - TDD cycle, test derivation, when tests can change
|
|
167
|
+
- **[code-quality.md](references/code-quality.md)** - DRY, SOLID, complexity, YAGNI
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
# Code Quality
|
|
2
|
+
|
|
3
|
+
*Reference for **[technical-implementation](../SKILL.md)***
|
|
4
|
+
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
Apply standard quality principles. Defer to project-specific skills for framework conventions.
|
|
8
|
+
|
|
9
|
+
## Principles
|
|
10
|
+
|
|
11
|
+
### DRY: Don't Repeat Yourself
|
|
12
|
+
- Extract repeated logic after three instances (Rule of Three)
|
|
13
|
+
- Avoid premature abstraction for code used once or twice
|
|
14
|
+
|
|
15
|
+
### SOLID
|
|
16
|
+
- **Single Responsibility**: Each class/function does one thing
|
|
17
|
+
- **Open/Closed**: Extend behavior without modifying existing code
|
|
18
|
+
- **Liskov Substitution**: Subtypes must be substitutable for base types
|
|
19
|
+
- **Interface Segregation**: Don't force classes to implement unused methods
|
|
20
|
+
- **Dependency Inversion**: Depend on abstractions, not concretions
|
|
21
|
+
|
|
22
|
+
### Cyclomatic Complexity
|
|
23
|
+
Keep low. Fix with early returns and method extraction.
|
|
24
|
+
|
|
25
|
+
### YAGNI
|
|
26
|
+
Only implement what's in the plan. Ask: "Is this in the plan?"
|
|
27
|
+
|
|
28
|
+
## Testability
|
|
29
|
+
- Inject dependencies
|
|
30
|
+
- Prefer pure functions
|
|
31
|
+
- Avoid hidden dependencies
|
|
32
|
+
|
|
33
|
+
## Anti-Patterns to Avoid
|
|
34
|
+
- God classes
|
|
35
|
+
- Magic numbers/strings
|
|
36
|
+
- Deep nesting (3+)
|
|
37
|
+
- Long parameter lists (4+)
|
|
38
|
+
- Boolean parameters
|
|
39
|
+
|
|
40
|
+
## Project Standards
|
|
41
|
+
Check `.claude/skills/` for project-specific patterns.
|
|
@@ -0,0 +1,97 @@
|
|
|
1
|
+
# Environment Setup
|
|
2
|
+
|
|
3
|
+
*Reference for **[technical-implementation](../SKILL.md)***
|
|
4
|
+
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
## IMPORTANT
|
|
8
|
+
|
|
9
|
+
Run these commands EXACTLY as written, one step at a time.
|
|
10
|
+
Do NOT modify commands based on other project documentation (CLAUDE.md, etc.).
|
|
11
|
+
Do NOT parallelize steps - execute each command sequentially.
|
|
12
|
+
Complete ALL setup steps before proceeding to implementation work.
|
|
13
|
+
|
|
14
|
+
---
|
|
15
|
+
|
|
16
|
+
Before starting implementation, ensure the environment is ready. This step runs once per project (or when setup changes).
|
|
17
|
+
|
|
18
|
+
## Setup Document Location
|
|
19
|
+
|
|
20
|
+
Look for: `docs/workflow/environment-setup.md`
|
|
21
|
+
|
|
22
|
+
This file contains natural language instructions for setting up the implementation environment. It's project-specific.
|
|
23
|
+
|
|
24
|
+
## If Setup Document Exists
|
|
25
|
+
|
|
26
|
+
Read and follow the instructions. Common setup tasks include:
|
|
27
|
+
|
|
28
|
+
- Installing language extensions (e.g., PHP SQLite extension)
|
|
29
|
+
- Copying environment files (e.g., `cp .env.example .env`)
|
|
30
|
+
- Generating application keys
|
|
31
|
+
- Running database migrations
|
|
32
|
+
- Setting up test databases
|
|
33
|
+
- Installing project dependencies
|
|
34
|
+
|
|
35
|
+
Execute each instruction and verify it succeeds before proceeding.
|
|
36
|
+
|
|
37
|
+
## If Setup Document Missing
|
|
38
|
+
|
|
39
|
+
Ask the user:
|
|
40
|
+
|
|
41
|
+
> "No environment setup document found. Are there any setup instructions I should follow before implementing?"
|
|
42
|
+
|
|
43
|
+
If they provide instructions, offer to save them:
|
|
44
|
+
|
|
45
|
+
> "Would you like me to save these instructions to `docs/workflow/environment-setup.md` for future sessions?"
|
|
46
|
+
|
|
47
|
+
## Plan Format Setup
|
|
48
|
+
|
|
49
|
+
Some plan formats require specific tools. Check the plan's `format` field and load the corresponding output adapter from the planning skill for setup instructions:
|
|
50
|
+
|
|
51
|
+
```
|
|
52
|
+
skills/technical-planning/references/output-{format}.md
|
|
53
|
+
```
|
|
54
|
+
|
|
55
|
+
Each output adapter contains prerequisites and installation instructions for that format.
|
|
56
|
+
|
|
57
|
+
## Example Setup Document
|
|
58
|
+
|
|
59
|
+
```markdown
|
|
60
|
+
# Environment Setup
|
|
61
|
+
|
|
62
|
+
Instructions for setting up the implementation environment.
|
|
63
|
+
|
|
64
|
+
## First-Time Setup
|
|
65
|
+
|
|
66
|
+
1. Copy environment file:
|
|
67
|
+
```bash
|
|
68
|
+
cp .env.example .env
|
|
69
|
+
```
|
|
70
|
+
|
|
71
|
+
2. Generate application key:
|
|
72
|
+
```bash
|
|
73
|
+
php artisan key:generate
|
|
74
|
+
```
|
|
75
|
+
|
|
76
|
+
3. Set up test database:
|
|
77
|
+
```bash
|
|
78
|
+
touch database/testing.sqlite
|
|
79
|
+
php artisan migrate --env=testing
|
|
80
|
+
```
|
|
81
|
+
|
|
82
|
+
## Claude Code on the Web
|
|
83
|
+
|
|
84
|
+
Additional setup for web-based Claude Code sessions:
|
|
85
|
+
|
|
86
|
+
1. Install PHP SQLite extension:
|
|
87
|
+
```bash
|
|
88
|
+
sudo apt-get update && sudo apt-get install -y php-sqlite3
|
|
89
|
+
```
|
|
90
|
+
|
|
91
|
+
## Verification
|
|
92
|
+
|
|
93
|
+
Run tests to verify setup:
|
|
94
|
+
```bash
|
|
95
|
+
php artisan test
|
|
96
|
+
```
|
|
97
|
+
```
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
# Plan Execution
|
|
2
|
+
|
|
3
|
+
*Reference for **[technical-implementation](../SKILL.md)***
|
|
4
|
+
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
## Plan Structure
|
|
8
|
+
|
|
9
|
+
Plans live in `docs/workflow/planning/{topic}.md` with phases and tasks.
|
|
10
|
+
|
|
11
|
+
**Phase** = grouping with acceptance criteria
|
|
12
|
+
**Task** = single TDD cycle = one commit
|
|
13
|
+
|
|
14
|
+
## Before Starting
|
|
15
|
+
|
|
16
|
+
1. Read entire plan
|
|
17
|
+
2. Read specification for context
|
|
18
|
+
3. Check dependencies and blockers
|
|
19
|
+
|
|
20
|
+
## Execution Flow
|
|
21
|
+
|
|
22
|
+
For each phase:
|
|
23
|
+
1. Announce phase start with acceptance criteria
|
|
24
|
+
2. For each task: derive test → write failing test → implement → commit
|
|
25
|
+
3. Verify all acceptance criteria met
|
|
26
|
+
4. **Wait for user confirmation before next phase**
|
|
27
|
+
|
|
28
|
+
## Referencing Specification
|
|
29
|
+
|
|
30
|
+
Check `docs/workflow/specification/{topic}.md` when:
|
|
31
|
+
- Task rationale unclear
|
|
32
|
+
- Multiple valid approaches
|
|
33
|
+
- Edge case handling not specified
|
|
34
|
+
|
|
35
|
+
The specification is the source of truth. Don't look further back than this.
|
|
36
|
+
|
|
37
|
+
## Handling Problems
|
|
38
|
+
|
|
39
|
+
- **Plan incomplete**: Stop and escalate with options
|
|
40
|
+
- **Plan seems wrong**: Stop and escalate discrepancy
|
|
41
|
+
- **Discovery during implementation**: Stop and escalate impact
|
|
42
|
+
|
|
43
|
+
**Never silently deviate.**
|
|
44
|
+
|
|
45
|
+
## Context Refresh Recovery
|
|
46
|
+
|
|
47
|
+
1. Check `git log` for recent commits
|
|
48
|
+
2. Find current phase/task in plan
|
|
49
|
+
3. Resume from last committed task
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
# TDD Workflow
|
|
2
|
+
|
|
3
|
+
*Reference for **[technical-implementation](../SKILL.md)***
|
|
4
|
+
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
## The Cycle
|
|
8
|
+
|
|
9
|
+
RED → GREEN → REFACTOR → COMMIT
|
|
10
|
+
|
|
11
|
+
Repeat for each task.
|
|
12
|
+
|
|
13
|
+
## RED: Write Failing Test
|
|
14
|
+
|
|
15
|
+
1. Read task's micro acceptance criteria
|
|
16
|
+
2. Write test asserting that behavior
|
|
17
|
+
3. Run test - must fail
|
|
18
|
+
4. Verify it fails for the right reason
|
|
19
|
+
|
|
20
|
+
**Derive tests from plan**: Task's micro acceptance becomes your first test. Edge cases become additional tests.
|
|
21
|
+
|
|
22
|
+
**Write test names first**: List all test names before writing bodies. Confirm coverage matches acceptance criteria.
|
|
23
|
+
|
|
24
|
+
## GREEN: Minimal Implementation
|
|
25
|
+
|
|
26
|
+
Write the simplest code that passes:
|
|
27
|
+
- No extra features
|
|
28
|
+
- No "while I'm here" improvements
|
|
29
|
+
- No edge cases not yet tested
|
|
30
|
+
|
|
31
|
+
If you think "I should also handle X" - stop. Write a test for X first.
|
|
32
|
+
|
|
33
|
+
**One test at a time**: Write → Pass → Commit → Next
|
|
34
|
+
|
|
35
|
+
## REFACTOR: Only When Green
|
|
36
|
+
|
|
37
|
+
**Do**: Remove duplication, improve naming, extract methods
|
|
38
|
+
**Don't**: Touch code outside current task, optimize prematurely
|
|
39
|
+
|
|
40
|
+
Run tests after. If they fail, undo.
|
|
41
|
+
|
|
42
|
+
## COMMIT: After Every Green
|
|
43
|
+
|
|
44
|
+
Commit with descriptive message referencing the task.
|
|
45
|
+
|
|
46
|
+
## When Tests CAN Change
|
|
47
|
+
|
|
48
|
+
- Genuine bug in test
|
|
49
|
+
- Tests implementation not behavior
|
|
50
|
+
- Missing setup/fixtures
|
|
51
|
+
|
|
52
|
+
## When Tests CANNOT Change
|
|
53
|
+
|
|
54
|
+
- To make broken code pass (fix the code)
|
|
55
|
+
- To avoid difficult work (the test is the requirement)
|
|
56
|
+
- To skip temporarily (fix or escalate)
|
|
57
|
+
|
|
58
|
+
## Red Flags
|
|
59
|
+
|
|
60
|
+
- Wrote code before test → delete code, write test first
|
|
61
|
+
- Multiple failing tests → work on one at a time
|
|
62
|
+
- Test passes immediately → investigate
|
|
63
|
+
- Changing tests frequently → design unclear, review plan
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: technical-planning
|
|
3
|
+
description: "Transform specifications into actionable implementation plans with phases, tasks, and acceptance criteria. Fourth phase of research-discussion-specification-plan-implement-review workflow. Use when: (1) User asks to create/write an implementation plan, (2) User asks to plan implementation after specification is complete, (3) Converting specifications from docs/workflow/specification/{topic}.md into implementation plans, (4) User says 'plan this' or 'create a plan' after specification, (5) Need to structure how to build something with phases and concrete steps. Creates plans in docs/workflow/planning/{topic}.md that implementation phase executes via strict TDD."
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# Technical Planning
|
|
7
|
+
|
|
8
|
+
Act as **expert technical architect**, **product owner**, and **plan documenter**. Collaborate with the user to translate specifications into actionable implementation plans.
|
|
9
|
+
|
|
10
|
+
Your role spans product (WHAT we're building and WHY) and technical (HOW to structure the work).
|
|
11
|
+
|
|
12
|
+
## Six-Phase Workflow
|
|
13
|
+
|
|
14
|
+
1. **Research** (previous): EXPLORE - ideas, feasibility, market, business, learning
|
|
15
|
+
2. **Discussion** (previous): WHAT and WHY - decisions, architecture, edge cases
|
|
16
|
+
3. **Specification** (previous): REFINE - validated, standalone specification
|
|
17
|
+
4. **Planning** (YOU): HOW - phases, tasks, acceptance criteria
|
|
18
|
+
5. **Implementation** (next): DOING - tests first, then code
|
|
19
|
+
6. **Review** (final): VALIDATING - check work against artifacts
|
|
20
|
+
|
|
21
|
+
You're at step 4. Create the plan. Don't jump to implementation.
|
|
22
|
+
|
|
23
|
+
## Source Material
|
|
24
|
+
|
|
25
|
+
Plans are built **exclusively** from the specification:
|
|
26
|
+
- **Specification** (`docs/workflow/specification/{topic}.md`)
|
|
27
|
+
|
|
28
|
+
The specification is the **sole source of truth**. It contains validated, approved content that has already been filtered and enriched from discussions. Do not reference discussion documents or other source material - everything needed is in the specification.
|
|
29
|
+
|
|
30
|
+
## The Process
|
|
31
|
+
|
|
32
|
+
**Load**: [formal-planning.md](references/formal-planning.md)
|
|
33
|
+
|
|
34
|
+
**Choose output format**: Ask user which format, then load the appropriate output adapter. See **[output-formats.md](references/output-formats.md)** for available formats.
|
|
35
|
+
|
|
36
|
+
**Output**: Implementation plan in chosen format
|
|
37
|
+
|
|
38
|
+
## Critical Rules
|
|
39
|
+
|
|
40
|
+
**Capture immediately**: After each user response, update the planning document BEFORE your next question. Never let more than 2-3 exchanges pass without writing.
|
|
41
|
+
|
|
42
|
+
**Commit frequently**: Commit at natural breaks, after significant exchanges, and before any context refresh. Context refresh = lost work.
|
|
43
|
+
|
|
44
|
+
**Never invent reasoning**: If it's not in the specification, ask again.
|
|
45
|
+
|
|
46
|
+
**Create plans, not code**: Your job is phases, tasks, and acceptance criteria - not implementation.
|
|
@@ -0,0 +1,118 @@
|
|
|
1
|
+
# Formal Planning
|
|
2
|
+
|
|
3
|
+
*Reference for **[technical-planning](../SKILL.md)***
|
|
4
|
+
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
You are creating the formal implementation plan from the specification.
|
|
8
|
+
|
|
9
|
+
## Before You Begin
|
|
10
|
+
|
|
11
|
+
**Confirm output format with user.** Ask which format they want, then load the appropriate output adapter from the main skill file. If you don't know which format, ask.
|
|
12
|
+
|
|
13
|
+
## The Planning Process
|
|
14
|
+
|
|
15
|
+
### 1. Read Specification
|
|
16
|
+
|
|
17
|
+
From the specification (`docs/workflow/specification/{topic}.md`), extract:
|
|
18
|
+
- Key decisions and rationale
|
|
19
|
+
- Architectural choices
|
|
20
|
+
- Edge cases identified
|
|
21
|
+
- Constraints and requirements
|
|
22
|
+
|
|
23
|
+
**The specification is your sole input.** Discussion documents and other source materials have already been validated, filtered, and enriched during the specification phase. Everything you need is in the specification - do not reference other documents.
|
|
24
|
+
|
|
25
|
+
### 2. Define Phases
|
|
26
|
+
|
|
27
|
+
Break into logical phases:
|
|
28
|
+
- Each independently testable
|
|
29
|
+
- Each has acceptance criteria
|
|
30
|
+
- Progression: Foundation → Core → Edge cases → Refinement
|
|
31
|
+
|
|
32
|
+
### 3. Break Phases into Tasks
|
|
33
|
+
|
|
34
|
+
Each task is one TDD cycle:
|
|
35
|
+
- One clear thing to build
|
|
36
|
+
- One test to prove it works
|
|
37
|
+
|
|
38
|
+
### 4. Write Micro Acceptance
|
|
39
|
+
|
|
40
|
+
For each task, name the test that proves completion. Implementation writes this test first.
|
|
41
|
+
|
|
42
|
+
### 5. Address Every Edge Case
|
|
43
|
+
|
|
44
|
+
Extract each edge case, create a task with micro acceptance.
|
|
45
|
+
|
|
46
|
+
### 6. Add Code Examples (if needed)
|
|
47
|
+
|
|
48
|
+
Only for novel patterns not obvious to implement.
|
|
49
|
+
|
|
50
|
+
### 7. Review Against Specification
|
|
51
|
+
|
|
52
|
+
Verify:
|
|
53
|
+
- All decisions referenced
|
|
54
|
+
- All edge cases have tasks
|
|
55
|
+
- Each phase has acceptance criteria
|
|
56
|
+
- Each task has micro acceptance
|
|
57
|
+
|
|
58
|
+
## Phase Design
|
|
59
|
+
|
|
60
|
+
**Each phase should**:
|
|
61
|
+
- Be independently testable
|
|
62
|
+
- Have clear acceptance criteria (checkboxes)
|
|
63
|
+
- Provide incremental value
|
|
64
|
+
|
|
65
|
+
**Progression**: Foundation → Core functionality → Edge cases → Refinement
|
|
66
|
+
|
|
67
|
+
## Task Design
|
|
68
|
+
|
|
69
|
+
**Each task should**:
|
|
70
|
+
- Be a single TDD cycle
|
|
71
|
+
- Have micro acceptance (specific test name)
|
|
72
|
+
- Do one clear thing
|
|
73
|
+
|
|
74
|
+
**One task = One TDD cycle**: write test → implement → pass → commit
|
|
75
|
+
|
|
76
|
+
## Plan as Source of Truth
|
|
77
|
+
|
|
78
|
+
The plan IS the source of truth. Every phase, every task must contain all information needed to execute it.
|
|
79
|
+
|
|
80
|
+
- **Self-contained**: Each task executable without external context
|
|
81
|
+
- **No assumptions**: Spell out the context, don't assume implementer knows it
|
|
82
|
+
|
|
83
|
+
## Flagging Incomplete Tasks
|
|
84
|
+
|
|
85
|
+
When information is missing, mark it clearly with `[needs-info]`:
|
|
86
|
+
|
|
87
|
+
```markdown
|
|
88
|
+
### Task 3: Configure rate limiting [needs-info]
|
|
89
|
+
|
|
90
|
+
**Do**: Set up rate limiting for the API endpoint
|
|
91
|
+
**Test**: `it throttles requests exceeding limit`
|
|
92
|
+
|
|
93
|
+
**Needs clarification**:
|
|
94
|
+
- What's the rate limit threshold?
|
|
95
|
+
- Per-user or per-IP?
|
|
96
|
+
```
|
|
97
|
+
|
|
98
|
+
Planning is iterative. Create structure, flag gaps, refine.
|
|
99
|
+
|
|
100
|
+
## Quality Checklist
|
|
101
|
+
|
|
102
|
+
Before handing off to implementation:
|
|
103
|
+
|
|
104
|
+
- [ ] Clear phases with acceptance criteria
|
|
105
|
+
- [ ] Each phase has TDD-sized tasks
|
|
106
|
+
- [ ] Each task has micro acceptance (test name)
|
|
107
|
+
- [ ] All edge cases mapped to tasks
|
|
108
|
+
- [ ] Gaps flagged with `[needs-info]`
|
|
109
|
+
|
|
110
|
+
## Commit Frequently
|
|
111
|
+
|
|
112
|
+
Commit planning docs at natural breaks, after significant progress, and before any context refresh.
|
|
113
|
+
|
|
114
|
+
Context refresh = memory loss. Uncommitted work = lost work.
|
|
115
|
+
|
|
116
|
+
## Output
|
|
117
|
+
|
|
118
|
+
Load the appropriate output adapter (linked from the main skill file) for format-specific structure and templates.
|