@codemcp/workflows 6.18.4 → 6.19.2
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/package.json +2 -2
- package/packages/cli/package.json +1 -1
- package/packages/cli/resources/workflows/qrspi.yaml +247 -0
- package/packages/core/package.json +1 -1
- package/packages/core/resources/workflows/qrspi.yaml +247 -0
- package/packages/docs/.vitepress/dist/404.html +2 -2
- package/packages/docs/.vitepress/dist/assets/{app.CAEWYLPb.js → app.CMJFkZ5d.js} +1 -1
- package/packages/docs/.vitepress/dist/assets/chunks/{theme.CshoOl3e.js → theme.BarNEZau.js} +1 -1
- package/packages/docs/.vitepress/dist/assets/workflows_qrspi.md.CPYiTyJ8.js +1 -0
- package/packages/docs/.vitepress/dist/assets/workflows_qrspi.md.CPYiTyJ8.lean.js +1 -0
- package/packages/docs/.vitepress/dist/dev/ARCHITECTURE.html +3 -3
- package/packages/docs/.vitepress/dist/dev/DEVELOPMENT.html +3 -3
- package/packages/docs/.vitepress/dist/dev/LOGGING.html +3 -3
- package/packages/docs/.vitepress/dist/dev/PUBLISHING.html +3 -3
- package/packages/docs/.vitepress/dist/hashmap.json +1 -1
- package/packages/docs/.vitepress/dist/index.html +3 -3
- package/packages/docs/.vitepress/dist/user/advanced-engineering.html +3 -3
- package/packages/docs/.vitepress/dist/user/agent-setup.html +3 -3
- package/packages/docs/.vitepress/dist/user/beads-integration.html +3 -3
- package/packages/docs/.vitepress/dist/user/crowd-mcp-integration.html +3 -3
- package/packages/docs/.vitepress/dist/user/custom-workflows.html +3 -3
- package/packages/docs/.vitepress/dist/user/git-commit-feature.html +3 -3
- package/packages/docs/.vitepress/dist/user/how-it-works.html +3 -3
- package/packages/docs/.vitepress/dist/user/long-term-memory.html +3 -3
- package/packages/docs/.vitepress/dist/user/packaged-workflows.html +3 -3
- package/packages/docs/.vitepress/dist/user/tutorial.html +3 -3
- package/packages/docs/.vitepress/dist/user/workflow-selection.html +3 -3
- package/packages/docs/.vitepress/dist/workflows/adr.html +3 -3
- package/packages/docs/.vitepress/dist/workflows/big-bang-conversion.html +3 -3
- package/packages/docs/.vitepress/dist/workflows/boundary-testing.html +3 -3
- package/packages/docs/.vitepress/dist/workflows/bugfix.html +3 -3
- package/packages/docs/.vitepress/dist/workflows/business-analysis.html +3 -3
- package/packages/docs/.vitepress/dist/workflows/c4-analysis.html +3 -3
- package/packages/docs/.vitepress/dist/workflows/epcc.html +3 -3
- package/packages/docs/.vitepress/dist/workflows/game-beginner.html +3 -3
- package/packages/docs/.vitepress/dist/workflows/greenfield.html +3 -3
- package/packages/docs/.vitepress/dist/workflows/minor.html +3 -3
- package/packages/docs/.vitepress/dist/workflows/posts.html +3 -3
- package/packages/docs/.vitepress/dist/workflows/pr-review.html +3 -3
- package/packages/docs/.vitepress/dist/workflows/qrspi.html +26 -0
- package/packages/docs/.vitepress/dist/workflows/qrspi.yaml +247 -0
- package/packages/docs/.vitepress/dist/workflows/sdd-bugfix-crowd.html +3 -3
- package/packages/docs/.vitepress/dist/workflows/sdd-bugfix.html +3 -3
- package/packages/docs/.vitepress/dist/workflows/sdd-feature-crowd.html +3 -3
- package/packages/docs/.vitepress/dist/workflows/sdd-feature.html +3 -3
- package/packages/docs/.vitepress/dist/workflows/sdd-greenfield-crowd.html +3 -3
- package/packages/docs/.vitepress/dist/workflows/sdd-greenfield.html +3 -3
- package/packages/docs/.vitepress/dist/workflows/skilled-bugfix.html +3 -3
- package/packages/docs/.vitepress/dist/workflows/skilled-epcc.html +3 -3
- package/packages/docs/.vitepress/dist/workflows/skilled-greenfield.html +3 -3
- package/packages/docs/.vitepress/dist/workflows/slides.html +3 -3
- package/packages/docs/.vitepress/dist/workflows/tdd.html +3 -3
- package/packages/docs/.vitepress/dist/workflows/waterfall.html +3 -3
- package/packages/docs/.vitepress/dist/workflows.html +3 -3
- package/packages/docs/package.json +1 -1
- package/packages/mcp-server/package.json +1 -1
- package/packages/mcp-server/resources/workflows/qrspi.yaml +247 -0
- package/packages/opencode-plugin/package.json +1 -1
- package/packages/opencode-plugin/resources/workflows/qrspi.yaml +247 -0
- package/packages/opencode-tui-plugin/package.json +1 -1
- package/packages/visualizer/dist/services/workflow-list.ts +1 -0
- package/packages/visualizer/package.json +1 -1
- package/resources/state-machine-schema.json +29 -0
- package/resources/workflows/qrspi.yaml +247 -0
|
@@ -0,0 +1,247 @@
|
|
|
1
|
+
# yaml-language-server: $schema=../state-machine-schema.json
|
|
2
|
+
---
|
|
3
|
+
name: 'qrspi'
|
|
4
|
+
description: 'Questions, Research, Design, Structure, Plan, Implement — for creative, complex challenges requiring deep alignment before execution'
|
|
5
|
+
initial_state: 'questions'
|
|
6
|
+
|
|
7
|
+
metadata:
|
|
8
|
+
domain: 'code'
|
|
9
|
+
complexity: 'high'
|
|
10
|
+
bestFor:
|
|
11
|
+
- 'Creative and complex challenges'
|
|
12
|
+
- 'Deep alignment before execution'
|
|
13
|
+
- 'Unconventional problems'
|
|
14
|
+
- 'Architecture-heavy features'
|
|
15
|
+
- 'High-stakes changes'
|
|
16
|
+
useCases:
|
|
17
|
+
- 'Designing a novel system architecture'
|
|
18
|
+
- 'Implementing complex multi-domain features'
|
|
19
|
+
- 'Solving problems with unclear requirements'
|
|
20
|
+
- 'Building features requiring extensive stakeholder alignment'
|
|
21
|
+
- 'Refactoring core infrastructure'
|
|
22
|
+
examples:
|
|
23
|
+
- 'Design and implement a new plugin architecture'
|
|
24
|
+
- 'Create a custom workflow engine with validation'
|
|
25
|
+
- 'Refactor monolith to modular services'
|
|
26
|
+
- 'Build a creative AI-powered feature with novel UX'
|
|
27
|
+
|
|
28
|
+
states:
|
|
29
|
+
questions:
|
|
30
|
+
description: 'Clarify intent, scope, and success criteria before any exploration'
|
|
31
|
+
allowed_file_patterns:
|
|
32
|
+
- '**/*.md'
|
|
33
|
+
- '**/*.txt'
|
|
34
|
+
- '**/*.adoc'
|
|
35
|
+
default_instructions: |
|
|
36
|
+
**Principle**: Clarify intent before exploring solutions.
|
|
37
|
+
|
|
38
|
+
Document in the development plan: the problem being solved, success criteria, constraints, and any clarifying questions asked. Use `$REQUIREMENTS_DOC` as context only — do not modify it.
|
|
39
|
+
|
|
40
|
+
Do not research, design, plan, or write code.
|
|
41
|
+
transitions:
|
|
42
|
+
- trigger: 'questions_answered'
|
|
43
|
+
to: 'research'
|
|
44
|
+
transition_reason: 'Intent clarified, ready to gather facts'
|
|
45
|
+
|
|
46
|
+
- trigger: 'abandon_feature'
|
|
47
|
+
to: 'questions'
|
|
48
|
+
instructions: 'Feature abandoned. Reset for new tasks.'
|
|
49
|
+
transition_reason: 'User abandoned feature during questions'
|
|
50
|
+
|
|
51
|
+
research:
|
|
52
|
+
description: 'Gather facts without forming conclusions or proposing solutions'
|
|
53
|
+
allowed_file_patterns:
|
|
54
|
+
- '**/*.md'
|
|
55
|
+
- '**/*.txt'
|
|
56
|
+
- '**/*.adoc'
|
|
57
|
+
default_instructions: |
|
|
58
|
+
**Principle**: Gather facts before forming opinions.
|
|
59
|
+
|
|
60
|
+
Explore the codebase, patterns, and relevant documentation. Document findings as facts (not opinions) in the development plan. Highlight what requires design decisions. Use `$REQUIREMENTS_DOC` as context only — do not modify it.
|
|
61
|
+
|
|
62
|
+
Do not propose solutions, make design decisions, or write code.
|
|
63
|
+
transitions:
|
|
64
|
+
- trigger: 'research_complete'
|
|
65
|
+
to: 'design'
|
|
66
|
+
transition_reason: 'Facts gathered, ready for design discussion'
|
|
67
|
+
|
|
68
|
+
- trigger: 'need_more_questions'
|
|
69
|
+
to: 'questions'
|
|
70
|
+
additional_instructions: 'Focus on the specific areas where intent is still unclear.'
|
|
71
|
+
transition_reason: 'Research revealed gaps in understanding'
|
|
72
|
+
|
|
73
|
+
- trigger: 'abandon_feature'
|
|
74
|
+
to: 'questions'
|
|
75
|
+
instructions: 'Feature abandoned. Reset for new tasks.'
|
|
76
|
+
transition_reason: 'User abandoned feature during research'
|
|
77
|
+
|
|
78
|
+
design:
|
|
79
|
+
description: 'Explore options and reach consensus on WHAT and high-level HOW'
|
|
80
|
+
allowed_file_patterns:
|
|
81
|
+
- '**/*.md'
|
|
82
|
+
- '**/*.txt'
|
|
83
|
+
- '**/*.adoc'
|
|
84
|
+
default_instructions: |
|
|
85
|
+
**Principle**: Align on WHAT and WHY before deciding detailed HOW.
|
|
86
|
+
|
|
87
|
+
Propose 2-3 viable high-level approaches with trade-offs. Reference `$DESIGN_DOC` and `$ARCHITECTURE_DOC` if they exist. Reach consensus with the user on the direction. On loop-back from `need_design_changes`, update those docs if they exist.
|
|
88
|
+
|
|
89
|
+
Document the agreed direction in the development plan.
|
|
90
|
+
|
|
91
|
+
Do not plan detailed implementation or write code.
|
|
92
|
+
transitions:
|
|
93
|
+
- trigger: 'design_approved'
|
|
94
|
+
to: 'structure'
|
|
95
|
+
transition_reason: 'Design direction approved, ready to decompose'
|
|
96
|
+
review_perspectives:
|
|
97
|
+
- perspective: 'product_owner'
|
|
98
|
+
prompt: 'Review whether the proposed design aligns with user goals, business value, and intended outcomes. Ensure the solution direction serves the actual need.'
|
|
99
|
+
|
|
100
|
+
- trigger: 'need_research'
|
|
101
|
+
to: 'research'
|
|
102
|
+
additional_instructions: 'Focus on the specific gaps that block design consensus.'
|
|
103
|
+
transition_reason: 'Design discussion revealed need for more research'
|
|
104
|
+
|
|
105
|
+
- trigger: 'abandon_feature'
|
|
106
|
+
to: 'questions'
|
|
107
|
+
instructions: 'Feature abandoned. Reset for new tasks.'
|
|
108
|
+
transition_reason: 'User abandoned feature during design'
|
|
109
|
+
|
|
110
|
+
structure:
|
|
111
|
+
description: 'Decompose the approved design into end-to-end vertical slices'
|
|
112
|
+
allowed_file_patterns:
|
|
113
|
+
- '**/*.md'
|
|
114
|
+
- '**/*.txt'
|
|
115
|
+
- '**/*.adoc'
|
|
116
|
+
default_instructions: |
|
|
117
|
+
**Principle**: Decompose into end-to-end, testable units before planning implementation details.
|
|
118
|
+
|
|
119
|
+
Define 1-5 vertical slices that each deliver user-visible behavior independently. Describe what each slice delivers, which components it touches, and how it will be tested end-to-end. Reference `$ARCHITECTURE_DOC` if it exists.
|
|
120
|
+
|
|
121
|
+
Document slice definitions in the development plan.
|
|
122
|
+
|
|
123
|
+
Do not plan implementation tasks or write code.
|
|
124
|
+
transitions:
|
|
125
|
+
- trigger: 'structure_defined'
|
|
126
|
+
to: 'plan'
|
|
127
|
+
transition_reason: 'Slices defined, ready for detailed planning'
|
|
128
|
+
|
|
129
|
+
- trigger: 'need_design_changes'
|
|
130
|
+
to: 'design'
|
|
131
|
+
additional_instructions: 'The design approach makes slicing difficult. Revisit the high-level approach with the user.'
|
|
132
|
+
transition_reason: 'Structure work revealed design gaps'
|
|
133
|
+
|
|
134
|
+
- trigger: 'abandon_feature'
|
|
135
|
+
to: 'questions'
|
|
136
|
+
instructions: 'Feature abandoned. Reset for new tasks.'
|
|
137
|
+
transition_reason: 'User abandoned feature during structure'
|
|
138
|
+
|
|
139
|
+
plan:
|
|
140
|
+
description: 'Create a detailed implementation plan per vertical slice'
|
|
141
|
+
allowed_file_patterns:
|
|
142
|
+
- '**/*.md'
|
|
143
|
+
- '**/*.txt'
|
|
144
|
+
- '**/*.adoc'
|
|
145
|
+
default_instructions: |
|
|
146
|
+
**Principle**: Define detailed HOW per slice without changing the design direction.
|
|
147
|
+
|
|
148
|
+
For each vertical slice, define actionable tasks, dependencies, and risks. If any existing document contradicts what is needed, document the contradiction in the development plan and use `need_design_changes`.
|
|
149
|
+
|
|
150
|
+
Document the plan in the development plan.
|
|
151
|
+
|
|
152
|
+
Do not change the design direction or write code.
|
|
153
|
+
transitions:
|
|
154
|
+
- trigger: 'plan_complete'
|
|
155
|
+
to: 'implement'
|
|
156
|
+
transition_reason: 'Plan complete, ready for coding'
|
|
157
|
+
review_perspectives:
|
|
158
|
+
- perspective: 'architect'
|
|
159
|
+
prompt: 'Review implementation strategy, design decisions, and integration approach for soundness and maintainability. Ensure the plan aligns with existing system architecture and follows best practices.'
|
|
160
|
+
- perspective: 'security_expert'
|
|
161
|
+
prompt: 'Assess security considerations and potential risks in the planned implementation approach. Review data handling, authentication, and potential vulnerabilities.'
|
|
162
|
+
|
|
163
|
+
- trigger: 'need_design_changes'
|
|
164
|
+
to: 'design'
|
|
165
|
+
additional_instructions: 'The approved design direction is unworkable for the planned slices. Revisit the high-level approach with the user.'
|
|
166
|
+
transition_reason: 'Planning revealed fundamental flaws in design direction'
|
|
167
|
+
|
|
168
|
+
- trigger: 'need_restructuring'
|
|
169
|
+
to: 'structure'
|
|
170
|
+
additional_instructions: 'The slice boundaries are wrong. Redefine the vertical slices.'
|
|
171
|
+
transition_reason: 'Planning revealed flaws in slice boundaries'
|
|
172
|
+
|
|
173
|
+
- trigger: 'abandon_feature'
|
|
174
|
+
to: 'questions'
|
|
175
|
+
instructions: 'Feature abandoned. Reset for new tasks.'
|
|
176
|
+
transition_reason: 'User abandoned feature during planning'
|
|
177
|
+
|
|
178
|
+
implement:
|
|
179
|
+
description: 'Build the solution slice by slice'
|
|
180
|
+
allowed_file_patterns:
|
|
181
|
+
- '**/*'
|
|
182
|
+
default_instructions: |
|
|
183
|
+
**Principle**: Execute the plan one slice at a time; delegate each slice to a fresh context.
|
|
184
|
+
|
|
185
|
+
Build each vertical slice end-to-end before moving to the next. Delegate each slice to a fresh agent session with focused context. Reference `$DESIGN_DOC`, `$ARCHITECTURE_DOC`, and `$REQUIREMENTS_DOC` if they exist. Prevent regressions via build, lint, and tests.
|
|
186
|
+
|
|
187
|
+
Adapt tactics within slices. Loop back via `need_design_changes` only if the high-level approach is fundamentally flawed.
|
|
188
|
+
|
|
189
|
+
Document progress in the development plan.
|
|
190
|
+
transitions:
|
|
191
|
+
- trigger: 'implementation_complete'
|
|
192
|
+
to: 'commit'
|
|
193
|
+
transition_reason: 'Implementation complete, ready for finalization'
|
|
194
|
+
review_perspectives:
|
|
195
|
+
- perspective: 'senior_software_developer'
|
|
196
|
+
prompt: 'Review code quality, best practices, testing coverage, and readiness for production deployment. Ensure the implementation follows coding standards and is maintainable.'
|
|
197
|
+
- perspective: 'performance_engineer'
|
|
198
|
+
prompt: 'Evaluate performance impact, resource efficiency, and scalability of the implemented solution. Check for potential bottlenecks or optimization opportunities.'
|
|
199
|
+
|
|
200
|
+
- trigger: 'need_replanning'
|
|
201
|
+
to: 'plan'
|
|
202
|
+
additional_instructions: 'Adjust the plan based on what you learned during coding. Document changes and reasons.'
|
|
203
|
+
transition_reason: 'Implementation revealed need to revise the plan'
|
|
204
|
+
|
|
205
|
+
- trigger: 'need_design_changes'
|
|
206
|
+
to: 'design'
|
|
207
|
+
additional_instructions: 'The high-level design approach is fundamentally flawed. Revisit design decisions with the user.'
|
|
208
|
+
transition_reason: 'Implementation revealed the approved design is unworkable'
|
|
209
|
+
|
|
210
|
+
- trigger: 'need_more_research'
|
|
211
|
+
to: 'research'
|
|
212
|
+
additional_instructions: 'Focus on the specific areas blocking implementation progress.'
|
|
213
|
+
transition_reason: 'Implementation revealed need for more research'
|
|
214
|
+
|
|
215
|
+
- trigger: 'abandon_feature'
|
|
216
|
+
to: 'questions'
|
|
217
|
+
instructions: 'Feature abandoned. Clean up incomplete code and reset for new tasks.'
|
|
218
|
+
transition_reason: 'User abandoned feature during implementation'
|
|
219
|
+
|
|
220
|
+
commit:
|
|
221
|
+
description: 'Cleanup, documentation finalization, and delivery'
|
|
222
|
+
allowed_file_patterns:
|
|
223
|
+
- '**/*'
|
|
224
|
+
default_instructions: |
|
|
225
|
+
**Principle**: Leave the codebase cleaner than you found it.
|
|
226
|
+
|
|
227
|
+
**Cleanup**: Remove debug output, temporary code, test code blocks, and completed TODOs. Address or document any remaining FIXMEs.
|
|
228
|
+
|
|
229
|
+
**Documentation**: Update `$REQUIREMENTS_DOC`, `$ARCHITECTURE_DOC`, and `$DESIGN_DOC` if they exist and changed during implementation. Otherwise, document changes in the development plan. Ensure docs reflect the final implemented state, not the development process.
|
|
230
|
+
|
|
231
|
+
**Validation**: Run tests to ensure no regressions. Verify the development plan is accurate.
|
|
232
|
+
|
|
233
|
+
Do not add new features.
|
|
234
|
+
transitions:
|
|
235
|
+
- trigger: 'commit_complete'
|
|
236
|
+
to: 'questions'
|
|
237
|
+
transition_reason: 'Feature delivered, ready for next task'
|
|
238
|
+
|
|
239
|
+
- trigger: 'need_code_changes'
|
|
240
|
+
to: 'implement'
|
|
241
|
+
additional_instructions: 'Fix the problems identified during final review.'
|
|
242
|
+
transition_reason: 'Final review found issues requiring code changes'
|
|
243
|
+
|
|
244
|
+
- trigger: 'abandon_feature'
|
|
245
|
+
to: 'questions'
|
|
246
|
+
instructions: 'Feature abandoned. Clean up artifacts and reset for new tasks.'
|
|
247
|
+
transition_reason: 'User abandoned feature during finalization'
|
|
@@ -51,6 +51,10 @@
|
|
|
51
51
|
"type": "boolean",
|
|
52
52
|
"description": "Whether this workflow requires project documentation (architecture, requirements, design) to be set up before starting. Defaults to false for backwards compatibility.",
|
|
53
53
|
"default": false
|
|
54
|
+
},
|
|
55
|
+
"domain": {
|
|
56
|
+
"type": "string",
|
|
57
|
+
"description": "Domain or category of the workflow (e.g., code, architecture, office, skilled)"
|
|
54
58
|
}
|
|
55
59
|
}
|
|
56
60
|
},
|
|
@@ -71,6 +75,13 @@
|
|
|
71
75
|
"type": "string",
|
|
72
76
|
"description": "Description of this state"
|
|
73
77
|
},
|
|
78
|
+
"allowed_file_patterns": {
|
|
79
|
+
"type": "array",
|
|
80
|
+
"items": {
|
|
81
|
+
"type": "string"
|
|
82
|
+
},
|
|
83
|
+
"description": "Glob patterns for files that can be edited in this state. Use '**/*' to allow all files."
|
|
84
|
+
},
|
|
74
85
|
"default_instructions": {
|
|
75
86
|
"type": "string",
|
|
76
87
|
"description": "Default instructions when entering this state"
|
|
@@ -107,6 +118,24 @@
|
|
|
107
118
|
"transition_reason": {
|
|
108
119
|
"type": "string",
|
|
109
120
|
"description": "Reason for this transition"
|
|
121
|
+
},
|
|
122
|
+
"review_perspectives": {
|
|
123
|
+
"type": "array",
|
|
124
|
+
"description": "Optional review perspectives to apply when this transition is taken",
|
|
125
|
+
"items": {
|
|
126
|
+
"type": "object",
|
|
127
|
+
"required": ["perspective", "prompt"],
|
|
128
|
+
"properties": {
|
|
129
|
+
"perspective": {
|
|
130
|
+
"type": "string",
|
|
131
|
+
"description": "Name of the review perspective (e.g., architect, security_expert)"
|
|
132
|
+
},
|
|
133
|
+
"prompt": {
|
|
134
|
+
"type": "string",
|
|
135
|
+
"description": "Prompt or instructions for the review perspective"
|
|
136
|
+
}
|
|
137
|
+
}
|
|
138
|
+
}
|
|
110
139
|
}
|
|
111
140
|
}
|
|
112
141
|
}
|
|
@@ -0,0 +1,247 @@
|
|
|
1
|
+
# yaml-language-server: $schema=../state-machine-schema.json
|
|
2
|
+
---
|
|
3
|
+
name: 'qrspi'
|
|
4
|
+
description: 'Questions, Research, Design, Structure, Plan, Implement — for creative, complex challenges requiring deep alignment before execution'
|
|
5
|
+
initial_state: 'questions'
|
|
6
|
+
|
|
7
|
+
metadata:
|
|
8
|
+
domain: 'code'
|
|
9
|
+
complexity: 'high'
|
|
10
|
+
bestFor:
|
|
11
|
+
- 'Creative and complex challenges'
|
|
12
|
+
- 'Deep alignment before execution'
|
|
13
|
+
- 'Unconventional problems'
|
|
14
|
+
- 'Architecture-heavy features'
|
|
15
|
+
- 'High-stakes changes'
|
|
16
|
+
useCases:
|
|
17
|
+
- 'Designing a novel system architecture'
|
|
18
|
+
- 'Implementing complex multi-domain features'
|
|
19
|
+
- 'Solving problems with unclear requirements'
|
|
20
|
+
- 'Building features requiring extensive stakeholder alignment'
|
|
21
|
+
- 'Refactoring core infrastructure'
|
|
22
|
+
examples:
|
|
23
|
+
- 'Design and implement a new plugin architecture'
|
|
24
|
+
- 'Create a custom workflow engine with validation'
|
|
25
|
+
- 'Refactor monolith to modular services'
|
|
26
|
+
- 'Build a creative AI-powered feature with novel UX'
|
|
27
|
+
|
|
28
|
+
states:
|
|
29
|
+
questions:
|
|
30
|
+
description: 'Clarify intent, scope, and success criteria before any exploration'
|
|
31
|
+
allowed_file_patterns:
|
|
32
|
+
- '**/*.md'
|
|
33
|
+
- '**/*.txt'
|
|
34
|
+
- '**/*.adoc'
|
|
35
|
+
default_instructions: |
|
|
36
|
+
**Principle**: Clarify intent before exploring solutions.
|
|
37
|
+
|
|
38
|
+
Document in the development plan: the problem being solved, success criteria, constraints, and any clarifying questions asked. Use `$REQUIREMENTS_DOC` as context only — do not modify it.
|
|
39
|
+
|
|
40
|
+
Do not research, design, plan, or write code.
|
|
41
|
+
transitions:
|
|
42
|
+
- trigger: 'questions_answered'
|
|
43
|
+
to: 'research'
|
|
44
|
+
transition_reason: 'Intent clarified, ready to gather facts'
|
|
45
|
+
|
|
46
|
+
- trigger: 'abandon_feature'
|
|
47
|
+
to: 'questions'
|
|
48
|
+
instructions: 'Feature abandoned. Reset for new tasks.'
|
|
49
|
+
transition_reason: 'User abandoned feature during questions'
|
|
50
|
+
|
|
51
|
+
research:
|
|
52
|
+
description: 'Gather facts without forming conclusions or proposing solutions'
|
|
53
|
+
allowed_file_patterns:
|
|
54
|
+
- '**/*.md'
|
|
55
|
+
- '**/*.txt'
|
|
56
|
+
- '**/*.adoc'
|
|
57
|
+
default_instructions: |
|
|
58
|
+
**Principle**: Gather facts before forming opinions.
|
|
59
|
+
|
|
60
|
+
Explore the codebase, patterns, and relevant documentation. Document findings as facts (not opinions) in the development plan. Highlight what requires design decisions. Use `$REQUIREMENTS_DOC` as context only — do not modify it.
|
|
61
|
+
|
|
62
|
+
Do not propose solutions, make design decisions, or write code.
|
|
63
|
+
transitions:
|
|
64
|
+
- trigger: 'research_complete'
|
|
65
|
+
to: 'design'
|
|
66
|
+
transition_reason: 'Facts gathered, ready for design discussion'
|
|
67
|
+
|
|
68
|
+
- trigger: 'need_more_questions'
|
|
69
|
+
to: 'questions'
|
|
70
|
+
additional_instructions: 'Focus on the specific areas where intent is still unclear.'
|
|
71
|
+
transition_reason: 'Research revealed gaps in understanding'
|
|
72
|
+
|
|
73
|
+
- trigger: 'abandon_feature'
|
|
74
|
+
to: 'questions'
|
|
75
|
+
instructions: 'Feature abandoned. Reset for new tasks.'
|
|
76
|
+
transition_reason: 'User abandoned feature during research'
|
|
77
|
+
|
|
78
|
+
design:
|
|
79
|
+
description: 'Explore options and reach consensus on WHAT and high-level HOW'
|
|
80
|
+
allowed_file_patterns:
|
|
81
|
+
- '**/*.md'
|
|
82
|
+
- '**/*.txt'
|
|
83
|
+
- '**/*.adoc'
|
|
84
|
+
default_instructions: |
|
|
85
|
+
**Principle**: Align on WHAT and WHY before deciding detailed HOW.
|
|
86
|
+
|
|
87
|
+
Propose 2-3 viable high-level approaches with trade-offs. Reference `$DESIGN_DOC` and `$ARCHITECTURE_DOC` if they exist. Reach consensus with the user on the direction. On loop-back from `need_design_changes`, update those docs if they exist.
|
|
88
|
+
|
|
89
|
+
Document the agreed direction in the development plan.
|
|
90
|
+
|
|
91
|
+
Do not plan detailed implementation or write code.
|
|
92
|
+
transitions:
|
|
93
|
+
- trigger: 'design_approved'
|
|
94
|
+
to: 'structure'
|
|
95
|
+
transition_reason: 'Design direction approved, ready to decompose'
|
|
96
|
+
review_perspectives:
|
|
97
|
+
- perspective: 'product_owner'
|
|
98
|
+
prompt: 'Review whether the proposed design aligns with user goals, business value, and intended outcomes. Ensure the solution direction serves the actual need.'
|
|
99
|
+
|
|
100
|
+
- trigger: 'need_research'
|
|
101
|
+
to: 'research'
|
|
102
|
+
additional_instructions: 'Focus on the specific gaps that block design consensus.'
|
|
103
|
+
transition_reason: 'Design discussion revealed need for more research'
|
|
104
|
+
|
|
105
|
+
- trigger: 'abandon_feature'
|
|
106
|
+
to: 'questions'
|
|
107
|
+
instructions: 'Feature abandoned. Reset for new tasks.'
|
|
108
|
+
transition_reason: 'User abandoned feature during design'
|
|
109
|
+
|
|
110
|
+
structure:
|
|
111
|
+
description: 'Decompose the approved design into end-to-end vertical slices'
|
|
112
|
+
allowed_file_patterns:
|
|
113
|
+
- '**/*.md'
|
|
114
|
+
- '**/*.txt'
|
|
115
|
+
- '**/*.adoc'
|
|
116
|
+
default_instructions: |
|
|
117
|
+
**Principle**: Decompose into end-to-end, testable units before planning implementation details.
|
|
118
|
+
|
|
119
|
+
Define 1-5 vertical slices that each deliver user-visible behavior independently. Describe what each slice delivers, which components it touches, and how it will be tested end-to-end. Reference `$ARCHITECTURE_DOC` if it exists.
|
|
120
|
+
|
|
121
|
+
Document slice definitions in the development plan.
|
|
122
|
+
|
|
123
|
+
Do not plan implementation tasks or write code.
|
|
124
|
+
transitions:
|
|
125
|
+
- trigger: 'structure_defined'
|
|
126
|
+
to: 'plan'
|
|
127
|
+
transition_reason: 'Slices defined, ready for detailed planning'
|
|
128
|
+
|
|
129
|
+
- trigger: 'need_design_changes'
|
|
130
|
+
to: 'design'
|
|
131
|
+
additional_instructions: 'The design approach makes slicing difficult. Revisit the high-level approach with the user.'
|
|
132
|
+
transition_reason: 'Structure work revealed design gaps'
|
|
133
|
+
|
|
134
|
+
- trigger: 'abandon_feature'
|
|
135
|
+
to: 'questions'
|
|
136
|
+
instructions: 'Feature abandoned. Reset for new tasks.'
|
|
137
|
+
transition_reason: 'User abandoned feature during structure'
|
|
138
|
+
|
|
139
|
+
plan:
|
|
140
|
+
description: 'Create a detailed implementation plan per vertical slice'
|
|
141
|
+
allowed_file_patterns:
|
|
142
|
+
- '**/*.md'
|
|
143
|
+
- '**/*.txt'
|
|
144
|
+
- '**/*.adoc'
|
|
145
|
+
default_instructions: |
|
|
146
|
+
**Principle**: Define detailed HOW per slice without changing the design direction.
|
|
147
|
+
|
|
148
|
+
For each vertical slice, define actionable tasks, dependencies, and risks. If any existing document contradicts what is needed, document the contradiction in the development plan and use `need_design_changes`.
|
|
149
|
+
|
|
150
|
+
Document the plan in the development plan.
|
|
151
|
+
|
|
152
|
+
Do not change the design direction or write code.
|
|
153
|
+
transitions:
|
|
154
|
+
- trigger: 'plan_complete'
|
|
155
|
+
to: 'implement'
|
|
156
|
+
transition_reason: 'Plan complete, ready for coding'
|
|
157
|
+
review_perspectives:
|
|
158
|
+
- perspective: 'architect'
|
|
159
|
+
prompt: 'Review implementation strategy, design decisions, and integration approach for soundness and maintainability. Ensure the plan aligns with existing system architecture and follows best practices.'
|
|
160
|
+
- perspective: 'security_expert'
|
|
161
|
+
prompt: 'Assess security considerations and potential risks in the planned implementation approach. Review data handling, authentication, and potential vulnerabilities.'
|
|
162
|
+
|
|
163
|
+
- trigger: 'need_design_changes'
|
|
164
|
+
to: 'design'
|
|
165
|
+
additional_instructions: 'The approved design direction is unworkable for the planned slices. Revisit the high-level approach with the user.'
|
|
166
|
+
transition_reason: 'Planning revealed fundamental flaws in design direction'
|
|
167
|
+
|
|
168
|
+
- trigger: 'need_restructuring'
|
|
169
|
+
to: 'structure'
|
|
170
|
+
additional_instructions: 'The slice boundaries are wrong. Redefine the vertical slices.'
|
|
171
|
+
transition_reason: 'Planning revealed flaws in slice boundaries'
|
|
172
|
+
|
|
173
|
+
- trigger: 'abandon_feature'
|
|
174
|
+
to: 'questions'
|
|
175
|
+
instructions: 'Feature abandoned. Reset for new tasks.'
|
|
176
|
+
transition_reason: 'User abandoned feature during planning'
|
|
177
|
+
|
|
178
|
+
implement:
|
|
179
|
+
description: 'Build the solution slice by slice'
|
|
180
|
+
allowed_file_patterns:
|
|
181
|
+
- '**/*'
|
|
182
|
+
default_instructions: |
|
|
183
|
+
**Principle**: Execute the plan one slice at a time; delegate each slice to a fresh context.
|
|
184
|
+
|
|
185
|
+
Build each vertical slice end-to-end before moving to the next. Delegate each slice to a fresh agent session with focused context. Reference `$DESIGN_DOC`, `$ARCHITECTURE_DOC`, and `$REQUIREMENTS_DOC` if they exist. Prevent regressions via build, lint, and tests.
|
|
186
|
+
|
|
187
|
+
Adapt tactics within slices. Loop back via `need_design_changes` only if the high-level approach is fundamentally flawed.
|
|
188
|
+
|
|
189
|
+
Document progress in the development plan.
|
|
190
|
+
transitions:
|
|
191
|
+
- trigger: 'implementation_complete'
|
|
192
|
+
to: 'commit'
|
|
193
|
+
transition_reason: 'Implementation complete, ready for finalization'
|
|
194
|
+
review_perspectives:
|
|
195
|
+
- perspective: 'senior_software_developer'
|
|
196
|
+
prompt: 'Review code quality, best practices, testing coverage, and readiness for production deployment. Ensure the implementation follows coding standards and is maintainable.'
|
|
197
|
+
- perspective: 'performance_engineer'
|
|
198
|
+
prompt: 'Evaluate performance impact, resource efficiency, and scalability of the implemented solution. Check for potential bottlenecks or optimization opportunities.'
|
|
199
|
+
|
|
200
|
+
- trigger: 'need_replanning'
|
|
201
|
+
to: 'plan'
|
|
202
|
+
additional_instructions: 'Adjust the plan based on what you learned during coding. Document changes and reasons.'
|
|
203
|
+
transition_reason: 'Implementation revealed need to revise the plan'
|
|
204
|
+
|
|
205
|
+
- trigger: 'need_design_changes'
|
|
206
|
+
to: 'design'
|
|
207
|
+
additional_instructions: 'The high-level design approach is fundamentally flawed. Revisit design decisions with the user.'
|
|
208
|
+
transition_reason: 'Implementation revealed the approved design is unworkable'
|
|
209
|
+
|
|
210
|
+
- trigger: 'need_more_research'
|
|
211
|
+
to: 'research'
|
|
212
|
+
additional_instructions: 'Focus on the specific areas blocking implementation progress.'
|
|
213
|
+
transition_reason: 'Implementation revealed need for more research'
|
|
214
|
+
|
|
215
|
+
- trigger: 'abandon_feature'
|
|
216
|
+
to: 'questions'
|
|
217
|
+
instructions: 'Feature abandoned. Clean up incomplete code and reset for new tasks.'
|
|
218
|
+
transition_reason: 'User abandoned feature during implementation'
|
|
219
|
+
|
|
220
|
+
commit:
|
|
221
|
+
description: 'Cleanup, documentation finalization, and delivery'
|
|
222
|
+
allowed_file_patterns:
|
|
223
|
+
- '**/*'
|
|
224
|
+
default_instructions: |
|
|
225
|
+
**Principle**: Leave the codebase cleaner than you found it.
|
|
226
|
+
|
|
227
|
+
**Cleanup**: Remove debug output, temporary code, test code blocks, and completed TODOs. Address or document any remaining FIXMEs.
|
|
228
|
+
|
|
229
|
+
**Documentation**: Update `$REQUIREMENTS_DOC`, `$ARCHITECTURE_DOC`, and `$DESIGN_DOC` if they exist and changed during implementation. Otherwise, document changes in the development plan. Ensure docs reflect the final implemented state, not the development process.
|
|
230
|
+
|
|
231
|
+
**Validation**: Run tests to ensure no regressions. Verify the development plan is accurate.
|
|
232
|
+
|
|
233
|
+
Do not add new features.
|
|
234
|
+
transitions:
|
|
235
|
+
- trigger: 'commit_complete'
|
|
236
|
+
to: 'questions'
|
|
237
|
+
transition_reason: 'Feature delivered, ready for next task'
|
|
238
|
+
|
|
239
|
+
- trigger: 'need_code_changes'
|
|
240
|
+
to: 'implement'
|
|
241
|
+
additional_instructions: 'Fix the problems identified during final review.'
|
|
242
|
+
transition_reason: 'Final review found issues requiring code changes'
|
|
243
|
+
|
|
244
|
+
- trigger: 'abandon_feature'
|
|
245
|
+
to: 'questions'
|
|
246
|
+
instructions: 'Feature abandoned. Clean up artifacts and reset for new tasks.'
|
|
247
|
+
transition_reason: 'User abandoned feature during finalization'
|