claude-code-workflow 7.2.26 → 7.2.27

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.
Files changed (27) hide show
  1. package/.claude/skills/team-arch-opt/SKILL.md +1 -1
  2. package/.claude/skills/team-arch-opt/roles/coordinator/commands/monitor.md +3 -1
  3. package/.claude/skills/team-arch-opt/roles/refactorer/role.md +3 -1
  4. package/.claude/skills/team-arch-opt/specs/team-config.json +2 -2
  5. package/.claude/skills/team-coordinate/SKILL.md +4 -3
  6. package/.claude/skills/team-coordinate/roles/coordinator/commands/analyze-task.md +1 -1
  7. package/.claude/skills/team-coordinate/roles/coordinator/commands/dispatch.md +3 -2
  8. package/.claude/skills/team-coordinate/roles/coordinator/commands/monitor.md +3 -2
  9. package/.claude/skills/team-coordinate/roles/coordinator/role.md +16 -15
  10. package/.claude/skills/team-coordinate/specs/pipelines.md +7 -4
  11. package/.claude/skills/team-coordinate/specs/role-spec-template.md +1 -0
  12. package/.claude/skills/team-lifecycle-v4/SKILL.md +1 -1
  13. package/.claude/skills/team-lifecycle-v4/roles/coordinator/commands/dispatch.md +14 -2
  14. package/.claude/skills/team-lifecycle-v4/roles/coordinator/commands/monitor.md +24 -2
  15. package/.claude/skills/team-lifecycle-v4/roles/executor/role.md +3 -1
  16. package/.claude/skills/team-perf-opt/SKILL.md +1 -1
  17. package/.claude/skills/team-perf-opt/roles/optimizer/role.md +3 -1
  18. package/.claude/skills/team-perf-opt/specs/team-config.json +2 -2
  19. package/.claude/skills/team-quality-assurance/SKILL.md +1 -1
  20. package/.claude/skills/team-quality-assurance/roles/coordinator/commands/dispatch.md +4 -2
  21. package/.claude/skills/team-quality-assurance/roles/coordinator/commands/monitor.md +4 -2
  22. package/.claude/skills/team-quality-assurance/roles/executor/role.md +3 -1
  23. package/.claude/skills/team-testing/SKILL.md +1 -1
  24. package/.claude/skills/team-testing/roles/coordinator/commands/dispatch.md +5 -2
  25. package/.claude/skills/team-testing/roles/coordinator/commands/monitor.md +4 -2
  26. package/.claude/skills/team-testing/roles/executor/role.md +3 -1
  27. package/package.json +1 -1
@@ -78,7 +78,7 @@ Execute built-in Phase 1 (task discovery) -> role Phase 2-4 -> built-in Phase 5
78
78
  })
79
79
  ```
80
80
 
81
- **Inner Loop roles** (refactorer): Set `inner_loop: true`.
81
+ **Inner Loop roles** (refactorer): Set `inner_loop` dynamically — `true` for single mode, `false` for fan-out/independent (parallel branches).
82
82
  **Single-task roles** (analyzer, designer, validator, reviewer): Set `inner_loop: false`.
83
83
 
84
84
  ## User Commands
@@ -82,7 +82,9 @@ Find ready tasks, spawn workers, STOP.
82
82
  2. No ready + work in progress -> report waiting, STOP
83
83
  3. No ready + nothing in progress -> handleComplete
84
84
  4. Has ready -> for each:
85
- a. Check if inner loop role with active worker -> skip (worker picks up)
85
+ a. Check inner_loop: parse task description `InnerLoop:` field (NOT role.md default)
86
+ - InnerLoop: true AND same-role worker already active -> skip (worker picks up)
87
+ - InnerLoop: false OR no active same-role worker -> spawn new worker
86
88
  b. TaskUpdate -> in_progress
87
89
  c. team_msg log -> task_unblocked
88
90
  d. Spawn team-worker (see SKILL.md Spawn Template):
@@ -1,12 +1,14 @@
1
1
  ---
2
2
  role: refactorer
3
3
  prefix: REFACTOR
4
- inner_loop: true
4
+ inner_loop: dynamic
5
5
  message_types: [state_update]
6
6
  ---
7
7
 
8
8
  # Code Refactorer
9
9
 
10
+ > **inner_loop: dynamic** — Dispatch sets per-task: `true` for single mode (one REFACTOR task with iterative fix cycles), `false` for fan-out/independent modes (REFACTOR-B01..N run as separate parallel workers). When false, each branch gets its own worker.
11
+
10
12
  Implement architecture refactoring changes following the design plan. For FIX tasks, apply targeted corrections based on review/validation feedback.
11
13
 
12
14
  ## Modes
@@ -64,10 +64,10 @@
64
64
  "type": "code_generation",
65
65
  "description": "Implements architecture refactoring changes following the design plan",
66
66
  "role_spec": "roles/refactorer/role.md",
67
- "inner_loop": true,
67
+ "inner_loop": "dynamic",
68
68
  "frontmatter": {
69
69
  "prefix": "REFACTOR",
70
- "inner_loop": true,
70
+ "inner_loop": "dynamic",
71
71
  "additional_prefixes": ["FIX"],
72
72
  "discuss_rounds": [],
73
73
  "cli_tools": ["explore"],
@@ -130,9 +130,10 @@ Execute built-in Phase 1 (task discovery) -> role-spec Phase 2-4 -> built-in Pha
130
130
  })
131
131
  ```
132
132
 
133
- **Inner Loop roles** (role has 2+ serial same-prefix tasks): Set `inner_loop: true`. The team-worker agent handles the loop internally.
134
-
135
- **Single-task roles**: Set `inner_loop: false`.
133
+ **Inner Loop**: Determined per-task from task description `InnerLoop:` field, not per-role:
134
+ - Serial chain (2+ tasks, each blockedBy previous): `inner_loop: true` — single worker loops
135
+ - Parallel tasks (no mutual blockedBy): `inner_loop: false` — separate workers per task
136
+ - Single-task roles: `inner_loop: false`
136
137
 
137
138
  ---
138
139
 
@@ -130,7 +130,7 @@ For each role, determine frontmatter and generation hints:
130
130
  | Field | Derivation |
131
131
  |-------|------------|
132
132
  | `prefix` | From capability prefix (e.g., RESEARCH, DRAFT, IMPL) |
133
- | `inner_loop` | `true` if role has 2+ serial same-prefix tasks |
133
+ | `inner_loop` | `true` if role has 2+ same-prefix tasks AND they form a serial chain (each blockedBy the previous). `false` if tasks are parallel (no mutual blockedBy) or role has only 1 task |
134
134
  | `CLI tools` | Suggested, not mandatory — coordinator may adjust based on task needs |
135
135
  | `pattern_hint` | Reference pattern name from role-spec-template (research/document/code/analysis/validation) — guides coordinator's Phase 2-4 composition, NOT a rigid template selector |
136
136
  | `output_type` | `artifact` (new files in session/artifacts/) / `codebase` (modify existing project files) / `mixed` (both) — determines verification strategy in Behavioral Traits |
@@ -95,9 +95,10 @@ RoleSpec: <session-folder>/role-specs/<role-name>.md
95
95
 
96
96
  | Condition | InnerLoop |
97
97
  |-----------|-----------|
98
- | Role has 2+ serial same-prefix tasks | true |
98
+ | Role has 2+ same-prefix tasks forming a serial chain (each blockedBy the previous) | true |
99
99
  | Role has 1 task | false |
100
- | Tasks are parallel (no dependency between them) | false |
100
+ | Role has 2+ same-prefix tasks but they are parallel (no mutual blockedBy) | false |
101
+ | Mixed: some serial, some parallel within same role | Set per-task: true for serial chain members, false for parallel members |
101
102
 
102
103
  ### Dependency Validation
103
104
 
@@ -144,9 +144,10 @@ Ready tasks found?
144
144
  +- NONE + work in progress -> report waiting -> STOP
145
145
  +- NONE + nothing in progress -> PIPELINE_COMPLETE -> handleComplete
146
146
  +- HAS ready tasks -> for each:
147
- +- Is task owner an Inner Loop role AND that role already has an active_worker?
147
+ +- Parse task description `InnerLoop:` field (NOT session.roles[].inner_loop)
148
+ +- InnerLoop: true AND same-role worker already in active_workers?
148
149
  | +- YES -> SKIP spawn (existing worker will pick it up via inner loop)
149
- | +- NO -> normal spawn below
150
+ | +- NO -> normal spawn below (InnerLoop: false OR no active same-role worker)
150
151
  +- TaskUpdate -> in_progress
151
152
  +- team_msg log -> task_unblocked (session_id=<session-id>)
152
153
  +- Spawn team-worker (see spawn tool call below)
@@ -207,15 +207,9 @@ Regardless of complexity score or role count, coordinator MUST:
207
207
  - `project_root` = result of `Bash({ command: "pwd" })`
208
208
  - `skill_root` = `<project_root>/.claude/skills/team-coordinate`
209
209
 
210
- 2. **Check `needs_research` flag** from task-analysis.json:
211
- - If `true`: **Spawn researcher worker first** to gather codebase context
212
- - Wait for researcher callback
213
- - Merge research findings into task context
214
- - Update task-analysis.json with enriched context
210
+ 2. **Generate session ID**: `TC-<slug>-<date>` (slug from first 3 meaningful words of task)
215
211
 
216
- 3. **Generate session ID**: `TC-<slug>-<date>` (slug from first 3 meaningful words of task)
217
-
218
- 4. **Create session folder structure**:
212
+ 3. **Create session folder structure**:
219
213
  ```
220
214
  .workflow/.team/<session-id>/
221
215
  +-- role-specs/
@@ -226,11 +220,11 @@ Regardless of complexity score or role count, coordinator MUST:
226
220
  +-- .msg/
227
221
  ```
228
222
 
229
- 5. **Call TeamCreate** with team name derived from session ID
223
+ 4. **Call TeamCreate** with team name derived from session ID
230
224
 
231
- 6. **Read `specs/role-spec-template.md`** for Behavioral Traits + Reference Patterns
225
+ 5. **Read `specs/role-spec-template.md`** for Behavioral Traits + Reference Patterns
232
226
 
233
- 7. **For each role in task-analysis.json#roles**:
227
+ 6. **For each role in task-analysis.json#roles**:
234
228
  - Fill YAML frontmatter: role, prefix, inner_loop, additional_members, message_types
235
229
  - **Compose Phase 2-4 content** (NOT copy from template):
236
230
  - Phase 2: Derive input sources and context loading steps from **task description + upstream dependencies**
@@ -239,14 +233,14 @@ Regardless of complexity score or role count, coordinator MUST:
239
233
  - Reference Patterns may guide phase structure, but task description determines specific content
240
234
  - Write generated role-spec to `<session>/role-specs/<role-name>.md`
241
235
 
242
- 8. **Register roles** in team-session.json#roles (with `role_spec` path instead of `role_file`)
236
+ 7. **Register roles** in team-session.json#roles (with `role_spec` path instead of `role_file`)
243
237
 
244
- 9. **Initialize shared infrastructure**:
238
+ 8. **Initialize shared infrastructure**:
245
239
  - `wisdom/learnings.md`, `wisdom/decisions.md`, `wisdom/issues.md` (empty with headers)
246
240
  - `explorations/cache-index.json` (`{ "entries": [] }`)
247
241
  - `discussions/` (empty directory)
248
242
 
249
- 10. **Initialize pipeline metadata** via team_msg:
243
+ 9. **Initialize pipeline metadata** via team_msg:
250
244
  ```typescript
251
245
  // 使用 team_msg 将 pipeline 元数据写入 .msg/meta.json
252
246
  // 注意: 此处为动态角色,执行时需将 <placeholders> 替换为 task-analysis.json 中生成的实际角色列表
@@ -265,7 +259,14 @@ mcp__ccw-tools__team_msg({
265
259
  })
266
260
  ```
267
261
 
268
- 11. **Write team-session.json** with: session_id, task_description, status="active", roles, pipeline (empty), active_workers=[], completion_action="interactive", created_at
262
+ 10. **Write team-session.json** with: session_id, task_description, status="active", roles, pipeline (empty), active_workers=[], completion_action="interactive", created_at
263
+
264
+ 11. **Check `needs_research` flag** from task-analysis.json:
265
+ - If `true`: Spawn researcher worker (role-spec now exists from step 6) to gather codebase context
266
+ - Wait for researcher callback
267
+ - Merge research findings into task context
268
+ - Update task-analysis.json with enriched context
269
+ - If `false`: Skip, proceed to Phase 3
269
270
 
270
271
  **Success**: Session created, role-spec files generated, shared infrastructure initialized.
271
272
 
@@ -38,18 +38,20 @@ Phase 3-N: monitor.md
38
38
 
39
39
  ## Dependency Graph Structure
40
40
 
41
- task-analysis.json encodes the pipeline:
41
+ task-analysis.json encodes the pipeline as adjacency list (task ID -> blockedBy array):
42
42
 
43
43
  ```json
44
44
  {
45
45
  "dependency_graph": {
46
- "RESEARCH-001": { "role": "researcher", "blockedBy": [], "priority": "P0" },
47
- "IMPL-001": { "role": "developer", "blockedBy": ["RESEARCH-001"], "priority": "P1" },
48
- "TEST-001": { "role": "tester", "blockedBy": ["IMPL-001"], "priority": "P2" }
46
+ "RESEARCH-001": [],
47
+ "IMPL-001": ["RESEARCH-001"],
48
+ "TEST-001": ["IMPL-001"]
49
49
  }
50
50
  }
51
51
  ```
52
52
 
53
+ Role mapping comes from `task-analysis.json#capabilities[].tasks[]`, not from the dependency graph itself.
54
+
53
55
  ## Role-Worker Map
54
56
 
55
57
  Dynamic — loaded from session role-specs at runtime:
@@ -64,6 +66,7 @@ Role-spec files contain YAML frontmatter:
64
66
  role: <role-name>
65
67
  prefix: <PREFIX>
66
68
  inner_loop: <true|false>
69
+ output_tag: "[<role-name>]"
67
70
  message_types:
68
71
  success: <type>
69
72
  error: error
@@ -11,6 +11,7 @@ Template used by coordinator to generate lightweight worker role-spec files at r
11
11
  role: <role_name>
12
12
  prefix: <PREFIX>
13
13
  inner_loop: <true|false>
14
+ output_tag: "[<role_name>]"
14
15
  CLI tools: [<CLI tool-names>]
15
16
  message_types:
16
17
  success: <prefix>_complete
@@ -40,7 +40,7 @@ Skill(skill="team-lifecycle-v4", args="task description")
40
40
  | analyst | [roles/analyst/role.md](roles/analyst/role.md) | RESEARCH-* | false |
41
41
  | writer | [roles/writer/role.md](roles/writer/role.md) | DRAFT-* | true |
42
42
  | planner | [roles/planner/role.md](roles/planner/role.md) | PLAN-* | true |
43
- | executor | [roles/executor/role.md](roles/executor/role.md) | IMPL-* | true |
43
+ | executor | [roles/executor/role.md](roles/executor/role.md) | IMPL-* | dynamic |
44
44
  | tester | [roles/tester/role.md](roles/tester/role.md) | TEST-* | false |
45
45
  | reviewer | [roles/reviewer/role.md](roles/reviewer/role.md) | REVIEW-*, QUALITY-*, IMPROVE-* | false |
46
46
  | supervisor | [roles/supervisor/role.md](roles/supervisor/role.md) | CHECKPOINT-* | false |
@@ -34,8 +34,20 @@ RoleSpec: ~ or <project>/.claude/skills/team-lifecycle-v4/roles/<role>/role.md
34
34
 
35
35
  ## InnerLoop Flag Rules
36
36
 
37
- - true: Role has 2+ serial same-prefix tasks (writer: DRAFT-001->004)
38
- - false: Role has 1 task, or tasks are parallel
37
+ - true: Role has 2+ serial same-prefix tasks (writer: DRAFT-001->004) where each blockedBy the previous
38
+ - false: Role has 1 task, or tasks are parallel (no mutual blockedBy)
39
+
40
+ ### Parallel Detection for IMPL Tasks
41
+
42
+ When creating IMPL-{1..N} tasks from PLAN-001 output:
43
+
44
+ 1. Read plan.json → extract `tasks[]` with their `depends_on` fields
45
+ 2. Build dependency graph among IMPL tasks only
46
+ 3. Classify:
47
+ - **Serial chain**: IMPL-002 blockedBy IMPL-001 → both get `InnerLoop: true`, single worker
48
+ - **Parallel set**: IMPL-001..N all blockedBy PLAN-001 only (no mutual deps) → each gets `InnerLoop: false`, separate workers
49
+ - **Mixed DAG**: Some parallel, some serial → group into independent chains, each chain gets one worker with `InnerLoop: true`; independent chains spawn in parallel
50
+ 4. Set `InnerLoop` in each task description accordingly
39
51
 
40
52
  ## CHECKPOINT Task Rules
41
53
 
@@ -36,9 +36,29 @@ Worker completed. Process and advance.
36
36
  - CHECKPOINT-* with verdict "warn" -> log risks to wisdom, proceed normally
37
37
  - CHECKPOINT-* with verdict "pass" -> proceed normally
38
38
  - QUALITY-001 -> display quality gate, pause for user commands
39
- - PLAN-001 -> read plan.json complexity, create dynamic IMPL tasks per specs/pipelines.md routing
39
+ - PLAN-001 -> dynamicImplDispatch (see below)
40
40
  6. -> handleSpawnNext
41
41
 
42
+ ### dynamicImplDispatch (PLAN-001 callback)
43
+
44
+ When PLAN-001 completes, coordinator creates IMPL tasks based on complexity:
45
+
46
+ 1. Read `<session>/plan/plan.json` → extract `complexity`, `tasks[]`
47
+ 2. Route by complexity (per specs/pipelines.md §6):
48
+
49
+ | Complexity | Action |
50
+ |------------|--------|
51
+ | Low (1-2 modules) | Create single IMPL-001, blockedBy: [PLAN-001], InnerLoop: true |
52
+ | Medium (3-4 modules) | Create IMPL-{1..N}, each blockedBy: [PLAN-001] only, InnerLoop: false |
53
+ | High (5+ modules) | Create IMPL-{1..N} with DAG deps from plan.json, InnerLoop per dispatch rules |
54
+
55
+ 3. For each IMPL task: TaskCreate with structured description (dispatch.md template)
56
+ 4. Set blockedBy:
57
+ - **Parallel tasks**: blockedBy: [PLAN-001] (or [CHECKPOINT-003] if supervision enabled)
58
+ - **Serial chain within DAG**: blockedBy includes upstream IMPL task IDs
59
+ 5. Update team-session.json: `pipeline.tasks_total`, `pipeline.impl_topology: "single"|"parallel"|"dag"`
60
+ 6. Log via team_msg: `{ type: "state_update", data: { impl_count: N, topology: "..." } }`
61
+
42
62
  ## handleCheck
43
63
 
44
64
  Read-only status report, then STOP.
@@ -71,7 +91,9 @@ Find ready tasks, spawn workers, STOP.
71
91
  2. No ready + work in progress -> report waiting, STOP
72
92
  3. No ready + nothing in progress -> handleComplete
73
93
  4. Has ready -> for each:
74
- a. Check if inner loop role with active worker -> skip (worker picks up)
94
+ a. Check inner_loop: parse task description `InnerLoop:` field (NOT role.md default)
95
+ - InnerLoop: true AND same-role worker already active -> skip (worker picks up next task)
96
+ - InnerLoop: false OR no active same-role worker -> spawn new worker
75
97
  b. **CHECKPOINT-* task** -> wake resident supervisor (see below)
76
98
  c. Other tasks -> standard spawn:
77
99
  - TaskUpdate -> in_progress
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  role: executor
3
3
  prefix: IMPL
4
- inner_loop: true
4
+ inner_loop: dynamic
5
5
  message_types:
6
6
  success: impl_complete
7
7
  progress: impl_progress
@@ -12,6 +12,8 @@ message_types:
12
12
 
13
13
  Code implementation worker with dual execution modes.
14
14
 
15
+ > **inner_loop: dynamic** — Dispatch sets per-task: `true` for serial IMPL chains (IMPL-001→002→003 with inter-dependencies), `false` for parallel IMPL sets (independent modules). When false, each IMPL task gets its own worker.
16
+
15
17
  ## Identity
16
18
  - Tag: [executor] | Prefix: IMPL-*
17
19
  - Responsibility: Implement code from plan tasks via agent or CLI delegation
@@ -90,7 +90,7 @@ Execute built-in Phase 1 (task discovery) -> role Phase 2-4 -> built-in Phase 5
90
90
  })
91
91
  ```
92
92
 
93
- **Inner Loop roles** (optimizer): Set `inner_loop: true`.
93
+ **Inner Loop roles** (optimizer): Set `inner_loop` dynamically — `true` for single mode, `false` for fan-out/independent (parallel branches).
94
94
  **Single-task roles** (profiler, strategist, benchmarker, reviewer): Set `inner_loop: false`.
95
95
 
96
96
  ## User Commands
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  role: optimizer
3
3
  prefix: IMPL
4
- inner_loop: true
4
+ inner_loop: dynamic
5
5
  additional_prefixes: [FIX]
6
6
  message_types:
7
7
  success: impl_complete
@@ -11,6 +11,8 @@ message_types:
11
11
 
12
12
  # Code Optimizer
13
13
 
14
+ > **inner_loop: dynamic** — Dispatch sets per-task: `true` for single mode (one IMPL task with iterative fix cycles), `false` for fan-out/independent modes (IMPL-B01..N run as separate parallel workers). When false, each branch gets its own worker.
15
+
14
16
  Implement optimization changes following the strategy plan. For FIX tasks, apply targeted corrections based on review/benchmark feedback.
15
17
 
16
18
  ## Modes
@@ -65,10 +65,10 @@
65
65
  "type": "code_generation",
66
66
  "description": "Implements optimization changes following the strategy plan",
67
67
  "role_spec": "roles/optimizer/role.md",
68
- "inner_loop": true,
68
+ "inner_loop": "dynamic",
69
69
  "frontmatter": {
70
70
  "prefix": "IMPL",
71
- "inner_loop": true,
71
+ "inner_loop": "dynamic",
72
72
  "additional_prefixes": ["FIX"],
73
73
  "discuss_rounds": [],
74
74
  "delegates_to": [],
@@ -38,7 +38,7 @@ Skill(skill="team-quality-assurance", args="task description")
38
38
  | scout | [roles/scout/role.md](roles/scout/role.md) | SCOUT-* | false |
39
39
  | strategist | [roles/strategist/role.md](roles/strategist/role.md) | QASTRAT-* | false |
40
40
  | generator | [roles/generator/role.md](roles/generator/role.md) | QAGEN-* | false |
41
- | executor | [roles/executor/role.md](roles/executor/role.md) | QARUN-* | true |
41
+ | executor | [roles/executor/role.md](roles/executor/role.md) | QARUN-* | dynamic |
42
42
  | analyst | [roles/analyst/role.md](roles/analyst/role.md) | QAANA-* | false |
43
43
 
44
44
  ## Role Router
@@ -87,8 +87,10 @@ SCOUT-002 (scout): Regression scan after fixes
87
87
 
88
88
  ## InnerLoop Flag Rules
89
89
 
90
- - true: executor roles (run-fix cycles)
91
- - false: scout, strategist, generator, analyst roles
90
+ - **executor**: dynamic per pipeline mode:
91
+ - Discovery/Testing: `true` (serial layer chain, single executor handles GC loops)
92
+ - Full: `false` for parallel QARUN tasks (QARUN-L1-001 and QARUN-L2-001 have independent blockedBy, each gets own worker)
93
+ - **scout, strategist, generator, analyst**: always false
92
94
 
93
95
  ## Dependency Validation
94
96
 
@@ -132,10 +132,12 @@ Find ready tasks, spawn workers, STOP.
132
132
  | SCOUT-* | scout | false |
133
133
  | QASTRAT-* | strategist | false |
134
134
  | QAGEN-* | generator | false |
135
- | QARUN-* | executor | true |
135
+ | QARUN-* | executor | dynamic |
136
136
  | QAANA-* | analyst | false |
137
137
 
138
- b. Check if inner loop role with active worker -> skip (worker picks up next task)
138
+ b. Check inner_loop: parse task description `InnerLoop:` field (NOT role.md default)
139
+ - InnerLoop: true AND same-role worker already active -> skip (worker picks up next task)
140
+ - InnerLoop: false OR no active same-role worker -> spawn new worker
139
141
  c. TaskUpdate -> in_progress
140
142
  d. team_msg log -> task_unblocked
141
143
  e. Spawn team-worker:
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  role: executor
3
3
  prefix: QARUN
4
- inner_loop: true
4
+ inner_loop: dynamic
5
5
  additional_prefixes: [QARUN-gc]
6
6
  message_types:
7
7
  success: tests_passed
@@ -12,6 +12,8 @@ message_types:
12
12
 
13
13
  # Test Executor
14
14
 
15
+ > **inner_loop: dynamic** — Dispatch sets per-task: `true` for serial layer chains (discovery/testing mode), `false` for parallel layer execution (full mode where QARUN-L1-001 and QARUN-L2-001 run independently). When false, each QARUN task gets its own worker.
16
+
15
17
  Run test suites, collect coverage data, and perform automatic fix cycles when tests fail. Implements the execution side of the Generator-Executor (GC) loop.
16
18
 
17
19
  ## Phase 2: Environment Detection
@@ -37,7 +37,7 @@ Skill(skill="team-testing", args="task description")
37
37
  | coordinator | [roles/coordinator/role.md](roles/coordinator/role.md) | — | — |
38
38
  | strategist | [roles/strategist/role.md](roles/strategist/role.md) | STRATEGY-* | false |
39
39
  | generator | [roles/generator/role.md](roles/generator/role.md) | TESTGEN-* | true |
40
- | executor | [roles/executor/role.md](roles/executor/role.md) | TESTRUN-* | true |
40
+ | executor | [roles/executor/role.md](roles/executor/role.md) | TESTRUN-* | dynamic |
41
41
  | analyst | [roles/analyst/role.md](roles/analyst/role.md) | TESTANA-* | false |
42
42
 
43
43
  ## Role Router
@@ -84,8 +84,11 @@ TESTANA-001 (analyst): Defect pattern analysis, quality report
84
84
 
85
85
  ## InnerLoop Flag Rules
86
86
 
87
- - true: generator, executor roles (GC loop iterations)
88
- - false: strategist, analyst roles
87
+ - **generator**: always true (GC loop iterations within a single layer)
88
+ - **executor**: dynamic per pipeline mode:
89
+ - Targeted/Standard: `true` (serial layer chain, single executor handles GC loops)
90
+ - Comprehensive: `false` for parallel TESTRUN tasks (TESTRUN-001 and TESTRUN-002 have independent blockedBy, each gets own worker)
91
+ - **strategist, analyst**: always false
89
92
 
90
93
  ## Dependency Validation
91
94
 
@@ -27,7 +27,7 @@ Event-driven pipeline coordination. Beat model: coordinator wake -> process -> s
27
27
  |--------|------|-----------|------------|
28
28
  | STRATEGY-* | strategist | `~ or <project>/.claude/skills/team-testing/roles/strategist/role.md` | false |
29
29
  | TESTGEN-* | generator | `~ or <project>/.claude/skills/team-testing/roles/generator/role.md` | true |
30
- | TESTRUN-* | executor | `~ or <project>/.claude/skills/team-testing/roles/executor/role.md` | true |
30
+ | TESTRUN-* | executor | `~ or <project>/.claude/skills/team-testing/roles/executor/role.md` | dynamic |
31
31
  | TESTANA-* | analyst | `~ or <project>/.claude/skills/team-testing/roles/analyst/role.md` | false |
32
32
 
33
33
  ## handleCallback
@@ -136,7 +136,9 @@ Find ready tasks, spawn workers, STOP.
136
136
  3. No ready + nothing in progress -> handleComplete
137
137
  4. Has ready -> for each ready task:
138
138
  a. Determine role from prefix (use Role-Worker Map)
139
- b. Check if inner loop role (generator/executor) with active worker -> skip (worker picks up next task)
139
+ b. Check inner_loop: parse task description `InnerLoop:` field (NOT role.md default)
140
+ - InnerLoop: true AND same-role worker already active -> skip (worker picks up next task)
141
+ - InnerLoop: false OR no active same-role worker -> spawn new worker
140
142
  c. TaskUpdate -> in_progress
141
143
  d. team_msg log -> task_unblocked
142
144
  e. Spawn team-worker:
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  role: executor
3
3
  prefix: TESTRUN
4
- inner_loop: true
4
+ inner_loop: dynamic
5
5
  message_types:
6
6
  success: tests_passed
7
7
  failure: tests_failed
@@ -11,6 +11,8 @@ message_types:
11
11
 
12
12
  # Test Executor
13
13
 
14
+ > **inner_loop: dynamic** — Dispatch sets per-task: `true` for serial GC loops (single layer pipeline), `false` for parallel layer execution (comprehensive pipeline where TESTRUN-001 and TESTRUN-002 run independently). When false, each TESTRUN task gets its own worker.
15
+
14
16
  Execute tests, collect coverage, attempt auto-fix for failures. Acts as the Critic in the Generator-Critic loop. Reports pass rate and coverage for coordinator GC decisions.
15
17
 
16
18
  ## Phase 2: Context Loading
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "claude-code-workflow",
3
- "version": "7.2.26",
3
+ "version": "7.2.27",
4
4
  "description": "JSON-driven multi-agent development framework with intelligent CLI orchestration (Gemini/Qwen/Codex), context-first architecture, and automated workflow execution",
5
5
  "type": "module",
6
6
  "main": "ccw/dist/index.js",