claude-flow-novice 1.6.1 → 1.6.2

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 (244) hide show
  1. package/.claude/agents/cfn-loop/product-owner.md +54 -4
  2. package/.claude/commands/cfn-claude-sync.md +303 -0
  3. package/.claude/commands/cfn-loop-epic.md +290 -0
  4. package/.claude/commands/cfn-loop-single.md +168 -0
  5. package/.claude/commands/cfn-loop-sprints.md +384 -0
  6. package/.claude/commands/cfn-loop.md +180 -0
  7. package/.claude/commands/metrics-summary.md +58 -0
  8. package/.claude/commands/parse-epic.md +357 -0
  9. package/.claude/settings.json +4 -4
  10. package/.claude/settings.local.json +9 -2
  11. package/.claude-flow-novice/.claude/agents/cfn-loop/product-owner.md +792 -0
  12. package/.claude-flow-novice/dist/mcp/server.js +21 -2
  13. package/.claude-flow-novice/dist/src/api/claude-client.js +138 -3
  14. package/.claude-flow-novice/dist/src/api/claude-client.js.map +1 -1
  15. package/.claude-flow-novice/dist/src/cfn-loop/phase-orchestrator-example.js +1 -1
  16. package/.claude-flow-novice/dist/src/cfn-loop/scope-control.js +247 -0
  17. package/.claude-flow-novice/dist/src/cfn-loop/scope-control.js.map +1 -0
  18. package/.claude-flow-novice/dist/src/cli/commands/swarm.js +32 -15
  19. package/.claude-flow-novice/dist/src/cli/commands/swarm.js.map +1 -1
  20. package/.claude-flow-novice/dist/src/cli/commands/transparency.js +455 -0
  21. package/.claude-flow-novice/dist/src/cli/commands/transparency.js.map +1 -0
  22. package/.claude-flow-novice/dist/src/cli/simple-commands/init/templates/CLAUDE.md +129 -13
  23. package/.claude-flow-novice/dist/src/components/visualizations/index.js +9 -0
  24. package/.claude-flow-novice/dist/src/components/visualizations/index.js.map +1 -0
  25. package/.claude-flow-novice/dist/src/coordination/adapters/v1-coordinator-adapter.js +462 -0
  26. package/.claude-flow-novice/dist/src/coordination/adapters/v1-coordinator-adapter.js.map +1 -0
  27. package/.claude-flow-novice/dist/src/coordination/config-translator.js +248 -0
  28. package/.claude-flow-novice/dist/src/coordination/config-translator.js.map +1 -0
  29. package/.claude-flow-novice/dist/src/coordination/coordination-toggle.js +287 -0
  30. package/.claude-flow-novice/dist/src/coordination/coordination-toggle.js.map +1 -0
  31. package/.claude-flow-novice/dist/src/coordination/distributed-consensus.js +68 -9
  32. package/.claude-flow-novice/dist/src/coordination/distributed-consensus.js.map +1 -1
  33. package/.claude-flow-novice/dist/src/coordination/feature-flags.js +166 -0
  34. package/.claude-flow-novice/dist/src/coordination/feature-flags.js.map +1 -0
  35. package/.claude-flow-novice/dist/src/coordination/queen-agent.js +18 -4
  36. package/.claude-flow-novice/dist/src/coordination/queen-agent.js.map +1 -1
  37. package/.claude-flow-novice/dist/src/coordination/role-assignment.js +6 -110
  38. package/.claude-flow-novice/dist/src/coordination/role-assignment.js.map +1 -1
  39. package/.claude-flow-novice/dist/src/coordination/v2/cache/artifact-cache-optimizer.js +632 -0
  40. package/.claude-flow-novice/dist/src/coordination/v2/cache/artifact-cache-optimizer.js.map +1 -0
  41. package/.claude-flow-novice/dist/src/coordination/v2/cache/index.js +11 -0
  42. package/.claude-flow-novice/dist/src/coordination/v2/cache/index.js.map +1 -0
  43. package/.claude-flow-novice/dist/src/coordination/v2/checkpoints/checkpoint-compressor.js +318 -0
  44. package/.claude-flow-novice/dist/src/coordination/v2/checkpoints/checkpoint-compressor.js.map +1 -0
  45. package/.claude-flow-novice/dist/src/coordination/v2/coordinators/cascading-shutdown.example.js +364 -0
  46. package/.claude-flow-novice/dist/src/coordination/v2/coordinators/cascading-shutdown.example.js.map +1 -0
  47. package/.claude-flow-novice/dist/src/coordination/v2/coordinators/cascading-shutdown.js +492 -0
  48. package/.claude-flow-novice/dist/src/coordination/v2/coordinators/cascading-shutdown.js.map +1 -0
  49. package/.claude-flow-novice/dist/src/coordination/v2/coordinators/hierarchical-coordinator.js +786 -0
  50. package/.claude-flow-novice/dist/src/coordination/v2/coordinators/hierarchical-coordinator.js.map +1 -0
  51. package/.claude-flow-novice/dist/src/coordination/v2/coordinators/index.js +16 -0
  52. package/.claude-flow-novice/dist/src/coordination/v2/coordinators/index.js.map +1 -0
  53. package/.claude-flow-novice/dist/src/coordination/v2/coordinators/parent-child-manager.js +342 -0
  54. package/.claude-flow-novice/dist/src/coordination/v2/coordinators/parent-child-manager.js.map +1 -0
  55. package/.claude-flow-novice/dist/src/coordination/v2/coordinators/swarm-coordinator-v2.js +601 -0
  56. package/.claude-flow-novice/dist/src/coordination/v2/coordinators/swarm-coordinator-v2.js.map +1 -0
  57. package/.claude-flow-novice/dist/src/coordination/v2/core/help-request-metrics.js +211 -0
  58. package/.claude-flow-novice/dist/src/coordination/v2/core/help-request-metrics.js.map +1 -0
  59. package/.claude-flow-novice/dist/src/coordination/v2/core/index.js +1 -0
  60. package/.claude-flow-novice/dist/src/coordination/v2/core/index.js.map +1 -1
  61. package/.claude-flow-novice/dist/src/coordination/v2/core/message-broker.js +365 -6
  62. package/.claude-flow-novice/dist/src/coordination/v2/core/message-broker.js.map +1 -1
  63. package/.claude-flow-novice/dist/src/coordination/v2/core/resource-manager-safe.js +478 -0
  64. package/.claude-flow-novice/dist/src/coordination/v2/core/resource-manager-safe.js.map +1 -0
  65. package/.claude-flow-novice/dist/src/coordination/v2/core/state-machine-config.js +5 -2
  66. package/.claude-flow-novice/dist/src/coordination/v2/core/state-machine-config.js.map +1 -1
  67. package/.claude-flow-novice/dist/src/coordination/v2/core/state-machine.js +189 -0
  68. package/.claude-flow-novice/dist/src/coordination/v2/core/state-machine.js.map +1 -1
  69. package/.claude-flow-novice/dist/src/coordination/v2/deadlock/deadlock-detector.js +424 -0
  70. package/.claude-flow-novice/dist/src/coordination/v2/deadlock/deadlock-detector.js.map +1 -0
  71. package/.claude-flow-novice/dist/src/coordination/v2/deadlock/index.js +9 -0
  72. package/.claude-flow-novice/dist/src/coordination/v2/deadlock/index.js.map +1 -0
  73. package/.claude-flow-novice/dist/src/coordination/v2/deadlock/resource-manager.js +669 -0
  74. package/.claude-flow-novice/dist/src/coordination/v2/deadlock/resource-manager.js.map +1 -0
  75. package/.claude-flow-novice/dist/src/coordination/v2/dependency/artifact-storage.js +451 -0
  76. package/.claude-flow-novice/dist/src/coordination/v2/dependency/artifact-storage.js.map +1 -0
  77. package/.claude-flow-novice/dist/src/coordination/v2/dependency/cycle-detector.js +271 -0
  78. package/.claude-flow-novice/dist/src/coordination/v2/dependency/cycle-detector.js.map +1 -0
  79. package/.claude-flow-novice/dist/src/coordination/v2/dependency/dependency-graph.js +335 -0
  80. package/.claude-flow-novice/dist/src/coordination/v2/dependency/dependency-graph.js.map +1 -0
  81. package/.claude-flow-novice/dist/src/coordination/v2/dependency/dependency-manager.js +439 -0
  82. package/.claude-flow-novice/dist/src/coordination/v2/dependency/dependency-manager.js.map +1 -0
  83. package/.claude-flow-novice/dist/src/coordination/v2/dependency/dependency-request.js +92 -0
  84. package/.claude-flow-novice/dist/src/coordination/v2/dependency/dependency-request.js.map +1 -0
  85. package/.claude-flow-novice/dist/src/coordination/v2/dependency/index.js +21 -0
  86. package/.claude-flow-novice/dist/src/coordination/v2/dependency/index.js.map +1 -0
  87. package/.claude-flow-novice/dist/src/coordination/v2/dependency/topological-sort.js +223 -0
  88. package/.claude-flow-novice/dist/src/coordination/v2/dependency/topological-sort.js.map +1 -0
  89. package/.claude-flow-novice/dist/src/coordination/v2/help-system/help-coordinator.js +436 -0
  90. package/.claude-flow-novice/dist/src/coordination/v2/help-system/help-coordinator.js.map +1 -0
  91. package/.claude-flow-novice/dist/src/coordination/v2/help-system/help-matcher.js +278 -0
  92. package/.claude-flow-novice/dist/src/coordination/v2/help-system/help-matcher.js.map +1 -0
  93. package/.claude-flow-novice/dist/src/coordination/v2/help-system/help-request-handler.js +317 -0
  94. package/.claude-flow-novice/dist/src/coordination/v2/help-system/help-request-handler.js.map +1 -0
  95. package/.claude-flow-novice/dist/src/coordination/v2/help-system/help-request.js +273 -0
  96. package/.claude-flow-novice/dist/src/coordination/v2/help-system/help-request.js.map +1 -0
  97. package/.claude-flow-novice/dist/src/coordination/v2/help-system/index.js +15 -0
  98. package/.claude-flow-novice/dist/src/coordination/v2/help-system/index.js.map +1 -0
  99. package/.claude-flow-novice/dist/src/coordination/v2/help-system/waiting-agent-pool.js +512 -0
  100. package/.claude-flow-novice/dist/src/coordination/v2/help-system/waiting-agent-pool.js.map +1 -0
  101. package/.claude-flow-novice/dist/src/coordination/v2/index.js +6 -0
  102. package/.claude-flow-novice/dist/src/coordination/v2/index.js.map +1 -1
  103. package/.claude-flow-novice/dist/src/coordination/v2/integration/help-deadlock-integration.js +557 -0
  104. package/.claude-flow-novice/dist/src/coordination/v2/integration/help-deadlock-integration.js.map +1 -0
  105. package/.claude-flow-novice/dist/src/coordination/v2/integration/index.js +14 -0
  106. package/.claude-flow-novice/dist/src/coordination/v2/integration/index.js.map +1 -0
  107. package/.claude-flow-novice/dist/src/coordination/v2/integration/message-bus-completion-integration.example.js +212 -0
  108. package/.claude-flow-novice/dist/src/coordination/v2/integration/message-bus-completion-integration.example.js.map +1 -0
  109. package/.claude-flow-novice/dist/src/coordination/v2/integration/message-bus-completion-integration.js +552 -0
  110. package/.claude-flow-novice/dist/src/coordination/v2/integration/message-bus-completion-integration.js.map +1 -0
  111. package/.claude-flow-novice/dist/src/coordination/v2/memory/dependency-storage.js +367 -0
  112. package/.claude-flow-novice/dist/src/coordination/v2/memory/dependency-storage.js.map +1 -0
  113. package/.claude-flow-novice/dist/src/coordination/v2/memory/index.js +1 -0
  114. package/.claude-flow-novice/dist/src/coordination/v2/memory/index.js.map +1 -1
  115. package/.claude-flow-novice/dist/src/coordination/v2/messaging/channel.js +371 -0
  116. package/.claude-flow-novice/dist/src/coordination/v2/messaging/channel.js.map +1 -0
  117. package/.claude-flow-novice/dist/src/coordination/v2/messaging/channels/dependency-channel.js +355 -0
  118. package/.claude-flow-novice/dist/src/coordination/v2/messaging/channels/dependency-channel.js.map +1 -0
  119. package/.claude-flow-novice/dist/src/coordination/v2/messaging/channels/help-channel.js +424 -0
  120. package/.claude-flow-novice/dist/src/coordination/v2/messaging/channels/help-channel.js.map +1 -0
  121. package/.claude-flow-novice/dist/src/coordination/v2/messaging/channels/index.js +16 -0
  122. package/.claude-flow-novice/dist/src/coordination/v2/messaging/channels/index.js.map +1 -0
  123. package/.claude-flow-novice/dist/src/coordination/v2/messaging/channels/state-channel.js +295 -0
  124. package/.claude-flow-novice/dist/src/coordination/v2/messaging/channels/state-channel.js.map +1 -0
  125. package/.claude-flow-novice/dist/src/coordination/v2/messaging/channels/task-channel.js +411 -0
  126. package/.claude-flow-novice/dist/src/coordination/v2/messaging/channels/task-channel.js.map +1 -0
  127. package/.claude-flow-novice/dist/src/coordination/v2/messaging/index.js +14 -0
  128. package/.claude-flow-novice/dist/src/coordination/v2/messaging/index.js.map +1 -0
  129. package/.claude-flow-novice/dist/src/coordination/v2/messaging/message-bus.js +387 -0
  130. package/.claude-flow-novice/dist/src/coordination/v2/messaging/message-bus.js.map +1 -0
  131. package/.claude-flow-novice/dist/src/coordination/v2/messaging/message-persistence.js +589 -0
  132. package/.claude-flow-novice/dist/src/coordination/v2/messaging/message-persistence.js.map +1 -0
  133. package/.claude-flow-novice/dist/src/coordination/v2/messaging/message-router.js +444 -0
  134. package/.claude-flow-novice/dist/src/coordination/v2/messaging/message-router.js.map +1 -0
  135. package/.claude-flow-novice/dist/src/coordination/v2/sdk/checkpoint-manager.js +29 -8
  136. package/.claude-flow-novice/dist/src/coordination/v2/sdk/checkpoint-manager.js.map +1 -1
  137. package/.claude-flow-novice/dist/src/coordination/v2/sdk/help-coordinator.js +470 -0
  138. package/.claude-flow-novice/dist/src/coordination/v2/sdk/help-coordinator.js.map +1 -0
  139. package/.claude-flow-novice/dist/src/coordination/v2/sdk/hierarchical-background-integration.js +450 -0
  140. package/.claude-flow-novice/dist/src/coordination/v2/sdk/hierarchical-background-integration.js.map +1 -0
  141. package/.claude-flow-novice/dist/src/coordination/v2/sdk/index.js +5 -0
  142. package/.claude-flow-novice/dist/src/coordination/v2/sdk/index.js.map +1 -1
  143. package/.claude-flow-novice/dist/src/coordination/v2/sdk/multi-level-control.js +545 -0
  144. package/.claude-flow-novice/dist/src/coordination/v2/sdk/multi-level-control.js.map +1 -0
  145. package/.claude-flow-novice/dist/src/coordination/v2/sdk/query-controller.js +44 -0
  146. package/.claude-flow-novice/dist/src/coordination/v2/sdk/query-controller.js.map +1 -1
  147. package/.claude-flow-novice/dist/src/coordination/v2/sdk/query-message-integration.js +415 -0
  148. package/.claude-flow-novice/dist/src/coordination/v2/sdk/query-message-integration.js.map +1 -0
  149. package/.claude-flow-novice/dist/src/coordination/v2/sdk/session-pool-optimizer.js +615 -0
  150. package/.claude-flow-novice/dist/src/coordination/v2/sdk/session-pool-optimizer.js.map +1 -0
  151. package/.claude-flow-novice/dist/src/coordination/v2/security/payload-validator.js +259 -0
  152. package/.claude-flow-novice/dist/src/coordination/v2/security/payload-validator.js.map +1 -0
  153. package/.claude-flow-novice/dist/src/coordination/v2/transparency/index.js +17 -0
  154. package/.claude-flow-novice/dist/src/coordination/v2/transparency/index.js.map +1 -0
  155. package/.claude-flow-novice/dist/src/coordination/v2/transparency/transparency-integration.js +357 -0
  156. package/.claude-flow-novice/dist/src/coordination/v2/transparency/transparency-integration.js.map +1 -0
  157. package/.claude-flow-novice/dist/src/coordination/v2/transparency/transparency-system.js +679 -0
  158. package/.claude-flow-novice/dist/src/coordination/v2/transparency/transparency-system.js.map +1 -0
  159. package/.claude-flow-novice/dist/src/core/agent-manager.js +30 -0
  160. package/.claude-flow-novice/dist/src/core/agent-manager.js.map +1 -1
  161. package/.claude-flow-novice/dist/src/mcp/server.js +21 -2
  162. package/.claude-flow-novice/dist/src/mcp/server.js.map +1 -1
  163. package/.claude-flow-novice/dist/src/observability/metrics-counter.js +268 -0
  164. package/.claude-flow-novice/dist/src/observability/metrics-counter.js.map +1 -0
  165. package/.claude-flow-novice/dist/src/observability/metrics-storage.js +265 -0
  166. package/.claude-flow-novice/dist/src/observability/metrics-storage.js.map +1 -0
  167. package/.claude-flow-novice/dist/src/observability/telemetry.js +26 -0
  168. package/.claude-flow-novice/dist/src/observability/telemetry.js.map +1 -1
  169. package/.claude-flow-novice/dist/src/providers/tiered-router.js +64 -10
  170. package/.claude-flow-novice/dist/src/providers/tiered-router.js.map +1 -1
  171. package/.claude-flow-novice/dist/src/providers/zai-provider.js +196 -97
  172. package/.claude-flow-novice/dist/src/providers/zai-provider.js.map +1 -1
  173. package/.claude-flow-novice/dist/src/slash-commands/cfn-claude-sync.js +533 -0
  174. package/.claude-flow-novice/dist/src/slash-commands/index.js +5 -0
  175. package/.claude-flow-novice/dist/src/slash-commands/metrics-summary-class.js +74 -0
  176. package/.claude-flow-novice/dist/src/slash-commands/metrics-summary.js +335 -0
  177. package/.claude-flow-novice/dist/src/slash-commands/register-all-commands.js +12 -0
  178. package/.claude-flow-novice/dist/src/verification/checkpoint-compression-demo.js +96 -0
  179. package/.claude-flow-novice/dist/src/verification/checkpoint-compression-demo.js.map +1 -0
  180. package/.claude-flow-novice/dist/src/verification/checkpoint-compression.js +406 -0
  181. package/.claude-flow-novice/dist/src/verification/checkpoint-compression.js.map +1 -0
  182. package/.claude-flow-novice/dist/src/verification/checkpoint-manager.js +35 -5
  183. package/.claude-flow-novice/dist/src/verification/checkpoint-manager.js.map +1 -1
  184. package/.claude-flow-novice/dist/src/web/api/config/api-config.js +186 -0
  185. package/.claude-flow-novice/dist/src/web/api/config/api-config.js.map +1 -0
  186. package/.claude-flow-novice/dist/src/web/api/middleware/auth.js +205 -0
  187. package/.claude-flow-novice/dist/src/web/api/middleware/auth.js.map +1 -0
  188. package/.claude-flow-novice/dist/src/web/api/middleware/cache.js +262 -0
  189. package/.claude-flow-novice/dist/src/web/api/middleware/cache.js.map +1 -0
  190. package/.claude-flow-novice/dist/src/web/api/middleware/error-handler.js +250 -0
  191. package/.claude-flow-novice/dist/src/web/api/middleware/error-handler.js.map +1 -0
  192. package/.claude-flow-novice/dist/src/web/api/middleware/request-logger.js +217 -0
  193. package/.claude-flow-novice/dist/src/web/api/middleware/request-logger.js.map +1 -0
  194. package/.claude-flow-novice/dist/src/web/api/middleware/validation.js +325 -0
  195. package/.claude-flow-novice/dist/src/web/api/middleware/validation.js.map +1 -0
  196. package/.claude-flow-novice/dist/src/web/api/routes/events.js +465 -0
  197. package/.claude-flow-novice/dist/src/web/api/routes/events.js.map +1 -0
  198. package/.claude-flow-novice/dist/src/web/api/routes/hierarchy.js +302 -0
  199. package/.claude-flow-novice/dist/src/web/api/routes/hierarchy.js.map +1 -0
  200. package/.claude-flow-novice/dist/src/web/api/routes/index.js +14 -0
  201. package/.claude-flow-novice/dist/src/web/api/routes/index.js.map +1 -0
  202. package/.claude-flow-novice/dist/src/web/api/routes/metrics.js +561 -0
  203. package/.claude-flow-novice/dist/src/web/api/routes/metrics.js.map +1 -0
  204. package/.claude-flow-novice/dist/src/web/api/routes/status.js +450 -0
  205. package/.claude-flow-novice/dist/src/web/api/routes/status.js.map +1 -0
  206. package/.claude-flow-novice/dist/src/web/api/server.js +451 -0
  207. package/.claude-flow-novice/dist/src/web/api/server.js.map +1 -0
  208. package/.claude-flow-novice/dist/src/web/dashboard/hooks/useWebSocket.js +385 -0
  209. package/.claude-flow-novice/dist/src/web/dashboard/hooks/useWebSocket.js.map +1 -0
  210. package/.claude-flow-novice/dist/src/web/dashboard/index.js +87 -0
  211. package/.claude-flow-novice/dist/src/web/dashboard/index.js.map +1 -0
  212. package/.claude-flow-novice/dist/src/web/dashboard/types.js +6 -0
  213. package/.claude-flow-novice/dist/src/web/dashboard/types.js.map +1 -0
  214. package/.claude-flow-novice/metrics.db +0 -0
  215. package/.claude-flow-novice/metrics.db-shm +0 -0
  216. package/.claude-flow-novice/metrics.db-wal +0 -0
  217. package/CLAUDE.md +29 -0
  218. package/README.md +27 -0
  219. package/config/hooks/post-edit-pipeline.js +36 -2
  220. package/examples/metrics-counter-demo.ts +106 -0
  221. package/examples/persistent-metrics-demo.ts +83 -0
  222. package/examples/phase-5-multi-level-control.ts +282 -0
  223. package/examples/session-pool-optimizer-example.ts +311 -0
  224. package/package.json +15 -3
  225. package/scripts/check-routing-stats.cjs +122 -0
  226. package/scripts/pre-publish-validation.cjs +212 -0
  227. package/scripts/test-provider-routing.cjs +228 -0
  228. package/scripts/test-routing-telemetry.cjs +147 -0
  229. package/scripts/test-zai-10k.cjs +81 -0
  230. package/scripts/test-zai-api.cjs +191 -0
  231. package/scripts/test-zai-diagnostic.cjs +151 -0
  232. package/scripts/test-zai-final.cjs +128 -0
  233. package/scripts/test-zai-with-env.cjs +85 -0
  234. package/scripts/validate-coordination-cli.js +69 -0
  235. package/scripts/validate-coordination-toggle-integration.cjs +501 -0
  236. package/src/cli/simple-commands/init/templates/CLAUDE.md +29 -0
  237. package/src/observability/metrics-counter.ts +347 -0
  238. package/src/observability/metrics-storage.ts +356 -0
  239. package/src/observability/telemetry.ts +658 -0
  240. package/src/slash-commands/cfn-claude-sync.js +533 -0
  241. package/src/slash-commands/index.js +5 -0
  242. package/src/slash-commands/metrics-summary-class.js +74 -0
  243. package/src/slash-commands/metrics-summary.js +335 -0
  244. package/src/slash-commands/register-all-commands.js +12 -0
@@ -0,0 +1,357 @@
1
+ ---
2
+ description: "Parse natural language epic documents to structured JSON configuration"
3
+ argument-hint: "<epic-directory> [--output <file>] [--validate]"
4
+ allowed-tools: ["Read", "Write", "Bash", "Glob", "Grep"]
5
+ ---
6
+
7
+ # Parse Epic - Natural Language to Structured JSON
8
+
9
+ Convert natural language epic markdown documents into structured JSON configuration for CFN Loop execution.
10
+
11
+ **Input**: Natural language epic directory with markdown files
12
+ **Output**: Structured JSON configuration with phases, sprints, dependencies
13
+
14
+ ## Usage
15
+
16
+ ```bash
17
+ # Basic parsing
18
+ /parse-epic planning/example-epic
19
+
20
+ # With custom output file
21
+ /parse-epic planning/my-epic --output epic-config.json
22
+
23
+ # With validation
24
+ /parse-epic planning/auth-epic --validate
25
+
26
+ # Full options
27
+ /parse-epic planning/example-epic --output custom-epic.json --validate
28
+ ```
29
+
30
+ ## Command Arguments
31
+
32
+ - `<epic-directory>`: **Required** - Path to epic directory containing markdown files
33
+ - `--output <file>`: Optional - Custom output JSON file (default: `<epic-name>-config.json`)
34
+ - `--validate`: Optional - Validate parsed configuration against schema
35
+
36
+ ## Epic Directory Structure
37
+
38
+ ```
39
+ planning/example-epic/
40
+ ├── OVERVIEW.md # Epic description, goals, scope
41
+ ├── phase-1-authentication.md # Phase 1 details
42
+ ├── phase-2-authorization.md # Phase 2 details
43
+ ├── phase-3-session-mgmt.md # Phase 3 details
44
+ └── dependencies.md # Cross-phase dependencies (optional)
45
+ ```
46
+
47
+ ## Markdown Format
48
+
49
+ ### OVERVIEW.md
50
+ ```markdown
51
+ # Auth System Epic
52
+
53
+ **Goal**: Build complete authentication and authorization system
54
+
55
+ ## Scope
56
+
57
+ ### In Scope
58
+ - JWT-based authentication
59
+ - Role-based access control (RBAC)
60
+ - Session management
61
+ - Password security (bcrypt)
62
+
63
+ ### Out of Scope
64
+ - OAuth/social login
65
+ - Multi-factor authentication
66
+ - Biometric authentication
67
+
68
+ ## Risk Profile
69
+ public-facing-medium-risk
70
+
71
+ ## Estimated Timeline
72
+ 3 phases, 8 sprints total
73
+ ```
74
+
75
+ ### Phase Markdown (phase-1-authentication.md)
76
+ ```markdown
77
+ # Phase 1: User Authentication
78
+
79
+ **Phase ID**: 1
80
+ **Dependencies**: None
81
+
82
+ ## Deliverables
83
+ - Login API endpoint (POST /auth/login)
84
+ - JWT token generation
85
+ - Password validation
86
+ - bcrypt password hashing
87
+
88
+ ## Sprints
89
+
90
+ ### Sprint 1.1: Core Login API
91
+ - POST /auth/login endpoint
92
+ - JWT token generation
93
+ - Basic password validation
94
+ **Estimated Agents**: 3
95
+
96
+ ### Sprint 1.2: Password Security
97
+ - bcrypt password hashing
98
+ - Salt generation
99
+ - Hash verification
100
+ **Estimated Agents**: 2
101
+
102
+ ## Success Criteria
103
+ - All login tests passing
104
+ - Security audit complete
105
+ - API documentation updated
106
+ ```
107
+
108
+ ## Output JSON Structure
109
+
110
+ The parser generates a structured JSON configuration:
111
+
112
+ ```json
113
+ {
114
+ "epic_name": "auth-system",
115
+ "epic_goal": "Build complete authentication and authorization system",
116
+ "scope": {
117
+ "in_scope": [
118
+ "JWT-based authentication",
119
+ "Role-based access control (RBAC)",
120
+ "Session management",
121
+ "Password security (bcrypt)"
122
+ ],
123
+ "out_of_scope": [
124
+ "OAuth/social login",
125
+ "Multi-factor authentication",
126
+ "Biometric authentication"
127
+ ],
128
+ "risk_profile": "public-facing-medium-risk"
129
+ },
130
+ "phases": [
131
+ {
132
+ "phase_id": "1",
133
+ "phase_name": "User Authentication",
134
+ "dependencies": [],
135
+ "deliverables": [
136
+ "Login API endpoint (POST /auth/login)",
137
+ "JWT token generation",
138
+ "Password validation",
139
+ "bcrypt password hashing"
140
+ ],
141
+ "sprints": [
142
+ {
143
+ "sprint_id": "1.1",
144
+ "sprint_name": "Core Login API",
145
+ "deliverables": [
146
+ "POST /auth/login endpoint",
147
+ "JWT token generation",
148
+ "Basic password validation"
149
+ ],
150
+ "estimated_agents": 3
151
+ },
152
+ {
153
+ "sprint_id": "1.2",
154
+ "sprint_name": "Password Security",
155
+ "deliverables": [
156
+ "bcrypt password hashing",
157
+ "Salt generation",
158
+ "Hash verification"
159
+ ],
160
+ "estimated_agents": 2
161
+ }
162
+ ],
163
+ "success_criteria": [
164
+ "All login tests passing",
165
+ "Security audit complete",
166
+ "API documentation updated"
167
+ ]
168
+ }
169
+ ],
170
+ "decision_authority_config": {
171
+ "auto_approve_threshold": 0.90,
172
+ "auto_relaunch_max_iteration": 10,
173
+ "escalation_criteria": [
174
+ "security vulnerability",
175
+ "data loss risk"
176
+ ]
177
+ }
178
+ }
179
+ ```
180
+
181
+ ## Validation
182
+
183
+ When using `--validate`, the parser checks:
184
+ - ✅ Valid phase IDs and naming
185
+ - ✅ Dependency resolution (no circular dependencies)
186
+ - ✅ Sprint numbering consistency (1.1, 1.2, etc.)
187
+ - ✅ Deliverables are non-empty
188
+ - ✅ Scope boundaries are defined
189
+ - ✅ Risk profile is valid (internal-only-low-risk, public-facing-medium-risk, critical-high-risk)
190
+ - ✅ Success criteria are specified
191
+
192
+ **Validation Errors:**
193
+ ```
194
+ ❌ Validation Failed:
195
+ - Phase 2 dependency on Phase 5 (does not exist)
196
+ - Sprint 1.3 missing deliverables
197
+ - Risk profile "high" invalid (use: internal-only-low-risk, public-facing-medium-risk, critical-high-risk)
198
+ ```
199
+
200
+ ## Integration with CFN Loop
201
+
202
+ After parsing, use the JSON configuration with CFN Loop commands:
203
+
204
+ ```bash
205
+ # 1. Parse epic to JSON
206
+ /parse-epic planning/auth-epic --output auth-config.json --validate
207
+
208
+ # 2. Execute epic using parsed configuration
209
+ /cfn-loop-epic "$(cat auth-config.json)"
210
+
211
+ # Or manually reference phases
212
+ /cfn-loop-sprints "Phase 1: User Authentication (from auth-config.json)"
213
+ ```
214
+
215
+ ## Automatic Scope Storage
216
+
217
+ The parser automatically stores scope boundaries in memory for Product Owner access:
218
+
219
+ ```javascript
220
+ // Automatically executed during parsing
221
+ mcp__claude-flow-novice__memory_usage({
222
+ action: "store",
223
+ namespace: "scope-control",
224
+ key: "project-boundaries",
225
+ value: JSON.stringify({
226
+ primary_goal: epicConfig.epic_goal,
227
+ in_scope: epicConfig.scope.in_scope,
228
+ out_of_scope: epicConfig.scope.out_of_scope,
229
+ risk_profile: epicConfig.scope.risk_profile,
230
+ decision_authority_config: epicConfig.decision_authority_config
231
+ })
232
+ })
233
+ ```
234
+
235
+ ## Example Workflows
236
+
237
+ ### Workflow 1: Parse and Execute Epic
238
+ ```bash
239
+ # Step 1: Create epic markdown files in planning/auth-epic/
240
+ # Step 2: Parse to JSON
241
+ /parse-epic planning/auth-epic --output auth-config.json --validate
242
+
243
+ # Step 3: Execute epic (automatic phase orchestration)
244
+ /cfn-loop-epic "$(cat auth-config.json)"
245
+ ```
246
+
247
+ ### Workflow 2: Parse and Execute Single Phase
248
+ ```bash
249
+ # Step 1: Parse epic
250
+ /parse-epic planning/my-epic --validate
251
+
252
+ # Step 2: Extract specific phase (manual)
253
+ # Read my-epic-config.json, copy Phase 1 details
254
+
255
+ # Step 3: Execute single phase
256
+ /cfn-loop-sprints "Phase 1 content from parsed JSON"
257
+ ```
258
+
259
+ ### Workflow 3: Validate Epic Structure
260
+ ```bash
261
+ # Validate epic structure before execution
262
+ /parse-epic planning/complex-epic --validate
263
+
264
+ # Review validation output
265
+ # Fix any errors in markdown files
266
+ # Re-run validation until clean
267
+ ```
268
+
269
+ ## Output Files
270
+
271
+ **Generated Files:**
272
+ - `<epic-name>-config.json` - Structured epic configuration
273
+ - `<epic-name>-validation-report.json` - Validation results (if --validate)
274
+
275
+ **Example Output:**
276
+ ```bash
277
+ 🔍 Epic Parser - Natural Language to Structured JSON
278
+
279
+ 📂 Epic directory: planning/auth-epic
280
+ 📄 Overview file: OVERVIEW.md
281
+
282
+ ✅ Parsed successfully:
283
+ - Epic: auth-system
284
+ - Phases: 3
285
+ - Total Sprints: 8
286
+ - Scope boundaries: ✓
287
+ - Dependencies: ✓
288
+
289
+ 📄 Output: auth-config.json
290
+ ✅ Validation: PASSED
291
+
292
+ Ready for CFN Loop execution!
293
+ ```
294
+
295
+ ## Error Handling
296
+
297
+ **Common Errors:**
298
+
299
+ 1. **Missing OVERVIEW.md**
300
+ ```
301
+ ❌ Epic directory must contain OVERVIEW.md
302
+ ```
303
+
304
+ 2. **Invalid Phase Dependencies**
305
+ ```
306
+ ❌ Phase 3 depends on Phase 5 (not found)
307
+ ```
308
+
309
+ 3. **Circular Dependencies**
310
+ ```
311
+ ❌ Circular dependency detected: Phase 1 → Phase 2 → Phase 1
312
+ ```
313
+
314
+ 4. **Invalid Sprint Numbering**
315
+ ```
316
+ ❌ Sprint 1.5 follows 1.2 (expected 1.3)
317
+ ```
318
+
319
+ ## Advanced Features
320
+
321
+ ### Custom Risk Profiles
322
+ ```markdown
323
+ ## Risk Profile
324
+ custom-high-security-critical
325
+
326
+ ## Decision Authority
327
+ - Auto-approve threshold: 0.95
328
+ - Max iteration: 5
329
+ - Escalation: security-team-approval-required
330
+ ```
331
+
332
+ ### Cross-Phase Dependencies
333
+ Create `dependencies.md`:
334
+ ```markdown
335
+ # Epic Dependencies
336
+
337
+ - Phase 2 requires Phase 1 (authentication must complete first)
338
+ - Phase 3 requires Phase 1, Phase 2 (session needs auth + authorization)
339
+ - Phase 4 requires Phase 3 (admin panel needs sessions)
340
+ ```
341
+
342
+ ### Sprint Estimation
343
+ ```markdown
344
+ ### Sprint 2.3: Complex Authorization Logic
345
+ **Estimated Agents**: 8
346
+ **Complexity**: High
347
+ **Rationale**: Multi-tenant RBAC with custom permission system
348
+ ```
349
+
350
+ ## Tips for Epic Creation
351
+
352
+ 1. **Start with OVERVIEW.md** - Define clear scope boundaries
353
+ 2. **One phase per file** - Keep phase definitions modular
354
+ 3. **Explicit dependencies** - Document all cross-phase requirements
355
+ 4. **Realistic sprint sizing** - 2-5 deliverables per sprint
356
+ 5. **Validate early** - Use `--validate` during epic creation
357
+ 6. **Clear success criteria** - Define measurable phase completion criteria
@@ -42,7 +42,7 @@
42
42
  "hooks": [
43
43
  {
44
44
  "type": "command",
45
- "command": "cat | jq -r '.tool_input.command // empty' | tr '\\n' '\\0' | xargs -0 -I {} npx claude-flow-novice hooks pre-command --command '{}' --validate-safety true --prepare-resources true"
45
+ "command": "bash -c 'CMD=$(cat | jq -r \".tool_input.command // empty\"); case \"$CMD\" in *\"npx claude-flow-novice\"*|*\"hooks pre-command\"*|*\"hooks post-command\"*) echo \"[Hook] Skipping recursion: $CMD\" >&2;; *) echo \"$CMD\" | tr \"\\n\" \"\\0\" | xargs -0 -I {} npx claude-flow-novice hooks pre-command --command \"{}\" --validate-safety true --prepare-resources true;; esac'"
46
46
  }
47
47
  ]
48
48
  },
@@ -62,7 +62,7 @@
62
62
  "hooks": [
63
63
  {
64
64
  "type": "command",
65
- "command": "cat | jq -r '.tool_input.command // empty' | tr '\\n' '\\0' | xargs -0 -I {} npx claude-flow-novice hooks post-command --command '{}' --track-metrics true --store-results true"
65
+ "command": "bash -c 'CMD=$(cat | jq -r \".tool_input.command // empty\"); case \"$CMD\" in *\"npx claude-flow-novice\"*|*\"hooks pre-command\"*|*\"hooks post-command\"*) echo \"[Hook] Skipping recursion: $CMD\" >&2;; *) echo \"$CMD\" | tr \"\\n\" \"\\0\" | xargs -0 -I {} npx claude-flow-novice hooks post-command --command \"{}\" --track-metrics true --store-results true;; esac'"
66
66
  }
67
67
  ]
68
68
  },
@@ -91,7 +91,7 @@
91
91
  "hooks": [
92
92
  {
93
93
  "type": "command",
94
- "command": "/bin/bash -c 'echo \"🔄 Auto-Compact Guidance (Context Window Full):\"; echo \"📋 CRITICAL: Before compacting, ensure you understand:\"; echo \" The claude.md file of the directory you're working in\"; echo \" • Concurrent execution patterns from CLAUDE.md\"; echo \" • the CFN loop \"; echo \" • Swarm coordination strategies for complex tasks\"; echo \"⚡ Apply GOLDEN RULE: Always batch operations in single messages\"; echo \"✅ Auto-compact proceeding with full agent context\"'"
94
+ "command": "/bin/bash -c 'echo \"🔄 Auto-Compact Guidance (Context Window Full):\"; echo \"📋 CRITICAL: Before compacting, ensure you understand:\"; echo \" The claude.md file of the directory you are working in\"; echo \" • Concurrent execution patterns from CLAUDE.md\"; echo \" • the CFN loop \"; echo \" • Swarm coordination strategies for complex tasks\"; echo \"⚡ Apply GOLDEN RULE: Always batch operations in single messages\"; echo \"\"; echo \"📊 Recent Metrics Summary (Last 60 min):\"; node src/slash-commands/metrics-summary.js --minutes=60 2>/dev/null || echo \" Metrics unavailable\"; echo \"✅ Auto-compact proceeding with full agent context\"'"
95
95
  }
96
96
  ]
97
97
  }
@@ -114,6 +114,6 @@
114
114
  "n8n-mcp"
115
115
  ],
116
116
  "tieredRouting": {
117
- "enabled": false
117
+ "enabled": true
118
118
  }
119
119
  }
@@ -3,10 +3,17 @@
3
3
  "allow": [
4
4
  "mcp__ruv-swarm",
5
5
  "mcp__claude-flow@alpha",
6
- "mcp__flow-nexus"
6
+ "mcp__flow-nexus",
7
+ "WebSearch",
8
+ "Bash(npm run build:*)",
9
+ "Bash(node:*)"
7
10
  ],
8
11
  "deny": []
9
12
  },
13
+ "enableAllProjectMcpServers": true,
14
+ "enabledMcpjsonServers": [
15
+ "shadcn"
16
+ ],
10
17
  "hooks": {
11
18
  "PreToolUse": [
12
19
  {
@@ -21,4 +28,4 @@
21
28
  }
22
29
  ]
23
30
  }
24
- }
31
+ }