task-o-matic-core 0.1.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 (447) hide show
  1. package/README.md +646 -0
  2. package/dist/index.d.ts +27 -0
  3. package/dist/index.d.ts.map +1 -0
  4. package/dist/index.js +46 -0
  5. package/dist/lib/ai-service/ai-operations.d.ts +45 -0
  6. package/dist/lib/ai-service/ai-operations.d.ts.map +1 -0
  7. package/dist/lib/ai-service/ai-operations.js +60 -0
  8. package/dist/lib/ai-service/base-operations.d.ts +43 -0
  9. package/dist/lib/ai-service/base-operations.d.ts.map +1 -0
  10. package/dist/lib/ai-service/base-operations.js +119 -0
  11. package/dist/lib/ai-service/documentation-operations.d.ts +18 -0
  12. package/dist/lib/ai-service/documentation-operations.d.ts.map +1 -0
  13. package/dist/lib/ai-service/documentation-operations.js +308 -0
  14. package/dist/lib/ai-service/filesystem-tools.d.ts +69 -0
  15. package/dist/lib/ai-service/filesystem-tools.d.ts.map +1 -0
  16. package/dist/lib/ai-service/filesystem-tools.js +70 -0
  17. package/dist/lib/ai-service/json-parser.d.ts +34 -0
  18. package/dist/lib/ai-service/json-parser.d.ts.map +1 -0
  19. package/dist/lib/ai-service/json-parser.js +177 -0
  20. package/dist/lib/ai-service/mcp-client.d.ts +9 -0
  21. package/dist/lib/ai-service/mcp-client.d.ts.map +1 -0
  22. package/dist/lib/ai-service/mcp-client.js +48 -0
  23. package/dist/lib/ai-service/model-provider.d.ts +12 -0
  24. package/dist/lib/ai-service/model-provider.d.ts.map +1 -0
  25. package/dist/lib/ai-service/model-provider.js +146 -0
  26. package/dist/lib/ai-service/prd-operations.d.ts +25 -0
  27. package/dist/lib/ai-service/prd-operations.d.ts.map +1 -0
  28. package/dist/lib/ai-service/prd-operations.js +592 -0
  29. package/dist/lib/ai-service/research-tools.d.ts +4 -0
  30. package/dist/lib/ai-service/research-tools.d.ts.map +1 -0
  31. package/dist/lib/ai-service/research-tools.js +8 -0
  32. package/dist/lib/ai-service/retry-handler.d.ts +8 -0
  33. package/dist/lib/ai-service/retry-handler.d.ts.map +1 -0
  34. package/dist/lib/ai-service/retry-handler.js +63 -0
  35. package/dist/lib/ai-service/task-operations.d.ts +13 -0
  36. package/dist/lib/ai-service/task-operations.d.ts.map +1 -0
  37. package/dist/lib/ai-service/task-operations.js +220 -0
  38. package/dist/lib/benchmark/registry.d.ts +11 -0
  39. package/dist/lib/benchmark/registry.d.ts.map +1 -0
  40. package/dist/lib/benchmark/registry.js +212 -0
  41. package/dist/lib/benchmark/runner.d.ts +6 -0
  42. package/dist/lib/benchmark/runner.d.ts.map +1 -0
  43. package/dist/lib/benchmark/runner.js +150 -0
  44. package/dist/lib/benchmark/storage.d.ts +13 -0
  45. package/dist/lib/benchmark/storage.d.ts.map +1 -0
  46. package/dist/lib/benchmark/storage.js +100 -0
  47. package/dist/lib/benchmark/types.d.ts +104 -0
  48. package/dist/lib/benchmark/types.d.ts.map +1 -0
  49. package/dist/lib/benchmark/types.js +2 -0
  50. package/dist/lib/better-t-stack-cli.d.ts +50 -0
  51. package/dist/lib/better-t-stack-cli.d.ts.map +1 -0
  52. package/dist/lib/better-t-stack-cli.js +428 -0
  53. package/dist/lib/bootstrap/cli-bootstrap.d.ts +14 -0
  54. package/dist/lib/bootstrap/cli-bootstrap.d.ts.map +1 -0
  55. package/dist/lib/bootstrap/cli-bootstrap.js +322 -0
  56. package/dist/lib/bootstrap/index.d.ts +3 -0
  57. package/dist/lib/bootstrap/index.d.ts.map +1 -0
  58. package/dist/lib/bootstrap/index.js +18 -0
  59. package/dist/lib/bootstrap/medusa-bootstrap.d.ts +14 -0
  60. package/dist/lib/bootstrap/medusa-bootstrap.d.ts.map +1 -0
  61. package/dist/lib/bootstrap/medusa-bootstrap.js +215 -0
  62. package/dist/lib/config-validation.d.ts +215 -0
  63. package/dist/lib/config-validation.d.ts.map +1 -0
  64. package/dist/lib/config-validation.js +254 -0
  65. package/dist/lib/config.d.ts +55 -0
  66. package/dist/lib/config.d.ts.map +1 -0
  67. package/dist/lib/config.js +351 -0
  68. package/dist/lib/context-builder.d.ts +66 -0
  69. package/dist/lib/context-builder.d.ts.map +1 -0
  70. package/dist/lib/context-builder.js +322 -0
  71. package/dist/lib/executors/claude-code-executor.d.ts +9 -0
  72. package/dist/lib/executors/claude-code-executor.d.ts.map +1 -0
  73. package/dist/lib/executors/claude-code-executor.js +69 -0
  74. package/dist/lib/executors/codex-executor.d.ts +9 -0
  75. package/dist/lib/executors/codex-executor.d.ts.map +1 -0
  76. package/dist/lib/executors/codex-executor.js +73 -0
  77. package/dist/lib/executors/executor-factory.d.ts +5 -0
  78. package/dist/lib/executors/executor-factory.d.ts.map +1 -0
  79. package/dist/lib/executors/executor-factory.js +27 -0
  80. package/dist/lib/executors/gemini-executor.d.ts +9 -0
  81. package/dist/lib/executors/gemini-executor.d.ts.map +1 -0
  82. package/dist/lib/executors/gemini-executor.js +67 -0
  83. package/dist/lib/executors/kilo-executor.d.ts +9 -0
  84. package/dist/lib/executors/kilo-executor.d.ts.map +1 -0
  85. package/dist/lib/executors/kilo-executor.js +69 -0
  86. package/dist/lib/executors/opencode-executor.d.ts +9 -0
  87. package/dist/lib/executors/opencode-executor.d.ts.map +1 -0
  88. package/dist/lib/executors/opencode-executor.js +67 -0
  89. package/dist/lib/git-utils.d.ts +88 -0
  90. package/dist/lib/git-utils.d.ts.map +1 -0
  91. package/dist/lib/git-utils.js +242 -0
  92. package/dist/lib/hooks.d.ts +73 -0
  93. package/dist/lib/hooks.d.ts.map +1 -0
  94. package/dist/lib/hooks.js +62 -0
  95. package/dist/lib/index.d.ts +100 -0
  96. package/dist/lib/index.d.ts.map +1 -0
  97. package/dist/lib/index.js +143 -0
  98. package/dist/lib/logger.d.ts +20 -0
  99. package/dist/lib/logger.d.ts.map +1 -0
  100. package/dist/lib/logger.js +32 -0
  101. package/dist/lib/notifications.d.ts +7 -0
  102. package/dist/lib/notifications.d.ts.map +1 -0
  103. package/dist/lib/notifications.js +81 -0
  104. package/dist/lib/prompt-builder.d.ts +70 -0
  105. package/dist/lib/prompt-builder.d.ts.map +1 -0
  106. package/dist/lib/prompt-builder.js +344 -0
  107. package/dist/lib/prompt-registry.d.ts +22 -0
  108. package/dist/lib/prompt-registry.d.ts.map +1 -0
  109. package/dist/lib/prompt-registry.js +409 -0
  110. package/dist/lib/provider-defaults.json +32 -0
  111. package/dist/lib/storage/file-system.d.ts +57 -0
  112. package/dist/lib/storage/file-system.d.ts.map +1 -0
  113. package/dist/lib/storage/file-system.js +638 -0
  114. package/dist/lib/storage/storage-callbacks.d.ts +17 -0
  115. package/dist/lib/storage/storage-callbacks.d.ts.map +1 -0
  116. package/dist/lib/storage/storage-callbacks.js +94 -0
  117. package/dist/lib/storage/types.d.ts +43 -0
  118. package/dist/lib/storage/types.d.ts.map +1 -0
  119. package/dist/lib/storage/types.js +2 -0
  120. package/dist/lib/task-execution-core.d.ts +7 -0
  121. package/dist/lib/task-execution-core.d.ts.map +1 -0
  122. package/dist/lib/task-execution-core.js +381 -0
  123. package/dist/lib/task-execution.d.ts +7 -0
  124. package/dist/lib/task-execution.d.ts.map +1 -0
  125. package/dist/lib/task-execution.js +40 -0
  126. package/dist/lib/task-loop-execution.d.ts +7 -0
  127. package/dist/lib/task-loop-execution.d.ts.map +1 -0
  128. package/dist/lib/task-loop-execution.js +156 -0
  129. package/dist/lib/task-planning.d.ts +29 -0
  130. package/dist/lib/task-planning.d.ts.map +1 -0
  131. package/dist/lib/task-planning.js +103 -0
  132. package/dist/lib/task-review.d.ts +27 -0
  133. package/dist/lib/task-review.d.ts.map +1 -0
  134. package/dist/lib/task-review.js +103 -0
  135. package/dist/lib/validation.d.ts +26 -0
  136. package/dist/lib/validation.d.ts.map +1 -0
  137. package/dist/lib/validation.js +98 -0
  138. package/dist/prompts/documentation-detection.d.ts +2 -0
  139. package/dist/prompts/documentation-detection.d.ts.map +1 -0
  140. package/dist/prompts/documentation-detection.js +24 -0
  141. package/dist/prompts/documentation-recap.d.ts +3 -0
  142. package/dist/prompts/documentation-recap.d.ts.map +1 -0
  143. package/dist/prompts/documentation-recap.js +13 -0
  144. package/dist/prompts/index.d.ts +15 -0
  145. package/dist/prompts/index.d.ts.map +1 -0
  146. package/dist/prompts/index.js +30 -0
  147. package/dist/prompts/prd-combination.d.ts +2 -0
  148. package/dist/prompts/prd-combination.d.ts.map +1 -0
  149. package/dist/prompts/prd-combination.js +35 -0
  150. package/dist/prompts/prd-generation.d.ts +2 -0
  151. package/dist/prompts/prd-generation.d.ts.map +1 -0
  152. package/dist/prompts/prd-generation.js +49 -0
  153. package/dist/prompts/prd-parsing.d.ts +3 -0
  154. package/dist/prompts/prd-parsing.d.ts.map +1 -0
  155. package/dist/prompts/prd-parsing.js +172 -0
  156. package/dist/prompts/prd-question-answer.d.ts +3 -0
  157. package/dist/prompts/prd-question-answer.d.ts.map +1 -0
  158. package/dist/prompts/prd-question-answer.js +27 -0
  159. package/dist/prompts/prd-question.d.ts +3 -0
  160. package/dist/prompts/prd-question.d.ts.map +1 -0
  161. package/dist/prompts/prd-question.js +40 -0
  162. package/dist/prompts/prd-rework.d.ts +3 -0
  163. package/dist/prompts/prd-rework.d.ts.map +1 -0
  164. package/dist/prompts/prd-rework.js +81 -0
  165. package/dist/prompts/prd-suggest-stack.d.ts +3 -0
  166. package/dist/prompts/prd-suggest-stack.d.ts.map +1 -0
  167. package/dist/prompts/prd-suggest-stack.js +99 -0
  168. package/dist/prompts/task-breakdown.d.ts +3 -0
  169. package/dist/prompts/task-breakdown.d.ts.map +1 -0
  170. package/dist/prompts/task-breakdown.js +151 -0
  171. package/dist/prompts/task-enhancement.d.ts +3 -0
  172. package/dist/prompts/task-enhancement.d.ts.map +1 -0
  173. package/dist/prompts/task-enhancement.js +140 -0
  174. package/dist/prompts/task-execution.d.ts +3 -0
  175. package/dist/prompts/task-execution.d.ts.map +1 -0
  176. package/dist/prompts/task-execution.js +24 -0
  177. package/dist/prompts/task-planning.d.ts +3 -0
  178. package/dist/prompts/task-planning.d.ts.map +1 -0
  179. package/dist/prompts/task-planning.js +66 -0
  180. package/dist/prompts/workflow-assistance.d.ts +32 -0
  181. package/dist/prompts/workflow-assistance.d.ts.map +1 -0
  182. package/dist/prompts/workflow-assistance.js +130 -0
  183. package/dist/prompts/workflow-prompts.d.ts +9 -0
  184. package/dist/prompts/workflow-prompts.d.ts.map +1 -0
  185. package/dist/prompts/workflow-prompts.js +93 -0
  186. package/dist/services/benchmark.d.ts +26 -0
  187. package/dist/services/benchmark.d.ts.map +1 -0
  188. package/dist/services/benchmark.js +343 -0
  189. package/dist/services/prd.d.ts +136 -0
  190. package/dist/services/prd.d.ts.map +1 -0
  191. package/dist/services/prd.js +550 -0
  192. package/dist/services/tasks.d.ts +388 -0
  193. package/dist/services/tasks.d.ts.map +1 -0
  194. package/dist/services/tasks.js +1150 -0
  195. package/dist/services/workflow-ai-assistant.d.ts +74 -0
  196. package/dist/services/workflow-ai-assistant.d.ts.map +1 -0
  197. package/dist/services/workflow-ai-assistant.js +175 -0
  198. package/dist/services/workflow-benchmark.d.ts +34 -0
  199. package/dist/services/workflow-benchmark.d.ts.map +1 -0
  200. package/dist/services/workflow-benchmark.js +318 -0
  201. package/dist/services/workflow.d.ts +107 -0
  202. package/dist/services/workflow.d.ts.map +1 -0
  203. package/dist/services/workflow.js +580 -0
  204. package/dist/test/hooks.test.d.ts +2 -0
  205. package/dist/test/hooks.test.d.ts.map +1 -0
  206. package/dist/test/hooks.test.js +67 -0
  207. package/dist/test/integration/callbacks.test.d.ts +2 -0
  208. package/dist/test/integration/callbacks.test.d.ts.map +1 -0
  209. package/dist/test/integration/callbacks.test.js +64 -0
  210. package/dist/test/lib/ai-service/task-operations.test.d.ts +2 -0
  211. package/dist/test/lib/ai-service/task-operations.test.d.ts.map +1 -0
  212. package/dist/test/lib/ai-service/task-operations.test.js +362 -0
  213. package/dist/test/lib/config.test.d.ts +2 -0
  214. package/dist/test/lib/config.test.d.ts.map +1 -0
  215. package/dist/test/lib/config.test.js +128 -0
  216. package/dist/test/lib/git-utils.test.d.ts +2 -0
  217. package/dist/test/lib/git-utils.test.d.ts.map +1 -0
  218. package/dist/test/lib/git-utils.test.js +168 -0
  219. package/dist/test/mocks/mock-ai-operations.d.ts +15 -0
  220. package/dist/test/mocks/mock-ai-operations.d.ts.map +1 -0
  221. package/dist/test/mocks/mock-ai-operations.js +107 -0
  222. package/dist/test/mocks/mock-context-builder.d.ts +10 -0
  223. package/dist/test/mocks/mock-context-builder.d.ts.map +1 -0
  224. package/dist/test/mocks/mock-context-builder.js +81 -0
  225. package/dist/test/mocks/mock-model-provider.d.ts +7 -0
  226. package/dist/test/mocks/mock-model-provider.d.ts.map +1 -0
  227. package/dist/test/mocks/mock-model-provider.js +21 -0
  228. package/dist/test/mocks/mock-service-factory.d.ts +11 -0
  229. package/dist/test/mocks/mock-service-factory.d.ts.map +1 -0
  230. package/dist/test/mocks/mock-service-factory.js +61 -0
  231. package/dist/test/mocks/mock-storage.d.ts +50 -0
  232. package/dist/test/mocks/mock-storage.d.ts.map +1 -0
  233. package/dist/test/mocks/mock-storage.js +145 -0
  234. package/dist/test/model-parsing.test.d.ts +2 -0
  235. package/dist/test/model-parsing.test.d.ts.map +1 -0
  236. package/dist/test/model-parsing.test.js +73 -0
  237. package/dist/test/services/task-service.test.d.ts +2 -0
  238. package/dist/test/services/task-service.test.d.ts.map +1 -0
  239. package/dist/test/services/task-service.test.js +459 -0
  240. package/dist/test/storage.test.d.ts +2 -0
  241. package/dist/test/storage.test.d.ts.map +1 -0
  242. package/dist/test/storage.test.js +207 -0
  243. package/dist/test/task-loop-git.test.d.ts +2 -0
  244. package/dist/test/task-loop-git.test.d.ts.map +1 -0
  245. package/dist/test/task-loop-git.test.js +95 -0
  246. package/dist/test/test-mock-setup.d.ts +26 -0
  247. package/dist/test/test-mock-setup.d.ts.map +1 -0
  248. package/dist/test/test-mock-setup.js +41 -0
  249. package/dist/test/test-setup.d.ts +9 -0
  250. package/dist/test/test-setup.d.ts.map +1 -0
  251. package/dist/test/test-setup.js +44 -0
  252. package/dist/test/test-utils.d.ts +22 -0
  253. package/dist/test/test-utils.d.ts.map +1 -0
  254. package/dist/test/test-utils.js +37 -0
  255. package/dist/test/utils/ai-operation-utility.test.d.ts +2 -0
  256. package/dist/test/utils/ai-operation-utility.test.d.ts.map +1 -0
  257. package/dist/test/utils/ai-operation-utility.test.js +290 -0
  258. package/dist/test/utils/error-handling.test.d.ts +2 -0
  259. package/dist/test/utils/error-handling.test.d.ts.map +1 -0
  260. package/dist/test/utils/error-handling.test.js +231 -0
  261. package/dist/test/utils/file-utils.test.d.ts +2 -0
  262. package/dist/test/utils/file-utils.test.d.ts.map +1 -0
  263. package/dist/test/utils/file-utils.test.js +76 -0
  264. package/dist/test/utils/id-generator.test.d.ts +2 -0
  265. package/dist/test/utils/id-generator.test.d.ts.map +1 -0
  266. package/dist/test/utils/id-generator.test.js +41 -0
  267. package/dist/test/utils/model-parser.test.d.ts +2 -0
  268. package/dist/test/utils/model-parser.test.d.ts.map +1 -0
  269. package/dist/test/utils/model-parser.test.js +65 -0
  270. package/dist/test/validation.test.d.ts +2 -0
  271. package/dist/test/validation.test.d.ts.map +1 -0
  272. package/dist/test/validation.test.js +22 -0
  273. package/dist/types/callbacks.d.ts +30 -0
  274. package/dist/types/callbacks.d.ts.map +1 -0
  275. package/dist/types/callbacks.js +2 -0
  276. package/dist/types/index.d.ts +435 -0
  277. package/dist/types/index.d.ts.map +1 -0
  278. package/dist/types/index.js +30 -0
  279. package/dist/types/mcp.d.ts +3 -0
  280. package/dist/types/mcp.d.ts.map +1 -0
  281. package/dist/types/mcp.js +3 -0
  282. package/dist/types/options.d.ts +112 -0
  283. package/dist/types/options.d.ts.map +1 -0
  284. package/dist/types/options.js +2 -0
  285. package/dist/types/results.d.ts +200 -0
  286. package/dist/types/results.d.ts.map +1 -0
  287. package/dist/types/results.js +2 -0
  288. package/dist/types/workflow-options.d.ts +82 -0
  289. package/dist/types/workflow-options.d.ts.map +1 -0
  290. package/dist/types/workflow-options.js +2 -0
  291. package/dist/types/workflow-results.d.ts +82 -0
  292. package/dist/types/workflow-results.d.ts.map +1 -0
  293. package/dist/types/workflow-results.js +2 -0
  294. package/dist/utils/ai-config-builder.d.ts +14 -0
  295. package/dist/utils/ai-config-builder.d.ts.map +1 -0
  296. package/dist/utils/ai-config-builder.js +22 -0
  297. package/dist/utils/ai-operation-utility.d.ts +142 -0
  298. package/dist/utils/ai-operation-utility.d.ts.map +1 -0
  299. package/dist/utils/ai-operation-utility.js +303 -0
  300. package/dist/utils/ai-service-factory.d.ts +34 -0
  301. package/dist/utils/ai-service-factory.d.ts.map +1 -0
  302. package/dist/utils/ai-service-factory.js +99 -0
  303. package/dist/utils/error-utils.d.ts +70 -0
  304. package/dist/utils/error-utils.d.ts.map +1 -0
  305. package/dist/utils/error-utils.js +104 -0
  306. package/dist/utils/file-utils.d.ts +107 -0
  307. package/dist/utils/file-utils.d.ts.map +1 -0
  308. package/dist/utils/file-utils.js +171 -0
  309. package/dist/utils/id-generator.d.ts +92 -0
  310. package/dist/utils/id-generator.d.ts.map +1 -0
  311. package/dist/utils/id-generator.js +146 -0
  312. package/dist/utils/metadata-utils.d.ts +40 -0
  313. package/dist/utils/metadata-utils.d.ts.map +1 -0
  314. package/dist/utils/metadata-utils.js +43 -0
  315. package/dist/utils/model-executor-parser.d.ts +38 -0
  316. package/dist/utils/model-executor-parser.d.ts.map +1 -0
  317. package/dist/utils/model-executor-parser.js +69 -0
  318. package/dist/utils/model-parser.d.ts +6 -0
  319. package/dist/utils/model-parser.d.ts.map +1 -0
  320. package/dist/utils/model-parser.js +49 -0
  321. package/dist/utils/stack-formatter.d.ts +12 -0
  322. package/dist/utils/stack-formatter.d.ts.map +1 -0
  323. package/dist/utils/stack-formatter.js +36 -0
  324. package/dist/utils/storage-utils.d.ts +49 -0
  325. package/dist/utils/storage-utils.d.ts.map +1 -0
  326. package/dist/utils/storage-utils.js +80 -0
  327. package/dist/utils/streaming-utils.d.ts +38 -0
  328. package/dist/utils/streaming-utils.d.ts.map +1 -0
  329. package/dist/utils/streaming-utils.js +64 -0
  330. package/dist/utils/task-o-matic-error.d.ts +206 -0
  331. package/dist/utils/task-o-matic-error.d.ts.map +1 -0
  332. package/dist/utils/task-o-matic-error.js +304 -0
  333. package/package.json +40 -0
  334. package/src/index.ts +36 -0
  335. package/src/lib/ai-service/ai-operations.ts +310 -0
  336. package/src/lib/ai-service/base-operations.ts +139 -0
  337. package/src/lib/ai-service/documentation-operations.ts +438 -0
  338. package/src/lib/ai-service/filesystem-tools.ts +73 -0
  339. package/src/lib/ai-service/gemini-proxy.ts.bak +52 -0
  340. package/src/lib/ai-service/json-parser.ts +203 -0
  341. package/src/lib/ai-service/mcp-client.ts +54 -0
  342. package/src/lib/ai-service/model-provider.ts +192 -0
  343. package/src/lib/ai-service/prd-operations.ts +854 -0
  344. package/src/lib/ai-service/research-tools.ts +207 -0
  345. package/src/lib/ai-service/retry-handler.ts +89 -0
  346. package/src/lib/ai-service/task-operations.ts +342 -0
  347. package/src/lib/benchmark/registry.ts +307 -0
  348. package/src/lib/benchmark/runner.ts +190 -0
  349. package/src/lib/benchmark/storage.ts +140 -0
  350. package/src/lib/benchmark/types.ts +121 -0
  351. package/src/lib/better-t-stack-cli.ts +524 -0
  352. package/src/lib/bootstrap/cli-bootstrap.ts +397 -0
  353. package/src/lib/bootstrap/index.ts +2 -0
  354. package/src/lib/bootstrap/medusa-bootstrap.ts +261 -0
  355. package/src/lib/config-validation.ts +278 -0
  356. package/src/lib/config.ts +435 -0
  357. package/src/lib/context-builder.ts +383 -0
  358. package/src/lib/executors/claude-code-executor.ts +83 -0
  359. package/src/lib/executors/codex-executor.ts +85 -0
  360. package/src/lib/executors/executor-factory.ts +28 -0
  361. package/src/lib/executors/gemini-executor.ts +80 -0
  362. package/src/lib/executors/kilo-executor.ts +83 -0
  363. package/src/lib/executors/opencode-executor.ts +81 -0
  364. package/src/lib/git-utils.ts +334 -0
  365. package/src/lib/hooks.ts +121 -0
  366. package/src/lib/index.ts +166 -0
  367. package/src/lib/logger.ts +43 -0
  368. package/src/lib/notifications.ts +103 -0
  369. package/src/lib/prompt-builder.ts +471 -0
  370. package/src/lib/prompt-registry.ts +491 -0
  371. package/src/lib/provider-defaults.json +32 -0
  372. package/src/lib/storage/file-system.ts +864 -0
  373. package/src/lib/storage/storage-callbacks.ts +120 -0
  374. package/src/lib/storage/types.ts +58 -0
  375. package/src/lib/task-execution-core.ts +591 -0
  376. package/src/lib/task-execution.ts +59 -0
  377. package/src/lib/task-loop-execution.ts +214 -0
  378. package/src/lib/task-planning.ts +157 -0
  379. package/src/lib/task-review.ts +138 -0
  380. package/src/lib/validation.ts +140 -0
  381. package/src/prompts/documentation-detection.ts +21 -0
  382. package/src/prompts/documentation-recap.ts +11 -0
  383. package/src/prompts/index.ts +14 -0
  384. package/src/prompts/prd-combination.ts +32 -0
  385. package/src/prompts/prd-generation.ts +46 -0
  386. package/src/prompts/prd-parsing.ts +170 -0
  387. package/src/prompts/prd-question-answer.ts +25 -0
  388. package/src/prompts/prd-question.ts +38 -0
  389. package/src/prompts/prd-rework.ts +79 -0
  390. package/src/prompts/prd-suggest-stack.ts +97 -0
  391. package/src/prompts/task-breakdown.ts +149 -0
  392. package/src/prompts/task-enhancement.ts +138 -0
  393. package/src/prompts/task-execution.ts +22 -0
  394. package/src/prompts/task-planning.ts +64 -0
  395. package/src/prompts/workflow-assistance.ts +151 -0
  396. package/src/prompts/workflow-prompts.ts +97 -0
  397. package/src/services/benchmark.ts +433 -0
  398. package/src/services/prd.ts +845 -0
  399. package/src/services/tasks.ts +1515 -0
  400. package/src/services/workflow-ai-assistant.ts +298 -0
  401. package/src/services/workflow-benchmark.ts +339 -0
  402. package/src/services/workflow.ts +779 -0
  403. package/src/test/hooks.test.ts +77 -0
  404. package/src/test/integration/callbacks.test.ts +39 -0
  405. package/src/test/lib/ai-service/task-operations.test.ts +430 -0
  406. package/src/test/lib/config.test.ts +150 -0
  407. package/src/test/lib/git-utils.test.ts +198 -0
  408. package/src/test/mocks/mock-ai-operations.ts +205 -0
  409. package/src/test/mocks/mock-context-builder.ts +84 -0
  410. package/src/test/mocks/mock-model-provider.ts +21 -0
  411. package/src/test/mocks/mock-service-factory.ts +64 -0
  412. package/src/test/mocks/mock-storage.ts +204 -0
  413. package/src/test/model-parsing.test.ts +78 -0
  414. package/src/test/services/task-service.test.ts +551 -0
  415. package/src/test/storage.test.ts +206 -0
  416. package/src/test/task-loop-git.test.ts +142 -0
  417. package/src/test/test-mock-setup.ts +46 -0
  418. package/src/test/test-setup.ts +48 -0
  419. package/src/test/test-utils.ts +45 -0
  420. package/src/test/utils/ai-operation-utility.test.ts +306 -0
  421. package/src/test/utils/error-handling.test.ts +241 -0
  422. package/src/test/utils/file-utils.test.ts +80 -0
  423. package/src/test/utils/id-generator.test.ts +44 -0
  424. package/src/test/utils/model-parser.test.ts +67 -0
  425. package/src/test/validation.test.ts +19 -0
  426. package/src/types/callbacks.ts +14 -0
  427. package/src/types/index.ts +628 -0
  428. package/src/types/mcp.ts +5 -0
  429. package/src/types/options.ts +165 -0
  430. package/src/types/results.ts +216 -0
  431. package/src/types/workflow-options.ts +113 -0
  432. package/src/types/workflow-results.ts +87 -0
  433. package/src/utils/ai-config-builder.ts +33 -0
  434. package/src/utils/ai-operation-utility.ts +380 -0
  435. package/src/utils/ai-service-factory.ts +125 -0
  436. package/src/utils/error-utils.ts +124 -0
  437. package/src/utils/file-utils.ts +197 -0
  438. package/src/utils/id-generator.ts +168 -0
  439. package/src/utils/metadata-utils.ts +48 -0
  440. package/src/utils/model-executor-parser.ts +80 -0
  441. package/src/utils/model-parser.ts +58 -0
  442. package/src/utils/stack-formatter.ts +53 -0
  443. package/src/utils/storage-utils.ts +94 -0
  444. package/src/utils/streaming-utils.ts +91 -0
  445. package/src/utils/task-o-matic-error.ts +393 -0
  446. package/tsconfig.json +20 -0
  447. package/tsconfig.tsbuildinfo +1 -0
@@ -0,0 +1,151 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.TASK_BREAKDOWN_SYSTEM_PROMPT = exports.TASK_BREAKDOWN_PROMPT = void 0;
4
+ exports.TASK_BREAKDOWN_PROMPT = `
5
+ You are a project management expert. Break down the following 1-3 week development phase into focused 1-3 day subtasks.
6
+
7
+ ## 🚨 REQUIREMENTS - 1-3 DAYS PER SUBTASK 🚨
8
+
9
+ Each subtask MUST represent 1-3 DAYS of focused developer work. Each subtask should be a complete, deliverable piece of functionality.
10
+
11
+ ### SUBTASK SCOPE (1-3 DAYS EACH):
12
+ - ✅ Complete feature implementations with full stack components
13
+ - ✅ Focused modules that can be demonstrated and tested independently
14
+ - ✅ Specific deliverables that contribute meaningfully to the parent phase
15
+
16
+ ### EXAMPLE SUBTASKS (1-3 DAYS):
17
+ - ✅ "User authentication system with registration, login, password reset, database schema, API endpoints, and frontend forms"
18
+ - ✅ "Interactive map component with location search, marker display, geolocation, and integration with bakery data"
19
+ - ✅ "Rating system with star ratings, review submission, validation, storage, and display components"
20
+
21
+ ## CRITICAL: Subtask ID and Dependency Format
22
+ You MUST generate unique subtask IDs and reference them properly in dependencies:
23
+
24
+ 1. **Subtask ID Generation**:
25
+ - Each subtask must have an "id" field with format "N.M" where N is the parent task ID and M is the subtask index
26
+ - For example: "1.1", "1.2", "1.3", etc.
27
+ - IDs must be sequential starting from .1
28
+ - Each subtask ID must be unique
29
+
30
+ 2. **Dependency References**:
31
+ - Dependencies MUST reference the exact subtask IDs (not titles)
32
+ - Use format: ["1.1", "1.2"]
33
+ - NEVER use subtask titles in dependencies
34
+ - Only reference subtasks that appear EARLIER in the list
35
+ - The first subtask should have no dependencies
36
+
37
+ ## CRITICAL: Avoid Duplicate Subtasks
38
+ If existing subtasks are listed below, DO NOT create similar or duplicate subtasks. Focus on creating NEW subtasks that complement the existing ones.
39
+
40
+ ## TASK SIZING - 1-3 DAYS:
41
+ - **1 DAY (8 hours)**: Focused feature with clear boundaries. Example: "Build user registration and login with database, API, and frontend forms"
42
+ - **2 DAYS (16 hours)**: Complex feature with multiple components. Example: "Implement map integration with search, markers, and user location"
43
+ - **3 DAYS (24 hours)**: Comprehensive feature with advanced functionality. Example: "Create complete rating system with reviews, validation, and admin moderation"
44
+
45
+ ## 🚨 VALIDATION 🚨
46
+ Each subtask must be substantial enough to occupy a developer for 1-3 full days and represent meaningful, demonstrable progress.
47
+
48
+ Format your response as JSON:
49
+ {
50
+ "subtasks": [
51
+ {
52
+ "id": "1.1",
53
+ "title": "Build user authentication system",
54
+ "description": "Implement user registration, login/logout, password reset, database schema, secure API endpoints, and responsive frontend forms with proper validation and error handling",
55
+ "effort": "medium",
56
+ "dependencies": []
57
+ },
58
+ {
59
+ "id": "1.2",
60
+ "title": "Create interactive map integration",
61
+ "description": "Implement map component with bakery location markers, search functionality, geolocation support, and responsive design for mobile and desktop",
62
+ "effort": "medium",
63
+ "dependencies": ["1.1"]
64
+ }
65
+ ]
66
+ }
67
+
68
+ ## Task Details:
69
+ Title: {TASK_TITLE}
70
+ Description: {TASK_DESCRIPTION}
71
+
72
+ ## Full Task Content:
73
+ {TASK_CONTENT}
74
+
75
+ ## Technical Stack Context:
76
+ {STACK_INFO}
77
+
78
+ ## Existing Subtasks (DO NOT DUPLICATE):
79
+ {EXISTING_SUBTASKS}
80
+ `;
81
+ exports.TASK_BREAKDOWN_SYSTEM_PROMPT = `
82
+ 🚨 CRITICAL SYSTEM PROMPT - BREAK DOWN PHASES INTO 1-3 DAY SUBTASKS 🚨
83
+
84
+ You are an expert technical project manager and software architect. Your role is to break down 1-3 week development phases into focused subtasks that represent 1-3 DAYS of work each.
85
+
86
+ ## MANDATE: PROPER SUBTASK SIZING
87
+ Break down the parent phase into substantial subtasks that each represent 1-3 full days of focused development work.
88
+
89
+ ### SUBTASK SCOPE (1-3 DAYS EACH):
90
+ - Complete features that can be demonstrated independently
91
+ - Focused modules with clear deliverables and boundaries
92
+ - Specific functionality that contributes meaningfully to the parent phase
93
+
94
+ ### SUBTASK EXAMPLES (1-3 DAYS):
95
+ - "User authentication system with registration, login, password reset, database schema, API endpoints, and frontend forms"
96
+ - "Interactive map component with location search, markers, geolocation, and mobile responsiveness"
97
+ - "Rating system with star ratings, review submission, validation, storage, and display components"
98
+
99
+ ## CRITICAL INSTRUCTION: Subtask ID Generation and Dependencies
100
+ You MUST generate unique subtask IDs and use them for dependencies:
101
+
102
+ 1. **Generate Subtask IDs**:
103
+ - Each subtask needs an "id" field: "N.M" format where N is parent task ID, M is subtask index
104
+ - For example: "1.1", "1.2", "1.3", etc.
105
+ - IDs must be sequential and unique
106
+ - Start with .1 for the first subtask
107
+
108
+ 2. **Dependency References**:
109
+ - Use the exact subtask IDs in dependencies arrays
110
+ - NEVER use subtask titles
111
+ - Only reference earlier subtasks (lower numbers)
112
+ - The first subtask must have no dependencies
113
+
114
+ 3. **Required Fields for Each Subtask**:
115
+ - id: "N.M" format (required)
116
+ - title: string (required)
117
+ - description: string (required)
118
+ - effort: "small"|"medium"|"large" (required)
119
+ - dependencies: array of subtask IDs (required)
120
+
121
+ ## CRITICAL: Avoid Duplicate Subtasks
122
+ If existing subtasks are provided in the context, DO NOT create similar or duplicate subtasks. Analyze the existing subtasks and create NEW ones that complement them.
123
+
124
+ ## TASK SIZING - 1-3 DAYS:
125
+ - **small (1 day/8 hours)**: Focused feature with clear boundaries and deliverables
126
+ - **medium (2 days/16 hours)**: Complex feature with multiple components and integrations
127
+ - **large (3 days/24 hours)**: Comprehensive feature with advanced functionality and polish
128
+
129
+ ## VALIDATION CHECKLIST:
130
+ Before returning your response, verify each subtask:
131
+ 1. Represents 1-3 FULL DAYS of focused development work
132
+ 2. Is a complete, deliverable feature or module
133
+ 3. Can be demonstrated and tested independently
134
+ 4. Contributes meaningfully to the parent phase
135
+ 5. Has clear boundaries and specific outcomes
136
+
137
+ ## Output Validation:
138
+ Before returning your response, verify:
139
+ 1. Every subtask has a unique sequential ID ("1.1", "1.2", etc.)
140
+ 2. All dependency arrays contain valid subtask IDs (not titles)
141
+ 3. No subtask depends on itself or a later subtask
142
+ 4. The first subtask has no dependencies
143
+ 5. All referenced subtask IDs exist in the subtasks array
144
+ 6. Each subtask represents 1-3 days of substantial work
145
+ 7. JSON structure is valid and parseable
146
+ 8. No duplicate subtasks based on existing subtasks in context
147
+
148
+ Return only valid JSON that can be parsed. Ensure all required fields are present and properly formatted.
149
+
150
+ 🚨 REMINDER: BREAK PHASES INTO 1-3 DAY SUBTASKS! 🚨
151
+ `;
@@ -0,0 +1,3 @@
1
+ export declare const TASK_ENHANCEMENT_PROMPT = "\nEnhance this task for better clarity and actionability using Context7 documentation and the specific project context:\n\n## Task Information:\n**Title**: {TASK_TITLE}\n**Description**: {TASK_DESCRIPTION}\n\n## Project Context:\n{CONTEXT_INFO}\n\n## Product Requirements Context:\n{PRD_CONTENT}\n\n## Available Research & Documentation:\n{EXISTING_RESEARCH}\n\n## Enhancement Requirements:\n\nProvide an improved task description that includes:\n\n### 1. **Clear Implementation Scope**\n- Specific deliverables and outcomes\n- Boundaries of what's included/excluded\n- Integration points with existing systems\n- File locations and project structure considerations\n- Alignment with broader product requirements from PRD\n\n### 2. **Stack-Specific Implementation Details**\n- Leverage the existing technology stack (frontend: {FRONTEND}, backend: {BACKEND}, auth: {AUTH})\n- Use stack-specific patterns and conventions\n- Integrate with existing project architecture\n- Consider addon capabilities ({ADDONS})\n\n### 3. **Technical Implementation Guidance**\n- Specific libraries, frameworks, or APIs to use based on the stack\n- Code structure and architectural considerations\n- Performance and security requirements\n- Database/ORM considerations if applicable\n- PRD-aligned technical specifications\n\n### 4. **Acceptance Criteria**\n- Measurable conditions for task completion\n- Test scenarios and expected outcomes\n- Definition of \"done\" with specific metrics\n- Stack-specific validation requirements\n- PRD requirement fulfillment criteria\n\n### 5. **Implementation Approach**\n- Step-by-step implementation strategy\n- Key technical decisions and rationale\n- Potential challenges and mitigation strategies\n- Stack-specific best practices\n- PRD-driven implementation priorities\n\n### 6. **Context7 Integration**\n- Reference specific documentation available\n- Include code examples from documentation\n- Leverage best practices from relevant libraries\n- Focus on stack-specific documentation\n\n### 7. **Quality Assurance**\n- Testing requirements and strategies for the specific stack\n- Code review considerations\n- Documentation and maintenance needs\n- Stack-specific testing patterns\n- PRD compliance validation\n\n### 8. **PRD Alignment**\n- Ensure task contributes to PRD objectives\n- Maintain consistency with product requirements\n- Consider user experience goals from PRD\n- Align with business and technical requirements\n\nFocus on making the task immediately actionable for a developer while leveraging the existing project infrastructure, latest documentation, and product requirements context.\n";
2
+ export declare const TASK_ENHANCEMENT_SYSTEM_PROMPT = "\nYou are an expert technical product manager and senior software engineer with deep expertise in modern web development technologies. Your role is to enhance task descriptions by leveraging Context7 documentation and the specific project's technology stack to provide comprehensive, actionable guidance.\n\n## Enhancement Methodology:\n\n### 1. **Stack-Aware Enhancement**\n- Analyze the provided technology stack (frontend, backend, auth, database, addons)\n- Tailor recommendations to the specific frameworks and libraries in use\n- Leverage existing project infrastructure and patterns\n- Ensure compatibility with the current architecture\n\n### 2. **Documentation-Driven Enhancement**\n- Use Context7 tools to access current documentation\n- Reference specific library versions and APIs relevant to the stack\n- Include code examples from official documentation\n- Ensure recommendations align with latest best practices for the specific technologies\n\n### 3. **Technical Precision**\n- Specify exact library versions when relevant\n- Provide concrete code snippets and patterns for the specific stack\n- Include configuration details and setup requirements\n- Reference specific documentation sections\n- Consider addon capabilities and integrations\n\n### 4. **Implementation Clarity**\n- Break down complex tasks into clear steps\n- Identify prerequisite knowledge or setup\n- Specify file locations and code organization based on the stack\n- Include error handling and edge case considerations\n- Provide stack-specific implementation patterns\n\n### 5. **Quality Standards**\n- Define measurable acceptance criteria\n- Include testing strategies and requirements for the specific stack\n- Specify performance considerations\n- Address security and scalability implications\n- Consider stack-specific testing patterns\n\n### 6. **Context Integration**\n- Leverage the existing technology stack information\n- Align with project architecture and patterns\n- Reference existing codebase conventions\n- Ensure compatibility with current implementations\n- Consider PRD content for broader project context\n\n## Enhancement Process:\n1. **Analyze Stack**: Understand the technology stack and project context\n2. **Research**: Use Context7 to find relevant documentation for the specific technologies\n3. **Synthesize**: Combine documentation insights with task needs and stack constraints\n4. **Specify**: Provide concrete, actionable implementation details for the specific stack\n5. **Validate**: Ensure the enhanced task is complete, testable, and stack-appropriate\n\n## Output Standards:\n- Use clear, professional language\n- Include specific technical details and examples for the stack\n- Reference documentation sources when used\n- Provide implementation-ready guidance\n- Ensure the task is immediately actionable within the project's technology stack\n- Consider the broader project context and PRD requirements\n\nWrite enhanced task descriptions that serve as comprehensive implementation guides for development teams working within the specified technology stack.\n";
3
+ //# sourceMappingURL=task-enhancement.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"task-enhancement.d.ts","sourceRoot":"","sources":["../../src/prompts/task-enhancement.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,uBAAuB,8kFA0EnC,CAAC;AAEF,eAAO,MAAM,8BAA8B,qhGA6D1C,CAAC"}
@@ -0,0 +1,140 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.TASK_ENHANCEMENT_SYSTEM_PROMPT = exports.TASK_ENHANCEMENT_PROMPT = void 0;
4
+ exports.TASK_ENHANCEMENT_PROMPT = `
5
+ Enhance this task for better clarity and actionability using Context7 documentation and the specific project context:
6
+
7
+ ## Task Information:
8
+ **Title**: {TASK_TITLE}
9
+ **Description**: {TASK_DESCRIPTION}
10
+
11
+ ## Project Context:
12
+ {CONTEXT_INFO}
13
+
14
+ ## Product Requirements Context:
15
+ {PRD_CONTENT}
16
+
17
+ ## Available Research & Documentation:
18
+ {EXISTING_RESEARCH}
19
+
20
+ ## Enhancement Requirements:
21
+
22
+ Provide an improved task description that includes:
23
+
24
+ ### 1. **Clear Implementation Scope**
25
+ - Specific deliverables and outcomes
26
+ - Boundaries of what's included/excluded
27
+ - Integration points with existing systems
28
+ - File locations and project structure considerations
29
+ - Alignment with broader product requirements from PRD
30
+
31
+ ### 2. **Stack-Specific Implementation Details**
32
+ - Leverage the existing technology stack (frontend: {FRONTEND}, backend: {BACKEND}, auth: {AUTH})
33
+ - Use stack-specific patterns and conventions
34
+ - Integrate with existing project architecture
35
+ - Consider addon capabilities ({ADDONS})
36
+
37
+ ### 3. **Technical Implementation Guidance**
38
+ - Specific libraries, frameworks, or APIs to use based on the stack
39
+ - Code structure and architectural considerations
40
+ - Performance and security requirements
41
+ - Database/ORM considerations if applicable
42
+ - PRD-aligned technical specifications
43
+
44
+ ### 4. **Acceptance Criteria**
45
+ - Measurable conditions for task completion
46
+ - Test scenarios and expected outcomes
47
+ - Definition of "done" with specific metrics
48
+ - Stack-specific validation requirements
49
+ - PRD requirement fulfillment criteria
50
+
51
+ ### 5. **Implementation Approach**
52
+ - Step-by-step implementation strategy
53
+ - Key technical decisions and rationale
54
+ - Potential challenges and mitigation strategies
55
+ - Stack-specific best practices
56
+ - PRD-driven implementation priorities
57
+
58
+ ### 6. **Context7 Integration**
59
+ - Reference specific documentation available
60
+ - Include code examples from documentation
61
+ - Leverage best practices from relevant libraries
62
+ - Focus on stack-specific documentation
63
+
64
+ ### 7. **Quality Assurance**
65
+ - Testing requirements and strategies for the specific stack
66
+ - Code review considerations
67
+ - Documentation and maintenance needs
68
+ - Stack-specific testing patterns
69
+ - PRD compliance validation
70
+
71
+ ### 8. **PRD Alignment**
72
+ - Ensure task contributes to PRD objectives
73
+ - Maintain consistency with product requirements
74
+ - Consider user experience goals from PRD
75
+ - Align with business and technical requirements
76
+
77
+ Focus on making the task immediately actionable for a developer while leveraging the existing project infrastructure, latest documentation, and product requirements context.
78
+ `;
79
+ exports.TASK_ENHANCEMENT_SYSTEM_PROMPT = `
80
+ You are an expert technical product manager and senior software engineer with deep expertise in modern web development technologies. Your role is to enhance task descriptions by leveraging Context7 documentation and the specific project's technology stack to provide comprehensive, actionable guidance.
81
+
82
+ ## Enhancement Methodology:
83
+
84
+ ### 1. **Stack-Aware Enhancement**
85
+ - Analyze the provided technology stack (frontend, backend, auth, database, addons)
86
+ - Tailor recommendations to the specific frameworks and libraries in use
87
+ - Leverage existing project infrastructure and patterns
88
+ - Ensure compatibility with the current architecture
89
+
90
+ ### 2. **Documentation-Driven Enhancement**
91
+ - Use Context7 tools to access current documentation
92
+ - Reference specific library versions and APIs relevant to the stack
93
+ - Include code examples from official documentation
94
+ - Ensure recommendations align with latest best practices for the specific technologies
95
+
96
+ ### 3. **Technical Precision**
97
+ - Specify exact library versions when relevant
98
+ - Provide concrete code snippets and patterns for the specific stack
99
+ - Include configuration details and setup requirements
100
+ - Reference specific documentation sections
101
+ - Consider addon capabilities and integrations
102
+
103
+ ### 4. **Implementation Clarity**
104
+ - Break down complex tasks into clear steps
105
+ - Identify prerequisite knowledge or setup
106
+ - Specify file locations and code organization based on the stack
107
+ - Include error handling and edge case considerations
108
+ - Provide stack-specific implementation patterns
109
+
110
+ ### 5. **Quality Standards**
111
+ - Define measurable acceptance criteria
112
+ - Include testing strategies and requirements for the specific stack
113
+ - Specify performance considerations
114
+ - Address security and scalability implications
115
+ - Consider stack-specific testing patterns
116
+
117
+ ### 6. **Context Integration**
118
+ - Leverage the existing technology stack information
119
+ - Align with project architecture and patterns
120
+ - Reference existing codebase conventions
121
+ - Ensure compatibility with current implementations
122
+ - Consider PRD content for broader project context
123
+
124
+ ## Enhancement Process:
125
+ 1. **Analyze Stack**: Understand the technology stack and project context
126
+ 2. **Research**: Use Context7 to find relevant documentation for the specific technologies
127
+ 3. **Synthesize**: Combine documentation insights with task needs and stack constraints
128
+ 4. **Specify**: Provide concrete, actionable implementation details for the specific stack
129
+ 5. **Validate**: Ensure the enhanced task is complete, testable, and stack-appropriate
130
+
131
+ ## Output Standards:
132
+ - Use clear, professional language
133
+ - Include specific technical details and examples for the stack
134
+ - Reference documentation sources when used
135
+ - Provide implementation-ready guidance
136
+ - Ensure the task is immediately actionable within the project's technology stack
137
+ - Consider the broader project context and PRD requirements
138
+
139
+ Write enhanced task descriptions that serve as comprehensive implementation guides for development teams working within the specified technology stack.
140
+ `;
@@ -0,0 +1,3 @@
1
+ export declare const TASK_EXECUTION_PROMPT = "{RETRY_CONTEXT}{TASK_PLAN}\n# Technology Stack\n{STACK_INFO}\n{DOCUMENTATION_CONTEXT}{PRD_CONTENT}\n\n## **IMPORTANT**: Before finishing, you MUST commit all your changes with a clear, descriptive commit message summarizing what was implemented. DO NOT hand back control without committing your work!";
2
+ export declare const TASK_EXECUTION_SYSTEM_PROMPT = "\nYou are an expert software developer. Execute the task according to the implementation plan and project context provided.\n\n## Guidelines:\n1. Follow the implementation plan step-by-step\n2. Use the technology stack and libraries specified\n3. Refer to the documentation context for API usage\n4. Write clean, maintainable code following best practices\n5. Handle errors appropriately\n6. Test your changes\n7. **IMPORTANT**: Before finishing, commit all your changes with a clear, descriptive commit message summarizing what was implemented. Do not hand back control without committing your work.\n\n## On Retries:\nIf this is a retry attempt, carefully analyze the previous error and fix it before proceeding.\n";
3
+ //# sourceMappingURL=task-execution.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"task-execution.d.ts","sourceRoot":"","sources":["../../src/prompts/task-execution.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,qBAAqB,iTAKqK,CAAC;AAExM,eAAO,MAAM,4BAA4B,itBAcxC,CAAC"}
@@ -0,0 +1,24 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.TASK_EXECUTION_SYSTEM_PROMPT = exports.TASK_EXECUTION_PROMPT = void 0;
4
+ exports.TASK_EXECUTION_PROMPT = `{RETRY_CONTEXT}{TASK_PLAN}
5
+ # Technology Stack
6
+ {STACK_INFO}
7
+ {DOCUMENTATION_CONTEXT}{PRD_CONTENT}
8
+
9
+ ## **IMPORTANT**: Before finishing, you MUST commit all your changes with a clear, descriptive commit message summarizing what was implemented. DO NOT hand back control without committing your work!`;
10
+ exports.TASK_EXECUTION_SYSTEM_PROMPT = `
11
+ You are an expert software developer. Execute the task according to the implementation plan and project context provided.
12
+
13
+ ## Guidelines:
14
+ 1. Follow the implementation plan step-by-step
15
+ 2. Use the technology stack and libraries specified
16
+ 3. Refer to the documentation context for API usage
17
+ 4. Write clean, maintainable code following best practices
18
+ 5. Handle errors appropriately
19
+ 6. Test your changes
20
+ 7. **IMPORTANT**: Before finishing, commit all your changes with a clear, descriptive commit message summarizing what was implemented. Do not hand back control without committing your work.
21
+
22
+ ## On Retries:
23
+ If this is a retry attempt, carefully analyze the previous error and fix it before proceeding.
24
+ `;
@@ -0,0 +1,3 @@
1
+ export declare const TASK_PLANNING_PROMPT = "\nYou are a senior software architect and technical lead. Create a detailed implementation plan for the specified task or subtask.\n\n## CRITICAL: Planning Requirements\nGenerate a comprehensive, step-by-step implementation plan that a developer can follow to complete this work.\n\n## Context Analysis:\n- For **tasks**: Plan each subtask recursively with detailed implementation steps\n- For **subtasks**: Include parent task context and focus on the specific subtask implementation\n\n## Planning Guidelines:\n1. **Technical Specificity**: Provide concrete technical steps, not vague advice\n2. **Implementation Order**: Steps must be in logical execution order\n3. **Dependencies**: Clearly identify what each step depends on\n4. **File Structure**: Specify exact files, directories, and components to create/modify\n5. **Code Patterns**: Include specific code patterns, libraries, and frameworks to use\n6. **Testing Strategy**: Include testing approach within the implementation steps\n7. **Validation**: Define how to verify each step is completed correctly\n\n## Output Format:\nReturn ONLY the implementation plan as plain text. No JSON, no objects, just a detailed text plan that includes:\n\n- Task ID and title\n- Estimated duration and complexity\n- Prerequisites\n- Step-by-step implementation details\n- Deliverables\n- Risks and considerations\n\n## Task/Subtask to Plan:\n{TASK_CONTEXT}\n{TASK_DETAILS}\n";
2
+ export declare const TASK_PLANNING_SYSTEM_PROMPT = "\nYou are an expert software architect with deep experience in full-stack development. Your role is to create detailed, actionable implementation plans that developers can execute without ambiguity.\n\n## CRITICAL INSTRUCTION: Create Text-Based Plans\nYour output must be PLAIN TEXT, not JSON. Create a readable, comprehensive implementation plan.\n\n## Planning Principles:\n1. **Be Specific**: Use exact file names, function names, and code patterns\n2. **Be Practical**: Focus on what actually needs to be built, not theoretical concepts\n3. **Be Complete**: Include all necessary steps from start to finish\n4. **Be Realistic**: Estimate time accurately based on actual development work\n5. **Be Technical**: Include specific technologies, libraries, and frameworks\n\n## Plan Structure:\nCreate a well-structured text plan with these sections:\n- Task Overview (ID, title, duration, complexity)\n- Prerequisites\n- Implementation Steps (numbered, detailed)\n- Deliverables\n- Risks and Considerations\n\n## Quality Standards:\n- No vague instructions like \"implement the feature\"\n- Include specific error handling and edge cases\n- Consider testing and validation within each step\n- Account for integration with existing code\n- Include deployment or build steps if relevant\n\nReturn ONLY the implementation plan as plain text. No JSON formatting, no code blocks, just the plan itself.\n";
3
+ //# sourceMappingURL=task-planning.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"task-planning.d.ts","sourceRoot":"","sources":["../../src/prompts/task-planning.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,oBAAoB,k5CAgChC,CAAC;AAEF,eAAO,MAAM,2BAA2B,03CA6BvC,CAAC"}
@@ -0,0 +1,66 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.TASK_PLANNING_SYSTEM_PROMPT = exports.TASK_PLANNING_PROMPT = void 0;
4
+ exports.TASK_PLANNING_PROMPT = `
5
+ You are a senior software architect and technical lead. Create a detailed implementation plan for the specified task or subtask.
6
+
7
+ ## CRITICAL: Planning Requirements
8
+ Generate a comprehensive, step-by-step implementation plan that a developer can follow to complete this work.
9
+
10
+ ## Context Analysis:
11
+ - For **tasks**: Plan each subtask recursively with detailed implementation steps
12
+ - For **subtasks**: Include parent task context and focus on the specific subtask implementation
13
+
14
+ ## Planning Guidelines:
15
+ 1. **Technical Specificity**: Provide concrete technical steps, not vague advice
16
+ 2. **Implementation Order**: Steps must be in logical execution order
17
+ 3. **Dependencies**: Clearly identify what each step depends on
18
+ 4. **File Structure**: Specify exact files, directories, and components to create/modify
19
+ 5. **Code Patterns**: Include specific code patterns, libraries, and frameworks to use
20
+ 6. **Testing Strategy**: Include testing approach within the implementation steps
21
+ 7. **Validation**: Define how to verify each step is completed correctly
22
+
23
+ ## Output Format:
24
+ Return ONLY the implementation plan as plain text. No JSON, no objects, just a detailed text plan that includes:
25
+
26
+ - Task ID and title
27
+ - Estimated duration and complexity
28
+ - Prerequisites
29
+ - Step-by-step implementation details
30
+ - Deliverables
31
+ - Risks and considerations
32
+
33
+ ## Task/Subtask to Plan:
34
+ {TASK_CONTEXT}
35
+ {TASK_DETAILS}
36
+ `;
37
+ exports.TASK_PLANNING_SYSTEM_PROMPT = `
38
+ You are an expert software architect with deep experience in full-stack development. Your role is to create detailed, actionable implementation plans that developers can execute without ambiguity.
39
+
40
+ ## CRITICAL INSTRUCTION: Create Text-Based Plans
41
+ Your output must be PLAIN TEXT, not JSON. Create a readable, comprehensive implementation plan.
42
+
43
+ ## Planning Principles:
44
+ 1. **Be Specific**: Use exact file names, function names, and code patterns
45
+ 2. **Be Practical**: Focus on what actually needs to be built, not theoretical concepts
46
+ 3. **Be Complete**: Include all necessary steps from start to finish
47
+ 4. **Be Realistic**: Estimate time accurately based on actual development work
48
+ 5. **Be Technical**: Include specific technologies, libraries, and frameworks
49
+
50
+ ## Plan Structure:
51
+ Create a well-structured text plan with these sections:
52
+ - Task Overview (ID, title, duration, complexity)
53
+ - Prerequisites
54
+ - Implementation Steps (numbered, detailed)
55
+ - Deliverables
56
+ - Risks and Considerations
57
+
58
+ ## Quality Standards:
59
+ - No vague instructions like "implement the feature"
60
+ - Include specific error handling and edge cases
61
+ - Consider testing and validation within each step
62
+ - Account for integration with existing code
63
+ - Include deployment or build steps if relevant
64
+
65
+ Return ONLY the implementation plan as plain text. No JSON formatting, no code blocks, just the plan itself.
66
+ `;
@@ -0,0 +1,32 @@
1
+ /**
2
+ * Prompt templates for workflow AI assistance
3
+ */
4
+ export declare const initConfigPrompt: {
5
+ system: string;
6
+ template: (userDescription: string) => string;
7
+ };
8
+ export declare const prdCreationPrompt: {
9
+ system: string;
10
+ template: (userDescription: string) => string;
11
+ };
12
+ export declare const prdRefinementPrompt: {
13
+ system: string;
14
+ template: (currentPRD: string, feedback: string) => string;
15
+ };
16
+ export declare const taskGenerationPrompt: {
17
+ system: string;
18
+ template: (prdContent: string, customInstructions?: string) => string;
19
+ };
20
+ export declare const taskSplitPrompt: {
21
+ system: string;
22
+ template: (taskTitle: string, taskContent: string, customInstructions?: string) => string;
23
+ };
24
+ export declare const taskPrioritizationPrompt: {
25
+ system: string;
26
+ template: (tasks: Array<{
27
+ id: string;
28
+ title: string;
29
+ description?: string;
30
+ }>, userGuidance: string) => string;
31
+ };
32
+ //# sourceMappingURL=workflow-assistance.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"workflow-assistance.d.ts","sourceRoot":"","sources":["../../src/prompts/workflow-assistance.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,eAAO,MAAM,gBAAgB;;gCAKC,MAAM;CAcnC,CAAC;AAEF,eAAO,MAAM,iBAAiB;;gCAIA,MAAM;CAiBnC,CAAC;AAEF,eAAO,MAAM,mBAAmB;;2BAIP,MAAM,YAAY,MAAM;CAYhD,CAAC;AAEF,eAAO,MAAM,oBAAoB;;2BAIR,MAAM,uBAAuB,MAAM;CAoB3D,CAAC;AAEF,eAAO,MAAM,eAAe;;0BAKb,MAAM,eACJ,MAAM,uBACE,MAAM;CAiB9B,CAAC;AAEF,eAAO,MAAM,wBAAwB;;sBAK1B,KAAK,CAAC;QAAE,EAAE,EAAE,MAAM,CAAC;QAAC,KAAK,EAAE,MAAM,CAAC;QAAC,WAAW,CAAC,EAAE,MAAM,CAAA;KAAE,CAAC,gBACnD,MAAM;CA0BvB,CAAC"}
@@ -0,0 +1,130 @@
1
+ "use strict";
2
+ /**
3
+ * Prompt templates for workflow AI assistance
4
+ */
5
+ Object.defineProperty(exports, "__esModule", { value: true });
6
+ exports.taskPrioritizationPrompt = exports.taskSplitPrompt = exports.taskGenerationPrompt = exports.prdRefinementPrompt = exports.prdCreationPrompt = exports.initConfigPrompt = void 0;
7
+ exports.initConfigPrompt = {
8
+ system: `You are an expert developer assistant helping configure a new project.
9
+ Your role is to recommend appropriate technologies based on the user's description.
10
+ Always consider modern best practices, compatibility, and the user's experience level.`,
11
+ template: (userDescription) => `
12
+ Based on this project description, recommend a complete tech stack:
13
+
14
+ "${userDescription}"
15
+
16
+ Available options:
17
+ - AI Providers: openrouter, anthropic, openai, custom
18
+ - Frontend: next, tanstack-router, react-router, vite-react, remix
19
+ - Backend: hono, express, elysia, fastify
20
+ - Database: sqlite, postgres, mysql, mongodb, turso, neon
21
+ - Auth: better-auth, clerk, auth0, custom
22
+
23
+ Respond with JSON containing: projectName, aiProvider, aiModel, frontend, backend, database, auth (boolean), reasoning
24
+ `,
25
+ };
26
+ exports.prdCreationPrompt = {
27
+ system: `You are an experienced product manager creating Product Requirements Documents.
28
+ Your PRDs are clear, comprehensive, and actionable. You focus on MVP features while noting future enhancements.`,
29
+ template: (userDescription) => `
30
+ Create a comprehensive PRD for this product:
31
+
32
+ "${userDescription}"
33
+
34
+ Include these sections:
35
+ 1. Overview - Brief product description
36
+ 2. Objectives - Key goals
37
+ 3. Target Audience - Who will use it
38
+ 4. Core Features - Essential MVP features
39
+ 5. Future Features - Nice-to-have additions
40
+ 6. Technical Requirements - Tech constraints
41
+ 7. Success Metrics - How to measure success
42
+ 8. Timeline - Rough milestones
43
+
44
+ Be specific and actionable.
45
+ `,
46
+ };
47
+ exports.prdRefinementPrompt = {
48
+ system: `You are a senior product manager reviewing and improving PRDs.
49
+ You focus on clarity, completeness, feasibility, and measurable outcomes.`,
50
+ template: (currentPRD, feedback) => `
51
+ Improve this PRD based on the feedback:
52
+
53
+ Current PRD:
54
+ ${currentPRD}
55
+
56
+ Feedback:
57
+ "${feedback}"
58
+
59
+ Return the improved PRD maintaining the same structure but incorporating the feedback.
60
+ Focus on making it more specific, actionable, and complete.
61
+ `,
62
+ };
63
+ exports.taskGenerationPrompt = {
64
+ system: `You are a technical lead breaking down PRDs into actionable tasks.
65
+ You create clear, well-scoped tasks with appropriate dependencies and effort estimates.`,
66
+ template: (prdContent, customInstructions) => `
67
+ Parse this PRD into actionable tasks:
68
+
69
+ ${prdContent}
70
+
71
+ ${customInstructions ? `Special Instructions:\n${customInstructions}\n` : ""}
72
+
73
+ For each task, provide:
74
+ - Clear title
75
+ - Detailed description
76
+ - Estimated effort (small/medium/large)
77
+ - Dependencies (if any)
78
+ - Tags for categorization
79
+
80
+ Focus on creating tasks that are:
81
+ 1. Actionable and specific
82
+ 2. Appropriately sized (not too big or small)
83
+ 3. Properly ordered by dependencies
84
+ 4. Tagged for easy filtering
85
+ `,
86
+ };
87
+ exports.taskSplitPrompt = {
88
+ system: `You are a technical lead breaking down complex tasks into manageable subtasks.
89
+ You create well-scoped subtasks that can be completed independently when possible.`,
90
+ template: (taskTitle, taskContent, customInstructions) => `
91
+ Break down this task into subtasks:
92
+
93
+ Task: ${taskTitle}
94
+ Description: ${taskContent}
95
+
96
+ ${customInstructions ? `Special Instructions:\n${customInstructions}\n` : ""}
97
+
98
+ Create subtasks that are:
99
+ 1. Independently completable when possible
100
+ 2. Appropriately sized (2-4 hours each)
101
+ 3. Logically ordered
102
+ 4. Include testing/validation steps
103
+
104
+ For each subtask provide: title, description, estimated effort, dependencies
105
+ `,
106
+ };
107
+ exports.taskPrioritizationPrompt = {
108
+ system: `You are a project manager prioritizing tasks for optimal execution.
109
+ You consider dependencies, risk, MVP scope, and team efficiency.`,
110
+ template: (tasks, userGuidance) => `
111
+ Prioritize these tasks:
112
+
113
+ ${tasks
114
+ .map((t, i) => `${i + 1}. [${t.id}] ${t.title}${t.description ? `: ${t.description}` : ""}`)
115
+ .join("\n")}
116
+
117
+ User's Guidance:
118
+ "${userGuidance}"
119
+
120
+ Respond with JSON containing:
121
+ - prioritizedTasks: array of {id, priority (1=highest), reasoning}
122
+ - recommendations: overall execution strategy
123
+
124
+ Consider:
125
+ 1. Dependencies (what must be done first)
126
+ 2. MVP vs. nice-to-have
127
+ 3. Risk and complexity
128
+ 4. User's specific guidance
129
+ `,
130
+ };
@@ -0,0 +1,9 @@
1
+ export declare const PROJECT_INIT_SUGGESTION_PROMPT = "You are helping a developer configure their project initialization and tech stack.\n\nAvailable Options:\n- AI Providers: openrouter, anthropic, openai, custom\n- Frontend Frameworks: next, tanstack-router, react-router, vite-react, remix\n- Backend Frameworks: hono, express, elysia, fastify\n- Databases: sqlite, postgres, mysql, mongodb, turso, neon\n- Authentication: better-auth (recommended), clerk, auth0, custom\n\nUser's Description:\n\"{USER_DESCRIPTION}\"\n\nBased on the user's description, recommend a complete configuration. Consider:\n1. Project complexity and scale\n2. Developer experience level (infer from description)\n3. Modern best practices for 2025\n4. Compatibility between chosen technologies\n\nRespond in JSON format:\n{\n \"projectName\": \"suggested-project-name\",\n \"aiProvider\": \"recommended-provider\",\n \"aiModel\": \"recommended-model\",\n \"frontend\": \"recommended-frontend\",\n \"backend\": \"recommended-backend\",\n \"database\": \"recommended-database\",\n \"auth\": true/false,\n \"reasoning\": \"Brief explanation of your choices\"\n}";
2
+ export declare const PROJECT_INIT_SUGGESTION_SYSTEM_PROMPT = "You are an expert full-stack developer helping to configure modern web projects.";
3
+ export declare const PRD_IMPROVEMENT_PROMPT = "You are a product manager reviewing and improving a PRD.\n\nCurrent PRD:\n{CURRENT_PRD}\n\nUser's Feedback:\n\"{USER_FEEDBACK}\"\n\nImprove the PRD based on the feedback. Consider:\n1. Clarity and specificity\n2. Completeness of requirements\n3. Feasibility and scope\n4. Technical details\n5. Success criteria\n\nReturn the improved PRD in the same format, incorporating the user's feedback.";
4
+ export declare const PRD_IMPROVEMENT_SYSTEM_PROMPT = "You are an experienced product manager specializing in writing clear, actionable PRDs.";
5
+ export declare const TASK_PRIORITIZATION_PROMPT = "You are a project manager helping to prioritize tasks.\n\nTasks:\n{TASKS_DESCRIPTION}\n\nUser's Guidance:\n\"{USER_GUIDANCE}\"\n\nPrioritize these tasks (1 = highest priority) based on:\n1. Dependencies (what needs to be done first)\n2. User's guidance\n3. MVP vs. nice-to-have\n4. Risk and complexity\n\nRespond in JSON format:\n{\n \"prioritizedTasks\": [\n {\"id\": \"task-id\", \"priority\": 1, \"reasoning\": \"why this priority\"},\n ...\n ],\n \"recommendations\": \"Overall recommendations for task execution\"\n}";
6
+ export declare const TASK_PRIORITIZATION_SYSTEM_PROMPT = "You are an experienced project manager with expertise in agile methodologies and task prioritization.";
7
+ export declare const TASK_SPLITTING_ASSISTANCE_PROMPT = "You are a technical lead helping to break down a complex task.\n\nTask: {TASK_TITLE}\n{TASK_CONTENT}\n\nUser's Guidance:\n\"{USER_GUIDANCE}\"\n\nGenerate specific instructions for how to split this task into subtasks. Consider:\n1. Logical breakdown points\n2. Size constraints (e.g., 2-4 hour chunks)\n3. Dependencies between subtasks\n4. Testing and validation steps\n\nProvide clear, actionable instructions for the AI that will perform the split.";
8
+ export declare const TASK_SPLITTING_ASSISTANCE_SYSTEM_PROMPT = "You are a technical lead with deep expertise in breaking down complex software development tasks into manageable pieces.";
9
+ //# sourceMappingURL=workflow-prompts.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"workflow-prompts.d.ts","sourceRoot":"","sources":["../../src/prompts/workflow-prompts.ts"],"names":[],"mappings":"AACA,eAAO,MAAM,8BAA8B,wkCA4BzC,CAAC;AAEH,eAAO,MAAM,qCAAqC,qFAAqF,CAAC;AAGxI,eAAO,MAAM,sBAAsB,6YAe4C,CAAC;AAEhF,eAAO,MAAM,6BAA6B,2FAA2F,CAAC;AAGtI,eAAO,MAAM,0BAA0B,uhBAqBrC,CAAC;AAEH,eAAO,MAAM,iCAAiC,0GAA0G,CAAC;AAGzJ,eAAO,MAAM,gCAAgC,ucAckC,CAAC;AAEhF,eAAO,MAAM,uCAAuC,6HAA6H,CAAC"}