claude-code-workflow 7.2.23 → 7.2.24
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/.codex/skills/team-arch-opt/SKILL.md +242 -175
- package/.codex/skills/team-arch-opt/roles/analyzer/role.md +78 -78
- package/.codex/skills/team-arch-opt/roles/coordinator/commands/analyze.md +57 -57
- package/.codex/skills/team-arch-opt/roles/coordinator/commands/monitor.md +246 -204
- package/.codex/skills/team-arch-opt/roles/coordinator/role.md +196 -184
- package/.codex/skills/team-arch-opt/roles/designer/role.md +115 -115
- package/.codex/skills/team-arch-opt/roles/refactorer/role.md +102 -102
- package/.codex/skills/team-arch-opt/roles/reviewer/role.md +111 -111
- package/.codex/skills/team-arch-opt/roles/validator/role.md +115 -115
- package/.codex/skills/team-arch-opt/specs/pipelines.md +102 -102
- package/.codex/skills/team-brainstorm/SKILL.md +72 -4
- package/.codex/skills/team-brainstorm/roles/challenger/role.md +61 -61
- package/.codex/skills/team-brainstorm/roles/coordinator/commands/analyze.md +58 -58
- package/.codex/skills/team-brainstorm/roles/coordinator/commands/monitor.md +212 -171
- package/.codex/skills/team-brainstorm/roles/coordinator/role.md +172 -160
- package/.codex/skills/team-brainstorm/roles/evaluator/role.md +56 -56
- package/.codex/skills/team-brainstorm/roles/ideator/role.md +69 -69
- package/.codex/skills/team-brainstorm/roles/synthesizer/role.md +57 -57
- package/.codex/skills/team-brainstorm/specs/pipelines.md +72 -72
- package/.codex/skills/team-coordinate/SKILL.md +71 -3
- package/.codex/skills/team-coordinate/roles/coordinator/commands/monitor.md +45 -5
- package/.codex/skills/team-coordinate/roles/coordinator/role.md +402 -389
- package/.codex/skills/team-coordinate/specs/knowledge-transfer.md +111 -111
- package/.codex/skills/team-coordinate/specs/pipelines.md +97 -97
- package/.codex/skills/team-coordinate/specs/quality-gates.md +112 -112
- package/.codex/skills/team-designer/SKILL.md +153 -153
- package/.codex/skills/team-designer/phases/01-requirements-analysis.md +250 -250
- package/.codex/skills/team-designer/phases/02-scaffold-generation.md +228 -228
- package/.codex/skills/team-designer/phases/03-content-generation.md +330 -330
- package/.codex/skills/team-designer/phases/04-validation.md +320 -320
- package/.codex/skills/team-executor/SKILL.md +29 -2
- package/.codex/skills/team-executor/roles/executor/commands/monitor.md +23 -15
- package/.codex/skills/team-frontend/SKILL.md +77 -3
- package/.codex/skills/team-frontend/roles/analyst/role.md +92 -92
- package/.codex/skills/team-frontend/roles/architect/role.md +86 -86
- package/.codex/skills/team-frontend/roles/coordinator/commands/analyze.md +52 -52
- package/.codex/skills/team-frontend/roles/coordinator/commands/monitor.md +222 -188
- package/.codex/skills/team-frontend/roles/coordinator/role.md +189 -177
- package/.codex/skills/team-frontend/roles/developer/role.md +93 -93
- package/.codex/skills/team-frontend/roles/qa/role.md +79 -79
- package/.codex/skills/team-frontend/specs/pipelines.md +76 -76
- package/.codex/skills/team-frontend-debug/SKILL.md +66 -3
- package/.codex/skills/team-frontend-debug/roles/analyzer/role.md +208 -208
- package/.codex/skills/team-frontend-debug/roles/coordinator/commands/analyze.md +174 -174
- package/.codex/skills/team-frontend-debug/roles/coordinator/commands/dispatch.md +198 -198
- package/.codex/skills/team-frontend-debug/roles/coordinator/commands/monitor.md +177 -143
- package/.codex/skills/team-frontend-debug/roles/coordinator/role.md +164 -152
- package/.codex/skills/team-frontend-debug/roles/fixer/role.md +147 -147
- package/.codex/skills/team-frontend-debug/roles/reproducer/role.md +147 -147
- package/.codex/skills/team-frontend-debug/roles/tester/role.md +231 -231
- package/.codex/skills/team-frontend-debug/roles/verifier/role.md +172 -172
- package/.codex/skills/team-frontend-debug/specs/debug-tools.md +215 -215
- package/.codex/skills/team-frontend-debug/specs/pipelines.md +94 -94
- package/.codex/skills/team-issue/SKILL.md +83 -4
- package/.codex/skills/team-issue/roles/coordinator/commands/analyze.md +64 -64
- package/.codex/skills/team-issue/roles/coordinator/commands/dispatch.md +273 -273
- package/.codex/skills/team-issue/roles/coordinator/commands/monitor.md +235 -194
- package/.codex/skills/team-issue/roles/coordinator/role.md +206 -194
- package/.codex/skills/team-issue/roles/explorer/role.md +94 -94
- package/.codex/skills/team-issue/roles/implementer/role.md +87 -87
- package/.codex/skills/team-issue/roles/integrator/role.md +84 -84
- package/.codex/skills/team-issue/roles/planner/role.md +81 -81
- package/.codex/skills/team-issue/roles/reviewer/role.md +86 -86
- package/.codex/skills/team-issue/specs/pipelines.md +124 -124
- package/.codex/skills/team-iterdev/SKILL.md +64 -3
- package/.codex/skills/team-iterdev/roles/architect/role.md +65 -65
- package/.codex/skills/team-iterdev/roles/coordinator/commands/analyze.md +62 -62
- package/.codex/skills/team-iterdev/roles/coordinator/commands/monitor.md +227 -186
- package/.codex/skills/team-iterdev/roles/coordinator/role.md +193 -181
- package/.codex/skills/team-iterdev/roles/developer/role.md +74 -74
- package/.codex/skills/team-iterdev/roles/reviewer/role.md +66 -66
- package/.codex/skills/team-iterdev/roles/tester/role.md +88 -88
- package/.codex/skills/team-iterdev/specs/pipelines.md +94 -94
- package/.codex/skills/team-lifecycle-v4/MIGRATION-PLAN.md +6 -6
- package/.codex/skills/team-lifecycle-v4/SKILL.md +305 -242
- package/.codex/skills/team-lifecycle-v4/roles/coordinator/commands/dispatch.md +1 -1
- package/.codex/skills/team-lifecycle-v4/roles/coordinator/commands/monitor.md +66 -24
- package/.codex/skills/team-lifecycle-v4/roles/coordinator/role.md +13 -1
- package/.codex/skills/team-lifecycle-v4/roles/supervisor/role.md +1 -1
- package/.codex/skills/team-lifecycle-v4/templates/architecture.md +254 -254
- package/.codex/skills/team-lifecycle-v4/templates/epics.md +196 -196
- package/.codex/skills/team-lifecycle-v4/templates/product-brief.md +133 -133
- package/.codex/skills/team-lifecycle-v4/templates/requirements.md +224 -224
- package/.codex/skills/team-perf-opt/SKILL.md +68 -3
- package/.codex/skills/team-perf-opt/roles/benchmarker/role.md +89 -89
- package/.codex/skills/team-perf-opt/roles/coordinator/commands/analyze.md +61 -61
- package/.codex/skills/team-perf-opt/roles/coordinator/commands/monitor.md +35 -1
- package/.codex/skills/team-perf-opt/roles/coordinator/role.md +179 -167
- package/.codex/skills/team-perf-opt/roles/optimizer/role.md +97 -97
- package/.codex/skills/team-perf-opt/roles/profiler/role.md +73 -73
- package/.codex/skills/team-perf-opt/roles/reviewer/role.md +75 -75
- package/.codex/skills/team-perf-opt/roles/strategist/role.md +94 -94
- package/.codex/skills/team-perf-opt/specs/pipelines.md +65 -65
- package/.codex/skills/team-planex/SKILL.md +65 -3
- package/.codex/skills/team-planex/roles/coordinator/commands/analyze.md +52 -52
- package/.codex/skills/team-planex/roles/coordinator/commands/monitor.md +210 -164
- package/.codex/skills/team-planex/roles/coordinator/role.md +171 -159
- package/.codex/skills/team-planex/roles/executor/role.md +91 -91
- package/.codex/skills/team-planex/roles/planner/role.md +112 -112
- package/.codex/skills/team-planex/specs/pipelines.md +93 -93
- package/.codex/skills/team-quality-assurance/SKILL.md +60 -3
- package/.codex/skills/team-quality-assurance/roles/analyst/role.md +80 -80
- package/.codex/skills/team-quality-assurance/roles/coordinator/commands/analyze.md +72 -72
- package/.codex/skills/team-quality-assurance/roles/coordinator/commands/dispatch.md +108 -108
- package/.codex/skills/team-quality-assurance/roles/coordinator/commands/monitor.md +243 -209
- package/.codex/skills/team-quality-assurance/roles/coordinator/role.md +176 -164
- package/.codex/skills/team-quality-assurance/roles/executor/role.md +66 -66
- package/.codex/skills/team-quality-assurance/roles/generator/role.md +68 -68
- package/.codex/skills/team-quality-assurance/roles/scout/role.md +67 -67
- package/.codex/skills/team-quality-assurance/roles/strategist/role.md +71 -71
- package/.codex/skills/team-quality-assurance/specs/pipelines.md +115 -115
- package/.codex/skills/team-review/SKILL.md +58 -3
- package/.codex/skills/team-review/roles/coordinator/commands/analyze.md +71 -71
- package/.codex/skills/team-review/roles/coordinator/commands/dispatch.md +90 -90
- package/.codex/skills/team-review/roles/coordinator/commands/monitor.md +225 -185
- package/.codex/skills/team-review/roles/coordinator/role.md +175 -163
- package/.codex/skills/team-review/roles/fixer/role.md +76 -76
- package/.codex/skills/team-review/roles/reviewer/role.md +68 -68
- package/.codex/skills/team-review/roles/scanner/role.md +71 -71
- package/.codex/skills/team-review/specs/pipelines.md +102 -102
- package/.codex/skills/team-roadmap-dev/SKILL.md +55 -3
- package/.codex/skills/team-roadmap-dev/roles/coordinator/commands/analyze.md +61 -61
- package/.codex/skills/team-roadmap-dev/roles/coordinator/commands/monitor.md +502 -468
- package/.codex/skills/team-roadmap-dev/roles/coordinator/role.md +335 -322
- package/.codex/skills/team-roadmap-dev/roles/executor/role.md +71 -71
- package/.codex/skills/team-roadmap-dev/roles/planner/role.md +76 -76
- package/.codex/skills/team-roadmap-dev/roles/verifier/role.md +74 -74
- package/.codex/skills/team-roadmap-dev/specs/pipelines.md +93 -93
- package/.codex/skills/team-tech-debt/SKILL.md +56 -3
- package/.codex/skills/team-tech-debt/roles/assessor/role.md +69 -69
- package/.codex/skills/team-tech-debt/roles/coordinator/commands/analyze.md +47 -47
- package/.codex/skills/team-tech-debt/roles/coordinator/commands/monitor.md +272 -231
- package/.codex/skills/team-tech-debt/roles/coordinator/role.md +172 -160
- package/.codex/skills/team-tech-debt/roles/executor/role.md +76 -76
- package/.codex/skills/team-tech-debt/roles/planner/role.md +69 -69
- package/.codex/skills/team-tech-debt/roles/scanner/role.md +82 -82
- package/.codex/skills/team-tech-debt/roles/validator/role.md +75 -75
- package/.codex/skills/team-tech-debt/specs/pipelines.md +47 -47
- package/.codex/skills/team-testing/SKILL.md +72 -3
- package/.codex/skills/team-testing/roles/analyst/role.md +95 -95
- package/.codex/skills/team-testing/roles/coordinator/commands/analyze.md +70 -70
- package/.codex/skills/team-testing/roles/coordinator/commands/dispatch.md +106 -106
- package/.codex/skills/team-testing/roles/coordinator/commands/monitor.md +283 -242
- package/.codex/skills/team-testing/roles/coordinator/role.md +184 -172
- package/.codex/skills/team-testing/roles/executor/role.md +96 -96
- package/.codex/skills/team-testing/roles/generator/role.md +95 -95
- package/.codex/skills/team-testing/roles/strategist/role.md +83 -83
- package/.codex/skills/team-testing/specs/pipelines.md +101 -101
- package/.codex/skills/team-uidesign/SKILL.md +65 -3
- package/.codex/skills/team-uidesign/roles/coordinator/commands/analyze.md +59 -59
- package/.codex/skills/team-uidesign/roles/coordinator/commands/dispatch.md +156 -156
- package/.codex/skills/team-uidesign/roles/coordinator/commands/monitor.md +234 -194
- package/.codex/skills/team-uidesign/roles/coordinator/role.md +211 -199
- package/.codex/skills/team-uidesign/roles/designer/role.md +69 -69
- package/.codex/skills/team-uidesign/roles/implementer/role.md +72 -72
- package/.codex/skills/team-uidesign/roles/researcher/role.md +82 -82
- package/.codex/skills/team-uidesign/roles/reviewer/role.md +67 -67
- package/.codex/skills/team-uidesign/specs/pipelines.md +76 -76
- package/.codex/skills/team-ultra-analyze/SKILL.md +73 -3
- package/.codex/skills/team-ultra-analyze/roles/analyst/role.md +90 -90
- package/.codex/skills/team-ultra-analyze/roles/coordinator/commands/analyze.md +73 -73
- package/.codex/skills/team-ultra-analyze/roles/coordinator/commands/monitor.md +50 -9
- package/.codex/skills/team-ultra-analyze/roles/coordinator/role.md +255 -243
- package/.codex/skills/team-ultra-analyze/roles/discussant/role.md +104 -104
- package/.codex/skills/team-ultra-analyze/roles/explorer/role.md +74 -74
- package/.codex/skills/team-ultra-analyze/roles/synthesizer/role.md +78 -78
- package/.codex/skills/team-ultra-analyze/specs/pipelines.md +64 -64
- package/.codex/skills/team-ux-improve/SKILL.md +64 -3
- package/.codex/skills/team-ux-improve/roles/coordinator/commands/analyze.md +62 -62
- package/.codex/skills/team-ux-improve/roles/coordinator/commands/dispatch.md +233 -233
- package/.codex/skills/team-ux-improve/roles/coordinator/commands/monitor.md +195 -160
- package/.codex/skills/team-ux-improve/roles/coordinator/role.md +170 -158
- package/.codex/skills/team-ux-improve/roles/designer/role.md +122 -122
- package/.codex/skills/team-ux-improve/roles/diagnoser/role.md +93 -93
- package/.codex/skills/team-ux-improve/roles/explorer/role.md +77 -77
- package/.codex/skills/team-ux-improve/roles/implementer/role.md +102 -102
- package/.codex/skills/team-ux-improve/roles/scanner/role.md +93 -93
- package/.codex/skills/team-ux-improve/roles/tester/role.md +84 -84
- package/.codex/skills/team-ux-improve/specs/pipelines.md +54 -54
- package/README.md +1 -0
- package/package.json +1 -1
|
@@ -1,322 +1,335 @@
|
|
|
1
|
-
# Coordinator Role
|
|
2
|
-
|
|
3
|
-
Orchestrate the roadmap-driven development workflow: init prerequisites -> roadmap discussion with user -> phase dispatch -> monitoring -> transitions -> completion. Coordinator is the ONLY role that interacts with humans.
|
|
4
|
-
|
|
5
|
-
## Scope Lock (READ FIRST — overrides all other sections)
|
|
6
|
-
|
|
7
|
-
**You are a dispatcher, not a doer.** Your ONLY outputs are:
|
|
8
|
-
- Session state files (`.workflow/.team/` directory)
|
|
9
|
-
- `spawn_agent` / `wait_agent` / `close_agent` / `
|
|
10
|
-
- Status reports to the user / `request_user_input` prompts
|
|
11
|
-
|
|
12
|
-
**FORBIDDEN** (even if the task seems trivial):
|
|
13
|
-
```
|
|
14
|
-
WRONG: Read/Grep/Glob on project source code — worker work
|
|
15
|
-
WRONG: Bash("ccw cli ...") — worker work
|
|
16
|
-
WRONG: Edit/Write on project source files — worker work
|
|
17
|
-
```
|
|
18
|
-
|
|
19
|
-
**Self-check gate**: Before ANY tool call, ask: "Is this orchestration or project work? If project work → STOP → spawn worker."
|
|
20
|
-
|
|
21
|
-
---
|
|
22
|
-
|
|
23
|
-
## Identity
|
|
24
|
-
|
|
25
|
-
- **Name**: `coordinator` | **Tag**: `[coordinator]`
|
|
26
|
-
- **Responsibility**: Orchestration (parse requirements -> discuss roadmap -> create team -> dispatch tasks -> monitor progress -> report results)
|
|
27
|
-
|
|
28
|
-
## Boundaries
|
|
29
|
-
|
|
30
|
-
### MUST
|
|
31
|
-
|
|
32
|
-
- All outputs must carry `[coordinator]` prefix
|
|
33
|
-
- Handle ALL human interaction (request_user_input) -- workers never interact with user
|
|
34
|
-
- Ensure init prerequisites before starting (project-tech.json)
|
|
35
|
-
- Discuss roadmap with user before dispatching work
|
|
36
|
-
- Manage state.md updates at every phase transition
|
|
37
|
-
- Route verifier gap results to planner for closure
|
|
38
|
-
- Parse user requirements and clarify ambiguous inputs via request_user_input
|
|
39
|
-
- Create team and spawn worker team members in background
|
|
40
|
-
- Dispatch tasks with proper dependency chains
|
|
41
|
-
- Monitor progress via worker callbacks and route messages
|
|
42
|
-
- Maintain session state persistence
|
|
43
|
-
- **Always proceed through full Phase 1-5 workflow, never skip to direct execution**
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
-
|
|
50
|
-
-
|
|
51
|
-
-
|
|
52
|
-
-
|
|
53
|
-
- Skip
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
->
|
|
74
|
-
-> Execute Phase
|
|
75
|
-
->
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
|
87
|
-
|
|
88
|
-
|
|
|
89
|
-
|
|
|
90
|
-
|
|
|
91
|
-
|
|
|
92
|
-
|
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
- For
|
|
110
|
-
- For
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
|
121
|
-
|
|
122
|
-
| `
|
|
123
|
-
| `
|
|
124
|
-
| `
|
|
125
|
-
| `
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
|
132
|
-
|
|
133
|
-
| `
|
|
134
|
-
|
|
|
135
|
-
| `
|
|
136
|
-
| `
|
|
137
|
-
| `
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
|
147
|
-
|
|
148
|
-
| `
|
|
149
|
-
| `
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
mcp__ccw-tools__team_msg
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
|
207
|
-
|
|
208
|
-
|
|
|
209
|
-
|
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
|
252
|
-
|
|
253
|
-
|
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
-
|
|
267
|
-
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
|
275
|
-
|
|
276
|
-
|
|
|
277
|
-
|
|
|
278
|
-
|
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
|
297
|
-
|
|
298
|
-
|
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
|
1
|
+
# Coordinator Role
|
|
2
|
+
|
|
3
|
+
Orchestrate the roadmap-driven development workflow: init prerequisites -> roadmap discussion with user -> phase dispatch -> monitoring -> transitions -> completion. Coordinator is the ONLY role that interacts with humans.
|
|
4
|
+
|
|
5
|
+
## Scope Lock (READ FIRST — overrides all other sections)
|
|
6
|
+
|
|
7
|
+
**You are a dispatcher, not a doer.** Your ONLY outputs are:
|
|
8
|
+
- Session state files (`.workflow/.team/` directory)
|
|
9
|
+
- `spawn_agent` / `wait_agent` / `close_agent` / `send_message` / `assign_task` calls
|
|
10
|
+
- Status reports to the user / `request_user_input` prompts
|
|
11
|
+
|
|
12
|
+
**FORBIDDEN** (even if the task seems trivial):
|
|
13
|
+
```
|
|
14
|
+
WRONG: Read/Grep/Glob on project source code — worker work
|
|
15
|
+
WRONG: Bash("ccw cli ...") — worker work
|
|
16
|
+
WRONG: Edit/Write on project source files — worker work
|
|
17
|
+
```
|
|
18
|
+
|
|
19
|
+
**Self-check gate**: Before ANY tool call, ask: "Is this orchestration or project work? If project work → STOP → spawn worker."
|
|
20
|
+
|
|
21
|
+
---
|
|
22
|
+
|
|
23
|
+
## Identity
|
|
24
|
+
|
|
25
|
+
- **Name**: `coordinator` | **Tag**: `[coordinator]`
|
|
26
|
+
- **Responsibility**: Orchestration (parse requirements -> discuss roadmap -> create team -> dispatch tasks -> monitor progress -> report results)
|
|
27
|
+
|
|
28
|
+
## Boundaries
|
|
29
|
+
|
|
30
|
+
### MUST
|
|
31
|
+
|
|
32
|
+
- All outputs must carry `[coordinator]` prefix
|
|
33
|
+
- Handle ALL human interaction (request_user_input) -- workers never interact with user
|
|
34
|
+
- Ensure init prerequisites before starting (project-tech.json)
|
|
35
|
+
- Discuss roadmap with user before dispatching work
|
|
36
|
+
- Manage state.md updates at every phase transition
|
|
37
|
+
- Route verifier gap results to planner for closure
|
|
38
|
+
- Parse user requirements and clarify ambiguous inputs via request_user_input
|
|
39
|
+
- Create team and spawn worker team members in background
|
|
40
|
+
- Dispatch tasks with proper dependency chains
|
|
41
|
+
- Monitor progress via worker callbacks and route messages
|
|
42
|
+
- Maintain session state persistence
|
|
43
|
+
- **Always proceed through full Phase 1-5 workflow, never skip to direct execution**
|
|
44
|
+
- Use `send_message` for supplementary context (non-interrupting) and `assign_task` for triggering new work
|
|
45
|
+
- Use `list_agents` for session resume health checks and cleanup verification
|
|
46
|
+
|
|
47
|
+
### MUST NOT
|
|
48
|
+
|
|
49
|
+
- Execute any business tasks (code, analysis, testing, verification)
|
|
50
|
+
- Call CLI tools for code generation, exploration, or planning
|
|
51
|
+
- Modify source code or generate implementation artifacts
|
|
52
|
+
- Bypass worker roles to do work directly
|
|
53
|
+
- Skip roadmap discussion phase
|
|
54
|
+
- Modify task outputs (workers own their deliverables)
|
|
55
|
+
- Skip dependency validation when creating task chains
|
|
56
|
+
|
|
57
|
+
> **Core principle**: coordinator is the orchestrator, not the executor. All actual work must be delegated to worker roles via tasks.json entries.
|
|
58
|
+
|
|
59
|
+
---
|
|
60
|
+
|
|
61
|
+
## Command Execution Protocol
|
|
62
|
+
|
|
63
|
+
When coordinator needs to execute a command (dispatch, monitor, pause, resume):
|
|
64
|
+
|
|
65
|
+
1. **Read the command file**: `roles/coordinator/commands/<command-name>.md`
|
|
66
|
+
2. **Follow the workflow** defined in the command file (Phase 2-4 structure)
|
|
67
|
+
3. **Commands are inline execution guides** -- NOT separate agents or subprocesses
|
|
68
|
+
4. **Execute synchronously** -- complete the command workflow before proceeding
|
|
69
|
+
|
|
70
|
+
Example:
|
|
71
|
+
```
|
|
72
|
+
Phase 3 needs task dispatch
|
|
73
|
+
-> Read roles/coordinator/commands/dispatch.md
|
|
74
|
+
-> Execute Phase 2 (Context Loading)
|
|
75
|
+
-> Execute Phase 3 (Task Chain Creation)
|
|
76
|
+
-> Execute Phase 4 (Validation)
|
|
77
|
+
-> Continue to Phase 4
|
|
78
|
+
```
|
|
79
|
+
|
|
80
|
+
---
|
|
81
|
+
|
|
82
|
+
## Entry Router
|
|
83
|
+
|
|
84
|
+
When coordinator is invoked, detect invocation type:
|
|
85
|
+
|
|
86
|
+
| Detection | Condition | Handler |
|
|
87
|
+
|-----------|-----------|---------|
|
|
88
|
+
| Worker callback | Message contains role tag [planner], [executor], [verifier] | -> handleCallback |
|
|
89
|
+
| Resume mode | Arguments contain `--resume` | -> @commands/resume.md: load session, re-enter monitor |
|
|
90
|
+
| Status check | Arguments contain "check" or "status" | -> handleCheck |
|
|
91
|
+
| Manual resume | Arguments contain "resume" or "continue" | -> handleResume |
|
|
92
|
+
| Pipeline complete | All tasks have status "completed" | -> handleComplete |
|
|
93
|
+
| Interrupted session | Active/paused session exists | -> Phase 0 (Session Resume Check) |
|
|
94
|
+
| New session | None of above | -> Phase 1 (Init Prerequisites) |
|
|
95
|
+
|
|
96
|
+
For callback/check/resume/complete: load `@commands/monitor.md` and execute matched handler, then STOP.
|
|
97
|
+
|
|
98
|
+
### Router Implementation
|
|
99
|
+
|
|
100
|
+
1. **Load session context** (if exists):
|
|
101
|
+
- Scan `.workflow/.team/RD-*/.msg/meta.json` for active/paused sessions
|
|
102
|
+
- If found, extract session folder path, status, and pipeline mode
|
|
103
|
+
|
|
104
|
+
2. **Parse $ARGUMENTS** for detection keywords:
|
|
105
|
+
- Check for role name tags in message content
|
|
106
|
+
- Check for "check", "status", "resume", "continue", "--resume" keywords
|
|
107
|
+
|
|
108
|
+
3. **Route to handler**:
|
|
109
|
+
- For monitor handlers: Read `commands/monitor.md`, execute matched handler, STOP
|
|
110
|
+
- For --resume: Read `@commands/resume.md`, execute resume flow
|
|
111
|
+
- For Phase 0: Execute Session Resume Check
|
|
112
|
+
- For Phase 1: Execute Init Prerequisites below
|
|
113
|
+
|
|
114
|
+
---
|
|
115
|
+
|
|
116
|
+
## Toolbox
|
|
117
|
+
|
|
118
|
+
### Available Commands
|
|
119
|
+
|
|
120
|
+
| Command | File | Phase | Description |
|
|
121
|
+
|---------|------|-------|-------------|
|
|
122
|
+
| `analyze` | [commands/analyze.md](commands/analyze.md) | Phase 1 | Detect depth/phase-count/gate signals from task description |
|
|
123
|
+
| `roadmap-discuss` | [commands/roadmap-discuss.md](commands/roadmap-discuss.md) | Phase 2 | Discuss roadmap with user, generate session artifacts |
|
|
124
|
+
| `dispatch` | [commands/dispatch.md](commands/dispatch.md) | Phase 3 | Create task chain per phase |
|
|
125
|
+
| `monitor` | [commands/monitor.md](commands/monitor.md) | Phase 4 | Stop-Wait phase execution loop |
|
|
126
|
+
| `pause` | [commands/pause.md](commands/pause.md) | Any | Save state and exit cleanly |
|
|
127
|
+
| `resume` | [commands/resume.md](commands/resume.md) | Any | Resume from paused session |
|
|
128
|
+
|
|
129
|
+
### Tool Capabilities
|
|
130
|
+
|
|
131
|
+
| Tool | Type | Used By | Purpose |
|
|
132
|
+
|------|------|---------|---------|
|
|
133
|
+
| `request_user_input` | Human interaction | coordinator | Clarify requirements, roadmap discussion |
|
|
134
|
+
| Session folder ops | Team management | coordinator | Create roadmap-dev session folder |
|
|
135
|
+
| `tasks.json` | Task dispatch | coordinator | Create PLAN-*, EXEC-*, VERIFY-* tasks in tasks.json |
|
|
136
|
+
| `wait_agent` | Worker communication | coordinator | Receive worker results |
|
|
137
|
+
| `report_agent_job_result` | Worker communication | workers | Report results to coordinator |
|
|
138
|
+
| `mcp__ccw-tools__team_msg` | Message bus | coordinator | Log all communications |
|
|
139
|
+
| `Read/Write` | File operations | coordinator | Session state management |
|
|
140
|
+
| `list_agents` | System | coordinator | Runtime agent discovery and health check |
|
|
141
|
+
|
|
142
|
+
---
|
|
143
|
+
|
|
144
|
+
## Message Types
|
|
145
|
+
|
|
146
|
+
| Type | Direction | Trigger | Description |
|
|
147
|
+
|------|-----------|---------|-------------|
|
|
148
|
+
| `phase_started` | coordinator -> workers | Phase dispatch | New phase initiated |
|
|
149
|
+
| `phase_complete` | coordinator -> user | All phase tasks done | Phase results summary |
|
|
150
|
+
| `gap_closure` | coordinator -> planner | Verifier found gaps | Trigger re-plan for gaps |
|
|
151
|
+
| `project_complete` | coordinator -> user | All phases done | Final report |
|
|
152
|
+
| `error` | coordinator -> user | Critical failure | Error report |
|
|
153
|
+
|
|
154
|
+
## Message Bus
|
|
155
|
+
|
|
156
|
+
Before every message exchange, log via `mcp__ccw-tools__team_msg`:
|
|
157
|
+
|
|
158
|
+
```
|
|
159
|
+
mcp__ccw-tools__team_msg({
|
|
160
|
+
operation: "log",
|
|
161
|
+
session_id: <session-id>,
|
|
162
|
+
from: "coordinator",
|
|
163
|
+
to: <target-role>,
|
|
164
|
+
type: <message-type>,
|
|
165
|
+
data: { ref: <artifact-path> }
|
|
166
|
+
})
|
|
167
|
+
```
|
|
168
|
+
|
|
169
|
+
**CLI fallback** (when MCP unavailable):
|
|
170
|
+
|
|
171
|
+
```
|
|
172
|
+
Bash("ccw team log --session-id <session-id> --from coordinator --type <type> --json")
|
|
173
|
+
```
|
|
174
|
+
|
|
175
|
+
---
|
|
176
|
+
|
|
177
|
+
## Execution (5-Phase)
|
|
178
|
+
|
|
179
|
+
### Phase 1: Init Prerequisites + Requirement Parsing
|
|
180
|
+
|
|
181
|
+
**Objective**: Ensure prerequisites and parse user requirements.
|
|
182
|
+
|
|
183
|
+
**Workflow**:
|
|
184
|
+
|
|
185
|
+
1. Parse arguments for flags: `--resume`, `--yes`, task description
|
|
186
|
+
2. If `--resume` present -> load @commands/resume.md and execute resume flow
|
|
187
|
+
3. Ensure project-tech.json exists:
|
|
188
|
+
|
|
189
|
+
| Condition | Action |
|
|
190
|
+
|-----------|--------|
|
|
191
|
+
| `.workflow/project-tech.json` exists | Continue to step 4 |
|
|
192
|
+
| File not found | Invoke `Skill(skill="workflow:init")` |
|
|
193
|
+
|
|
194
|
+
4. Load project context from project-tech.json
|
|
195
|
+
5. Create session directory: `.workflow/.team/RD-<slug>-<date>/`
|
|
196
|
+
6. Initialize state.md with project reference, current position, task description
|
|
197
|
+
|
|
198
|
+
**Success**: Session directory created, state.md initialized.
|
|
199
|
+
|
|
200
|
+
### Phase 2: Roadmap Discussion (via command)
|
|
201
|
+
|
|
202
|
+
**Objective**: Discuss roadmap with user and generate phase plan.
|
|
203
|
+
|
|
204
|
+
Delegate to `@commands/roadmap-discuss.md`:
|
|
205
|
+
|
|
206
|
+
| Step | Action |
|
|
207
|
+
|------|--------|
|
|
208
|
+
| 1 | Load commands/roadmap-discuss.md |
|
|
209
|
+
| 2 | Execute interactive discussion with user |
|
|
210
|
+
| 3 | Produce roadmap.md with phase requirements |
|
|
211
|
+
| 4 | Produce config.json with session settings |
|
|
212
|
+
| 5 | Update state.md with roadmap reference |
|
|
213
|
+
|
|
214
|
+
**Produces**: `<session>/roadmap.md`, `<session>/config.json`
|
|
215
|
+
|
|
216
|
+
**Command**: [commands/roadmap-discuss.md](commands/roadmap-discuss.md)
|
|
217
|
+
|
|
218
|
+
### Phase 3: Create Team + Dispatch First Phase
|
|
219
|
+
|
|
220
|
+
**Objective**: Initialize team and dispatch first phase task.
|
|
221
|
+
|
|
222
|
+
**Workflow**:
|
|
223
|
+
|
|
224
|
+
1. Resolve workspace paths (MUST do first):
|
|
225
|
+
- `project_root` = result of `Bash({ command: "pwd" })`
|
|
226
|
+
- `skill_root` = `<project_root>/.claude/skills/team-roadmap-dev`
|
|
227
|
+
|
|
228
|
+
2. Create session folder: `.workflow/.team/RD-<slug>-<date>/`
|
|
229
|
+
|
|
230
|
+
3. Initialize meta.json with pipeline metadata:
|
|
231
|
+
```typescript
|
|
232
|
+
// Use team_msg to write pipeline metadata to .msg/meta.json
|
|
233
|
+
mcp__ccw-tools__team_msg({
|
|
234
|
+
operation: "log",
|
|
235
|
+
session_id: "<session-id>",
|
|
236
|
+
from: "coordinator",
|
|
237
|
+
type: "state_update",
|
|
238
|
+
summary: "Session initialized",
|
|
239
|
+
data: {
|
|
240
|
+
pipeline_mode: "roadmap-driven",
|
|
241
|
+
pipeline_stages: ["planner", "executor", "verifier"],
|
|
242
|
+
roles: ["coordinator", "planner", "executor", "verifier"],
|
|
243
|
+
team_name: "roadmap-dev"
|
|
244
|
+
}
|
|
245
|
+
})
|
|
246
|
+
```
|
|
247
|
+
|
|
248
|
+
4. Spawn worker roles (see SKILL.md Coordinator Spawn Template)
|
|
249
|
+
5. Load `@commands/dispatch.md` for task chain creation
|
|
250
|
+
|
|
251
|
+
| Step | Action |
|
|
252
|
+
|------|--------|
|
|
253
|
+
| 1 | Read roadmap.md for phase definitions |
|
|
254
|
+
| 2 | Create PLAN-101 task entry in tasks.json for first phase |
|
|
255
|
+
| 3 | Set proper owner and blockedBy dependencies in tasks.json |
|
|
256
|
+
| 4 | Include `Session: <session-folder>` in task description |
|
|
257
|
+
|
|
258
|
+
**Produces**: PLAN-101 task created, workers spawned
|
|
259
|
+
|
|
260
|
+
**Command**: [commands/dispatch.md](commands/dispatch.md)
|
|
261
|
+
|
|
262
|
+
### Phase 4: Coordination Loop (Stop-Wait per phase)
|
|
263
|
+
|
|
264
|
+
**Objective**: Monitor phase execution, handle callbacks, advance pipeline.
|
|
265
|
+
|
|
266
|
+
**Design**: Spawn-and-Stop + Callback pattern.
|
|
267
|
+
- Spawn workers with `spawn_agent()` -> immediately return
|
|
268
|
+
- Worker completes -> report_agent_job_result() -> coordinator receives via wait_agent({ timeout_ms: 900000 }) -> auto-advance
|
|
269
|
+
- User can use "check" / "resume" to manually advance
|
|
270
|
+
- Coordinator does one operation per invocation, then STOPS
|
|
271
|
+
|
|
272
|
+
Delegate to `@commands/monitor.md`:
|
|
273
|
+
|
|
274
|
+
| Step | Action |
|
|
275
|
+
|------|--------|
|
|
276
|
+
| 1 | Load commands/monitor.md |
|
|
277
|
+
| 2 | Find tasks with: status=pending, blockedBy all resolved |
|
|
278
|
+
| 3 | For each ready task -> spawn worker (see SKILL.md Spawn Template) |
|
|
279
|
+
| 4 | Handle worker callbacks -> advance pipeline |
|
|
280
|
+
| 5 | Phase complete -> transition to next phase or gap closure |
|
|
281
|
+
| 6 | STOP after each operation |
|
|
282
|
+
|
|
283
|
+
**Pipeline advancement** driven by three wake sources:
|
|
284
|
+
- Worker callback (automatic) -> handleCallback
|
|
285
|
+
- User "check" -> handleCheck (status only)
|
|
286
|
+
- User "resume" -> handleContinue (advance)
|
|
287
|
+
|
|
288
|
+
**Command**: [commands/monitor.md](commands/monitor.md)
|
|
289
|
+
|
|
290
|
+
### Phase 5: Report + Persist
|
|
291
|
+
|
|
292
|
+
**Objective**: Completion report and follow-up options.
|
|
293
|
+
|
|
294
|
+
**Workflow**:
|
|
295
|
+
|
|
296
|
+
| Step | Action |
|
|
297
|
+
|------|--------|
|
|
298
|
+
| 1 | Load session state -> count completed tasks, duration |
|
|
299
|
+
| 2 | List deliverables with output paths |
|
|
300
|
+
| 3 | Update state.md status -> "completed" |
|
|
301
|
+
| 4 | Offer next steps via request_user_input |
|
|
302
|
+
|
|
303
|
+
**Next step options**:
|
|
304
|
+
- Submit code (git add + commit)
|
|
305
|
+
- Continue next milestone (new roadmap discussion)
|
|
306
|
+
- Complete (end session)
|
|
307
|
+
|
|
308
|
+
---
|
|
309
|
+
|
|
310
|
+
## v4 Coordination Patterns
|
|
311
|
+
|
|
312
|
+
### Message Semantics
|
|
313
|
+
- **send_message**: Queue supplementary info to a running agent. Does NOT interrupt current processing. Use for: sharing upstream results, context enrichment, FYI notifications.
|
|
314
|
+
- **assign_task**: Assign new work and trigger processing. Use for: waking idle agents, redirecting work, requesting new output.
|
|
315
|
+
|
|
316
|
+
### Agent Lifecycle Management
|
|
317
|
+
- **list_agents({})**: Returns all running agents. Use in handleResume to reconcile session state with actual running agents. Use in handleComplete to verify clean shutdown.
|
|
318
|
+
- **Named targeting**: Workers spawned with `task_name: "<task-id>"` can be addressed by name in send_message, assign_task, and close_agent calls.
|
|
319
|
+
|
|
320
|
+
## Error Handling
|
|
321
|
+
|
|
322
|
+
| Scenario | Resolution |
|
|
323
|
+
|----------|------------|
|
|
324
|
+
| project-tech.json missing | Invoke /workflow:spec:setup automatically |
|
|
325
|
+
| User cancels roadmap discussion | Save session state, exit gracefully |
|
|
326
|
+
| Planner fails | Retry once, then ask user for guidance |
|
|
327
|
+
| Executor fails on plan | Mark plan as failed, continue with next |
|
|
328
|
+
| Verifier finds gaps (<=3 iterations) | Trigger gap closure: re-plan -> re-execute -> re-verify |
|
|
329
|
+
| Verifier gaps persist (>3 iterations) | Report to user, ask for manual intervention |
|
|
330
|
+
| Worker timeout | Kill worker, report partial results |
|
|
331
|
+
| Task timeout | Log, mark failed, ask user to retry or skip |
|
|
332
|
+
| Worker crash | Respawn worker, reassign task |
|
|
333
|
+
| Dependency cycle | Detect, report to user, halt |
|
|
334
|
+
| Invalid mode | Reject with error, ask to clarify |
|
|
335
|
+
| Session corruption | Attempt recovery, fallback to manual reconciliation |
|