@codemcp/workflows-core 4.0.0 → 4.1.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/dist/project-docs-manager.js +3 -0
- package/dist/project-docs-manager.js.map +1 -1
- package/dist/state-machine-types.d.ts +6 -0
- package/dist/transition-engine.d.ts +7 -0
- package/dist/transition-engine.js +12 -0
- package/dist/transition-engine.js.map +1 -1
- package/package.json +4 -3
- package/resources/agents/architect.yaml +61 -0
- package/resources/agents/business-analyst.yaml +60 -0
- package/resources/agents/developer.yaml +61 -0
- package/resources/workflows/sdd-bugfix-crowd.yaml +633 -0
- package/resources/workflows/sdd-feature-crowd.yaml +736 -0
- package/resources/workflows/sdd-greenfield-crowd.yaml +328 -0
|
@@ -0,0 +1,328 @@
|
|
|
1
|
+
# yaml-language-server: $schema=../../state-machine-schema.json
|
|
2
|
+
---
|
|
3
|
+
name: 'sdd-greenfield-crowd'
|
|
4
|
+
description: 'Collaborative greenfield project development: Team establishes constitution → Business Analyst specifies → Architect plans → Developer implements → Team documents'
|
|
5
|
+
initial_state: 'constitution'
|
|
6
|
+
|
|
7
|
+
# Enhanced metadata for better discoverability
|
|
8
|
+
metadata:
|
|
9
|
+
domain: 'sdd-crowd'
|
|
10
|
+
complexity: 'high'
|
|
11
|
+
collaboration: true
|
|
12
|
+
requiredRoles:
|
|
13
|
+
- business-analyst
|
|
14
|
+
- architect
|
|
15
|
+
- developer
|
|
16
|
+
bestFor:
|
|
17
|
+
- 'Team-based new projects from scratch'
|
|
18
|
+
- 'Collaborative greenfield development'
|
|
19
|
+
- 'Complex system design with specialized roles'
|
|
20
|
+
useCases:
|
|
21
|
+
- 'Team builds new application from scratch'
|
|
22
|
+
- 'Collaborative creation of new service'
|
|
23
|
+
examples:
|
|
24
|
+
- 'Team builds new web application'
|
|
25
|
+
- 'Collaborative microservice architecture creation'
|
|
26
|
+
|
|
27
|
+
# States with default instructions and role-specific transitions
|
|
28
|
+
states:
|
|
29
|
+
constitution:
|
|
30
|
+
description: 'Establish constitutional framework and project governance'
|
|
31
|
+
default_instructions: |
|
|
32
|
+
**Team Collaboration Mode**
|
|
33
|
+
|
|
34
|
+
You are $VIBE_ROLE working in a collaborative team starting a new project.
|
|
35
|
+
Current phase: CONSTITUTION
|
|
36
|
+
|
|
37
|
+
All team members collaborate on establishing project principles.
|
|
38
|
+
|
|
39
|
+
transitions:
|
|
40
|
+
# All agents participate in constitution (no single responsible agent)
|
|
41
|
+
# Architect typically leads this as it's about technical governance
|
|
42
|
+
- trigger: 'constitution_established'
|
|
43
|
+
to: 'specify'
|
|
44
|
+
role: architect
|
|
45
|
+
transition_reason: 'Constitutional framework established, moving to specification'
|
|
46
|
+
additional_instructions: |
|
|
47
|
+
**You are LEADING the constitution phase.**
|
|
48
|
+
|
|
49
|
+
Work with the full team to establish the constitutional framework.
|
|
50
|
+
|
|
51
|
+
**Constitution Tasks:**
|
|
52
|
+
1. Create `constitution.md` in project root
|
|
53
|
+
2. Define core principles for the project
|
|
54
|
+
3. Establish quality gates and governance
|
|
55
|
+
|
|
56
|
+
**Collaboration:**
|
|
57
|
+
- Use send_message to business-analyst: "What are the key business principles?"
|
|
58
|
+
- Use send_message to developer: "What are essential development practices?"
|
|
59
|
+
- Build consensus on project values
|
|
60
|
+
|
|
61
|
+
**Template sections**:
|
|
62
|
+
- Core Principles (Specifications First, User Value, Simplicity, etc.)
|
|
63
|
+
- Quality Gates
|
|
64
|
+
- Governance
|
|
65
|
+
|
|
66
|
+
**Handoff to Business-Analyst:**
|
|
67
|
+
|
|
68
|
+
Before proceeding:
|
|
69
|
+
1. Use send_message to business-analyst: "Constitution established. Please take the lead for specification phase."
|
|
70
|
+
2. Use send_message to developer: "Constitution ready, specification will begin next"
|
|
71
|
+
3. Use send_message_to_operator: "Constitution complete, handing off to business-analyst"
|
|
72
|
+
4. Call proceed_to_phase
|
|
73
|
+
|
|
74
|
+
- trigger: 'constitution_established'
|
|
75
|
+
to: 'specify'
|
|
76
|
+
role: business-analyst
|
|
77
|
+
transition_reason: 'Constitutional framework established, preparing to specify'
|
|
78
|
+
additional_instructions: |
|
|
79
|
+
**You are CONTRIBUTING to the constitution phase.**
|
|
80
|
+
|
|
81
|
+
Work with architect to establish project principles.
|
|
82
|
+
|
|
83
|
+
**Your Contributions:**
|
|
84
|
+
- Provide input on business values and user-centric principles
|
|
85
|
+
- Suggest quality standards for specifications
|
|
86
|
+
- Define what "done" means from business perspective
|
|
87
|
+
|
|
88
|
+
**Handoff Notice:**
|
|
89
|
+
- When constitution is complete, YOU become RESPONSIBLE
|
|
90
|
+
- You will take the lead in specify phase
|
|
91
|
+
- Prepare to create the feature specification
|
|
92
|
+
|
|
93
|
+
- trigger: 'constitution_established'
|
|
94
|
+
to: 'specify'
|
|
95
|
+
role: developer
|
|
96
|
+
transition_reason: 'Constitutional framework established, transitioning to specification'
|
|
97
|
+
additional_instructions: |
|
|
98
|
+
**You are CONTRIBUTING to the constitution phase.**
|
|
99
|
+
|
|
100
|
+
Work with architect to establish project principles.
|
|
101
|
+
|
|
102
|
+
**Your Contributions:**
|
|
103
|
+
- Provide input on code quality and maintainability principles
|
|
104
|
+
- Suggest development and testing practices
|
|
105
|
+
- Share experience with what works in practice
|
|
106
|
+
|
|
107
|
+
specify:
|
|
108
|
+
description: 'Create comprehensive feature specification'
|
|
109
|
+
default_instructions: |
|
|
110
|
+
**Team Collaboration Mode**
|
|
111
|
+
|
|
112
|
+
You are $VIBE_ROLE working in a collaborative team on this new project.
|
|
113
|
+
Current phase: SPECIFY
|
|
114
|
+
|
|
115
|
+
Business-analyst is responsible. Architect and developer are consulted.
|
|
116
|
+
|
|
117
|
+
transitions:
|
|
118
|
+
# Business Analyst is RESPONSIBLE for specify phase
|
|
119
|
+
- trigger: 'specification_complete'
|
|
120
|
+
to: 'plan'
|
|
121
|
+
role: business-analyst
|
|
122
|
+
transition_reason: 'Feature specification completed, handing off to architect'
|
|
123
|
+
additional_instructions: |
|
|
124
|
+
**You are RESPONSIBLE for the specify phase.**
|
|
125
|
+
|
|
126
|
+
Create the project specification following greenfield specification process.
|
|
127
|
+
(Instructions similar to sdd-feature-crowd specify phase)
|
|
128
|
+
|
|
129
|
+
**Handoff to Architect:**
|
|
130
|
+
|
|
131
|
+
Before proceeding:
|
|
132
|
+
1. Use send_message to architect: "Specification complete. Please take the lead for plan phase."
|
|
133
|
+
2. Use send_message_to_operator: "Specification complete, handing off to architect"
|
|
134
|
+
3. Call proceed_to_phase
|
|
135
|
+
|
|
136
|
+
- trigger: 'specification_complete'
|
|
137
|
+
to: 'plan'
|
|
138
|
+
role: architect
|
|
139
|
+
transition_reason: 'Specification completed, preparing to plan'
|
|
140
|
+
additional_instructions: |
|
|
141
|
+
**You are CONSULTED during the specify phase.**
|
|
142
|
+
|
|
143
|
+
(Consultative instructions similar to sdd-feature-crowd)
|
|
144
|
+
|
|
145
|
+
**Handoff Notice:**
|
|
146
|
+
- When complete, YOU become RESPONSIBLE in plan phase
|
|
147
|
+
|
|
148
|
+
- trigger: 'specification_complete'
|
|
149
|
+
to: 'plan'
|
|
150
|
+
role: developer
|
|
151
|
+
transition_reason: 'Specification completed, architect will plan'
|
|
152
|
+
additional_instructions: |
|
|
153
|
+
**You are CONSULTED during the specify phase.**
|
|
154
|
+
|
|
155
|
+
(Consultative instructions similar to sdd-feature-crowd)
|
|
156
|
+
|
|
157
|
+
plan:
|
|
158
|
+
description: 'Generate implementation plan with constitutional compliance'
|
|
159
|
+
default_instructions: |
|
|
160
|
+
**Team Collaboration Mode**
|
|
161
|
+
|
|
162
|
+
You are $VIBE_ROLE working in a collaborative team on this new project.
|
|
163
|
+
Current phase: PLAN
|
|
164
|
+
|
|
165
|
+
Architect is responsible for technology decisions and architecture.
|
|
166
|
+
|
|
167
|
+
transitions:
|
|
168
|
+
- trigger: 'plan_complete'
|
|
169
|
+
to: 'tasks'
|
|
170
|
+
role: architect
|
|
171
|
+
transition_reason: 'Implementation plan completed, moving to tasks'
|
|
172
|
+
additional_instructions: |
|
|
173
|
+
**You are RESPONSIBLE for the plan phase.**
|
|
174
|
+
|
|
175
|
+
**Planning includes:**
|
|
176
|
+
- Technology stack selection (ask user for preferences)
|
|
177
|
+
- Architecture design
|
|
178
|
+
- Constitutional compliance check
|
|
179
|
+
- High-level design documentation
|
|
180
|
+
|
|
181
|
+
**You remain RESPONSIBLE in tasks phase**
|
|
182
|
+
|
|
183
|
+
- trigger: 'plan_complete'
|
|
184
|
+
to: 'tasks'
|
|
185
|
+
role: business-analyst
|
|
186
|
+
transition_reason: 'Plan completed, architect moving to tasks'
|
|
187
|
+
additional_instructions: |
|
|
188
|
+
**You are CONSULTED during the plan phase.**
|
|
189
|
+
(Consultative instructions)
|
|
190
|
+
|
|
191
|
+
- trigger: 'plan_complete'
|
|
192
|
+
to: 'tasks'
|
|
193
|
+
role: developer
|
|
194
|
+
transition_reason: 'Plan completed, architect moving to tasks'
|
|
195
|
+
additional_instructions: |
|
|
196
|
+
**You are CONSULTED during the plan phase.**
|
|
197
|
+
(Consultative instructions)
|
|
198
|
+
|
|
199
|
+
tasks:
|
|
200
|
+
description: 'Generate actionable, dependency-ordered tasks'
|
|
201
|
+
default_instructions: |
|
|
202
|
+
**Team Collaboration Mode**
|
|
203
|
+
|
|
204
|
+
You are $VIBE_ROLE working in a collaborative team on this new project.
|
|
205
|
+
Current phase: TASKS
|
|
206
|
+
|
|
207
|
+
Architect creates task breakdown.
|
|
208
|
+
|
|
209
|
+
transitions:
|
|
210
|
+
- trigger: 'tasks_generated'
|
|
211
|
+
to: 'implement'
|
|
212
|
+
role: architect
|
|
213
|
+
transition_reason: 'Tasks generated, handing off to developer'
|
|
214
|
+
additional_instructions: |
|
|
215
|
+
**You are RESPONSIBLE for the tasks phase.**
|
|
216
|
+
|
|
217
|
+
Generate comprehensive task breakdown organized by user stories.
|
|
218
|
+
|
|
219
|
+
**Handoff to Developer:**
|
|
220
|
+
Before proceeding, send handoff messages to developer.
|
|
221
|
+
|
|
222
|
+
- trigger: 'tasks_generated'
|
|
223
|
+
to: 'implement'
|
|
224
|
+
role: developer
|
|
225
|
+
transition_reason: 'Tasks generated, preparing to implement'
|
|
226
|
+
additional_instructions: |
|
|
227
|
+
**You are CONSULTED during tasks phase.**
|
|
228
|
+
|
|
229
|
+
**Handoff Notice:** YOU become RESPONSIBLE in implement phase.
|
|
230
|
+
|
|
231
|
+
- trigger: 'tasks_generated'
|
|
232
|
+
to: 'implement'
|
|
233
|
+
role: business-analyst
|
|
234
|
+
transition_reason: 'Tasks generated, developer will implement'
|
|
235
|
+
additional_instructions: |
|
|
236
|
+
**You are INFORMED during tasks phase.**
|
|
237
|
+
|
|
238
|
+
implement:
|
|
239
|
+
description: 'Execute implementation following task breakdown'
|
|
240
|
+
default_instructions: |
|
|
241
|
+
**Team Collaboration Mode**
|
|
242
|
+
|
|
243
|
+
You are $VIBE_ROLE working in a collaborative team on this new project.
|
|
244
|
+
Current phase: IMPLEMENT
|
|
245
|
+
|
|
246
|
+
Developer drives implementation.
|
|
247
|
+
|
|
248
|
+
transitions:
|
|
249
|
+
- trigger: 'implementation_complete'
|
|
250
|
+
to: 'document'
|
|
251
|
+
role: developer
|
|
252
|
+
transition_reason: 'Implementation complete, team will document'
|
|
253
|
+
additional_instructions: |
|
|
254
|
+
**You are RESPONSIBLE for the implement phase.**
|
|
255
|
+
|
|
256
|
+
Execute implementation following task breakdown.
|
|
257
|
+
(Instructions similar to sdd-feature-crowd)
|
|
258
|
+
|
|
259
|
+
**Handoff to Team Documentation:**
|
|
260
|
+
All team members contribute to documentation phase.
|
|
261
|
+
|
|
262
|
+
- trigger: 'implementation_complete'
|
|
263
|
+
to: 'document'
|
|
264
|
+
role: architect
|
|
265
|
+
transition_reason: 'Implementation complete, moving to documentation'
|
|
266
|
+
additional_instructions: |
|
|
267
|
+
**You are CONSULTED during implement phase.**
|
|
268
|
+
|
|
269
|
+
- trigger: 'implementation_complete'
|
|
270
|
+
to: 'document'
|
|
271
|
+
role: business-analyst
|
|
272
|
+
transition_reason: 'Implementation complete, moving to documentation'
|
|
273
|
+
additional_instructions: |
|
|
274
|
+
**You are CONSULTED during implement phase.**
|
|
275
|
+
|
|
276
|
+
document:
|
|
277
|
+
description: 'Create comprehensive project documentation'
|
|
278
|
+
default_instructions: |
|
|
279
|
+
**Team Collaboration Mode**
|
|
280
|
+
|
|
281
|
+
You are $VIBE_ROLE working in a collaborative team on this new project.
|
|
282
|
+
Current phase: DOCUMENT
|
|
283
|
+
|
|
284
|
+
All team members contribute to documentation.
|
|
285
|
+
|
|
286
|
+
transitions:
|
|
287
|
+
- trigger: 'documentation_complete'
|
|
288
|
+
to: 'document'
|
|
289
|
+
role: developer
|
|
290
|
+
transition_reason: 'Documentation complete, project ready'
|
|
291
|
+
additional_instructions: |
|
|
292
|
+
**You are RESPONSIBLE for finalizing documentation.**
|
|
293
|
+
|
|
294
|
+
Coordinate with team to create:
|
|
295
|
+
- User documentation
|
|
296
|
+
- Developer documentation
|
|
297
|
+
- Project documentation (README, changelog, etc.)
|
|
298
|
+
|
|
299
|
+
**Collaborate:**
|
|
300
|
+
- Business-analyst creates user guides
|
|
301
|
+
- Architect creates architecture documentation
|
|
302
|
+
- You create developer setup guides
|
|
303
|
+
|
|
304
|
+
- trigger: 'documentation_complete'
|
|
305
|
+
to: 'document'
|
|
306
|
+
role: architect
|
|
307
|
+
transition_reason: 'Documentation complete'
|
|
308
|
+
additional_instructions: |
|
|
309
|
+
**You CONTRIBUTE architecture documentation.**
|
|
310
|
+
|
|
311
|
+
Create architecture overview, deployment guide, and technical docs.
|
|
312
|
+
|
|
313
|
+
- trigger: 'documentation_complete'
|
|
314
|
+
to: 'document'
|
|
315
|
+
role: business-analyst
|
|
316
|
+
transition_reason: 'Documentation complete'
|
|
317
|
+
additional_instructions: |
|
|
318
|
+
**You CONTRIBUTE user documentation.**
|
|
319
|
+
|
|
320
|
+
Create user manual, examples, and user-focused guides.
|
|
321
|
+
|
|
322
|
+
# Global transitions
|
|
323
|
+
global_transitions:
|
|
324
|
+
- trigger: 'abandon_project'
|
|
325
|
+
to: 'constitution'
|
|
326
|
+
transition_reason: 'Project abandoned, restart from beginning'
|
|
327
|
+
additional_instructions: |
|
|
328
|
+
Project abandoned. If you want to restart, begin again with establishing the constitutional framework.
|