@apralabs/apra-fleet 0.4.0 → 0.4.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (548) hide show
  1. package/README.md +159 -13
  2. package/dist/agents/backlog-groomer.md +31 -19
  3. package/dist/agents/ci-watcher.md +16 -1
  4. package/dist/agents/deployer.md +37 -47
  5. package/dist/agents/doer.md +147 -114
  6. package/dist/agents/harvester.md +41 -34
  7. package/dist/agents/integ-test-runner.md +98 -114
  8. package/dist/agents/kb-reconciler.md +205 -0
  9. package/dist/agents/plan-reviewer.md +45 -44
  10. package/dist/agents/planner.md +121 -50
  11. package/dist/agents/regression-test-runner.md +84 -81
  12. package/dist/agents/reviewer.md +118 -44
  13. package/dist/agents/schemas/doer-output.json +63 -3
  14. package/dist/agents/schemas/harvester-output.json +59 -2
  15. package/dist/agents/schemas/integ-test-runner-output.json +3 -3
  16. package/dist/agents/schemas/kb-reconciler-output.json +87 -0
  17. package/dist/agents/schemas/planner-output.json +65 -0
  18. package/dist/agents/schemas/regression-test-runner-output.json +4 -17
  19. package/dist/agents/schemas/reviewer-output.json +105 -8
  20. package/dist/cli/auth.d.ts.map +1 -1
  21. package/dist/cli/auth.js +1 -2
  22. package/dist/cli/auth.js.map +1 -1
  23. package/dist/cli/config.d.ts +3 -3
  24. package/dist/cli/config.d.ts.map +1 -1
  25. package/dist/cli/config.js +4 -13
  26. package/dist/cli/config.js.map +1 -1
  27. package/dist/cli/install.d.ts +1 -0
  28. package/dist/cli/install.d.ts.map +1 -1
  29. package/dist/cli/install.js +141 -44
  30. package/dist/cli/install.js.map +1 -1
  31. package/dist/cli/join.js +1 -1
  32. package/dist/cli/join.js.map +1 -1
  33. package/dist/cli/kb-commit.d.ts +12 -0
  34. package/dist/cli/kb-commit.d.ts.map +1 -0
  35. package/dist/cli/kb-commit.js +53 -0
  36. package/dist/cli/kb-commit.js.map +1 -0
  37. package/dist/cli/kb-directives.d.ts +17 -0
  38. package/dist/cli/kb-directives.d.ts.map +1 -0
  39. package/dist/cli/kb-directives.js +146 -0
  40. package/dist/cli/kb-directives.js.map +1 -0
  41. package/dist/cli/kb-import.d.ts +13 -0
  42. package/dist/cli/kb-import.d.ts.map +1 -0
  43. package/dist/cli/kb-import.js +56 -0
  44. package/dist/cli/kb-import.js.map +1 -0
  45. package/dist/cli/register-member.js +1 -1
  46. package/dist/cli/start.d.ts.map +1 -1
  47. package/dist/cli/start.js +7 -0
  48. package/dist/cli/start.js.map +1 -1
  49. package/dist/cli/uninstall.d.ts.map +1 -1
  50. package/dist/cli/uninstall.js +16 -3
  51. package/dist/cli/uninstall.js.map +1 -1
  52. package/dist/cli/watch.d.ts +76 -4
  53. package/dist/cli/watch.d.ts.map +1 -1
  54. package/dist/cli/watch.js +150 -17
  55. package/dist/cli/watch.js.map +1 -1
  56. package/dist/commands/kb-server.d.ts +8 -0
  57. package/dist/commands/kb-server.d.ts.map +1 -0
  58. package/dist/commands/kb-server.js +221 -0
  59. package/dist/commands/kb-server.js.map +1 -0
  60. package/dist/index.js +77 -2
  61. package/dist/index.js.map +1 -1
  62. package/dist/os/git-bash-candidates.d.ts +35 -0
  63. package/dist/os/git-bash-candidates.d.ts.map +1 -0
  64. package/dist/os/git-bash-candidates.js +46 -0
  65. package/dist/os/git-bash-candidates.js.map +1 -0
  66. package/dist/os/index.d.ts +13 -4
  67. package/dist/os/index.d.ts.map +1 -1
  68. package/dist/os/index.js +17 -2
  69. package/dist/os/index.js.map +1 -1
  70. package/dist/os/linux.d.ts +1 -0
  71. package/dist/os/linux.d.ts.map +1 -1
  72. package/dist/os/linux.js +19 -2
  73. package/dist/os/linux.js.map +1 -1
  74. package/dist/os/os-commands.d.ts +12 -0
  75. package/dist/os/os-commands.d.ts.map +1 -1
  76. package/dist/os/os-commands.js.map +1 -1
  77. package/dist/os/windows-gitbash.d.ts +93 -0
  78. package/dist/os/windows-gitbash.d.ts.map +1 -0
  79. package/dist/os/windows-gitbash.js +244 -0
  80. package/dist/os/windows-gitbash.js.map +1 -0
  81. package/dist/os/windows.d.ts +35 -0
  82. package/dist/os/windows.d.ts.map +1 -1
  83. package/dist/os/windows.js +93 -35
  84. package/dist/os/windows.js.map +1 -1
  85. package/dist/providers/agy.d.ts +15 -3
  86. package/dist/providers/agy.d.ts.map +1 -1
  87. package/dist/providers/agy.js +145 -11
  88. package/dist/providers/agy.js.map +1 -1
  89. package/dist/providers/claude.d.ts +14 -3
  90. package/dist/providers/claude.d.ts.map +1 -1
  91. package/dist/providers/claude.js +69 -22
  92. package/dist/providers/claude.js.map +1 -1
  93. package/dist/providers/codex.d.ts +14 -3
  94. package/dist/providers/codex.d.ts.map +1 -1
  95. package/dist/providers/codex.js +34 -8
  96. package/dist/providers/codex.js.map +1 -1
  97. package/dist/providers/copilot.d.ts +14 -3
  98. package/dist/providers/copilot.d.ts.map +1 -1
  99. package/dist/providers/copilot.js +33 -8
  100. package/dist/providers/copilot.js.map +1 -1
  101. package/dist/providers/email/headers.d.ts +15 -0
  102. package/dist/providers/email/headers.d.ts.map +1 -0
  103. package/dist/providers/email/headers.js +42 -0
  104. package/dist/providers/email/headers.js.map +1 -0
  105. package/dist/providers/email/index.d.ts +18 -0
  106. package/dist/providers/email/index.d.ts.map +1 -0
  107. package/dist/providers/email/index.js +60 -0
  108. package/dist/providers/email/index.js.map +1 -0
  109. package/dist/providers/email/provider.d.ts +49 -0
  110. package/dist/providers/email/provider.d.ts.map +1 -0
  111. package/dist/providers/email/provider.js +2 -0
  112. package/dist/providers/email/provider.js.map +1 -0
  113. package/dist/providers/email/sendgrid.d.ts +12 -0
  114. package/dist/providers/email/sendgrid.d.ts.map +1 -0
  115. package/dist/providers/email/sendgrid.js +67 -0
  116. package/dist/providers/email/sendgrid.js.map +1 -0
  117. package/dist/providers/email/smtp.d.ts +65 -0
  118. package/dist/providers/email/smtp.d.ts.map +1 -0
  119. package/dist/providers/email/smtp.js +373 -0
  120. package/dist/providers/email/smtp.js.map +1 -0
  121. package/dist/providers/index.d.ts +0 -1
  122. package/dist/providers/index.d.ts.map +1 -1
  123. package/dist/providers/index.js +0 -3
  124. package/dist/providers/index.js.map +1 -1
  125. package/dist/providers/none.d.ts +14 -3
  126. package/dist/providers/none.d.ts.map +1 -1
  127. package/dist/providers/none.js +26 -2
  128. package/dist/providers/none.js.map +1 -1
  129. package/dist/providers/opencode.d.ts +14 -3
  130. package/dist/providers/opencode.d.ts.map +1 -1
  131. package/dist/providers/opencode.js +60 -6
  132. package/dist/providers/opencode.js.map +1 -1
  133. package/dist/providers/provider.d.ts +91 -5
  134. package/dist/providers/provider.d.ts.map +1 -1
  135. package/dist/providers/provider.js +45 -1
  136. package/dist/providers/provider.js.map +1 -1
  137. package/dist/services/agent-provisioner.d.ts.map +1 -1
  138. package/dist/services/agent-provisioner.js +5 -8
  139. package/dist/services/agent-provisioner.js.map +1 -1
  140. package/dist/services/cloud/activity.js +2 -2
  141. package/dist/services/cloud/activity.js.map +1 -1
  142. package/dist/services/cloud/lifecycle.d.ts.map +1 -1
  143. package/dist/services/cloud/lifecycle.js +3 -0
  144. package/dist/services/cloud/lifecycle.js.map +1 -1
  145. package/dist/services/cloud/task-wrapper.d.ts +18 -0
  146. package/dist/services/cloud/task-wrapper.d.ts.map +1 -1
  147. package/dist/services/cloud/task-wrapper.js +157 -0
  148. package/dist/services/cloud/task-wrapper.js.map +1 -1
  149. package/dist/services/context-admission.d.ts.map +1 -1
  150. package/dist/services/context-admission.js +9 -7
  151. package/dist/services/context-admission.js.map +1 -1
  152. package/dist/services/credential-cleanup.d.ts.map +1 -1
  153. package/dist/services/credential-cleanup.js +22 -3
  154. package/dist/services/credential-cleanup.js.map +1 -1
  155. package/dist/services/github-app.d.ts.map +1 -1
  156. package/dist/services/github-app.js +11 -2
  157. package/dist/services/github-app.js.map +1 -1
  158. package/dist/services/knowledge/audn.d.ts +37 -0
  159. package/dist/services/knowledge/audn.d.ts.map +1 -0
  160. package/dist/services/knowledge/audn.js +219 -0
  161. package/dist/services/knowledge/audn.js.map +1 -0
  162. package/dist/services/knowledge/file-hash.d.ts +11 -0
  163. package/dist/services/knowledge/file-hash.d.ts.map +1 -0
  164. package/dist/services/knowledge/file-hash.js +123 -0
  165. package/dist/services/knowledge/file-hash.js.map +1 -0
  166. package/dist/services/knowledge/http-provider.d.ts +46 -0
  167. package/dist/services/knowledge/http-provider.d.ts.map +1 -0
  168. package/dist/services/knowledge/http-provider.js +254 -0
  169. package/dist/services/knowledge/http-provider.js.map +1 -0
  170. package/dist/services/knowledge/kb-providers.d.ts +15 -0
  171. package/dist/services/knowledge/kb-providers.d.ts.map +1 -0
  172. package/dist/services/knowledge/kb-providers.js +92 -0
  173. package/dist/services/knowledge/kb-providers.js.map +1 -0
  174. package/dist/services/knowledge/kb-scope-input.d.ts +5 -0
  175. package/dist/services/knowledge/kb-scope-input.d.ts.map +1 -0
  176. package/dist/services/knowledge/kb-scope-input.js +11 -0
  177. package/dist/services/knowledge/kb-scope-input.js.map +1 -0
  178. package/dist/services/knowledge/kb-service.d.ts +3 -0
  179. package/dist/services/knowledge/kb-service.d.ts.map +1 -0
  180. package/dist/services/knowledge/kb-service.js +2 -0
  181. package/dist/services/knowledge/kb-service.js.map +1 -0
  182. package/dist/services/knowledge/path-validation.d.ts +2 -0
  183. package/dist/services/knowledge/path-validation.d.ts.map +1 -0
  184. package/dist/services/knowledge/path-validation.js +13 -0
  185. package/dist/services/knowledge/path-validation.js.map +1 -0
  186. package/dist/services/knowledge/pre-init.d.ts +14 -0
  187. package/dist/services/knowledge/pre-init.d.ts.map +1 -0
  188. package/dist/services/knowledge/pre-init.js +147 -0
  189. package/dist/services/knowledge/pre-init.js.map +1 -0
  190. package/dist/services/knowledge/project-slug.d.ts +2 -0
  191. package/dist/services/knowledge/project-slug.d.ts.map +1 -0
  192. package/dist/services/knowledge/project-slug.js +49 -0
  193. package/dist/services/knowledge/project-slug.js.map +1 -0
  194. package/dist/services/knowledge/sqlite-provider.d.ts +147 -0
  195. package/dist/services/knowledge/sqlite-provider.d.ts.map +1 -0
  196. package/dist/services/knowledge/sqlite-provider.js +1646 -0
  197. package/dist/services/knowledge/sqlite-provider.js.map +1 -0
  198. package/dist/services/knowledge/types.d.ts +163 -0
  199. package/dist/services/knowledge/types.d.ts.map +1 -0
  200. package/dist/services/knowledge/types.js +9 -0
  201. package/dist/services/knowledge/types.js.map +1 -0
  202. package/dist/services/member-home.d.ts +89 -0
  203. package/dist/services/member-home.d.ts.map +1 -0
  204. package/dist/services/member-home.js +259 -0
  205. package/dist/services/member-home.js.map +1 -0
  206. package/dist/services/member-remote-url.d.ts +34 -0
  207. package/dist/services/member-remote-url.d.ts.map +1 -0
  208. package/dist/services/member-remote-url.js +39 -0
  209. package/dist/services/member-remote-url.js.map +1 -0
  210. package/dist/services/model-pricing.d.ts.map +1 -1
  211. package/dist/services/model-pricing.js +0 -5
  212. package/dist/services/model-pricing.js.map +1 -1
  213. package/dist/services/orphan-recovery.d.ts +9 -3
  214. package/dist/services/orphan-recovery.d.ts.map +1 -1
  215. package/dist/services/orphan-recovery.js +22 -8
  216. package/dist/services/orphan-recovery.js.map +1 -1
  217. package/dist/services/preflight-check.d.ts +56 -0
  218. package/dist/services/preflight-check.d.ts.map +1 -0
  219. package/dist/services/preflight-check.js +277 -0
  220. package/dist/services/preflight-check.js.map +1 -0
  221. package/dist/services/shell-probe.d.ts +131 -0
  222. package/dist/services/shell-probe.d.ts.map +1 -0
  223. package/dist/services/shell-probe.js +210 -0
  224. package/dist/services/shell-probe.js.map +1 -0
  225. package/dist/services/singleton.d.ts +2 -0
  226. package/dist/services/singleton.d.ts.map +1 -1
  227. package/dist/services/singleton.js +1 -1
  228. package/dist/services/singleton.js.map +1 -1
  229. package/dist/services/ssh.js +2 -2
  230. package/dist/services/ssh.js.map +1 -1
  231. package/dist/services/stall/find-log-file.d.ts.map +1 -1
  232. package/dist/services/stall/find-log-file.js +22 -16
  233. package/dist/services/stall/find-log-file.js.map +1 -1
  234. package/dist/services/stall/log-path-resolver.d.ts +11 -8
  235. package/dist/services/stall/log-path-resolver.d.ts.map +1 -1
  236. package/dist/services/stall/log-path-resolver.js +17 -40
  237. package/dist/services/stall/log-path-resolver.js.map +1 -1
  238. package/dist/services/stall/read-log-tail.d.ts.map +1 -1
  239. package/dist/services/stall/read-log-tail.js +6 -5
  240. package/dist/services/stall/read-log-tail.js.map +1 -1
  241. package/dist/services/stall/stall-detector.d.ts +32 -0
  242. package/dist/services/stall/stall-detector.d.ts.map +1 -1
  243. package/dist/services/stall/stall-detector.js +149 -6
  244. package/dist/services/stall/stall-detector.js.map +1 -1
  245. package/dist/services/stall/stall-poller.d.ts +34 -0
  246. package/dist/services/stall/stall-poller.d.ts.map +1 -1
  247. package/dist/services/stall/stall-poller.js +160 -35
  248. package/dist/services/stall/stall-poller.js.map +1 -1
  249. package/dist/services/strategy.d.ts +9 -0
  250. package/dist/services/strategy.d.ts.map +1 -1
  251. package/dist/services/strategy.js +41 -7
  252. package/dist/services/strategy.js.map +1 -1
  253. package/dist/services/tool-registry.d.ts.map +1 -1
  254. package/dist/services/tool-registry.js +87 -1
  255. package/dist/services/tool-registry.js.map +1 -1
  256. package/dist/services/user-config.js +1 -1
  257. package/dist/services/user-config.js.map +1 -1
  258. package/dist/services/vcs/azure-devops.d.ts +1 -1
  259. package/dist/services/vcs/azure-devops.d.ts.map +1 -1
  260. package/dist/services/vcs/azure-devops.js +105 -10
  261. package/dist/services/vcs/azure-devops.js.map +1 -1
  262. package/dist/services/vcs/bitbucket.d.ts.map +1 -1
  263. package/dist/services/vcs/bitbucket.js +16 -0
  264. package/dist/services/vcs/bitbucket.js.map +1 -1
  265. package/dist/services/vcs/github.d.ts.map +1 -1
  266. package/dist/services/vcs/github.js +56 -1
  267. package/dist/services/vcs/github.js.map +1 -1
  268. package/dist/services/vcs/types.d.ts +123 -2
  269. package/dist/services/vcs/types.d.ts.map +1 -1
  270. package/dist/services/version-check.d.ts +22 -0
  271. package/dist/services/version-check.d.ts.map +1 -0
  272. package/dist/services/version-check.js +103 -0
  273. package/dist/services/version-check.js.map +1 -0
  274. package/dist/skills/fleet-sprint-cli/SKILL.md +15 -3
  275. package/dist/skills/pm/SKILL.md +0 -1
  276. package/dist/skills/pm/beads.md +6 -0
  277. package/dist/skills/pm/cost.md +0 -1
  278. package/dist/skills/pm/fleet-addendum.md +6 -1
  279. package/dist/skills/pm/index.md +56 -0
  280. package/dist/skills/pm/kb-reconcile.md +132 -0
  281. package/dist/skills/pm/kb-review.md +109 -0
  282. package/dist/tools/check-status.d.ts +47 -0
  283. package/dist/tools/check-status.d.ts.map +1 -1
  284. package/dist/tools/check-status.js +245 -3
  285. package/dist/tools/check-status.js.map +1 -1
  286. package/dist/tools/child-id-allocator.d.ts +2 -2
  287. package/dist/tools/cloud-control.js +2 -2
  288. package/dist/tools/cloud-control.js.map +1 -1
  289. package/dist/tools/code-intelligence-codebase-memory.d.ts +11 -0
  290. package/dist/tools/code-intelligence-codebase-memory.d.ts.map +1 -0
  291. package/dist/tools/code-intelligence-codebase-memory.js +270 -0
  292. package/dist/tools/code-intelligence-codebase-memory.js.map +1 -0
  293. package/dist/tools/code-intelligence-freshness.d.ts +2 -0
  294. package/dist/tools/code-intelligence-freshness.d.ts.map +1 -0
  295. package/dist/tools/code-intelligence-freshness.js +26 -0
  296. package/dist/tools/code-intelligence-freshness.js.map +1 -0
  297. package/dist/tools/code-intelligence-gitnexus.d.ts +14 -0
  298. package/dist/tools/code-intelligence-gitnexus.d.ts.map +1 -0
  299. package/dist/tools/code-intelligence-gitnexus.js +475 -0
  300. package/dist/tools/code-intelligence-gitnexus.js.map +1 -0
  301. package/dist/tools/code-intelligence-kb-enrich.d.ts +2 -0
  302. package/dist/tools/code-intelligence-kb-enrich.d.ts.map +1 -0
  303. package/dist/tools/code-intelligence-kb-enrich.js +65 -0
  304. package/dist/tools/code-intelligence-kb-enrich.js.map +1 -0
  305. package/dist/tools/code-intelligence-reindex.d.ts +7 -0
  306. package/dist/tools/code-intelligence-reindex.d.ts.map +1 -0
  307. package/dist/tools/code-intelligence-reindex.js +106 -0
  308. package/dist/tools/code-intelligence-reindex.js.map +1 -0
  309. package/dist/tools/code-intelligence-telemetry.d.ts +5 -0
  310. package/dist/tools/code-intelligence-telemetry.d.ts.map +1 -0
  311. package/dist/tools/code-intelligence-telemetry.js +52 -0
  312. package/dist/tools/code-intelligence-telemetry.js.map +1 -0
  313. package/dist/tools/code-intelligence-tests.d.ts +2 -0
  314. package/dist/tools/code-intelligence-tests.d.ts.map +1 -0
  315. package/dist/tools/code-intelligence-tests.js +24 -0
  316. package/dist/tools/code-intelligence-tests.js.map +1 -0
  317. package/dist/tools/code-intelligence.d.ts +114 -0
  318. package/dist/tools/code-intelligence.d.ts.map +1 -0
  319. package/dist/tools/code-intelligence.js +124 -0
  320. package/dist/tools/code-intelligence.js.map +1 -0
  321. package/dist/tools/compose-permissions.d.ts +26 -0
  322. package/dist/tools/compose-permissions.d.ts.map +1 -1
  323. package/dist/tools/compose-permissions.js +257 -33
  324. package/dist/tools/compose-permissions.js.map +1 -1
  325. package/dist/tools/execute-command.d.ts +2 -0
  326. package/dist/tools/execute-command.d.ts.map +1 -1
  327. package/dist/tools/execute-command.js +114 -28
  328. package/dist/tools/execute-command.js.map +1 -1
  329. package/dist/tools/execute-prompt.d.ts +13 -1
  330. package/dist/tools/execute-prompt.d.ts.map +1 -1
  331. package/dist/tools/execute-prompt.js +310 -61
  332. package/dist/tools/execute-prompt.js.map +1 -1
  333. package/dist/tools/kb-capture.d.ts +53 -0
  334. package/dist/tools/kb-capture.d.ts.map +1 -0
  335. package/dist/tools/kb-capture.js +130 -0
  336. package/dist/tools/kb-capture.js.map +1 -0
  337. package/dist/tools/kb-context.d.ts +17 -0
  338. package/dist/tools/kb-context.d.ts.map +1 -0
  339. package/dist/tools/kb-context.js +29 -0
  340. package/dist/tools/kb-context.js.map +1 -0
  341. package/dist/tools/kb-export.d.ts +19 -0
  342. package/dist/tools/kb-export.d.ts.map +1 -0
  343. package/dist/tools/kb-export.js +344 -0
  344. package/dist/tools/kb-export.js.map +1 -0
  345. package/dist/tools/kb-feedback.d.ts +23 -0
  346. package/dist/tools/kb-feedback.d.ts.map +1 -0
  347. package/dist/tools/kb-feedback.js +43 -0
  348. package/dist/tools/kb-feedback.js.map +1 -0
  349. package/dist/tools/kb-freshness-sweep.d.ts +14 -0
  350. package/dist/tools/kb-freshness-sweep.d.ts.map +1 -0
  351. package/dist/tools/kb-freshness-sweep.js +29 -0
  352. package/dist/tools/kb-freshness-sweep.js.map +1 -0
  353. package/dist/tools/kb-harvest.d.ts +20 -0
  354. package/dist/tools/kb-harvest.d.ts.map +1 -0
  355. package/dist/tools/kb-harvest.js +143 -0
  356. package/dist/tools/kb-harvest.js.map +1 -0
  357. package/dist/tools/kb-import.d.ts +44 -0
  358. package/dist/tools/kb-import.d.ts.map +1 -0
  359. package/dist/tools/kb-import.js +239 -0
  360. package/dist/tools/kb-import.js.map +1 -0
  361. package/dist/tools/kb-invalidate.d.ts +19 -0
  362. package/dist/tools/kb-invalidate.d.ts.map +1 -0
  363. package/dist/tools/kb-invalidate.js +34 -0
  364. package/dist/tools/kb-invalidate.js.map +1 -0
  365. package/dist/tools/kb-list.d.ts +32 -0
  366. package/dist/tools/kb-list.d.ts.map +1 -0
  367. package/dist/tools/kb-list.js +43 -0
  368. package/dist/tools/kb-list.js.map +1 -0
  369. package/dist/tools/kb-promote.d.ts +20 -0
  370. package/dist/tools/kb-promote.d.ts.map +1 -0
  371. package/dist/tools/kb-promote.js +20 -0
  372. package/dist/tools/kb-promote.js.map +1 -0
  373. package/dist/tools/kb-query.d.ts +35 -0
  374. package/dist/tools/kb-query.d.ts.map +1 -0
  375. package/dist/tools/kb-query.js +111 -0
  376. package/dist/tools/kb-query.js.map +1 -0
  377. package/dist/tools/kb-reconcile-prefilter.d.ts +14 -0
  378. package/dist/tools/kb-reconcile-prefilter.d.ts.map +1 -0
  379. package/dist/tools/kb-reconcile-prefilter.js +26 -0
  380. package/dist/tools/kb-reconcile-prefilter.js.map +1 -0
  381. package/dist/tools/kb-resolve-contradiction.d.ts +23 -0
  382. package/dist/tools/kb-resolve-contradiction.d.ts.map +1 -0
  383. package/dist/tools/kb-resolve-contradiction.js +37 -0
  384. package/dist/tools/kb-resolve-contradiction.js.map +1 -0
  385. package/dist/tools/kb-session-prime.d.ts +26 -0
  386. package/dist/tools/kb-session-prime.d.ts.map +1 -0
  387. package/dist/tools/kb-session-prime.js +392 -0
  388. package/dist/tools/kb-session-prime.js.map +1 -0
  389. package/dist/tools/kb-setup.d.ts +20 -0
  390. package/dist/tools/kb-setup.d.ts.map +1 -0
  391. package/dist/tools/kb-setup.js +49 -0
  392. package/dist/tools/kb-setup.js.map +1 -0
  393. package/dist/tools/kb-stats.d.ts +20 -0
  394. package/dist/tools/kb-stats.d.ts.map +1 -0
  395. package/dist/tools/kb-stats.js +115 -0
  396. package/dist/tools/kb-stats.js.map +1 -0
  397. package/dist/tools/list-members.d.ts.map +1 -1
  398. package/dist/tools/list-members.js +6 -2
  399. package/dist/tools/list-members.js.map +1 -1
  400. package/dist/tools/member-detail.d.ts.map +1 -1
  401. package/dist/tools/member-detail.js +13 -3
  402. package/dist/tools/member-detail.js.map +1 -1
  403. package/dist/tools/member-reservation.d.ts.map +1 -1
  404. package/dist/tools/member-reservation.js +13 -1
  405. package/dist/tools/member-reservation.js.map +1 -1
  406. package/dist/tools/monitor-task.d.ts.map +1 -1
  407. package/dist/tools/monitor-task.js +38 -5
  408. package/dist/tools/monitor-task.js.map +1 -1
  409. package/dist/tools/provision-auth.d.ts.map +1 -1
  410. package/dist/tools/provision-auth.js +15 -8
  411. package/dist/tools/provision-auth.js.map +1 -1
  412. package/dist/tools/provision-vcs-auth.d.ts +5 -2
  413. package/dist/tools/provision-vcs-auth.d.ts.map +1 -1
  414. package/dist/tools/provision-vcs-auth.js +58 -52
  415. package/dist/tools/provision-vcs-auth.js.map +1 -1
  416. package/dist/tools/register-member.d.ts +21 -12
  417. package/dist/tools/register-member.d.ts.map +1 -1
  418. package/dist/tools/register-member.js +70 -3
  419. package/dist/tools/register-member.js.map +1 -1
  420. package/dist/tools/remove-member.d.ts.map +1 -1
  421. package/dist/tools/remove-member.js +19 -5
  422. package/dist/tools/remove-member.js.map +1 -1
  423. package/dist/tools/report-status.d.ts.map +1 -1
  424. package/dist/tools/report-status.js +2 -1
  425. package/dist/tools/report-status.js.map +1 -1
  426. package/dist/tools/revoke-vcs-auth.js +2 -2
  427. package/dist/tools/revoke-vcs-auth.js.map +1 -1
  428. package/dist/tools/send-email.d.ts +69 -0
  429. package/dist/tools/send-email.d.ts.map +1 -0
  430. package/dist/tools/send-email.js +177 -0
  431. package/dist/tools/send-email.js.map +1 -0
  432. package/dist/tools/setup-ssh-key.d.ts.map +1 -1
  433. package/dist/tools/setup-ssh-key.js +4 -1
  434. package/dist/tools/setup-ssh-key.js.map +1 -1
  435. package/dist/tools/stop-prompt.js +2 -2
  436. package/dist/tools/stop-prompt.js.map +1 -1
  437. package/dist/tools/update-agent-cli.js +2 -2
  438. package/dist/tools/update-agent-cli.js.map +1 -1
  439. package/dist/tools/update-member.d.ts +21 -12
  440. package/dist/tools/update-member.d.ts.map +1 -1
  441. package/dist/tools/update-member.js +43 -2
  442. package/dist/tools/update-member.js.map +1 -1
  443. package/dist/types.d.ts +12 -1
  444. package/dist/types.d.ts.map +1 -1
  445. package/dist/utils/agent-helpers.d.ts +36 -0
  446. package/dist/utils/agent-helpers.d.ts.map +1 -1
  447. package/dist/utils/agent-helpers.js +39 -1
  448. package/dist/utils/agent-helpers.js.map +1 -1
  449. package/dist/utils/platform.d.ts +7 -0
  450. package/dist/utils/platform.d.ts.map +1 -1
  451. package/dist/utils/platform.js +11 -1
  452. package/dist/utils/platform.js.map +1 -1
  453. package/dist/utils/prompt-errors.js +1 -1
  454. package/dist/utils/prompt-errors.js.map +1 -1
  455. package/dist/utils/session-caller.d.ts +28 -0
  456. package/dist/utils/session-caller.d.ts.map +1 -0
  457. package/dist/utils/session-caller.js +24 -0
  458. package/dist/utils/session-caller.js.map +1 -0
  459. package/dist/utils/work-folder-validation.d.ts +39 -0
  460. package/dist/utils/work-folder-validation.d.ts.map +1 -0
  461. package/dist/utils/work-folder-validation.js +60 -0
  462. package/dist/utils/work-folder-validation.js.map +1 -0
  463. package/dist/utils/workspace-trust.d.ts.map +1 -1
  464. package/dist/utils/workspace-trust.js +5 -1
  465. package/dist/utils/workspace-trust.js.map +1 -1
  466. package/dist/workflows/auto-sprint.js +550 -23
  467. package/package.json +7 -4
  468. package/packages/apra-fleet-client/src/client/api.mjs +210 -7
  469. package/packages/apra-fleet-se/apra-pm/agents/backlog-groomer.md +31 -19
  470. package/packages/apra-fleet-se/apra-pm/agents/ci-watcher.md +16 -1
  471. package/packages/apra-fleet-se/apra-pm/agents/deployer.md +37 -47
  472. package/packages/apra-fleet-se/apra-pm/agents/doer.md +147 -114
  473. package/packages/apra-fleet-se/apra-pm/agents/harvester.md +41 -34
  474. package/packages/apra-fleet-se/apra-pm/agents/integ-test-runner.md +98 -114
  475. package/packages/apra-fleet-se/apra-pm/agents/kb-reconciler.md +205 -0
  476. package/packages/apra-fleet-se/apra-pm/agents/plan-reviewer.md +45 -44
  477. package/packages/apra-fleet-se/apra-pm/agents/planner.md +121 -50
  478. package/packages/apra-fleet-se/apra-pm/agents/regression-test-runner.md +84 -81
  479. package/packages/apra-fleet-se/apra-pm/agents/reviewer.md +118 -44
  480. package/packages/apra-fleet-se/apra-pm/agents/schemas/doer-output.json +63 -3
  481. package/packages/apra-fleet-se/apra-pm/agents/schemas/harvester-output.json +59 -2
  482. package/packages/apra-fleet-se/apra-pm/agents/schemas/integ-test-runner-output.json +3 -3
  483. package/packages/apra-fleet-se/apra-pm/agents/schemas/kb-reconciler-output.json +87 -0
  484. package/packages/apra-fleet-se/apra-pm/agents/schemas/planner-output.json +65 -0
  485. package/packages/apra-fleet-se/apra-pm/agents/schemas/regression-test-runner-output.json +4 -17
  486. package/packages/apra-fleet-se/apra-pm/agents/schemas/reviewer-output.json +105 -8
  487. package/packages/apra-fleet-se/apra-pm/skills/pm/SKILL.md +0 -1
  488. package/packages/apra-fleet-se/apra-pm/skills/pm/beads.md +6 -0
  489. package/packages/apra-fleet-se/apra-pm/skills/pm/cost.md +0 -1
  490. package/packages/apra-fleet-se/apra-pm/skills/pm/fleet-addendum.md +6 -1
  491. package/packages/apra-fleet-se/apra-pm/skills/pm/index.md +56 -0
  492. package/packages/apra-fleet-se/apra-pm/skills/pm/kb-reconcile.md +132 -0
  493. package/packages/apra-fleet-se/apra-pm/skills/pm/kb-review.md +109 -0
  494. package/packages/apra-fleet-se/bin/cli.mjs +139 -3
  495. package/packages/apra-fleet-se/bin/serve.mjs +49 -2
  496. package/packages/apra-fleet-se/fleet-sprint/contracts.mjs +182 -38
  497. package/packages/apra-fleet-se/fleet-sprint/docs/README.md +23 -8
  498. package/packages/apra-fleet-se/fleet-sprint/docs/dolt-manual-recovery-verified.md +258 -0
  499. package/packages/apra-fleet-se/fleet-sprint/docs/dolt-sync-redesign.md +1487 -0
  500. package/packages/apra-fleet-se/fleet-sprint/docs/escalate-to-llm-design.md +908 -0
  501. package/packages/apra-fleet-se/fleet-sprint/docs/shared-orchestrator-reservation-design.md +399 -0
  502. package/packages/apra-fleet-se/fleet-sprint/docs/stabilization-log.md +14 -4
  503. package/packages/apra-fleet-se/fleet-sprint/dolt-settle.mjs +1148 -0
  504. package/packages/apra-fleet-se/fleet-sprint/dolt-sync.mjs +229 -112
  505. package/packages/apra-fleet-se/fleet-sprint/errors.mjs +91 -6
  506. package/packages/apra-fleet-se/fleet-sprint/runner.js +2469 -238
  507. package/packages/apra-fleet-se/fleet-sprint/se-os-commands.mjs +134 -0
  508. package/packages/apra-fleet-se/fleet-sprint/se-posix.mjs +154 -0
  509. package/packages/apra-fleet-se/fleet-sprint/se-windows-gitbash.mjs +97 -0
  510. package/packages/apra-fleet-se/fleet-sprint/se-windows.mjs +143 -0
  511. package/packages/apra-fleet-se/fleet-sprint/skills/fleet-sprint-cli/SKILL.md +15 -3
  512. package/packages/apra-fleet-se/fleet-sprint/skills/fleet-supervisor/SKILL.md +350 -0
  513. package/packages/apra-fleet-se/fleet-sprint/sprint-progress.mjs +101 -0
  514. package/packages/apra-fleet-se/fleet-sprint/vcs-module.mjs +51 -0
  515. package/packages/apra-fleet-se/fleet-sprint/vcs-providers/azure-devops.mjs +657 -12
  516. package/packages/apra-fleet-se/fleet-sprint/vcs-providers/dolt.mjs +33 -4
  517. package/packages/apra-fleet-se/fleet-sprint/vcs-providers/github.mjs +60 -30
  518. package/packages/apra-fleet-se/fleet-sprint/vcs-providers/index.mjs +205 -2
  519. package/packages/apra-fleet-se/fleet-sprint/vcs-providers/shell-helpers.mjs +164 -0
  520. package/packages/apra-fleet-se/fleet-sprint/viewer-extensions.mjs +141 -26
  521. package/packages/apra-fleet-se/package.json +1 -0
  522. package/packages/apra-fleet-workflow/src/viewer/index.mjs +294 -14
  523. package/packages/apra-fleet-workflow/src/viewer/run-title.mjs +60 -0
  524. package/packages/apra-fleet-workflow/src/workflow/index.mjs +443 -35
  525. package/skills/fleet/SKILL.md +20 -9
  526. package/skills/fleet/auth-azdevops.md +44 -5
  527. package/skills/fleet/auth-bitbucket.md +3 -3
  528. package/skills/fleet/auth-github.md +2 -2
  529. package/skills/fleet/beads-conflict-resolution.md +141 -0
  530. package/skills/fleet/beads.md +16 -12
  531. package/skills/fleet/knowledge-agent.md +66 -0
  532. package/skills/fleet/onboarding.md +4 -4
  533. package/skills/fleet/permissions.md +32 -8
  534. package/skills/fleet/profiles/base-dev.json +10 -1
  535. package/skills/fleet/profiles/base-reviewer.json +8 -1
  536. package/skills/fleet/profiles/tag-kb-reconciler.json +20 -0
  537. package/skills/fleet/skill-matrix.md +1 -1
  538. package/skills/fleet/troubleshooting.md +2 -1
  539. package/version.json +1 -1
  540. package/dist/providers/gemini.d.ts +0 -42
  541. package/dist/providers/gemini.d.ts.map +0 -1
  542. package/dist/providers/gemini.js +0 -202
  543. package/dist/providers/gemini.js.map +0 -1
  544. package/packages/apra-fleet-se/fleet-sprint/docs/coach-role-design.md +0 -151
  545. package/packages/apra-fleet-se/fleet-sprint/docs/dolt-tier2-runbook.md +0 -127
  546. package/packages/apra-fleet-se/fleet-sprint/dolt-recovery-path-b.mjs +0 -339
  547. package/packages/apra-fleet-se/fleet-sprint/dolt-recovery-tier2.mjs +0 -360
  548. package/packages/apra-fleet-se/fleet-sprint/dolt-recovery.mjs +0 -363
package/README.md CHANGED
@@ -19,7 +19,7 @@ workforce -- on any machine, anywhere, using every LLM provider at once.
19
19
  [![MCP](https://img.shields.io/badge/MCP-compatible-8A2BE2.svg)](https://modelcontextprotocol.io)
20
20
  [![Ask DeepWiki](https://deepwiki.com/badge.svg)](https://deepwiki.com/Apra-Labs/apra-fleet)
21
21
 
22
- [Quick Start](#quick-start-5-minutes) - [Live Demo](#watch-a-fleet-work) - [How It Works](#how-it-works) - [fleet-sprint Getting Started Guide](docs/fleet-sprint-getting-started.md) - [Docs](https://apra-labs.github.io/apra-fleet)
22
+ [Quick Start](#quick-start-5-minutes) - [Live Demo](#watch-a-fleet-work) - [How It Works](#how-it-works) - [fleet-sprint Getting Started Guide](docs/fleet-sprint-getting-started.md) - [Website](https://apra-labs.github.io/apra-fleet)
23
23
 
24
24
  </div>
25
25
 
@@ -58,8 +58,8 @@ One control plane. Any device. Any model. Any workflow. Any domain.
58
58
 
59
59
  | Pillar | Concretely |
60
60
  |---|---|
61
- | **Any device** | Register any Windows / macOS / Linux machine (local or over SSH) as a fleet member in one command. Cloud members auto-start on demand. |
62
- | **Any model** | Claude, Codex, Gemini, Copilot, Antigravity, local models (any OpenAI-compatible endpoint via OpenCode) -- mixed freely. Tier-based routing (cheap / standard / premium) keeps cost governance built in. Cross-provider review is a quality mechanism: a different model, with different blind spots, checks every change. |
61
+ | **Any device** | Register any Windows / macOS / Linux machine (local or over SSH) as a fleet member in one command. Cloud members auto-start on demand. Windows members are fully supported for dispatch, command execution, and background long-running tasks (launched detached via WMI). |
62
+ | **Any model** | Claude, Codex, Copilot, Antigravity, local models (any OpenAI-compatible endpoint via OpenCode) -- mixed freely. Tier-based routing (cheap / standard / premium) keeps cost governance built in. Cross-provider review is a quality mechanism: a different model, with different blind spots, checks every change. |
63
63
  | **Any workflow** | Workflows are durable programs, not prompt chains: multi-hour, resumable, observable, with member reservations and atomic state. Write your own; ship it to the fleet. |
64
64
  | **Any domain** | Not just software development. The pattern fits wherever work decomposes into agent-sized pieces that need orchestration and an audit trail: nightly retail replenishment (reconcile inventory deltas, draft purchase orders for sign-off), logistics exception handling (triage a delayed shipment, re-book, notify), healthcare intake (summarize referrals, check completeness, route), back-office runs (invoice matching, compliance evidence collection). Software engineering is the vertical running today -- your domain is a workflow away. |
65
65
 
@@ -106,8 +106,8 @@ double-click it (installation is the default action):
106
106
 
107
107
  ```bash
108
108
  npm install -g @apralabs/apra-fleet
109
- apra-fleet # installs for Claude Code (default)
110
- apra-fleet --llm agy # or OpenCode/Codex/Copilot/Gemini
109
+ apra-fleet install # installs for Claude Code (default)
110
+ apra-fleet install --llm agy # or --llm opencode / codex / copilot
111
111
  cd ~/.apra-fleet/bin && apra-fleet start # start the apra-fleet
112
112
  ```
113
113
 
@@ -143,9 +143,9 @@ apra-fleet workflow fleet-sprint \
143
143
  Open the dashboard, watch your fleet PLAN->BUILD->REVIEW->TEST->SHIP in a loop till closure
144
144
 
145
145
  > **New to fleet-sprint?** Read the
146
- > [fleet-sprint Getting Started Guide](docs/fleet-sprint-getting-started.md)
147
- > ([HTML](docs/fleet-sprint-getting-started.html) -
148
- > [PDF](docs/fleet-sprint-getting-started.pdf)) -- a plain-English walkthrough
146
+ > [fleet-sprint Getting Started Guide](https://apra-labs.github.io/apra-fleet/fleet-sprint-getting-started.html)
147
+ > ([Markdown](docs/fleet-sprint-getting-started.md) if you're reading this on
148
+ > GitHub -- [PDF](docs/fleet-sprint-getting-started.pdf)) -- a plain-English walkthrough
149
149
  > of what it does, what you need to prepare (beads backlog, `deploy.md`,
150
150
  > test playbooks, member registration), how to launch and monitor a sprint,
151
151
  > and what's automated versus what's still your call.
@@ -178,8 +178,54 @@ flowchart LR
178
178
 
179
179
  - **Fleet server**: the control plane. Registers members, dispatches commands and prompts, moves files, brokers credentials. Speaks MCP, so any MCP-capable agent can drive a fleet.
180
180
  - **Members**: real machines running provider CLIs. Composes provider-native permissions before every dispatch; unattended modes are scoped, never blanket.
181
- - **Workflow engine**: runs workflow programs with phases, retries, turn budgets, resumable sessions, and per-activity persistent state.
182
- - **Supervisor**: always-on layer -- launch & stop sprints over HTTP, member reservation ledger, crash watchdog, run history.
181
+ - **Workflow engine**: runs workflow programs with phases, retries, turn budgets, resumable sessions, per-activity persistent state, and a cooperative pause/resume gate any workflow can hook into.
182
+ - **Supervisor**: always-on layer -- launch, pause/resume, & stop sprints over HTTP, member reservation ledger, crash watchdog (including a live "paused" state and base-branch-drift indicator), run history.
183
+
184
+ ## Knowledge Layer
185
+
186
+ Every agent session starts by calling `kb_session_prime`. The KB checks which
187
+ files have changed since last read and returns exactly those. Unchanged files
188
+ are served from cached summaries -- no re-read, no wasted tokens.
189
+
190
+ ```
191
+ Cold session: kb_session_prime returns stale_files=[a.ts, b.ts, c.ts]
192
+ Agent reads all three, calls kb_capture for each.
193
+ Warm session: kb_session_prime returns stale_files=[], session_warm=true
194
+ Agent works from KB summaries. Zero file reads.
195
+ ```
196
+
197
+ MCP tools that ship with the KB:
198
+
199
+ | Tool | What it does |
200
+ |------|--------------|
201
+ | `kb_session_prime` | Prime a session: stale files, fresh summaries, GitNexus call list |
202
+ | `kb_capture` | Store a learning, context-cache, runbook, or knowledge entry |
203
+ | `kb_query` | Two-level FTS retrieval (L1: title+summary, L2: full content) |
204
+ | `kb_list` | Audit-list entries by confidence/type/module/symbol (read-only, no use_count bump) |
205
+ | `kb_context` | Batch file freshness check (single git call for N files) |
206
+ | `kb_invalidate` | Mark files stale immediately (also called by the git hook) |
207
+ | `kb_promote` | Advance confidence: UNVERIFIED -> INFERRED -> CONFIRMED |
208
+ | `kb_harvest` | Extract learnings from a session transcript (auto-fires after execute_prompt) |
209
+ | `kb_export` | Write live CONFIRMED entries to `.fleet/kb-canonical.json` -- the git-shareable team bible |
210
+ | `kb_setup` | Install git hook, write provider config, store remote token encrypted |
211
+
212
+ Every KB tool call is scoped to the repo it is about -- a fleet server
213
+ handling many members across many repos never lets one repo's learnings land
214
+ in another repo's KB. Scope is normally derived from the caller's repo path;
215
+ tools also accept an explicit `repo_remote_url` so a remote member (whose
216
+ work folder is a path on another host, unreachable from the fleet server's
217
+ filesystem) resolves to the same project KB as a local clone of that repo
218
+ instead of a shared fallback database. The automatic post-prompt harvest and
219
+ the `code_context` KB enrichment path both forward this URL too, and an
220
+ unreachable work-folder path is never silently swapped for the fleet
221
+ server's own working directory -- see
222
+ [Per-repo KB isolation](docs/knowledge-layer.md#per-repo-kb-isolation) for
223
+ the full anchor and cache-keying rules.
224
+
225
+ The backend is swappable: start with local SQLite, add a central HTTP server for
226
+ a team, or plug in Postgres later -- all via a one-line config change.
227
+
228
+ See [docs/knowledge-layer.md](docs/knowledge-layer.md) for the full guide.
183
229
 
184
230
  ## Explore with agents. Operate with programs.
185
231
 
@@ -251,7 +297,100 @@ Secrets are entered out-of-band into a credential store and referenced as
251
297
  any LLM or log. Credentials scope to members, expire on TTL, and can carry
252
298
  a network egress policy (allow / deny / confirm). Every member runs with
253
299
  composed, provider-native permission files -- allow-listed tools, not
254
- god-mode. VCS access is provisioned and revocable per member.
300
+ god-mode. VCS access is provisioned and revocable per member, across GitHub,
301
+ Bitbucket, and Azure DevOps -- host differences (URL shape, PR REST dialect,
302
+ auth pattern, error vocabulary) are hidden behind a per-provider descriptor
303
+ rather than leaking into shared code; see
304
+ `docs/design-azure-devops-vcs-auth.md` for the Azure DevOps provider's
305
+ credential-assembly and PAT-lifetime details. Permission
306
+ composition verifies its own delivery: a grant is read back off the target
307
+ member and structurally compared against what was intended before it is
308
+ reported as applied, so a failed or partial write is surfaced as an
309
+ explicit failure rather than a false success.
310
+
311
+ ## Email Configuration
312
+
313
+ The fleet `send_email` tool sends email via **SendGrid** or **SMTP**. Secrets
314
+ are stored in the fleet credential store. Non-secret config (provider, host,
315
+ port, from address) is passed by the workflow in each call.
316
+
317
+ ### Storing secrets (one-time setup)
318
+
319
+ Store email secrets via the CLI:
320
+
321
+ ```bash
322
+ # SendGrid API key
323
+ apra-fleet secret --set sendgrid_api_key --persist
324
+
325
+ # SMTP password
326
+ apra-fleet secret --set smtp_password --persist
327
+ ```
328
+
329
+ Or via the MCP tool (the path an LLM agent uses):
330
+
331
+ ```json
332
+ { "name": "sendgrid_api_key", "prompt": "Enter your SendGrid API key", "persist": true }
333
+ ```
334
+
335
+ Secrets are encrypted in the fleet credential store. They never appear in
336
+ workflow code, config files, or environment variables.
337
+
338
+ ### Sending email from a workflow
339
+
340
+ The workflow passes non-secret config inline and calls `send_email`. Load
341
+ your config however you prefer (JSON file, hardcoded, etc.):
342
+
343
+ ```javascript
344
+ import { parseToolJson } from '@apralabs/apra-fleet-client';
345
+ import { connectFleet } from '@apralabs/apra-fleet-client/server-resolution';
346
+
347
+ const { fleetApi } = await connectFleet({ env: process.env });
348
+
349
+ // fleetApi wrappers return the raw MCP tool result ({ content: [...] });
350
+ // parseToolJson extracts the JSON payload.
351
+ const result = parseToolJson(await fleetApi.sendEmail({
352
+ provider: 'smtp',
353
+ host: 'smtp.example.com',
354
+ port: 587,
355
+ user: 'notifications@example.com',
356
+ from: 'noreply@example.com',
357
+ to: 'team@example.com',
358
+ subject: 'Sprint Report',
359
+ body: 'All tasks completed.'
360
+ }));
361
+ console.log(`Sent: ${result.messageId}`);
362
+ ```
363
+
364
+ The SMTP password resolves from the credential store automatically. It never
365
+ appears in the workflow. See `examples/workflows/email-notify/` for a
366
+ complete runnable example and `docs/email-workflow-guide.md` for the full
367
+ walkthrough.
368
+
369
+ ### send_email Tool Reference
370
+
371
+ | Parameter | Type | Required | Description |
372
+ |---|---|---|---|
373
+ | `provider` | `"sendgrid"` or `"smtp"` | no (default: `"sendgrid"`) | Email provider |
374
+ | `from` | string | yes | Sender email address |
375
+ | `host` | string | SMTP only | SMTP server hostname |
376
+ | `port` | number | no (default: 587, or 465 when `secure` is true) | SMTP server port |
377
+ | `user` | string | SMTP only | SMTP username |
378
+ | `secure` | boolean | no (default: false) | Implicit TLS (port 465). When false, STARTTLS is required. |
379
+ | `to` | string or string[] | yes | Recipient email address(es) |
380
+ | `subject` | string | yes | Email subject line |
381
+ | `body` | string | yes | Plain-text email body |
382
+ | `html` | string | no | HTML email body |
383
+ | `cc` | string[] | no | CC recipient addresses |
384
+ | `bcc` | string[] | no | BCC recipient addresses |
385
+ | `attachments` | attachment[] | no | File attachments (base64-encoded) |
386
+
387
+ Each attachment: `filename` (string), `content` (string, base64), `contentType` (string, optional).
388
+
389
+ Secrets are resolved from the credential store by name:
390
+ - **SendGrid:** `sendgrid_api_key`
391
+ - **SMTP:** `smtp_password`
392
+
393
+ Returns: `{ ok: true, messageId }` on success, `{ ok: false, error }` on failure.
255
394
 
256
395
  ## The packages
257
396
 
@@ -273,7 +412,7 @@ third-party verticals.
273
412
 
274
413
  | Topic | Link |
275
414
  |-------|------|
276
- | **fleet-sprint Getting Started Guide (start here, plain English)** | [Markdown](docs/fleet-sprint-getting-started.md) - [HTML](docs/fleet-sprint-getting-started.html) - [PDF](docs/fleet-sprint-getting-started.pdf) |
415
+ | **fleet-sprint Getting Started Guide (start here, plain English)** | [Website](https://apra-labs.github.io/apra-fleet/fleet-sprint-getting-started.html) - [Markdown](docs/fleet-sprint-getting-started.md) - [PDF](docs/fleet-sprint-getting-started.pdf) |
277
416
  | Codebase wiki (architecture, internals, AI Q&A) | [DeepWiki](https://deepwiki.com/Apra-Labs/apra-fleet) |
278
417
  | Install, uninstall, the `--llm` flag | [docs/install.md](docs/install.md) |
279
418
  | Choosing a provider (roles, gotchas, mixing providers, OpenCode/local models) | [docs/provider-guide.md](docs/provider-guide.md) |
@@ -290,10 +429,16 @@ third-party verticals.
290
429
  | Git authentication | [docs/design-git-auth.md](docs/design-git-auth.md) |
291
430
  | Cloud compute | [docs/cloud-compute.md](docs/cloud-compute.md) |
292
431
  | Architecture | [docs/architecture.md](docs/architecture.md) |
432
+ | Windows shell selection (probe order, gitbash/pwsh7/powershell5, shell vs os) | [docs/windows-shell-selection.md](docs/windows-shell-selection.md) |
433
+ | Cross-shell command construction for member-bound commands | [docs/cross-shell-command-construction.md](docs/cross-shell-command-construction.md) |
434
+ | Knowledge Layer (setup, usage, provider swap) | [docs/knowledge-layer.md](docs/knowledge-layer.md) |
435
+ | Code intelligence provider abstraction | [docs/code-intelligence-providers.md](docs/code-intelligence-providers.md) |
293
436
  | Hub-spoke cloud migration plan (historical; see tier-3 ownership ADR) | [docs/hub-spoke-master-plan.md](docs/hub-spoke-master-plan.md) |
294
437
  | Tier-3 ownership decision (fleet-dashboard vs `src/hub-service/`) | [docs/adr-tier3-ownership.md](docs/adr-tier3-ownership.md) |
295
438
  | Shared hub/dashboard API contract package | [packages/fleet-api-contract/README.md](packages/fleet-api-contract/README.md) |
296
- | Workflow engine internals (`agent()`/`parallel()`/`pipeline()`, journal, budget) | [packages/apra-fleet-workflow/docs/apra-fleet-workflow-architecture.md](packages/apra-fleet-workflow/docs/apra-fleet-workflow-architecture.md) |
439
+ | Workflow engine internals (`agent()`/`parallel()`/`pipeline()`, journal, budget, pause/resume) | [packages/apra-fleet-workflow/docs/apra-fleet-workflow-architecture.md](packages/apra-fleet-workflow/docs/apra-fleet-workflow-architecture.md) |
440
+ | Cooperative workflow pause/resume (engine, viewer, supervisor, fleet-sprint) | [docs/features/workflow-pause-resume.md](docs/features/workflow-pause-resume.md) |
441
+ | Supervisor dashboard live-refresh (`/state` + `/events` SSE, tab-activation refresh, in-memory scope expansion) | [docs/features/supervisor-dashboard-live-refresh.md](docs/features/supervisor-dashboard-live-refresh.md) |
297
442
  | Writing and running workflow scripts | [packages/apra-fleet-workflow/docs/workflow-guide.md](packages/apra-fleet-workflow/docs/workflow-guide.md) |
298
443
  | Authoring a SEA-embedded `apra-fleet workflow` (manifest, entry contract, launcher env vars) | [docs/authoring-workflows.md](docs/authoring-workflows.md) |
299
444
  | Workflow launcher fleet-server resolution order (HTTP singleton vs. stdio) | [docs/adr-workflow-server-resolution.md](docs/adr-workflow-server-resolution.md) |
@@ -302,6 +447,7 @@ third-party verticals.
302
447
  | Auto-sprint CLI reference | [packages/apra-fleet-se/docs/cli-reference.md](packages/apra-fleet-se/docs/cli-reference.md) |
303
448
  | Auto-sprint internals (cycle loop, stall detection, budget, topology) | [packages/apra-fleet-se/docs/architecture.md](packages/apra-fleet-se/docs/architecture.md) |
304
449
  | Auto-sprint agent role contracts | [packages/apra-fleet-se/docs/role-contracts.md](packages/apra-fleet-se/docs/role-contracts.md) |
450
+ | fleet-supervisor skill (start/stop/restart/auto-start-on-boot, sprint launch via HTTP API) | [packages/apra-fleet-se/fleet-sprint/skills/fleet-supervisor/SKILL.md](packages/apra-fleet-se/fleet-sprint/skills/fleet-supervisor/SKILL.md) |
305
451
  | MCP client SDK overview (transports, `ApraFleet` API) | [packages/apra-fleet-client/docs/overview.md](packages/apra-fleet-client/docs/overview.md) |
306
452
  | MCP client SDK API reference | [packages/apra-fleet-client/docs/api-reference.md](packages/apra-fleet-client/docs/api-reference.md) |
307
453
  | MCP client SDK getting started | [packages/apra-fleet-client/docs/getting-started.md](packages/apra-fleet-client/docs/getting-started.md) |
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  name: backlog-groomer
3
3
  description: For one operator's assigned beads, finds what is ready/urgent to sprint next, proposes cohesive sprint sets from interdependencies, finds duplicates, and surfaces high-priority/urgent-sounding items whose content quality is too low to act on. Full beads mutation authority (merge/close/defer/reject), always evidence-and-reasoning noted. Never changes code.
4
- tools: [Read, Grep, Glob, Bash]
4
+ tools: [Read, Grep, Glob, Bash, ToolSearch]
5
5
  ---
6
6
 
7
7
  # Backlog Groomer
@@ -10,6 +10,20 @@ You groom ONE operator's slice of the open beads backlog: what to pick up next,
10
10
  to sprint together, what's a duplicate, what needs fixing before it's actionable. You
11
11
  analyze AND mutate beads directly -- but you never touch code beyond reading it.
12
12
 
13
+ ## Step 0 -- Knowledge Bank (required -- do this BEFORE any grooming decision)
14
+
15
+ 1. Run ToolSearch with query `"select:mcp__apra-fleet__kb_session_prime,mcp__apra-fleet__kb_capture"`
16
+ 2. Call `mcp__apra-fleet__kb_session_prime` with `repo_path` set to the repo whose backlog
17
+ you are grooming, and `hint_modules` naming the subsystems the assigned beads touch.
18
+ Trust CONFIRMED entries fully. Use INFERRED entries as hints, not facts. This matters
19
+ most for duplicate detection and sprint-set grouping.
20
+ 3. When grooming turns up a durable backlog fact -- two ids that are genuinely the same
21
+ work, a dependency between beads that their text does not state, or a recurring reason
22
+ items land unactionable -- call `mcp__apra-fleet__kb_capture` with type "knowledge".
23
+ Do not capture per-sprint churn; capture what stays true.
24
+
25
+ If ToolSearch returns no KB tools (MCP server not running), skip these steps and proceed.
26
+
13
27
  ## Usage modes
14
28
 
15
29
  - **"Define my sprint"** -> Responsibility 1: ready/urgent items + sprint-set groups.
@@ -78,24 +92,23 @@ The canonical machine-readable contract lives in the sibling file
78
92
 
79
93
  ## Beads semantics
80
94
 
81
- - `parent-child` = GROUPING. `blocks` = ORDERING. Never conflate them. One parent only.
95
+ Graph semantics (`parent-child` = grouping, `blocks` = ordering, epic rules, `bd epic
96
+ status` gotchas) are canonical in `_shared/GRAPH-SEMANTICS.md`, the sibling file
97
+ installed alongside this one -- read it; do not restate or improvise those rules here.
98
+ Semantics specific to this role:
99
+
82
100
  - `assignee` is set explicitly (`bd update <id> --assignee <identity>`) or via
83
101
  `bd update <id> --claim` (also flips status to `in_progress`). Fall back to `owner`
84
- (static, set once at creation) only when `assignee` is empty.
85
- - `issue_type` does NOT affect ready/dispatch eligibility. Only three things hide a bead
86
- from ready work: an unclosed child, an unmet `blocks` dependency, or status not
87
- `open`/`in_progress`.
88
- - `epic -> feature -> task` is a loose convention. The one hard rule: an epic may
89
- `blocks` only another epic -- bd does not enforce same-type pairs.
90
- - `bd epic status <id>` only rolls up correctly when `<id>` is actually typed `epic`;
91
- on a non-epic id it silently returns unrelated epics.
102
+ (static, set at creation) only when `assignee` is empty.
103
+ - Only three things hide a bead from ready work: an unclosed child, an unmet `blocks`
104
+ dependency, or status not `open`/`in_progress`. `issue_type` never does.
92
105
  - `gate` (`bd create --type=gate --await-type=<kind> --await-id=<id>`) blocks dependents
93
106
  until an external condition resolves. Documented await-types are GitHub-shaped; when
94
107
  recommending a gate, describe the pattern and let the operator pick an await-type
95
108
  matching their actual VCS/CI.
96
- - Title prefixes are convention, not schema, but widely matched on: `[test]` = verification
97
- work for a sibling/parent; `[impl]` = implementation; `[integ]` = filed by an
98
- integration/re-verification pass; `[regression][carry-over]` = rolled-over regression bug.
109
+ - Title prefixes are convention, not schema, but widely matched on: `[test]` =
110
+ verification work; `[impl]` = implementation; `[integ]` = filed by an integration
111
+ pass; `[regression][carry-over]` = rolled-over regression bug.
99
112
 
100
113
  ## Step 1 -- Load the backlog, scoped to identity
101
114
 
@@ -111,9 +124,8 @@ Fall back to non-`--json`/non-`--assignee` forms if unsupported, then filter cli
111
124
  visibly separate. `bd show <id> --json` before any judgment call -- never flag
112
125
  description quality from a summary line alone.
113
126
 
114
- If a `bd` JSON payload is too large to read directly, redirect it under a scratch dir
115
- instead of the repo root -- e.g. `.beads/tmp/<name>.json` (already covered by the
116
- existing `.beads/` gitignore entry) -- never write scratch JSON to the repo root.
127
+ If a `bd` JSON payload is too large to read directly, redirect it to a gitignored
128
+ scratch path (e.g. `.beads/tmp/<name>.json`) -- never to the repo root.
117
129
 
118
130
  ## Step 2 -- Structural deadlock scan (every time)
119
131
 
@@ -225,10 +237,10 @@ The canonical machine-readable contract for this output lives in the sibling fil
225
237
  ```json
226
238
  {
227
239
  "status": "OK",
228
- "identity": "akhil.kumar@gmail.com",
240
+ "identity": "dev@example.com",
229
241
  "notes": "12 ready, 2 sprint sets proposed, 1 duplicate merged, 3 needing grooming.",
230
242
  "ready": [
231
- { "id": "BD-14", "type": "task", "priority": "P1", "status": "open", "assignee": "akhil.kumar@gmail.com", "ageDays": 4, "size": "M", "rationale": "No blockers, clear AC, feeds the auth epic." }
243
+ { "id": "BD-14", "type": "task", "priority": "P1", "status": "open", "assignee": "dev@example.com", "ageDays": 4, "size": "M", "rationale": "No blockers, clear AC, feeds the auth epic." }
232
244
  ],
233
245
  "sprintSets": [
234
246
  { "label": "auth-hardening", "beadIds": ["BD-14", "BD-15"], "reason": "Shared parent BD-10, sequential blocks edge." }
@@ -247,7 +259,7 @@ The canonical machine-readable contract for this output lives in the sibling fil
247
259
  ],
248
260
  "notYours": [],
249
261
  "stale": [
250
- { "id": "BD-60", "type": "bug", "priority": "P1", "status": "open", "assignee": "akhil.kumar@gmail.com", "ageDays": 95, "size": "S", "rationale": "P1, 95 days untouched -- likely dropped, confirm before continuing to carry it." }
262
+ { "id": "BD-60", "type": "bug", "priority": "P1", "status": "open", "assignee": "dev@example.com", "ageDays": 95, "size": "S", "rationale": "P1, 95 days untouched -- likely dropped, confirm before continuing to carry it." }
251
263
  ],
252
264
  "structuralIssues": [
253
265
  { "kind": "deadlock", "description": "BD-70 blocks its own parent BD-71", "beadIds": ["BD-70", "BD-71"] }
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  name: ci-watcher
3
3
  description: Polls CI for the sprint HEAD SHA; returns green/red/not_configured/pending.
4
- tools: [Bash]
4
+ tools: [Bash, ToolSearch]
5
5
  ---
6
6
 
7
7
  # CI Status Check
@@ -22,6 +22,18 @@ Your dispatch prompt must supply ONE of the two scoping forms:
22
22
  `expectedHeadSha` missing), do not guess or check an arbitrary branch. Return
23
23
  `status: "pending"` with `notes` stating which input was missing.
24
24
 
25
+ ## Step 0 -- Knowledge Bank (required -- do this BEFORE any other work)
26
+
27
+ 1. Run ToolSearch with query `"select:mcp__apra-fleet__kb_session_prime"`
28
+ 2. Call `mcp__apra-fleet__kb_session_prime` with `repo_path` set to the repo whose CI you
29
+ are checking, and `hint_modules` naming its CI workflow files. Trust CONFIRMED entries
30
+ fully. Use INFERRED entries as hints, not facts. Known-flaky tests and known CI failure
31
+ modes are the point here -- they change how you read a red run.
32
+ 3. Do NOT capture. You poll a status API; you verify no claim about this repository, so you
33
+ have no basis to write one down.
34
+
35
+ If ToolSearch returns no KB tools (MCP server not running), skip these steps and proceed.
36
+
25
37
  ## Step 1 -- List recent CI runs
26
38
 
27
39
  Branch-scoped:
@@ -36,6 +48,9 @@ gh run list --pr <prNumber> --limit 5 --json databaseId,status,conclusion,headSh
36
48
  (In PR-scoped mode, apply Step 2 to the runs for the PR's head commit instead of
37
49
  `expectedHeadSha`.)
38
50
 
51
+ If `gh` is unavailable or the repo's remote is not GitHub, do not guess at another CI
52
+ system: return `status: "not_configured"` with `notes` naming what was found.
53
+
39
54
  ## Step 2 -- Interpret the result
40
55
 
41
56
  **No runs returned**: CI has never been triggered on this branch.
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  name: deployer
3
3
  description: Follows deploy.md to deploy the software onto the target environment and verify it with the smoke test.
4
- tools: [Read, Bash]
4
+ tools: [Read, Bash, ToolSearch]
5
5
  ---
6
6
 
7
7
  # Deployment
@@ -28,29 +28,21 @@ playbook yourself. If `deploy.md` is entirely absent (not just missing a
28
28
  section), return `deployed: false` with `notes` naming the missing file -- do
29
29
  not improvise deploy steps that are not written down in the runbook.
30
30
 
31
- ## Step 0 -- Check permissions before running anything
32
-
33
- Read `deploy.md`. Look for a `## Permissions` section. If found, verify each
34
- listed command prefix is covered by the MERGED effective permission set --
35
- on Claude Code that means SOME entry in `permissions.allow` of EITHER
36
- `.claude/settings.json` (the team-committed, shared baseline) OR
37
- `.claude/settings.local.json` (the per-checkout, individual/gitignored file;
38
- this is the ONLY file the fleet's `compose_permissions` tool ever writes to
39
- for Claude Code members -- see `skills/fleet/permissions.md`). Claude Code
40
- merges `permissions.allow` from both files, so a grant in EITHER one counts
41
- as coverage; checking only `settings.json` misses every grant
42
- `compose_permissions` delivered. A broader prefix entry counts as coverage
43
- too -- e.g. `Bash(docker:*)` covers `docker compose`. Other providers keep
44
- the equivalent allowlist in their own native config file (see
45
- `src/providers/*.ts`).
46
-
47
- Run the merge MECHANICALLY, in one command, rather than reading each file
48
- separately and merging by eye -- two sequential `cat`s invite stopping at the
49
- first (often-empty) file and never getting to the second, which silently
50
- reports a real grant as missing (observed live, apra-fleet: `settings.json`
51
- legitimately carries no `permissions.allow` in this repo's convention -- every
52
- grant lives in `settings.local.json` -- so a by-eye read that stops at the
53
- first empty file always concludes "nothing is granted" even when it is):
31
+ ## Step 0a -- Check permissions before running anything
32
+
33
+ Read `deploy.md`. If it has a `## Permissions` section, verify each listed
34
+ command prefix is covered by the MERGED effective permission set -- on
35
+ Claude Code, the union of `permissions.allow` from BOTH
36
+ `.claude/settings.json` (team-committed baseline) AND
37
+ `.claude/settings.local.json` (per-checkout, gitignored -- the only file the
38
+ fleet's `compose_permissions` tool writes to; see
39
+ `skills/fleet/permissions.md`). A grant in either file counts; a broader
40
+ prefix counts too (e.g. `Bash(docker:*)` covers `docker compose`). Other
41
+ providers keep the equivalent allowlist in their own native config file.
42
+
43
+ Compute the union MECHANICALLY, in one command -- reading the files
44
+ separately and merging by eye reliably misses grants when the first file is
45
+ empty:
54
46
 
55
47
  ```bash
56
48
  node -e '
@@ -67,29 +59,27 @@ console.log(JSON.stringify([...allow], null, 2));
67
59
  # use your provider's native config file(s) otherwise
68
60
  ```
69
61
 
70
- Check every required command prefix against this one merged list. If any
71
- required command prefix has no covering entry in it, STOP immediately and
72
- return `deployed: false` with notes listing every missing entry, e.g.:
73
-
74
- Missing permissions in the merged CLI permission settings (.claude/settings.json
75
- + .claude/settings.local.json on Claude Code -- neither file covers these):
76
- Bash(docker *)
77
- Bash(docker-compose *)
78
- Ask the orchestrator/operator to run compose_permissions with the missing
79
- grant(s), then re-trigger the sprint.
80
-
81
- Do NOT attempt to add the permissions yourself, by editing any file directly:
82
- - `.claude/settings.json` is the team-committed baseline -- changes there
83
- require the team/a PR, never a self-edit.
84
- - `.claude/settings.local.json` is the correct target for an individual/local
85
- grant, but it must be provisioned via the `compose_permissions` MCP tool
86
- (grant mode), NOT hand-edited either -- that tool is the provider-agnostic
87
- delivery mechanism (this repo supports non-Claude providers too: Gemini,
88
- AGY, OpenCode, Codex -- each has its own native config path via the same
89
- tool).
90
- The correct escalation when a required permission is missing from the merged
91
- effective set is: ask the orchestrator/operator to run `compose_permissions`
92
- with the missing grant. Do NOT proceed past Step 0 if any permissions are missing.
62
+ Check every required prefix against this one merged list. If any prefix has
63
+ no covering entry, STOP immediately and return `deployed: false`, listing
64
+ every missing entry in `notes` and asking the orchestrator/operator to run
65
+ `compose_permissions` with the missing grant(s), then re-trigger the sprint.
66
+ NEVER add permissions yourself: `.claude/settings.json` changes require a
67
+ team PR, and `.claude/settings.local.json` must be provisioned via the
68
+ `compose_permissions` MCP tool (the provider-agnostic delivery mechanism
69
+ across all supported providers), never hand-edited. Do NOT proceed past
70
+ Step 0a while any permission is missing.
71
+
72
+ ## Step 0b -- Knowledge Bank (required -- do this BEFORE any deploy.md operation)
73
+
74
+ 1. Run ToolSearch with query `"select:mcp__apra-fleet__kb_session_prime,mcp__apra-fleet__kb_capture"`
75
+ 2. Call `mcp__apra-fleet__kb_session_prime` with `repo_path` set to the repo being deployed,
76
+ and `hint_modules` naming the deploy targets in `deploy.md`. Trust CONFIRMED entries
77
+ fully. Use INFERRED entries as hints, not facts.
78
+ 3. When a deploy step fails for a non-obvious reason, or a runbook instruction turns out to
79
+ be wrong or incomplete, call `mcp__apra-fleet__kb_capture` with type "runbook" or
80
+ "learning". A deploy gotcha you had to discover is exactly what the next deploy needs.
81
+
82
+ If ToolSearch returns no KB tools (MCP server not running), skip these steps and proceed.
93
83
 
94
84
  ## deploy.md operations
95
85