pmp-gywd 3.3.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 +27 -0
- package/README.md +567 -0
- package/bin/install.js +348 -0
- package/commands/gywd/add-phase.md +207 -0
- package/commands/gywd/anticipate.md +271 -0
- package/commands/gywd/bootstrap.md +336 -0
- package/commands/gywd/challenge.md +344 -0
- package/commands/gywd/check-drift.md +144 -0
- package/commands/gywd/complete-milestone.md +106 -0
- package/commands/gywd/consider-issues.md +202 -0
- package/commands/gywd/context.md +93 -0
- package/commands/gywd/create-roadmap.md +115 -0
- package/commands/gywd/deps.md +169 -0
- package/commands/gywd/digest.md +138 -0
- package/commands/gywd/discuss-milestone.md +47 -0
- package/commands/gywd/discuss-phase.md +60 -0
- package/commands/gywd/execute-plan.md +161 -0
- package/commands/gywd/extract-decisions.md +325 -0
- package/commands/gywd/health.md +150 -0
- package/commands/gywd/help.md +556 -0
- package/commands/gywd/history.md +278 -0
- package/commands/gywd/impact.md +317 -0
- package/commands/gywd/init.md +95 -0
- package/commands/gywd/insert-phase.md +227 -0
- package/commands/gywd/list-phase-assumptions.md +50 -0
- package/commands/gywd/map-codebase.md +84 -0
- package/commands/gywd/memory.md +159 -0
- package/commands/gywd/new-milestone.md +59 -0
- package/commands/gywd/new-project.md +315 -0
- package/commands/gywd/pause-work.md +123 -0
- package/commands/gywd/plan-fix.md +205 -0
- package/commands/gywd/plan-phase.md +93 -0
- package/commands/gywd/preview-plan.md +139 -0
- package/commands/gywd/profile.md +363 -0
- package/commands/gywd/progress.md +317 -0
- package/commands/gywd/remove-phase.md +338 -0
- package/commands/gywd/research-phase.md +91 -0
- package/commands/gywd/resume-work.md +40 -0
- package/commands/gywd/rollback.md +179 -0
- package/commands/gywd/status.md +42 -0
- package/commands/gywd/sync-github.md +234 -0
- package/commands/gywd/verify-work.md +71 -0
- package/commands/gywd/why.md +251 -0
- package/docs/COMMANDS.md +722 -0
- package/docs/CONTRIBUTING.md +342 -0
- package/docs/EXAMPLES.md +535 -0
- package/docs/GETTING-STARTED.md +262 -0
- package/docs/README.md +55 -0
- package/docs/RELEASING.md +159 -0
- package/get-your-work-done/core/agent-patterns.md +331 -0
- package/get-your-work-done/core/architecture.md +334 -0
- package/get-your-work-done/core/context-model-schema.json +154 -0
- package/get-your-work-done/core/decisions-schema.json +193 -0
- package/get-your-work-done/core/learning-state-schema.json +133 -0
- package/get-your-work-done/core/profile-schema.json +257 -0
- package/get-your-work-done/references/adaptive-decomposition.md +175 -0
- package/get-your-work-done/references/checkpoints.md +287 -0
- package/get-your-work-done/references/confidence-scoring.md +169 -0
- package/get-your-work-done/references/continuation-format.md +255 -0
- package/get-your-work-done/references/git-integration.md +254 -0
- package/get-your-work-done/references/plan-format.md +428 -0
- package/get-your-work-done/references/principles.md +157 -0
- package/get-your-work-done/references/questioning.md +162 -0
- package/get-your-work-done/references/research-pitfalls.md +215 -0
- package/get-your-work-done/references/scope-estimation.md +172 -0
- package/get-your-work-done/references/tdd.md +263 -0
- package/get-your-work-done/templates/codebase/architecture.md +255 -0
- package/get-your-work-done/templates/codebase/concerns.md +310 -0
- package/get-your-work-done/templates/codebase/conventions.md +307 -0
- package/get-your-work-done/templates/codebase/integrations.md +280 -0
- package/get-your-work-done/templates/codebase/stack.md +186 -0
- package/get-your-work-done/templates/codebase/structure.md +285 -0
- package/get-your-work-done/templates/codebase/testing.md +480 -0
- package/get-your-work-done/templates/config.json +18 -0
- package/get-your-work-done/templates/context.md +161 -0
- package/get-your-work-done/templates/continue-here.md +78 -0
- package/get-your-work-done/templates/discovery.md +146 -0
- package/get-your-work-done/templates/issues.md +32 -0
- package/get-your-work-done/templates/milestone-archive.md +123 -0
- package/get-your-work-done/templates/milestone-context.md +93 -0
- package/get-your-work-done/templates/milestone.md +115 -0
- package/get-your-work-done/templates/phase-prompt.md +303 -0
- package/get-your-work-done/templates/project.md +184 -0
- package/get-your-work-done/templates/research.md +529 -0
- package/get-your-work-done/templates/roadmap.md +196 -0
- package/get-your-work-done/templates/state.md +210 -0
- package/get-your-work-done/templates/summary.md +273 -0
- package/get-your-work-done/templates/uat-issues.md +143 -0
- package/get-your-work-done/workflows/complete-milestone.md +643 -0
- package/get-your-work-done/workflows/create-milestone.md +416 -0
- package/get-your-work-done/workflows/create-roadmap.md +481 -0
- package/get-your-work-done/workflows/discovery-phase.md +293 -0
- package/get-your-work-done/workflows/discuss-milestone.md +236 -0
- package/get-your-work-done/workflows/discuss-phase.md +247 -0
- package/get-your-work-done/workflows/execute-phase.md +1625 -0
- package/get-your-work-done/workflows/list-phase-assumptions.md +178 -0
- package/get-your-work-done/workflows/map-codebase.md +434 -0
- package/get-your-work-done/workflows/plan-phase.md +488 -0
- package/get-your-work-done/workflows/research-phase.md +436 -0
- package/get-your-work-done/workflows/resume-project.md +287 -0
- package/get-your-work-done/workflows/transition.md +580 -0
- package/get-your-work-done/workflows/verify-work.md +202 -0
- package/lib/automation/dependency-analyzer.js +635 -0
- package/lib/automation/doc-generator.js +643 -0
- package/lib/automation/index.js +42 -0
- package/lib/automation/test-generator.js +628 -0
- package/lib/context/context-analyzer.js +554 -0
- package/lib/context/context-cache.js +426 -0
- package/lib/context/context-predictor.js +622 -0
- package/lib/context/index.js +44 -0
- package/lib/memory/confidence-calibrator.js +484 -0
- package/lib/memory/feedback-collector.js +551 -0
- package/lib/memory/global-memory.js +465 -0
- package/lib/memory/index.js +75 -0
- package/lib/memory/pattern-aggregator.js +487 -0
- package/lib/memory/team-sync.js +501 -0
- package/lib/profile/index.js +24 -0
- package/lib/profile/pattern-learner.js +303 -0
- package/lib/profile/profile-manager.js +445 -0
- package/lib/questioning/index.js +49 -0
- package/lib/questioning/question-engine.js +311 -0
- package/lib/questioning/question-templates.js +315 -0
- package/lib/validators/command-validator.js +188 -0
- package/lib/validators/index.js +29 -0
- package/lib/validators/schema-validator.js +183 -0
- package/package.json +61 -0
|
@@ -0,0 +1,257 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "http://json-schema.org/draft-07/schema#",
|
|
3
|
+
"title": "GYWD Developer Profile Schema",
|
|
4
|
+
"description": "Schema for the Developer Digital Twin",
|
|
5
|
+
"type": "object",
|
|
6
|
+
"properties": {
|
|
7
|
+
"version": {
|
|
8
|
+
"type": "string",
|
|
9
|
+
"const": "2.0.0"
|
|
10
|
+
},
|
|
11
|
+
"metadata": {
|
|
12
|
+
"type": "object",
|
|
13
|
+
"properties": {
|
|
14
|
+
"developer": { "type": "string" },
|
|
15
|
+
"created_at": { "type": "string", "format": "date-time" },
|
|
16
|
+
"last_updated": { "type": "string", "format": "date-time" },
|
|
17
|
+
"data_sources": {
|
|
18
|
+
"type": "array",
|
|
19
|
+
"items": {
|
|
20
|
+
"enum": ["git_history", "code_patterns", "explicit_input", "behavior_observation"]
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
},
|
|
25
|
+
"cognitive": {
|
|
26
|
+
"type": "object",
|
|
27
|
+
"description": "Cognitive fingerprint - how the developer thinks",
|
|
28
|
+
"properties": {
|
|
29
|
+
"problem_approach": {
|
|
30
|
+
"type": "object",
|
|
31
|
+
"properties": {
|
|
32
|
+
"style": {
|
|
33
|
+
"enum": ["top_down", "bottom_up", "middle_out", "mixed"],
|
|
34
|
+
"description": "How they typically approach problems"
|
|
35
|
+
},
|
|
36
|
+
"confidence": { "type": "number" }
|
|
37
|
+
}
|
|
38
|
+
},
|
|
39
|
+
"abstraction_preference": {
|
|
40
|
+
"type": "object",
|
|
41
|
+
"properties": {
|
|
42
|
+
"level": {
|
|
43
|
+
"enum": ["concrete", "abstract", "balanced"],
|
|
44
|
+
"description": "Preference for concrete vs abstract thinking"
|
|
45
|
+
},
|
|
46
|
+
"confidence": { "type": "number" }
|
|
47
|
+
}
|
|
48
|
+
},
|
|
49
|
+
"detail_orientation": {
|
|
50
|
+
"type": "object",
|
|
51
|
+
"properties": {
|
|
52
|
+
"level": {
|
|
53
|
+
"enum": ["big_picture", "detail_focused", "balanced"],
|
|
54
|
+
"description": "Focus on details vs big picture"
|
|
55
|
+
},
|
|
56
|
+
"confidence": { "type": "number" }
|
|
57
|
+
}
|
|
58
|
+
},
|
|
59
|
+
"risk_tolerance": {
|
|
60
|
+
"type": "object",
|
|
61
|
+
"properties": {
|
|
62
|
+
"level": {
|
|
63
|
+
"enum": ["conservative", "moderate", "aggressive"],
|
|
64
|
+
"description": "Willingness to take technical risks"
|
|
65
|
+
},
|
|
66
|
+
"confidence": { "type": "number" }
|
|
67
|
+
}
|
|
68
|
+
},
|
|
69
|
+
"learning_style": {
|
|
70
|
+
"type": "object",
|
|
71
|
+
"properties": {
|
|
72
|
+
"preference": {
|
|
73
|
+
"enum": ["documentation", "examples", "experimentation", "discussion"],
|
|
74
|
+
"description": "How they prefer to learn new things"
|
|
75
|
+
},
|
|
76
|
+
"confidence": { "type": "number" }
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
},
|
|
81
|
+
"expertise": {
|
|
82
|
+
"type": "object",
|
|
83
|
+
"description": "Expertise topology - what they know well",
|
|
84
|
+
"properties": {
|
|
85
|
+
"languages": {
|
|
86
|
+
"type": "array",
|
|
87
|
+
"items": {
|
|
88
|
+
"type": "object",
|
|
89
|
+
"properties": {
|
|
90
|
+
"name": { "type": "string" },
|
|
91
|
+
"proficiency": { "enum": ["novice", "intermediate", "advanced", "expert"] },
|
|
92
|
+
"lines_written": { "type": "integer" },
|
|
93
|
+
"confidence": { "type": "number" }
|
|
94
|
+
}
|
|
95
|
+
}
|
|
96
|
+
},
|
|
97
|
+
"frameworks": {
|
|
98
|
+
"type": "array",
|
|
99
|
+
"items": {
|
|
100
|
+
"type": "object",
|
|
101
|
+
"properties": {
|
|
102
|
+
"name": { "type": "string" },
|
|
103
|
+
"proficiency": { "enum": ["novice", "intermediate", "advanced", "expert"] },
|
|
104
|
+
"usage_count": { "type": "integer" },
|
|
105
|
+
"confidence": { "type": "number" }
|
|
106
|
+
}
|
|
107
|
+
}
|
|
108
|
+
},
|
|
109
|
+
"domains": {
|
|
110
|
+
"type": "array",
|
|
111
|
+
"items": {
|
|
112
|
+
"type": "object",
|
|
113
|
+
"properties": {
|
|
114
|
+
"name": { "type": "string" },
|
|
115
|
+
"depth": { "enum": ["surface", "working", "deep", "expert"] },
|
|
116
|
+
"evidence": { "type": "array", "items": { "type": "string" } },
|
|
117
|
+
"confidence": { "type": "number" }
|
|
118
|
+
}
|
|
119
|
+
}
|
|
120
|
+
},
|
|
121
|
+
"architectural_patterns": {
|
|
122
|
+
"type": "array",
|
|
123
|
+
"items": {
|
|
124
|
+
"type": "object",
|
|
125
|
+
"properties": {
|
|
126
|
+
"pattern": { "type": "string" },
|
|
127
|
+
"familiarity": { "enum": ["aware", "used", "proficient", "expert"] },
|
|
128
|
+
"times_applied": { "type": "integer" }
|
|
129
|
+
}
|
|
130
|
+
}
|
|
131
|
+
}
|
|
132
|
+
}
|
|
133
|
+
},
|
|
134
|
+
"preferences": {
|
|
135
|
+
"type": "object",
|
|
136
|
+
"description": "Style and workflow preferences",
|
|
137
|
+
"properties": {
|
|
138
|
+
"code_style": {
|
|
139
|
+
"type": "object",
|
|
140
|
+
"properties": {
|
|
141
|
+
"naming_convention": {
|
|
142
|
+
"enum": ["camelCase", "snake_case", "PascalCase", "mixed"],
|
|
143
|
+
"description": "Preferred naming convention"
|
|
144
|
+
},
|
|
145
|
+
"comment_density": {
|
|
146
|
+
"enum": ["minimal", "moderate", "heavy"],
|
|
147
|
+
"description": "How much they comment code"
|
|
148
|
+
},
|
|
149
|
+
"function_size": {
|
|
150
|
+
"enum": ["small", "medium", "large"],
|
|
151
|
+
"description": "Typical function length preference"
|
|
152
|
+
},
|
|
153
|
+
"abstraction_eagerness": {
|
|
154
|
+
"enum": ["early", "when_needed", "late"],
|
|
155
|
+
"description": "When they create abstractions"
|
|
156
|
+
}
|
|
157
|
+
}
|
|
158
|
+
},
|
|
159
|
+
"workflow": {
|
|
160
|
+
"type": "object",
|
|
161
|
+
"properties": {
|
|
162
|
+
"commit_frequency": {
|
|
163
|
+
"enum": ["frequent_small", "moderate", "large_batches"],
|
|
164
|
+
"description": "How often they commit"
|
|
165
|
+
},
|
|
166
|
+
"test_approach": {
|
|
167
|
+
"enum": ["tdd", "test_after", "minimal_testing"],
|
|
168
|
+
"description": "Testing approach"
|
|
169
|
+
},
|
|
170
|
+
"documentation_timing": {
|
|
171
|
+
"enum": ["upfront", "as_you_go", "after_implementation"],
|
|
172
|
+
"description": "When they write docs"
|
|
173
|
+
},
|
|
174
|
+
"review_preference": {
|
|
175
|
+
"enum": ["self_review", "peer_review", "automated_only"],
|
|
176
|
+
"description": "Code review preferences"
|
|
177
|
+
}
|
|
178
|
+
}
|
|
179
|
+
},
|
|
180
|
+
"communication": {
|
|
181
|
+
"type": "object",
|
|
182
|
+
"properties": {
|
|
183
|
+
"detail_level": {
|
|
184
|
+
"enum": ["brief", "moderate", "detailed"],
|
|
185
|
+
"description": "How much detail they want in explanations"
|
|
186
|
+
},
|
|
187
|
+
"format_preference": {
|
|
188
|
+
"enum": ["prose", "bullets", "code_examples", "mixed"],
|
|
189
|
+
"description": "Preferred output format"
|
|
190
|
+
},
|
|
191
|
+
"interruption_tolerance": {
|
|
192
|
+
"enum": ["low", "medium", "high"],
|
|
193
|
+
"description": "Tolerance for confirmations/questions"
|
|
194
|
+
}
|
|
195
|
+
}
|
|
196
|
+
}
|
|
197
|
+
}
|
|
198
|
+
},
|
|
199
|
+
"work_patterns": {
|
|
200
|
+
"type": "object",
|
|
201
|
+
"description": "Temporal and behavioral patterns",
|
|
202
|
+
"properties": {
|
|
203
|
+
"active_hours": {
|
|
204
|
+
"type": "array",
|
|
205
|
+
"items": {
|
|
206
|
+
"type": "object",
|
|
207
|
+
"properties": {
|
|
208
|
+
"day": { "enum": ["monday", "tuesday", "wednesday", "thursday", "friday", "saturday", "sunday"] },
|
|
209
|
+
"peak_hours": { "type": "array", "items": { "type": "integer", "minimum": 0, "maximum": 23 } }
|
|
210
|
+
}
|
|
211
|
+
}
|
|
212
|
+
},
|
|
213
|
+
"session_length": {
|
|
214
|
+
"type": "object",
|
|
215
|
+
"properties": {
|
|
216
|
+
"typical_minutes": { "type": "integer" },
|
|
217
|
+
"variation": { "enum": ["consistent", "variable", "highly_variable"] }
|
|
218
|
+
}
|
|
219
|
+
},
|
|
220
|
+
"focus_areas": {
|
|
221
|
+
"type": "array",
|
|
222
|
+
"description": "Code areas they work on most",
|
|
223
|
+
"items": {
|
|
224
|
+
"type": "object",
|
|
225
|
+
"properties": {
|
|
226
|
+
"area": { "type": "string" },
|
|
227
|
+
"percentage": { "type": "number" },
|
|
228
|
+
"commit_count": { "type": "integer" }
|
|
229
|
+
}
|
|
230
|
+
}
|
|
231
|
+
}
|
|
232
|
+
}
|
|
233
|
+
},
|
|
234
|
+
"decision_patterns": {
|
|
235
|
+
"type": "object",
|
|
236
|
+
"description": "How they make technical decisions",
|
|
237
|
+
"properties": {
|
|
238
|
+
"typical_considerations": {
|
|
239
|
+
"type": "array",
|
|
240
|
+
"items": { "type": "string" },
|
|
241
|
+
"description": "What they typically consider when deciding"
|
|
242
|
+
},
|
|
243
|
+
"priority_order": {
|
|
244
|
+
"type": "array",
|
|
245
|
+
"items": {
|
|
246
|
+
"enum": ["performance", "maintainability", "simplicity", "correctness", "security", "cost", "time_to_market"]
|
|
247
|
+
},
|
|
248
|
+
"description": "Priority ordering of concerns"
|
|
249
|
+
},
|
|
250
|
+
"change_tolerance": {
|
|
251
|
+
"enum": ["resistant", "cautious", "open", "eager"],
|
|
252
|
+
"description": "Openness to changing existing code"
|
|
253
|
+
}
|
|
254
|
+
}
|
|
255
|
+
}
|
|
256
|
+
}
|
|
257
|
+
}
|
|
@@ -0,0 +1,175 @@
|
|
|
1
|
+
# Adaptive Task Decomposition Reference
|
|
2
|
+
|
|
3
|
+
## Overview
|
|
4
|
+
|
|
5
|
+
Adaptive task decomposition automatically adjusts task granularity based on detected complexity. Simple tasks stay simple; complex tasks get broken down further.
|
|
6
|
+
|
|
7
|
+
## Complexity Detection
|
|
8
|
+
|
|
9
|
+
### Complexity Indicators
|
|
10
|
+
|
|
11
|
+
| Indicator | Weight | Description |
|
|
12
|
+
|-----------|--------|-------------|
|
|
13
|
+
| External dependencies | +3 | APIs, databases, third-party services |
|
|
14
|
+
| State management | +2 | Complex state flows, side effects |
|
|
15
|
+
| Async operations | +2 | Promises, callbacks, event handling |
|
|
16
|
+
| Multiple files | +1/file | Cross-file changes beyond 3 |
|
|
17
|
+
| Novel patterns | +2 | No existing pattern in codebase |
|
|
18
|
+
| Security-sensitive | +3 | Auth, encryption, permissions |
|
|
19
|
+
| Performance-critical | +2 | Must meet specific benchmarks |
|
|
20
|
+
| Data migrations | +4 | Schema changes, data transforms |
|
|
21
|
+
|
|
22
|
+
### Complexity Scoring
|
|
23
|
+
|
|
24
|
+
| Score | Level | Task Size | Decomposition |
|
|
25
|
+
|-------|-------|-----------|---------------|
|
|
26
|
+
| 0-3 | Low | Small | Keep as single task |
|
|
27
|
+
| 4-6 | Medium | Standard | 2-3 subtasks |
|
|
28
|
+
| 7-10 | High | Large | 4-6 subtasks |
|
|
29
|
+
| 11+ | Very High | Epic | Split into separate plan |
|
|
30
|
+
|
|
31
|
+
## Decomposition Rules
|
|
32
|
+
|
|
33
|
+
### When to Decompose
|
|
34
|
+
|
|
35
|
+
1. **Task exceeds complexity threshold (7+)**
|
|
36
|
+
```
|
|
37
|
+
Original: "Implement user authentication"
|
|
38
|
+
Complexity: 12 (High)
|
|
39
|
+
|
|
40
|
+
Decomposed:
|
|
41
|
+
- T1.1: Create user model and schema
|
|
42
|
+
- T1.2: Implement password hashing
|
|
43
|
+
- T1.3: Create JWT token service
|
|
44
|
+
- T1.4: Build login endpoint
|
|
45
|
+
- T1.5: Build registration endpoint
|
|
46
|
+
- T1.6: Add authentication middleware
|
|
47
|
+
```
|
|
48
|
+
|
|
49
|
+
2. **Task has unclear verification**
|
|
50
|
+
```
|
|
51
|
+
Original: "Make the app faster"
|
|
52
|
+
Issue: No clear done state
|
|
53
|
+
|
|
54
|
+
Decomposed:
|
|
55
|
+
- T1.1: Profile current performance (baseline)
|
|
56
|
+
- T1.2: Identify top 3 bottlenecks
|
|
57
|
+
- T1.3: Optimize bottleneck #1
|
|
58
|
+
- T1.4: Optimize bottleneck #2
|
|
59
|
+
- T1.5: Optimize bottleneck #3
|
|
60
|
+
- T1.6: Verify improvement vs baseline
|
|
61
|
+
```
|
|
62
|
+
|
|
63
|
+
3. **Task spans multiple domains**
|
|
64
|
+
```
|
|
65
|
+
Original: "Add payment processing"
|
|
66
|
+
Domains: API, Database, UI, External Service
|
|
67
|
+
|
|
68
|
+
Decomposed:
|
|
69
|
+
- T1.1: Database schema for transactions
|
|
70
|
+
- T1.2: Stripe API integration
|
|
71
|
+
- T1.3: Payment endpoint
|
|
72
|
+
- T1.4: Transaction history UI
|
|
73
|
+
- T1.5: Webhook handling
|
|
74
|
+
```
|
|
75
|
+
|
|
76
|
+
### When NOT to Decompose
|
|
77
|
+
|
|
78
|
+
1. **Simple CRUD operations** (complexity < 4)
|
|
79
|
+
2. **Configuration changes**
|
|
80
|
+
3. **Documentation updates**
|
|
81
|
+
4. **Style/formatting fixes**
|
|
82
|
+
5. **Single-file changes with clear scope**
|
|
83
|
+
|
|
84
|
+
## Integration with plan-phase
|
|
85
|
+
|
|
86
|
+
### Automatic Detection
|
|
87
|
+
|
|
88
|
+
During `/gywd:plan-phase`, each task is scored:
|
|
89
|
+
|
|
90
|
+
```markdown
|
|
91
|
+
## Phase 3: Payment Integration
|
|
92
|
+
|
|
93
|
+
### Initial Tasks (Before Decomposition)
|
|
94
|
+
|
|
95
|
+
1. Add payment processing (complexity: 14) → DECOMPOSE
|
|
96
|
+
2. Update user model for billing (complexity: 4) → KEEP
|
|
97
|
+
3. Add Stripe webhook handling (complexity: 8) → DECOMPOSE
|
|
98
|
+
4. Update tests (complexity: 3) → KEEP
|
|
99
|
+
|
|
100
|
+
### After Adaptive Decomposition
|
|
101
|
+
|
|
102
|
+
1.1 Create transaction database schema [3]
|
|
103
|
+
1.2 Implement Stripe client wrapper [4]
|
|
104
|
+
1.3 Create payment intent endpoint [5]
|
|
105
|
+
1.4 Handle successful payment [4]
|
|
106
|
+
1.5 Handle failed payment [4]
|
|
107
|
+
1.6 Create payment history endpoint [3]
|
|
108
|
+
|
|
109
|
+
2. Update user model for billing [4]
|
|
110
|
+
|
|
111
|
+
3.1 Create webhook endpoint [4]
|
|
112
|
+
3.2 Verify webhook signatures [3]
|
|
113
|
+
3.3 Handle payment_intent.succeeded [3]
|
|
114
|
+
3.4 Handle payment_intent.failed [3]
|
|
115
|
+
|
|
116
|
+
4. Update tests [3]
|
|
117
|
+
```
|
|
118
|
+
|
|
119
|
+
### User Override
|
|
120
|
+
|
|
121
|
+
Users can control decomposition:
|
|
122
|
+
|
|
123
|
+
```bash
|
|
124
|
+
# Force decomposition
|
|
125
|
+
/gywd:plan-phase 3 --decompose-all
|
|
126
|
+
|
|
127
|
+
# Prevent decomposition
|
|
128
|
+
/gywd:plan-phase 3 --no-decompose
|
|
129
|
+
|
|
130
|
+
# Set custom threshold
|
|
131
|
+
/gywd:plan-phase 3 --complexity-threshold 10
|
|
132
|
+
```
|
|
133
|
+
|
|
134
|
+
### Memory Integration
|
|
135
|
+
|
|
136
|
+
Decomposition patterns are learned:
|
|
137
|
+
|
|
138
|
+
```markdown
|
|
139
|
+
## MEMORY.md
|
|
140
|
+
|
|
141
|
+
### Patterns
|
|
142
|
+
|
|
143
|
+
- Payment tasks always decompose into: schema → client → endpoints → webhooks
|
|
144
|
+
- Auth tasks split by: model → crypto → endpoints → middleware
|
|
145
|
+
- API tasks split by: endpoint type (GET/POST/PUT/DELETE)
|
|
146
|
+
```
|
|
147
|
+
|
|
148
|
+
## Output Format
|
|
149
|
+
|
|
150
|
+
When a plan uses adaptive decomposition:
|
|
151
|
+
|
|
152
|
+
```markdown
|
|
153
|
+
## Decomposition Summary
|
|
154
|
+
|
|
155
|
+
This plan used adaptive task decomposition.
|
|
156
|
+
|
|
157
|
+
| Original Task | Complexity | Result |
|
|
158
|
+
|--------------|------------|--------|
|
|
159
|
+
| Payment processing | 14 | Split into 6 subtasks |
|
|
160
|
+
| Update user model | 4 | Kept as-is |
|
|
161
|
+
| Webhook handling | 8 | Split into 4 subtasks |
|
|
162
|
+
| Update tests | 3 | Kept as-is |
|
|
163
|
+
|
|
164
|
+
**Original tasks:** 4
|
|
165
|
+
**After decomposition:** 12
|
|
166
|
+
**Average complexity:** 3.5 (down from 7.2)
|
|
167
|
+
```
|
|
168
|
+
|
|
169
|
+
## Benefits
|
|
170
|
+
|
|
171
|
+
1. **Predictable execution** - Each task is right-sized
|
|
172
|
+
2. **Better commits** - One feature per commit
|
|
173
|
+
3. **Easier review** - Smaller, focused changes
|
|
174
|
+
4. **Progress visibility** - More granular tracking
|
|
175
|
+
5. **Reduced risk** - Problems caught earlier
|