claude-code-workflow 6.3.48 → 6.3.49
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/.claude/CLAUDE.md +6 -8
- package/.claude/agents/action-planning-agent.md +28 -45
- package/.claude/agents/cli-lite-planning-agent.md +93 -1
- package/.claude/agents/code-developer.md +144 -27
- package/.claude/commands/ccw-coordinator.md +175 -21
- package/.claude/commands/ccw-debug.md +832 -0
- package/.claude/commands/ccw.md +90 -9
- package/.claude/commands/cli/cli-init.md +1 -0
- package/.claude/commands/issue/convert-to-plan.md +718 -0
- package/.claude/commands/issue/from-brainstorm.md +382 -0
- package/.claude/commands/memory/tips.md +332 -0
- package/.claude/commands/workflow/analyze-with-file.md +804 -0
- package/.claude/commands/workflow/brainstorm/auto-parallel.md +18 -43
- package/.claude/commands/workflow/brainstorm/role-analysis.md +705 -0
- package/.claude/commands/workflow/brainstorm-with-file.md +1153 -0
- package/.claude/commands/workflow/debug-with-file.md +7 -5
- package/.claude/commands/workflow/execute.md +6 -4
- package/.claude/commands/workflow/lite-plan.md +2 -2
- package/.claude/commands/workflow/plan-verify.md +162 -327
- package/.claude/commands/workflow/plan.md +162 -26
- package/.claude/commands/workflow/replan.md +78 -2
- package/.claude/commands/workflow/{review-fix.md → review-cycle-fix.md} +6 -6
- package/.claude/commands/workflow/review-module-cycle.md +2 -2
- package/.claude/commands/workflow/review-session-cycle.md +2 -2
- package/.claude/commands/workflow/tools/conflict-resolution.md +16 -26
- package/.claude/commands/workflow/tools/context-gather.md +81 -118
- package/.claude/commands/workflow/tools/task-generate-agent.md +94 -10
- package/.claude/skills/ccw-help/command.json +4 -4
- package/.claude/skills/lite-skill-generator/SKILL.md +650 -0
- package/.claude/skills/lite-skill-generator/templates/simple-skill.md +68 -0
- package/.claude/skills/lite-skill-generator/templates/style-guide.md +64 -0
- package/.claude/skills/skill-generator/SKILL.md +277 -85
- package/.claude/skills/skill-generator/phases/01-requirements-discovery.md +4 -15
- package/.claude/skills/skill-generator/phases/02-structure-generation.md +72 -17
- package/.claude/skills/skill-generator/phases/03-phase-generation.md +218 -51
- package/.claude/skills/skill-generator/phases/04-specs-templates.md +111 -41
- package/.claude/skills/skill-generator/phases/05-validation.md +139 -56
- package/.claude/skills/skill-generator/templates/autonomous-action.md +78 -268
- package/.claude/skills/skill-generator/templates/autonomous-orchestrator.md +14 -0
- package/.claude/skills/skill-generator/templates/code-analysis-action.md +12 -0
- package/.claude/skills/skill-generator/templates/llm-action.md +12 -0
- package/.claude/skills/skill-generator/templates/script-template.md +368 -0
- package/.claude/skills/skill-generator/templates/sequential-phase.md +14 -0
- package/.claude/skills/skill-generator/templates/skill-md.md +14 -0
- package/.claude/skills/skill-tuning/SKILL.md +130 -266
- package/.claude/skills/skill-tuning/phases/orchestrator.md +95 -283
- package/.claude/skills/skill-tuning/specs/problem-taxonomy.md +90 -198
- package/.claude/skills/skill-tuning/specs/tuning-strategies.md +193 -1345
- package/.claude/workflows/cli-templates/schemas/plan-verify-agent-schema.json +47 -0
- package/.claude/workflows/cli-templates/schemas/verify-json-schema.json +158 -0
- package/.claude/workflows/cli-tools-usage.md +1 -1
- package/.codex/AGENTS.md +1 -3
- package/.codex/prompts/analyze-with-file.md +607 -0
- package/.codex/prompts/brainstorm-to-cycle.md +455 -0
- package/.codex/prompts/brainstorm-with-file.md +933 -0
- package/.codex/prompts/debug-with-file.md +15 -20
- package/.codex/skills/ccw-cli-tools/SKILL.md +559 -0
- package/ccw/dist/commands/cli.d.ts.map +1 -1
- package/ccw/dist/commands/cli.js +29 -5
- package/ccw/dist/commands/cli.js.map +1 -1
- package/ccw/dist/commands/issue.d.ts +2 -0
- package/ccw/dist/commands/issue.d.ts.map +1 -1
- package/ccw/dist/commands/issue.js +62 -20
- package/ccw/dist/commands/issue.js.map +1 -1
- package/ccw/dist/config/litellm-api-config-manager.d.ts.map +1 -1
- package/ccw/dist/config/litellm-api-config-manager.js +5 -3
- package/ccw/dist/config/litellm-api-config-manager.js.map +1 -1
- package/ccw/dist/config/litellm-provider-models.d.ts +73 -0
- package/ccw/dist/config/litellm-provider-models.d.ts.map +1 -0
- package/ccw/dist/config/litellm-provider-models.js +172 -0
- package/ccw/dist/config/litellm-provider-models.js.map +1 -0
- package/ccw/dist/config/provider-models.d.ts +25 -51
- package/ccw/dist/config/provider-models.d.ts.map +1 -1
- package/ccw/dist/config/provider-models.js +84 -149
- package/ccw/dist/config/provider-models.js.map +1 -1
- package/ccw/dist/config/storage-paths.d.ts.map +1 -1
- package/ccw/dist/config/storage-paths.js +23 -5
- package/ccw/dist/config/storage-paths.js.map +1 -1
- package/ccw/dist/core/auth/csrf-middleware.js +3 -3
- package/ccw/dist/core/auth/csrf-middleware.js.map +1 -1
- package/ccw/dist/core/dashboard-generator.d.ts.map +1 -1
- package/ccw/dist/core/dashboard-generator.js +3 -1
- package/ccw/dist/core/dashboard-generator.js.map +1 -1
- package/ccw/dist/core/routes/claude-routes.d.ts.map +1 -1
- package/ccw/dist/core/routes/claude-routes.js +206 -14
- package/ccw/dist/core/routes/claude-routes.js.map +1 -1
- package/ccw/dist/core/routes/cli-routes.d.ts.map +1 -1
- package/ccw/dist/core/routes/cli-routes.js.map +1 -1
- package/ccw/dist/core/routes/commands-routes.d.ts +7 -0
- package/ccw/dist/core/routes/commands-routes.d.ts.map +1 -0
- package/ccw/dist/core/routes/commands-routes.js +480 -0
- package/ccw/dist/core/routes/commands-routes.js.map +1 -0
- package/ccw/dist/core/routes/model-routes.d.ts +11 -0
- package/ccw/dist/core/routes/model-routes.d.ts.map +1 -0
- package/ccw/dist/core/routes/model-routes.js +112 -0
- package/ccw/dist/core/routes/model-routes.js.map +1 -0
- package/ccw/dist/core/routes/nav-status-routes.d.ts.map +1 -1
- package/ccw/dist/core/routes/nav-status-routes.js +84 -1
- package/ccw/dist/core/routes/nav-status-routes.js.map +1 -1
- package/ccw/dist/core/routes/provider-routes.d.ts +11 -0
- package/ccw/dist/core/routes/provider-routes.d.ts.map +1 -0
- package/ccw/dist/core/routes/provider-routes.js +67 -0
- package/ccw/dist/core/routes/provider-routes.js.map +1 -0
- package/ccw/dist/core/routes/skills-routes.d.ts.map +1 -1
- package/ccw/dist/core/routes/skills-routes.js +219 -7
- package/ccw/dist/core/routes/skills-routes.js.map +1 -1
- package/ccw/dist/core/routes/system-routes.d.ts.map +1 -1
- package/ccw/dist/core/routes/system-routes.js +58 -6
- package/ccw/dist/core/routes/system-routes.js.map +1 -1
- package/ccw/dist/core/server.d.ts.map +1 -1
- package/ccw/dist/core/server.js +13 -0
- package/ccw/dist/core/server.js.map +1 -1
- package/ccw/dist/mcp-server/index.js +2 -2
- package/ccw/dist/mcp-server/index.js.map +1 -1
- package/ccw/dist/tools/claude-cli-tools.d.ts +48 -11
- package/ccw/dist/tools/claude-cli-tools.d.ts.map +1 -1
- package/ccw/dist/tools/claude-cli-tools.js +146 -50
- package/ccw/dist/tools/claude-cli-tools.js.map +1 -1
- package/ccw/dist/tools/cli-config-manager.d.ts +1 -13
- package/ccw/dist/tools/cli-config-manager.d.ts.map +1 -1
- package/ccw/dist/tools/cli-config-manager.js +3 -27
- package/ccw/dist/tools/cli-config-manager.js.map +1 -1
- package/ccw/dist/tools/cli-executor-core.d.ts.map +1 -1
- package/ccw/dist/tools/cli-executor-core.js +7 -2
- package/ccw/dist/tools/cli-executor-core.js.map +1 -1
- package/ccw/dist/tools/cli-executor-state.d.ts.map +1 -1
- package/ccw/dist/tools/cli-history-store.d.ts +11 -0
- package/ccw/dist/tools/cli-history-store.d.ts.map +1 -1
- package/ccw/dist/tools/cli-history-store.js +82 -2
- package/ccw/dist/tools/cli-history-store.js.map +1 -1
- package/ccw/dist/tools/command-registry.d.ts +7 -0
- package/ccw/dist/tools/command-registry.d.ts.map +1 -1
- package/ccw/dist/tools/command-registry.js +14 -1
- package/ccw/dist/tools/command-registry.js.map +1 -1
- package/ccw/dist/tools/generate-module-docs.d.ts.map +1 -1
- package/ccw/dist/tools/generate-module-docs.js +11 -7
- package/ccw/dist/tools/generate-module-docs.js.map +1 -1
- package/ccw/dist/tools/litellm-executor.d.ts +1 -0
- package/ccw/dist/tools/litellm-executor.d.ts.map +1 -1
- package/ccw/dist/tools/litellm-executor.js +11 -9
- package/ccw/dist/tools/litellm-executor.js.map +1 -1
- package/ccw/dist/types/skill-types.d.ts +97 -0
- package/ccw/dist/types/skill-types.d.ts.map +1 -0
- package/ccw/dist/types/skill-types.js +6 -0
- package/ccw/dist/types/skill-types.js.map +1 -0
- package/ccw/src/commands/cli.ts +36 -5
- package/ccw/src/commands/issue.ts +81 -26
- package/ccw/src/config/litellm-api-config-manager.ts +5 -3
- package/ccw/src/config/litellm-provider-models.ts +222 -0
- package/ccw/src/config/provider-models.ts +91 -190
- package/ccw/src/config/storage-paths.ts +20 -5
- package/ccw/src/core/auth/csrf-middleware.ts +3 -3
- package/ccw/src/core/dashboard-generator.ts +3 -1
- package/ccw/src/core/routes/claude-routes.ts +233 -15
- package/ccw/src/core/routes/cli-routes.ts +2 -3
- package/ccw/src/core/routes/commands-routes.ts +620 -0
- package/ccw/src/core/routes/nav-status-routes.ts +95 -1
- package/ccw/src/core/routes/provider-routes.ts +78 -0
- package/ccw/src/core/routes/skills-routes.ts +266 -45
- package/ccw/src/core/routes/system-routes.ts +102 -50
- package/ccw/src/core/server.ts +13 -0
- package/ccw/src/mcp-server/index.ts +2 -2
- package/ccw/src/templates/dashboard-css/18-cli-settings.css +35 -0
- package/ccw/src/templates/dashboard-css/37-commands.css +193 -0
- package/ccw/src/templates/dashboard-js/components/navigation.js +4 -0
- package/ccw/src/templates/dashboard-js/i18n.js +116 -0
- package/ccw/src/templates/dashboard-js/views/cli-manager.js +249 -4
- package/ccw/src/templates/dashboard-js/views/commands-manager.js +503 -0
- package/ccw/src/templates/dashboard-js/views/issue-manager.js +7 -7
- package/ccw/src/templates/dashboard-js/views/mcp-manager.js +2 -7
- package/ccw/src/templates/dashboard-js/views/skills-manager.js +164 -23
- package/ccw/src/templates/dashboard.html +7 -0
- package/ccw/src/tools/claude-cli-tools.ts +170 -56
- package/ccw/src/tools/cli-config-manager.ts +2 -33
- package/ccw/src/tools/cli-executor-core.ts +8 -2
- package/ccw/src/tools/cli-history-store.ts +92 -2
- package/ccw/src/tools/command-registry.ts +16 -1
- package/ccw/src/tools/generate-module-docs.ts +11 -7
- package/ccw/src/tools/litellm-executor.ts +13 -9
- package/ccw/src/types/skill-types.ts +99 -0
- package/package.json +1 -1
- package/.claude/commands/enhance-prompt.md +0 -93
- package/.claude/commands/memory/code-map-memory.md +0 -687
- package/.claude/commands/memory/docs.md +0 -615
- package/.claude/commands/memory/load-skill-memory.md +0 -182
- package/.claude/commands/memory/skill-memory.md +0 -525
- package/.claude/commands/memory/swagger-docs.md +0 -773
- package/.claude/commands/memory/tech-research-rules.md +0 -310
- package/.claude/commands/memory/workflow-skill-memory.md +0 -517
- package/.claude/commands/task/breakdown.md +0 -208
- package/.claude/commands/task/create.md +0 -152
- package/.claude/commands/task/execute.md +0 -270
- package/.claude/commands/task/replan.md +0 -441
- package/.claude/commands/version.md +0 -254
- package/.claude/commands/workflow/action-plan-verify.md +0 -485
- package/.claude/commands/workflow/brainstorm/api-designer.md +0 -587
- package/.claude/commands/workflow/brainstorm/data-architect.md +0 -220
- package/.claude/commands/workflow/brainstorm/product-manager.md +0 -200
- package/.claude/commands/workflow/brainstorm/product-owner.md +0 -200
- package/.claude/commands/workflow/brainstorm/scrum-master.md +0 -200
- package/.claude/commands/workflow/brainstorm/subject-matter-expert.md +0 -200
- package/.claude/commands/workflow/brainstorm/system-architect.md +0 -389
- package/.claude/commands/workflow/brainstorm/ui-designer.md +0 -221
- package/.claude/commands/workflow/brainstorm/ux-expert.md +0 -221
- package/.claude/commands/workflow/debug.md +0 -331
- package/.claude/commands/workflow/develop-with-file.md +0 -1044
- package/.claude/skills/ccw-loop/README.md +0 -303
- package/.claude/skills/skill-generator/templates/script-bash.md +0 -277
- package/.claude/skills/skill-generator/templates/script-python.md +0 -198
- package/.codex/prompts/debug.md +0 -318
- package/ccw/src/core/routes/mcp-routes.ts.backup +0 -549
|
@@ -0,0 +1,1153 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: brainstorm-with-file
|
|
3
|
+
description: Interactive brainstorming with multi-CLI collaboration, idea expansion, and documented thought evolution
|
|
4
|
+
argument-hint: "[-y|--yes] [-c|--continue] [-m|--mode creative|structured] \"idea or topic\""
|
|
5
|
+
allowed-tools: TodoWrite(*), Task(*), AskUserQuestion(*), Read(*), Grep(*), Glob(*), Bash(*), Edit(*), Write(*)
|
|
6
|
+
---
|
|
7
|
+
|
|
8
|
+
## Auto Mode
|
|
9
|
+
|
|
10
|
+
When `--yes` or `-y`: Auto-confirm decisions, use balanced exploration across all perspectives.
|
|
11
|
+
|
|
12
|
+
# Workflow Brainstorm-With-File Command (/workflow:brainstorm-with-file)
|
|
13
|
+
|
|
14
|
+
## Overview
|
|
15
|
+
|
|
16
|
+
Interactive brainstorming workflow with **multi-CLI collaboration** and **documented thought evolution**. Expands initial ideas through questioning, multi-perspective analysis, and iterative refinement.
|
|
17
|
+
|
|
18
|
+
**Core workflow**: Seed Idea → Expand → Multi-CLI Discuss → Synthesize → Refine → Crystallize
|
|
19
|
+
|
|
20
|
+
**Key features**:
|
|
21
|
+
- **brainstorm.md**: Complete thought evolution timeline
|
|
22
|
+
- **Multi-CLI collaboration**: Gemini (creative), Codex (pragmatic), Claude (systematic) perspectives
|
|
23
|
+
- **Idea expansion**: Progressive questioning and exploration
|
|
24
|
+
- **Diverge-Converge cycles**: Generate options then focus on best paths
|
|
25
|
+
- **Synthesis**: Merge multiple perspectives into coherent solutions
|
|
26
|
+
|
|
27
|
+
## Usage
|
|
28
|
+
|
|
29
|
+
```bash
|
|
30
|
+
/workflow:brainstorm-with-file [FLAGS] <IDEA_OR_TOPIC>
|
|
31
|
+
|
|
32
|
+
# Flags
|
|
33
|
+
-y, --yes Skip confirmations, use recommended settings
|
|
34
|
+
-c, --continue Continue existing session (auto-detected if exists)
|
|
35
|
+
-m, --mode <mode> Brainstorm mode: creative (divergent) | structured (goal-oriented)
|
|
36
|
+
|
|
37
|
+
# Arguments
|
|
38
|
+
<idea-or-topic> Initial idea, problem, or topic to brainstorm (required)
|
|
39
|
+
|
|
40
|
+
# Examples
|
|
41
|
+
/workflow:brainstorm-with-file "如何重新设计用户通知系统"
|
|
42
|
+
/workflow:brainstorm-with-file --continue "通知系统" # Continue existing
|
|
43
|
+
/workflow:brainstorm-with-file -y -m creative "创新的AI辅助功能" # Creative auto mode
|
|
44
|
+
/workflow:brainstorm-with-file -m structured "优化缓存策略" # Goal-oriented mode
|
|
45
|
+
```
|
|
46
|
+
|
|
47
|
+
## Execution Process
|
|
48
|
+
|
|
49
|
+
```
|
|
50
|
+
Session Detection:
|
|
51
|
+
├─ Check if brainstorm session exists for topic
|
|
52
|
+
├─ EXISTS + brainstorm.md exists → Continue mode
|
|
53
|
+
└─ NOT_FOUND → New session mode
|
|
54
|
+
|
|
55
|
+
Phase 1: Seed Understanding
|
|
56
|
+
├─ Parse initial idea/topic
|
|
57
|
+
├─ Identify brainstorm dimensions (technical, UX, business, etc.)
|
|
58
|
+
├─ Initial scoping questions (AskUserQuestion)
|
|
59
|
+
├─ Expand seed into exploration vectors
|
|
60
|
+
└─ Document in brainstorm.md
|
|
61
|
+
|
|
62
|
+
Phase 2: Divergent Exploration (Multi-CLI Parallel)
|
|
63
|
+
├─ Gemini CLI: Creative/innovative perspectives
|
|
64
|
+
├─ Codex CLI: Pragmatic/implementation perspectives
|
|
65
|
+
├─ Claude CLI: Systematic/architectural perspectives
|
|
66
|
+
└─ Aggregate diverse viewpoints
|
|
67
|
+
|
|
68
|
+
Phase 3: Interactive Refinement (Multi-Round)
|
|
69
|
+
├─ Present multi-perspective findings
|
|
70
|
+
├─ User selects promising directions
|
|
71
|
+
├─ Deep dive on selected paths
|
|
72
|
+
├─ Challenge assumptions (devil's advocate)
|
|
73
|
+
├─ Update brainstorm.md with evolution
|
|
74
|
+
└─ Repeat diverge-converge cycles
|
|
75
|
+
|
|
76
|
+
Phase 4: Convergence & Crystallization
|
|
77
|
+
├─ Synthesize best ideas
|
|
78
|
+
├─ Resolve conflicts between perspectives
|
|
79
|
+
├─ Formulate actionable conclusions
|
|
80
|
+
├─ Generate next steps or implementation plan
|
|
81
|
+
└─ Final brainstorm.md update
|
|
82
|
+
|
|
83
|
+
Output:
|
|
84
|
+
├─ .workflow/.brainstorm/{slug}-{date}/brainstorm.md (thought evolution)
|
|
85
|
+
├─ .workflow/.brainstorm/{slug}-{date}/perspectives.json (CLI findings)
|
|
86
|
+
├─ .workflow/.brainstorm/{slug}-{date}/synthesis.json (final ideas)
|
|
87
|
+
└─ .workflow/.brainstorm/{slug}-{date}/ideas/ (individual idea deep-dives)
|
|
88
|
+
```
|
|
89
|
+
|
|
90
|
+
## Implementation
|
|
91
|
+
|
|
92
|
+
### Session Setup & Mode Detection
|
|
93
|
+
|
|
94
|
+
```javascript
|
|
95
|
+
const getUtc8ISOString = () => new Date(Date.now() + 8 * 60 * 60 * 1000).toISOString()
|
|
96
|
+
|
|
97
|
+
const topicSlug = idea_or_topic.toLowerCase().replace(/[^a-z0-9\u4e00-\u9fa5]+/g, '-').substring(0, 40)
|
|
98
|
+
const dateStr = getUtc8ISOString().substring(0, 10)
|
|
99
|
+
|
|
100
|
+
const sessionId = `BS-${topicSlug}-${dateStr}`
|
|
101
|
+
const sessionFolder = `.workflow/.brainstorm/${sessionId}`
|
|
102
|
+
const brainstormPath = `${sessionFolder}/brainstorm.md`
|
|
103
|
+
const perspectivesPath = `${sessionFolder}/perspectives.json`
|
|
104
|
+
const synthesisPath = `${sessionFolder}/synthesis.json`
|
|
105
|
+
const ideasFolder = `${sessionFolder}/ideas`
|
|
106
|
+
|
|
107
|
+
// Auto-detect mode
|
|
108
|
+
const sessionExists = fs.existsSync(sessionFolder)
|
|
109
|
+
const hasBrainstorm = sessionExists && fs.existsSync(brainstormPath)
|
|
110
|
+
const forcesContinue = $ARGUMENTS.includes('--continue') || $ARGUMENTS.includes('-c')
|
|
111
|
+
|
|
112
|
+
const mode = (hasBrainstorm || forcesContinue) ? 'continue' : 'new'
|
|
113
|
+
|
|
114
|
+
// Brainstorm mode
|
|
115
|
+
const brainstormMode = $ARGUMENTS.includes('--mode')
|
|
116
|
+
? $ARGUMENTS.match(/--mode\s+(creative|structured)/)?.[1] || 'balanced'
|
|
117
|
+
: 'balanced'
|
|
118
|
+
|
|
119
|
+
if (!sessionExists) {
|
|
120
|
+
bash(`mkdir -p ${sessionFolder}/ideas`)
|
|
121
|
+
}
|
|
122
|
+
```
|
|
123
|
+
|
|
124
|
+
---
|
|
125
|
+
|
|
126
|
+
### Phase 1: Seed Understanding
|
|
127
|
+
|
|
128
|
+
**Step 1.1: Parse Seed & Identify Dimensions**
|
|
129
|
+
|
|
130
|
+
```javascript
|
|
131
|
+
// Brainstorm dimensions for multi-perspective analysis
|
|
132
|
+
const BRAINSTORM_DIMENSIONS = {
|
|
133
|
+
technical: ['技术', 'technical', 'implementation', 'code', '实现', 'architecture'],
|
|
134
|
+
ux: ['用户', 'user', 'experience', 'UX', 'UI', '体验', 'interaction'],
|
|
135
|
+
business: ['业务', 'business', 'value', 'ROI', '价值', 'market'],
|
|
136
|
+
innovation: ['创新', 'innovation', 'novel', 'creative', '新颖'],
|
|
137
|
+
feasibility: ['可行', 'feasible', 'practical', 'realistic', '实际'],
|
|
138
|
+
scalability: ['扩展', 'scale', 'growth', 'performance', '性能'],
|
|
139
|
+
security: ['安全', 'security', 'risk', 'protection', '风险']
|
|
140
|
+
}
|
|
141
|
+
|
|
142
|
+
function identifyDimensions(topic) {
|
|
143
|
+
const text = topic.toLowerCase()
|
|
144
|
+
const matched = []
|
|
145
|
+
|
|
146
|
+
for (const [dimension, keywords] of Object.entries(BRAINSTORM_DIMENSIONS)) {
|
|
147
|
+
if (keywords.some(k => text.includes(k))) {
|
|
148
|
+
matched.push(dimension)
|
|
149
|
+
}
|
|
150
|
+
}
|
|
151
|
+
|
|
152
|
+
// Default dimensions based on mode
|
|
153
|
+
if (matched.length === 0) {
|
|
154
|
+
return brainstormMode === 'creative'
|
|
155
|
+
? ['innovation', 'ux', 'technical']
|
|
156
|
+
: ['technical', 'feasibility', 'business']
|
|
157
|
+
}
|
|
158
|
+
|
|
159
|
+
return matched
|
|
160
|
+
}
|
|
161
|
+
|
|
162
|
+
const dimensions = identifyDimensions(idea_or_topic)
|
|
163
|
+
```
|
|
164
|
+
|
|
165
|
+
**Step 1.2: Initial Scoping Questions**
|
|
166
|
+
|
|
167
|
+
```javascript
|
|
168
|
+
const autoYes = $ARGUMENTS.includes('--yes') || $ARGUMENTS.includes('-y')
|
|
169
|
+
|
|
170
|
+
if (mode === 'new' && !autoYes) {
|
|
171
|
+
// Expand the seed with targeted questions
|
|
172
|
+
AskUserQuestion({
|
|
173
|
+
questions: [
|
|
174
|
+
{
|
|
175
|
+
question: `头脑风暴主题: "${idea_or_topic}"\n\n您希望探索哪些方向?`,
|
|
176
|
+
header: "方向",
|
|
177
|
+
multiSelect: true,
|
|
178
|
+
options: [
|
|
179
|
+
{ label: "技术方案", description: "探索技术实现可能性" },
|
|
180
|
+
{ label: "用户体验", description: "从用户角度出发" },
|
|
181
|
+
{ label: "创新突破", description: "寻找非常规解决方案" },
|
|
182
|
+
{ label: "可行性评估", description: "评估实际落地可能" }
|
|
183
|
+
]
|
|
184
|
+
},
|
|
185
|
+
{
|
|
186
|
+
question: "头脑风暴深度?",
|
|
187
|
+
header: "深度",
|
|
188
|
+
multiSelect: false,
|
|
189
|
+
options: [
|
|
190
|
+
{ label: "快速发散", description: "广度优先,快速生成多个想法 (15-20分钟)" },
|
|
191
|
+
{ label: "平衡探索", description: "深度和广度平衡 (30-60分钟)" },
|
|
192
|
+
{ label: "深度挖掘", description: "深入探索少数核心想法 (1-2小时)" }
|
|
193
|
+
]
|
|
194
|
+
},
|
|
195
|
+
{
|
|
196
|
+
question: "是否有任何约束或必须考虑的因素?",
|
|
197
|
+
header: "约束",
|
|
198
|
+
multiSelect: true,
|
|
199
|
+
options: [
|
|
200
|
+
{ label: "现有架构", description: "需要与现有系统兼容" },
|
|
201
|
+
{ label: "时间限制", description: "有实施时间约束" },
|
|
202
|
+
{ label: "资源限制", description: "开发资源有限" },
|
|
203
|
+
{ label: "无约束", description: "完全开放探索" }
|
|
204
|
+
]
|
|
205
|
+
}
|
|
206
|
+
]
|
|
207
|
+
})
|
|
208
|
+
}
|
|
209
|
+
```
|
|
210
|
+
|
|
211
|
+
**Step 1.3: Expand Seed into Exploration Vectors**
|
|
212
|
+
|
|
213
|
+
```javascript
|
|
214
|
+
// Generate exploration vectors from seed idea
|
|
215
|
+
const expansionPrompt = `
|
|
216
|
+
Given the initial idea: "${idea_or_topic}"
|
|
217
|
+
User focus areas: ${userFocusAreas.join(', ')}
|
|
218
|
+
Constraints: ${constraints.join(', ')}
|
|
219
|
+
|
|
220
|
+
Generate 5-7 exploration vectors (questions/directions) to expand this idea:
|
|
221
|
+
|
|
222
|
+
1. Core question: What is the fundamental problem/opportunity?
|
|
223
|
+
2. User perspective: Who benefits and how?
|
|
224
|
+
3. Technical angle: What enables this technically?
|
|
225
|
+
4. Alternative approaches: What other ways could this be solved?
|
|
226
|
+
5. Challenges: What could go wrong or block success?
|
|
227
|
+
6. Innovation angle: What would make this 10x better?
|
|
228
|
+
7. Integration: How does this fit with existing systems/processes?
|
|
229
|
+
|
|
230
|
+
Output as structured exploration vectors for multi-perspective analysis.
|
|
231
|
+
`
|
|
232
|
+
|
|
233
|
+
// Use quick Gemini call to expand seed
|
|
234
|
+
const expansionResult = await Bash({
|
|
235
|
+
command: `ccw cli -p "${expansionPrompt}" --tool gemini --mode analysis --model gemini-2.5-flash`,
|
|
236
|
+
run_in_background: false
|
|
237
|
+
})
|
|
238
|
+
|
|
239
|
+
const explorationVectors = parseExpansionResult(expansionResult)
|
|
240
|
+
```
|
|
241
|
+
|
|
242
|
+
**Step 1.4: Create brainstorm.md**
|
|
243
|
+
|
|
244
|
+
```markdown
|
|
245
|
+
# Brainstorm Session
|
|
246
|
+
|
|
247
|
+
**Session ID**: ${sessionId}
|
|
248
|
+
**Topic**: ${idea_or_topic}
|
|
249
|
+
**Started**: ${getUtc8ISOString()}
|
|
250
|
+
**Mode**: ${brainstormMode}
|
|
251
|
+
**Dimensions**: ${dimensions.join(', ')}
|
|
252
|
+
|
|
253
|
+
---
|
|
254
|
+
|
|
255
|
+
## Initial Context
|
|
256
|
+
|
|
257
|
+
**User Focus**: ${userFocusAreas.join(', ')}
|
|
258
|
+
**Depth**: ${analysisDepth}
|
|
259
|
+
**Constraints**: ${constraints.join(', ')}
|
|
260
|
+
|
|
261
|
+
---
|
|
262
|
+
|
|
263
|
+
## Seed Expansion
|
|
264
|
+
|
|
265
|
+
### Original Idea
|
|
266
|
+
> ${idea_or_topic}
|
|
267
|
+
|
|
268
|
+
### Exploration Vectors
|
|
269
|
+
|
|
270
|
+
${explorationVectors.map((v, i) => `
|
|
271
|
+
#### Vector ${i+1}: ${v.title}
|
|
272
|
+
**Question**: ${v.question}
|
|
273
|
+
**Angle**: ${v.angle}
|
|
274
|
+
**Potential**: ${v.potential}
|
|
275
|
+
`).join('\n')}
|
|
276
|
+
|
|
277
|
+
---
|
|
278
|
+
|
|
279
|
+
## Thought Evolution Timeline
|
|
280
|
+
|
|
281
|
+
### Round 1 - Seed Understanding (${timestamp})
|
|
282
|
+
|
|
283
|
+
#### Initial Parsing
|
|
284
|
+
- **Core concept**: ${coreConcept}
|
|
285
|
+
- **Problem space**: ${problemSpace}
|
|
286
|
+
- **Opportunity**: ${opportunity}
|
|
287
|
+
|
|
288
|
+
#### Key Questions to Explore
|
|
289
|
+
${keyQuestions.map((q, i) => `${i+1}. ${q}`).join('\n')}
|
|
290
|
+
|
|
291
|
+
---
|
|
292
|
+
|
|
293
|
+
## Current Ideas
|
|
294
|
+
|
|
295
|
+
*To be populated after exploration phases*
|
|
296
|
+
|
|
297
|
+
---
|
|
298
|
+
|
|
299
|
+
## Idea Graveyard
|
|
300
|
+
|
|
301
|
+
*Discarded ideas with reasons - kept for reference*
|
|
302
|
+
```
|
|
303
|
+
|
|
304
|
+
---
|
|
305
|
+
|
|
306
|
+
### Phase 2: Divergent Exploration (Multi-CLI Parallel)
|
|
307
|
+
|
|
308
|
+
**Step 2.1: Launch Multi-CLI Perspectives**
|
|
309
|
+
|
|
310
|
+
```javascript
|
|
311
|
+
const cliPromises = []
|
|
312
|
+
|
|
313
|
+
// 1. Gemini: Creative/Innovative Perspective
|
|
314
|
+
cliPromises.push(
|
|
315
|
+
Bash({
|
|
316
|
+
command: `ccw cli -p "
|
|
317
|
+
PURPOSE: Creative brainstorming for '${idea_or_topic}' - generate innovative, unconventional ideas
|
|
318
|
+
Success: 5+ unique creative solutions that push boundaries
|
|
319
|
+
|
|
320
|
+
TASK:
|
|
321
|
+
• Think beyond obvious solutions - what would be surprising/delightful?
|
|
322
|
+
• Explore cross-domain inspiration (what can we learn from other industries?)
|
|
323
|
+
• Challenge assumptions - what if the opposite were true?
|
|
324
|
+
• Generate 'moonshot' ideas alongside practical ones
|
|
325
|
+
• Consider future trends and emerging technologies
|
|
326
|
+
|
|
327
|
+
MODE: analysis
|
|
328
|
+
|
|
329
|
+
CONTEXT: @**/* | Topic: ${idea_or_topic}
|
|
330
|
+
Exploration vectors: ${explorationVectors.map(v => v.title).join(', ')}
|
|
331
|
+
|
|
332
|
+
EXPECTED:
|
|
333
|
+
- 5+ creative ideas with brief descriptions
|
|
334
|
+
- Each idea rated: novelty (1-5), potential impact (1-5)
|
|
335
|
+
- Key assumptions challenged
|
|
336
|
+
- Cross-domain inspirations
|
|
337
|
+
- One 'crazy' idea that might just work
|
|
338
|
+
|
|
339
|
+
CONSTRAINTS: ${brainstormMode === 'structured' ? 'Keep ideas technically feasible' : 'No constraints - think freely'}
|
|
340
|
+
" --tool gemini --mode analysis`,
|
|
341
|
+
run_in_background: true
|
|
342
|
+
})
|
|
343
|
+
)
|
|
344
|
+
|
|
345
|
+
// 2. Codex: Pragmatic/Implementation Perspective
|
|
346
|
+
cliPromises.push(
|
|
347
|
+
Bash({
|
|
348
|
+
command: `ccw cli -p "
|
|
349
|
+
PURPOSE: Pragmatic analysis for '${idea_or_topic}' - focus on implementation reality
|
|
350
|
+
Success: Actionable approaches with clear implementation paths
|
|
351
|
+
|
|
352
|
+
TASK:
|
|
353
|
+
• Evaluate technical feasibility of core concept
|
|
354
|
+
• Identify existing patterns/libraries that could help
|
|
355
|
+
• Consider integration with current codebase
|
|
356
|
+
• Estimate implementation complexity
|
|
357
|
+
• Highlight potential technical blockers
|
|
358
|
+
• Suggest incremental implementation approach
|
|
359
|
+
|
|
360
|
+
MODE: analysis
|
|
361
|
+
|
|
362
|
+
CONTEXT: @**/* | Topic: ${idea_or_topic}
|
|
363
|
+
Exploration vectors: ${explorationVectors.map(v => v.title).join(', ')}
|
|
364
|
+
|
|
365
|
+
EXPECTED:
|
|
366
|
+
- 3-5 practical implementation approaches
|
|
367
|
+
- Each rated: effort (1-5), risk (1-5), reuse potential (1-5)
|
|
368
|
+
- Technical dependencies identified
|
|
369
|
+
- Quick wins vs long-term solutions
|
|
370
|
+
- Recommended starting point
|
|
371
|
+
|
|
372
|
+
CONSTRAINTS: Focus on what can actually be built with current tech stack
|
|
373
|
+
" --tool codex --mode analysis`,
|
|
374
|
+
run_in_background: true
|
|
375
|
+
})
|
|
376
|
+
)
|
|
377
|
+
|
|
378
|
+
// 3. Claude: Systematic/Architectural Perspective
|
|
379
|
+
cliPromises.push(
|
|
380
|
+
Bash({
|
|
381
|
+
command: `ccw cli -p "
|
|
382
|
+
PURPOSE: Systematic analysis for '${idea_or_topic}' - architectural and structural thinking
|
|
383
|
+
Success: Well-structured solution framework with clear tradeoffs
|
|
384
|
+
|
|
385
|
+
TASK:
|
|
386
|
+
• Decompose the problem into sub-problems
|
|
387
|
+
• Identify architectural patterns that apply
|
|
388
|
+
• Map dependencies and interactions
|
|
389
|
+
• Consider scalability implications
|
|
390
|
+
• Evaluate long-term maintainability
|
|
391
|
+
• Propose systematic solution structure
|
|
392
|
+
|
|
393
|
+
MODE: analysis
|
|
394
|
+
|
|
395
|
+
CONTEXT: @**/* | Topic: ${idea_or_topic}
|
|
396
|
+
Exploration vectors: ${explorationVectors.map(v => v.title).join(', ')}
|
|
397
|
+
|
|
398
|
+
EXPECTED:
|
|
399
|
+
- Problem decomposition diagram (text)
|
|
400
|
+
- 2-3 architectural approaches with tradeoffs
|
|
401
|
+
- Dependency mapping
|
|
402
|
+
- Scalability assessment
|
|
403
|
+
- Recommended architecture pattern
|
|
404
|
+
- Risk matrix
|
|
405
|
+
|
|
406
|
+
CONSTRAINTS: Consider existing system architecture
|
|
407
|
+
" --tool claude --mode analysis`,
|
|
408
|
+
run_in_background: true
|
|
409
|
+
})
|
|
410
|
+
)
|
|
411
|
+
|
|
412
|
+
// Wait for all CLI analyses
|
|
413
|
+
await Promise.all(cliPromises)
|
|
414
|
+
```
|
|
415
|
+
|
|
416
|
+
**Step 2.2: Aggregate Multi-Perspective Findings**
|
|
417
|
+
|
|
418
|
+
```javascript
|
|
419
|
+
const perspectives = {
|
|
420
|
+
session_id: sessionId,
|
|
421
|
+
timestamp: getUtc8ISOString(),
|
|
422
|
+
topic: idea_or_topic,
|
|
423
|
+
|
|
424
|
+
creative: {
|
|
425
|
+
source: 'gemini',
|
|
426
|
+
ideas: [...],
|
|
427
|
+
insights: [...],
|
|
428
|
+
challenges: [...]
|
|
429
|
+
},
|
|
430
|
+
|
|
431
|
+
pragmatic: {
|
|
432
|
+
source: 'codex',
|
|
433
|
+
approaches: [...],
|
|
434
|
+
blockers: [...],
|
|
435
|
+
recommendations: [...]
|
|
436
|
+
},
|
|
437
|
+
|
|
438
|
+
systematic: {
|
|
439
|
+
source: 'claude',
|
|
440
|
+
decomposition: [...],
|
|
441
|
+
patterns: [...],
|
|
442
|
+
tradeoffs: [...]
|
|
443
|
+
},
|
|
444
|
+
|
|
445
|
+
synthesis: {
|
|
446
|
+
convergent_themes: [],
|
|
447
|
+
conflicting_views: [],
|
|
448
|
+
unique_contributions: []
|
|
449
|
+
}
|
|
450
|
+
}
|
|
451
|
+
|
|
452
|
+
Write(perspectivesPath, JSON.stringify(perspectives, null, 2))
|
|
453
|
+
```
|
|
454
|
+
|
|
455
|
+
**Step 2.3: Update brainstorm.md with Perspectives**
|
|
456
|
+
|
|
457
|
+
```markdown
|
|
458
|
+
### Round 2 - Multi-Perspective Exploration (${timestamp})
|
|
459
|
+
|
|
460
|
+
#### Creative Perspective (Gemini)
|
|
461
|
+
|
|
462
|
+
**Top Creative Ideas**:
|
|
463
|
+
${creativeIdeas.map((idea, i) => `
|
|
464
|
+
${i+1}. **${idea.title}** ⭐ Novelty: ${idea.novelty}/5 | Impact: ${idea.impact}/5
|
|
465
|
+
${idea.description}
|
|
466
|
+
`).join('\n')}
|
|
467
|
+
|
|
468
|
+
**Challenged Assumptions**:
|
|
469
|
+
${challengedAssumptions.map(a => `- ~~${a.assumption}~~ → Consider: ${a.alternative}`).join('\n')}
|
|
470
|
+
|
|
471
|
+
**Cross-Domain Inspirations**:
|
|
472
|
+
${inspirations.map(i => `- ${i}`).join('\n')}
|
|
473
|
+
|
|
474
|
+
---
|
|
475
|
+
|
|
476
|
+
#### Pragmatic Perspective (Codex)
|
|
477
|
+
|
|
478
|
+
**Implementation Approaches**:
|
|
479
|
+
${pragmaticApproaches.map((a, i) => `
|
|
480
|
+
${i+1}. **${a.title}** | Effort: ${a.effort}/5 | Risk: ${a.risk}/5
|
|
481
|
+
${a.description}
|
|
482
|
+
- Quick win: ${a.quickWin}
|
|
483
|
+
- Dependencies: ${a.dependencies.join(', ')}
|
|
484
|
+
`).join('\n')}
|
|
485
|
+
|
|
486
|
+
**Technical Blockers**:
|
|
487
|
+
${blockers.map(b => `- ⚠️ ${b}`).join('\n')}
|
|
488
|
+
|
|
489
|
+
---
|
|
490
|
+
|
|
491
|
+
#### Systematic Perspective (Claude)
|
|
492
|
+
|
|
493
|
+
**Problem Decomposition**:
|
|
494
|
+
${decomposition}
|
|
495
|
+
|
|
496
|
+
**Architectural Options**:
|
|
497
|
+
${architecturalOptions.map((opt, i) => `
|
|
498
|
+
${i+1}. **${opt.pattern}**
|
|
499
|
+
- Pros: ${opt.pros.join(', ')}
|
|
500
|
+
- Cons: ${opt.cons.join(', ')}
|
|
501
|
+
- Best for: ${opt.bestFor}
|
|
502
|
+
`).join('\n')}
|
|
503
|
+
|
|
504
|
+
---
|
|
505
|
+
|
|
506
|
+
#### Perspective Synthesis
|
|
507
|
+
|
|
508
|
+
**Convergent Themes** (all perspectives agree):
|
|
509
|
+
${convergentThemes.map(t => `- ✅ ${t}`).join('\n')}
|
|
510
|
+
|
|
511
|
+
**Conflicting Views** (need resolution):
|
|
512
|
+
${conflictingViews.map(v => `
|
|
513
|
+
- 🔄 ${v.topic}
|
|
514
|
+
- Creative: ${v.creative}
|
|
515
|
+
- Pragmatic: ${v.pragmatic}
|
|
516
|
+
- Systematic: ${v.systematic}
|
|
517
|
+
`).join('\n')}
|
|
518
|
+
|
|
519
|
+
**Unique Contributions**:
|
|
520
|
+
${uniqueContributions.map(c => `- 💡 [${c.source}] ${c.insight}`).join('\n')}
|
|
521
|
+
```
|
|
522
|
+
|
|
523
|
+
---
|
|
524
|
+
|
|
525
|
+
### Phase 3: Interactive Refinement (Multi-Round)
|
|
526
|
+
|
|
527
|
+
**Step 3.1: Present & Select Directions**
|
|
528
|
+
|
|
529
|
+
```javascript
|
|
530
|
+
const MAX_ROUNDS = 6
|
|
531
|
+
let roundNumber = 3 // After initial exploration
|
|
532
|
+
let brainstormComplete = false
|
|
533
|
+
|
|
534
|
+
while (!brainstormComplete && roundNumber <= MAX_ROUNDS) {
|
|
535
|
+
|
|
536
|
+
// Present current state
|
|
537
|
+
console.log(`
|
|
538
|
+
## Brainstorm Round ${roundNumber}
|
|
539
|
+
|
|
540
|
+
### Top Ideas So Far
|
|
541
|
+
|
|
542
|
+
${topIdeas.map((idea, i) => `
|
|
543
|
+
${i+1}. **${idea.title}** (${idea.source})
|
|
544
|
+
${idea.brief}
|
|
545
|
+
- Novelty: ${'⭐'.repeat(idea.novelty)} | Feasibility: ${'✅'.repeat(idea.feasibility)}
|
|
546
|
+
`).join('\n')}
|
|
547
|
+
|
|
548
|
+
### Open Questions
|
|
549
|
+
${openQuestions.map((q, i) => `${i+1}. ${q}`).join('\n')}
|
|
550
|
+
`)
|
|
551
|
+
|
|
552
|
+
// Gather user direction
|
|
553
|
+
const userDirection = AskUserQuestion({
|
|
554
|
+
questions: [
|
|
555
|
+
{
|
|
556
|
+
question: "哪些想法值得深入探索?",
|
|
557
|
+
header: "选择",
|
|
558
|
+
multiSelect: true,
|
|
559
|
+
options: topIdeas.slice(0, 4).map(idea => ({
|
|
560
|
+
label: idea.title,
|
|
561
|
+
description: idea.brief
|
|
562
|
+
}))
|
|
563
|
+
},
|
|
564
|
+
{
|
|
565
|
+
question: "下一步?",
|
|
566
|
+
header: "方向",
|
|
567
|
+
multiSelect: false,
|
|
568
|
+
options: [
|
|
569
|
+
{ label: "深入探索", description: "深入分析选中的想法" },
|
|
570
|
+
{ label: "继续发散", description: "生成更多新想法" },
|
|
571
|
+
{ label: "挑战验证", description: "Devil's advocate - 挑战当前想法" },
|
|
572
|
+
{ label: "合并综合", description: "尝试合并多个想法" },
|
|
573
|
+
{ label: "准备收敛", description: "开始整理最终结论" }
|
|
574
|
+
]
|
|
575
|
+
}
|
|
576
|
+
]
|
|
577
|
+
})
|
|
578
|
+
|
|
579
|
+
// Process based on direction
|
|
580
|
+
switch (userDirection.direction) {
|
|
581
|
+
case "深入探索":
|
|
582
|
+
await deepDiveIdeas(userDirection.selectedIdeas)
|
|
583
|
+
break
|
|
584
|
+
case "继续发散":
|
|
585
|
+
await generateMoreIdeas()
|
|
586
|
+
break
|
|
587
|
+
case "挑战验证":
|
|
588
|
+
await devilsAdvocate(topIdeas)
|
|
589
|
+
break
|
|
590
|
+
case "合并综合":
|
|
591
|
+
await mergeIdeas(userDirection.selectedIdeas)
|
|
592
|
+
break
|
|
593
|
+
case "准备收敛":
|
|
594
|
+
brainstormComplete = true
|
|
595
|
+
break
|
|
596
|
+
}
|
|
597
|
+
|
|
598
|
+
// Update brainstorm.md
|
|
599
|
+
updateBrainstormDocument(roundNumber, userDirection, findings)
|
|
600
|
+
roundNumber++
|
|
601
|
+
}
|
|
602
|
+
```
|
|
603
|
+
|
|
604
|
+
**Step 3.2: Deep Dive on Selected Ideas**
|
|
605
|
+
|
|
606
|
+
```javascript
|
|
607
|
+
async function deepDiveIdeas(selectedIdeas) {
|
|
608
|
+
for (const idea of selectedIdeas) {
|
|
609
|
+
// Create dedicated idea file
|
|
610
|
+
const ideaPath = `${ideasFolder}/${idea.slug}.md`
|
|
611
|
+
|
|
612
|
+
// Deep dive with targeted CLI call
|
|
613
|
+
await Bash({
|
|
614
|
+
command: `ccw cli -p "
|
|
615
|
+
PURPOSE: Deep dive analysis on idea '${idea.title}'
|
|
616
|
+
Success: Comprehensive understanding with actionable next steps
|
|
617
|
+
|
|
618
|
+
TASK:
|
|
619
|
+
• Elaborate the core concept in detail
|
|
620
|
+
• Identify implementation requirements
|
|
621
|
+
• List potential challenges and mitigations
|
|
622
|
+
• Suggest proof-of-concept approach
|
|
623
|
+
• Define success metrics
|
|
624
|
+
• Map related/dependent features
|
|
625
|
+
|
|
626
|
+
MODE: analysis
|
|
627
|
+
|
|
628
|
+
CONTEXT: @**/*
|
|
629
|
+
Original idea: ${idea.description}
|
|
630
|
+
Source perspective: ${idea.source}
|
|
631
|
+
User interest reason: ${idea.userReason || 'Selected for exploration'}
|
|
632
|
+
|
|
633
|
+
EXPECTED:
|
|
634
|
+
- Detailed concept description
|
|
635
|
+
- Technical requirements list
|
|
636
|
+
- Risk/challenge matrix
|
|
637
|
+
- MVP definition
|
|
638
|
+
- Success criteria
|
|
639
|
+
- Recommendation: pursue/pivot/park
|
|
640
|
+
|
|
641
|
+
CONSTRAINTS: Focus on actionability
|
|
642
|
+
" --tool gemini --mode analysis`,
|
|
643
|
+
run_in_background: false
|
|
644
|
+
})
|
|
645
|
+
|
|
646
|
+
// Save deep dive to dedicated file
|
|
647
|
+
Write(ideaPath, deepDiveContent)
|
|
648
|
+
}
|
|
649
|
+
}
|
|
650
|
+
```
|
|
651
|
+
|
|
652
|
+
**Step 3.3: Devil's Advocate Challenge**
|
|
653
|
+
|
|
654
|
+
```javascript
|
|
655
|
+
async function devilsAdvocate(ideas) {
|
|
656
|
+
const challengeResult = await Bash({
|
|
657
|
+
command: `ccw cli -p "
|
|
658
|
+
PURPOSE: Devil's advocate - rigorously challenge these brainstorm ideas
|
|
659
|
+
Success: Uncover hidden weaknesses and strengthen viable ideas
|
|
660
|
+
|
|
661
|
+
IDEAS TO CHALLENGE:
|
|
662
|
+
${ideas.map((idea, i) => `${i+1}. ${idea.title}: ${idea.brief}`).join('\n')}
|
|
663
|
+
|
|
664
|
+
TASK:
|
|
665
|
+
• For each idea, identify 3 strongest objections
|
|
666
|
+
• Challenge core assumptions
|
|
667
|
+
• Identify scenarios where this fails
|
|
668
|
+
• Consider competitive/alternative solutions
|
|
669
|
+
• Assess whether this solves the right problem
|
|
670
|
+
• Rate survivability after challenge (1-5)
|
|
671
|
+
|
|
672
|
+
MODE: analysis
|
|
673
|
+
|
|
674
|
+
EXPECTED:
|
|
675
|
+
- Per-idea challenge report
|
|
676
|
+
- Critical weaknesses exposed
|
|
677
|
+
- Counter-arguments to objections (if any)
|
|
678
|
+
- Ideas that survive the challenge
|
|
679
|
+
- Modified/strengthened versions
|
|
680
|
+
|
|
681
|
+
CONSTRAINTS: Be genuinely critical, not just contrarian
|
|
682
|
+
" --tool codex --mode analysis`,
|
|
683
|
+
run_in_background: false
|
|
684
|
+
})
|
|
685
|
+
|
|
686
|
+
return challengeResult
|
|
687
|
+
}
|
|
688
|
+
```
|
|
689
|
+
|
|
690
|
+
**Step 3.4: Merge & Synthesize Ideas**
|
|
691
|
+
|
|
692
|
+
```javascript
|
|
693
|
+
async function mergeIdeas(ideaIds) {
|
|
694
|
+
const selectedIdeas = ideas.filter(i => ideaIds.includes(i.id))
|
|
695
|
+
|
|
696
|
+
const mergeResult = await Bash({
|
|
697
|
+
command: `ccw cli -p "
|
|
698
|
+
PURPOSE: Synthesize multiple ideas into unified concept
|
|
699
|
+
Success: Coherent merged idea that captures best elements
|
|
700
|
+
|
|
701
|
+
IDEAS TO MERGE:
|
|
702
|
+
${selectedIdeas.map((idea, i) => `
|
|
703
|
+
${i+1}. ${idea.title} (${idea.source})
|
|
704
|
+
${idea.description}
|
|
705
|
+
Strengths: ${idea.strengths.join(', ')}
|
|
706
|
+
`).join('\n')}
|
|
707
|
+
|
|
708
|
+
TASK:
|
|
709
|
+
• Identify complementary elements
|
|
710
|
+
• Resolve contradictions
|
|
711
|
+
• Create unified concept
|
|
712
|
+
• Preserve key strengths from each
|
|
713
|
+
• Describe the merged solution
|
|
714
|
+
• Assess viability of merged idea
|
|
715
|
+
|
|
716
|
+
MODE: analysis
|
|
717
|
+
|
|
718
|
+
EXPECTED:
|
|
719
|
+
- Merged concept description
|
|
720
|
+
- Elements taken from each source idea
|
|
721
|
+
- Contradictions resolved (or noted as tradeoffs)
|
|
722
|
+
- New combined strengths
|
|
723
|
+
- Implementation considerations
|
|
724
|
+
|
|
725
|
+
CONSTRAINTS: Don't force incompatible ideas together
|
|
726
|
+
" --tool gemini --mode analysis`,
|
|
727
|
+
run_in_background: false
|
|
728
|
+
})
|
|
729
|
+
|
|
730
|
+
// Add merged idea to list
|
|
731
|
+
const mergedIdea = parseMergeResult(mergeResult)
|
|
732
|
+
ideas.push(mergedIdea)
|
|
733
|
+
|
|
734
|
+
return mergedIdea
|
|
735
|
+
}
|
|
736
|
+
```
|
|
737
|
+
|
|
738
|
+
**Step 3.5: Document Each Round**
|
|
739
|
+
|
|
740
|
+
Append to brainstorm.md:
|
|
741
|
+
```markdown
|
|
742
|
+
### Round ${n} - ${roundType} (${timestamp})
|
|
743
|
+
|
|
744
|
+
#### User Direction
|
|
745
|
+
- **Selected ideas**: ${selectedIdeas.join(', ')}
|
|
746
|
+
- **Action**: ${action}
|
|
747
|
+
- **Reasoning**: ${userReasoning || 'Not specified'}
|
|
748
|
+
|
|
749
|
+
${roundType === 'deep-dive' ? `
|
|
750
|
+
#### Deep Dive: ${ideaTitle}
|
|
751
|
+
|
|
752
|
+
**Elaborated Concept**:
|
|
753
|
+
${elaboratedConcept}
|
|
754
|
+
|
|
755
|
+
**Implementation Requirements**:
|
|
756
|
+
${requirements.map(r => `- ${r}`).join('\n')}
|
|
757
|
+
|
|
758
|
+
**Challenges & Mitigations**:
|
|
759
|
+
${challenges.map(c => `- ⚠️ ${c.challenge} → ✅ ${c.mitigation}`).join('\n')}
|
|
760
|
+
|
|
761
|
+
**MVP Definition**:
|
|
762
|
+
${mvpDefinition}
|
|
763
|
+
|
|
764
|
+
**Recommendation**: ${recommendation}
|
|
765
|
+
` : ''}
|
|
766
|
+
|
|
767
|
+
${roundType === 'challenge' ? `
|
|
768
|
+
#### Devil's Advocate Results
|
|
769
|
+
|
|
770
|
+
**Challenges Raised**:
|
|
771
|
+
${challenges.map(c => `
|
|
772
|
+
- 🔴 **${c.idea}**: ${c.objection}
|
|
773
|
+
- Counter: ${c.counter || 'No strong counter-argument'}
|
|
774
|
+
- Survivability: ${c.survivability}/5
|
|
775
|
+
`).join('\n')}
|
|
776
|
+
|
|
777
|
+
**Ideas That Survived**:
|
|
778
|
+
${survivedIdeas.map(i => `- ✅ ${i}`).join('\n')}
|
|
779
|
+
|
|
780
|
+
**Eliminated/Parked**:
|
|
781
|
+
${eliminatedIdeas.map(i => `- ❌ ${i.title}: ${i.reason}`).join('\n')}
|
|
782
|
+
` : ''}
|
|
783
|
+
|
|
784
|
+
${roundType === 'merge' ? `
|
|
785
|
+
#### Merged Idea: ${mergedIdea.title}
|
|
786
|
+
|
|
787
|
+
**Source Ideas Combined**:
|
|
788
|
+
${sourceIdeas.map(i => `- ${i}`).join('\n')}
|
|
789
|
+
|
|
790
|
+
**Unified Concept**:
|
|
791
|
+
${mergedIdea.description}
|
|
792
|
+
|
|
793
|
+
**Key Elements Preserved**:
|
|
794
|
+
${preservedElements.map(e => `- ✅ ${e}`).join('\n')}
|
|
795
|
+
|
|
796
|
+
**Tradeoffs Accepted**:
|
|
797
|
+
${tradeoffs.map(t => `- ⚖️ ${t}`).join('\n')}
|
|
798
|
+
` : ''}
|
|
799
|
+
|
|
800
|
+
#### Updated Idea Ranking
|
|
801
|
+
|
|
802
|
+
${updatedRanking.map((idea, i) => `
|
|
803
|
+
${i+1}. **${idea.title}** ${idea.status}
|
|
804
|
+
- Score: ${idea.score}/10
|
|
805
|
+
- Source: ${idea.source}
|
|
806
|
+
`).join('\n')}
|
|
807
|
+
```
|
|
808
|
+
|
|
809
|
+
---
|
|
810
|
+
|
|
811
|
+
### Phase 4: Convergence & Crystallization
|
|
812
|
+
|
|
813
|
+
**Step 4.1: Final Synthesis**
|
|
814
|
+
|
|
815
|
+
```javascript
|
|
816
|
+
const synthesis = {
|
|
817
|
+
session_id: sessionId,
|
|
818
|
+
topic: idea_or_topic,
|
|
819
|
+
completed: getUtc8ISOString(),
|
|
820
|
+
total_rounds: roundNumber,
|
|
821
|
+
|
|
822
|
+
// Top ideas with full details
|
|
823
|
+
top_ideas: ideas.filter(i => i.status === 'active').sort((a,b) => b.score - a.score).slice(0, 5).map(idea => ({
|
|
824
|
+
title: idea.title,
|
|
825
|
+
description: idea.description,
|
|
826
|
+
source_perspective: idea.source,
|
|
827
|
+
score: idea.score,
|
|
828
|
+
novelty: idea.novelty,
|
|
829
|
+
feasibility: idea.feasibility,
|
|
830
|
+
key_strengths: idea.strengths,
|
|
831
|
+
main_challenges: idea.challenges,
|
|
832
|
+
next_steps: idea.nextSteps
|
|
833
|
+
})),
|
|
834
|
+
|
|
835
|
+
// Parked ideas for future reference
|
|
836
|
+
parked_ideas: ideas.filter(i => i.status === 'parked').map(idea => ({
|
|
837
|
+
title: idea.title,
|
|
838
|
+
reason_parked: idea.parkReason,
|
|
839
|
+
potential_future_trigger: idea.futureTrigger
|
|
840
|
+
})),
|
|
841
|
+
|
|
842
|
+
// Key insights from the process
|
|
843
|
+
key_insights: keyInsights,
|
|
844
|
+
|
|
845
|
+
// Recommendations
|
|
846
|
+
recommendations: {
|
|
847
|
+
primary: primaryRecommendation,
|
|
848
|
+
alternatives: alternativeApproaches,
|
|
849
|
+
not_recommended: notRecommended
|
|
850
|
+
},
|
|
851
|
+
|
|
852
|
+
// Follow-up suggestions
|
|
853
|
+
follow_up: [
|
|
854
|
+
{ type: 'implementation', summary: '...' },
|
|
855
|
+
{ type: 'research', summary: '...' },
|
|
856
|
+
{ type: 'validation', summary: '...' }
|
|
857
|
+
]
|
|
858
|
+
}
|
|
859
|
+
|
|
860
|
+
Write(synthesisPath, JSON.stringify(synthesis, null, 2))
|
|
861
|
+
```
|
|
862
|
+
|
|
863
|
+
**Step 4.2: Final brainstorm.md Update**
|
|
864
|
+
|
|
865
|
+
```markdown
|
|
866
|
+
---
|
|
867
|
+
|
|
868
|
+
## Synthesis & Conclusions (${timestamp})
|
|
869
|
+
|
|
870
|
+
### Executive Summary
|
|
871
|
+
|
|
872
|
+
${executiveSummary}
|
|
873
|
+
|
|
874
|
+
### Top Ideas (Final Ranking)
|
|
875
|
+
|
|
876
|
+
${topIdeas.map((idea, i) => `
|
|
877
|
+
#### ${i+1}. ${idea.title} ⭐ Score: ${idea.score}/10
|
|
878
|
+
|
|
879
|
+
**Description**: ${idea.description}
|
|
880
|
+
|
|
881
|
+
**Why This Idea**:
|
|
882
|
+
${idea.strengths.map(s => `- ✅ ${s}`).join('\n')}
|
|
883
|
+
|
|
884
|
+
**Main Challenges**:
|
|
885
|
+
${idea.challenges.map(c => `- ⚠️ ${c}`).join('\n')}
|
|
886
|
+
|
|
887
|
+
**Recommended Next Steps**:
|
|
888
|
+
${idea.nextSteps.map((s, j) => `${j+1}. ${s}`).join('\n')}
|
|
889
|
+
|
|
890
|
+
---
|
|
891
|
+
`).join('\n')}
|
|
892
|
+
|
|
893
|
+
### Primary Recommendation
|
|
894
|
+
|
|
895
|
+
> ${primaryRecommendation}
|
|
896
|
+
|
|
897
|
+
**Rationale**: ${primaryRationale}
|
|
898
|
+
|
|
899
|
+
**Quick Start Path**:
|
|
900
|
+
1. ${step1}
|
|
901
|
+
2. ${step2}
|
|
902
|
+
3. ${step3}
|
|
903
|
+
|
|
904
|
+
### Alternative Approaches
|
|
905
|
+
|
|
906
|
+
${alternatives.map((alt, i) => `
|
|
907
|
+
${i+1}. **${alt.title}**
|
|
908
|
+
- When to consider: ${alt.whenToConsider}
|
|
909
|
+
- Tradeoff: ${alt.tradeoff}
|
|
910
|
+
`).join('\n')}
|
|
911
|
+
|
|
912
|
+
### Ideas Parked for Future
|
|
913
|
+
|
|
914
|
+
${parkedIdeas.map(idea => `
|
|
915
|
+
- **${idea.title}** (Parked: ${idea.reason})
|
|
916
|
+
- Revisit when: ${idea.futureTrigger}
|
|
917
|
+
`).join('\n')}
|
|
918
|
+
|
|
919
|
+
---
|
|
920
|
+
|
|
921
|
+
## Key Insights
|
|
922
|
+
|
|
923
|
+
### Process Discoveries
|
|
924
|
+
|
|
925
|
+
${processDiscoveries.map(d => `- 💡 ${d}`).join('\n')}
|
|
926
|
+
|
|
927
|
+
### Assumptions Challenged
|
|
928
|
+
|
|
929
|
+
${challengedAssumptions.map(a => `- ~~${a.original}~~ → ${a.updated}`).join('\n')}
|
|
930
|
+
|
|
931
|
+
### Unexpected Connections
|
|
932
|
+
|
|
933
|
+
${unexpectedConnections.map(c => `- 🔗 ${c}`).join('\n')}
|
|
934
|
+
|
|
935
|
+
---
|
|
936
|
+
|
|
937
|
+
## Current Understanding (Final)
|
|
938
|
+
|
|
939
|
+
### Problem Reframed
|
|
940
|
+
|
|
941
|
+
${reframedProblem}
|
|
942
|
+
|
|
943
|
+
### Solution Space Mapped
|
|
944
|
+
|
|
945
|
+
${solutionSpaceMap}
|
|
946
|
+
|
|
947
|
+
### Decision Framework
|
|
948
|
+
|
|
949
|
+
When to choose each approach:
|
|
950
|
+
${decisionFramework}
|
|
951
|
+
|
|
952
|
+
---
|
|
953
|
+
|
|
954
|
+
## Session Statistics
|
|
955
|
+
|
|
956
|
+
- **Total Rounds**: ${totalRounds}
|
|
957
|
+
- **Ideas Generated**: ${totalIdeas}
|
|
958
|
+
- **Ideas Survived**: ${survivedIdeas}
|
|
959
|
+
- **Perspectives Used**: Gemini (creative), Codex (pragmatic), Claude (systematic)
|
|
960
|
+
- **Duration**: ${duration}
|
|
961
|
+
- **Artifacts**: brainstorm.md, perspectives.json, synthesis.json, ${ideaFiles.length} idea deep-dives
|
|
962
|
+
```
|
|
963
|
+
|
|
964
|
+
**Step 4.3: Post-Completion Options**
|
|
965
|
+
|
|
966
|
+
```javascript
|
|
967
|
+
AskUserQuestion({
|
|
968
|
+
questions: [{
|
|
969
|
+
question: "头脑风暴完成。是否需要后续操作?",
|
|
970
|
+
header: "后续",
|
|
971
|
+
multiSelect: true,
|
|
972
|
+
options: [
|
|
973
|
+
{ label: "创建实施计划", description: "将最佳想法转为实施计划" },
|
|
974
|
+
{ label: "创建Issue", description: "将想法转为可追踪的Issue" },
|
|
975
|
+
{ label: "深入分析", description: "对某个想法进行深度技术分析" },
|
|
976
|
+
{ label: "导出分享", description: "生成可分享的报告" },
|
|
977
|
+
{ label: "完成", description: "不需要后续操作" }
|
|
978
|
+
]
|
|
979
|
+
}]
|
|
980
|
+
})
|
|
981
|
+
|
|
982
|
+
// Handle selections
|
|
983
|
+
if (selection.includes("创建实施计划")) {
|
|
984
|
+
const topIdea = synthesis.top_ideas[0]
|
|
985
|
+
SlashCommand("/workflow:plan", `实施: ${topIdea.title} - ${topIdea.description}`)
|
|
986
|
+
}
|
|
987
|
+
if (selection.includes("创建Issue")) {
|
|
988
|
+
for (const idea of synthesis.top_ideas.slice(0, 3)) {
|
|
989
|
+
SlashCommand("/issue:new", `${idea.title}: ${idea.next_steps[0]}`)
|
|
990
|
+
}
|
|
991
|
+
}
|
|
992
|
+
if (selection.includes("深入分析")) {
|
|
993
|
+
SlashCommand("/workflow:analyze-with-file", synthesis.top_ideas[0].title)
|
|
994
|
+
}
|
|
995
|
+
if (selection.includes("导出分享")) {
|
|
996
|
+
exportBrainstormReport(sessionFolder)
|
|
997
|
+
}
|
|
998
|
+
```
|
|
999
|
+
|
|
1000
|
+
---
|
|
1001
|
+
|
|
1002
|
+
## Session Folder Structure
|
|
1003
|
+
|
|
1004
|
+
```
|
|
1005
|
+
.workflow/.brainstorm/BS-{slug}-{date}/
|
|
1006
|
+
├── brainstorm.md # Complete thought evolution
|
|
1007
|
+
├── perspectives.json # Multi-CLI perspective findings
|
|
1008
|
+
├── synthesis.json # Final synthesis
|
|
1009
|
+
└── ideas/ # Individual idea deep-dives
|
|
1010
|
+
├── idea-1.md
|
|
1011
|
+
├── idea-2.md
|
|
1012
|
+
└── merged-idea-1.md
|
|
1013
|
+
```
|
|
1014
|
+
|
|
1015
|
+
## Brainstorm Document Template
|
|
1016
|
+
|
|
1017
|
+
```markdown
|
|
1018
|
+
# Brainstorm Session
|
|
1019
|
+
|
|
1020
|
+
**Session ID**: BS-xxx-2025-01-27
|
|
1021
|
+
**Topic**: [idea or topic]
|
|
1022
|
+
**Started**: 2025-01-27T10:00:00+08:00
|
|
1023
|
+
**Mode**: creative | structured | balanced
|
|
1024
|
+
**Dimensions**: [technical, ux, innovation, ...]
|
|
1025
|
+
|
|
1026
|
+
---
|
|
1027
|
+
|
|
1028
|
+
## Initial Context
|
|
1029
|
+
|
|
1030
|
+
**User Focus**: [selected focus areas]
|
|
1031
|
+
**Depth**: [quick|balanced|deep]
|
|
1032
|
+
**Constraints**: [if any]
|
|
1033
|
+
|
|
1034
|
+
---
|
|
1035
|
+
|
|
1036
|
+
## Seed Expansion
|
|
1037
|
+
|
|
1038
|
+
### Original Idea
|
|
1039
|
+
> [the initial idea]
|
|
1040
|
+
|
|
1041
|
+
### Exploration Vectors
|
|
1042
|
+
[generated questions and directions]
|
|
1043
|
+
|
|
1044
|
+
---
|
|
1045
|
+
|
|
1046
|
+
## Thought Evolution Timeline
|
|
1047
|
+
|
|
1048
|
+
### Round 1 - Seed Understanding
|
|
1049
|
+
...
|
|
1050
|
+
|
|
1051
|
+
### Round 2 - Multi-Perspective Exploration
|
|
1052
|
+
|
|
1053
|
+
#### Creative Perspective (Gemini)
|
|
1054
|
+
...
|
|
1055
|
+
|
|
1056
|
+
#### Pragmatic Perspective (Codex)
|
|
1057
|
+
...
|
|
1058
|
+
|
|
1059
|
+
#### Systematic Perspective (Claude)
|
|
1060
|
+
...
|
|
1061
|
+
|
|
1062
|
+
#### Perspective Synthesis
|
|
1063
|
+
...
|
|
1064
|
+
|
|
1065
|
+
### Round 3 - Deep Dive
|
|
1066
|
+
...
|
|
1067
|
+
|
|
1068
|
+
### Round 4 - Challenge
|
|
1069
|
+
...
|
|
1070
|
+
|
|
1071
|
+
---
|
|
1072
|
+
|
|
1073
|
+
## Synthesis & Conclusions
|
|
1074
|
+
|
|
1075
|
+
### Executive Summary
|
|
1076
|
+
...
|
|
1077
|
+
|
|
1078
|
+
### Top Ideas (Final Ranking)
|
|
1079
|
+
...
|
|
1080
|
+
|
|
1081
|
+
### Primary Recommendation
|
|
1082
|
+
...
|
|
1083
|
+
|
|
1084
|
+
---
|
|
1085
|
+
|
|
1086
|
+
## Key Insights
|
|
1087
|
+
...
|
|
1088
|
+
|
|
1089
|
+
---
|
|
1090
|
+
|
|
1091
|
+
## Current Understanding (Final)
|
|
1092
|
+
...
|
|
1093
|
+
|
|
1094
|
+
---
|
|
1095
|
+
|
|
1096
|
+
## Session Statistics
|
|
1097
|
+
...
|
|
1098
|
+
```
|
|
1099
|
+
|
|
1100
|
+
## Multi-CLI Collaboration Strategy
|
|
1101
|
+
|
|
1102
|
+
### Perspective Roles
|
|
1103
|
+
|
|
1104
|
+
| CLI | Role | Focus | Best For |
|
|
1105
|
+
|-----|------|-------|----------|
|
|
1106
|
+
| Gemini | Creative | Innovation, cross-domain | Generating novel ideas |
|
|
1107
|
+
| Codex | Pragmatic | Implementation, feasibility | Reality-checking ideas |
|
|
1108
|
+
| Claude | Systematic | Architecture, structure | Organizing solutions |
|
|
1109
|
+
|
|
1110
|
+
### Collaboration Patterns
|
|
1111
|
+
|
|
1112
|
+
1. **Parallel Divergence**: All CLIs explore simultaneously from different angles
|
|
1113
|
+
2. **Sequential Deep-Dive**: One CLI expands, others critique/refine
|
|
1114
|
+
3. **Debate Mode**: CLIs argue for/against specific approaches
|
|
1115
|
+
4. **Synthesis Mode**: Combine insights from all perspectives
|
|
1116
|
+
|
|
1117
|
+
### When to Use Each Pattern
|
|
1118
|
+
|
|
1119
|
+
- **New topic**: Parallel Divergence → get diverse initial ideas
|
|
1120
|
+
- **Promising idea**: Sequential Deep-Dive → thorough exploration
|
|
1121
|
+
- **Controversial approach**: Debate Mode → uncover hidden issues
|
|
1122
|
+
- **Ready to decide**: Synthesis Mode → create actionable conclusion
|
|
1123
|
+
|
|
1124
|
+
## Error Handling
|
|
1125
|
+
|
|
1126
|
+
| Situation | Action |
|
|
1127
|
+
|-----------|--------|
|
|
1128
|
+
| CLI timeout | Retry with shorter prompt, or continue without that perspective |
|
|
1129
|
+
| No good ideas | Reframe the problem, adjust constraints, try different angles |
|
|
1130
|
+
| User disengaged | Summarize progress, offer break point with resume option |
|
|
1131
|
+
| Perspectives conflict | Present as tradeoff, let user decide direction |
|
|
1132
|
+
| Max rounds reached | Force synthesis, highlight unresolved questions |
|
|
1133
|
+
| All ideas fail challenge | Return to divergent phase with new constraints |
|
|
1134
|
+
|
|
1135
|
+
## Usage Recommendations
|
|
1136
|
+
|
|
1137
|
+
Use `/workflow:brainstorm-with-file` when:
|
|
1138
|
+
- Starting a new feature/product without clear direction
|
|
1139
|
+
- Facing a complex problem with multiple possible solutions
|
|
1140
|
+
- Need to explore alternatives before committing
|
|
1141
|
+
- Want documented thinking process for team review
|
|
1142
|
+
- Combining multiple stakeholder perspectives
|
|
1143
|
+
|
|
1144
|
+
Use `/workflow:analyze-with-file` when:
|
|
1145
|
+
- Investigating existing code/system
|
|
1146
|
+
- Need factual analysis over ideation
|
|
1147
|
+
- Debugging or troubleshooting
|
|
1148
|
+
- Understanding current state
|
|
1149
|
+
|
|
1150
|
+
Use `/workflow:plan` when:
|
|
1151
|
+
- Direction is already clear
|
|
1152
|
+
- Ready to move from ideas to execution
|
|
1153
|
+
- Need implementation breakdown
|