@thierrynakoa/fire-flow 10.0.0 → 12.2.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (94) hide show
  1. package/.claude-plugin/plugin.json +8 -8
  2. package/ARCHITECTURE-DIAGRAM.md +7 -4
  3. package/COMMAND-REFERENCE.md +33 -13
  4. package/DOMINION-FLOW-OVERVIEW.md +581 -421
  5. package/QUICK-START.md +3 -3
  6. package/README.md +101 -44
  7. package/TROUBLESHOOTING.md +264 -264
  8. package/agents/fire-executor.md +200 -116
  9. package/agents/fire-fact-checker.md +276 -276
  10. package/agents/fire-phoenix-analyst.md +394 -0
  11. package/agents/fire-planner.md +145 -53
  12. package/agents/fire-project-researcher.md +155 -155
  13. package/agents/fire-research-synthesizer.md +166 -166
  14. package/agents/fire-researcher.md +144 -59
  15. package/agents/fire-roadmapper.md +215 -203
  16. package/agents/fire-verifier.md +247 -65
  17. package/agents/fire-vision-architect.md +381 -0
  18. package/commands/fire-0-orient.md +476 -476
  19. package/commands/fire-1a-new.md +216 -0
  20. package/commands/fire-1b-research.md +210 -0
  21. package/commands/fire-1c-setup.md +254 -0
  22. package/commands/{fire-1a-discuss.md → fire-1d-discuss.md} +35 -7
  23. package/commands/fire-3-execute.md +55 -2
  24. package/commands/fire-4-verify.md +61 -0
  25. package/commands/fire-5-handoff.md +2 -2
  26. package/commands/fire-6-resume.md +37 -2
  27. package/commands/fire-add-new-skill.md +2 -2
  28. package/commands/fire-autonomous.md +20 -3
  29. package/commands/fire-brainstorm.md +1 -1
  30. package/commands/fire-complete-milestone.md +2 -2
  31. package/commands/fire-cost.md +183 -0
  32. package/commands/fire-dashboard.md +2 -2
  33. package/commands/fire-debug.md +663 -663
  34. package/commands/fire-loop-resume.md +2 -2
  35. package/commands/fire-loop-stop.md +1 -1
  36. package/commands/fire-loop.md +1168 -1168
  37. package/commands/fire-map-codebase.md +3 -3
  38. package/commands/fire-new-milestone.md +356 -356
  39. package/commands/fire-phoenix.md +603 -0
  40. package/commands/fire-reflect.md +235 -235
  41. package/commands/fire-research.md +246 -246
  42. package/commands/fire-search.md +1 -1
  43. package/commands/fire-skills-diff.md +3 -3
  44. package/commands/fire-skills-history.md +3 -3
  45. package/commands/fire-skills-rollback.md +7 -7
  46. package/commands/fire-skills-sync.md +5 -5
  47. package/commands/fire-test.md +9 -9
  48. package/commands/fire-todos.md +1 -1
  49. package/commands/fire-update.md +5 -5
  50. package/hooks/hooks.json +16 -16
  51. package/hooks/run-hook.sh +8 -8
  52. package/hooks/run-session-end.sh +7 -7
  53. package/hooks/session-end.sh +90 -90
  54. package/hooks/session-start.sh +1 -1
  55. package/package.json +4 -2
  56. package/plugin.json +7 -7
  57. package/references/metrics-and-trends.md +1 -1
  58. package/skills-library/SKILLS-INDEX.md +588 -588
  59. package/skills-library/_general/methodology/AUTONOMOUS_ORCHESTRATION.md +182 -0
  60. package/skills-library/_general/methodology/BACKWARD_PLANNING_INTERVIEW.md +307 -0
  61. package/skills-library/_general/methodology/CIRCUIT_BREAKER_INTELLIGENCE.md +163 -0
  62. package/skills-library/_general/methodology/CONTEXT_ROTATION.md +151 -0
  63. package/skills-library/_general/methodology/DEAD_ENDS_SHELF.md +188 -0
  64. package/skills-library/_general/methodology/DESIGN_PHILOSOPHY_ENFORCEMENT.md +152 -0
  65. package/skills-library/_general/methodology/INTERNAL_CONSISTENCY_AUDIT.md +212 -0
  66. package/skills-library/_general/methodology/LIVE_BREADCRUMB_PROTOCOL.md +242 -0
  67. package/skills-library/_general/methodology/PHOENIX_REBUILD_METHODOLOGY.md +251 -0
  68. package/skills-library/_general/methodology/QUALITY_GATES_AND_VERIFICATION.md +157 -0
  69. package/skills-library/_general/methodology/RELIABILITY_PREDICTION.md +104 -0
  70. package/skills-library/_general/methodology/REQUIREMENTS_DECOMPOSITION.md +155 -0
  71. package/skills-library/_general/methodology/SELF_TESTING_FEEDBACK_LOOP.md +143 -0
  72. package/skills-library/_general/methodology/STACK_COMPATIBILITY_MATRIX.md +178 -0
  73. package/skills-library/_general/methodology/TIERED_CONTEXT_ARCHITECTURE.md +118 -0
  74. package/skills-library/_general/methodology/ZERO_FRICTION_CLI_SETUP.md +312 -0
  75. package/skills-library/_general/methodology/autonomous-multi-phase-build.md +133 -0
  76. package/skills-library/_general/methodology/claude-md-archival.md +280 -0
  77. package/skills-library/_general/methodology/debug-swarm-researcher-escape-hatch.md +240 -240
  78. package/skills-library/_general/methodology/git-worktrees-parallel.md +232 -0
  79. package/skills-library/_general/methodology/llm-judge-memory-crud.md +241 -0
  80. package/skills-library/_general/methodology/multi-project-autonomous-build.md +360 -0
  81. package/skills-library/_general/methodology/shell-autonomous-loop-fixplan.md +238 -238
  82. package/skills-library/_general/patterns-standards/GOF_DESIGN_PATTERNS_FOR_AI_AGENTS.md +358 -0
  83. package/skills-library/methodology/BREATH_BASED_PARALLEL_EXECUTION.md +1 -1
  84. package/skills-library/methodology/RESEARCH_BACKED_WORKFLOW_UPGRADE.md +1 -1
  85. package/skills-library/methodology/SABBATH_REST_PATTERN.md +1 -1
  86. package/templates/ASSUMPTIONS.md +1 -1
  87. package/templates/BLOCKERS.md +1 -1
  88. package/templates/DECISION_LOG.md +1 -1
  89. package/templates/phase-prompt.md +1 -1
  90. package/templates/phoenix-comparison.md +80 -0
  91. package/version.json +2 -2
  92. package/workflows/handoff-session.md +1 -1
  93. package/workflows/new-project.md +2 -2
  94. package/commands/fire-1-new.md +0 -281
@@ -0,0 +1,360 @@
1
+ ---
2
+ name: Multi-Project Autonomous Build
3
+ category: methodology
4
+ version: 1.0.0
5
+ contributed: 2026-02-24
6
+ tags: [autonomous, multi-project, subagents, methodology, parallel-execution, monitoring, config-first]
7
+ difficulty: hard
8
+ usage_count: 0
9
+ success_rate: 100
10
+ ---
11
+
12
+ # Multi-Project Autonomous Build
13
+
14
+ ## Problem
15
+
16
+ You need to build 3+ independent projects simultaneously without human bottlenecks. Each project has its own repo, stack, and requirements, but they may share infrastructure (dashboards monitoring services, services exposing state to dashboards). Sequential building wastes time. Asking for approval between every step wastes attention. You need an autonomous workflow that plans, executes, verifies, and advances across all projects with minimal human intervention.
17
+
18
+ ## Solution Pattern
19
+
20
+ **Autonomous execution with subagent parallelism, status sidecars for monitoring, config-first development**
21
+
22
+ Define all projects in a single plan document. Verify they are independent (no cross-repo file edits). Execute each project through a plan-execute-verify-advance loop using `/fire-autonomous`. Use status sidecars (lightweight HTTP endpoints) on each service so a central dashboard can monitor everything. Start every project with config-first development: define the full config schema with defaults before writing any feature code.
23
+
24
+ ## Architecture
25
+
26
+ ```
27
+ Human (User)
28
+ |
29
+ +-- Approves plan document (one-time)
30
+ |
31
+ Autonomous Loop (per project)
32
+ |
33
+ +-- Plan Phase: Read requirements, define phases, create STATE.md
34
+ +-- Execute Phase: Build features per phase
35
+ +-- Verify Phase: Run tests, check endpoints, validate UI
36
+ +-- Advance Phase: Update STATE.md, commit, move to next phase
37
+ |
38
+ +-- Status Sidecar (per service)
39
+ | +-- HTTP JSON endpoint on dedicated port
40
+ | +-- Exposes: version, uptime, component status, queue sizes
41
+ |
42
+ +-- Central Dashboard (optional)
43
+ +-- Polls all sidecar endpoints
44
+ +-- Watches STATE.md files via Chokidar
45
+ +-- SSE pushes updates to browser
46
+
47
+ Subagent Strategy:
48
+ +-- Research Agents (parallel, read-only) -- explore docs, APIs, libs
49
+ +-- Execution Agents (sequential within project) -- build features
50
+ +-- Verification Agents (parallel post-execution) -- test, validate
51
+ ```
52
+
53
+ ## Workflow
54
+
55
+ ### Phase 1: Plan Document
56
+
57
+ Create a single plan document that defines all projects and their phases. This is the one artifact the human approves before autonomous execution begins.
58
+
59
+ ```markdown
60
+ # Multi-Project Build Plan
61
+
62
+ ## Projects
63
+
64
+ ### 1. Voice Bridge v4
65
+ - Repo: C:\path\to\repos\voice-bridge-v3
66
+ - Stack: Python 3.11, PyQt6, RealtimeSTT, edge-tts
67
+ - Independence: Own repo, own venv, no shared code
68
+ - Phases:
69
+ 1. Config system with deep_merge defaults
70
+ 2. STT engine with Qt signal bridge
71
+ 3. TTS engine with audio queue
72
+ 4. Overlay + system tray
73
+ 5. Status sidecar on port 7899
74
+ 6. Claude integration + post-processing
75
+ 7. Settings dialog
76
+
77
+ ### 2. Mission Control Dashboard
78
+ - Repo: C:\path\to\repos\claude-mission-control
79
+ - Stack: Vite, React 18, TypeScript, Tailwind, Express
80
+ - Independence: Own repo, consumes other projects' APIs (read-only)
81
+ - Phases:
82
+ 1. Vite + React + Tailwind scaffold + dark theme
83
+ 2. Express backend + STATE.md parser
84
+ 3. Panel components (Projects, Memory, Git, Debug)
85
+ 4. SSE live updates via Chokidar
86
+ 5. Voice Bridge status panel (consumes sidecar)
87
+
88
+ ### 3. Ministry-LLM Bible App
89
+ - Repo: C:\path\to\repos\ministry-llm
90
+ - Stack: React, Vite, Tailwind, Express, Prisma, Qdrant
91
+ - Independence: Own repo, own database, no shared code
92
+ - Phases:
93
+ 1. Theme system (CSS custom properties, 22 themes)
94
+ 2. Prisma schema + seed data
95
+ 3. Qdrant verse embeddings
96
+ 4. Graph canvas with custom nodes
97
+ 5. Interlinear viewer
98
+ 6. AI analysis integration
99
+
100
+ ## Cross-Project Dependencies (NONE that block parallel execution)
101
+ - Dashboard reads Voice Bridge sidecar (port 7899) -- but gracefully handles offline
102
+ - Dashboard reads STATE.md files -- but files exist from phase 1 of each project
103
+ - No shared source files, no shared databases, no shared build outputs
104
+ ```
105
+
106
+ ### Phase 2: Independence Verification
107
+
108
+ Before starting autonomous execution, verify:
109
+
110
+ ```
111
+ Independence Checklist:
112
+ [x] Each project is in its own repository
113
+ [x] No shared source files between projects
114
+ [x] No shared database instances (or isolated schemas)
115
+ [x] No build output dependencies
116
+ [x] Cross-project communication is HTTP only (graceful on failure)
117
+ [x] Each project can be built and tested independently
118
+ ```
119
+
120
+ ### Phase 3: Autonomous Execution Loop
121
+
122
+ For each project, execute this loop per phase:
123
+
124
+ ```
125
+ /fire-autonomous [project-name] [phase-number]
126
+
127
+ 1. READ: Load project plan + STATE.md + current phase requirements
128
+ 2. PLAN: Break phase into implementation steps
129
+ 3. EXECUTE: Build each step, commit after each
130
+ 4. VERIFY: Run tests, check endpoints, validate outputs
131
+ 5. ADVANCE: Update STATE.md phase status, commit
132
+ 6. LOOP: Move to next phase or next project
133
+ ```
134
+
135
+ ### Phase 4: Status Sidecars for Monitoring
136
+
137
+ Every long-running service exposes a JSON status endpoint:
138
+
139
+ ```python
140
+ # Minimal status sidecar (Python)
141
+ import json
142
+ import threading
143
+ from http.server import HTTPServer, BaseHTTPRequestHandler
144
+
145
+ class StatusHandler(BaseHTTPRequestHandler):
146
+ state = {"service": "my-app", "status": "running"}
147
+
148
+ def do_GET(self):
149
+ if self.path == "/status":
150
+ self.send_response(200)
151
+ self.send_header("Content-Type", "application/json")
152
+ self.send_header("Access-Control-Allow-Origin", "*")
153
+ self.end_headers()
154
+ self.wfile.write(json.dumps(self.state).encode())
155
+ else:
156
+ self.send_error(404)
157
+
158
+ def log_message(self, *args):
159
+ pass
160
+
161
+ def start_sidecar(port, state_dict):
162
+ StatusHandler.state = state_dict
163
+ server = HTTPServer(("127.0.0.1", port), StatusHandler)
164
+ threading.Thread(target=server.serve_forever, daemon=True).start()
165
+ return server
166
+ ```
167
+
168
+ ```typescript
169
+ // Minimal status sidecar (Node.js/Express)
170
+ import express from "express";
171
+
172
+ export function startSidecar(port: number, getState: () => object) {
173
+ const app = express();
174
+ app.get("/status", (_req, res) => {
175
+ res.json(getState());
176
+ });
177
+ app.listen(port, "127.0.0.1");
178
+ }
179
+ ```
180
+
181
+ ### Phase 5: Dashboard Consumes All Endpoints
182
+
183
+ The central dashboard polls all sidecar endpoints and aggregates state:
184
+
185
+ ```typescript
186
+ // Dashboard backend: aggregate all service statuses
187
+ const SERVICES = [
188
+ { name: "voice-bridge", url: "http://127.0.0.1:7899/status" },
189
+ { name: "qdrant", url: "http://127.0.0.1:6335/collections" },
190
+ { name: "ollama", url: "http://127.0.0.1:11434/api/tags" },
191
+ { name: "neo4j", url: "http://127.0.0.1:7474" },
192
+ ];
193
+
194
+ app.get("/api/services", async (_req, res) => {
195
+ const statuses = await Promise.allSettled(
196
+ SERVICES.map(async (svc) => {
197
+ const resp = await fetch(svc.url, { signal: AbortSignal.timeout(2000) });
198
+ const data = await resp.json();
199
+ return { ...svc, status: "online", data };
200
+ })
201
+ );
202
+
203
+ res.json(
204
+ statuses.map((result, i) => {
205
+ if (result.status === "fulfilled") return result.value;
206
+ return { ...SERVICES[i], status: "offline", error: result.reason?.message };
207
+ })
208
+ );
209
+ });
210
+ ```
211
+
212
+ ## Config-First Development
213
+
214
+ **Define the full config schema with defaults BEFORE building any feature.**
215
+
216
+ This is the single most important pattern for autonomous builds. When every feature starts as a config entry, you get:
217
+ - Self-documenting feature list (the config IS the feature manifest)
218
+ - Old config files auto-upgrade via `deep_merge` (new keys get defaults)
219
+ - Settings UI can be auto-generated from the config schema
220
+ - Feature flags are built-in (just toggle config values)
221
+
222
+ ```python
223
+ # Config-first: define EVERYTHING before building anything
224
+ DEFAULT_CONFIG = {
225
+ "stt": {
226
+ "enabled": True,
227
+ "model": "base.en",
228
+ "language": "en",
229
+ "wake_word": "hey claude",
230
+ "wake_word_debounce_ms": 2000,
231
+ },
232
+ "tts": {
233
+ "enabled": True,
234
+ "engine": "edge-tts",
235
+ "voice": "en-US-AriaNeural",
236
+ },
237
+ "overlay": {
238
+ "enabled": True,
239
+ "position": "bottom-right",
240
+ "opacity": 0.85,
241
+ },
242
+ "status_server": {
243
+ "enabled": True,
244
+ "port": 7899,
245
+ },
246
+ # ... every feature has a config entry from day 1
247
+ }
248
+
249
+ def deep_merge(base: dict, override: dict) -> dict:
250
+ """Recursively merge. Override wins. New base keys auto-appear."""
251
+ from copy import deepcopy
252
+ result = deepcopy(base)
253
+ for key, value in override.items():
254
+ if key in result and isinstance(result[key], dict) and isinstance(value, dict):
255
+ result[key] = deep_merge(result[key], value)
256
+ else:
257
+ result[key] = deepcopy(value)
258
+ return result
259
+ ```
260
+
261
+ ## Subagent Strategy
262
+
263
+ ### Research Agents (Parallel, Read-Only)
264
+
265
+ Use the Task tool to spawn multiple research agents simultaneously. They explore documentation, APIs, and libraries without modifying any files.
266
+
267
+ ```
268
+ Research agents (parallel):
269
+ - Agent 1: "Research PyQt6 transparent overlay patterns"
270
+ - Agent 2: "Research pystray system tray integration with Qt"
271
+ - Agent 3: "Research RealtimeSTT configuration options"
272
+
273
+ All 3 run simultaneously. Results feed into the execution plan.
274
+ ```
275
+
276
+ ### Execution Agents (Sequential Within Project)
277
+
278
+ Within a single project, execution must be sequential. Files change, and concurrent edits to the same repo cause conflicts.
279
+
280
+ ```
281
+ Execution (sequential per project, parallel across projects):
282
+ Project A: Phase 1 → Phase 2 → Phase 3
283
+ Project B: Phase 1 → Phase 2 → Phase 3
284
+ Project C: Phase 1 → Phase 2 → Phase 3
285
+
286
+ A, B, C run in parallel (different repos).
287
+ Phases within each project run sequentially (same repo).
288
+ ```
289
+
290
+ ### Verification Agents (Parallel Post-Execution)
291
+
292
+ After execution, spawn parallel verification agents:
293
+
294
+ ```
295
+ Verification agents (parallel):
296
+ - Agent 1: "Run pytest in voice-bridge-v3, verify all pass"
297
+ - Agent 2: "curl localhost:3101/api/projects, verify JSON response"
298
+ - Agent 3: "Run prisma migrate status in ministry-llm"
299
+ ```
300
+
301
+ ## Parallel Execution Rules
302
+
303
+ 1. **Projects MUST be independent repos.** Never edit the same repository from multiple execution contexts.
304
+ 2. **Cross-project communication MUST be HTTP only.** No shared files, no shared databases (or use isolated schemas).
305
+ 3. **Each project gets its own execution context.** Own working directory, own git state, own STATE.md.
306
+ 4. **Graceful degradation on cross-project dependencies.** If the dashboard can't reach the voice bridge sidecar, it shows "offline" -- it doesn't crash.
307
+ 5. **Commit after each phase, not after each line.** Atomic phase commits make rollback clean.
308
+ 6. **STATE.md is the ground truth.** If a project's STATE.md says Phase 2 is complete, it IS complete. The dashboard reads STATE.md, not internal build state.
309
+
310
+ ## Implementation Steps
311
+
312
+ 1. **Write the plan document** -- Single Markdown file with all projects, phases, and independence checklist.
313
+ 2. **Get human approval** -- This is the one gate. After approval, autonomous execution begins.
314
+ 3. **Create STATE.md for each project** -- Initial state: Phase 1, Status: planning.
315
+ 4. **Execute config-first** -- For each project, define DEFAULT_CONFIG with all features before coding.
316
+ 5. **Run autonomous loop** -- `/fire-autonomous` per project: plan, execute, verify, advance.
317
+ 6. **Add status sidecars** -- Each service gets an HTTP /status endpoint on its own port.
318
+ 7. **Build the dashboard last** -- It consumes everything else. Build it after sidecar endpoints are stable.
319
+ 8. **Verify cross-project integration** -- Dashboard shows all services, STATE.md files are current, sidecars respond.
320
+
321
+ ## When to Use
322
+
323
+ - Building 3+ independent projects in a single session
324
+ - Projects that will eventually interact (service A exposes API, service B consumes it)
325
+ - Hackathon-style builds where time efficiency matters
326
+ - When the human wants to approve a plan once and let execution run
327
+ - Building a service mesh (multiple services + monitoring dashboard)
328
+
329
+ ## When NOT to Use
330
+
331
+ - Single project with focused requirements -- autonomous loop overhead is not worth it
332
+ - Tightly coupled projects that share source files -- parallel execution will conflict
333
+ - Exploratory/research tasks where the plan changes every 10 minutes
334
+ - When detailed human review is needed at every step (e.g., security-sensitive code)
335
+ - Fewer than 3 projects -- the orchestration overhead exceeds the parallelism benefit
336
+
337
+ ## Common Mistakes
338
+
339
+ 1. **Editing the same repo from multiple agents** -- This causes git conflicts and file corruption. One execution agent per repo at a time.
340
+ 2. **Not verifying independence before starting** -- If Project A's build output is Project B's input, they're not independent. Restructure first.
341
+ 3. **Skipping config-first development** -- Without DEFAULT_CONFIG, adding features later breaks existing config files. Users get `KeyError` on upgrade.
342
+ 4. **Hardcoding sidecar ports** -- Put port numbers in config, not in source code. Two services on the same port crash silently.
343
+ 5. **Not handling sidecar offline gracefully** -- The dashboard WILL try to reach services that haven't started yet. Return `{ status: "offline" }`, don't throw.
344
+ 6. **Committing too granularly or too coarsely** -- Commit per phase is the sweet spot. Per-line commits pollute history. Per-project commits make rollback impossible.
345
+ 7. **Not updating STATE.md** -- If the autonomous loop doesn't update STATE.md after each phase, the dashboard shows stale data and humans lose trust.
346
+ 8. **Forgetting to seed/migrate databases** -- Each project with a database needs its seed step. Don't assume databases exist from previous sessions.
347
+
348
+ ## Related Skills
349
+
350
+ - `python-desktop-app-architecture.md` -- One of the projects built with this methodology
351
+ - `realtime-monitoring-dashboard.md` -- The dashboard that monitors all projects
352
+ - `fullstack-bible-study-platform.md` -- Another project built with this methodology
353
+
354
+ ## References
355
+
356
+ - Contributed from: **voice-bridge-v4** + **claude-mission-control** + **ministry-llm**
357
+ - Repos:
358
+ - `C:\path\to\repos\voice-bridge-v3`
359
+ - `C:\path\to\repos\claude-mission-control`
360
+ - `C:\path\to\repos\ministry-llm`