feed-the-machine 1.6.0 → 1.7.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -21
- package/README.md +170 -170
- package/bin/brain.py +1340 -0
- package/bin/convert_claude_skills_to_codex.py +490 -0
- package/bin/generate-manifest.mjs +463 -463
- package/bin/harden_codex_skills.py +141 -0
- package/bin/install.mjs +491 -491
- package/bin/migrate-eng-buddy-data.py +875 -0
- package/bin/playbook_engine/__init__.py +1 -0
- package/bin/playbook_engine/conftest.py +8 -0
- package/bin/playbook_engine/extractor.py +33 -0
- package/bin/playbook_engine/manager.py +102 -0
- package/bin/playbook_engine/models.py +84 -0
- package/bin/playbook_engine/registry.py +35 -0
- package/bin/playbook_engine/test_extractor.py +72 -0
- package/bin/playbook_engine/test_integration.py +129 -0
- package/bin/playbook_engine/test_manager.py +85 -0
- package/bin/playbook_engine/test_models.py +166 -0
- package/bin/playbook_engine/test_registry.py +67 -0
- package/bin/playbook_engine/test_tracer.py +86 -0
- package/bin/playbook_engine/tracer.py +93 -0
- package/bin/tasks_db.py +456 -0
- package/docs/HOOKS.md +243 -243
- package/docs/INBOX.md +233 -233
- package/ftm/SKILL.md +125 -122
- package/ftm-audit/SKILL.md +623 -623
- package/ftm-audit/references/protocols/PROJECT-PATTERNS.md +91 -91
- package/ftm-audit/references/protocols/RUNTIME-WIRING.md +66 -66
- package/ftm-audit/references/protocols/WIRING-CONTRACTS.md +135 -135
- package/ftm-audit/references/strategies/AUTO-FIX-STRATEGIES.md +69 -69
- package/ftm-audit/references/templates/REPORT-FORMAT.md +96 -96
- package/ftm-audit/scripts/run-knip.sh +23 -23
- package/ftm-audit.yml +2 -2
- package/ftm-brainstorm/SKILL.md +1003 -498
- package/ftm-brainstorm/evals/evals.json +180 -100
- package/ftm-brainstorm/evals/promptfoo.yaml +109 -109
- package/ftm-brainstorm/references/agent-prompts.md +552 -224
- package/ftm-brainstorm/references/plan-template.md +209 -121
- package/ftm-brainstorm.yml +2 -2
- package/ftm-browse/SKILL.md +454 -454
- package/ftm-browse/daemon/browser-manager.ts +206 -206
- package/ftm-browse/daemon/bun.lock +30 -30
- package/ftm-browse/daemon/cli.ts +347 -347
- package/ftm-browse/daemon/commands.ts +410 -410
- package/ftm-browse/daemon/main.ts +357 -357
- package/ftm-browse/daemon/package.json +17 -17
- package/ftm-browse/daemon/server.ts +189 -189
- package/ftm-browse/daemon/snapshot.ts +519 -519
- package/ftm-browse/daemon/tsconfig.json +22 -22
- package/ftm-browse.yml +4 -4
- package/ftm-capture/SKILL.md +370 -370
- package/ftm-capture.yml +4 -4
- package/ftm-codex-gate/SKILL.md +361 -361
- package/ftm-codex-gate.yml +2 -2
- package/ftm-config/SKILL.md +422 -345
- package/ftm-config.default.yml +125 -82
- package/ftm-config.yml +44 -2
- package/ftm-council/SKILL.md +416 -416
- package/ftm-council/references/prompts/CLAUDE-INVESTIGATION.md +60 -60
- package/ftm-council/references/prompts/CODEX-INVESTIGATION.md +58 -58
- package/ftm-council/references/prompts/GEMINI-INVESTIGATION.md +58 -58
- package/ftm-council/references/prompts/REBUTTAL-TEMPLATE.md +57 -57
- package/ftm-council/references/protocols/PREREQUISITES.md +47 -47
- package/ftm-council/references/protocols/STEP-0-FRAMING.md +46 -46
- package/ftm-council.yml +2 -2
- package/ftm-dashboard/SKILL.md +163 -163
- package/ftm-dashboard.yml +4 -4
- package/ftm-debug/SKILL.md +1037 -1037
- package/ftm-debug/references/phases/PHASE-0-INTAKE.md +58 -58
- package/ftm-debug/references/phases/PHASE-1-TRIAGE.md +46 -46
- package/ftm-debug/references/phases/PHASE-2-WAR-ROOM-AGENTS.md +279 -279
- package/ftm-debug/references/phases/PHASE-3-TO-6-EXECUTION.md +436 -436
- package/ftm-debug/references/protocols/BLACKBOARD.md +86 -86
- package/ftm-debug/references/protocols/EDGE-CASES.md +103 -103
- package/ftm-debug.yml +2 -2
- package/ftm-diagram/SKILL.md +277 -277
- package/ftm-diagram.yml +2 -2
- package/ftm-executor/SKILL.md +777 -777
- package/ftm-executor/references/STYLE-TEMPLATE.md +73 -73
- package/ftm-executor/references/phases/PHASE-0-VERIFICATION.md +62 -62
- package/ftm-executor/references/phases/PHASE-2-AGENT-ASSEMBLY.md +34 -34
- package/ftm-executor/references/phases/PHASE-3-WORKTREES.md +38 -38
- package/ftm-executor/references/phases/PHASE-4-5-AUDIT.md +72 -72
- package/ftm-executor/references/phases/PHASE-4-DISPATCH.md +66 -66
- package/ftm-executor/references/phases/PHASE-5-5-CODEX-GATE.md +73 -73
- package/ftm-executor/references/protocols/DOCUMENTATION-BOOTSTRAP.md +36 -36
- package/ftm-executor/references/protocols/MODEL-PROFILE.md +59 -59
- package/ftm-executor/references/protocols/PROGRESS-TRACKING.md +66 -66
- package/ftm-executor/runtime/ftm-runtime.mjs +252 -252
- package/ftm-executor/runtime/package.json +8 -8
- package/ftm-executor.yml +2 -2
- package/ftm-git/SKILL.md +441 -441
- package/ftm-git/evals/evals.json +26 -26
- package/ftm-git/evals/promptfoo.yaml +75 -75
- package/ftm-git/hooks/post-commit-experience.sh +92 -92
- package/ftm-git/references/patterns/SECRET-PATTERNS.md +104 -104
- package/ftm-git/references/protocols/REMEDIATION.md +139 -139
- package/ftm-git/scripts/pre-commit-secrets.sh +110 -110
- package/ftm-git.yml +2 -2
- package/ftm-inbox/backend/__pycache__/main.cpython-314.pyc +0 -0
- package/ftm-inbox/backend/adapters/_retry.py +64 -64
- package/ftm-inbox/backend/adapters/base.py +230 -230
- package/ftm-inbox/backend/adapters/freshservice.py +104 -104
- package/ftm-inbox/backend/adapters/gmail.py +125 -125
- package/ftm-inbox/backend/adapters/jira.py +136 -136
- package/ftm-inbox/backend/adapters/registry.py +192 -192
- package/ftm-inbox/backend/adapters/slack.py +110 -110
- package/ftm-inbox/backend/db/connection.py +54 -54
- package/ftm-inbox/backend/db/schema.py +78 -78
- package/ftm-inbox/backend/executor/__init__.py +7 -7
- package/ftm-inbox/backend/executor/engine.py +149 -149
- package/ftm-inbox/backend/executor/step_runner.py +98 -98
- package/ftm-inbox/backend/main.py +103 -103
- package/ftm-inbox/backend/models/__init__.py +1 -1
- package/ftm-inbox/backend/models/unified_task.py +36 -36
- package/ftm-inbox/backend/planner/__init__.py +6 -6
- package/ftm-inbox/backend/planner/__pycache__/__init__.cpython-314.pyc +0 -0
- package/ftm-inbox/backend/planner/__pycache__/generator.cpython-314.pyc +0 -0
- package/ftm-inbox/backend/planner/__pycache__/schema.cpython-314.pyc +0 -0
- package/ftm-inbox/backend/planner/generator.py +127 -127
- package/ftm-inbox/backend/planner/schema.py +34 -34
- package/ftm-inbox/backend/requirements.txt +5 -5
- package/ftm-inbox/backend/routes/__pycache__/plan.cpython-314.pyc +0 -0
- package/ftm-inbox/backend/routes/execute.py +186 -186
- package/ftm-inbox/backend/routes/health.py +52 -52
- package/ftm-inbox/backend/routes/inbox.py +68 -68
- package/ftm-inbox/backend/routes/plan.py +271 -271
- package/ftm-inbox/bin/launchagent.mjs +91 -91
- package/ftm-inbox/bin/setup.mjs +188 -188
- package/ftm-inbox/bin/start.sh +10 -10
- package/ftm-inbox/bin/status.sh +17 -17
- package/ftm-inbox/bin/stop.sh +8 -8
- package/ftm-inbox/config.example.yml +55 -55
- package/ftm-inbox/package-lock.json +2898 -2898
- package/ftm-inbox/package.json +26 -26
- package/ftm-inbox/postcss.config.js +6 -6
- package/ftm-inbox/src/app.css +199 -199
- package/ftm-inbox/src/app.html +18 -18
- package/ftm-inbox/src/lib/api.ts +166 -166
- package/ftm-inbox/src/lib/components/ExecutionLog.svelte +81 -81
- package/ftm-inbox/src/lib/components/InboxFeed.svelte +143 -143
- package/ftm-inbox/src/lib/components/PlanStep.svelte +271 -271
- package/ftm-inbox/src/lib/components/PlanView.svelte +206 -206
- package/ftm-inbox/src/lib/components/StreamPanel.svelte +99 -99
- package/ftm-inbox/src/lib/components/TaskCard.svelte +190 -190
- package/ftm-inbox/src/lib/components/ui/EmptyState.svelte +63 -63
- package/ftm-inbox/src/lib/components/ui/KawaiiCard.svelte +86 -86
- package/ftm-inbox/src/lib/components/ui/PillButton.svelte +106 -106
- package/ftm-inbox/src/lib/components/ui/StatusBadge.svelte +67 -67
- package/ftm-inbox/src/lib/components/ui/StreamDrawer.svelte +149 -149
- package/ftm-inbox/src/lib/components/ui/ThemeToggle.svelte +80 -80
- package/ftm-inbox/src/lib/theme.ts +47 -47
- package/ftm-inbox/src/routes/+layout.svelte +76 -76
- package/ftm-inbox/src/routes/+page.svelte +401 -401
- package/ftm-inbox/svelte.config.js +12 -12
- package/ftm-inbox/tailwind.config.ts +63 -63
- package/ftm-inbox/tsconfig.json +13 -13
- package/ftm-inbox/vite.config.ts +6 -6
- package/ftm-intent/SKILL.md +241 -241
- package/ftm-intent.yml +2 -2
- package/ftm-manifest.json +3794 -3794
- package/ftm-map/SKILL.md +291 -291
- package/ftm-map/scripts/db.py +712 -712
- package/ftm-map/scripts/index.py +415 -415
- package/ftm-map/scripts/parser.py +224 -224
- package/ftm-map/scripts/queries/go-tags.scm +20 -20
- package/ftm-map/scripts/queries/javascript-tags.scm +35 -35
- package/ftm-map/scripts/queries/python-tags.scm +31 -31
- package/ftm-map/scripts/queries/ruby-tags.scm +19 -19
- package/ftm-map/scripts/queries/rust-tags.scm +37 -37
- package/ftm-map/scripts/queries/typescript-tags.scm +41 -41
- package/ftm-map/scripts/query.py +301 -301
- package/ftm-map/scripts/ranker.py +377 -377
- package/ftm-map/scripts/requirements.txt +5 -5
- package/ftm-map/scripts/setup-hooks.sh +27 -27
- package/ftm-map/scripts/setup.sh +56 -56
- package/ftm-map/scripts/test_db.py +364 -364
- package/ftm-map/scripts/test_parser.py +174 -174
- package/ftm-map/scripts/test_query.py +183 -183
- package/ftm-map/scripts/test_ranker.py +199 -199
- package/ftm-map/scripts/views.py +591 -591
- package/ftm-map.yml +2 -2
- package/ftm-mind/SKILL.md +201 -1943
- package/ftm-mind/evals/promptfoo.yaml +142 -142
- package/ftm-mind/references/blackboard-protocol.md +110 -0
- package/ftm-mind/references/blackboard-schema.md +328 -328
- package/ftm-mind/references/complexity-guide.md +110 -110
- package/ftm-mind/references/complexity-sizing.md +138 -0
- package/ftm-mind/references/decide-act-protocol.md +172 -0
- package/ftm-mind/references/direct-execution.md +51 -0
- package/ftm-mind/references/environment-discovery.md +77 -0
- package/ftm-mind/references/event-registry.md +319 -319
- package/ftm-mind/references/mcp-inventory.md +300 -296
- package/ftm-mind/references/ops-routing.md +47 -0
- package/ftm-mind/references/orient-protocol.md +234 -0
- package/ftm-mind/references/personality.md +40 -0
- package/ftm-mind/references/protocols/COMPLEXITY-SIZING.md +72 -72
- package/ftm-mind/references/protocols/MCP-HEURISTICS.md +32 -32
- package/ftm-mind/references/protocols/PLAN-APPROVAL.md +80 -80
- package/ftm-mind/references/reflexion-protocol.md +249 -249
- package/ftm-mind/references/routing/SCENARIOS.md +22 -22
- package/ftm-mind/references/routing-scenarios.md +35 -35
- package/ftm-mind.yml +2 -2
- package/ftm-ops.yml +4 -0
- package/ftm-pause/SKILL.md +395 -395
- package/ftm-pause/references/protocols/SKILL-RESTORE-PROTOCOLS.md +186 -186
- package/ftm-pause/references/protocols/VALIDATION.md +80 -80
- package/ftm-pause.yml +2 -2
- package/ftm-researcher/SKILL.md +275 -275
- package/ftm-researcher/evals/agent-diversity.yaml +17 -17
- package/ftm-researcher/evals/synthesis-quality.yaml +12 -12
- package/ftm-researcher/evals/trigger-accuracy.yaml +39 -39
- package/ftm-researcher/references/adaptive-search.md +116 -116
- package/ftm-researcher/references/agent-prompts.md +193 -193
- package/ftm-researcher/references/council-integration.md +193 -193
- package/ftm-researcher/references/output-format.md +203 -203
- package/ftm-researcher/references/synthesis-pipeline.md +165 -165
- package/ftm-researcher/scripts/score_credibility.py +234 -234
- package/ftm-researcher/scripts/validate_research.py +92 -92
- package/ftm-researcher.yml +2 -2
- package/ftm-resume/SKILL.md +518 -518
- package/ftm-resume/references/protocols/VALIDATION.md +172 -172
- package/ftm-resume.yml +2 -2
- package/ftm-retro/SKILL.md +380 -380
- package/ftm-retro/references/protocols/SCORING-RUBRICS.md +89 -89
- package/ftm-retro/references/templates/REPORT-FORMAT.md +109 -109
- package/ftm-retro.yml +2 -2
- package/ftm-routine/SKILL.md +170 -170
- package/ftm-routine.yml +4 -4
- package/ftm-state/blackboard/capabilities.json +5 -5
- package/ftm-state/blackboard/capabilities.schema.json +27 -27
- package/ftm-state/blackboard/context.json +37 -23
- package/ftm-state/blackboard/experiences/doom-statusline-fix.json +26 -0
- package/ftm-state/blackboard/experiences/hackathon-pages-site.json +26 -0
- package/ftm-state/blackboard/experiences/hindsight-sso-kickoff.json +42 -0
- package/ftm-state/blackboard/experiences/index.json +58 -9
- package/ftm-state/blackboard/experiences/learning-ragnarok-api-access.json +23 -0
- package/ftm-state/blackboard/experiences/nordlayer-members-auto-assign.json +26 -0
- package/ftm-state/blackboard/experiences/saml2aws-stale-session-fix.json +41 -0
- package/ftm-state/blackboard/patterns.json +6 -6
- package/ftm-state/schemas/context.schema.json +130 -130
- package/ftm-state/schemas/experience-index.schema.json +77 -77
- package/ftm-state/schemas/experience.schema.json +78 -78
- package/ftm-state/schemas/patterns.schema.json +44 -44
- package/ftm-upgrade/SKILL.md +194 -194
- package/ftm-upgrade/scripts/check-version.sh +76 -76
- package/ftm-upgrade/scripts/upgrade.sh +143 -143
- package/ftm-upgrade.yml +2 -2
- package/ftm-verify.yml +2 -2
- package/ftm.yml +2 -2
- package/hooks/ftm-auto-log.sh +137 -0
- package/hooks/ftm-blackboard-enforcer.sh +93 -93
- package/hooks/ftm-discovery-reminder.sh +90 -90
- package/hooks/ftm-drafts-gate.sh +61 -61
- package/hooks/ftm-event-logger.mjs +107 -107
- package/hooks/ftm-install-hooks.sh +240 -0
- package/hooks/ftm-learning-capture.sh +117 -0
- package/hooks/ftm-map-autodetect.sh +79 -79
- package/hooks/ftm-pending-sync-check.sh +22 -22
- package/hooks/ftm-plan-gate.sh +92 -92
- package/hooks/ftm-post-commit-trigger.sh +57 -57
- package/hooks/ftm-post-compaction.sh +138 -0
- package/hooks/ftm-pre-compaction.sh +147 -0
- package/hooks/ftm-session-end.sh +52 -0
- package/hooks/ftm-session-snapshot.sh +213 -0
- package/hooks/settings-template.json +81 -81
- package/install.sh +363 -363
- package/package.json +84 -84
- package/uninstall.sh +25 -25
package/ftm-brainstorm/SKILL.md
CHANGED
|
@@ -1,498 +1,1003 @@
|
|
|
1
|
-
---
|
|
2
|
-
name: ftm-brainstorm
|
|
3
|
-
description: Research-powered Socratic brainstorming that dispatches parallel agents to search the web and GitHub for real-world patterns, then synthesizes findings into actionable suggestions with citations. Use this skill whenever the user wants to brainstorm, explore ideas, think through a feature, plan a project, or flesh out a concept before building. Also triggers when the user pastes a large block of text (notes, prior brainstorm, meeting transcript, spec draft, stream-of-consciousness dump) and wants to turn it into something buildable — phrases like "help me build this", "turn this into a plan", "here's what I've been thinking", or just a big paste followed by "what do you think?" or "go". Triggers on "brainstorm", "help me think through", "I have an idea for", "how should I approach", "let's explore", "what if we built", "I'm thinking about", "help me figure out", or any conversation where the user has a concept they want to develop before writing code. Even vague ideas like "I want to build something that..." or "what's the best way to..." should trigger this skill.
|
|
4
|
-
---
|
|
5
|
-
|
|
6
|
-
## Events
|
|
7
|
-
|
|
8
|
-
### Emits
|
|
9
|
-
- `plan_generated` — when Phase 3 completes and plan is saved
|
|
10
|
-
- Payload: `{ plan_path, plan_title, task_count, wave_count }`
|
|
11
|
-
- `task_completed` — when the full brainstorm-to-plan cycle finishes
|
|
12
|
-
- Payload: `{ task_title, plan_path, duration_ms }`
|
|
13
|
-
|
|
14
|
-
### Listens To
|
|
15
|
-
- `task_received` — begin ideation when ftm-mind routes an incoming task for exploration
|
|
16
|
-
- Expected payload: `{ task_description, plan_path, wave_number, task_number }`
|
|
17
|
-
- `research_complete` — consume structured findings from ftm-researcher for the current research sprint
|
|
18
|
-
- Expected payload: `{ query, mode, findings_count, consensus_count, contested_count, unique_count, sources_count, council_used, duration_ms }`
|
|
19
|
-
|
|
20
|
-
## Config Read
|
|
21
|
-
|
|
22
|
-
Before dispatching any agents, read `~/.claude/ftm-config.yml`:
|
|
23
|
-
- Use the `planning` model from the active profile for all research agents
|
|
24
|
-
- Example: if profile is `balanced`, agents get `model: opus`
|
|
25
|
-
- If config missing, use session default
|
|
26
|
-
|
|
27
|
-
## Blackboard Read
|
|
28
|
-
|
|
29
|
-
Before starting, load context from the blackboard:
|
|
30
|
-
1. Read `~/.claude/ftm-state/blackboard/context.json` — check current_task, recent_decisions, active_constraints
|
|
31
|
-
2. Read `~/.claude/ftm-state/blackboard/experiences/index.json` — filter by task_type "feature"/"investigation"
|
|
32
|
-
3. Load top 3-5 matching experience files for past brainstorm lessons
|
|
33
|
-
4. Read `~/.claude/ftm-state/blackboard/patterns.json` — check execution_patterns and user_behavior
|
|
34
|
-
|
|
35
|
-
If missing or empty, proceed without.
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
- Turns
|
|
48
|
-
- Turns
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
-
|
|
53
|
-
-
|
|
54
|
-
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
**
|
|
76
|
-
|
|
77
|
-
**
|
|
78
|
-
- **
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
**Use
|
|
83
|
-
|
|
84
|
-
**
|
|
85
|
-
|
|
86
|
-
**
|
|
87
|
-
|
|
88
|
-
**You maintain a
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
-
|
|
93
|
-
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
#
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
##
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
Each
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
**
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
- **
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
- **
|
|
242
|
-
- **
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
**
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
|
|
327
|
-
---
|
|
328
|
-
|
|
329
|
-
##
|
|
330
|
-
|
|
331
|
-
**
|
|
332
|
-
|
|
333
|
-
**
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
**
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
|
|
386
|
-
|
|
387
|
-
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
-
|
|
392
|
-
-
|
|
393
|
-
|
|
394
|
-
|
|
395
|
-
|
|
396
|
-
|
|
397
|
-
|
|
398
|
-
|
|
399
|
-
|
|
400
|
-
|
|
401
|
-
|
|
402
|
-
|
|
403
|
-
|
|
404
|
-
|
|
405
|
-
|
|
406
|
-
-
|
|
407
|
-
|
|
408
|
-
|
|
409
|
-
|
|
410
|
-
|
|
411
|
-
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
|
|
422
|
-
|
|
423
|
-
|
|
424
|
-
|
|
425
|
-
|
|
426
|
-
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
|
|
430
|
-
|
|
431
|
-
|
|
432
|
-
|
|
433
|
-
|
|
434
|
-
|
|
435
|
-
|
|
436
|
-
|
|
437
|
-
|
|
438
|
-
|
|
439
|
-
|
|
440
|
-
|
|
441
|
-
|
|
442
|
-
|
|
443
|
-
|
|
444
|
-
|
|
445
|
-
|
|
446
|
-
|
|
447
|
-
|
|
448
|
-
|
|
449
|
-
##
|
|
450
|
-
|
|
451
|
-
|
|
452
|
-
|
|
453
|
-
|
|
454
|
-
|
|
455
|
-
|
|
456
|
-
|
|
457
|
-
|
|
458
|
-
|
|
459
|
-
|
|
460
|
-
|
|
461
|
-
|
|
462
|
-
|
|
463
|
-
|
|
464
|
-
|
|
465
|
-
|
|
466
|
-
|
|
467
|
-
|
|
468
|
-
|
|
469
|
-
|
|
470
|
-
|
|
471
|
-
|
|
472
|
-
|
|
473
|
-
-
|
|
474
|
-
-
|
|
475
|
-
-
|
|
476
|
-
-
|
|
477
|
-
|
|
478
|
-
|
|
479
|
-
|
|
480
|
-
|
|
481
|
-
|
|
482
|
-
|
|
483
|
-
|
|
484
|
-
|
|
485
|
-
|
|
486
|
-
|
|
487
|
-
|
|
488
|
-
|
|
489
|
-
|
|
490
|
-
|
|
491
|
-
|
|
492
|
-
|
|
493
|
-
|
|
494
|
-
|
|
495
|
-
|
|
496
|
-
|
|
497
|
-
|
|
498
|
-
|
|
1
|
+
---
|
|
2
|
+
name: ftm-brainstorm
|
|
3
|
+
description: Research-powered Socratic brainstorming that dispatches parallel agents to search the web and GitHub for real-world patterns, then synthesizes findings into actionable suggestions with citations. Use this skill whenever the user wants to brainstorm, explore ideas, think through a feature, plan a project, or flesh out a concept before building. Also triggers when the user pastes a large block of text (notes, prior brainstorm, meeting transcript, spec draft, stream-of-consciousness dump) and wants to turn it into something buildable — phrases like "help me build this", "turn this into a plan", "here's what I've been thinking", or just a big paste followed by "what do you think?" or "go". Triggers on "brainstorm", "help me think through", "I have an idea for", "how should I approach", "let's explore", "what if we built", "I'm thinking about", "help me figure out", or any conversation where the user has a concept they want to develop before writing code. Even vague ideas like "I want to build something that..." or "what's the best way to..." should trigger this skill.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
## Events
|
|
7
|
+
|
|
8
|
+
### Emits
|
|
9
|
+
- `plan_generated` — when Phase 3 completes and plan is saved
|
|
10
|
+
- Payload: `{ plan_path, plan_title, task_count, wave_count }`
|
|
11
|
+
- `task_completed` — when the full brainstorm-to-plan cycle finishes
|
|
12
|
+
- Payload: `{ task_title, plan_path, duration_ms }`
|
|
13
|
+
|
|
14
|
+
### Listens To
|
|
15
|
+
- `task_received` — begin ideation when ftm-mind routes an incoming task for exploration
|
|
16
|
+
- Expected payload: `{ task_description, plan_path, wave_number, task_number }`
|
|
17
|
+
- `research_complete` — consume structured findings from ftm-researcher for the current research sprint
|
|
18
|
+
- Expected payload: `{ query, mode, findings_count, consensus_count, contested_count, unique_count, sources_count, council_used, duration_ms }`
|
|
19
|
+
|
|
20
|
+
## Config Read
|
|
21
|
+
|
|
22
|
+
Before dispatching any agents, read `~/.claude/ftm-config.yml`:
|
|
23
|
+
- Use the `planning` model from the active profile for all research agents
|
|
24
|
+
- Example: if profile is `balanced`, agents get `model: opus`
|
|
25
|
+
- If config missing, use session default
|
|
26
|
+
|
|
27
|
+
## Blackboard Read
|
|
28
|
+
|
|
29
|
+
Before starting, load context from the blackboard:
|
|
30
|
+
1. Read `~/.claude/ftm-state/blackboard/context.json` — check current_task, recent_decisions, active_constraints
|
|
31
|
+
2. Read `~/.claude/ftm-state/blackboard/experiences/index.json` — filter by task_type "feature"/"investigation"
|
|
32
|
+
3. Load top 3-5 matching experience files for past brainstorm lessons
|
|
33
|
+
4. Read `~/.claude/ftm-state/blackboard/patterns.json` — check execution_patterns and user_behavior
|
|
34
|
+
|
|
35
|
+
If missing or empty, proceed without.
|
|
36
|
+
|
|
37
|
+
## Research Sprint Dispatch
|
|
38
|
+
|
|
39
|
+
Each research sprint invokes ftm-researcher rather than dispatching agents directly.
|
|
40
|
+
|
|
41
|
+
Interface:
|
|
42
|
+
- Pass: { research_question: [derived from current turn], context_register: [all prior findings], depth_mode: [based on turn number] }
|
|
43
|
+
- Receive: { findings, disagreement_map, confidence_scores }
|
|
44
|
+
|
|
45
|
+
Depth mode mapping:
|
|
46
|
+
- Turns 1-2 (BROAD): ftm-researcher quick mode (3 finders)
|
|
47
|
+
- Turns 3-5 (FOCUSED): ftm-researcher standard mode (7 finders + reconciler)
|
|
48
|
+
- Turns 6+ (IMPLEMENTATION): ftm-researcher deep mode (full pipeline with council)
|
|
49
|
+
|
|
50
|
+
The brainstorm skill consumes the researcher's structured output and weaves it into:
|
|
51
|
+
- 3-5 numbered suggestions with evidence and source URLs
|
|
52
|
+
- A recommended option with rationale
|
|
53
|
+
- Challenges based on contested claims from the disagreement map
|
|
54
|
+
- Targeted questions based on research gaps
|
|
55
|
+
|
|
56
|
+
---
|
|
57
|
+
|
|
58
|
+
# THE CORE LOOP
|
|
59
|
+
|
|
60
|
+
This skill is a **multi-turn research conversation**. Every single turn after the first follows the same cycle. There are no shortcuts, no collapsing turns, no "let me just generate the plan now."
|
|
61
|
+
|
|
62
|
+
```
|
|
63
|
+
EVERY TURN (after initial intake):
|
|
64
|
+
1. RESEARCH SPRINT — 7 agents search in parallel from different vectors + synthesizer reconciles
|
|
65
|
+
2. SYNTHESIZE — merge findings into suggestions with evidence
|
|
66
|
+
3. CHALLENGE — observations that push back on assumptions (NOT questions)
|
|
67
|
+
4. ASK VIA UI — use AskUserQuestion tool (1-4 questions, clickable options)
|
|
68
|
+
5. >>> STOP <<< — wait for the user. Do NOT continue.
|
|
69
|
+
```
|
|
70
|
+
|
|
71
|
+
The research sprints get progressively deeper. The questions get progressively sharper. Each cycle builds on everything before it. The goal is to extract the user's complete vision AND ground it in real-world evidence before generating any plan.
|
|
72
|
+
|
|
73
|
+
**Use `AskUserQuestion` for all questions.** This gives the user a clickable selection UI instead of making them type answers. Format every question with 2-4 labeled options, each with a short description of the trade-off. The user clicks their choice (or picks "Other" to type a custom answer). This is faster, less friction, and prevents answers from getting lost.
|
|
74
|
+
|
|
75
|
+
**Batching rules:** `AskUserQuestion` supports 1-4 questions per call. Use this intelligently:
|
|
76
|
+
- **Batch independent questions together** (up to 4) when the answer to one doesn't affect the options for another. Example: "Output format?" and "Config file approach?" are independent — batch them.
|
|
77
|
+
- **Ask sequentially** when answers are dependent — if the answer to question 1 changes what you'd ask for question 2, don't batch them. Ask question 1 first, process the answer, then ask question 2 on the next turn.
|
|
78
|
+
- **After each batch, run a research sprint** before asking the next batch. The answers may open new research directions.
|
|
79
|
+
|
|
80
|
+
**Use previews for concrete comparisons.** When options involve code patterns, file structures, or architectural layouts, use the `preview` field to show the user what each option looks like. Example: showing a flat transcript format vs a timestamped JSON format side by side.
|
|
81
|
+
|
|
82
|
+
**Use `multiSelect: true`** when choices aren't mutually exclusive. Example: "Which meeting apps should we support?" — the user might want both Zoom and Meet.
|
|
83
|
+
|
|
84
|
+
**Track what's been answered.** Before asking anything, check your context register. If the user already addressed a topic (even as an aside in a longer message), mark it answered and move on. Never re-ask something the user has already addressed, even if they answered it in a different format than you expected.
|
|
85
|
+
|
|
86
|
+
**You maintain a CONTEXT REGISTER** — a running mental document of everything learned so far. Every research sprint receives this register so agents don't re-search old ground. After each turn, append what you learned.
|
|
87
|
+
|
|
88
|
+
**You maintain a PRIOR DECISIONS LOG** — a structured record of every decision the user has made across ALL turns. Format:
|
|
89
|
+
|
|
90
|
+
```
|
|
91
|
+
PRIOR DECISIONS:
|
|
92
|
+
- D-01: [decision] (Turn N)
|
|
93
|
+
- D-02: [decision] (Turn N)
|
|
94
|
+
...
|
|
95
|
+
```
|
|
96
|
+
|
|
97
|
+
Before asking ANY question, check this log. If the user already decided something — even indirectly — do NOT re-ask. This log persists across sessions via ftm-pause/resume.
|
|
98
|
+
|
|
99
|
+
**Research depth escalates automatically:**
|
|
100
|
+
- **Turns 1-2: BROAD** — map the landscape, major approaches, who's done this
|
|
101
|
+
- **Turns 3-5: FOCUSED** — drill into the user's chosen direction, real trade-offs, failure modes
|
|
102
|
+
- **Turns 6+: IMPLEMENTATION** — concrete libraries, code patterns, integration specifics
|
|
103
|
+
|
|
104
|
+
---
|
|
105
|
+
|
|
106
|
+
# ANTI-RATIONALIZATION PROTOCOL
|
|
107
|
+
|
|
108
|
+
Every phase of this skill has moments where you'll be tempted to skip process. This table applies GLOBALLY — check it before every shortcut.
|
|
109
|
+
|
|
110
|
+
| Thought | Reality |
|
|
111
|
+
|---|---|
|
|
112
|
+
| "This idea is simple, skip deep research" | Simple ideas have hidden complexity. Research it. |
|
|
113
|
+
| "The user seems eager to code" | Eagerness isn't readiness. Finish the brainstorm. |
|
|
114
|
+
| "Research is returning similar results" | Similar ≠ saturated. Reformulate queries with more specific terms. |
|
|
115
|
+
| "I already know the best approach" | Your training data is stale. Search for what's current. |
|
|
116
|
+
| "The user answered enough questions" | You decide depth by research saturation, not question count. |
|
|
117
|
+
| "Let me just generate the plan now" | Phase 3 requires explicit user request. HARD GATE. |
|
|
118
|
+
| "This is just a quick feature" | Quick features become complex systems. Research it. |
|
|
119
|
+
| "I can skip the pre-mortem, the plan looks solid" | That's exactly when pre-mortems catch things. Run it. |
|
|
120
|
+
| "The assumption audit would slow us down" | Crackable assumptions caught now save weeks of rework. |
|
|
121
|
+
| "One more turn won't surface anything new" | Run the sprint. Let the research prove it, don't assume it. |
|
|
122
|
+
| "The user already validated this approach" | Validation from the user ≠ validation from evidence. |
|
|
123
|
+
|
|
124
|
+
**Red flags in your own behavior:**
|
|
125
|
+
- Generating suggestions without dispatching agents first → STOP
|
|
126
|
+
- Offering to move to Phase 3 before the user asks → STOP
|
|
127
|
+
- Asking a question the user already answered → check context register
|
|
128
|
+
- Presenting only one approach → you haven't researched enough
|
|
129
|
+
- Skipping challenges because everything looks good → research harder
|
|
130
|
+
|
|
131
|
+
---
|
|
132
|
+
|
|
133
|
+
# PHASE 0: REPO SCAN (automatic, silent)
|
|
134
|
+
|
|
135
|
+
Run this in the background before your first response. Do not ask.
|
|
136
|
+
|
|
137
|
+
Spawn an **Explore** agent (subagent_type: Explore):
|
|
138
|
+
```
|
|
139
|
+
Analyze the current repository: project type, tech stack, architecture,
|
|
140
|
+
patterns in use, existing infrastructure, scale indicators.
|
|
141
|
+
Focus on what's relevant for proposing new features or architectural changes.
|
|
142
|
+
Map: reusable assets, established patterns, integration points, dependency graph highlights.
|
|
143
|
+
```
|
|
144
|
+
|
|
145
|
+
Store as your project context. Reference throughout all phases. If not in a git repo, skip and ask about stack during intake.
|
|
146
|
+
|
|
147
|
+
---
|
|
148
|
+
|
|
149
|
+
# PHASE 1: INTAKE
|
|
150
|
+
|
|
151
|
+
Detect which path you're on:
|
|
152
|
+
|
|
153
|
+
## Path A: Fresh Idea (short/vague message)
|
|
154
|
+
|
|
155
|
+
**Questioning philosophy (from GSD):** This is dream extraction, not requirements gathering. You're a thinking partner, not an interviewer. Start open — let them dump their mental model. Follow energy — whatever they emphasized, dig into that. Challenge vagueness — "good" means what? "users" means who? "simple" means how? Make the abstract concrete — "walk me through using this."
|
|
156
|
+
|
|
157
|
+
**Anti-patterns to avoid:**
|
|
158
|
+
- Checklist walking (going through domains regardless of what they said)
|
|
159
|
+
- Canned questions ("What are your success criteria?" regardless of context)
|
|
160
|
+
- Corporate speak ("Who are your stakeholders?")
|
|
161
|
+
- Interrogation (firing questions without building on answers)
|
|
162
|
+
- Rushing (minimizing questions to get to "the work")
|
|
163
|
+
- Shallow acceptance (taking vague answers without probing)
|
|
164
|
+
- Premature constraints (asking about tech stack before understanding the idea)
|
|
165
|
+
- Asking about user's skills (NEVER ask about technical experience — Claude builds)
|
|
166
|
+
|
|
167
|
+
**Turn 1 ONLY:** Ask ONE question to understand the core idea — the single most important unknown. If the opening message covers basics (what, who, problem), skip to the first research sprint.
|
|
168
|
+
|
|
169
|
+
**>>> STOP. Wait for response. <<<**
|
|
170
|
+
|
|
171
|
+
**Turn 2:** Take the user's answer. NOW run your first research sprint (7 agents, BROAD depth — see Phase 2). Synthesize, challenge (observations only), then ask ONE question — the single most important decision point that research surfaced. Frame it with specific options from the research.
|
|
172
|
+
|
|
173
|
+
**>>> STOP. Wait for response. <<<**
|
|
174
|
+
|
|
175
|
+
**Turn 3+:** You're now in the core loop. Every turn from here follows the cycle: research sprint -> synthesize -> challenge (observations) -> ask via AskUserQuestion -> STOP.
|
|
176
|
+
|
|
177
|
+
## Path B: Brain Dump (large paste, notes, transcript)
|
|
178
|
+
|
|
179
|
+
**Turn 1:** Parse the entire paste. Extract: decisions already made, open questions, assumptions to validate, contradictions, gaps. Present structured summary. Then ask ONE confirmation question — the single biggest gap or ambiguity. Do NOT ask basic questions already answered in the paste. Do NOT list all open questions — pick the most critical one.
|
|
180
|
+
|
|
181
|
+
**>>> STOP. Wait for confirmation. <<<**
|
|
182
|
+
|
|
183
|
+
**Turn 2:** Take the confirmation. Run first research sprint in BRAIN DUMP MODE (agents search for each specific architectural claim from the paste). Present novelty map. Synthesize, challenge (observations only), then ask ONE question about the most important decision point the research surfaced.
|
|
184
|
+
|
|
185
|
+
**>>> STOP. Wait for response. <<<**
|
|
186
|
+
|
|
187
|
+
**Turn 3+:** Core loop continues. One question per turn.
|
|
188
|
+
|
|
189
|
+
---
|
|
190
|
+
|
|
191
|
+
# DISCUSS MODE
|
|
192
|
+
|
|
193
|
+
When the user provides a clear, specific spec or feature description (not a vague idea), skip broad research and go straight to targeted analysis.
|
|
194
|
+
|
|
195
|
+
## Detection
|
|
196
|
+
|
|
197
|
+
Discuss mode activates when:
|
|
198
|
+
- The user's input is 200+ words with specific technical details
|
|
199
|
+
- The user says "I know what I want to build" or "here's my spec" or "discuss this"
|
|
200
|
+
- The input contains file paths, function names, or architecture details
|
|
201
|
+
- The user explicitly requests "discuss" rather than "brainstorm"
|
|
202
|
+
|
|
203
|
+
## Flow
|
|
204
|
+
|
|
205
|
+
Instead of the standard brainstorm research -> synthesis -> suggestions flow:
|
|
206
|
+
|
|
207
|
+
1. **Parse the spec** — Extract: what's being built, key components, tech stack, constraints
|
|
208
|
+
2. **Identify gray areas** — Use the Gray Area Detection Heuristics (see module below) to systematically find unknowns
|
|
209
|
+
3. **Ask targeted questions** — Present 3-5 specific questions about the gray areas via AskUserQuestion
|
|
210
|
+
4. **Refine based on answers** — Each answer narrows the spec. After 2-3 rounds of Q&A, the spec should be implementation-ready.
|
|
211
|
+
5. **Output: implementation-ready spec** — Not a brainstorm document, but a tight spec that can feed directly into plan generation.
|
|
212
|
+
|
|
213
|
+
---
|
|
214
|
+
|
|
215
|
+
# PHASE 2: RESEARCH + CHALLENGE LOOP
|
|
216
|
+
|
|
217
|
+
This is the heart of the skill. Unlimited turns. Each one follows the cycle.
|
|
218
|
+
|
|
219
|
+
## Step 1: Dispatch Research Sprint
|
|
220
|
+
|
|
221
|
+
Every turn, read `references/agent-prompts.md` and spawn **7 parallel agents + 1 synthesizer** (subagent_type: general-purpose, model: from ftm-config `planning` profile). Each agent gets:
|
|
222
|
+
|
|
223
|
+
1. **Project context** from Phase 0
|
|
224
|
+
2. **Full context register** — everything learned across ALL prior turns
|
|
225
|
+
3. **Prior decisions log** — every decision made so far
|
|
226
|
+
4. **Research depth level** for this turn (broad/focused/implementation)
|
|
227
|
+
5. **Previous findings summary** so they don't re-search
|
|
228
|
+
6. **This turn's specific research question** — derived from what the user just said
|
|
229
|
+
7. **Brain dump claims** if Path B
|
|
230
|
+
|
|
231
|
+
The 7 agents search from different vectors:
|
|
232
|
+
- **Web Researcher** — blog posts, case studies, architectural write-ups
|
|
233
|
+
- **GitHub Explorer** — repos, code patterns, open-source implementations
|
|
234
|
+
- **Competitive Analyst** — products, tools, market gaps, user complaints
|
|
235
|
+
- **Stack Researcher** — tech stack evaluation, library comparison, dependency risks
|
|
236
|
+
- **Architecture Researcher** — system design patterns, scaling approaches, failure modes at scale
|
|
237
|
+
- **Pitfall Researcher** — anti-patterns, post-mortems, "what went wrong" case studies
|
|
238
|
+
- **UX/Domain Researcher** — UX patterns, accessibility standards, domain-specific conventions
|
|
239
|
+
|
|
240
|
+
After all 7 return, dispatch the **Synthesizer** agent which receives ALL findings and produces:
|
|
241
|
+
- **Consensus claims** — things multiple agents agree on
|
|
242
|
+
- **Contested claims** — things agents disagree on (with the disagreement explained)
|
|
243
|
+
- **Unique insights** — things only one agent found that are noteworthy
|
|
244
|
+
- **Research gaps** — what nobody found (gaps are signal)
|
|
245
|
+
- **Confidence scores** — per-finding confidence based on source quality and agreement
|
|
246
|
+
|
|
247
|
+
Each turn's research question should be DIFFERENT from the last. The user's response reveals new angles, constraints, or decisions — use those to formulate new, more specific search queries. If the user chose approach A over B, this turn's research digs into A's implementation details, not the broad landscape again.
|
|
248
|
+
|
|
249
|
+
## Step 2: Synthesize into 3-5 Suggestions
|
|
250
|
+
|
|
251
|
+
Once the synthesizer returns, merge findings into **3-5 numbered suggestions**. Lead with your recommendation.
|
|
252
|
+
|
|
253
|
+
Each suggestion needs:
|
|
254
|
+
1. **The suggestion** — concrete and actionable
|
|
255
|
+
2. **Real-world evidence** — which search results back this up, with URLs
|
|
256
|
+
3. **Why this matters** — specific advantage for this project
|
|
257
|
+
4. **Trade-off** — what you give up
|
|
258
|
+
5. **Confidence** — high/medium/low based on synthesizer's confidence scores
|
|
259
|
+
|
|
260
|
+
Label suggestion #1 as **RECOMMENDED** with a "Why I'd pick this" rationale.
|
|
261
|
+
|
|
262
|
+
If research was thin, present fewer suggestions. Quality over quantity. If all agents returned weak results, be honest: "Research didn't surface strong prior art — this might be genuinely novel, or we should reframe the search."
|
|
263
|
+
|
|
264
|
+
**Brain dump mode:** Present a **Novelty Map** table before suggestions:
|
|
265
|
+
|
|
266
|
+
| Brain Dump Claim | Verdict | Evidence |
|
|
267
|
+
|---|---|---|
|
|
268
|
+
| [claim] | Solved / Partially Solved / Novel | [link or explanation] |
|
|
269
|
+
|
|
270
|
+
## Step 3: Challenge (Observations, NOT Questions)
|
|
271
|
+
|
|
272
|
+
After suggestions, share 2-3 observations that challenge or refine the user's thinking. These are STATEMENTS, not questions. The user can respond to them if they want, but they don't create answer obligations.
|
|
273
|
+
|
|
274
|
+
Good challenge formats (declarative):
|
|
275
|
+
- **"Worth noting that..."** — surface a pattern they may not know about
|
|
276
|
+
- **"At scale, X typically becomes a bottleneck because..."** — flag edge cases
|
|
277
|
+
- **"The evidence suggests X contradicts the assumption about Y..."** — when research contradicts something
|
|
278
|
+
- **"Successful implementations of this (e.g., [product]) launched with only..."** — YAGNI signal
|
|
279
|
+
- **"Users of [product] reported frustration with..."** — inject real feedback
|
|
280
|
+
- **"The pitfall research surfaced that teams who tried X typically hit Y within Z months..."** — failure mode warning
|
|
281
|
+
|
|
282
|
+
Bad challenge formats (these are disguised questions — do NOT use):
|
|
283
|
+
- ~~"Have you considered..."~~ — this demands a yes/no answer
|
|
284
|
+
- ~~"What happens when..."~~ — this demands the user think through a scenario
|
|
285
|
+
- ~~"How would you handle..."~~ — this is just a question with extra steps
|
|
286
|
+
|
|
287
|
+
**YAGNI instinct:** Actively look for scope to cut. If research shows successful products launched with less, state it as an observation.
|
|
288
|
+
|
|
289
|
+
## Step 4: Ask Questions via AskUserQuestion
|
|
290
|
+
|
|
291
|
+
Use the `AskUserQuestion` tool for every question. Never just type a question in chat — always use the tool so the user gets the clickable selection UI.
|
|
292
|
+
|
|
293
|
+
**Maintain a question queue internally.** Prioritize by:
|
|
294
|
+
1. Which question unlocks the most downstream decisions (answering it resolves or narrows others)
|
|
295
|
+
2. Which requires the user's judgment (can't be answered by more research)
|
|
296
|
+
3. Which has the highest impact on the architecture
|
|
297
|
+
|
|
298
|
+
**Batch independent questions (up to 4 per call).** Review your queue — if the top 2-3 questions don't depend on each other's answers, send them in a single `AskUserQuestion` call. The user clicks through them quickly in the UI. If answers ARE dependent, send only the blocking question and save the rest.
|
|
299
|
+
|
|
300
|
+
**Format each question well:**
|
|
301
|
+
- `header`: Short tag, max 12 chars (e.g., "Output", "Trigger", "Auth")
|
|
302
|
+
- `options`: 2-4 choices, each with a clear `label` (1-5 words) and `description` (trade-off explanation)
|
|
303
|
+
- Put your recommended option first with "(Recommended)" in the label
|
|
304
|
+
- `multiSelect: true` when choices aren't exclusive
|
|
305
|
+
- `preview` for code/config/layout comparisons
|
|
306
|
+
|
|
307
|
+
Some questions will become unnecessary as earlier answers clarify things — drop them from the queue when that happens.
|
|
308
|
+
|
|
309
|
+
**When your initial question queue runs dry, DO NOT suggest wrapping up.** Instead, run a fresh research sprint using EVERYTHING you've learned so far. This sprint should go deeper than any previous one because now you have the user's full picture. The research will surface new unknowns, edge cases, failure modes, and implementation details that generate NEW questions. Present the findings with new suggestions and observations, then ask ONE question from the new unknowns the research surfaced. The loop keeps going — research always generates more questions if you dig deep enough.
|
|
310
|
+
|
|
311
|
+
**Research-driven question generation:** After each research sprint, actively mine the findings for questions the user hasn't considered yet. Examples: "The research surfaced that CoreAudio Taps require re-granting permissions weekly on Sonoma — how do you want to handle that UX?" or "Three of the repos I found use a daemon model instead of start/stop — worth considering?" The best brainstorms surface things the user didn't know to ask about. If your research isn't generating new questions, your research queries aren't specific enough — reformulate and go deeper.
|
|
312
|
+
|
|
313
|
+
**After your question, signal what's next.** Something like: "Answer this and I'll dig into [next topic area]." Do NOT offer to move to planning — let the user tell you when they're ready. The user should never feel like the brainstorm is wrapping up unless THEY decide it is.
|
|
314
|
+
|
|
315
|
+
## Step 5: STOP
|
|
316
|
+
|
|
317
|
+
**>>> STOP. Do NOT continue to the next turn. Wait for the user. <<<**
|
|
318
|
+
|
|
319
|
+
This is non-negotiable. The user's response is the input for the next research sprint. Without it, the next sprint has nothing new to search for.
|
|
320
|
+
|
|
321
|
+
---
|
|
322
|
+
|
|
323
|
+
# CREATIVITY MODULES
|
|
324
|
+
|
|
325
|
+
These modules activate at specific points in the brainstorm based on context. Each is a self-contained technique that can also be invoked explicitly by the user saying "run [module name]". When a module activates, announce it: "Activating [module] to [purpose]."
|
|
326
|
+
|
|
327
|
+
---
|
|
328
|
+
|
|
329
|
+
## Module: GRAY AREA DETECTION
|
|
330
|
+
|
|
331
|
+
**Activates:** Automatically in Discuss Mode. Also runs once during Phase 2 after feature type is detected.
|
|
332
|
+
|
|
333
|
+
**Source:** GSD discuss-phase heuristics
|
|
334
|
+
|
|
335
|
+
Systematically identify unknowns by categorizing what the feature involves:
|
|
336
|
+
|
|
337
|
+
| Category | Heuristic | Example Gray Areas |
|
|
338
|
+
|---|---|---|
|
|
339
|
+
| Something users **SEE** | Visual presentation, interactions, states | Layout density? Responsive approach? Loading/empty/error states? Animation? |
|
|
340
|
+
| Something users **CALL** | Interface contracts, responses, errors | REST vs GraphQL? Auth mechanism? Pagination? Error codes? Versioning? |
|
|
341
|
+
| Something users **RUN** | Invocation, output, behavior modes | Interactive or batch? Output format? Config approach? Daemon vs one-shot? |
|
|
342
|
+
| Something users **READ** | Structure, tone, depth, flow | Content hierarchy? Tone? Depth levels? Navigation? |
|
|
343
|
+
| Something being **ORGANIZED** | Criteria, grouping, exception handling | Sort/filter logic? Grouping rules? Edge case handling? |
|
|
344
|
+
|
|
345
|
+
**Feature-Type Specific Gray Areas:**
|
|
346
|
+
|
|
347
|
+
| Feature Type | Signals | Key Gray Areas |
|
|
348
|
+
|---|---|---|
|
|
349
|
+
| UI/Frontend | "page", "component", "dashboard" | Layout density, responsive approach, loading/empty/error states, accessibility |
|
|
350
|
+
| API/Backend | "endpoint", "API", "service" | REST vs GraphQL, auth mechanism, pagination, rate limiting, versioning |
|
|
351
|
+
| Data/Storage | "database", "store", "persist" | SQL vs NoSQL, read/write ratio, consistency requirements, migration strategy |
|
|
352
|
+
| Integration | "connect to", "sync with" | Push/pull/both, real-time or batch, retry handling, data mapping |
|
|
353
|
+
| Automation | "automate", "trigger", "schedule" | Trigger mechanism, failure notification, idempotency, monitoring |
|
|
354
|
+
| CLI Tool | "command", "CLI", "terminal" | Interactive or not, output format, config approach, distribution, daemon vs one-shot, error recovery, shell completions |
|
|
355
|
+
| AI/ML | "AI", "model", "generate", "LLM" | Which model, latency tolerance, fallback, cost ceiling, eval strategy |
|
|
356
|
+
|
|
357
|
+
Present discovered gray areas via AskUserQuestion, letting the user select which ones to discuss (multiSelect: true).
|
|
358
|
+
|
|
359
|
+
---
|
|
360
|
+
|
|
361
|
+
## Module: FIRST PRINCIPLES ASSUMPTION AUDIT
|
|
362
|
+
|
|
363
|
+
**Activates:** Once, during turns 2-3 when the problem space is defined but before deep research begins. Also activatable via "audit assumptions" or "challenge my assumptions."
|
|
364
|
+
|
|
365
|
+
**Purpose:** Surface hidden assumptions that constrain the solution space unnecessarily.
|
|
366
|
+
|
|
367
|
+
**Process — spawn 1 agent (subagent_type: general-purpose):**
|
|
368
|
+
|
|
369
|
+
```
|
|
370
|
+
You are conducting a First Principles Assumption Audit. Analyze the following idea
|
|
371
|
+
and extract assumptions at 5 levels:
|
|
372
|
+
|
|
373
|
+
IDEA: {user's idea + context register}
|
|
374
|
+
|
|
375
|
+
Level 1 — SURFACE ASSUMPTIONS (observable):
|
|
376
|
+
What behaviors, features, or outcomes is the user assuming?
|
|
377
|
+
|
|
378
|
+
Level 2 — PROCESS ASSUMPTIONS (how things "should" work):
|
|
379
|
+
What workflows, sequences, or methods is the user taking for granted?
|
|
380
|
+
|
|
381
|
+
Level 3 — STRUCTURAL ASSUMPTIONS (constraints treated as fixed):
|
|
382
|
+
What technical, organizational, or resource constraints are being accepted without question?
|
|
383
|
+
|
|
384
|
+
Level 4 — CULTURAL ASSUMPTIONS (beliefs about users/market):
|
|
385
|
+
What beliefs about user behavior, market needs, or competitive landscape are implicit?
|
|
386
|
+
|
|
387
|
+
Level 5 — FUNDAMENTAL ASSUMPTIONS (psychological/systemic):
|
|
388
|
+
What deeper truths about human behavior or system dynamics are being assumed?
|
|
389
|
+
|
|
390
|
+
For each assumption, classify as:
|
|
391
|
+
- VALID: supported by evidence, should keep
|
|
392
|
+
- QUESTIONABLE: might not hold, worth investigating
|
|
393
|
+
- CRACKABLE: presented as unchangeable but is actually a design choice — HIGH VALUE
|
|
394
|
+
|
|
395
|
+
Return as a structured list with level, assumption text, classification, and why.
|
|
396
|
+
```
|
|
397
|
+
|
|
398
|
+
**Present to user as:**
|
|
399
|
+
```
|
|
400
|
+
Assumption Audit — [N] assumptions found, [M] crackable:
|
|
401
|
+
|
|
402
|
+
CRACKABLE (design choices disguised as constraints):
|
|
403
|
+
- [assumption] — Why it's crackable: [explanation]
|
|
404
|
+
|
|
405
|
+
QUESTIONABLE (worth investigating):
|
|
406
|
+
- [assumption] — Why it's questionable: [explanation]
|
|
407
|
+
|
|
408
|
+
VALID (keep these):
|
|
409
|
+
- [assumption] — Supporting evidence: [brief]
|
|
410
|
+
```
|
|
411
|
+
|
|
412
|
+
Let user mark each as "keep", "challenge", or "ignore" via AskUserQuestion. Crackable assumptions become research targets for the next sprint.
|
|
413
|
+
|
|
414
|
+
---
|
|
415
|
+
|
|
416
|
+
## Module: MULTI-PERSPECTIVE STAKEHOLDER SIMULATION
|
|
417
|
+
|
|
418
|
+
**Activates:** When 3+ viable approaches exist and the user needs help choosing. Also activatable via "get perspectives" or "what would [stakeholder] think?"
|
|
419
|
+
|
|
420
|
+
**Purpose:** Eliminate blind spots by forcing analysis through multiple distinct viewpoints.
|
|
421
|
+
|
|
422
|
+
**Process — spawn 4-6 parallel agents, each roleplaying a domain-specific persona:**
|
|
423
|
+
|
|
424
|
+
Select personas based on the project context. Default set:
|
|
425
|
+
|
|
426
|
+
| Persona | Lens | Key Question |
|
|
427
|
+
|---|---|---|
|
|
428
|
+
| The Skeptical CFO | ROI, cost, sustainability | "Justify every dollar and hour." |
|
|
429
|
+
| The Overwhelmed User | Simplicity, time-to-value | "I have 5 minutes. Can I figure this out?" |
|
|
430
|
+
| The Security Auditor | Attack vectors, data exposure | "What can go wrong? What data is at risk?" |
|
|
431
|
+
| The Competitor PM | Defensibility, differentiation | "How would I copy this? What's the moat?" |
|
|
432
|
+
| The Support Lead | Failure modes, confusion points | "What tickets will this generate?" |
|
|
433
|
+
| The 5-Year Maintainer | Tech debt, scalability, clarity | "Will this still make sense? What rots?" |
|
|
434
|
+
|
|
435
|
+
Each agent receives the current top 3 approaches and evaluates them through their persona's lens.
|
|
436
|
+
|
|
437
|
+
**Present as a matrix:**
|
|
438
|
+
|
|
439
|
+
| Approach | CFO | User | Security | Competitor | Support | Maintainer |
|
|
440
|
+
|---|---|---|---|---|---|---|
|
|
441
|
+
| Option A | verdict | verdict | verdict | verdict | verdict | verdict |
|
|
442
|
+
| Option B | verdict | verdict | verdict | verdict | verdict | verdict |
|
|
443
|
+
| Option C | verdict | verdict | verdict | verdict | verdict | verdict |
|
|
444
|
+
|
|
445
|
+
Highlight cells where a persona strongly objects (risk) or strongly endorses (opportunity).
|
|
446
|
+
|
|
447
|
+
---
|
|
448
|
+
|
|
449
|
+
## Module: PRE-MORTEM STRESS TEST
|
|
450
|
+
|
|
451
|
+
**Activates:** Automatically between Phase 2 (brainstorm complete) and Phase 3 (plan generation). Also activatable via "stress test this" or "what could go wrong?"
|
|
452
|
+
|
|
453
|
+
**Purpose:** Imagine the project has already failed, work backward to identify why. Research shows this increases failure prediction accuracy by 30%.
|
|
454
|
+
|
|
455
|
+
**Process — spawn 1 agent (subagent_type: general-purpose):**
|
|
456
|
+
|
|
457
|
+
```
|
|
458
|
+
You are conducting a Pre-Mortem Analysis. The project described below has ALREADY
|
|
459
|
+
FAILED SPECTACULARLY 6 months from now. Your job is to explain why.
|
|
460
|
+
|
|
461
|
+
PROJECT: {vision summary from context register}
|
|
462
|
+
APPROACH: {chosen architecture/pattern}
|
|
463
|
+
KEY DECISIONS: {prior decisions log}
|
|
464
|
+
|
|
465
|
+
Generate 10+ failure scenarios across these categories:
|
|
466
|
+
1. TECHNICAL: architecture breaks, scaling fails, integration nightmares
|
|
467
|
+
2. MARKET: no demand, wrong timing, competitor moves
|
|
468
|
+
3. EXECUTION: timeline slips, scope creep, key dependency fails
|
|
469
|
+
4. USER ADOPTION: confusing UX, wrong assumptions about behavior, trust issues
|
|
470
|
+
5. EXTERNAL: regulation changes, dependency deprecated, API pricing changes
|
|
471
|
+
|
|
472
|
+
For each failure:
|
|
473
|
+
- Likelihood: high/medium/low
|
|
474
|
+
- Impact: catastrophic/major/minor
|
|
475
|
+
- Leading indicator: what early signal would warn you?
|
|
476
|
+
- Mitigation: what would prevent or reduce this?
|
|
477
|
+
|
|
478
|
+
Rank by (Likelihood x Impact). Return top 10.
|
|
479
|
+
```
|
|
480
|
+
|
|
481
|
+
**Present to user:**
|
|
482
|
+
|
|
483
|
+
```
|
|
484
|
+
Pre-Mortem: Top 5 ways this could fail
|
|
485
|
+
|
|
486
|
+
1. [TECHNICAL] [failure] — Likelihood: high, Impact: major
|
|
487
|
+
Leading indicator: [signal]
|
|
488
|
+
Mitigation: [strategy]
|
|
489
|
+
|
|
490
|
+
2. ...
|
|
491
|
+
```
|
|
492
|
+
|
|
493
|
+
Ask user which mitigations to fold into the plan via AskUserQuestion (multiSelect: true). Selected mitigations become explicit tasks in Phase 3.
|
|
494
|
+
|
|
495
|
+
---
|
|
496
|
+
|
|
497
|
+
## Module: ANALOGICAL REASONING ENGINE
|
|
498
|
+
|
|
499
|
+
**Activates:** During BROAD depth (turns 1-2) when exploring the solution space. Also activatable via "find analogies" or "what's this like in other domains?"
|
|
500
|
+
|
|
501
|
+
**Purpose:** Find solutions in unrelated domains and transfer principles back. Research shows analogical transfer produces significantly more novel and useful ideas than conventional brainstorming.
|
|
502
|
+
|
|
503
|
+
**Process — spawn 1 agent:**
|
|
504
|
+
|
|
505
|
+
```
|
|
506
|
+
You are the Analogical Reasoning Engine. Your job is to find solutions to this
|
|
507
|
+
problem in COMPLETELY UNRELATED domains, then transfer the principles back.
|
|
508
|
+
|
|
509
|
+
PROBLEM: {user's problem}
|
|
510
|
+
ABSTRACT VERSION: {abstract the problem to its essence — e.g., "user retention" becomes
|
|
511
|
+
"maintaining engagement of voluntary participants"}
|
|
512
|
+
|
|
513
|
+
Step 1: Identify 4-5 analogous domains where this abstract problem has been solved:
|
|
514
|
+
- One from biology/nature
|
|
515
|
+
- One from gaming/entertainment
|
|
516
|
+
- One from a traditional industry (manufacturing, agriculture, logistics)
|
|
517
|
+
- One from psychology/behavioral science
|
|
518
|
+
- One from an unexpected domain (religion, sports, music, cooking)
|
|
519
|
+
|
|
520
|
+
Step 2: For each domain, extract the principle that solves the abstract problem.
|
|
521
|
+
Example: Biology -> "Create an environment where leaving is costly" (ecosystem lock-in)
|
|
522
|
+
|
|
523
|
+
Step 3: Transfer each principle back to the original problem domain.
|
|
524
|
+
Example: "What if our app had visible skill trees like an RPG?"
|
|
525
|
+
|
|
526
|
+
Step 4: Rate each transferred idea:
|
|
527
|
+
- Novelty: how different is this from obvious approaches? (1-5)
|
|
528
|
+
- Feasibility: how hard to implement? (1-5)
|
|
529
|
+
- Potential: if it works, how impactful? (1-5)
|
|
530
|
+
|
|
531
|
+
Return the top 3-5 transferred ideas with the full reasoning chain.
|
|
532
|
+
```
|
|
533
|
+
|
|
534
|
+
Present as numbered ideas with the analogy chain visible: Domain -> Principle -> Transferred Idea.
|
|
535
|
+
|
|
536
|
+
---
|
|
537
|
+
|
|
538
|
+
## Module: CONSTRAINT STORMS
|
|
539
|
+
|
|
540
|
+
**Activates:** When the brainstorm feels stuck or suggestions are too similar/conventional. Also activatable via "constrain this" or "force creativity."
|
|
541
|
+
|
|
542
|
+
**Purpose:** Impose artificial constraints to force creative solutions. Ideas that survive after removing constraints are genuinely novel.
|
|
543
|
+
|
|
544
|
+
**Process — spawn 3 parallel agents, each with a different constraint set:**
|
|
545
|
+
|
|
546
|
+
Constraint categories (pick 1 from each for each agent):
|
|
547
|
+
1. **RESOURCE**: "Zero budget", "One person", "No code", "Weekend project"
|
|
548
|
+
2. **TIME**: "Ship in 48 hours", "MVP in 1 hour", "Prototype today"
|
|
549
|
+
3. **TECHNOLOGY**: "No database", "No API calls", "Browser-only", "CLI-only", "No dependencies"
|
|
550
|
+
4. **AUDIENCE**: "For 80-year-olds", "For children", "For non-English speakers", "For offline users"
|
|
551
|
+
5. **INVERSION**: "User pays YOU", "It's hardware not software", "It's a game not a tool", "It's temporary not permanent"
|
|
552
|
+
|
|
553
|
+
Each agent generates 3-5 solutions under their constraint set.
|
|
554
|
+
|
|
555
|
+
**Present to user:**
|
|
556
|
+
|
|
557
|
+
```
|
|
558
|
+
Constraint Storm Results:
|
|
559
|
+
|
|
560
|
+
Under "zero budget + browser-only + for offline users":
|
|
561
|
+
1. [solution] — survives without constraint? YES/NO
|
|
562
|
+
2. [solution] — survives without constraint? YES/NO
|
|
563
|
+
|
|
564
|
+
Under "ship in 48 hours + no dependencies + for children":
|
|
565
|
+
1. [solution] — survives without constraint? YES/NO
|
|
566
|
+
...
|
|
567
|
+
|
|
568
|
+
Surviving ideas (viable even without constraints):
|
|
569
|
+
- [idea 1] — born from [constraint], core insight: [what makes it good]
|
|
570
|
+
- [idea 2] — ...
|
|
571
|
+
```
|
|
572
|
+
|
|
573
|
+
The surviving ideas are the gold. Present them as additional suggestions in the next synthesis.
|
|
574
|
+
|
|
575
|
+
---
|
|
576
|
+
|
|
577
|
+
## Module: REVERSE BRAINSTORM
|
|
578
|
+
|
|
579
|
+
**Activates:** When suggestions cluster in conventional categories (AI fixation bias detected). Also activatable via "reverse brainstorm" or "break my thinking."
|
|
580
|
+
|
|
581
|
+
**Purpose:** Generate deliberately terrible ideas, then invert them. Breaks fixation bias.
|
|
582
|
+
|
|
583
|
+
**Process — inline (no agent needed):**
|
|
584
|
+
|
|
585
|
+
1. Generate 5-7 ways to make the product/feature WORSE:
|
|
586
|
+
- "Make onboarding take 45 minutes"
|
|
587
|
+
- "Require a fax machine to sign up"
|
|
588
|
+
- "Send 50 emails a day"
|
|
589
|
+
|
|
590
|
+
2. Invert each:
|
|
591
|
+
- "Onboarding in under 45 seconds"
|
|
592
|
+
- "Sign up with zero forms — just a phone number"
|
|
593
|
+
- "Zero emails — everything in-app, user-initiated"
|
|
594
|
+
|
|
595
|
+
3. Evaluate inversions as genuine proposals.
|
|
596
|
+
|
|
597
|
+
Present the inversions that are genuinely viable as additional suggestions.
|
|
598
|
+
|
|
599
|
+
---
|
|
600
|
+
|
|
601
|
+
## Module: WEIGHTED DECISION MATRIX
|
|
602
|
+
|
|
603
|
+
**Activates:** When converging on a final approach from 3+ options. Also activatable via "score these" or "help me decide."
|
|
604
|
+
|
|
605
|
+
**Purpose:** Replace subjective "which do you like?" with quantified evaluation.
|
|
606
|
+
|
|
607
|
+
**Process:**
|
|
608
|
+
|
|
609
|
+
1. **Define criteria** (suggest defaults, let user customize via AskUserQuestion):
|
|
610
|
+
- Impact (1-5)
|
|
611
|
+
- Feasibility (1-5)
|
|
612
|
+
- Time to implement (1-5)
|
|
613
|
+
- Strategic alignment (1-5)
|
|
614
|
+
- Risk level (1-5, inverted — low risk = high score)
|
|
615
|
+
|
|
616
|
+
2. **Assign weights** (ask user via AskUserQuestion):
|
|
617
|
+
- Impact: ?x weight (default 3x)
|
|
618
|
+
- Feasibility: ?x weight (default 2x)
|
|
619
|
+
- Time: ?x weight (default 1x)
|
|
620
|
+
- etc.
|
|
621
|
+
|
|
622
|
+
3. **Score each option** against each criterion with rationale
|
|
623
|
+
|
|
624
|
+
4. **Calculate weighted totals**, rank
|
|
625
|
+
|
|
626
|
+
5. **Present as table:**
|
|
627
|
+
|
|
628
|
+
| Option | Impact (3x) | Feasibility (2x) | Time (1x) | Alignment (2x) | Risk (1x) | **Total** |
|
|
629
|
+
|---|---|---|---|---|---|---|
|
|
630
|
+
| A | 4 (12) | 3 (6) | 5 (5) | 4 (8) | 3 (3) | **34** |
|
|
631
|
+
| B | 5 (15) | 2 (4) | 2 (2) | 5 (10) | 2 (2) | **33** |
|
|
632
|
+
|
|
633
|
+
6. **Sensitivity analysis:** "If you cared more about speed than impact, option B drops to #3 and option C rises to #1."
|
|
634
|
+
|
|
635
|
+
---
|
|
636
|
+
|
|
637
|
+
## Module: DIVERGE/CONVERGE PHASE CONTROLLER
|
|
638
|
+
|
|
639
|
+
**Activates:** Automatically manages the brainstorm's creative phases. Not user-invokable directly.
|
|
640
|
+
|
|
641
|
+
**Purpose:** Prevent premature convergence. Research shows AI tools evaluate ideas too early, killing creative potential.
|
|
642
|
+
|
|
643
|
+
**Rules:**
|
|
644
|
+
|
|
645
|
+
During **DIVERGE phases** (turns 1-3, and whenever exploring new sub-problems):
|
|
646
|
+
- Suppress evaluation language ("best", "recommended", "should")
|
|
647
|
+
- Push for quantity: "What ELSE could this look like?"
|
|
648
|
+
- Activate Analogical Reasoning, Constraint Storms, Reverse Brainstorm
|
|
649
|
+
- DO NOT label anything as RECOMMENDED
|
|
650
|
+
- Present ALL options as equally valid for now
|
|
651
|
+
|
|
652
|
+
During **CONVERGE phases** (turns 4+ when the user signals preference, and before Phase 3):
|
|
653
|
+
- Activate Weighted Decision Matrix, Stakeholder Simulation
|
|
654
|
+
- Label recommendations
|
|
655
|
+
- Compare and rank
|
|
656
|
+
- Cut scope aggressively (YAGNI)
|
|
657
|
+
|
|
658
|
+
**Announce transitions:** "We've explored the space — shifting to evaluation mode to narrow down."
|
|
659
|
+
|
|
660
|
+
The user can override: "keep exploring" → back to DIVERGE. "help me choose" → switch to CONVERGE.
|
|
661
|
+
|
|
662
|
+
---
|
|
663
|
+
|
|
664
|
+
## Module: VISUAL COMPANION
|
|
665
|
+
|
|
666
|
+
**Activates:** When the brainstorm involves visual decisions — UI layouts, information architecture, workflow diagrams, comparison matrices.
|
|
667
|
+
|
|
668
|
+
**Purpose:** Show, don't tell. Present mockups and diagrams in the browser alongside terminal conversation.
|
|
669
|
+
|
|
670
|
+
**Process:**
|
|
671
|
+
|
|
672
|
+
For each visual decision point, decide: does this need a visual? If the user needs to compare layouts, see a workflow, or understand spatial relationships — yes.
|
|
673
|
+
|
|
674
|
+
Use the `preview` field in AskUserQuestion for simple comparisons (code layouts, file structures, config formats).
|
|
675
|
+
|
|
676
|
+
For complex visuals (UI mockups, architecture diagrams, flow charts), use Mermaid syntax in the response and note that the user can paste it into a renderer if needed. Format:
|
|
677
|
+
|
|
678
|
+
```mermaid
|
|
679
|
+
graph TD
|
|
680
|
+
A[User Request] --> B{Route}
|
|
681
|
+
B --> C[Brainstorm]
|
|
682
|
+
B --> D[Discuss]
|
|
683
|
+
B --> E[Quick Mode]
|
|
684
|
+
```
|
|
685
|
+
|
|
686
|
+
---
|
|
687
|
+
|
|
688
|
+
## Module: SPEC SELF-REVIEW
|
|
689
|
+
|
|
690
|
+
**Activates:** Automatically after Phase 2 summary is approved, before Phase 3 plan generation begins.
|
|
691
|
+
|
|
692
|
+
**Source:** Superpowers spec-document-reviewer
|
|
693
|
+
|
|
694
|
+
**Purpose:** Catch issues in the accumulated decisions before they become plan defects.
|
|
695
|
+
|
|
696
|
+
**Checklist (run through mentally, fix issues inline):**
|
|
697
|
+
|
|
698
|
+
1. **Placeholder scan** — Are there any TBD, TODO, "we'll figure this out later" items? Surface them now.
|
|
699
|
+
2. **Internal consistency** — Do any decisions contradict each other? (e.g., "real-time" in one place, "batch" in another)
|
|
700
|
+
3. **Scope check** — Is anything included that wasn't discussed? Is anything discussed but missing?
|
|
701
|
+
4. **Ambiguity check** — Could any decision be interpreted two different ways by an implementer?
|
|
702
|
+
5. **Completeness** — Are all gray areas resolved? Any feature-type-specific gaps (see Gray Area Detection)?
|
|
703
|
+
6. **YAGNI sweep** — One final pass: can anything be cut without losing core value?
|
|
704
|
+
|
|
705
|
+
**Present findings to user:** "Before I generate the plan, I found [N] issues in our accumulated decisions: [list]. Let me resolve these."
|
|
706
|
+
|
|
707
|
+
Fix issues inline. If any require user input, ask via AskUserQuestion before proceeding.
|
|
708
|
+
|
|
709
|
+
---
|
|
710
|
+
|
|
711
|
+
# SCOPE GUARDRAIL
|
|
712
|
+
|
|
713
|
+
**Source:** GSD discuss-phase
|
|
714
|
+
|
|
715
|
+
The brainstorm's scope, once established in Phase 1, is FIXED in terms of WHAT we're building. Phase 2 discussions clarify HOW to implement what's scoped, never WHETHER to add new capabilities.
|
|
716
|
+
|
|
717
|
+
When the user raises something that expands scope during Phase 2:
|
|
718
|
+
1. Acknowledge it's a good idea
|
|
719
|
+
2. Add it to a **Deferred Ideas** list in the context register
|
|
720
|
+
3. Redirect: "That's worth building, but it's scope expansion. Let's nail the core first and revisit after."
|
|
721
|
+
4. Continue with the current scope
|
|
722
|
+
|
|
723
|
+
The Deferred Ideas list is included in the Phase 3 plan as a "Future Work" section.
|
|
724
|
+
|
|
725
|
+
Exception: if the user explicitly says "I want to change the scope" or "add this to v1", honor it and update the context register.
|
|
726
|
+
|
|
727
|
+
---
|
|
728
|
+
|
|
729
|
+
# When to Suggest Phase 3
|
|
730
|
+
|
|
731
|
+
**Depth is dynamic, not counted.** Don't track a minimum question number. Instead, measure whether your research is still producing new, useful information. The brainstorm is deep enough when research sprints stop surfacing unknowns — not when you've hit some arbitrary question count. A simple CLI wrapper might genuinely need 3-4 questions. A distributed system with multiple integration points might need 15. Let the research tell you.
|
|
732
|
+
|
|
733
|
+
**How to judge depth: the "new information" test.** After each research sprint, ask yourself: did this sprint surface anything the user hasn't already addressed or that I couldn't have inferred from prior answers? If yes, there's more to explore — formulate a question from the new finding. If two consecutive sprints return the same repos, same patterns, and no new unknowns, the research is saturated for this idea.
|
|
734
|
+
|
|
735
|
+
**The key behavior change: when your question queue empties, don't offer to wrap up — run another research sprint first.** The sprint might surface new angles (failure modes, deployment concerns, maintenance patterns, edge cases from similar projects) that generate fresh questions. Only when the sprint comes back dry should you consider the brainstorm naturally complete.
|
|
736
|
+
|
|
737
|
+
**Never proactively suggest Phase 3.** Don't say "Ready to turn this into an implementation plan?" or "Want to move to planning?" or any variation. Instead, when research is genuinely saturated, just ask your next research-driven question. If there truly isn't one, present your latest findings and observations — the user will tell you when they're ready to move on. The user controls the pace, not you.
|
|
738
|
+
|
|
739
|
+
**The one exception:** If research has been genuinely dry across 2+ consecutive sprints AND you have no new questions, you may say something like: "I've dug into [X, Y, Z areas] and the research is converging — happy to keep exploring if there's anything else on your mind, or we can shape this up." This is a status update, not a push. Say it once. If the user asks anything, go back to the research loop.
|
|
740
|
+
|
|
741
|
+
**Before Phase 3, scan your context register.** Every question you've asked should have an answer recorded. If any are unanswered, ask them ONE AT A TIME in subsequent turns before Phase 3. Do NOT re-ask questions the user already answered — even if their answer was embedded in a longer message or phrased differently than expected.
|
|
742
|
+
|
|
743
|
+
**HARD GATE: The user must explicitly say they're ready.** When they do, activate the following sequence:
|
|
744
|
+
|
|
745
|
+
1. **Spec Self-Review** module runs
|
|
746
|
+
2. **Pre-Mortem Stress Test** module runs
|
|
747
|
+
3. Present combined summary:
|
|
748
|
+
|
|
749
|
+
```
|
|
750
|
+
Here's what I think we've landed on:
|
|
751
|
+
|
|
752
|
+
**Building:** [one sentence]
|
|
753
|
+
**Core approach:** [recommended architecture/pattern]
|
|
754
|
+
**Key decisions:** [2-3 bullets from prior decisions log]
|
|
755
|
+
**Scope for v1:** [what's in, what's deferred]
|
|
756
|
+
**Top risks (from pre-mortem):** [2-3 bullets with mitigations]
|
|
757
|
+
**Canonical references:** [links to key specs, docs, or ADRs that implementers must read]
|
|
758
|
+
```
|
|
759
|
+
|
|
760
|
+
Then proceed to Phase 3. If they raise corrections, address them before proceeding.
|
|
761
|
+
|
|
762
|
+
---
|
|
763
|
+
|
|
764
|
+
# PHASE 3: PLAN GENERATION
|
|
765
|
+
|
|
766
|
+
Read `references/plan-template.md` for the full template and rules. Present the plan incrementally (vision -> tasks -> agents/waves), getting approval at each step.
|
|
767
|
+
|
|
768
|
+
## Plan Quality Verification Loop
|
|
769
|
+
|
|
770
|
+
**Source:** GSD plan-checker
|
|
771
|
+
|
|
772
|
+
After generating the plan, spawn a **Plan Checker** agent (subagent_type: general-purpose):
|
|
773
|
+
|
|
774
|
+
```
|
|
775
|
+
You are the Plan Quality Reviewer. Review the following implementation plan against
|
|
776
|
+
the brainstorm decisions and spec.
|
|
777
|
+
|
|
778
|
+
PLAN: {full plan text}
|
|
779
|
+
SPEC DECISIONS: {prior decisions log + context register}
|
|
780
|
+
PROJECT CONTEXT: {Phase 0 repo scan}
|
|
781
|
+
|
|
782
|
+
Check:
|
|
783
|
+
1. SPEC COVERAGE — Does every decision from the brainstorm appear in a task? Flag gaps.
|
|
784
|
+
2. PLACEHOLDER SCAN — Any vague instructions, TBDs, or "figure this out" in tasks? Flag all.
|
|
785
|
+
3. TASK DECOMPOSITION — Is every task completable in one agent session? Flag too-large tasks.
|
|
786
|
+
4. BUILDABILITY — Can tasks be executed in the stated order? Flag dependency issues.
|
|
787
|
+
5. NYQUIST VALIDATION — Does every task have testable acceptance criteria with an automated verify command?
|
|
788
|
+
6. WIRING COMPLETENESS — Are all exports/imports/routes specified? Flag orphaned components.
|
|
789
|
+
7. YAGNI — Are any tasks not traceable to a brainstorm decision? Flag for removal.
|
|
790
|
+
8. EXECUTION FITNESS — Is this the right architectural pattern for how ftm-executor will run it? Check:
|
|
791
|
+
- Shared path conflicts: Do any tasks mutate files outside the repo (global paths like ~/.claude/)? If so, they MUST NOT run in parallel worktree isolation — flag missing shared path constraints.
|
|
792
|
+
- Context budget: Is the plan small enough for a single executor session, or should it be split into multiple runs with review checkpoints? Plans with 7+ tasks or 3+ waves should recommend a split.
|
|
793
|
+
- Wave sizing: Are parallel waves actually safe to parallelize? Two tasks in the same wave touching the same file or global path is a blocker.
|
|
794
|
+
- Agent isolation: Can each task's agent work independently, or do tasks have implicit shared state not captured in the dependency graph?
|
|
795
|
+
|
|
796
|
+
Return: list of issues by category, severity (blocker/warning/nit), and suggested fix.
|
|
797
|
+
```
|
|
798
|
+
|
|
799
|
+
If the checker finds blockers, fix them and re-check. Up to 3 iterations. After 3, present remaining issues to the user.
|
|
800
|
+
|
|
801
|
+
## Discovery Levels
|
|
802
|
+
|
|
803
|
+
**Source:** GSD plan-phase
|
|
804
|
+
|
|
805
|
+
When generating tasks, assess each task's discovery level:
|
|
806
|
+
|
|
807
|
+
- **Level 0 (Skip):** Pure internal work, existing patterns. No research needed.
|
|
808
|
+
- **Level 1 (Quick Verify):** Single known library, confirm syntax. 2-5 min research.
|
|
809
|
+
- **Level 2 (Standard):** Choosing between options, new integration. 15-30 min research.
|
|
810
|
+
- **Level 3 (Deep Dive):** Architectural decisions, novel problems. Extended research.
|
|
811
|
+
|
|
812
|
+
Tag each task with its discovery level. Level 2+ tasks get research hints from the brainstorm's findings.
|
|
813
|
+
|
|
814
|
+
---
|
|
815
|
+
|
|
816
|
+
# COMPLEXITY MODES
|
|
817
|
+
|
|
818
|
+
**Source:** GSD quick/fast/full routing
|
|
819
|
+
|
|
820
|
+
The skill auto-detects complexity but can be overridden.
|
|
821
|
+
|
|
822
|
+
## Quick Mode
|
|
823
|
+
|
|
824
|
+
**Detects:** Simple, well-understood tasks. User says "quick brainstorm" or the idea is clearly scoped.
|
|
825
|
+
|
|
826
|
+
- 3 agents instead of 7 (Web, GitHub, Competitive only)
|
|
827
|
+
- 2-3 turns max before suggesting Phase 3
|
|
828
|
+
- Skip Assumption Audit, Stakeholder Sim, Constraint Storms
|
|
829
|
+
- Keep: Gray Area Detection, Pre-Mortem (abbreviated)
|
|
830
|
+
|
|
831
|
+
## Standard Mode (default)
|
|
832
|
+
|
|
833
|
+
- Full 7 agents + synthesizer
|
|
834
|
+
- Unlimited turns
|
|
835
|
+
- All modules available, activated by context
|
|
836
|
+
- Full Pre-Mortem and Spec Self-Review before Phase 3
|
|
837
|
+
|
|
838
|
+
## Deep Mode
|
|
839
|
+
|
|
840
|
+
**Detects:** Complex, multi-system, high-stakes projects. User says "deep brainstorm" or the idea spans multiple domains.
|
|
841
|
+
|
|
842
|
+
- Full 7 agents + synthesizer
|
|
843
|
+
- Unlimited turns
|
|
844
|
+
- ALL modules activate at least once
|
|
845
|
+
- Assumption Audit runs on turns 2-3
|
|
846
|
+
- Stakeholder Simulation runs when 3+ approaches exist
|
|
847
|
+
- Constraint Storms run at least once
|
|
848
|
+
- Weighted Decision Matrix runs before convergence
|
|
849
|
+
- Analogical Reasoning runs during BROAD phase
|
|
850
|
+
- Double Pre-Mortem: once mid-brainstorm, once before Phase 3
|
|
851
|
+
- Plan Verification Loop always runs full 3 iterations
|
|
852
|
+
|
|
853
|
+
---
|
|
854
|
+
|
|
855
|
+
## Relationship to superpowers:brainstorming
|
|
856
|
+
|
|
857
|
+
**ftm-brainstorm absorbs superpowers:brainstorming.** This skill handles ALL brainstorming:
|
|
858
|
+
- Idea exploration with live research (formerly ftm-brainstorm only)
|
|
859
|
+
- Design/spec work with gray area detection (formerly superpowers:brainstorming)
|
|
860
|
+
- Discuss mode for known specs (formerly GSD discuss-phase)
|
|
861
|
+
- Quick mode for simple tasks (formerly GSD quick)
|
|
862
|
+
|
|
863
|
+
If user invokes superpowers:brainstorming, redirect here. If user already completed a brainstorm, point to ftm-executor.
|
|
864
|
+
|
|
865
|
+
---
|
|
866
|
+
|
|
867
|
+
## Context Compression
|
|
868
|
+
|
|
869
|
+
After turn 5 in a brainstorm session, earlier turns start consuming significant context. Apply compression to maintain quality in later turns.
|
|
870
|
+
|
|
871
|
+
### Trigger
|
|
872
|
+
|
|
873
|
+
- Turns 1-5: No compression. Full fidelity.
|
|
874
|
+
- Turn 6+: Compress turns 1 through (current - 3). Keep the 3 most recent turns at full fidelity.
|
|
875
|
+
|
|
876
|
+
### Compression Strategy
|
|
877
|
+
|
|
878
|
+
For each compressed turn, replace the full content with a summary:
|
|
879
|
+
|
|
880
|
+
```
|
|
881
|
+
[Turn N summary]
|
|
882
|
+
- Topic: [what was discussed]
|
|
883
|
+
- Key decisions: [bullet list of decisions made]
|
|
884
|
+
- Open questions resolved: [what was answered]
|
|
885
|
+
- Artifacts produced: [any specs, diagrams, code snippets referenced]
|
|
886
|
+
- Module activations: [which creativity modules ran and their output]
|
|
887
|
+
```
|
|
888
|
+
|
|
889
|
+
### What to Preserve in Summaries
|
|
890
|
+
|
|
891
|
+
- Decisions and their rationale (WHY something was decided)
|
|
892
|
+
- Constraints discovered
|
|
893
|
+
- Requirements confirmed by the user
|
|
894
|
+
- Technical choices made
|
|
895
|
+
- Pre-mortem mitigations selected
|
|
896
|
+
- Assumption audit results
|
|
897
|
+
- Stakeholder simulation verdicts
|
|
898
|
+
|
|
899
|
+
### What to Drop
|
|
900
|
+
|
|
901
|
+
- Exploratory tangents that were abandoned
|
|
902
|
+
- Research citations already synthesized
|
|
903
|
+
- Verbose explanations of options not chosen
|
|
904
|
+
- Repeated context that's already captured in later turns
|
|
905
|
+
- Full agent outputs (keep synthesis only)
|
|
906
|
+
|
|
907
|
+
### Implementation
|
|
908
|
+
|
|
909
|
+
This is implemented at the skill level, not via hooks. When presenting a response at turn 6+:
|
|
910
|
+
1. Mentally compress old turns using the strategy above
|
|
911
|
+
2. Reference compressed summaries when needed
|
|
912
|
+
3. Keep recent turns verbatim for conversational continuity
|
|
913
|
+
4. If the user references something from a compressed turn, expand it on demand
|
|
914
|
+
|
|
915
|
+
---
|
|
916
|
+
|
|
917
|
+
## Session State (for ftm-pause/resume)
|
|
918
|
+
|
|
919
|
+
When paused, the following state must be capturable so ftm-resume can pick up exactly where you left off:
|
|
920
|
+
|
|
921
|
+
- **Phase tracking**: current phase (0/1/2/3), path (A/B/Discuss), turn number, research depth level, complexity mode (quick/standard/deep)
|
|
922
|
+
- **Phase 0**: full repo scan results (or "skipped — no git repo")
|
|
923
|
+
- **Phase 1**: original idea (verbatim), brain dump extraction if Path B, all user answers per round
|
|
924
|
+
- **Phase 2**: every completed turn's suggestions with evidence/URLs, every challenge and response, every question and answer, accumulated decisions, the current direction, context register contents, prior decisions log, deferred ideas list, diverge/converge phase state
|
|
925
|
+
- **Module state**: assumption audit results, stakeholder sim matrix, pre-mortem results, constraint storm survivors, decision matrix scores
|
|
926
|
+
- **Phase 3**: which sections presented/approved, plan content so far, plan file path if saved, plan checker iteration count
|
|
927
|
+
|
|
928
|
+
This state is what ftm-pause captures and ftm-resume restores. Keep it current as you go.
|
|
929
|
+
|
|
930
|
+
## Blackboard Write
|
|
931
|
+
|
|
932
|
+
After completing, update:
|
|
933
|
+
1. `~/.claude/ftm-state/blackboard/context.json`:
|
|
934
|
+
- Set current_task status to "complete"
|
|
935
|
+
- Append decision summary to recent_decisions (cap at 10)
|
|
936
|
+
- Update session_metadata.skills_invoked and last_updated
|
|
937
|
+
2. Write experience file to `~/.claude/ftm-state/blackboard/experiences/YYYY-MM-DD_task-slug.json`:
|
|
938
|
+
- task_type: "feature" or "investigation"
|
|
939
|
+
- feature_type: detected type (UI, API, etc.)
|
|
940
|
+
- architectural_direction: the approach chosen
|
|
941
|
+
- research_quality: how useful the research sprints were (high/medium/low)
|
|
942
|
+
- turns_to_resolution: how many Phase 2 turns before Phase 3
|
|
943
|
+
- modules_activated: which creativity modules ran and their impact
|
|
944
|
+
- assumption_audit_results: crackable assumptions found
|
|
945
|
+
- pre_mortem_top_risks: top 3 risks and whether mitigations were adopted
|
|
946
|
+
- tags: keywords for future matching
|
|
947
|
+
3. Update `experiences/index.json` with the new entry
|
|
948
|
+
4. Emit `plan_generated` with `{ plan_path, plan_title, task_count, wave_count }` (if Phase 3 completed)
|
|
949
|
+
5. Emit `task_completed` with `{ task_title, plan_path, duration_ms }`
|
|
950
|
+
|
|
951
|
+
## Requirements
|
|
952
|
+
|
|
953
|
+
- config: `~/.claude/ftm-config.yml` | optional | model profile for planning agents
|
|
954
|
+
- reference: `references/agent-prompts.md` | required | research agent prompt templates (7 agents + synthesizer)
|
|
955
|
+
- reference: `references/plan-template.md` | required | plan document generation template
|
|
956
|
+
- reference: `~/.claude/ftm-state/blackboard/context.json` | optional | session state and active constraints
|
|
957
|
+
- reference: `~/.claude/ftm-state/blackboard/experiences/index.json` | optional | past brainstorm lessons
|
|
958
|
+
- reference: `~/.claude/ftm-state/blackboard/patterns.json` | optional | execution and user behavior patterns
|
|
959
|
+
|
|
960
|
+
## Risk
|
|
961
|
+
|
|
962
|
+
- level: low_write
|
|
963
|
+
- scope: writes plan documents to ~/.claude/plans/; writes blackboard context and experience files; does not modify project source code
|
|
964
|
+
- rollback: delete generated plan file; blackboard writes can be reverted by editing JSON files
|
|
965
|
+
|
|
966
|
+
## Approval Gates
|
|
967
|
+
|
|
968
|
+
- trigger: Phase 3 plan generation ready | action: run Spec Self-Review + Pre-Mortem, present "Here's what I think we've landed on" summary, wait for explicit user approval
|
|
969
|
+
- trigger: plan document generated | action: present plan incrementally (vision -> tasks -> agents/waves), get approval at each step, run Plan Checker before final save
|
|
970
|
+
- trigger: research returns thin results on all agents | action: note research gaps, present fewer suggestions, do not fabricate citations
|
|
971
|
+
- trigger: module activation | action: announce which module is activating and why
|
|
972
|
+
- complexity_routing: micro -> auto | small -> auto | medium -> plan_first | large -> plan_first | xl -> always_ask
|
|
973
|
+
|
|
974
|
+
## Fallbacks
|
|
975
|
+
|
|
976
|
+
- condition: ftm-researcher not available | action: dispatch 7 direct parallel research agents using built-in prompts from references/agent-prompts.md + synthesizer
|
|
977
|
+
- condition: no git repo detected in Phase 0 | action: skip repo scan, ask about tech stack during intake
|
|
978
|
+
- condition: blackboard missing or empty | action: proceed without experience-informed shortcuts, rely on direct analysis
|
|
979
|
+
- condition: ftm-config.yml missing | action: use session default model for all agents
|
|
980
|
+
- condition: module agent fails | action: skip module, note gap, continue with available data
|
|
981
|
+
|
|
982
|
+
## Capabilities
|
|
983
|
+
|
|
984
|
+
- mcp: `WebSearch` | optional | web research agents use for blog posts and case studies
|
|
985
|
+
- mcp: `WebFetch` | optional | GitHub exploration and competitive analysis
|
|
986
|
+
- mcp: `sequential-thinking` | optional | complex trade-off analysis during synthesis
|
|
987
|
+
- mcp: `playwright` | optional | visual companion browser rendering
|
|
988
|
+
- env: none required
|
|
989
|
+
|
|
990
|
+
## Event Payloads
|
|
991
|
+
|
|
992
|
+
### plan_generated
|
|
993
|
+
- skill: string — "ftm-brainstorm"
|
|
994
|
+
- plan_path: string — absolute path to generated plan file
|
|
995
|
+
- plan_title: string — human-readable plan title
|
|
996
|
+
- task_count: number — total tasks in the plan
|
|
997
|
+
- wave_count: number — number of parallel execution waves
|
|
998
|
+
|
|
999
|
+
### task_completed
|
|
1000
|
+
- skill: string — "ftm-brainstorm"
|
|
1001
|
+
- task_title: string — title of the brainstorm topic
|
|
1002
|
+
- plan_path: string | null — path to generated plan if Phase 3 completed
|
|
1003
|
+
- duration_ms: number — total session duration
|