claude-code-workflow 7.2.30 → 7.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (183) hide show
  1. package/.claude/commands/workflow-skill.md +130 -0
  2. package/.claude/skills/ccw-chain/SKILL.md +44 -71
  3. package/.claude/skills/ccw-chain/chains/ccw-cycle.json +13 -3
  4. package/.claude/skills/ccw-chain/chains/ccw-exploration.json +33 -22
  5. package/.claude/skills/ccw-chain/chains/ccw-issue.json +23 -12
  6. package/.claude/skills/ccw-chain/chains/ccw-lightweight.json +23 -9
  7. package/.claude/skills/ccw-chain/chains/ccw-main.json +15 -2
  8. package/.claude/skills/ccw-chain/chains/ccw-standard.json +28 -16
  9. package/.claude/skills/ccw-chain/chains/ccw-team.json +7 -2
  10. package/.claude/skills/ccw-chain/chains/ccw-with-file.json +25 -9
  11. package/.claude/skills/chain-loader/phases/01-analyze-skill.md +53 -53
  12. package/.claude/skills/chain-loader/specs/chain-schema.md +30 -3
  13. package/.claude/skills/chain-loader/templates/chain-json.md +63 -63
  14. package/.claude/skills/workflow-plan/SKILL.md +1 -0
  15. package/.claude/skills/workflow-plan/phases/01-session-discovery.md +19 -2
  16. package/.claude/skills/workflow-plan/phases/02-context-gathering.md +2 -2
  17. package/.claude/skills/workflow-plan/phases/04-task-generation.md +9 -1
  18. package/.codex/skills/analyze-with-file/SKILL.md +383 -134
  19. package/.codex/skills/brainstorm/SKILL.md +3 -3
  20. package/.codex/skills/brainstorm-with-file/SKILL.md +208 -88
  21. package/.codex/skills/clean/SKILL.md +1 -1
  22. package/.codex/skills/csv-wave-pipeline/SKILL.md +2 -2
  23. package/.codex/skills/investigate/orchestrator.md +24 -0
  24. package/.codex/skills/issue-discover/SKILL.md +374 -361
  25. package/.codex/skills/issue-discover/phases/01-issue-new.md +1 -1
  26. package/.codex/skills/issue-discover/phases/02-discover.md +2 -2
  27. package/.codex/skills/issue-discover/phases/03-discover-by-prompt.md +1 -1
  28. package/.codex/skills/issue-discover/phases/04-quick-execute.md +2 -2
  29. package/.codex/skills/parallel-dev-cycle/SKILL.md +44 -37
  30. package/.codex/skills/project-documentation-workflow/SKILL.md +1 -1
  31. package/.codex/skills/review-cycle/SKILL.md +31 -12
  32. package/.codex/skills/roadmap-with-file/SKILL.md +141 -133
  33. package/.codex/skills/security-audit/orchestrator.md +29 -0
  34. package/.codex/skills/session-sync/SKILL.md +1 -1
  35. package/.codex/skills/ship/orchestrator.md +24 -0
  36. package/.codex/skills/spec-add/SKILL.md +5 -5
  37. package/.codex/skills/spec-generator/SKILL.md +33 -2
  38. package/.codex/skills/spec-generator/phases/01-5-requirement-clarification.md +3 -3
  39. package/.codex/skills/spec-generator/phases/01-discovery.md +1 -1
  40. package/.codex/skills/spec-generator/phases/02-product-brief.md +1 -1
  41. package/.codex/skills/spec-generator/phases/03-requirements.md +1 -1
  42. package/.codex/skills/spec-generator/phases/04-architecture.md +1 -1
  43. package/.codex/skills/spec-generator/phases/05-epics-stories.md +1 -1
  44. package/.codex/skills/spec-generator/phases/06-readiness-check.md +1 -1
  45. package/.codex/skills/spec-generator/phases/07-issue-export.md +1 -1
  46. package/.codex/skills/spec-setup/SKILL.md +669 -669
  47. package/.codex/skills/team-arch-opt/specs/team-config.json +1 -1
  48. package/.codex/skills/team-brainstorm/SKILL.md +259 -259
  49. package/.codex/skills/team-coordinate/SKILL.md +359 -359
  50. package/.codex/skills/team-coordinate/roles/coordinator/commands/monitor.md +1 -1
  51. package/.codex/skills/team-designer/SKILL.md +27 -1
  52. package/.codex/skills/team-designer/phases/01-requirements-analysis.md +2 -2
  53. package/.codex/skills/team-designer/phases/02-scaffold-generation.md +1 -1
  54. package/.codex/skills/team-designer/phases/04-validation.md +1 -1
  55. package/.codex/skills/team-executor/SKILL.md +218 -218
  56. package/.codex/skills/team-frontend/SKILL.md +227 -227
  57. package/.codex/skills/team-frontend-debug/SKILL.md +278 -278
  58. package/.codex/skills/team-frontend-debug/roles/coordinator/commands/analyze.md +2 -2
  59. package/.codex/skills/team-interactive-craft/SKILL.md +220 -220
  60. package/.codex/skills/team-interactive-craft/roles/coordinator/role.md +209 -209
  61. package/.codex/skills/team-issue/SKILL.md +269 -269
  62. package/.codex/skills/team-issue/roles/coordinator/role.md +1 -1
  63. package/.codex/skills/team-lifecycle-v4/SKILL.md +305 -305
  64. package/.codex/skills/team-motion-design/SKILL.md +222 -222
  65. package/.codex/skills/team-motion-design/roles/coordinator/role.md +210 -210
  66. package/.codex/skills/team-perf-opt/SKILL.md +258 -258
  67. package/.codex/skills/team-perf-opt/specs/team-config.json +1 -1
  68. package/.codex/skills/team-planex/SKILL.md +216 -216
  69. package/.codex/skills/team-quality-assurance/SKILL.md +229 -229
  70. package/.codex/skills/team-review/SKILL.md +227 -227
  71. package/.codex/skills/team-roadmap-dev/SKILL.md +238 -238
  72. package/.codex/skills/team-roadmap-dev/roles/coordinator/commands/roadmap-discuss.md +5 -5
  73. package/.codex/skills/team-tech-debt/SKILL.md +206 -206
  74. package/.codex/skills/team-tech-debt/roles/coordinator/commands/monitor.md +1 -1
  75. package/.codex/skills/team-testing/SKILL.md +237 -237
  76. package/.codex/skills/team-ui-polish/SKILL.md +218 -218
  77. package/.codex/skills/team-ui-polish/roles/coordinator/role.md +213 -213
  78. package/.codex/skills/team-uidesign/SKILL.md +219 -219
  79. package/.codex/skills/team-uidesign/roles/coordinator/role.md +2 -2
  80. package/.codex/skills/team-ultra-analyze/SKILL.md +260 -260
  81. package/.codex/skills/team-ultra-analyze/roles/coordinator/commands/monitor.md +1 -1
  82. package/.codex/skills/team-ultra-analyze/roles/coordinator/role.md +1 -1
  83. package/.codex/skills/team-ux-improve/SKILL.md +227 -227
  84. package/.codex/skills/team-ux-improve/roles/coordinator/role.md +1 -1
  85. package/.codex/skills/team-ux-improve/specs/team-config.json +1 -1
  86. package/.codex/skills/team-visual-a11y/SKILL.md +319 -319
  87. package/.codex/skills/team-visual-a11y/roles/coordinator/role.md +213 -213
  88. package/.codex/skills/workflow-execute/SKILL.md +5 -5
  89. package/.codex/skills/workflow-lite-planex/SKILL.md +3 -3
  90. package/.codex/skills/workflow-plan/SKILL.md +3 -3
  91. package/.codex/skills/workflow-tdd-plan/SKILL.md +4 -4
  92. package/.codex/skills/workflow-test-fix-cycle/SKILL.md +403 -402
  93. package/ccw/dist/cli.d.ts.map +1 -1
  94. package/ccw/dist/cli.js +16 -0
  95. package/ccw/dist/cli.js.map +1 -1
  96. package/ccw/dist/commands/chain-loader.d.ts +2 -0
  97. package/ccw/dist/commands/chain-loader.d.ts.map +1 -0
  98. package/ccw/dist/commands/chain-loader.js +11 -0
  99. package/ccw/dist/commands/chain-loader.js.map +1 -0
  100. package/ccw/dist/commands/install.d.ts.map +1 -1
  101. package/ccw/dist/commands/install.js +52 -1
  102. package/ccw/dist/commands/install.js.map +1 -1
  103. package/ccw/dist/commands/launcher.d.ts +2 -0
  104. package/ccw/dist/commands/launcher.d.ts.map +1 -0
  105. package/ccw/dist/commands/launcher.js +434 -0
  106. package/ccw/dist/commands/launcher.js.map +1 -0
  107. package/ccw/dist/tools/chain-loader.d.ts.map +1 -1
  108. package/ccw/dist/tools/chain-loader.js +457 -45
  109. package/ccw/dist/tools/chain-loader.js.map +1 -1
  110. package/ccw/dist/tools/skill-context-loader.d.ts.map +1 -1
  111. package/ccw/dist/tools/skill-context-loader.js +12 -26
  112. package/ccw/dist/tools/skill-context-loader.js.map +1 -1
  113. package/ccw/dist/types/chain-types.d.ts +41 -1
  114. package/ccw/dist/types/chain-types.d.ts.map +1 -1
  115. package/ccw/dist/utils/chain-visualizer.d.ts +13 -0
  116. package/ccw/dist/utils/chain-visualizer.d.ts.map +1 -0
  117. package/ccw/dist/utils/chain-visualizer.js +164 -0
  118. package/ccw/dist/utils/chain-visualizer.js.map +1 -0
  119. package/package.json +1 -1
  120. package/.claude/commands/cli/cli-init.md +0 -441
  121. package/.claude/commands/cli/codex-review.md +0 -361
  122. package/.claude/commands/flow-create.md +0 -663
  123. package/.claude/skills/ccw-chain/phases/analyze-with-file.md +0 -788
  124. package/.claude/skills/ccw-chain/phases/brainstorm/SKILL.md +0 -408
  125. package/.claude/skills/ccw-chain/phases/brainstorm/phases/01-mode-routing.md +0 -207
  126. package/.claude/skills/ccw-chain/phases/brainstorm/phases/02-artifacts.md +0 -567
  127. package/.claude/skills/ccw-chain/phases/brainstorm/phases/03-role-analysis.md +0 -748
  128. package/.claude/skills/ccw-chain/phases/brainstorm/phases/04-synthesis.md +0 -827
  129. package/.claude/skills/ccw-chain/phases/brainstorm-with-file.md +0 -482
  130. package/.claude/skills/ccw-chain/phases/collaborative-plan-with-file.md +0 -639
  131. package/.claude/skills/ccw-chain/phases/debug-with-file.md +0 -656
  132. package/.claude/skills/ccw-chain/phases/integration-test-cycle.md +0 -936
  133. package/.claude/skills/ccw-chain/phases/issue-convert-to-plan.md +0 -720
  134. package/.claude/skills/ccw-chain/phases/issue-discover.md +0 -483
  135. package/.claude/skills/ccw-chain/phases/issue-execute.md +0 -629
  136. package/.claude/skills/ccw-chain/phases/issue-from-brainstorm.md +0 -382
  137. package/.claude/skills/ccw-chain/phases/issue-plan.md +0 -343
  138. package/.claude/skills/ccw-chain/phases/issue-queue.md +0 -464
  139. package/.claude/skills/ccw-chain/phases/refactor-cycle.md +0 -852
  140. package/.claude/skills/ccw-chain/phases/review-cycle/SKILL.md +0 -132
  141. package/.claude/skills/ccw-chain/phases/review-cycle/phases/review-fix.md +0 -760
  142. package/.claude/skills/ccw-chain/phases/review-cycle/phases/review-module.md +0 -764
  143. package/.claude/skills/ccw-chain/phases/review-cycle/phases/review-session.md +0 -775
  144. package/.claude/skills/ccw-chain/phases/roadmap-with-file.md +0 -544
  145. package/.claude/skills/ccw-chain/phases/spec-generator/SKILL.md +0 -338
  146. package/.claude/skills/ccw-chain/phases/spec-generator/phases/01-5-requirement-clarification.md +0 -404
  147. package/.claude/skills/ccw-chain/phases/spec-generator/phases/01-discovery.md +0 -257
  148. package/.claude/skills/ccw-chain/phases/spec-generator/phases/02-product-brief.md +0 -274
  149. package/.claude/skills/ccw-chain/phases/spec-generator/phases/03-requirements.md +0 -184
  150. package/.claude/skills/ccw-chain/phases/spec-generator/phases/04-architecture.md +0 -248
  151. package/.claude/skills/ccw-chain/phases/spec-generator/phases/05-epics-stories.md +0 -178
  152. package/.claude/skills/ccw-chain/phases/spec-generator/phases/06-5-auto-fix.md +0 -144
  153. package/.claude/skills/ccw-chain/phases/spec-generator/phases/06-readiness-check.md +0 -480
  154. package/.claude/skills/ccw-chain/phases/team-planex.md +0 -123
  155. package/.claude/skills/ccw-chain/phases/ui-design-explore-auto.md +0 -678
  156. package/.claude/skills/ccw-chain/phases/unified-execute-with-file.md +0 -870
  157. package/.claude/skills/ccw-chain/phases/workflow-execute/SKILL.md +0 -625
  158. package/.claude/skills/ccw-chain/phases/workflow-execute/phases/06-review.md +0 -215
  159. package/.claude/skills/ccw-chain/phases/workflow-lite-plan.md +0 -616
  160. package/.claude/skills/ccw-chain/phases/workflow-multi-cli-plan.md +0 -424
  161. package/.claude/skills/ccw-chain/phases/workflow-plan/SKILL.md +0 -466
  162. package/.claude/skills/ccw-chain/phases/workflow-plan/phases/01-session-discovery.md +0 -99
  163. package/.claude/skills/ccw-chain/phases/workflow-plan/phases/02-context-gathering.md +0 -338
  164. package/.claude/skills/ccw-chain/phases/workflow-plan/phases/03-conflict-resolution.md +0 -422
  165. package/.claude/skills/ccw-chain/phases/workflow-plan/phases/04-task-generation.md +0 -440
  166. package/.claude/skills/ccw-chain/phases/workflow-plan/phases/05-plan-verify.md +0 -395
  167. package/.claude/skills/ccw-chain/phases/workflow-plan/phases/06-replan.md +0 -594
  168. package/.claude/skills/ccw-chain/phases/workflow-tdd-plan/SKILL.md +0 -527
  169. package/.claude/skills/ccw-chain/phases/workflow-tdd-plan/phases/01-session-discovery.md +0 -57
  170. package/.claude/skills/ccw-chain/phases/workflow-tdd-plan/phases/02-context-gathering.md +0 -407
  171. package/.claude/skills/ccw-chain/phases/workflow-tdd-plan/phases/03-test-coverage-analysis.md +0 -172
  172. package/.claude/skills/ccw-chain/phases/workflow-tdd-plan/phases/04-conflict-resolution.md +0 -426
  173. package/.claude/skills/ccw-chain/phases/workflow-tdd-plan/phases/05-tdd-task-generation.md +0 -473
  174. package/.claude/skills/ccw-chain/phases/workflow-tdd-plan/phases/06-tdd-structure-validation.md +0 -189
  175. package/.claude/skills/ccw-chain/phases/workflow-tdd-plan/phases/07-tdd-verify.md +0 -635
  176. package/.claude/skills/ccw-chain/phases/workflow-test-fix/SKILL.md +0 -482
  177. package/.claude/skills/ccw-chain/phases/workflow-test-fix/phases/01-session-start.md +0 -60
  178. package/.claude/skills/ccw-chain/phases/workflow-test-fix/phases/02-test-context-gather.md +0 -493
  179. package/.claude/skills/ccw-chain/phases/workflow-test-fix/phases/03-test-concept-enhanced.md +0 -150
  180. package/.claude/skills/ccw-chain/phases/workflow-test-fix/phases/04-test-task-generate.md +0 -346
  181. package/.claude/skills/ccw-chain/phases/workflow-test-fix/phases/05-test-cycle-execute.md +0 -538
  182. package/.claude/skills/ccw-chain/specs/intent-patterns.md +0 -60
  183. package/.claude/skills/team-edict.zip +0 -0
@@ -1,440 +0,0 @@
1
- # Phase 4: Task Generation
2
-
3
- > **📌 COMPACT SENTINEL [Phase 4: Task-Generation]**
4
- > This phase contains 6 execution steps (Step 4.0 — 4.4).
5
- > If you can read this sentinel but cannot find the full Step protocol below, context has been compressed.
6
- > Recovery: `Read("phases/04-task-generation.md")`
7
-
8
- Generate implementation plan and task JSONs via action-planning-agent.
9
-
10
- ## Objective
11
-
12
- - Generate IMPL_PLAN.md, task JSONs, and TODO_LIST.md
13
- - Present user with plan confirmation choices (verify / execute / review)
14
- - Route to Phase 5 (verify) if user selects verification
15
-
16
- ## Relationship with Brainstorm Phase
17
-
18
- - If brainstorm role analyses exist ([role]/analysis.md files), they are incorporated as input
19
- - **User's original intent is ALWAYS primary**: New or refined user goals override brainstorm recommendations
20
- - **Role analysis.md files define "WHAT"**: Requirements, design specs, role-specific insights
21
- - **IMPL_PLAN.md defines "HOW"**: Executable task breakdown, dependencies, implementation sequence
22
- - Task generation translates high-level role analyses into concrete, actionable work items
23
- - **Intent priority**: Current user prompt > role analysis.md files > guidance-specification.md
24
-
25
- ## Core Philosophy
26
-
27
- - **Planning Only**: Generate planning documents (IMPL_PLAN.md, task JSONs, TODO_LIST.md) - does NOT implement code
28
- - **Agent-Driven Document Generation**: Delegate plan generation to action-planning-agent
29
- - **NO Redundant Context Sorting**: Context priority sorting is ALREADY completed in context-gather Phase 2/3
30
- - Use `context-package.json.prioritized_context` directly
31
- - DO NOT re-sort files or re-compute priorities
32
- - `priority_tiers` and `dependency_order` are pre-computed and ready-to-use
33
- - **N+1 Parallel Planning**: Auto-detect multi-module projects, enable parallel planning (2+1 or 3+1 mode)
34
- - **Progressive Loading**: Load context incrementally (Core -> Selective -> On-Demand) due to analysis.md file size
35
- - **Memory-First**: Reuse loaded documents from conversation memory
36
- - **Smart Selection**: Load synthesis_output OR guidance + relevant role analyses, NOT all role analyses
37
-
38
- ## Execution
39
-
40
- ### Step 4.0: User Configuration (Interactive)
41
-
42
- **Auto Mode Check**:
43
- ```javascript
44
- const autoYes = workflowPreferences?.autoYes || false;
45
-
46
- if (autoYes) {
47
- console.log(`[autoYes] Using defaults: No materials, Agent executor, Codex CLI`)
48
- userConfig = {
49
- supplementaryMaterials: { type: "none", content: [] },
50
- executionMethod: "agent",
51
- preferredCliTool: "codex",
52
- enableResume: true
53
- }
54
- // Skip to Step 4.1
55
- }
56
- ```
57
-
58
- **User Questions** (skipped if autoYes):
59
- ```javascript
60
- if (!autoYes) AskUserQuestion({
61
- questions: [
62
- {
63
- question: "Do you have supplementary materials or guidelines to include?",
64
- header: "Materials",
65
- multiSelect: false,
66
- options: [
67
- { label: "No additional materials", description: "Use existing context only" },
68
- { label: "Provide file paths", description: "I'll specify paths to include" },
69
- { label: "Provide inline content", description: "I'll paste content directly" }
70
- ]
71
- },
72
- {
73
- question: "Select execution method for generated tasks:",
74
- header: "Execution",
75
- multiSelect: false,
76
- options: [
77
- { label: "Agent (Recommended)", description: "Claude agent executes tasks directly" },
78
- { label: "Hybrid", description: "Agent orchestrates, calls CLI for complex steps" },
79
- { label: "CLI Only", description: "All execution via CLI tools (codex/gemini/qwen)" }
80
- ]
81
- },
82
- {
83
- question: "If using CLI, which tool do you prefer?",
84
- header: "CLI Tool",
85
- multiSelect: false,
86
- options: [
87
- { label: "Codex (Recommended)", description: "Best for implementation tasks" },
88
- { label: "Gemini", description: "Best for analysis and large context" },
89
- { label: "Qwen", description: "Alternative analysis tool" },
90
- { label: "Auto", description: "Let agent decide per-task" }
91
- ]
92
- }
93
- ]
94
- })
95
- ```
96
-
97
- ### Step 4.1: Context Preparation & Module Detection
98
-
99
- **Command prepares session paths, metadata, detects module structure. Context priority sorting is NOT performed here.**
100
-
101
- ```javascript
102
- // Session Path Structure:
103
- // .workflow/active/WFS-{session-id}/
104
- // ├── workflow-session.json # Session metadata
105
- // ├── planning-notes.md # Consolidated planning notes
106
- // ├── .process/
107
- // │ └── context-package.json # Context package
108
- // ├── .task/ # Output: Task JSON files
109
- // ├── plan.json # Output: Structured plan overview
110
- // ├── IMPL_PLAN.md # Output: Implementation plan
111
- // └── TODO_LIST.md # Output: TODO list
112
-
113
- // Auto Module Detection (determines single vs parallel mode)
114
- function autoDetectModules(contextPackage, projectRoot) {
115
- // Complexity Gate: Only parallelize for High complexity
116
- const complexity = contextPackage.metadata?.complexity || 'Medium';
117
- if (complexity !== 'High') {
118
- return [{ name: 'main', prefix: '', paths: ['.'] }];
119
- }
120
-
121
- // Priority 1: Explicit frontend/backend separation
122
- if (exists('src/frontend') && exists('src/backend')) {
123
- return [
124
- { name: 'frontend', prefix: 'A', paths: ['src/frontend'] },
125
- { name: 'backend', prefix: 'B', paths: ['src/backend'] }
126
- ];
127
- }
128
-
129
- // Priority 2: Monorepo structure
130
- if (exists('packages/*') || exists('apps/*')) {
131
- return detectMonorepoModules();
132
- }
133
-
134
- // Priority 3: Context-package dependency clustering
135
- const modules = clusterByDependencies(contextPackage.dependencies?.internal);
136
- if (modules.length >= 2) return modules.slice(0, 3);
137
-
138
- // Default: Single module (original flow)
139
- return [{ name: 'main', prefix: '', paths: ['.'] }];
140
- }
141
-
142
- // Decision Logic:
143
- // complexity !== 'High' -> Force Phase 2A (Single Agent)
144
- // modules.length == 1 -> Phase 2A (Single Agent, original flow)
145
- // modules.length >= 2 && complexity == 'High' -> Phase 2B + Phase 3 (N+1 Parallel)
146
- ```
147
-
148
- ### Step 4.2A: Single Agent Planning (modules.length == 1)
149
-
150
- **Purpose**: Generate IMPL_PLAN.md, task JSONs, and TODO_LIST.md - planning documents only, NOT code implementation.
151
-
152
- **Design Note**: The agent specification (action-planning-agent.md) already defines schemas, strategies, quality standards, and loading algorithms. This prompt provides **instance-specific parameters only** — session paths, user config, and context-package consumption guidance unique to this session.
153
-
154
- ```javascript
155
- Task(
156
- subagent_type="action-planning-agent",
157
- run_in_background=false,
158
- description="Generate planning documents (IMPL_PLAN.md, task JSONs, TODO_LIST.md)",
159
- prompt=`
160
- ## TASK OBJECTIVE
161
- Generate implementation planning documents (IMPL_PLAN.md, task JSONs, TODO_LIST.md) for workflow session ${sessionId}
162
-
163
- ## SESSION PATHS
164
- Session Root: .workflow/active/${sessionId}/
165
- Input:
166
- - Session Metadata: .workflow/active/${sessionId}/workflow-session.json
167
- - Planning Notes: .workflow/active/${sessionId}/planning-notes.md
168
- - Context Package: .workflow/active/${sessionId}/.process/context-package.json
169
- Output:
170
- - Task Dir: .workflow/active/${sessionId}/.task/
171
- - IMPL_PLAN: .workflow/active/${sessionId}/IMPL_PLAN.md
172
- - TODO_LIST: .workflow/active/${sessionId}/TODO_LIST.md
173
-
174
- ## CONTEXT METADATA
175
- Session ID: ${sessionId}
176
- MCP Capabilities: {exa_code, exa_web, code_index}
177
-
178
- ## PROJECT CONTEXT (MANDATORY - load via ccw spec)
179
- Execute: ccw spec load --category planning
180
-
181
- This loads:
182
- - Technology stack, architecture, key components, build system, test framework
183
- - User-maintained rules and constraints (coding_conventions, naming_rules, forbidden_patterns, quality_gates)
184
-
185
- Usage:
186
- - Populate plan.json shared_context, align task tech choices, set correct test commands
187
- - Apply as HARD CONSTRAINTS on all generated tasks — task implementation steps,
188
- acceptance criteria, and convergence.verification MUST respect these guidelines
189
-
190
- If spec load returns empty: Proceed normally with context-package.project_context
191
-
192
- Loading order: ccw spec load → planning-notes.md → context-package.json
193
-
194
- ## USER CONFIGURATION (from Step 4.0)
195
- Execution Method: ${userConfig.executionMethod} // agent|hybrid|cli
196
- Preferred CLI Tool: ${userConfig.preferredCliTool} // codex|gemini|qwen|auto
197
- Supplementary Materials: ${userConfig.supplementaryMaterials}
198
-
199
- ## PRIORITIZED CONTEXT (from context-package.prioritized_context) - ALREADY SORTED
200
- Context sorting is ALREADY COMPLETED in Phase 2/3. DO NOT re-sort.
201
- Direct usage:
202
- - **user_intent**: Use goal/scope/key_constraints for task alignment
203
- - **priority_tiers.critical**: PRIMARY focus for task generation
204
- - **priority_tiers.high**: SECONDARY focus
205
- - **dependency_order**: Use for task sequencing - already computed
206
- - **sorting_rationale**: Reference for understanding priority decisions
207
-
208
- ## EXPLORATION CONTEXT (from context-package.exploration_results) - SUPPLEMENT ONLY
209
- If prioritized_context is incomplete, fall back to exploration_results:
210
- - Use aggregated_insights.critical_files for focus_paths generation
211
- - Apply aggregated_insights.constraints to acceptance criteria
212
- - Reference aggregated_insights.all_patterns for implementation approach
213
- - Use aggregated_insights.all_integration_points for precise modification locations
214
-
215
- ## FEATURE SPECIFICATIONS (conditional)
216
- If context-package has brainstorm_artifacts.feature_index_path:
217
- Feature Index: [from context-package]
218
- Feature Spec Dir: [from context-package]
219
- Else if .workflow/active/${sessionId}/.brainstorming/feature-specs/ exists:
220
- Feature Index: .workflow/active/${sessionId}/.brainstorming/feature-specs/feature-index.json
221
-
222
- If the directory does not exist, skip this section.
223
-
224
- ## SESSION-SPECIFIC NOTES
225
- - Deliverables: Task JSONs + IMPL_PLAN.md + plan.json + TODO_LIST.md (all 4 required)
226
- - focus_paths: Derive from prioritized_context.priority_tiers (critical + high)
227
- - Task sequencing: Use dependency_order from context-package (pre-computed)
228
- - All other schemas, strategies, quality standards: Follow agent specification
229
- `
230
- )
231
- ```
232
-
233
- ### Step 4.2B: N Parallel Planning (modules.length >= 2)
234
-
235
- **Condition**: `modules.length >= 2` (multi-module detected)
236
-
237
- **Purpose**: Launch N action-planning-agents simultaneously, one per module.
238
-
239
- ```javascript
240
- // Launch N agents in parallel (one per module)
241
- const planningTasks = modules.map(module =>
242
- Task(
243
- subagent_type="action-planning-agent",
244
- run_in_background=false,
245
- description=`Generate ${module.name} module task JSONs`,
246
- prompt=`
247
- ## TASK OBJECTIVE
248
- Generate task JSON files for ${module.name} module within workflow session
249
-
250
- IMPORTANT: This is PLANNING ONLY - generate task JSONs, NOT implementing code.
251
- IMPORTANT: Generate Task JSONs ONLY. IMPL_PLAN.md and TODO_LIST.md by Phase 3 Coordinator.
252
-
253
- ## PLANNING NOTES (PHASE 1-3 CONTEXT)
254
- Load: .workflow/active/${sessionId}/planning-notes.md
255
-
256
- ## MODULE SCOPE
257
- - Module: ${module.name} (${module.type})
258
- - Focus Paths: ${module.paths.join(', ')}
259
- - Task ID Prefix: IMPL-${module.prefix}
260
- - Task Limit: <=6 tasks (hard limit for this module)
261
- - Other Modules: ${otherModules.join(', ')} (reference only)
262
-
263
- ## SESSION PATHS
264
- Input:
265
- - Session Metadata: .workflow/active/${sessionId}/workflow-session.json
266
- - Planning Notes: .workflow/active/${sessionId}/planning-notes.md
267
- - Context Package: .workflow/active/${sessionId}/.process/context-package.json
268
- Output:
269
- - Task Dir: .workflow/active/${sessionId}/.task/
270
-
271
- ## CROSS-MODULE DEPENDENCIES
272
- - For dependencies ON other modules: Use placeholder depends_on: ["CROSS::{module}::{pattern}"]
273
- - Example: depends_on: ["CROSS::B::api-endpoint"]
274
- - Phase 3 Coordinator resolves to actual task IDs
275
-
276
- ## CLI EXECUTION ID REQUIREMENTS (MANDATORY)
277
- Each task JSON MUST include:
278
- - **cli_execution.id**: Unique ID (format: {session_id}-IMPL-${module.prefix}{seq})
279
- - Cross-module dep -> { "strategy": "cross_module_fork", "resume_from": "CROSS::{module}::{pattern}" }
280
-
281
- ## QUALITY STANDARDS
282
- - Task count <= 9 for this module
283
- - Focus paths scoped to ${module.paths.join(', ')} only
284
- - Cross-module dependencies use CROSS:: placeholder format
285
-
286
- ## PLANNING NOTES RECORD (REQUIRED)
287
- ### [${module.name}] YYYY-MM-DD
288
- - **Tasks**: [count] ([IDs])
289
- - **CROSS deps**: [placeholders used]
290
- `
291
- )
292
- );
293
-
294
- // Execute all in parallel
295
- await Promise.all(planningTasks);
296
- ```
297
-
298
- ### Step 4.3: Integration (+1 Coordinator, Multi-Module Only)
299
-
300
- **Condition**: Only executed when `modules.length >= 2`
301
-
302
- ```javascript
303
- Task(
304
- subagent_type="action-planning-agent",
305
- run_in_background=false,
306
- description="Integrate module tasks and generate unified documents",
307
- prompt=`
308
- ## TASK OBJECTIVE
309
- Integrate all module task JSONs, resolve cross-module dependencies, and generate unified IMPL_PLAN.md and TODO_LIST.md
310
-
311
- IMPORTANT: This is INTEGRATION ONLY - consolidate existing task JSONs, NOT creating new tasks.
312
-
313
- ## SESSION PATHS
314
- Input:
315
- - Session Metadata: .workflow/active/${sessionId}/workflow-session.json
316
- - Context Package: .workflow/active/${sessionId}/.process/context-package.json
317
- - Task JSONs: .workflow/active/${sessionId}/.task/IMPL-*.json (from Phase 2B)
318
- Output:
319
- - Updated Task JSONs: .workflow/active/${sessionId}/.task/IMPL-*.json (resolved dependencies)
320
- - IMPL_PLAN: .workflow/active/${sessionId}/IMPL_PLAN.md
321
- - TODO_LIST: .workflow/active/${sessionId}/TODO_LIST.md
322
-
323
- ## INTEGRATION STEPS
324
- 1. Collect all .task/IMPL-*.json, group by module prefix
325
- 2. Resolve CROSS:: dependencies -> actual task IDs, update task JSONs
326
- 3. Generate IMPL_PLAN.md (multi-module format)
327
- 4. Generate TODO_LIST.md (hierarchical format)
328
-
329
- ## CROSS-MODULE DEPENDENCY RESOLUTION
330
- - Pattern: CROSS::{module}::{pattern} -> IMPL-{module}* matching title/context
331
- - Log unresolved as warnings
332
-
333
- ## PLANNING NOTES RECORD (REQUIRED)
334
- ### [Coordinator] YYYY-MM-DD
335
- - **Total**: [count] tasks
336
- - **Resolved**: [CROSS:: resolutions]
337
- `
338
- )
339
- ```
340
-
341
- **Executor Label** (computed after Step 4.0):
342
- ```javascript
343
- const executorLabel = userConfig.executionMethod === 'agent' ? 'Agent'
344
- : userConfig.executionMethod === 'hybrid' ? 'Hybrid'
345
- : `CLI (${userConfig.preferredCliTool})`
346
- ```
347
-
348
- ### TodoWrite Update (Phase 4 in progress)
349
-
350
- ```json
351
- [
352
- {"content": "Phase 1: Session Discovery", "status": "completed", "activeForm": "Executing session discovery"},
353
- {"content": "Phase 2: Context Gathering", "status": "completed", "activeForm": "Executing context gathering"},
354
- {"content": "Phase 4: Task Generation [${executorLabel}]", "status": "in_progress", "activeForm": "Generating tasks [${executorLabel}]"}
355
- ]
356
- ```
357
-
358
- ### TodoWrite Update (Phase 4 completed)
359
-
360
- ```json
361
- [
362
- {"content": "Phase 1: Session Discovery", "status": "completed", "activeForm": "Executing session discovery"},
363
- {"content": "Phase 2: Context Gathering", "status": "completed", "activeForm": "Executing context gathering"},
364
- {"content": "Phase 4: Task Generation [${executorLabel}]", "status": "completed", "activeForm": "Generating tasks [${executorLabel}]"}
365
- ]
366
- ```
367
-
368
- ### Step 4.4: Plan Confirmation (User Decision Gate)
369
-
370
- After Phase 4 completes, present user with action choices:
371
-
372
- ```javascript
373
- console.log(`
374
- Planning complete for session: ${sessionId}
375
- Tasks generated: ${taskCount}
376
- Plan: .workflow/active/${sessionId}/IMPL_PLAN.md
377
- `);
378
-
379
- // Ask user for next action
380
- const userChoice = AskUserQuestion({
381
- questions: [{
382
- question: "Planning complete. What would you like to do next?",
383
- header: "Next Action",
384
- multiSelect: false,
385
- options: [
386
- {
387
- label: "Verify Plan Quality (Recommended)",
388
- description: "Run quality verification to catch issues before execution."
389
- },
390
- {
391
- label: "Start Execution",
392
- description: "Begin implementing tasks immediately."
393
- },
394
- {
395
- label: "Review Status Only",
396
- description: "View task breakdown and session status without taking further action."
397
- }
398
- ]
399
- }]
400
- });
401
-
402
- // Execute based on user choice
403
- if (userChoice.answers["Next Action"] === "Verify Plan Quality (Recommended)") {
404
- console.log("\nStarting plan verification...\n");
405
- // Route to Phase 5 (plan-verify) within this skill
406
- } else if (userChoice.answers["Next Action"] === "Start Execution") {
407
- console.log("\nStarting task execution...\n");
408
- Skill(skill="workflow-execute", args="--session " + sessionId);
409
- } else if (userChoice.answers["Next Action"] === "Review Status Only") {
410
- console.log("\nDisplaying session status...\n");
411
- // Display session status inline
412
- const sessionMeta = JSON.parse(Read(`.workflow/active/${sessionId}/workflow-session.json`));
413
- const todoList = Read(`.workflow/active/${sessionId}/TODO_LIST.md`);
414
- console.log(`Session: ${sessionId}`);
415
- console.log(`Status: ${sessionMeta.status}`);
416
- console.log(`\n--- TODO List ---\n${todoList}`);
417
- }
418
- ```
419
-
420
- **Auto Mode**: When `workflowPreferences.autoYes` is true, auto-select "Verify Plan Quality", then auto-continue to execute if quality gate is PROCEED.
421
-
422
- **Return to Orchestrator**: Based on user's choice:
423
- - **Verify** -> Orchestrator reads phases/05-plan-verify.md and executes Phase 5 in-process
424
- - **Execute** -> Skill(skill="workflow-execute")
425
- - **Review** -> Display session status inline
426
-
427
- ## Output
428
-
429
- - **File**: `IMPL_PLAN.md` (implementation plan)
430
- - **File**: `IMPL-*.json` (task JSON files)
431
- - **File**: `TODO_LIST.md` (task list)
432
- - **File**: `plan.json` (structured plan overview)
433
- - **TodoWrite**: Mark Phase 4 completed
434
-
435
- ## Next Phase (Conditional)
436
-
437
- Based on user's plan confirmation choice:
438
- - If "Verify" -> [Phase 5: Plan Verification](05-plan-verify.md)
439
- - If "Execute" -> Skill(skill="workflow-execute")
440
- - If "Review" -> Display session status inline