@dewtech/dare-cli 3.2.0 → 3.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 (839) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +764 -762
  3. package/dist/__tests__/confidence.test.js +13 -13
  4. package/dist/__tests__/dag-converter.test.js +56 -56
  5. package/dist/__tests__/dag-runner/ralph-loop.test.js +107 -45
  6. package/dist/__tests__/dag-runner/ralph-loop.test.js.map +1 -1
  7. package/dist/__tests__/dag-runner/state-store.test.d.ts +2 -0
  8. package/dist/__tests__/dag-runner/state-store.test.d.ts.map +1 -0
  9. package/dist/__tests__/dag-runner/state-store.test.js +74 -0
  10. package/dist/__tests__/dag-runner/state-store.test.js.map +1 -0
  11. package/dist/__tests__/ide-command-parity.test.js +1 -0
  12. package/dist/__tests__/ide-command-parity.test.js.map +1 -1
  13. package/dist/__tests__/mcp-server/server.test.js +3 -16
  14. package/dist/__tests__/mcp-server/server.test.js.map +1 -1
  15. package/dist/__tests__/project-generator.test.d.ts +2 -0
  16. package/dist/__tests__/project-generator.test.d.ts.map +1 -0
  17. package/dist/__tests__/project-generator.test.js +56 -0
  18. package/dist/__tests__/project-generator.test.js.map +1 -0
  19. package/dist/__tests__/refine.test.js +49 -49
  20. package/dist/__tests__/reverse-collection.test.js +6 -6
  21. package/dist/__tests__/review.test.js +38 -38
  22. package/dist/__tests__/security-hardening.test.d.ts +2 -0
  23. package/dist/__tests__/security-hardening.test.d.ts.map +1 -0
  24. package/dist/__tests__/security-hardening.test.js +101 -0
  25. package/dist/__tests__/security-hardening.test.js.map +1 -0
  26. package/dist/__tests__/validate.test.js +65 -65
  27. package/dist/bin/dare.js +2 -0
  28. package/dist/bin/dare.js.map +1 -1
  29. package/dist/commands/__tests__/bench.spec.d.ts +2 -0
  30. package/dist/commands/__tests__/bench.spec.d.ts.map +1 -0
  31. package/dist/commands/__tests__/bench.spec.js +106 -0
  32. package/dist/commands/__tests__/bench.spec.js.map +1 -0
  33. package/dist/commands/__tests__/execute.best-of.spec.d.ts +2 -0
  34. package/dist/commands/__tests__/execute.best-of.spec.d.ts.map +1 -0
  35. package/dist/commands/__tests__/execute.best-of.spec.js +24 -0
  36. package/dist/commands/__tests__/execute.best-of.spec.js.map +1 -0
  37. package/dist/commands/__tests__/execute.telemetry.spec.d.ts +2 -0
  38. package/dist/commands/__tests__/execute.telemetry.spec.d.ts.map +1 -0
  39. package/dist/commands/__tests__/execute.telemetry.spec.js +93 -0
  40. package/dist/commands/__tests__/execute.telemetry.spec.js.map +1 -0
  41. package/dist/commands/__tests__/execute.verify.spec.d.ts +2 -0
  42. package/dist/commands/__tests__/execute.verify.spec.d.ts.map +1 -0
  43. package/dist/commands/__tests__/execute.verify.spec.js +150 -0
  44. package/dist/commands/__tests__/execute.verify.spec.js.map +1 -0
  45. package/dist/commands/__tests__/init-validation.test.d.ts +2 -0
  46. package/dist/commands/__tests__/init-validation.test.d.ts.map +1 -0
  47. package/dist/commands/__tests__/init-validation.test.js +81 -0
  48. package/dist/commands/__tests__/init-validation.test.js.map +1 -0
  49. package/dist/commands/__tests__/init.integration.spec.js +6 -4
  50. package/dist/commands/__tests__/init.integration.spec.js.map +1 -1
  51. package/dist/commands/__tests__/init.spec.d.ts +2 -0
  52. package/dist/commands/__tests__/init.spec.d.ts.map +1 -0
  53. package/dist/commands/__tests__/init.spec.js +88 -0
  54. package/dist/commands/__tests__/init.spec.js.map +1 -0
  55. package/dist/commands/bench.d.ts +10 -0
  56. package/dist/commands/bench.d.ts.map +1 -0
  57. package/dist/commands/bench.js +64 -0
  58. package/dist/commands/bench.js.map +1 -0
  59. package/dist/commands/blueprint.js +122 -122
  60. package/dist/commands/design.js +20 -20
  61. package/dist/commands/execute-verification.d.ts +51 -0
  62. package/dist/commands/execute-verification.d.ts.map +1 -0
  63. package/dist/commands/execute-verification.js +201 -0
  64. package/dist/commands/execute-verification.js.map +1 -0
  65. package/dist/commands/execute.d.ts.map +1 -1
  66. package/dist/commands/execute.js +139 -2
  67. package/dist/commands/execute.js.map +1 -1
  68. package/dist/commands/init-validation.d.ts +22 -0
  69. package/dist/commands/init-validation.d.ts.map +1 -0
  70. package/dist/commands/init-validation.js +54 -0
  71. package/dist/commands/init-validation.js.map +1 -0
  72. package/dist/commands/init.d.ts.map +1 -1
  73. package/dist/commands/init.js +26 -10
  74. package/dist/commands/init.js.map +1 -1
  75. package/dist/dag-runner/ralph-loop.d.ts +9 -9
  76. package/dist/dag-runner/ralph-loop.d.ts.map +1 -1
  77. package/dist/dag-runner/ralph-loop.js +89 -113
  78. package/dist/dag-runner/ralph-loop.js.map +1 -1
  79. package/dist/dag-runner/state-store.d.ts +14 -1
  80. package/dist/dag-runner/state-store.d.ts.map +1 -1
  81. package/dist/dag-runner/state-store.js +39 -8
  82. package/dist/dag-runner/state-store.js.map +1 -1
  83. package/dist/exec/npm-invoke.d.ts +8 -0
  84. package/dist/exec/npm-invoke.d.ts.map +1 -0
  85. package/dist/exec/npm-invoke.js +45 -0
  86. package/dist/exec/npm-invoke.js.map +1 -0
  87. package/dist/exec/safe-spawn.d.ts +21 -0
  88. package/dist/exec/safe-spawn.d.ts.map +1 -0
  89. package/dist/exec/safe-spawn.js +108 -0
  90. package/dist/exec/safe-spawn.js.map +1 -0
  91. package/dist/graphrag/graph-rag.js +24 -24
  92. package/dist/graphrag/types.d.ts +2 -2
  93. package/dist/graphrag/types.d.ts.map +1 -1
  94. package/dist/mcp-server/__tests__/auth.test.d.ts +2 -0
  95. package/dist/mcp-server/__tests__/auth.test.d.ts.map +1 -0
  96. package/dist/mcp-server/__tests__/auth.test.js +72 -0
  97. package/dist/mcp-server/__tests__/auth.test.js.map +1 -0
  98. package/dist/mcp-server/__tests__/boot-config.test.d.ts +2 -0
  99. package/dist/mcp-server/__tests__/boot-config.test.d.ts.map +1 -0
  100. package/dist/mcp-server/__tests__/boot-config.test.js +29 -0
  101. package/dist/mcp-server/__tests__/boot-config.test.js.map +1 -0
  102. package/dist/mcp-server/__tests__/error-sanitize.test.d.ts +2 -0
  103. package/dist/mcp-server/__tests__/error-sanitize.test.d.ts.map +1 -0
  104. package/dist/mcp-server/__tests__/error-sanitize.test.js +66 -0
  105. package/dist/mcp-server/__tests__/error-sanitize.test.js.map +1 -0
  106. package/dist/mcp-server/__tests__/path-confinement.test.d.ts +2 -0
  107. package/dist/mcp-server/__tests__/path-confinement.test.d.ts.map +1 -0
  108. package/dist/mcp-server/__tests__/path-confinement.test.js +135 -0
  109. package/dist/mcp-server/__tests__/path-confinement.test.js.map +1 -0
  110. package/dist/mcp-server/bin/server.js +18 -6
  111. package/dist/mcp-server/bin/server.js.map +1 -1
  112. package/dist/mcp-server/boot-config.d.ts +6 -0
  113. package/dist/mcp-server/boot-config.d.ts.map +1 -0
  114. package/dist/mcp-server/boot-config.js +17 -0
  115. package/dist/mcp-server/boot-config.js.map +1 -0
  116. package/dist/mcp-server/middleware/auth.d.ts +10 -0
  117. package/dist/mcp-server/middleware/auth.d.ts.map +1 -0
  118. package/dist/mcp-server/middleware/auth.js +44 -0
  119. package/dist/mcp-server/middleware/auth.js.map +1 -0
  120. package/dist/mcp-server/middleware/cors.d.ts +6 -0
  121. package/dist/mcp-server/middleware/cors.d.ts.map +1 -0
  122. package/dist/mcp-server/middleware/cors.js +30 -0
  123. package/dist/mcp-server/middleware/cors.js.map +1 -0
  124. package/dist/mcp-server/middleware/error-handler.d.ts +11 -0
  125. package/dist/mcp-server/middleware/error-handler.d.ts.map +1 -0
  126. package/dist/mcp-server/middleware/error-handler.js +14 -0
  127. package/dist/mcp-server/middleware/error-handler.js.map +1 -0
  128. package/dist/mcp-server/server.d.ts +7 -2
  129. package/dist/mcp-server/server.d.ts.map +1 -1
  130. package/dist/mcp-server/server.js +185 -105
  131. package/dist/mcp-server/server.js.map +1 -1
  132. package/dist/skills/registry-mock.json +109 -109
  133. package/dist/skills/tests/manifest.spec.js +20 -20
  134. package/dist/stacks/__tests__/dna-emitter.spec.js +6 -6
  135. package/dist/stacks/dna-emitter.d.ts.map +1 -1
  136. package/dist/stacks/dna-emitter.js +70 -79
  137. package/dist/stacks/dna-emitter.js.map +1 -1
  138. package/dist/stacks/ruby-rails-8/scaffold.js +15 -15
  139. package/dist/utils/UpdateApplier.d.ts.map +1 -1
  140. package/dist/utils/UpdateApplier.js +8 -0
  141. package/dist/utils/UpdateApplier.js.map +1 -1
  142. package/dist/utils/logger.d.ts +7 -0
  143. package/dist/utils/logger.d.ts.map +1 -0
  144. package/dist/utils/logger.js +23 -0
  145. package/dist/utils/logger.js.map +1 -0
  146. package/dist/utils/path-safety.d.ts +22 -0
  147. package/dist/utils/path-safety.d.ts.map +1 -0
  148. package/dist/utils/path-safety.js +83 -0
  149. package/dist/utils/path-safety.js.map +1 -0
  150. package/dist/utils/project-generator.d.ts.map +1 -1
  151. package/dist/utils/project-generator.js +256 -252
  152. package/dist/utils/project-generator.js.map +1 -1
  153. package/dist/utils/stack-bootstrap.js +373 -373
  154. package/dist/utils/stack-bootstrap.js.map +1 -1
  155. package/dist/utils/templates.js +394 -394
  156. package/dist/verification/__tests__/anti-tamper.test.d.ts +2 -0
  157. package/dist/verification/__tests__/anti-tamper.test.d.ts.map +1 -0
  158. package/dist/verification/__tests__/anti-tamper.test.js +73 -0
  159. package/dist/verification/__tests__/anti-tamper.test.js.map +1 -0
  160. package/dist/verification/__tests__/bench-fixtures.test.d.ts +2 -0
  161. package/dist/verification/__tests__/bench-fixtures.test.d.ts.map +1 -0
  162. package/dist/verification/__tests__/bench-fixtures.test.js +35 -0
  163. package/dist/verification/__tests__/bench-fixtures.test.js.map +1 -0
  164. package/dist/verification/__tests__/bench-harness.test.d.ts +2 -0
  165. package/dist/verification/__tests__/bench-harness.test.d.ts.map +1 -0
  166. package/dist/verification/__tests__/bench-harness.test.js +75 -0
  167. package/dist/verification/__tests__/bench-harness.test.js.map +1 -0
  168. package/dist/verification/__tests__/bench-report.test.d.ts +2 -0
  169. package/dist/verification/__tests__/bench-report.test.d.ts.map +1 -0
  170. package/dist/verification/__tests__/bench-report.test.js +73 -0
  171. package/dist/verification/__tests__/bench-report.test.js.map +1 -0
  172. package/dist/verification/__tests__/best-of-n-runner.test.d.ts +2 -0
  173. package/dist/verification/__tests__/best-of-n-runner.test.d.ts.map +1 -0
  174. package/dist/verification/__tests__/best-of-n-runner.test.js +94 -0
  175. package/dist/verification/__tests__/best-of-n-runner.test.js.map +1 -0
  176. package/dist/verification/__tests__/config.test.d.ts +2 -0
  177. package/dist/verification/__tests__/config.test.d.ts.map +1 -0
  178. package/dist/verification/__tests__/config.test.js +50 -0
  179. package/dist/verification/__tests__/config.test.js.map +1 -0
  180. package/dist/verification/__tests__/decay-policy.test.d.ts +2 -0
  181. package/dist/verification/__tests__/decay-policy.test.d.ts.map +1 -0
  182. package/dist/verification/__tests__/decay-policy.test.js +130 -0
  183. package/dist/verification/__tests__/decay-policy.test.js.map +1 -0
  184. package/dist/verification/__tests__/fail-to-pass.test.d.ts +2 -0
  185. package/dist/verification/__tests__/fail-to-pass.test.d.ts.map +1 -0
  186. package/dist/verification/__tests__/fail-to-pass.test.js +107 -0
  187. package/dist/verification/__tests__/fail-to-pass.test.js.map +1 -0
  188. package/dist/verification/__tests__/failure-signature.test.d.ts +2 -0
  189. package/dist/verification/__tests__/failure-signature.test.d.ts.map +1 -0
  190. package/dist/verification/__tests__/failure-signature.test.js +40 -0
  191. package/dist/verification/__tests__/failure-signature.test.js.map +1 -0
  192. package/dist/verification/__tests__/logger.test.d.ts +2 -0
  193. package/dist/verification/__tests__/logger.test.d.ts.map +1 -0
  194. package/dist/verification/__tests__/logger.test.js +23 -0
  195. package/dist/verification/__tests__/logger.test.js.map +1 -0
  196. package/dist/verification/__tests__/mutation-cargo-mutants.test.d.ts +2 -0
  197. package/dist/verification/__tests__/mutation-cargo-mutants.test.d.ts.map +1 -0
  198. package/dist/verification/__tests__/mutation-cargo-mutants.test.js +96 -0
  199. package/dist/verification/__tests__/mutation-cargo-mutants.test.js.map +1 -0
  200. package/dist/verification/__tests__/mutation-infection.test.d.ts +2 -0
  201. package/dist/verification/__tests__/mutation-infection.test.d.ts.map +1 -0
  202. package/dist/verification/__tests__/mutation-infection.test.js +101 -0
  203. package/dist/verification/__tests__/mutation-infection.test.js.map +1 -0
  204. package/dist/verification/__tests__/mutation-mutmut.test.d.ts +2 -0
  205. package/dist/verification/__tests__/mutation-mutmut.test.d.ts.map +1 -0
  206. package/dist/verification/__tests__/mutation-mutmut.test.js +102 -0
  207. package/dist/verification/__tests__/mutation-mutmut.test.js.map +1 -0
  208. package/dist/verification/__tests__/mutation-registry.test.d.ts +2 -0
  209. package/dist/verification/__tests__/mutation-registry.test.d.ts.map +1 -0
  210. package/dist/verification/__tests__/mutation-registry.test.js +28 -0
  211. package/dist/verification/__tests__/mutation-registry.test.js.map +1 -0
  212. package/dist/verification/__tests__/mutation-stryker.test.d.ts +2 -0
  213. package/dist/verification/__tests__/mutation-stryker.test.d.ts.map +1 -0
  214. package/dist/verification/__tests__/mutation-stryker.test.js +88 -0
  215. package/dist/verification/__tests__/mutation-stryker.test.js.map +1 -0
  216. package/dist/verification/__tests__/no-shell-true.test.d.ts +2 -0
  217. package/dist/verification/__tests__/no-shell-true.test.d.ts.map +1 -0
  218. package/dist/verification/__tests__/no-shell-true.test.js +43 -0
  219. package/dist/verification/__tests__/no-shell-true.test.js.map +1 -0
  220. package/dist/verification/__tests__/path-safety.test.d.ts +2 -0
  221. package/dist/verification/__tests__/path-safety.test.d.ts.map +1 -0
  222. package/dist/verification/__tests__/path-safety.test.js +59 -0
  223. package/dist/verification/__tests__/path-safety.test.js.map +1 -0
  224. package/dist/verification/__tests__/prerank.test.d.ts +2 -0
  225. package/dist/verification/__tests__/prerank.test.d.ts.map +1 -0
  226. package/dist/verification/__tests__/prerank.test.js +44 -0
  227. package/dist/verification/__tests__/prerank.test.js.map +1 -0
  228. package/dist/verification/__tests__/runner.test.d.ts +2 -0
  229. package/dist/verification/__tests__/runner.test.d.ts.map +1 -0
  230. package/dist/verification/__tests__/runner.test.js +200 -0
  231. package/dist/verification/__tests__/runner.test.js.map +1 -0
  232. package/dist/verification/__tests__/safe-spawn.test.d.ts +2 -0
  233. package/dist/verification/__tests__/safe-spawn.test.d.ts.map +1 -0
  234. package/dist/verification/__tests__/safe-spawn.test.js +36 -0
  235. package/dist/verification/__tests__/safe-spawn.test.js.map +1 -0
  236. package/dist/verification/__tests__/security.test.d.ts +2 -0
  237. package/dist/verification/__tests__/security.test.d.ts.map +1 -0
  238. package/dist/verification/__tests__/security.test.js +79 -0
  239. package/dist/verification/__tests__/security.test.js.map +1 -0
  240. package/dist/verification/__tests__/selector-pareto.test.d.ts +2 -0
  241. package/dist/verification/__tests__/selector-pareto.test.d.ts.map +1 -0
  242. package/dist/verification/__tests__/selector-pareto.test.js +77 -0
  243. package/dist/verification/__tests__/selector-pareto.test.js.map +1 -0
  244. package/dist/verification/__tests__/telemetry.test.d.ts +2 -0
  245. package/dist/verification/__tests__/telemetry.test.d.ts.map +1 -0
  246. package/dist/verification/__tests__/telemetry.test.js +116 -0
  247. package/dist/verification/__tests__/telemetry.test.js.map +1 -0
  248. package/dist/verification/__tests__/type-check.test.d.ts +2 -0
  249. package/dist/verification/__tests__/type-check.test.d.ts.map +1 -0
  250. package/dist/verification/__tests__/type-check.test.js +52 -0
  251. package/dist/verification/__tests__/type-check.test.js.map +1 -0
  252. package/dist/verification/__tests__/worktree.test.d.ts +2 -0
  253. package/dist/verification/__tests__/worktree.test.d.ts.map +1 -0
  254. package/dist/verification/__tests__/worktree.test.js +41 -0
  255. package/dist/verification/__tests__/worktree.test.js.map +1 -0
  256. package/dist/verification/bench/fixtures.d.ts +11 -0
  257. package/dist/verification/bench/fixtures.d.ts.map +1 -0
  258. package/dist/verification/bench/fixtures.js +66 -0
  259. package/dist/verification/bench/fixtures.js.map +1 -0
  260. package/dist/verification/bench/harness.d.ts +19 -0
  261. package/dist/verification/bench/harness.d.ts.map +1 -0
  262. package/dist/verification/bench/harness.js +138 -0
  263. package/dist/verification/bench/harness.js.map +1 -0
  264. package/dist/verification/bench/report.d.ts +53 -0
  265. package/dist/verification/bench/report.d.ts.map +1 -0
  266. package/dist/verification/bench/report.js +47 -0
  267. package/dist/verification/bench/report.js.map +1 -0
  268. package/dist/verification/best-of-n/runner.d.ts +29 -0
  269. package/dist/verification/best-of-n/runner.d.ts.map +1 -0
  270. package/dist/verification/best-of-n/runner.js +76 -0
  271. package/dist/verification/best-of-n/runner.js.map +1 -0
  272. package/dist/verification/best-of-n/selector/pareto.d.ts +10 -0
  273. package/dist/verification/best-of-n/selector/pareto.d.ts.map +1 -0
  274. package/dist/verification/best-of-n/selector/pareto.js +65 -0
  275. package/dist/verification/best-of-n/selector/pareto.js.map +1 -0
  276. package/dist/verification/best-of-n/selector/prerank.d.ts +23 -0
  277. package/dist/verification/best-of-n/selector/prerank.d.ts.map +1 -0
  278. package/dist/verification/best-of-n/selector/prerank.js +32 -0
  279. package/dist/verification/best-of-n/selector/prerank.js.map +1 -0
  280. package/dist/verification/best-of-n/worktree.d.ts +9 -0
  281. package/dist/verification/best-of-n/worktree.d.ts.map +1 -0
  282. package/dist/verification/best-of-n/worktree.js +100 -0
  283. package/dist/verification/best-of-n/worktree.js.map +1 -0
  284. package/dist/verification/config.d.ts +24 -0
  285. package/dist/verification/config.d.ts.map +1 -0
  286. package/dist/verification/config.js +168 -0
  287. package/dist/verification/config.js.map +1 -0
  288. package/dist/verification/decay/policy.d.ts +16 -0
  289. package/dist/verification/decay/policy.d.ts.map +1 -0
  290. package/dist/verification/decay/policy.js +64 -0
  291. package/dist/verification/decay/policy.js.map +1 -0
  292. package/dist/verification/decay/signature.d.ts +6 -0
  293. package/dist/verification/decay/signature.d.ts.map +1 -0
  294. package/dist/verification/decay/signature.js +18 -0
  295. package/dist/verification/decay/signature.js.map +1 -0
  296. package/dist/verification/gates/anti-tamper.d.ts +16 -0
  297. package/dist/verification/gates/anti-tamper.d.ts.map +1 -0
  298. package/dist/verification/gates/anti-tamper.js +142 -0
  299. package/dist/verification/gates/anti-tamper.js.map +1 -0
  300. package/dist/verification/gates/fail-to-pass.d.ts +39 -0
  301. package/dist/verification/gates/fail-to-pass.d.ts.map +1 -0
  302. package/dist/verification/gates/fail-to-pass.js +173 -0
  303. package/dist/verification/gates/fail-to-pass.js.map +1 -0
  304. package/dist/verification/gates/mutation/adapter.d.ts +34 -0
  305. package/dist/verification/gates/mutation/adapter.d.ts.map +1 -0
  306. package/dist/verification/gates/mutation/adapter.js +22 -0
  307. package/dist/verification/gates/mutation/adapter.js.map +1 -0
  308. package/dist/verification/gates/mutation/cargo-mutants.d.ts +28 -0
  309. package/dist/verification/gates/mutation/cargo-mutants.d.ts.map +1 -0
  310. package/dist/verification/gates/mutation/cargo-mutants.js +170 -0
  311. package/dist/verification/gates/mutation/cargo-mutants.js.map +1 -0
  312. package/dist/verification/gates/mutation/infection.d.ts +28 -0
  313. package/dist/verification/gates/mutation/infection.d.ts.map +1 -0
  314. package/dist/verification/gates/mutation/infection.js +149 -0
  315. package/dist/verification/gates/mutation/infection.js.map +1 -0
  316. package/dist/verification/gates/mutation/mutmut.d.ts +23 -0
  317. package/dist/verification/gates/mutation/mutmut.d.ts.map +1 -0
  318. package/dist/verification/gates/mutation/mutmut.js +148 -0
  319. package/dist/verification/gates/mutation/mutmut.js.map +1 -0
  320. package/dist/verification/gates/mutation/stryker.d.ts +19 -0
  321. package/dist/verification/gates/mutation/stryker.d.ts.map +1 -0
  322. package/dist/verification/gates/mutation/stryker.js +103 -0
  323. package/dist/verification/gates/mutation/stryker.js.map +1 -0
  324. package/dist/verification/gates/type-check.d.ts +11 -0
  325. package/dist/verification/gates/type-check.d.ts.map +1 -0
  326. package/dist/verification/gates/type-check.js +84 -0
  327. package/dist/verification/gates/type-check.js.map +1 -0
  328. package/dist/verification/registry.d.ts +6 -0
  329. package/dist/verification/registry.d.ts.map +1 -0
  330. package/dist/verification/registry.js +49 -0
  331. package/dist/verification/registry.js.map +1 -0
  332. package/dist/verification/runner.d.ts +27 -0
  333. package/dist/verification/runner.d.ts.map +1 -0
  334. package/dist/verification/runner.js +173 -0
  335. package/dist/verification/runner.js.map +1 -0
  336. package/dist/verification/telemetry.d.ts +18 -0
  337. package/dist/verification/telemetry.d.ts.map +1 -0
  338. package/dist/verification/telemetry.js +71 -0
  339. package/dist/verification/telemetry.js.map +1 -0
  340. package/dist/verification/types.d.ts +89 -0
  341. package/dist/verification/types.d.ts.map +1 -0
  342. package/dist/verification/types.js +3 -0
  343. package/dist/verification/types.js.map +1 -0
  344. package/package.json +96 -91
  345. package/templates/DARE-dag-example.yaml +280 -280
  346. package/templates/UPDATE-MANIFEST.json +68 -48
  347. package/templates/backend/node-nestjs/.env.example +9 -9
  348. package/templates/backend/node-nestjs/nest-cli.json +8 -8
  349. package/templates/backend/node-nestjs/package.json +50 -50
  350. package/templates/backend/node-nestjs/src/app.controller.ts +12 -12
  351. package/templates/backend/node-nestjs/src/app.module.ts +15 -15
  352. package/templates/backend/node-nestjs/src/app.service.ts +8 -8
  353. package/templates/backend/node-nestjs/src/main.ts +24 -24
  354. package/templates/backend/node-nestjs/tsconfig.json +21 -21
  355. package/templates/backend/php-laravel/.env.example +22 -22
  356. package/templates/backend/php-laravel/app/Http/Controllers/HealthController.php +15 -15
  357. package/templates/backend/php-laravel/composer.json +40 -40
  358. package/templates/backend/python-fastapi/.env.example +4 -4
  359. package/templates/backend/python-fastapi/app/api/router.py +8 -8
  360. package/templates/backend/python-fastapi/app/core/config.py +20 -20
  361. package/templates/backend/python-fastapi/main.py +35 -35
  362. package/templates/backend/python-fastapi/requirements.txt +13 -13
  363. package/templates/backend/rust-axum/.env.example +3 -3
  364. package/templates/backend/rust-axum/Cargo.toml +23 -23
  365. package/templates/backend/rust-axum/src/errors.rs +30 -30
  366. package/templates/backend/rust-axum/src/main.rs +32 -32
  367. package/templates/backend/rust-axum/src/routes.rs +6 -6
  368. package/templates/frontend/leptos-csr/.cargo/config.toml +2 -2
  369. package/templates/frontend/leptos-csr/Cargo.toml +16 -16
  370. package/templates/frontend/leptos-csr/Trunk.toml +10 -10
  371. package/templates/frontend/leptos-csr/index.html +11 -11
  372. package/templates/frontend/leptos-csr/src/lib.rs +20 -20
  373. package/templates/frontend/leptos-csr/style/main.scss +19 -19
  374. package/templates/frontend/leptos-fullstack/.cargo/config.toml +4 -4
  375. package/templates/frontend/leptos-fullstack/Cargo.toml +56 -56
  376. package/templates/frontend/leptos-fullstack/src/app.rs +49 -49
  377. package/templates/frontend/leptos-fullstack/src/lib.rs +9 -9
  378. package/templates/frontend/leptos-fullstack/src/main.rs +29 -29
  379. package/templates/frontend/leptos-fullstack/style/main.scss +19 -19
  380. package/templates/frontend/react/index.html +12 -12
  381. package/templates/frontend/react/package.json +35 -35
  382. package/templates/frontend/react/src/App.tsx +25 -25
  383. package/templates/frontend/react/src/main.tsx +9 -9
  384. package/templates/frontend/vue/package.json +32 -32
  385. package/templates/frontend/vue/src/App.vue +7 -7
  386. package/templates/frontend/vue/src/main.ts +10 -10
  387. package/templates/frontend/vue/src/router/index.ts +14 -14
  388. package/templates/frontend/vue/src/views/HomeView.vue +6 -6
  389. package/templates/hooks/pre-commit-dare-validate +24 -24
  390. package/templates/ide/antigravity/.agents/skills/dare-ax/SKILL.md +152 -152
  391. package/templates/ide/antigravity/.agents/skills/dare-bench/SKILL.md +21 -0
  392. package/templates/ide/antigravity/.agents/skills/dare-blueprint/SKILL.md +368 -368
  393. package/templates/ide/antigravity/.agents/skills/dare-bootstrap/SKILL.md +32 -32
  394. package/templates/ide/antigravity/.agents/skills/dare-bugfix-design/SKILL.md +76 -76
  395. package/templates/ide/antigravity/.agents/skills/dare-dag/SKILL.md +32 -32
  396. package/templates/ide/antigravity/.agents/skills/dare-dag-build/SKILL.md +154 -154
  397. package/templates/ide/antigravity/.agents/skills/dare-dag-run/SKILL.md +130 -130
  398. package/templates/ide/antigravity/.agents/skills/dare-dag-runner/SKILL.md +203 -203
  399. package/templates/ide/antigravity/.agents/skills/dare-design/SKILL.md +180 -180
  400. package/templates/ide/antigravity/.agents/skills/dare-discover/SKILL.md +33 -33
  401. package/templates/ide/antigravity/.agents/skills/dare-dna/SKILL.md +63 -63
  402. package/templates/ide/antigravity/.agents/skills/dare-docker/SKILL.md +315 -315
  403. package/templates/ide/antigravity/.agents/skills/dare-execute/SKILL.md +264 -264
  404. package/templates/ide/antigravity/.agents/skills/dare-feature-design/SKILL.md +74 -74
  405. package/templates/ide/antigravity/.agents/skills/dare-frontend-design/SKILL.md +192 -192
  406. package/templates/ide/antigravity/.agents/skills/dare-graph/SKILL.md +35 -35
  407. package/templates/ide/antigravity/.agents/skills/dare-info/SKILL.md +31 -31
  408. package/templates/ide/antigravity/.agents/skills/dare-init/SKILL.md +35 -35
  409. package/templates/ide/antigravity/.agents/skills/dare-laravel-api/SKILL.md +337 -337
  410. package/templates/ide/antigravity/.agents/skills/dare-layered-design/SKILL.md +166 -166
  411. package/templates/ide/antigravity/.agents/skills/dare-llm-integration/SKILL.md +217 -217
  412. package/templates/ide/antigravity/.agents/skills/dare-migrate/SKILL.md +61 -61
  413. package/templates/ide/antigravity/.agents/skills/dare-quality-telemetry/SKILL.md +187 -187
  414. package/templates/ide/antigravity/.agents/skills/dare-realtime/SKILL.md +217 -217
  415. package/templates/ide/antigravity/.agents/skills/dare-refine/SKILL.md +114 -114
  416. package/templates/ide/antigravity/.agents/skills/dare-reverse/SKILL.md +108 -108
  417. package/templates/ide/antigravity/.agents/skills/dare-review/SKILL.md +111 -111
  418. package/templates/ide/antigravity/.agents/skills/dare-rust-leptos/SKILL.md +263 -263
  419. package/templates/ide/antigravity/.agents/skills/dare-rust-workspace/SKILL.md +275 -275
  420. package/templates/ide/antigravity/.agents/skills/dare-security/SKILL.md +274 -274
  421. package/templates/ide/antigravity/.agents/skills/dare-skill/SKILL.md +35 -35
  422. package/templates/ide/antigravity/.agents/skills/dare-tasks/SKILL.md +265 -265
  423. package/templates/ide/antigravity/.agents/skills/dare-telemetry/SKILL.md +188 -188
  424. package/templates/ide/antigravity/.agents/skills/dare-update/SKILL.md +33 -33
  425. package/templates/ide/antigravity/.agents/skills/dare-validate/SKILL.md +33 -33
  426. package/templates/ide/antigravity/.agents/skills/dare-welcome/SKILL.md +30 -30
  427. package/templates/ide/antigravity/.agents/skills/skill-fastapi-api/SKILL.md +343 -343
  428. package/templates/ide/antigravity/.agents/skills/skill-go-gin-api/SKILL.md +377 -377
  429. package/templates/ide/antigravity/.agents/skills/skill-mcp-server/SKILL.md +382 -382
  430. package/templates/ide/antigravity/.agents/skills/skill-nestjs-api/SKILL.md +326 -326
  431. package/templates/ide/antigravity/.agents/skills/skill-rails-api/SKILL.md +393 -393
  432. package/templates/ide/antigravity/templates/BLUEPRINT-template.md +193 -193
  433. package/templates/ide/antigravity/templates/DESIGN-template.md +129 -129
  434. package/templates/ide/antigravity/templates/TASK-SPEC-template.md +141 -141
  435. package/templates/ide/antigravity/templates/TASKS-template.md +26 -26
  436. package/templates/ide/antigravity/templates/TELEMETRY-template.md +125 -125
  437. package/templates/ide/claude/.claude/commands/dare-ax.md +131 -131
  438. package/templates/ide/claude/.claude/commands/dare-bench.md +18 -0
  439. package/templates/ide/claude/.claude/commands/dare-blueprint.md +134 -134
  440. package/templates/ide/claude/.claude/commands/dare-bootstrap.md +27 -27
  441. package/templates/ide/claude/.claude/commands/dare-bugfix-design.md +119 -119
  442. package/templates/ide/claude/.claude/commands/dare-dag-build.md +151 -151
  443. package/templates/ide/claude/.claude/commands/dare-dag-run.md +109 -109
  444. package/templates/ide/claude/.claude/commands/dare-dag-runner.md +117 -117
  445. package/templates/ide/claude/.claude/commands/dare-dag-viz.md +197 -197
  446. package/templates/ide/claude/.claude/commands/dare-dag.md +27 -27
  447. package/templates/ide/claude/.claude/commands/dare-design.md +69 -69
  448. package/templates/ide/claude/.claude/commands/dare-discover.md +28 -28
  449. package/templates/ide/claude/.claude/commands/dare-dna.md +75 -75
  450. package/templates/ide/claude/.claude/commands/dare-docker.md +207 -207
  451. package/templates/ide/claude/.claude/commands/dare-execute.md +152 -152
  452. package/templates/ide/claude/.claude/commands/dare-feature-design.md +147 -147
  453. package/templates/ide/claude/.claude/commands/dare-frontend-design.md +149 -149
  454. package/templates/ide/claude/.claude/commands/dare-graph.md +30 -30
  455. package/templates/ide/claude/.claude/commands/dare-info.md +26 -26
  456. package/templates/ide/claude/.claude/commands/dare-init.md +30 -30
  457. package/templates/ide/claude/.claude/commands/dare-laravel-api.md +211 -211
  458. package/templates/ide/claude/.claude/commands/dare-layered-design.md +124 -124
  459. package/templates/ide/claude/.claude/commands/dare-llm-integration.md +148 -148
  460. package/templates/ide/claude/.claude/commands/dare-migrate.md +72 -72
  461. package/templates/ide/claude/.claude/commands/dare-quality-telemetry.md +166 -166
  462. package/templates/ide/claude/.claude/commands/dare-realtime.md +159 -159
  463. package/templates/ide/claude/.claude/commands/dare-refine.md +145 -145
  464. package/templates/ide/claude/.claude/commands/dare-reverse.md +139 -139
  465. package/templates/ide/claude/.claude/commands/dare-review.md +113 -113
  466. package/templates/ide/claude/.claude/commands/dare-rust-leptos.md +269 -269
  467. package/templates/ide/claude/.claude/commands/dare-rust-workspace.md +209 -209
  468. package/templates/ide/claude/.claude/commands/dare-security.md +232 -232
  469. package/templates/ide/claude/.claude/commands/dare-skill.md +30 -30
  470. package/templates/ide/claude/.claude/commands/dare-tasks.md +70 -70
  471. package/templates/ide/claude/.claude/commands/dare-telemetry.md +132 -132
  472. package/templates/ide/claude/.claude/commands/dare-update.md +28 -28
  473. package/templates/ide/claude/.claude/commands/dare-validate.md +28 -28
  474. package/templates/ide/claude/.claude/commands/dare-welcome.md +25 -25
  475. package/templates/ide/claude/.claude/commands/skill-fastapi-api.md +205 -205
  476. package/templates/ide/claude/.claude/commands/skill-go-gin-api.md +232 -232
  477. package/templates/ide/claude/.claude/commands/skill-mcp-server.md +228 -228
  478. package/templates/ide/claude/.claude/commands/skill-nestjs-api.md +210 -210
  479. package/templates/ide/claude/.claude/commands/skill-rails-api.md +236 -236
  480. package/templates/ide/claude/.claude/settings.example.json +35 -35
  481. package/templates/ide/claude/CLAUDE.md +146 -146
  482. package/templates/ide/claude/templates/BLUEPRINT-template.md +193 -193
  483. package/templates/ide/claude/templates/DESIGN-template.md +129 -129
  484. package/templates/ide/claude/templates/TASK-SPEC-template.md +141 -141
  485. package/templates/ide/claude/templates/TASKS-template.md +26 -26
  486. package/templates/ide/claude/templates/TELEMETRY-template.md +125 -125
  487. package/templates/ide/cursor/.cursor/commands/dare-bench.md +18 -0
  488. package/templates/ide/cursor/.cursor/commands/dare-blueprint.md +86 -86
  489. package/templates/ide/cursor/.cursor/commands/dare-bootstrap.md +27 -27
  490. package/templates/ide/cursor/.cursor/commands/dare-bugfix-design.md +64 -64
  491. package/templates/ide/cursor/.cursor/commands/dare-dag-run.md +110 -110
  492. package/templates/ide/cursor/.cursor/commands/dare-dag-viz.md +139 -139
  493. package/templates/ide/cursor/.cursor/commands/dare-dag.md +27 -27
  494. package/templates/ide/cursor/.cursor/commands/dare-design.md +35 -35
  495. package/templates/ide/cursor/.cursor/commands/dare-discover.md +28 -28
  496. package/templates/ide/cursor/.cursor/commands/dare-dna.md +75 -75
  497. package/templates/ide/cursor/.cursor/commands/dare-docker-compose.md +18 -18
  498. package/templates/ide/cursor/.cursor/commands/dare-dockerfile.md +17 -17
  499. package/templates/ide/cursor/.cursor/commands/dare-execute.md +19 -19
  500. package/templates/ide/cursor/.cursor/commands/dare-feature-design.md +64 -64
  501. package/templates/ide/cursor/.cursor/commands/dare-graph.md +30 -30
  502. package/templates/ide/cursor/.cursor/commands/dare-info.md +26 -26
  503. package/templates/ide/cursor/.cursor/commands/dare-init.md +30 -30
  504. package/templates/ide/cursor/.cursor/commands/dare-migrate.md +72 -72
  505. package/templates/ide/cursor/.cursor/commands/dare-refine.md +107 -107
  506. package/templates/ide/cursor/.cursor/commands/dare-reverse.md +139 -139
  507. package/templates/ide/cursor/.cursor/commands/dare-review.md +91 -91
  508. package/templates/ide/cursor/.cursor/commands/dare-skill.md +30 -30
  509. package/templates/ide/cursor/.cursor/commands/dare-tasks.md +184 -184
  510. package/templates/ide/cursor/.cursor/commands/dare-telemetry.md +42 -42
  511. package/templates/ide/cursor/.cursor/commands/dare-update.md +28 -28
  512. package/templates/ide/cursor/.cursor/commands/dare-validate.md +28 -28
  513. package/templates/ide/cursor/.cursor/commands/dare-welcome.md +25 -25
  514. package/templates/ide/cursor/.cursor/rules/skill-ax.mdc +263 -263
  515. package/templates/ide/cursor/.cursor/rules/skill-bugfix-design.mdc +51 -51
  516. package/templates/ide/cursor/.cursor/rules/skill-dag-build.mdc +173 -173
  517. package/templates/ide/cursor/.cursor/rules/skill-dag-run.mdc +134 -134
  518. package/templates/ide/cursor/.cursor/rules/skill-dag-runner.mdc +221 -221
  519. package/templates/ide/cursor/.cursor/rules/skill-dna.mdc +63 -63
  520. package/templates/ide/cursor/.cursor/rules/skill-docker.mdc +33 -33
  521. package/templates/ide/cursor/.cursor/rules/skill-fastapi-api.mdc +352 -352
  522. package/templates/ide/cursor/.cursor/rules/skill-feature-design.mdc +43 -43
  523. package/templates/ide/cursor/.cursor/rules/skill-frontend-design.mdc +244 -244
  524. package/templates/ide/cursor/.cursor/rules/skill-go-gin-api.mdc +371 -371
  525. package/templates/ide/cursor/.cursor/rules/skill-laravel-api.mdc +44 -44
  526. package/templates/ide/cursor/.cursor/rules/skill-layered-design.mdc +266 -266
  527. package/templates/ide/cursor/.cursor/rules/skill-llm-integration.mdc +295 -295
  528. package/templates/ide/cursor/.cursor/rules/skill-mcp-server.mdc +367 -367
  529. package/templates/ide/cursor/.cursor/rules/skill-migrate.mdc +58 -58
  530. package/templates/ide/cursor/.cursor/rules/skill-nestjs-api.mdc +346 -346
  531. package/templates/ide/cursor/.cursor/rules/skill-quality-telemetry.mdc +248 -248
  532. package/templates/ide/cursor/.cursor/rules/skill-rails-api.mdc +400 -400
  533. package/templates/ide/cursor/.cursor/rules/skill-realtime.mdc +262 -262
  534. package/templates/ide/cursor/.cursor/rules/skill-reverse.mdc +107 -107
  535. package/templates/ide/cursor/.cursor/rules/skill-rust-leptos.mdc +281 -281
  536. package/templates/ide/cursor/.cursor/rules/skill-rust-workspace.mdc +312 -312
  537. package/templates/ide/cursor/.cursor/rules/skill-security.mdc +245 -245
  538. package/templates/ide/cursor/.cursor/rules/skill-telemetry.mdc +156 -156
  539. package/templates/ide/cursor/templates/BLUEPRINT-template.md +193 -193
  540. package/templates/ide/cursor/templates/DESIGN-template.md +129 -129
  541. package/templates/ide/cursor/templates/TASK-SPEC-template.md +141 -141
  542. package/templates/ide/cursor/templates/TASKS-template.md +26 -26
  543. package/templates/ide/cursor/templates/TELEMETRY-template.md +125 -125
  544. package/templates/shared/docker-compose.yml +41 -41
  545. package/templates/stacks/go-gin/.dare/skills.yml +11 -11
  546. package/templates/stacks/go-gin/.env.example +24 -24
  547. package/templates/stacks/go-gin/.github/workflows/dare-ci.yml +42 -42
  548. package/templates/stacks/go-gin/README.md.tpl +38 -38
  549. package/templates/stacks/go-gin/cmd/server/main.go.tpl +78 -78
  550. package/templates/stacks/go-gin/db/migrations/0001_create_users.down.sql +2 -2
  551. package/templates/stacks/go-gin/db/migrations/0001_create_users.up.sql +12 -12
  552. package/templates/stacks/go-gin/db/queries/users.sql +23 -23
  553. package/templates/stacks/go-gin/gitignore +7 -7
  554. package/templates/stacks/go-gin/go.mod.tpl +17 -17
  555. package/templates/stacks/go-gin/internal/config/config.go +41 -41
  556. package/templates/stacks/go-gin/internal/db/postgres.go.tpl +25 -25
  557. package/templates/stacks/go-gin/internal/handler/auth_handler.go.tpl +72 -72
  558. package/templates/stacks/go-gin/internal/handler/users_handler.go.tpl +72 -72
  559. package/templates/stacks/go-gin/internal/handler/ws_handler.go +37 -37
  560. package/templates/stacks/go-gin/internal/llm/dummy.go +14 -14
  561. package/templates/stacks/go-gin/internal/llm/provider.go +8 -8
  562. package/templates/stacks/go-gin/internal/middleware/jwt.go.tpl +58 -58
  563. package/templates/stacks/go-gin/internal/middleware/rate_limit.go +55 -55
  564. package/templates/stacks/go-gin/internal/model/user.go +17 -17
  565. package/templates/stacks/go-gin/internal/repository/users_repository.go.tpl +79 -79
  566. package/templates/stacks/go-gin/internal/service/auth_service.go.tpl +55 -55
  567. package/templates/stacks/go-gin/internal/service/users_service.go.tpl +53 -53
  568. package/templates/stacks/go-gin/llms.txt.tpl +54 -54
  569. package/templates/stacks/go-gin/openapi.json.tpl +46 -46
  570. package/templates/stacks/go-gin/sqlc.yaml +14 -14
  571. package/templates/stacks/go-gin/tests/smoke_test.go.tpl +22 -22
  572. package/templates/stacks/go-stdlib/.dare/skills.yml +11 -11
  573. package/templates/stacks/go-stdlib/.env.example +24 -24
  574. package/templates/stacks/go-stdlib/.github/workflows/dare-ci.yml +42 -42
  575. package/templates/stacks/go-stdlib/README.md.tpl +41 -41
  576. package/templates/stacks/go-stdlib/cmd/server/main.go.tpl +82 -82
  577. package/templates/stacks/go-stdlib/db/migrations/0001_create_users.down.sql +2 -2
  578. package/templates/stacks/go-stdlib/db/migrations/0001_create_users.up.sql +12 -12
  579. package/templates/stacks/go-stdlib/db/queries/users.sql +23 -23
  580. package/templates/stacks/go-stdlib/gitignore +6 -6
  581. package/templates/stacks/go-stdlib/go.mod.tpl +15 -15
  582. package/templates/stacks/go-stdlib/internal/config/config.go +41 -41
  583. package/templates/stacks/go-stdlib/internal/db/postgres.go.tpl +24 -24
  584. package/templates/stacks/go-stdlib/internal/handler/auth_handler.go.tpl +71 -71
  585. package/templates/stacks/go-stdlib/internal/handler/users_handler.go.tpl +84 -84
  586. package/templates/stacks/go-stdlib/internal/handler/ws_handler.go +36 -36
  587. package/templates/stacks/go-stdlib/internal/httpx/json.go +32 -32
  588. package/templates/stacks/go-stdlib/internal/llm/dummy.go +14 -14
  589. package/templates/stacks/go-stdlib/internal/llm/provider.go +8 -8
  590. package/templates/stacks/go-stdlib/internal/middleware/chain.go +21 -21
  591. package/templates/stacks/go-stdlib/internal/middleware/cors.go +27 -27
  592. package/templates/stacks/go-stdlib/internal/middleware/jwt.go.tpl +51 -51
  593. package/templates/stacks/go-stdlib/internal/middleware/rate_limit.go +81 -81
  594. package/templates/stacks/go-stdlib/internal/model/user.go +17 -17
  595. package/templates/stacks/go-stdlib/internal/repository/users_repository.go.tpl +75 -75
  596. package/templates/stacks/go-stdlib/internal/service/auth_service.go.tpl +55 -55
  597. package/templates/stacks/go-stdlib/internal/service/users_service.go.tpl +53 -53
  598. package/templates/stacks/go-stdlib/llms.txt.tpl +60 -60
  599. package/templates/stacks/go-stdlib/openapi.json.tpl +46 -46
  600. package/templates/stacks/go-stdlib/sqlc.yaml +14 -14
  601. package/templates/stacks/go-stdlib/tests/smoke_test.go.tpl +45 -45
  602. package/templates/stacks/mcp-go/.dare/skills.yml +8 -8
  603. package/templates/stacks/mcp-go/.env.example +14 -14
  604. package/templates/stacks/mcp-go/.github/workflows/dare-ci.yml +42 -42
  605. package/templates/stacks/mcp-go/README.md.tpl +50 -50
  606. package/templates/stacks/mcp-go/cmd/server/main.go.tpl +62 -62
  607. package/templates/stacks/mcp-go/gitignore +6 -6
  608. package/templates/stacks/mcp-go/go.mod.tpl +9 -9
  609. package/templates/stacks/mcp-go/internal/prompts/summarize.go +9 -9
  610. package/templates/stacks/mcp-go/internal/server/server.go.tpl +80 -80
  611. package/templates/stacks/mcp-go/internal/tools/echo.go +15 -15
  612. package/templates/stacks/mcp-go/internal/transports/http.go.tpl +21 -21
  613. package/templates/stacks/mcp-go/internal/transports/sse.go.tpl +17 -17
  614. package/templates/stacks/mcp-go/internal/transports/stdio.go.tpl +14 -14
  615. package/templates/stacks/mcp-go/llms.txt.tpl +60 -60
  616. package/templates/stacks/mcp-go/openapi.json.tpl +31 -31
  617. package/templates/stacks/mcp-go/tests/echo_test.go.tpl +37 -37
  618. package/templates/stacks/mcp-node-ts/.dare/skills.yml +8 -8
  619. package/templates/stacks/mcp-node-ts/.env.example +16 -16
  620. package/templates/stacks/mcp-node-ts/.github/workflows/dare-ci.yml +54 -54
  621. package/templates/stacks/mcp-node-ts/README.md.hbs +49 -49
  622. package/templates/stacks/mcp-node-ts/gitignore +7 -7
  623. package/templates/stacks/mcp-node-ts/llms.txt.hbs +61 -61
  624. package/templates/stacks/mcp-node-ts/openapi.json.hbs +39 -39
  625. package/templates/stacks/mcp-node-ts/package.json.hbs +35 -35
  626. package/templates/stacks/mcp-node-ts/src/cli.ts.hbs +71 -71
  627. package/templates/stacks/mcp-node-ts/src/prompts/index.ts +36 -36
  628. package/templates/stacks/mcp-node-ts/src/server.ts.hbs +45 -45
  629. package/templates/stacks/mcp-node-ts/src/tools/echo.ts +23 -23
  630. package/templates/stacks/mcp-node-ts/src/tools/index.ts +18 -18
  631. package/templates/stacks/mcp-node-ts/src/transports/http.ts +68 -68
  632. package/templates/stacks/mcp-node-ts/src/transports/sse.ts +58 -58
  633. package/templates/stacks/mcp-node-ts/src/transports/stdio.ts +5 -5
  634. package/templates/stacks/mcp-node-ts/tests/echo.test.ts +50 -50
  635. package/templates/stacks/mcp-node-ts/tsconfig.json +17 -17
  636. package/templates/stacks/mcp-python/.dare/skills.yml +8 -8
  637. package/templates/stacks/mcp-python/.env.example +14 -14
  638. package/templates/stacks/mcp-python/.github/workflows/dare-ci.yml +42 -42
  639. package/templates/stacks/mcp-python/README.md.j2 +49 -49
  640. package/templates/stacks/mcp-python/gitignore +12 -12
  641. package/templates/stacks/mcp-python/llms.txt.j2 +56 -56
  642. package/templates/stacks/mcp-python/openapi.json.j2 +33 -33
  643. package/templates/stacks/mcp-python/pyproject.toml.j2 +37 -37
  644. package/templates/stacks/mcp-python/src/cli.py.j2 +68 -68
  645. package/templates/stacks/mcp-python/src/prompts/summarize.py +10 -10
  646. package/templates/stacks/mcp-python/src/server.py.j2 +28 -28
  647. package/templates/stacks/mcp-python/src/tools/echo.py +12 -12
  648. package/templates/stacks/mcp-python/src/transports/http.py +12 -12
  649. package/templates/stacks/mcp-python/src/transports/sse.py +13 -13
  650. package/templates/stacks/mcp-python/src/transports/stdio.py +6 -6
  651. package/templates/stacks/mcp-python/tests/test_echo.py +28 -28
  652. package/templates/stacks/mcp-rust/.dare/skills.yml +8 -8
  653. package/templates/stacks/mcp-rust/.env.example +14 -14
  654. package/templates/stacks/mcp-rust/.github/workflows/dare-ci.yml +38 -38
  655. package/templates/stacks/mcp-rust/Cargo.toml.tera +35 -35
  656. package/templates/stacks/mcp-rust/README.md.tera +50 -50
  657. package/templates/stacks/mcp-rust/gitignore +5 -5
  658. package/templates/stacks/mcp-rust/llms.txt.tera +60 -60
  659. package/templates/stacks/mcp-rust/openapi.json.tera +31 -31
  660. package/templates/stacks/mcp-rust/src/cli.rs.tera +33 -33
  661. package/templates/stacks/mcp-rust/src/lib.rs +6 -6
  662. package/templates/stacks/mcp-rust/src/main.rs.tera +30 -30
  663. package/templates/stacks/mcp-rust/src/prompts/mod.rs +1 -1
  664. package/templates/stacks/mcp-rust/src/prompts/summarize.rs +5 -5
  665. package/templates/stacks/mcp-rust/src/server.rs.tera +38 -38
  666. package/templates/stacks/mcp-rust/src/tools/echo.rs +18 -18
  667. package/templates/stacks/mcp-rust/src/tools/mod.rs +22 -22
  668. package/templates/stacks/mcp-rust/src/transports/http.rs +27 -27
  669. package/templates/stacks/mcp-rust/src/transports/mod.rs +3 -3
  670. package/templates/stacks/mcp-rust/src/transports/sse.rs +33 -33
  671. package/templates/stacks/mcp-rust/src/transports/stdio.rs +14 -14
  672. package/templates/stacks/mcp-rust/tests/echo_test.rs.tera +27 -27
  673. package/templates/stacks/node-nestjs/.dare/skills.yml +11 -11
  674. package/templates/stacks/node-nestjs/.env.example +21 -21
  675. package/templates/stacks/node-nestjs/.github/workflows/dare-ci.yml +54 -54
  676. package/templates/stacks/node-nestjs/README.md.hbs +35 -35
  677. package/templates/stacks/node-nestjs/gitignore +7 -7
  678. package/templates/stacks/node-nestjs/llms.txt.hbs +47 -47
  679. package/templates/stacks/node-nestjs/nest-cli.json +16 -16
  680. package/templates/stacks/node-nestjs/openapi.json.hbs +75 -75
  681. package/templates/stacks/node-nestjs/package.json.hbs +57 -57
  682. package/templates/stacks/node-nestjs/prisma/schema.prisma +25 -25
  683. package/templates/stacks/node-nestjs/prisma/seed.ts.hbs +25 -25
  684. package/templates/stacks/node-nestjs/src/app.module.ts +39 -39
  685. package/templates/stacks/node-nestjs/src/auth/auth.controller.ts +29 -29
  686. package/templates/stacks/node-nestjs/src/auth/auth.module.ts +25 -25
  687. package/templates/stacks/node-nestjs/src/auth/auth.service.ts +36 -36
  688. package/templates/stacks/node-nestjs/src/auth/dto/login-response.dto.ts +9 -9
  689. package/templates/stacks/node-nestjs/src/auth/dto/login.dto.ts +17 -17
  690. package/templates/stacks/node-nestjs/src/auth/jwt.strategy.ts +25 -25
  691. package/templates/stacks/node-nestjs/src/common/filters/problem-details.filter.ts +38 -38
  692. package/templates/stacks/node-nestjs/src/common/interceptors/json-response.interceptor.ts +13 -13
  693. package/templates/stacks/node-nestjs/src/main.ts.hbs +44 -44
  694. package/templates/stacks/node-nestjs/src/prisma/prisma.module.ts +9 -9
  695. package/templates/stacks/node-nestjs/src/prisma/prisma.service.ts +9 -9
  696. package/templates/stacks/node-nestjs/src/users/dto/create-user.dto.ts +22 -22
  697. package/templates/stacks/node-nestjs/src/users/dto/user.dto.ts +15 -15
  698. package/templates/stacks/node-nestjs/src/users/users.controller.ts +41 -41
  699. package/templates/stacks/node-nestjs/src/users/users.module.ts +11 -11
  700. package/templates/stacks/node-nestjs/src/users/users.repository.ts +38 -38
  701. package/templates/stacks/node-nestjs/src/users/users.service.ts +38 -38
  702. package/templates/stacks/node-nestjs/tsconfig.build.json +4 -4
  703. package/templates/stacks/node-nestjs/tsconfig.json +28 -28
  704. package/templates/stacks/php-laravel/.dare/skills.yml +11 -11
  705. package/templates/stacks/php-laravel/.env.example +41 -41
  706. package/templates/stacks/php-laravel/.github/workflows/dare-ci.yml +43 -43
  707. package/templates/stacks/php-laravel/README.md.hbs +36 -36
  708. package/templates/stacks/php-laravel/app/Http/Controllers/Api/AuthController.php +36 -36
  709. package/templates/stacks/php-laravel/app/Http/Controllers/Api/UsersController.php +33 -33
  710. package/templates/stacks/php-laravel/app/Http/Requests/CreateUserRequest.php +26 -26
  711. package/templates/stacks/php-laravel/app/Http/Requests/LoginRequest.php +34 -34
  712. package/templates/stacks/php-laravel/app/Llm/Contracts/LlmProvider.php +12 -12
  713. package/templates/stacks/php-laravel/app/Llm/Providers/DummyProvider.php +13 -13
  714. package/templates/stacks/php-laravel/app/Llm/Providers/OpenAiProvider.php +33 -33
  715. package/templates/stacks/php-laravel/app/Models/User.php +44 -44
  716. package/templates/stacks/php-laravel/app/Repositories/UsersRepository.php +32 -32
  717. package/templates/stacks/php-laravel/app/Services/AuthService.php +37 -37
  718. package/templates/stacks/php-laravel/app/Services/UsersService.php +57 -57
  719. package/templates/stacks/php-laravel/artisan +12 -12
  720. package/templates/stacks/php-laravel/bootstrap/app.php +29 -29
  721. package/templates/stacks/php-laravel/bootstrap/providers.php +5 -5
  722. package/templates/stacks/php-laravel/composer.json.hbs +58 -58
  723. package/templates/stacks/php-laravel/config/l5-swagger.php +41 -41
  724. package/templates/stacks/php-laravel/config/reverb.php +34 -34
  725. package/templates/stacks/php-laravel/config/sanctum.php +15 -15
  726. package/templates/stacks/php-laravel/database/migrations/2026_06_01_000001_create_users_table.php +27 -27
  727. package/templates/stacks/php-laravel/database/seeders/DatabaseSeeder.php +21 -21
  728. package/templates/stacks/php-laravel/gitignore +23 -23
  729. package/templates/stacks/php-laravel/llms.txt.hbs +53 -53
  730. package/templates/stacks/php-laravel/openapi.json.hbs +43 -43
  731. package/templates/stacks/php-laravel/phpstan.neon +9 -9
  732. package/templates/stacks/php-laravel/routes/api.php +13 -13
  733. package/templates/stacks/php-laravel/routes/channels.php +7 -7
  734. package/templates/stacks/php-laravel/tests/Feature/AuthTest.php +35 -35
  735. package/templates/stacks/php-laravel/tests/Feature/UsersTest.php +30 -30
  736. package/templates/stacks/php-laravel/tests/Pest.php +5 -5
  737. package/templates/stacks/python-fastapi/.dare/skills.yml +11 -11
  738. package/templates/stacks/python-fastapi/.env.example +21 -21
  739. package/templates/stacks/python-fastapi/.github/workflows/dare-ci.yml +43 -43
  740. package/templates/stacks/python-fastapi/README.md.j2 +35 -35
  741. package/templates/stacks/python-fastapi/alembic/env.py +46 -46
  742. package/templates/stacks/python-fastapi/alembic/script.py.mako +26 -26
  743. package/templates/stacks/python-fastapi/alembic/versions/0001_create_users.py.j2 +37 -37
  744. package/templates/stacks/python-fastapi/alembic.ini.j2 +39 -39
  745. package/templates/stacks/python-fastapi/app/core/config.py +24 -24
  746. package/templates/stacks/python-fastapi/app/core/security.py +34 -34
  747. package/templates/stacks/python-fastapi/app/db/session.py +22 -22
  748. package/templates/stacks/python-fastapi/app/main.py.j2 +36 -36
  749. package/templates/stacks/python-fastapi/app/models/__init__.py +3 -3
  750. package/templates/stacks/python-fastapi/app/models/user.py +30 -30
  751. package/templates/stacks/python-fastapi/app/repositories/user_repository.py +34 -34
  752. package/templates/stacks/python-fastapi/app/routers/auth.py +37 -37
  753. package/templates/stacks/python-fastapi/app/routers/users.py +46 -46
  754. package/templates/stacks/python-fastapi/app/schemas/user.py +56 -56
  755. package/templates/stacks/python-fastapi/app/services/auth_service.py +22 -22
  756. package/templates/stacks/python-fastapi/app/services/user_service.py +31 -31
  757. package/templates/stacks/python-fastapi/gitignore +12 -12
  758. package/templates/stacks/python-fastapi/llms.txt.j2 +53 -53
  759. package/templates/stacks/python-fastapi/openapi.json.j2 +43 -43
  760. package/templates/stacks/python-fastapi/pyproject.toml.j2 +45 -45
  761. package/templates/stacks/python-fastapi/tests/test_auth.py +22 -22
  762. package/templates/stacks/ruby-rails-8/.dare/skills.yml +50 -50
  763. package/templates/stacks/ruby-rails-8/.env.example +20 -20
  764. package/templates/stacks/ruby-rails-8/.github/workflows/dare-ci.yml +112 -112
  765. package/templates/stacks/ruby-rails-8/Gemfile.erb +61 -61
  766. package/templates/stacks/ruby-rails-8/app/channels/application_cable/channel.rb +11 -11
  767. package/templates/stacks/ruby-rails-8/app/channels/application_cable/connection.rb +34 -34
  768. package/templates/stacks/ruby-rails-8/app/channels/dare_updates_channel.rb +18 -18
  769. package/templates/stacks/ruby-rails-8/app/channels/user_updates_channel.rb +23 -23
  770. package/templates/stacks/ruby-rails-8/app/controllers/application_controller.rb +44 -44
  771. package/templates/stacks/ruby-rails-8/app/controllers/concerns/problem_details.rb +93 -93
  772. package/templates/stacks/ruby-rails-8/app/handlers/summarize_handler.rb +33 -33
  773. package/templates/stacks/ruby-rails-8/app/handlers/users_handler.rb +68 -68
  774. package/templates/stacks/ruby-rails-8/app/llm/cache/llm_cache.rb +44 -44
  775. package/templates/stacks/ruby-rails-8/app/llm/prompts/prompt_loader.rb +54 -54
  776. package/templates/stacks/ruby-rails-8/app/llm/prompts/summarize_v1.jinja2 +12 -12
  777. package/templates/stacks/ruby-rails-8/app/llm/providers/dummy_provider.rb +35 -35
  778. package/templates/stacks/ruby-rails-8/app/llm/providers/llm_provider.rb +67 -67
  779. package/templates/stacks/ruby-rails-8/app/llm/providers/openai_provider.rb +62 -62
  780. package/templates/stacks/ruby-rails-8/app/llm/rate_limit/token_bucket.rb +82 -82
  781. package/templates/stacks/ruby-rails-8/app/llm/validators/summarize_output_schema.json +21 -21
  782. package/templates/stacks/ruby-rails-8/app/llm/validators/validator.rb +52 -52
  783. package/templates/stacks/ruby-rails-8/app/models/user.rb +36 -36
  784. package/templates/stacks/ruby-rails-8/app/presenters/user_presenter.rb +48 -48
  785. package/templates/stacks/ruby-rails-8/app/repositories/document_repository.rb +57 -57
  786. package/templates/stacks/ruby-rails-8/app/repositories/user_repository.rb +73 -73
  787. package/templates/stacks/ruby-rails-8/app/services/create_user_service.rb +67 -67
  788. package/templates/stacks/ruby-rails-8/app/services/realtime_service.rb +53 -53
  789. package/templates/stacks/ruby-rails-8/app/services/summarize_document_service.rb +57 -57
  790. package/templates/stacks/ruby-rails-8/config/dare.yml +42 -42
  791. package/templates/stacks/ruby-rails-8/config/initializers/dare.rb +31 -31
  792. package/templates/stacks/ruby-rails-8/config/initializers/rack_attack.rb +64 -64
  793. package/templates/stacks/ruby-rails-8/config/initializers/rswag_api.rb +12 -12
  794. package/templates/stacks/ruby-rails-8/lib/tasks/dare.rake +159 -159
  795. package/templates/stacks/ruby-rails-8/llms.txt.erb +69 -69
  796. package/templates/stacks/ruby-rails-8/spec/api/summarize_spec.rb +56 -56
  797. package/templates/stacks/ruby-rails-8/spec/api/users_spec.rb +72 -72
  798. package/templates/stacks/ruby-rails-8/spec/channels/dare_updates_channel_spec.rb +61 -61
  799. package/templates/stacks/ruby-rails-8/spec/channels/user_updates_channel_spec.rb +56 -56
  800. package/templates/stacks/ruby-rails-8/spec/factories/users.rb +27 -27
  801. package/templates/stacks/ruby-rails-8/spec/handlers/users_handler_spec.rb +88 -88
  802. package/templates/stacks/ruby-rails-8/spec/rails_helper.rb +31 -31
  803. package/templates/stacks/ruby-rails-8/spec/services/create_user_service_spec.rb +88 -88
  804. package/templates/stacks/ruby-rails-8/spec/services/summarize_document_service_spec.rb +142 -142
  805. package/templates/stacks/ruby-rails-8/spec/swagger_helper.rb +73 -73
  806. package/templates/stacks/rust-axum/.dare/skills.yml +11 -11
  807. package/templates/stacks/rust-axum/.env.example +26 -26
  808. package/templates/stacks/rust-axum/.github/workflows/dare-ci.yml +40 -40
  809. package/templates/stacks/rust-axum/Cargo.toml.tera +53 -53
  810. package/templates/stacks/rust-axum/README.md.tera +37 -37
  811. package/templates/stacks/rust-axum/gitignore +5 -5
  812. package/templates/stacks/rust-axum/llms.txt.tera +54 -54
  813. package/templates/stacks/rust-axum/migrations/0001_create_users.sql +13 -13
  814. package/templates/stacks/rust-axum/openapi.json.tera +46 -46
  815. package/templates/stacks/rust-axum/src/config.rs +45 -45
  816. package/templates/stacks/rust-axum/src/errors.rs +48 -48
  817. package/templates/stacks/rust-axum/src/handlers/auth.rs +48 -48
  818. package/templates/stacks/rust-axum/src/handlers/mod.rs +3 -3
  819. package/templates/stacks/rust-axum/src/handlers/users.rs +81 -81
  820. package/templates/stacks/rust-axum/src/handlers/ws.rs +24 -24
  821. package/templates/stacks/rust-axum/src/lib.rs +19 -19
  822. package/templates/stacks/rust-axum/src/llm/mod.rs +1 -1
  823. package/templates/stacks/rust-axum/src/llm/provider.rs +48 -48
  824. package/templates/stacks/rust-axum/src/main.rs.tera +64 -64
  825. package/templates/stacks/rust-axum/src/middleware/auth.rs +20 -20
  826. package/templates/stacks/rust-axum/src/middleware/mod.rs +2 -2
  827. package/templates/stacks/rust-axum/src/middleware/rate_limit.rs +27 -27
  828. package/templates/stacks/rust-axum/src/models/mod.rs +1 -1
  829. package/templates/stacks/rust-axum/src/models/user.rs +13 -13
  830. package/templates/stacks/rust-axum/src/repositories/mod.rs +1 -1
  831. package/templates/stacks/rust-axum/src/repositories/user_repository.rs +62 -62
  832. package/templates/stacks/rust-axum/src/services/auth_service.rs +50 -50
  833. package/templates/stacks/rust-axum/src/services/mod.rs +2 -2
  834. package/templates/stacks/rust-axum/src/services/user_service.rs +53 -53
  835. package/templates/stacks/rust-axum/tests/integration_test.rs.tera +13 -13
  836. package/dist/commands/new.d.ts +0 -16
  837. package/dist/commands/new.d.ts.map +0 -1
  838. package/dist/commands/new.js +0 -104
  839. package/dist/commands/new.js.map +0 -1
package/README.md CHANGED
@@ -1,762 +1,764 @@
1
- # @dewtech/dare-cli
2
-
3
- CLI tool for the **DARE Framework** — Design, Architect, Review, Execute.
4
-
5
- A structured methodology for AI-assisted software development with mandatory human-in-the-loop reviews and parallel task execution.
6
-
7
- [![npm](https://img.shields.io/npm/v/@dewtech/dare-cli)](https://www.npmjs.com/package/@dewtech/dare-cli)
8
- [![License: MIT](https://img.shields.io/badge/License-MIT-blue.svg)](https://github.com/dewtech-technologies/dare-method/blob/main/LICENSE)
9
-
10
- ---
11
-
12
- ## ⚠ Read this first — How `dare init` scaffolds a project (v3.2)
13
-
14
- `dare init` writes a **complete, DARE-shaped project** from generators
15
- internalized in this package — no shell-out to the framework's official CLI
16
- during init. Each backend + MCP stack lays down its full source tree
17
- (Layered Design, OpenAPI, JWT auth, rate limit, `.env.example`,
18
- `.dare/skills.yml`, CI gates), then prints the install/build steps to run next.
19
-
20
- | Stack | What `dare init` writes |
21
- |-------|-------------------------|
22
- | `ruby-rails-8` | Rails 8 + Layered Design + Action Cable + LLM + RSpec |
23
- | `node-nestjs` | NestJS 10 + Prisma + Swagger + Throttler + JWT |
24
- | `python-fastapi` | FastAPI + Pydantic v2 + SQLAlchemy + Alembic + slowapi |
25
- | `php-laravel` | Laravel 11 + Sanctum + FormRequest + Reverb + l5-swagger |
26
- | `rust-axum` | Axum + Tower + utoipa + jsonwebtoken + argon2 + sqlx |
27
- | `go-gin` | Gin + sqlc + swag + golang-jwt + gorilla/websocket |
28
- | `go-stdlib` | net/http 1.22 (no framework) + sqlc + coder/websocket |
29
- | `mcp-node-ts` | MCP server (`@modelcontextprotocol/sdk`) — stdio/sse/http |
30
- | `mcp-python` | MCP server (`mcp[cli]` / FastMCP) — stdio/sse/http |
31
- | `mcp-rust` (beta) | MCP server (`rmcp`) — stdio/sse/http |
32
- | `mcp-go` (beta) | MCP server (`mark3labs/mcp-go`) — stdio/sse/http |
33
- | `react`, `vue` | Vite scaffold + DARE overlay |
34
- | `rust-leptos` / `-csr` | Cargo workspace (Axum server + Leptos web) |
35
-
36
- Non-interactive: `dare init <name> --stack <id>` or `dare init <name> --mcp <lang> [--transport stdio\|sse\|http]`.
37
-
38
- Generation itself needs **no toolchain**. To build/run the generated project
39
- afterwards you need that stack's `ruby` / `composer` / `npm` / `cargo` / `python` / `go`
40
- **somewhere**. There are three ways to provide it — you pick at init time
41
- (prompt below), and the choice is saved in `dare.config.json` so
42
- `dare bootstrap` reuses it later.
43
-
44
- ```
45
- ? Toolchain for scaffolding (composer / npm / cargo / python / go):
46
- ❯ 🤖 Auto — use native if on PATH, else Docker (recommended)
47
- 🔧 Native only — require the CLI on PATH (faster, no Docker pulls)
48
- 🐳 Docker only — always use the official image (hermetic, no host install)
49
- ```
50
-
51
- ### 🤖 Auto (default)
52
-
53
- Tries the native CLI first. If missing, falls back to the official Docker
54
- image automatically. If neither is present, fails fast with both install
55
- links.
56
-
57
- ```
58
- which composer → ✓ found? use native
59
- → ✗ missing? which docker
60
- → ✓ found? docker run composer:latest …
61
- → ✗ missing? error: install Composer or Docker
62
- ```
63
-
64
- **When:** you don't know exactly what's installed; mixed teams (some
65
- machines have the toolchain, some only have Docker). The same project
66
- config (`dare.config.json` with `toolchain: auto`) works on every machine.
67
-
68
- ### 🔧 Native only
69
-
70
- Requires the CLI on PATH. **Fails immediately** if missing — no Docker
71
- fallback even if Docker is available.
72
-
73
- ```
74
- which composer → ✓ found? use native
75
- → ✗ missing? error: "Install Composer: https://getcomposer.org/"
76
- ```
77
-
78
- **When:** you already have the toolchain and want **maximum speed** (no
79
- `docker pull`, no bind-mount overhead, no container startup); you're in CI
80
- with the toolchain pre-installed; you want to avoid Docker Desktop edge
81
- cases (Windows volume throttling, Linux uid/gid issues, etc.).
82
-
83
- ### 🐳 Docker only
84
-
85
- **Always** runs the scaffold inside the official Docker image — even if
86
- the native CLI is on PATH. Fails if Docker isn't installed.
87
-
88
- ```
89
- which docker → ✓ found? docker run --rm -v ".:/app" composer:latest create-project …
90
- → ✗ missing? error: "Install Docker Desktop"
91
- ```
92
-
93
- **When:** you don't want to install PHP / Cargo / Python / Go on the
94
- host (keep host clean); you want **hermetic, reproducible** builds (every
95
- dev uses the exact toolchain version baked into the image); you want to
96
- mirror your CI locally.
97
-
98
- ### Quick decision table
99
-
100
- | Your situation | Pick |
101
- |----------------|------|
102
- | Already have the toolchain installed, want speed | **🔧 Native** |
103
- | Don't want to install PHP/Cargo/Python/Go on the host | **🐳 Docker** |
104
- | Mixed team, varying setups | **🤖 Auto** |
105
- | Just want it to work | **🤖 Auto** |
106
- | Want bit-for-bit toolchain reproducibility | **🐳 Docker** |
107
- | Solo dev with everything installed | **🔧 Native** |
108
-
109
- ### Override later
110
-
111
- ```bash
112
- dare bootstrap --toolchain docker # rerun scaffold inside Docker
113
- dare bootstrap --toolchain native --force # rerun native, overwriting framework files
114
- dare bootstrap --toolchain auto # back to auto-detect
115
- ```
116
-
117
- ### ⚠ Important caveat — Ralph Loop
118
-
119
- `dare execute --complete` runs the stack's quality gates
120
- (`composer dump-autoload`, `php artisan test`, `cargo build`, etc.)
121
- **directly on the host** — it does **not** automatically wrap them in
122
- Docker even if you picked `docker only` at init time.
123
-
124
- If you don't have the native toolchain installed, the agent should run
125
- the gates inside the container created by **task-001** (the Containerize
126
- task), e.g. `docker compose exec app php artisan test`. The skills
127
- shipped with `dare init` already nudge the agent toward that pattern.
128
-
129
- ---
130
-
131
- ## Prerequisites
132
-
133
- ### Required for the CLI itself
134
-
135
- | Tool | Why | Install |
136
- |------|-----|---------|
137
- | **Node.js 18+** | runs `dare`, `dare-mcp-server` and the bundled GraphRAG engine | https://nodejs.org/ |
138
-
139
- ### Required to build/run the generated project
140
-
141
- `dare init` itself needs no stack toolchain — it writes the project from
142
- internalized templates. To **build and run** what it generates, you need that
143
- stack's toolchain (`composer`/`npm`/`cargo`/`go`/`python`/`ruby`). If you don't
144
- have it natively but have Docker, run the build steps inside the stack's
145
- official image (the `.github/workflows/dare-ci.yml` the project ships shows the
146
- exact commands).
147
-
148
- Pick **one** of the two paths per stack:
149
-
150
- | Stack | Native toolchain | Docker fallback (used if native missing) |
151
- |-------|------------------|------------------------------------------|
152
- | `ruby-rails-8` | Ruby 3.3+ · Bundler 2+ · Rails 8 — https://www.ruby-lang.org/ | `ruby:3.3-slim` |
153
- | `php-laravel` | PHP 8.2+ · Composer 2+ — https://getcomposer.org/ | `composer:latest` |
154
- | `node-nestjs` | Node 18+ (bundles `npx`) | `node:20-alpine` |
155
- | `python-fastapi` | Python 3.11+ — https://www.python.org/downloads/ | `python:3.12-slim` |
156
- | `rust-axum` | Rust 1.83+ (rustup) — https://www.rust-lang.org/tools/install | `rust:1.83` |
157
- | `go-gin` | Go 1.25+ — https://go.dev/dl/ | `golang:1.25` |
158
- | `go-stdlib` | Go 1.22+ — https://go.dev/dl/ | `golang:1.25` |
159
- | `react`, `vue` | Node 18+ (bundles `npm`) | `node:20-alpine` |
160
- | `rust-leptos` | Rust 1.83+ (rustup) + **cargo-leptos 0.2.22** — `cargo install cargo-leptos --version 0.2.22` | `ghcr.io/dewtech-technologies/dare-rust-leptos:1` |
161
- | `rust-leptos-csr` | Rust 1.83+ (rustup) + **trunk** — `cargo install trunk` | `ghcr.io/dewtech-technologies/dare-rust-leptos:1` |
162
- | `mcp-node-ts` | Node 18+ | `node:20-alpine` |
163
- | `mcp-python` | Python 3.11+ | `python:3.12-slim` |
164
- | `mcp-rust` (beta) | Rust 1.78+ (rustup) | `rust:1.83` |
165
- | `mcp-go` (beta) | Go 1.23+ — https://go.dev/dl/ | `golang:1.25` |
166
-
167
- > **v3.2.0:** full **CLI IDE parity**every one of the 18 CLI commands is invocable as `/dare-<cmd>` across all three IDEs (Cursor, Claude Code, Antigravity); a parity test fails the build if a command is missing a skill. Brownfield commands now **collect real data by default**: `dare reverse`/`dna` extract endpoints + entities and render them into `IDEIA.md` and the module specs (no more skeleton-only artifacts).
168
-
169
- > **v3.1.0:** all **11 stacks** ship a full generator internalized in `@dewtech/dare-cli` 7 backend (ruby-rails-8, node-nestjs, python-fastapi, php-laravel, rust-axum, go-gin, go-stdlib) + 4 MCP (mcp-node-ts, mcp-python, mcp-rust, mcp-go). No isolated stack packages; everything is in one publishable tarball (fixes the `npm install -g` 404 of earlier releases). `dare new` was removed `dare init` is the only scaffolding entrypoint.
170
-
171
- > **TL;DR:** if you have **Docker Desktop** installed, you don't strictly need
172
- > any other toolchain — `dare init` will pull the right image on demand.
173
- > Native toolchains are faster and don't depend on Docker pulling images.
174
-
175
- If neither the native CLI **nor** Docker is available, `dare init` fails
176
- fast with a clear error message — it never falls back to a fake template.
177
-
178
- ### Choose the toolchain at init time
179
-
180
- The 3 modes (`auto` / `native` / `docker`) are explained in detail at the
181
- top of this README — see [⚠ Read this first](#-read-this-first--how-dare-init-runs-the-official-scaffold).
182
-
183
- Quick recap:
184
-
185
- | Mode | Behavior |
186
- |------|----------|
187
- | `auto` (default) | Native if available, else Docker. Recommended. |
188
- | `native` | Requires the native CLI; fails if missing. |
189
- | `docker` | Always uses the official Docker image. |
190
-
191
- The choice is persisted in `dare.config.json` (`"toolchain": "..."`).
192
- Override at any time:
193
-
194
- ```bash
195
- dare bootstrap --toolchain docker # rerun scaffold inside Docker
196
- dare bootstrap --toolchain native --force # rerun native, overwriting
197
- ```
198
-
199
- ### Required for the Ralph Loop (per project)
200
-
201
- Once the project is scaffolded, every `dare execute --complete` runs the
202
- stack's gates: `build → test → lint`. The same toolchain (native or Docker)
203
- that scaffolded the project is needed to run those gates. Plan accordingly:
204
- if you chose `php-laravel` and only have Docker, `dare execute --complete`
205
- needs to invoke `php artisan test` somehow typically by running it inside
206
- your `docker-compose` app service (this is the kind of thing the
207
- `task-001 = Containerize app` task sets up).
208
-
209
- ## Installation
210
-
211
- ```bash
212
- npm install -g @dewtech/dare-cli
213
- ```
214
-
215
- ## Commands
216
-
217
- ### `dare init`
218
-
219
- Interactive project initialization — creates the full project structure with DARE methodology files, IDE rules and stack templates.
220
-
221
- ```bash
222
- dare init my-project
223
- ```
224
-
225
- Prompts:
226
- - **Structure:** Monorepo · Backend only · Frontend only · **MCP Server** ← new
227
- - **MCP Server:** language (TypeScript / Python), transport (stdio / SSE / HTTP Stream), capabilities (Tools / Resources / Prompts)
228
- - **Backend stack:** Rust/Axum · Node.js/NestJS · Python/FastAPI · PHP/Laravel · Go/Gin · Go/stdlib
229
- - **Frontend stack:** React 18+ · Vue 3+ · Leptos fullstack (Rust SSR+WASM) · Leptos CSR-only (Rust WASM)
230
- - **Cargo workspace layout** *(Monorepo + Rust/Axum + Leptos only)*: Single-crate (`crates/server` + `crates/web`) · Multi-crate (`{prefix}-core` + `{prefix}-server` + `{prefix}-web` + `{prefix}-cli`) — prefix suggested from project initials (e.g. `ai-runtime-securyti-rasp` → `arsr`)
231
- - **IDE / Agent:** Claude Code · Cursor · Antigravity · Hybrid
232
- - **GraphRAG backend:** SQLite · JSON · Neo4j
233
- - **DARE MCP Server:** context query server (saves ~95% tokens)
234
-
235
- Generates:
236
- - `dare.config.json` — project config
237
- - `CLAUDE.md` + `.claude/commands/` + `.claude/settings.json` — Claude Code rules and slash commands (includes `/dare-security`)
238
- - `.cursorrules` / `.antigravityrules` — Cursor / Antigravity rules
239
- - `.cursor/rules/*.mdc` — stack-specific skills
240
- - `.cursor/commands/` — Cursor slash commands
241
- - `.agents/skills/`Antigravity agent skills
242
- - `DARE/` — methodology directory (DESIGN, BLUEPRINT, TASKS, dag)
243
- - Full project template ready to run (MCP server, backend or frontend)
244
-
245
- ---
246
-
247
- ### `dare discover` ← new in v0.3.0
248
-
249
- Detects an existing project's stack automatically and installs DARE files without touching your source code.
250
-
251
- ```bash
252
- # Run inside an existing project
253
- cd my-existing-project
254
- dare discover
255
-
256
- # Inspect only, no changes
257
- dare discover --check
258
-
259
- # Target a specific directory
260
- dare discover --dir ./path/to/project
261
- ```
262
-
263
- Auto-detects from: `package.json`, `Cargo.toml`, `requirements.txt`, `pyproject.toml`, `composer.json`.
264
-
265
- Recognizes: NestJS · React · Vue · Nuxt · Rust/Axum · FastAPI · Laravel · **MCP Server** (`@modelcontextprotocol/sdk`, `FastMCP`).
266
-
267
- ---
268
-
269
- ### `dare reverse` ← brownfield (Phase 0)
270
-
271
- Reverse-engineer an existing codebase into a Phase-0 understanding **without touching the source**.
272
- Deterministically detects module boundaries, sizes them by LOC and infers the dependency graph.
273
-
274
- ```bash
275
- cd my-legacy-project
276
- dare reverse # → DARE/IDEIA.md + REVERSE/module-*.md + reverse-facts.json + architecture.excalidraw
277
- dare reverse --check # detection only, no files
278
- dare reverse --modules api,auth
279
- dare reverse --no-excalidraw
280
- ```
281
-
282
- **Confidence & traceability.** The `/dare-reverse` skill marks each claim 🟢 CONFIRMED (with
283
- `file:line` evidence) · 🟡 INFERRED · 🔴 GAP. Then:
284
-
285
- ```bash
286
- dare reverse --report # deterministic confidence index from the markers (not LLM self-scored)
287
- ```
288
-
289
- → `confidence-report.md` + `traceability/code-spec-matrix.md`; the 🔴 become `gaps.md` + `questions.md`.
290
-
291
- **Deep extraction (framework-agnostic per language):**
292
-
293
- ```bash
294
- dare reverse --deep # + ERD, API surface, C4, domain-rules, state-machines, permissions
295
- ```
296
-
297
- The CLI extracts the data model (`erd.md`) and endpoints (`api-surface.md`) deterministically from
298
- **SQL inline (DDL + query tables), Prisma, ORMs and plain types/classes/structs** — so it works on
299
- legacy projects **with or without a framework** (e.g. raw-PDO PHP without Laravel). Routes cover
300
- multiple dialects per language (Express/Nest/Fastify, Laravel/Slim/Symfony, FastAPI/Flask/Django,
301
- Rails/Sinatra, Gin/stdlib, Axum).
302
-
303
- ---
304
-
305
- ### `dare dna` ← brownfield
306
-
307
- Extract the legacy codebase's **conventions** so the agent follows the house style instead of generic
308
- defaults — for legacy you can't rewrite.
309
-
310
- ```bash
311
- cd my-legacy-project
312
- dare dna # → DARE/PROJECT-DNA.md + dna-facts.json
313
- dare dna --check
314
- ```
315
-
316
- Detects lint/format tooling, naming conventions, architecture layers, test framework, key libraries
317
- (ORM/HTTP/auth/validation) and commit convention. The `/dare-dna` skill turns the facts into
318
- actionable rules. Reuses `reverse-facts.json` if `dare reverse` already ran.
319
-
320
- ---
321
-
322
- ### `dare migrate` ← brownfield (Phase 2)
323
-
324
- Plan a **safe migration** to a target stack, with **Gherkin parity scenarios** that guarantee
325
- behavior is preserved. Requires `dare reverse` first.
326
-
327
- ```bash
328
- cd my-legacy-project
329
- dare migrate --to go-gin # or rust-axum, node-nestjs, python-fastapi, php-laravel, ruby-rails-8…
330
- dare migrate --check
331
- ```
332
-
333
- Consumes `IDEIA` + `DNA`, inherits the **blocking gaps** (🔴) as risks, and generates
334
- `DARE/MIGRATION/MIGRATION.md` (paradigm, strategy, risk register, target architecture, cutover) +
335
- `parity/<module>.feature` (the behavioral acceptance contract). The `/dare-migrate` skill fills the
336
- strategy and the real parity scenarios.
337
-
338
- > **Brownfield loop:** `reverse` (the *what*) `dna` (the *how*) → `migrate` (reimplement with
339
- > parity) → `design`/`blueprint`/`execute` on the target stack.
340
-
341
- ---
342
-
343
- ### `dare design`
344
-
345
- Generate `DARE/DESIGN.md` from a project description.
346
-
347
- ```bash
348
- dare design "Build a REST API for user authentication with JWT"
349
- ```
350
-
351
- ---
352
-
353
- ### `dare blueprint`
354
-
355
- Generate `DARE/BLUEPRINT.md` from `DESIGN.md`. Stops here — requires human review and approval before tasks are created.
356
-
357
- ```bash
358
- dare blueprint
359
- ```
360
-
361
- ---
362
-
363
- ### `dare tasks`
364
-
365
- Generate `DARE/TASKS.md`, `DARE/dare-dag.yaml` and all `DARE/EXECUTION/task-*.md` specs from an approved `BLUEPRINT.md`. Run this only after reviewing and approving the blueprint.
366
-
367
- ```bash
368
- dare tasks
369
- ```
370
-
371
- ---
372
-
373
- ### `dare execute`
374
-
375
- Orchestrate DAG execution. **The IDE is the executor** (Cursor / Antigravity
376
- / Claude Code) — `dare execute` only coordinates state, composes prompts
377
- with parent context, updates the live canvas at `DARE/.canvas.md`, and
378
- ingests finished tasks into the knowledge graph.
379
-
380
- > **No API keys, no extra token costs.** You use the plan of the IDE you're
381
- > already logged into.
382
-
383
- ```bash
384
- # Print next executable tasks (with composed prompts)
385
- dare execute --next
386
-
387
- # Mark a task DONE after the agent finishes it
388
- dare execute --complete task-001 --output "Created src/auth.ts and tests/auth.test.ts; all tests green."
389
-
390
- # Mark a task FAILED descendants are cascade-skipped automatically
391
- dare execute --fail task-002 --reason "Schema migration conflict in users table"
392
-
393
- # Reset a task back to PENDING (for retry)
394
- dare execute --reset task-002
395
-
396
- # Show snapshot of canvas + summary (default action)
397
- dare execute --status
398
- ```
399
-
400
- #### Typical flow inside the IDE agent
401
-
402
- ```bash
403
- dare execute --next # → tasks ready in current rank
404
- # (agent executes each task: code, build, test, lint)
405
- dare execute --complete task-001 --output "…"
406
- dare execute --complete task-002 --output "…"
407
- dare execute --next # next rank
408
- # (repeat until "✅ All tasks resolved")
409
- ```
410
-
411
- The skills shipped by `dare init` (`.cursor/rules/skill-dag-runner.mdc`,
412
- `.agents/skills/dare-dag-runner/SKILL.md`, `.claude/commands/dare-dag-run.md`)
413
- guide the IDE agent through this loop.
414
-
415
- #### Stack-specific skills
416
-
417
- `dare init` also ships skills focused on architectural decisions for
418
- specific stacks. As of v2.15.0:
419
-
420
- - **`skill-rust-workspace.mdc`** (Cursor) /
421
- **`dare-rust-workspace/SKILL.md`** (Antigravity) /
422
- **`/dare-rust-workspace`** (Claude command) — guides the agent on
423
- whether a Rust project should start single-crate or as a Cargo
424
- workspace, and gives a step-by-step PR-by-PR migration plan when an
425
- existing single-crate project has outgrown its layout. Active during
426
- `/dare-design` and `/dare-blueprint` for `rust-axum` projects, plus on
427
- demand for migration analysis.
428
-
429
- - **`skill-rust-leptos.mdc`** (Cursor) /
430
- **`dare-rust-leptos/SKILL.md`** (Antigravity) /
431
- **`/dare-rust-leptos`** (Claude command) — full guide for Leptos
432
- development: CSR vs fullstack decision table, Leptos 0.7 idioms
433
- (signals, Resource, Action, Show, For, `#[server]`), shared types with
434
- `cfg_attr`, mixed workspace configuration (WASM + native crates), and
435
- antipatterns to avoid (`cargo leptos test` does not exist; no global
436
- `[build] target` in `.cargo/config.toml`). Ships 3 ready-to-use DARE
437
- task templates for Leptos projects.
438
-
439
- ### `dare bootstrap`
440
-
441
- Lay down a stack's DARE-shaped source on **an existing project** (created in
442
- older versions or with `--skip-bootstrap`). Reads `dare.config.json` and runs
443
- the internalized generator for the configured stack the same one `dare init`
444
- uses. Frontend stacks (`react` / `vue` / `rust-leptos`) still use their Vite /
445
- Cargo scaffold.
446
-
447
- ```bash
448
- dare bootstrap # refuses if vendor/ or node_modules/ already exist
449
- dare bootstrap --force # runs anyway (may overwrite framework files)
450
- ```
451
-
452
- Your DARE artifacts (`.cursor/`, `DARE/`, `dare.config.json`, `dare-graph.yml`)
453
- are preserved.
454
-
455
- ### `dare info`
456
-
457
- Read-only diagnostic of the current project: CLI version, platform, presence
458
- of each canonical DARE artifact, active GraphRAG backend, and task progress.
459
-
460
- ```bash
461
- dare info
462
- ```
463
-
464
- ### `dare review` ← new in v2.17.0
465
-
466
- **Anti-stub gate.** Audita os arquivos que uma task tocou e detecta padrões de "fake completeness": `TODO`/`FIXME`, stubs (`throw new Error('not implemented')`, `todo!()`, `NotImplementedError`), funções vazias, retorno-fantasma (`return null` como única statement), mocks fora de testes (`jest.fn`, `vi.mock`, `sinon.stub`, `MagicMock`), comentários-placeholder (`// implement later`).
467
-
468
- A camada estática (regex, determinística) é metade. A IDE agent pode rodar a skill `dare-review` / `review-task` para validar critério-a-critério se a implementação atende a spec, emitir um `SemanticVerdict` JSON, e o CLI funde os dois numa única decisão.
469
-
470
- ```bash
471
- # Audita os arquivos listados em DARE/EXECUTION/task-034.md
472
- dare review task-034
473
-
474
- # Em CI:
475
- dare review task-034 --strict --format json
476
-
477
- # Lista explícita de arquivos:
478
- dare review task-034 --files src/auth/login.ts src/auth/register.ts
479
-
480
- # Funde com verdito semântico do agente:
481
- dare review task-034 --from-agent .dare/verdict-task-034.json
482
- ```
483
-
484
- **Gate opt-in no Ralph Loop:** com `review.onComplete: true` em `dare.config.json`, `dare execute --complete <id>` bloqueia DONE se a review falhar. Para projetos novos (`dare init` v2.17+) já vem ligado; projetos legados permanecem off até o dev flipar.
485
-
486
- ### `dare refine` new in v2.17.0
487
-
488
- **Anti-monstro.** Mede complexidade de uma task e, opcionalmente, propõe quebra em sub-tasks menores. Heurística determinística pesa # arquivos, # funções/endpoints, # testes, # dependências, keywords "pesadas" (refactor/migrate/integrate/multiple) — produz um score em LOW (0–5) / MED (6–12) / HIGH (13–20) / CRITICAL (21+).
489
-
490
- ```bash
491
- # Apenas mede e reporta:
492
- dare refine task-034
493
-
494
- # Mede + propõe quebra em sub-tasks (task-034a, task-034b, ...):
495
- dare refine task-034 --split
496
-
497
- # Anota TASKS.md marcando a task para split (o agente regenera as specs):
498
- dare refine task-034 --split --apply
499
-
500
- # Em CI: exit code 2 se HIGH/CRITICAL:
501
- dare refine task-034 --strict
502
- ```
503
-
504
- A camada determinística agrupa arquivos por diretório raiz. A IDE agent (skills `dare-refine` / `refine-task`) refina o split semanticamente — por camada (Model/Controller/Service), por endpoint, por feature, refactor-then-feature, migration-then-code.
505
-
506
- Thresholds configuráveis em `dare.config.json`:
507
-
508
- ```jsonc
509
- {
510
- "refine": {
511
- "thresholds": { "low": 5, "med": 12, "high": 20 }
512
- }
513
- }
514
- ```
515
-
516
- ### `dare update` ← new in v2.17.0
517
-
518
- Sync the **project's DARE setup** (templates, slash commands, skills, schema)
519
- with the version of the CLI currently installed. Useful when you upgrade the
520
- CLI globally (`npm install -g @dewtech/dare-cli@latest`) and want a previous
521
- project to pick up the new improvements **without touching your DESIGN /
522
- BLUEPRINT / TASKS / dare-dag.yaml artifacts**.
523
-
524
- Different from upgrading the CLI itself: `npm update -g @dewtech/dare-cli`
525
- changes the binary on your machine; `dare update` changes the *project files
526
- on disk* to match what that binary now ships.
527
-
528
- ```bash
529
- dare update # interactive (recommended)
530
- dare update --dry-run # preview: shows changelog + affected files, writes nothing
531
- dare update --yes # CI: apply, preserve customizations, no prompts
532
- dare update --force # also overwrite files the dev customized (dangerous)
533
- dare update --target 2.17.0 # update to a specific release instead of the installed CLI
534
- ```
535
-
536
- **What it does:**
537
-
538
- 1. Reads `version` from `dare.config.json` (the project's last-known DARE version).
539
- 2. Loads `templates/UPDATE-MANIFEST.json` (ships with the CLI) and lists every
540
- release between the project's version and the CLI's version.
541
- 3. Prints the changelog for each pending release and the list of files
542
- affected for your IDE (cursor / claude-code / antigravity / hybrid).
543
- 4. For each file, classifies the situation:
544
- - **identical** skip
545
- - **missing** create
546
- - **apply** → file matches the previous template hash, safe to overwrite
547
- - **customized** → file diverges from the previous template; prompt
548
- (`keep` / `replace`) unless `--yes` (keep) or `--force` (replace).
549
- 5. Backs up every affected file to `.dare/backup-<from-version>/` before
550
- writing.
551
- 6. Runs any schema migrations declared by the release (e.g. renaming a
552
- config field).
553
- 7. Stamps `version` and `updatedAt` in `dare.config.json`.
554
-
555
- **Adding entries when you cut a release:** each new CLI version that ships
556
- template changes needs a corresponding entry in `templates/UPDATE-MANIFEST.json`
557
- listing `changes` (added / modified / removed / renamed) and optional
558
- `migrations`. The applier filters changes by `appliesTo: [ide]`, so a
559
- template that's cursor-only won't be installed in a Claude Code project and
560
- vice versa.
561
-
562
- ### `dare validate`
563
-
564
- Static checks on `dare-dag.yaml` — ideal for pre-commit hooks and CI.
565
- Verifies unique kebab-case ids, valid `depends_on`, absence of cycles,
566
- non-empty prompts, and parallelism (warning when only one task at rank 0).
567
-
568
- ```bash
569
- dare validate # errors fail; warnings printed
570
- dare validate --strict # warnings also fail (CI-friendly)
571
- ```
572
-
573
- A pre-commit hook template is shipped at
574
- `templates/hooks/pre-commit-dare-validate` — copy to `.git/hooks/pre-commit`
575
- (or use with husky) to validate the DAG before every commit.
576
-
577
- ### `dare execute --watch`
578
-
579
- Interactive loop: the CLI watches `.dare/state.json` and re-prints the next
580
- ready tasks every time the state changes. Pair with the IDE agent firing
581
- `--complete`/`--fail` from another terminal.
582
-
583
- ```bash
584
- dare execute --watch
585
- ```
586
-
587
- ### `dare dag`
588
-
589
- Inspect and visualize the **static task DAG** declared in `dare-dag.yaml`
590
- distinct from `dare graph`, which inspects the populated knowledge graph
591
- (only contains tasks already executed).
592
-
593
- ```bash
594
- dare dag viz # Mermaid to stdout
595
- dare dag viz -o DARE/dag-graph.mmd # Mermaid file
596
- dare dag viz -f dot -o DARE/dag-graph.dot # DOT (Graphviz)
597
- ```
598
-
599
- The Mermaid output groups tasks into rank subgraphs and colors nodes by
600
- status (`PENDING` / `RUNNING` / `DONE` / `FAILED` / `SKIPPED`), so you can
601
- **see the execution plan before running any task**.
602
-
603
- > `dare tasks` writes `DARE/dag-graph.mmd` automatically open it in
604
- > your editor with a Mermaid preview to see the static graph immediately.
605
-
606
- ### `dare graph`
607
-
608
- Inspect the project's knowledge graph. The graph is populated automatically
609
- by `dare execute --complete/--fail` (task nodes, file nodes, `depends_on` and
610
- `implements` edges). Backend is whatever `dare-graph.yml` declares
611
- (`sqlite` default, `json` available, `neo4j` planned).
612
-
613
- ```bash
614
- dare graph stats # totals + breakdown by type
615
- dare graph query auth # search nodes by label/description
616
- dare graph query auth --limit 20
617
-
618
- dare graph viz # Mermaid to stdout
619
- dare graph viz -f dot # DOT for Graphviz
620
- dare graph viz -o docs/graph.mmd # write to file
621
-
622
- dare graph ingest # re-sync from dare-dag.yaml + state
623
- ```
624
-
625
- ---
626
-
627
- ## Full Workflow
628
-
629
- ```bash
630
- # New project
631
- dare init my-project
632
- cd my-project
633
- dare design "Describe what you're building"
634
- dare blueprint
635
- dare execute --parallel
636
-
637
- # Existing project
638
- cd my-existing-project
639
- dare discover
640
- dare design "Describe what you're building"
641
- dare blueprint
642
- dare execute --parallel
643
- ```
644
-
645
- ## Claude Code Workflow
646
-
647
- ```bash
648
- dare init my-project
649
- # → IDE: Claude Code
650
- # Structure: Backend / Frontend / MCP Server
651
-
652
- cd my-project
653
- # Claude Code slash commands available:
654
- # /dare-design → generates DARE/DESIGN.md
655
- # /dare-blueprint generates BLUEPRINT.md + DAG
656
- # /dare-execute task-001 implements with Ralph Loop
657
- # /dare-tasks shows task status table
658
- ```
659
-
660
- Files generated for Claude Code:
661
- ```
662
- CLAUDE.md ← main context (stack rules + DARE methodology)
663
- .claude/
664
- settings.json permissions + Ralph Loop hook
665
- commands/
666
- dare-design.md /dare-design
667
- dare-blueprint.md ← /dare-blueprint
668
- dare-execute.md ← /dare-execute
669
- dare-tasks.md ← /dare-tasks
670
- ```
671
-
672
- ---
673
-
674
- ## MCP Server Workflow
675
-
676
- ```bash
677
- dare init my-mcp-server
678
- # → Structure: MCP Server
679
- # Language: TypeScript
680
- # → Transport: stdio
681
- # → Capabilities: Tools, Resources
682
-
683
- cd my-mcp-server
684
- npm install
685
- dare design "MCP server that exposes ZIP code lookup tools"
686
- dare blueprint
687
- dare execute --parallel
688
-
689
- # Test with MCP Inspector
690
- npm run inspect
691
- ```
692
-
693
- ---
694
-
695
- ## Performance
696
-
697
- | Mode | Estimated Time |
698
- |------|----------------|
699
- | Sequential | ~280 minutes |
700
- | Parallel DAG | ~70 minutes |
701
- | **Improvement** | **75% faster** |
702
-
703
- ---
704
-
705
- ## Supported Stacks
706
-
707
- | Type | Options |
708
- |------|---------|
709
- | **Backend** | Ruby on Rails 8 · Rust/Axum · Node.js/NestJS · Python/FastAPI · PHP/Laravel · Go/Gin · Go/stdlib |
710
- | **Frontend** | React 18+ · Vue 3+ · Leptos fullstack (Rust SSR+WASM) · Leptos CSR (Rust WASM) |
711
- | **MCP Server** | TypeScript/Node.js · Python stdio / SSE / HTTP Stream |
712
- | **IDE / Agent** | Claude Code · Cursor · Antigravity · Hybrid |
713
-
714
- ---
715
-
716
- ## Skills disponíveis (v3.0.0)
717
-
718
- **32 skills em paridade total** nas 3 IDEs (Antigravity, Claude Code, Cursor). Cada skill existe em formato nativo de cada uma e é entregue por `dare init` / `dare update`.
719
-
720
- | Categoria | Skills | Exemplos |
721
- |---|---|---|
722
- | **Método DARE** | 6 | `dare-design`, `dare-blueprint`, `dare-tasks`, `dare-execute`, `dare-review`, `dare-refine` |
723
- | **DAG runner** | 4 | `dare-dag-build`, `dare-dag-run`, `dare-dag-runner`, `dare-dag-viz` |
724
- | **Transversais** | 6 | `dare-ax`, `dare-layered-design`, `dare-llm-integration`, `dare-frontend-design`, `dare-realtime`, `dare-quality-telemetry` |
725
- | **Stack / Tools** | 8 | `dare-docker`, `dare-security`, `dare-telemetry`, `dare-bugfix-design`, `dare-feature-design`, `dare-rust-workspace`, `dare-rust-leptos`, `dare-laravel-api` |
726
- | **Stacks novas v3.0.0** | 5 | `dare-nestjs-api`, `dare-fastapi-api`, `dare-go-gin-api`, `dare-mcp-server`, `dare-rails-api` |
727
- | **Brownfield** | 3 | `dare-reverse`, `dare-dna`, `dare-migrate` |
728
-
729
- Ver tabela cruzada completa em [`docs/skills/INDEX.md`](https://github.com/dewtech-technologies/dare-method/blob/main/docs/skills/INDEX.md).
730
-
731
- ---
732
-
733
- ## O que vem com o pacote (v2.0+)
734
-
735
- A partir da v2.0 o `@dewtech/dare-cli` é um **pacote único** que inclui todas as
736
- funcionalidades do framework DARE. Você não precisa instalar nada além dele:
737
-
738
- ```bash
739
- npm install -g @dewtech/dare-cli
740
- ```
741
-
742
- Isso já dá:
743
-
744
- | Componente | O que é |
745
- |------------|---------|
746
- | CLI `dare` | `init`, `design`, `blueprint`, `execute`, `discover`, `reverse`, `dna`, `migrate` |
747
- | CLI `dare-mcp-server` | Servidor MCP local de contexto (~95% economia de tokens) |
748
- | Engine GraphRAG | Grafo de conhecimento com SQLite + FTS5 |
749
- | DAG Task Runner | Execução paralela de tasks com Kahn's algorithm |
750
- | Tipos e templates | Tudo embutido sem dependências externas do `@dewtech/*` |
751
-
752
- > **Histórico (v1.x):** os pacotes `@dewtech/dare-core`, `@dewtech/dare-graphrag` e
753
- > `@dewtech/dare-mcp-server` foram consolidados em `@dewtech/dare-cli` e estão
754
- > **deprecated** no npm. Não mais subpacotes para gerenciar.
755
-
756
- ---
757
-
758
- ## Links
759
-
760
- - [GitHub](https://github.com/dewtech-technologies/dare-method)
761
- - [DARE Methodology](https://github.com/dewtech-technologies/dare-method#-o-método)
762
- - [Dewtech](https://dewtech.tech)
1
+ # @dewtech/dare-cli
2
+
3
+ CLI tool for the **DARE Framework** — Design, Architect, Review, Execute.
4
+
5
+ A structured methodology for AI-assisted software development with mandatory human-in-the-loop reviews and parallel task execution.
6
+
7
+ [![npm](https://img.shields.io/npm/v/@dewtech/dare-cli)](https://www.npmjs.com/package/@dewtech/dare-cli)
8
+ [![License: MIT](https://img.shields.io/badge/License-MIT-blue.svg)](https://github.com/dewtech-technologies/dare-method/blob/main/LICENSE)
9
+
10
+ ---
11
+
12
+ ## ⚠ Read this first — How `dare init` scaffolds a project (v3.2)
13
+
14
+ `dare init` writes a **complete, DARE-shaped project** from generators
15
+ internalized in this package — no shell-out to the framework's official CLI
16
+ during init. Each backend + MCP stack lays down its full source tree
17
+ (Layered Design, OpenAPI, JWT auth, rate limit, `.env.example`,
18
+ `.dare/skills.yml`, CI gates), then prints the install/build steps to run next.
19
+
20
+ | Stack | What `dare init` writes |
21
+ |-------|-------------------------|
22
+ | `ruby-rails-8` | Rails 8 + Layered Design + Action Cable + LLM + RSpec |
23
+ | `node-nestjs` | NestJS 10 + Prisma + Swagger + Throttler + JWT |
24
+ | `python-fastapi` | FastAPI + Pydantic v2 + SQLAlchemy + Alembic + slowapi |
25
+ | `php-laravel` | Laravel 11 + Sanctum + FormRequest + Reverb + l5-swagger |
26
+ | `rust-axum` | Axum + Tower + utoipa + jsonwebtoken + argon2 + sqlx |
27
+ | `go-gin` | Gin + sqlc + swag + golang-jwt + gorilla/websocket |
28
+ | `go-stdlib` | net/http 1.22 (no framework) + sqlc + coder/websocket |
29
+ | `mcp-node-ts` | MCP server (`@modelcontextprotocol/sdk`) — stdio/sse/http |
30
+ | `mcp-python` | MCP server (`mcp[cli]` / FastMCP) — stdio/sse/http |
31
+ | `mcp-rust` (beta) | MCP server (`rmcp`) — stdio/sse/http |
32
+ | `mcp-go` (beta) | MCP server (`mark3labs/mcp-go`) — stdio/sse/http |
33
+ | `react`, `vue` | Vite scaffold + DARE overlay |
34
+ | `rust-leptos` / `-csr` | Cargo workspace (Axum server + Leptos web) |
35
+
36
+ Non-interactive: `dare init <name> --stack <id>` or `dare init <name> --mcp <lang> [--transport stdio\|sse\|http]`.
37
+
38
+ Generation itself needs **no toolchain**. To build/run the generated project
39
+ afterwards you need that stack's `ruby` / `composer` / `npm` / `cargo` / `python` / `go`
40
+ **somewhere**. There are three ways to provide it — you pick at init time
41
+ (prompt below), and the choice is saved in `dare.config.json` so
42
+ `dare bootstrap` reuses it later.
43
+
44
+ ```
45
+ ? Toolchain for scaffolding (composer / npm / cargo / python / go):
46
+ ❯ 🤖 Auto — use native if on PATH, else Docker (recommended)
47
+ 🔧 Native only — require the CLI on PATH (faster, no Docker pulls)
48
+ 🐳 Docker only — always use the official image (hermetic, no host install)
49
+ ```
50
+
51
+ ### 🤖 Auto (default)
52
+
53
+ Tries the native CLI first. If missing, falls back to the official Docker
54
+ image automatically. If neither is present, fails fast with both install
55
+ links.
56
+
57
+ ```
58
+ which composer → ✓ found? use native
59
+ → ✗ missing? which docker
60
+ → ✓ found? docker run composer:latest …
61
+ → ✗ missing? error: install Composer or Docker
62
+ ```
63
+
64
+ **When:** you don't know exactly what's installed; mixed teams (some
65
+ machines have the toolchain, some only have Docker). The same project
66
+ config (`dare.config.json` with `toolchain: auto`) works on every machine.
67
+
68
+ ### 🔧 Native only
69
+
70
+ Requires the CLI on PATH. **Fails immediately** if missing — no Docker
71
+ fallback even if Docker is available.
72
+
73
+ ```
74
+ which composer → ✓ found? use native
75
+ → ✗ missing? error: "Install Composer: https://getcomposer.org/"
76
+ ```
77
+
78
+ **When:** you already have the toolchain and want **maximum speed** (no
79
+ `docker pull`, no bind-mount overhead, no container startup); you're in CI
80
+ with the toolchain pre-installed; you want to avoid Docker Desktop edge
81
+ cases (Windows volume throttling, Linux uid/gid issues, etc.).
82
+
83
+ ### 🐳 Docker only
84
+
85
+ **Always** runs the scaffold inside the official Docker image — even if
86
+ the native CLI is on PATH. Fails if Docker isn't installed.
87
+
88
+ ```
89
+ which docker → ✓ found? docker run --rm -v ".:/app" composer:latest create-project …
90
+ → ✗ missing? error: "Install Docker Desktop"
91
+ ```
92
+
93
+ **When:** you don't want to install PHP / Cargo / Python / Go on the
94
+ host (keep host clean); you want **hermetic, reproducible** builds (every
95
+ dev uses the exact toolchain version baked into the image); you want to
96
+ mirror your CI locally.
97
+
98
+ ### Quick decision table
99
+
100
+ | Your situation | Pick |
101
+ |----------------|------|
102
+ | Already have the toolchain installed, want speed | **🔧 Native** |
103
+ | Don't want to install PHP/Cargo/Python/Go on the host | **🐳 Docker** |
104
+ | Mixed team, varying setups | **🤖 Auto** |
105
+ | Just want it to work | **🤖 Auto** |
106
+ | Want bit-for-bit toolchain reproducibility | **🐳 Docker** |
107
+ | Solo dev with everything installed | **🔧 Native** |
108
+
109
+ ### Override later
110
+
111
+ ```bash
112
+ dare bootstrap --toolchain docker # rerun scaffold inside Docker
113
+ dare bootstrap --toolchain native --force # rerun native, overwriting framework files
114
+ dare bootstrap --toolchain auto # back to auto-detect
115
+ ```
116
+
117
+ ### ⚠ Important caveat — Ralph Loop
118
+
119
+ `dare execute --complete` runs the stack's quality gates
120
+ (`composer dump-autoload`, `php artisan test`, `cargo build`, etc.)
121
+ **directly on the host** — it does **not** automatically wrap them in
122
+ Docker even if you picked `docker only` at init time.
123
+
124
+ If you don't have the native toolchain installed, the agent should run
125
+ the gates inside the container created by **task-001** (the Containerize
126
+ task), e.g. `docker compose exec app php artisan test`. The skills
127
+ shipped with `dare init` already nudge the agent toward that pattern.
128
+
129
+ ---
130
+
131
+ ## Prerequisites
132
+
133
+ ### Required for the CLI itself
134
+
135
+ | Tool | Why | Install |
136
+ |------|-----|---------|
137
+ | **Node.js 18+** | runs `dare`, `dare-mcp-server` and the bundled GraphRAG engine | https://nodejs.org/ |
138
+
139
+ ### Required to build/run the generated project
140
+
141
+ `dare init` itself needs no stack toolchain — it writes the project from
142
+ internalized templates. To **build and run** what it generates, you need that
143
+ stack's toolchain (`composer`/`npm`/`cargo`/`go`/`python`/`ruby`). If you don't
144
+ have it natively but have Docker, run the build steps inside the stack's
145
+ official image (the `.github/workflows/dare-ci.yml` the project ships shows the
146
+ exact commands).
147
+
148
+ Pick **one** of the two paths per stack:
149
+
150
+ | Stack | Native toolchain | Docker fallback (used if native missing) |
151
+ |-------|------------------|------------------------------------------|
152
+ | `ruby-rails-8` | Ruby 3.3+ · Bundler 2+ · Rails 8 — https://www.ruby-lang.org/ | `ruby:3.3-slim` |
153
+ | `php-laravel` | PHP 8.2+ · Composer 2+ — https://getcomposer.org/ | `composer:latest` |
154
+ | `node-nestjs` | Node 18+ (bundles `npx`) | `node:20-alpine` |
155
+ | `python-fastapi` | Python 3.11+ — https://www.python.org/downloads/ | `python:3.12-slim` |
156
+ | `rust-axum` | Rust 1.83+ (rustup) — https://www.rust-lang.org/tools/install | `rust:1.83` |
157
+ | `go-gin` | Go 1.25+ — https://go.dev/dl/ | `golang:1.25` |
158
+ | `go-stdlib` | Go 1.22+ — https://go.dev/dl/ | `golang:1.25` |
159
+ | `react`, `vue` | Node 18+ (bundles `npm`) | `node:20-alpine` |
160
+ | `rust-leptos` | Rust 1.83+ (rustup) + **cargo-leptos 0.2.22** — `cargo install cargo-leptos --version 0.2.22` | `ghcr.io/dewtech-technologies/dare-rust-leptos:1` |
161
+ | `rust-leptos-csr` | Rust 1.83+ (rustup) + **trunk** — `cargo install trunk` | `ghcr.io/dewtech-technologies/dare-rust-leptos:1` |
162
+ | `mcp-node-ts` | Node 18+ | `node:20-alpine` |
163
+ | `mcp-python` | Python 3.11+ | `python:3.12-slim` |
164
+ | `mcp-rust` (beta) | Rust 1.78+ (rustup) | `rust:1.83` |
165
+ | `mcp-go` (beta) | Go 1.23+ — https://go.dev/dl/ | `golang:1.25` |
166
+
167
+ > **v3.3.0:** **Reliable Verification Core** (opt-in via `dare.config.json#verification`)turns the Ralph Loop's "tests pass" gate into "correct & robust": mutation testing, fail-to-pass specs, anti-tamper, a decay-aware loop policy, best-of-N candidate selection over git worktrees, and a `dare bench` regression harness (solve-rate + Fix·Rate). Absent the `verification` block, behavior is unchanged.
168
+
169
+ > **v3.2.0:** full **CLI IDE parity** every one of the 18 CLI commands is invocable as `/dare-<cmd>` across all three IDEs (Cursor, Claude Code, Antigravity); a parity test fails the build if a command is missing a skill. Brownfield commands now **collect real data by default**: `dare reverse`/`dna` extract endpoints + entities and render them into `IDEIA.md` and the module specs (no more skeleton-only artifacts).
170
+
171
+ > **v3.1.0:** all **11 stacks** ship a full generator internalized in `@dewtech/dare-cli` — 7 backend (ruby-rails-8, node-nestjs, python-fastapi, php-laravel, rust-axum, go-gin, go-stdlib) + 4 MCP (mcp-node-ts, mcp-python, mcp-rust, mcp-go). No isolated stack packages; everything is in one publishable tarball (fixes the `npm install -g` 404 of earlier releases). `dare new` was removed — `dare init` is the only scaffolding entrypoint.
172
+
173
+ > **TL;DR:** if you have **Docker Desktop** installed, you don't strictly need
174
+ > any other toolchain — `dare init` will pull the right image on demand.
175
+ > Native toolchains are faster and don't depend on Docker pulling images.
176
+
177
+ If neither the native CLI **nor** Docker is available, `dare init` fails
178
+ fast with a clear error message — it never falls back to a fake template.
179
+
180
+ ### Choose the toolchain at init time
181
+
182
+ The 3 modes (`auto` / `native` / `docker`) are explained in detail at the
183
+ top of this README — see [⚠ Read this first](#-read-this-first--how-dare-init-runs-the-official-scaffold).
184
+
185
+ Quick recap:
186
+
187
+ | Mode | Behavior |
188
+ |------|----------|
189
+ | `auto` (default) | Native if available, else Docker. Recommended. |
190
+ | `native` | Requires the native CLI; fails if missing. |
191
+ | `docker` | Always uses the official Docker image. |
192
+
193
+ The choice is persisted in `dare.config.json` (`"toolchain": "..."`).
194
+ Override at any time:
195
+
196
+ ```bash
197
+ dare bootstrap --toolchain docker # rerun scaffold inside Docker
198
+ dare bootstrap --toolchain native --force # rerun native, overwriting
199
+ ```
200
+
201
+ ### Required for the Ralph Loop (per project)
202
+
203
+ Once the project is scaffolded, every `dare execute --complete` runs the
204
+ stack's gates: `build test lint`. The same toolchain (native or Docker)
205
+ that scaffolded the project is needed to run those gates. Plan accordingly:
206
+ if you chose `php-laravel` and only have Docker, `dare execute --complete`
207
+ needs to invoke `php artisan test` somehow — typically by running it inside
208
+ your `docker-compose` app service (this is the kind of thing the
209
+ `task-001 = Containerize app` task sets up).
210
+
211
+ ## Installation
212
+
213
+ ```bash
214
+ npm install -g @dewtech/dare-cli
215
+ ```
216
+
217
+ ## Commands
218
+
219
+ ### `dare init`
220
+
221
+ Interactive project initialization — creates the full project structure with DARE methodology files, IDE rules and stack templates.
222
+
223
+ ```bash
224
+ dare init my-project
225
+ ```
226
+
227
+ Prompts:
228
+ - **Structure:** Monorepo · Backend only · Frontend only · **MCP Server** new
229
+ - **MCP Server:** language (TypeScript / Python), transport (stdio / SSE / HTTP Stream), capabilities (Tools / Resources / Prompts)
230
+ - **Backend stack:** Rust/Axum · Node.js/NestJS · Python/FastAPI · PHP/Laravel · Go/Gin · Go/stdlib
231
+ - **Frontend stack:** React 18+ · Vue 3+ · Leptos fullstack (Rust SSR+WASM) · Leptos CSR-only (Rust WASM)
232
+ - **Cargo workspace layout** *(Monorepo + Rust/Axum + Leptos only)*: Single-crate (`crates/server` + `crates/web`) · Multi-crate (`{prefix}-core` + `{prefix}-server` + `{prefix}-web` + `{prefix}-cli`) — prefix suggested from project initials (e.g. `ai-runtime-securyti-rasp` → `arsr`)
233
+ - **IDE / Agent:** Claude Code · Cursor · Antigravity · Hybrid
234
+ - **GraphRAG backend:** SQLite · JSON · Neo4j
235
+ - **DARE MCP Server:** context query server (saves ~95% tokens)
236
+
237
+ Generates:
238
+ - `dare.config.json` — project config
239
+ - `CLAUDE.md` + `.claude/commands/` + `.claude/settings.json` — Claude Code rules and slash commands (includes `/dare-security`)
240
+ - `.cursorrules` / `.antigravityrules` — Cursor / Antigravity rules
241
+ - `.cursor/rules/*.mdc`stack-specific skills
242
+ - `.cursor/commands/` — Cursor slash commands
243
+ - `.agents/skills/` Antigravity agent skills
244
+ - `DARE/` — methodology directory (DESIGN, BLUEPRINT, TASKS, dag)
245
+ - Full project template ready to run (MCP server, backend or frontend)
246
+
247
+ ---
248
+
249
+ ### `dare discover` new in v0.3.0
250
+
251
+ Detects an existing project's stack automatically and installs DARE files without touching your source code.
252
+
253
+ ```bash
254
+ # Run inside an existing project
255
+ cd my-existing-project
256
+ dare discover
257
+
258
+ # Inspect only, no changes
259
+ dare discover --check
260
+
261
+ # Target a specific directory
262
+ dare discover --dir ./path/to/project
263
+ ```
264
+
265
+ Auto-detects from: `package.json`, `Cargo.toml`, `requirements.txt`, `pyproject.toml`, `composer.json`.
266
+
267
+ Recognizes: NestJS · React · Vue · Nuxt · Rust/Axum · FastAPI · Laravel · **MCP Server** (`@modelcontextprotocol/sdk`, `FastMCP`).
268
+
269
+ ---
270
+
271
+ ### `dare reverse` brownfield (Phase 0)
272
+
273
+ Reverse-engineer an existing codebase into a Phase-0 understanding **without touching the source**.
274
+ Deterministically detects module boundaries, sizes them by LOC and infers the dependency graph.
275
+
276
+ ```bash
277
+ cd my-legacy-project
278
+ dare reverse # DARE/IDEIA.md + REVERSE/module-*.md + reverse-facts.json + architecture.excalidraw
279
+ dare reverse --check # detection only, no files
280
+ dare reverse --modules api,auth
281
+ dare reverse --no-excalidraw
282
+ ```
283
+
284
+ **Confidence & traceability.** The `/dare-reverse` skill marks each claim 🟢 CONFIRMED (with
285
+ `file:line` evidence) · 🟡 INFERRED · 🔴 GAP. Then:
286
+
287
+ ```bash
288
+ dare reverse --report # deterministic confidence index from the markers (not LLM self-scored)
289
+ ```
290
+
291
+ `confidence-report.md` + `traceability/code-spec-matrix.md`; the 🔴 become `gaps.md` + `questions.md`.
292
+
293
+ **Deep extraction (framework-agnostic per language):**
294
+
295
+ ```bash
296
+ dare reverse --deep # + ERD, API surface, C4, domain-rules, state-machines, permissions
297
+ ```
298
+
299
+ The CLI extracts the data model (`erd.md`) and endpoints (`api-surface.md`) deterministically from
300
+ **SQL inline (DDL + query tables), Prisma, ORMs and plain types/classes/structs** — so it works on
301
+ legacy projects **with or without a framework** (e.g. raw-PDO PHP without Laravel). Routes cover
302
+ multiple dialects per language (Express/Nest/Fastify, Laravel/Slim/Symfony, FastAPI/Flask/Django,
303
+ Rails/Sinatra, Gin/stdlib, Axum).
304
+
305
+ ---
306
+
307
+ ### `dare dna` brownfield
308
+
309
+ Extract the legacy codebase's **conventions** so the agent follows the house style instead of generic
310
+ defaults — for legacy you can't rewrite.
311
+
312
+ ```bash
313
+ cd my-legacy-project
314
+ dare dna # → DARE/PROJECT-DNA.md + dna-facts.json
315
+ dare dna --check
316
+ ```
317
+
318
+ Detects lint/format tooling, naming conventions, architecture layers, test framework, key libraries
319
+ (ORM/HTTP/auth/validation) and commit convention. The `/dare-dna` skill turns the facts into
320
+ actionable rules. Reuses `reverse-facts.json` if `dare reverse` already ran.
321
+
322
+ ---
323
+
324
+ ### `dare migrate` brownfield (Phase 2)
325
+
326
+ Plan a **safe migration** to a target stack, with **Gherkin parity scenarios** that guarantee
327
+ behavior is preserved. Requires `dare reverse` first.
328
+
329
+ ```bash
330
+ cd my-legacy-project
331
+ dare migrate --to go-gin # or rust-axum, node-nestjs, python-fastapi, php-laravel, ruby-rails-8…
332
+ dare migrate --check
333
+ ```
334
+
335
+ Consumes `IDEIA` + `DNA`, inherits the **blocking gaps** (🔴) as risks, and generates
336
+ `DARE/MIGRATION/MIGRATION.md` (paradigm, strategy, risk register, target architecture, cutover) +
337
+ `parity/<module>.feature` (the behavioral acceptance contract). The `/dare-migrate` skill fills the
338
+ strategy and the real parity scenarios.
339
+
340
+ > **Brownfield loop:** `reverse` (the *what*) → `dna` (the *how*) → `migrate` (reimplement with
341
+ > parity) → `design`/`blueprint`/`execute` on the target stack.
342
+
343
+ ---
344
+
345
+ ### `dare design`
346
+
347
+ Generate `DARE/DESIGN.md` from a project description.
348
+
349
+ ```bash
350
+ dare design "Build a REST API for user authentication with JWT"
351
+ ```
352
+
353
+ ---
354
+
355
+ ### `dare blueprint`
356
+
357
+ Generate `DARE/BLUEPRINT.md` from `DESIGN.md`. Stops here — requires human review and approval before tasks are created.
358
+
359
+ ```bash
360
+ dare blueprint
361
+ ```
362
+
363
+ ---
364
+
365
+ ### `dare tasks`
366
+
367
+ Generate `DARE/TASKS.md`, `DARE/dare-dag.yaml` and all `DARE/EXECUTION/task-*.md` specs from an approved `BLUEPRINT.md`. Run this only after reviewing and approving the blueprint.
368
+
369
+ ```bash
370
+ dare tasks
371
+ ```
372
+
373
+ ---
374
+
375
+ ### `dare execute`
376
+
377
+ Orchestrate DAG execution. **The IDE is the executor** (Cursor / Antigravity
378
+ / Claude Code) `dare execute` only coordinates state, composes prompts
379
+ with parent context, updates the live canvas at `DARE/.canvas.md`, and
380
+ ingests finished tasks into the knowledge graph.
381
+
382
+ > **No API keys, no extra token costs.** You use the plan of the IDE you're
383
+ > already logged into.
384
+
385
+ ```bash
386
+ # Print next executable tasks (with composed prompts)
387
+ dare execute --next
388
+
389
+ # Mark a task DONE after the agent finishes it
390
+ dare execute --complete task-001 --output "Created src/auth.ts and tests/auth.test.ts; all tests green."
391
+
392
+ # Mark a task FAILED — descendants are cascade-skipped automatically
393
+ dare execute --fail task-002 --reason "Schema migration conflict in users table"
394
+
395
+ # Reset a task back to PENDING (for retry)
396
+ dare execute --reset task-002
397
+
398
+ # Show snapshot of canvas + summary (default action)
399
+ dare execute --status
400
+ ```
401
+
402
+ #### Typical flow inside the IDE agent
403
+
404
+ ```bash
405
+ dare execute --next # tasks ready in current rank
406
+ # (agent executes each task: code, build, test, lint)
407
+ dare execute --complete task-001 --output "…"
408
+ dare execute --complete task-002 --output "…"
409
+ dare execute --next # → next rank
410
+ # (repeat until "✅ All tasks resolved")
411
+ ```
412
+
413
+ The skills shipped by `dare init` (`.cursor/rules/skill-dag-runner.mdc`,
414
+ `.agents/skills/dare-dag-runner/SKILL.md`, `.claude/commands/dare-dag-run.md`)
415
+ guide the IDE agent through this loop.
416
+
417
+ #### Stack-specific skills
418
+
419
+ `dare init` also ships skills focused on architectural decisions for
420
+ specific stacks. As of v2.15.0:
421
+
422
+ - **`skill-rust-workspace.mdc`** (Cursor) /
423
+ **`dare-rust-workspace/SKILL.md`** (Antigravity) /
424
+ **`/dare-rust-workspace`** (Claude command) guides the agent on
425
+ whether a Rust project should start single-crate or as a Cargo
426
+ workspace, and gives a step-by-step PR-by-PR migration plan when an
427
+ existing single-crate project has outgrown its layout. Active during
428
+ `/dare-design` and `/dare-blueprint` for `rust-axum` projects, plus on
429
+ demand for migration analysis.
430
+
431
+ - **`skill-rust-leptos.mdc`** (Cursor) /
432
+ **`dare-rust-leptos/SKILL.md`** (Antigravity) /
433
+ **`/dare-rust-leptos`** (Claude command) full guide for Leptos
434
+ development: CSR vs fullstack decision table, Leptos 0.7 idioms
435
+ (signals, Resource, Action, Show, For, `#[server]`), shared types with
436
+ `cfg_attr`, mixed workspace configuration (WASM + native crates), and
437
+ antipatterns to avoid (`cargo leptos test` does not exist; no global
438
+ `[build] target` in `.cargo/config.toml`). Ships 3 ready-to-use DARE
439
+ task templates for Leptos projects.
440
+
441
+ ### `dare bootstrap`
442
+
443
+ Lay down a stack's DARE-shaped source on **an existing project** (created in
444
+ older versions or with `--skip-bootstrap`). Reads `dare.config.json` and runs
445
+ the internalized generator for the configured stack — the same one `dare init`
446
+ uses. Frontend stacks (`react` / `vue` / `rust-leptos`) still use their Vite /
447
+ Cargo scaffold.
448
+
449
+ ```bash
450
+ dare bootstrap # refuses if vendor/ or node_modules/ already exist
451
+ dare bootstrap --force # runs anyway (may overwrite framework files)
452
+ ```
453
+
454
+ Your DARE artifacts (`.cursor/`, `DARE/`, `dare.config.json`, `dare-graph.yml`)
455
+ are preserved.
456
+
457
+ ### `dare info`
458
+
459
+ Read-only diagnostic of the current project: CLI version, platform, presence
460
+ of each canonical DARE artifact, active GraphRAG backend, and task progress.
461
+
462
+ ```bash
463
+ dare info
464
+ ```
465
+
466
+ ### `dare review` new in v2.17.0
467
+
468
+ **Anti-stub gate.** Audita os arquivos que uma task tocou e detecta padrões de "fake completeness": `TODO`/`FIXME`, stubs (`throw new Error('not implemented')`, `todo!()`, `NotImplementedError`), funções vazias, retorno-fantasma (`return null` como única statement), mocks fora de testes (`jest.fn`, `vi.mock`, `sinon.stub`, `MagicMock`), comentários-placeholder (`// implement later`).
469
+
470
+ A camada estática (regex, determinística) é só metade. A IDE agent pode rodar a skill `dare-review` / `review-task` para validar critério-a-critério se a implementação atende a spec, emitir um `SemanticVerdict` JSON, e o CLI funde os dois numa única decisão.
471
+
472
+ ```bash
473
+ # Audita os arquivos listados em DARE/EXECUTION/task-034.md
474
+ dare review task-034
475
+
476
+ # Em CI:
477
+ dare review task-034 --strict --format json
478
+
479
+ # Lista explícita de arquivos:
480
+ dare review task-034 --files src/auth/login.ts src/auth/register.ts
481
+
482
+ # Funde com verdito semântico do agente:
483
+ dare review task-034 --from-agent .dare/verdict-task-034.json
484
+ ```
485
+
486
+ **Gate opt-in no Ralph Loop:** com `review.onComplete: true` em `dare.config.json`, `dare execute --complete <id>` bloqueia DONE se a review falhar. Para projetos novos (`dare init` v2.17+) já vem ligado; projetos legados permanecem off até o dev flipar.
487
+
488
+ ### `dare refine` new in v2.17.0
489
+
490
+ **Anti-monstro.** Mede complexidade de uma task e, opcionalmente, propõe quebra em sub-tasks menores. Heurística determinística pesa # arquivos, # funções/endpoints, # testes, # dependências, keywords "pesadas" (refactor/migrate/integrate/multiple) — produz um score em LOW (0–5) / MED (6–12) / HIGH (13–20) / CRITICAL (21+).
491
+
492
+ ```bash
493
+ # Apenas mede e reporta:
494
+ dare refine task-034
495
+
496
+ # Mede + propõe quebra em sub-tasks (task-034a, task-034b, ...):
497
+ dare refine task-034 --split
498
+
499
+ # Anota TASKS.md marcando a task para split (o agente regenera as specs):
500
+ dare refine task-034 --split --apply
501
+
502
+ # Em CI: exit code 2 se HIGH/CRITICAL:
503
+ dare refine task-034 --strict
504
+ ```
505
+
506
+ A camada determinística agrupa arquivos por diretório raiz. A IDE agent (skills `dare-refine` / `refine-task`) refina o split semanticamente — por camada (Model/Controller/Service), por endpoint, por feature, refactor-then-feature, migration-then-code.
507
+
508
+ Thresholds configuráveis em `dare.config.json`:
509
+
510
+ ```jsonc
511
+ {
512
+ "refine": {
513
+ "thresholds": { "low": 5, "med": 12, "high": 20 }
514
+ }
515
+ }
516
+ ```
517
+
518
+ ### `dare update` new in v2.17.0
519
+
520
+ Sync the **project's DARE setup** (templates, slash commands, skills, schema)
521
+ with the version of the CLI currently installed. Useful when you upgrade the
522
+ CLI globally (`npm install -g @dewtech/dare-cli@latest`) and want a previous
523
+ project to pick up the new improvements — **without touching your DESIGN /
524
+ BLUEPRINT / TASKS / dare-dag.yaml artifacts**.
525
+
526
+ Different from upgrading the CLI itself: `npm update -g @dewtech/dare-cli`
527
+ changes the binary on your machine; `dare update` changes the *project files
528
+ on disk* to match what that binary now ships.
529
+
530
+ ```bash
531
+ dare update # interactive (recommended)
532
+ dare update --dry-run # preview: shows changelog + affected files, writes nothing
533
+ dare update --yes # CI: apply, preserve customizations, no prompts
534
+ dare update --force # also overwrite files the dev customized (dangerous)
535
+ dare update --target 2.17.0 # update to a specific release instead of the installed CLI
536
+ ```
537
+
538
+ **What it does:**
539
+
540
+ 1. Reads `version` from `dare.config.json` (the project's last-known DARE version).
541
+ 2. Loads `templates/UPDATE-MANIFEST.json` (ships with the CLI) and lists every
542
+ release between the project's version and the CLI's version.
543
+ 3. Prints the changelog for each pending release and the list of files
544
+ affected for your IDE (cursor / claude-code / antigravity / hybrid).
545
+ 4. For each file, classifies the situation:
546
+ - **identical** → skip
547
+ - **missing** → create
548
+ - **apply** file matches the previous template hash, safe to overwrite
549
+ - **customized** file diverges from the previous template; prompt
550
+ (`keep` / `replace`) unless `--yes` (keep) or `--force` (replace).
551
+ 5. Backs up every affected file to `.dare/backup-<from-version>/` before
552
+ writing.
553
+ 6. Runs any schema migrations declared by the release (e.g. renaming a
554
+ config field).
555
+ 7. Stamps `version` and `updatedAt` in `dare.config.json`.
556
+
557
+ **Adding entries when you cut a release:** each new CLI version that ships
558
+ template changes needs a corresponding entry in `templates/UPDATE-MANIFEST.json`
559
+ listing `changes` (added / modified / removed / renamed) and optional
560
+ `migrations`. The applier filters changes by `appliesTo: [ide]`, so a
561
+ template that's cursor-only won't be installed in a Claude Code project and
562
+ vice versa.
563
+
564
+ ### `dare validate`
565
+
566
+ Static checks on `dare-dag.yaml` ideal for pre-commit hooks and CI.
567
+ Verifies unique kebab-case ids, valid `depends_on`, absence of cycles,
568
+ non-empty prompts, and parallelism (warning when only one task at rank 0).
569
+
570
+ ```bash
571
+ dare validate # errors fail; warnings printed
572
+ dare validate --strict # warnings also fail (CI-friendly)
573
+ ```
574
+
575
+ A pre-commit hook template is shipped at
576
+ `templates/hooks/pre-commit-dare-validate` — copy to `.git/hooks/pre-commit`
577
+ (or use with husky) to validate the DAG before every commit.
578
+
579
+ ### `dare execute --watch`
580
+
581
+ Interactive loop: the CLI watches `.dare/state.json` and re-prints the next
582
+ ready tasks every time the state changes. Pair with the IDE agent firing
583
+ `--complete`/`--fail` from another terminal.
584
+
585
+ ```bash
586
+ dare execute --watch
587
+ ```
588
+
589
+ ### `dare dag`
590
+
591
+ Inspect and visualize the **static task DAG** declared in `dare-dag.yaml` —
592
+ distinct from `dare graph`, which inspects the populated knowledge graph
593
+ (only contains tasks already executed).
594
+
595
+ ```bash
596
+ dare dag viz # Mermaid to stdout
597
+ dare dag viz -o DARE/dag-graph.mmd # Mermaid file
598
+ dare dag viz -f dot -o DARE/dag-graph.dot # DOT (Graphviz)
599
+ ```
600
+
601
+ The Mermaid output groups tasks into rank subgraphs and colors nodes by
602
+ status (`PENDING` / `RUNNING` / `DONE` / `FAILED` / `SKIPPED`), so you can
603
+ **see the execution plan before running any task**.
604
+
605
+ > `dare tasks` writes `DARE/dag-graph.mmd` automatically — open it in
606
+ > your editor with a Mermaid preview to see the static graph immediately.
607
+
608
+ ### `dare graph`
609
+
610
+ Inspect the project's knowledge graph. The graph is populated automatically
611
+ by `dare execute --complete/--fail` (task nodes, file nodes, `depends_on` and
612
+ `implements` edges). Backend is whatever `dare-graph.yml` declares
613
+ (`sqlite` default, `json` available, `neo4j` planned).
614
+
615
+ ```bash
616
+ dare graph stats # totals + breakdown by type
617
+ dare graph query auth # search nodes by label/description
618
+ dare graph query auth --limit 20
619
+
620
+ dare graph viz # Mermaid to stdout
621
+ dare graph viz -f dot # DOT for Graphviz
622
+ dare graph viz -o docs/graph.mmd # write to file
623
+
624
+ dare graph ingest # re-sync from dare-dag.yaml + state
625
+ ```
626
+
627
+ ---
628
+
629
+ ## Full Workflow
630
+
631
+ ```bash
632
+ # New project
633
+ dare init my-project
634
+ cd my-project
635
+ dare design "Describe what you're building"
636
+ dare blueprint
637
+ dare execute --parallel
638
+
639
+ # Existing project
640
+ cd my-existing-project
641
+ dare discover
642
+ dare design "Describe what you're building"
643
+ dare blueprint
644
+ dare execute --parallel
645
+ ```
646
+
647
+ ## Claude Code Workflow
648
+
649
+ ```bash
650
+ dare init my-project
651
+ # → IDE: Claude Code
652
+ # → Structure: Backend / Frontend / MCP Server
653
+
654
+ cd my-project
655
+ # Claude Code slash commands available:
656
+ # /dare-design generates DARE/DESIGN.md
657
+ # /dare-blueprint generates BLUEPRINT.md + DAG
658
+ # /dare-execute task-001 → implements with Ralph Loop
659
+ # /dare-tasks → shows task status table
660
+ ```
661
+
662
+ Files generated for Claude Code:
663
+ ```
664
+ CLAUDE.md main context (stack rules + DARE methodology)
665
+ .claude/
666
+ settings.json permissions + Ralph Loop hook
667
+ commands/
668
+ dare-design.md ← /dare-design
669
+ dare-blueprint.md ← /dare-blueprint
670
+ dare-execute.md ← /dare-execute
671
+ dare-tasks.md ← /dare-tasks
672
+ ```
673
+
674
+ ---
675
+
676
+ ## MCP Server Workflow
677
+
678
+ ```bash
679
+ dare init my-mcp-server
680
+ # → Structure: MCP Server
681
+ # → Language: TypeScript
682
+ # → Transport: stdio
683
+ # → Capabilities: Tools, Resources
684
+
685
+ cd my-mcp-server
686
+ npm install
687
+ dare design "MCP server that exposes ZIP code lookup tools"
688
+ dare blueprint
689
+ dare execute --parallel
690
+
691
+ # Test with MCP Inspector
692
+ npm run inspect
693
+ ```
694
+
695
+ ---
696
+
697
+ ## Performance
698
+
699
+ | Mode | Estimated Time |
700
+ |------|----------------|
701
+ | Sequential | ~280 minutes |
702
+ | Parallel DAG | ~70 minutes |
703
+ | **Improvement** | **75% faster** |
704
+
705
+ ---
706
+
707
+ ## Supported Stacks
708
+
709
+ | Type | Options |
710
+ |------|---------|
711
+ | **Backend** | Ruby on Rails 8 · Rust/Axum · Node.js/NestJS · Python/FastAPI · PHP/Laravel · Go/Gin · Go/stdlib |
712
+ | **Frontend** | React 18+ · Vue 3+ · Leptos fullstack (Rust SSR+WASM) · Leptos CSR (Rust WASM) |
713
+ | **MCP Server** | TypeScript/Node.js · Python — stdio / SSE / HTTP Stream |
714
+ | **IDE / Agent** | Claude Code · Cursor · Antigravity · Hybrid |
715
+
716
+ ---
717
+
718
+ ## Skills disponíveis (v3.0.0)
719
+
720
+ **32 skills em paridade total** nas 3 IDEs (Antigravity, Claude Code, Cursor). Cada skill existe em formato nativo de cada uma e é entregue por `dare init` / `dare update`.
721
+
722
+ | Categoria | Skills | Exemplos |
723
+ |---|---|---|
724
+ | **Método DARE** | 6 | `dare-design`, `dare-blueprint`, `dare-tasks`, `dare-execute`, `dare-review`, `dare-refine` |
725
+ | **DAG runner** | 4 | `dare-dag-build`, `dare-dag-run`, `dare-dag-runner`, `dare-dag-viz` |
726
+ | **Transversais** | 6 | `dare-ax`, `dare-layered-design`, `dare-llm-integration`, `dare-frontend-design`, `dare-realtime`, `dare-quality-telemetry` |
727
+ | **Stack / Tools** | 8 | `dare-docker`, `dare-security`, `dare-telemetry`, `dare-bugfix-design`, `dare-feature-design`, `dare-rust-workspace`, `dare-rust-leptos`, `dare-laravel-api` |
728
+ | **Stacks novas v3.0.0** | 5 | `dare-nestjs-api`, `dare-fastapi-api`, `dare-go-gin-api`, `dare-mcp-server`, `dare-rails-api` |
729
+ | **Brownfield** | 3 | `dare-reverse`, `dare-dna`, `dare-migrate` |
730
+
731
+ Ver tabela cruzada completa em [`docs/skills/INDEX.md`](https://github.com/dewtech-technologies/dare-method/blob/main/docs/skills/INDEX.md).
732
+
733
+ ---
734
+
735
+ ## O que vem com o pacote (v2.0+)
736
+
737
+ A partir da v2.0 o `@dewtech/dare-cli` é um **pacote único** que inclui todas as
738
+ funcionalidades do framework DARE. Você não precisa instalar nada além dele:
739
+
740
+ ```bash
741
+ npm install -g @dewtech/dare-cli
742
+ ```
743
+
744
+ Isso dá:
745
+
746
+ | Componente | O que é |
747
+ |------------|---------|
748
+ | CLI `dare` | `init`, `design`, `blueprint`, `execute`, `discover`, `reverse`, `dna`, `migrate` |
749
+ | CLI `dare-mcp-server` | Servidor MCP local de contexto (~95% economia de tokens) |
750
+ | Engine GraphRAG | Grafo de conhecimento com SQLite + FTS5 |
751
+ | DAG Task Runner | Execução paralela de tasks com Kahn's algorithm |
752
+ | Tipos e templates | Tudo embutido — sem dependências externas do `@dewtech/*` |
753
+
754
+ > **Histórico (v1.x):** os pacotes `@dewtech/dare-core`, `@dewtech/dare-graphrag` e
755
+ > `@dewtech/dare-mcp-server` foram consolidados em `@dewtech/dare-cli` e estão
756
+ > **deprecated** no npm. Não há mais subpacotes para gerenciar.
757
+
758
+ ---
759
+
760
+ ## Links
761
+
762
+ - [GitHub](https://github.com/dewtech-technologies/dare-method)
763
+ - [DARE Methodology](https://github.com/dewtech-technologies/dare-method#-o-método)
764
+ - [Dewtech](https://dewtech.tech)