wotann 0.5.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 (4534) hide show
  1. package/LICENSE +21 -0
  2. package/NOTICE +110 -0
  3. package/README.md +382 -0
  4. package/dist/acp/manifest.d.ts +160 -0
  5. package/dist/acp/manifest.d.ts.map +1 -0
  6. package/dist/acp/manifest.js +185 -0
  7. package/dist/acp/manifest.js.map +1 -0
  8. package/dist/acp/protocol.d.ts +533 -0
  9. package/dist/acp/protocol.d.ts.map +1 -0
  10. package/dist/acp/protocol.js +220 -0
  11. package/dist/acp/protocol.js.map +1 -0
  12. package/dist/acp/registry.d.ts +90 -0
  13. package/dist/acp/registry.d.ts.map +1 -0
  14. package/dist/acp/registry.js +297 -0
  15. package/dist/acp/registry.js.map +1 -0
  16. package/dist/acp/runtime-handlers.d.ts +58 -0
  17. package/dist/acp/runtime-handlers.d.ts.map +1 -0
  18. package/dist/acp/runtime-handlers.js +169 -0
  19. package/dist/acp/runtime-handlers.js.map +1 -0
  20. package/dist/acp/server.d.ts +184 -0
  21. package/dist/acp/server.d.ts.map +1 -0
  22. package/dist/acp/server.js +553 -0
  23. package/dist/acp/server.js.map +1 -0
  24. package/dist/acp/stdio.d.ts +57 -0
  25. package/dist/acp/stdio.d.ts.map +1 -0
  26. package/dist/acp/stdio.js +178 -0
  27. package/dist/acp/stdio.js.map +1 -0
  28. package/dist/acp/thread-handlers.d.ts +27 -0
  29. package/dist/acp/thread-handlers.d.ts.map +1 -0
  30. package/dist/acp/thread-handlers.js +94 -0
  31. package/dist/acp/thread-handlers.js.map +1 -0
  32. package/dist/agents/background-agent.d.ts +80 -0
  33. package/dist/agents/background-agent.d.ts.map +1 -0
  34. package/dist/agents/background-agent.js +329 -0
  35. package/dist/agents/background-agent.js.map +1 -0
  36. package/dist/agents/required-reading.d.ts +57 -0
  37. package/dist/agents/required-reading.d.ts.map +1 -0
  38. package/dist/agents/required-reading.js +118 -0
  39. package/dist/agents/required-reading.js.map +1 -0
  40. package/dist/api/anthropic-gateway.d.ts +195 -0
  41. package/dist/api/anthropic-gateway.d.ts.map +1 -0
  42. package/dist/api/anthropic-gateway.js +265 -0
  43. package/dist/api/anthropic-gateway.js.map +1 -0
  44. package/dist/api/server.d.ts +166 -0
  45. package/dist/api/server.d.ts.map +1 -0
  46. package/dist/api/server.js +413 -0
  47. package/dist/api/server.js.map +1 -0
  48. package/dist/api/sse-computer-session.d.ts +119 -0
  49. package/dist/api/sse-computer-session.d.ts.map +1 -0
  50. package/dist/api/sse-computer-session.js +220 -0
  51. package/dist/api/sse-computer-session.js.map +1 -0
  52. package/dist/api/ws-hardening.d.ts +76 -0
  53. package/dist/api/ws-hardening.d.ts.map +1 -0
  54. package/dist/api/ws-hardening.js +102 -0
  55. package/dist/api/ws-hardening.js.map +1 -0
  56. package/dist/auth/auth-mode.d.ts +111 -0
  57. package/dist/auth/auth-mode.d.ts.map +1 -0
  58. package/dist/auth/auth-mode.js +133 -0
  59. package/dist/auth/auth-mode.js.map +1 -0
  60. package/dist/auth/login.d.ts +72 -0
  61. package/dist/auth/login.d.ts.map +1 -0
  62. package/dist/auth/login.js +414 -0
  63. package/dist/auth/login.js.map +1 -0
  64. package/dist/auth/oauth-rotator.d.ts +60 -0
  65. package/dist/auth/oauth-rotator.d.ts.map +1 -0
  66. package/dist/auth/oauth-rotator.js +71 -0
  67. package/dist/auth/oauth-rotator.js.map +1 -0
  68. package/dist/auth/oauth-server.d.ts +88 -0
  69. package/dist/auth/oauth-server.d.ts.map +1 -0
  70. package/dist/auth/oauth-server.js +382 -0
  71. package/dist/auth/oauth-server.js.map +1 -0
  72. package/dist/auth/secure-store.d.ts +65 -0
  73. package/dist/auth/secure-store.d.ts.map +1 -0
  74. package/dist/auth/secure-store.js +235 -0
  75. package/dist/auth/secure-store.js.map +1 -0
  76. package/dist/automation/monitor-agents.d.ts +86 -0
  77. package/dist/automation/monitor-agents.d.ts.map +1 -0
  78. package/dist/automation/monitor-agents.js +210 -0
  79. package/dist/automation/monitor-agents.js.map +1 -0
  80. package/dist/automation/n8n-templates.d.ts +62 -0
  81. package/dist/automation/n8n-templates.d.ts.map +1 -0
  82. package/dist/automation/n8n-templates.js +164 -0
  83. package/dist/automation/n8n-templates.js.map +1 -0
  84. package/dist/automation/rss-parser.d.ts +26 -0
  85. package/dist/automation/rss-parser.d.ts.map +1 -0
  86. package/dist/automation/rss-parser.js +54 -0
  87. package/dist/automation/rss-parser.js.map +1 -0
  88. package/dist/autopilot/checkpoint.d.ts +116 -0
  89. package/dist/autopilot/checkpoint.d.ts.map +1 -0
  90. package/dist/autopilot/checkpoint.js +222 -0
  91. package/dist/autopilot/checkpoint.js.map +1 -0
  92. package/dist/autopilot/ci-feedback.d.ts +68 -0
  93. package/dist/autopilot/ci-feedback.d.ts.map +1 -0
  94. package/dist/autopilot/ci-feedback.js +207 -0
  95. package/dist/autopilot/ci-feedback.js.map +1 -0
  96. package/dist/autopilot/completion-oracle.d.ts +63 -0
  97. package/dist/autopilot/completion-oracle.d.ts.map +1 -0
  98. package/dist/autopilot/completion-oracle.js +280 -0
  99. package/dist/autopilot/completion-oracle.js.map +1 -0
  100. package/dist/autopilot/oracle-worker.d.ts +102 -0
  101. package/dist/autopilot/oracle-worker.d.ts.map +1 -0
  102. package/dist/autopilot/oracle-worker.js +232 -0
  103. package/dist/autopilot/oracle-worker.js.map +1 -0
  104. package/dist/autopilot/pr-artifacts.d.ts +73 -0
  105. package/dist/autopilot/pr-artifacts.d.ts.map +1 -0
  106. package/dist/autopilot/pr-artifacts.js +308 -0
  107. package/dist/autopilot/pr-artifacts.js.map +1 -0
  108. package/dist/autopilot/trajectory-recorder.d.ts +86 -0
  109. package/dist/autopilot/trajectory-recorder.d.ts.map +1 -0
  110. package/dist/autopilot/trajectory-recorder.js +181 -0
  111. package/dist/autopilot/trajectory-recorder.js.map +1 -0
  112. package/dist/autopilot/types.d.ts +60 -0
  113. package/dist/autopilot/types.d.ts.map +1 -0
  114. package/dist/autopilot/types.js +14 -0
  115. package/dist/autopilot/types.js.map +1 -0
  116. package/dist/browser/agentic-browser.d.ts +291 -0
  117. package/dist/browser/agentic-browser.d.ts.map +1 -0
  118. package/dist/browser/agentic-browser.js +595 -0
  119. package/dist/browser/agentic-browser.js.map +1 -0
  120. package/dist/browser/annotation-bridge.d.ts +116 -0
  121. package/dist/browser/annotation-bridge.d.ts.map +1 -0
  122. package/dist/browser/annotation-bridge.js +156 -0
  123. package/dist/browser/annotation-bridge.js.map +1 -0
  124. package/dist/browser/atomic-actions.d.ts +130 -0
  125. package/dist/browser/atomic-actions.d.ts.map +1 -0
  126. package/dist/browser/atomic-actions.js +178 -0
  127. package/dist/browser/atomic-actions.js.map +1 -0
  128. package/dist/browser/browser-tools.d.ts +86 -0
  129. package/dist/browser/browser-tools.d.ts.map +1 -0
  130. package/dist/browser/browser-tools.js +329 -0
  131. package/dist/browser/browser-tools.js.map +1 -0
  132. package/dist/browser/camoufox-backend.d.ts +166 -0
  133. package/dist/browser/camoufox-backend.d.ts.map +1 -0
  134. package/dist/browser/camoufox-backend.js +500 -0
  135. package/dist/browser/camoufox-backend.js.map +1 -0
  136. package/dist/browser/chrome-bridge.d.ts +183 -0
  137. package/dist/browser/chrome-bridge.d.ts.map +1 -0
  138. package/dist/browser/chrome-bridge.js +607 -0
  139. package/dist/browser/chrome-bridge.js.map +1 -0
  140. package/dist/browser/tab-registry.d.ts +103 -0
  141. package/dist/browser/tab-registry.d.ts.map +1 -0
  142. package/dist/browser/tab-registry.js +191 -0
  143. package/dist/browser/tab-registry.js.map +1 -0
  144. package/dist/build/auth-provisioner.d.ts +55 -0
  145. package/dist/build/auth-provisioner.d.ts.map +1 -0
  146. package/dist/build/auth-provisioner.js +207 -0
  147. package/dist/build/auth-provisioner.js.map +1 -0
  148. package/dist/build/db-provisioner.d.ts +63 -0
  149. package/dist/build/db-provisioner.d.ts.map +1 -0
  150. package/dist/build/db-provisioner.js +254 -0
  151. package/dist/build/db-provisioner.js.map +1 -0
  152. package/dist/build/deploy-adapter.d.ts +72 -0
  153. package/dist/build/deploy-adapter.d.ts.map +1 -0
  154. package/dist/build/deploy-adapter.js +273 -0
  155. package/dist/build/deploy-adapter.js.map +1 -0
  156. package/dist/build/deploy-targets/coolify.d.ts +148 -0
  157. package/dist/build/deploy-targets/coolify.d.ts.map +1 -0
  158. package/dist/build/deploy-targets/coolify.js +339 -0
  159. package/dist/build/deploy-targets/coolify.js.map +1 -0
  160. package/dist/build/deploy-targets/dokploy.d.ts +139 -0
  161. package/dist/build/deploy-targets/dokploy.d.ts.map +1 -0
  162. package/dist/build/deploy-targets/dokploy.js +339 -0
  163. package/dist/build/deploy-targets/dokploy.js.map +1 -0
  164. package/dist/build/scaffold-pack-materializer.d.ts +108 -0
  165. package/dist/build/scaffold-pack-materializer.d.ts.map +1 -0
  166. package/dist/build/scaffold-pack-materializer.js +235 -0
  167. package/dist/build/scaffold-pack-materializer.js.map +1 -0
  168. package/dist/build/scaffold-registry.d.ts +103 -0
  169. package/dist/build/scaffold-registry.d.ts.map +1 -0
  170. package/dist/build/scaffold-registry.js +279 -0
  171. package/dist/build/scaffold-registry.js.map +1 -0
  172. package/dist/channels/adapter.d.ts +94 -0
  173. package/dist/channels/adapter.d.ts.map +1 -0
  174. package/dist/channels/adapter.js +94 -0
  175. package/dist/channels/adapter.js.map +1 -0
  176. package/dist/channels/auto-detect.d.ts +165 -0
  177. package/dist/channels/auto-detect.d.ts.map +1 -0
  178. package/dist/channels/auto-detect.js +869 -0
  179. package/dist/channels/auto-detect.js.map +1 -0
  180. package/dist/channels/channel-types.d.ts +16 -0
  181. package/dist/channels/channel-types.d.ts.map +1 -0
  182. package/dist/channels/channel-types.js +15 -0
  183. package/dist/channels/channel-types.js.map +1 -0
  184. package/dist/channels/dingtalk.d.ts +65 -0
  185. package/dist/channels/dingtalk.d.ts.map +1 -0
  186. package/dist/channels/dingtalk.js +158 -0
  187. package/dist/channels/dingtalk.js.map +1 -0
  188. package/dist/channels/discord.d.ts +58 -0
  189. package/dist/channels/discord.d.ts.map +1 -0
  190. package/dist/channels/discord.js +257 -0
  191. package/dist/channels/discord.js.map +1 -0
  192. package/dist/channels/dispatch.d.ts +109 -0
  193. package/dist/channels/dispatch.d.ts.map +1 -0
  194. package/dist/channels/dispatch.js +266 -0
  195. package/dist/channels/dispatch.js.map +1 -0
  196. package/dist/channels/email.d.ts +42 -0
  197. package/dist/channels/email.d.ts.map +1 -0
  198. package/dist/channels/email.js +166 -0
  199. package/dist/channels/email.js.map +1 -0
  200. package/dist/channels/fan-out.d.ts +112 -0
  201. package/dist/channels/fan-out.d.ts.map +1 -0
  202. package/dist/channels/fan-out.js +202 -0
  203. package/dist/channels/fan-out.js.map +1 -0
  204. package/dist/channels/feishu.d.ts +85 -0
  205. package/dist/channels/feishu.d.ts.map +1 -0
  206. package/dist/channels/feishu.js +215 -0
  207. package/dist/channels/feishu.js.map +1 -0
  208. package/dist/channels/gateway.d.ts +207 -0
  209. package/dist/channels/gateway.d.ts.map +1 -0
  210. package/dist/channels/gateway.js +379 -0
  211. package/dist/channels/gateway.js.map +1 -0
  212. package/dist/channels/github-bot.d.ts +94 -0
  213. package/dist/channels/github-bot.d.ts.map +1 -0
  214. package/dist/channels/github-bot.js +318 -0
  215. package/dist/channels/github-bot.js.map +1 -0
  216. package/dist/channels/google-chat.d.ts +40 -0
  217. package/dist/channels/google-chat.d.ts.map +1 -0
  218. package/dist/channels/google-chat.js +84 -0
  219. package/dist/channels/google-chat.js.map +1 -0
  220. package/dist/channels/ide-bridge.d.ts +77 -0
  221. package/dist/channels/ide-bridge.d.ts.map +1 -0
  222. package/dist/channels/ide-bridge.js +316 -0
  223. package/dist/channels/ide-bridge.js.map +1 -0
  224. package/dist/channels/imessage-gateway-adapter.d.ts +25 -0
  225. package/dist/channels/imessage-gateway-adapter.d.ts.map +1 -0
  226. package/dist/channels/imessage-gateway-adapter.js +57 -0
  227. package/dist/channels/imessage-gateway-adapter.js.map +1 -0
  228. package/dist/channels/imessage.d.ts +45 -0
  229. package/dist/channels/imessage.d.ts.map +1 -0
  230. package/dist/channels/imessage.js +140 -0
  231. package/dist/channels/imessage.js.map +1 -0
  232. package/dist/channels/integration.d.ts +16 -0
  233. package/dist/channels/integration.d.ts.map +1 -0
  234. package/dist/channels/integration.js +79 -0
  235. package/dist/channels/integration.js.map +1 -0
  236. package/dist/channels/irc.d.ts +58 -0
  237. package/dist/channels/irc.d.ts.map +1 -0
  238. package/dist/channels/irc.js +188 -0
  239. package/dist/channels/irc.js.map +1 -0
  240. package/dist/channels/line.d.ts +75 -0
  241. package/dist/channels/line.d.ts.map +1 -0
  242. package/dist/channels/line.js +226 -0
  243. package/dist/channels/line.js.map +1 -0
  244. package/dist/channels/mastodon.d.ts +82 -0
  245. package/dist/channels/mastodon.d.ts.map +1 -0
  246. package/dist/channels/mastodon.js +217 -0
  247. package/dist/channels/mastodon.js.map +1 -0
  248. package/dist/channels/matrix.d.ts +36 -0
  249. package/dist/channels/matrix.d.ts.map +1 -0
  250. package/dist/channels/matrix.js +161 -0
  251. package/dist/channels/matrix.js.map +1 -0
  252. package/dist/channels/push-inversion.d.ts +63 -0
  253. package/dist/channels/push-inversion.d.ts.map +1 -0
  254. package/dist/channels/push-inversion.js +167 -0
  255. package/dist/channels/push-inversion.js.map +1 -0
  256. package/dist/channels/route-policies.d.ts +144 -0
  257. package/dist/channels/route-policies.d.ts.map +1 -0
  258. package/dist/channels/route-policies.js +374 -0
  259. package/dist/channels/route-policies.js.map +1 -0
  260. package/dist/channels/signal.d.ts +25 -0
  261. package/dist/channels/signal.d.ts.map +1 -0
  262. package/dist/channels/signal.js +109 -0
  263. package/dist/channels/signal.js.map +1 -0
  264. package/dist/channels/slack.d.ts +52 -0
  265. package/dist/channels/slack.d.ts.map +1 -0
  266. package/dist/channels/slack.js +194 -0
  267. package/dist/channels/slack.js.map +1 -0
  268. package/dist/channels/sms.d.ts +63 -0
  269. package/dist/channels/sms.d.ts.map +1 -0
  270. package/dist/channels/sms.js +151 -0
  271. package/dist/channels/sms.js.map +1 -0
  272. package/dist/channels/teams.d.ts +120 -0
  273. package/dist/channels/teams.d.ts.map +1 -0
  274. package/dist/channels/teams.js +263 -0
  275. package/dist/channels/teams.js.map +1 -0
  276. package/dist/channels/telegram.d.ts +55 -0
  277. package/dist/channels/telegram.d.ts.map +1 -0
  278. package/dist/channels/telegram.js +187 -0
  279. package/dist/channels/telegram.js.map +1 -0
  280. package/dist/channels/terminal-mention.d.ts +43 -0
  281. package/dist/channels/terminal-mention.d.ts.map +1 -0
  282. package/dist/channels/terminal-mention.js +86 -0
  283. package/dist/channels/terminal-mention.js.map +1 -0
  284. package/dist/channels/unified-dispatch.d.ts +190 -0
  285. package/dist/channels/unified-dispatch.d.ts.map +1 -0
  286. package/dist/channels/unified-dispatch.js +554 -0
  287. package/dist/channels/unified-dispatch.js.map +1 -0
  288. package/dist/channels/viber.d.ts +72 -0
  289. package/dist/channels/viber.d.ts.map +1 -0
  290. package/dist/channels/viber.js +185 -0
  291. package/dist/channels/viber.js.map +1 -0
  292. package/dist/channels/webchat.d.ts +44 -0
  293. package/dist/channels/webchat.d.ts.map +1 -0
  294. package/dist/channels/webchat.js +218 -0
  295. package/dist/channels/webchat.js.map +1 -0
  296. package/dist/channels/webhook-router.d.ts +155 -0
  297. package/dist/channels/webhook-router.d.ts.map +1 -0
  298. package/dist/channels/webhook-router.js +411 -0
  299. package/dist/channels/webhook-router.js.map +1 -0
  300. package/dist/channels/webhook.d.ts +28 -0
  301. package/dist/channels/webhook.d.ts.map +1 -0
  302. package/dist/channels/webhook.js +129 -0
  303. package/dist/channels/webhook.js.map +1 -0
  304. package/dist/channels/wechat.d.ts +68 -0
  305. package/dist/channels/wechat.d.ts.map +1 -0
  306. package/dist/channels/wechat.js +196 -0
  307. package/dist/channels/wechat.js.map +1 -0
  308. package/dist/channels/whatsapp.d.ts +74 -0
  309. package/dist/channels/whatsapp.d.ts.map +1 -0
  310. package/dist/channels/whatsapp.js +268 -0
  311. package/dist/channels/whatsapp.js.map +1 -0
  312. package/dist/claude/agents/definitions.d.ts +79 -0
  313. package/dist/claude/agents/definitions.d.ts.map +1 -0
  314. package/dist/claude/agents/definitions.js +196 -0
  315. package/dist/claude/agents/definitions.js.map +1 -0
  316. package/dist/claude/agents/index.d.ts +6 -0
  317. package/dist/claude/agents/index.d.ts.map +1 -0
  318. package/dist/claude/agents/index.js +5 -0
  319. package/dist/claude/agents/index.js.map +1 -0
  320. package/dist/claude/bridge-deps.d.ts +47 -0
  321. package/dist/claude/bridge-deps.d.ts.map +1 -0
  322. package/dist/claude/bridge-deps.js +251 -0
  323. package/dist/claude/bridge-deps.js.map +1 -0
  324. package/dist/claude/bridge.d.ts +65 -0
  325. package/dist/claude/bridge.d.ts.map +1 -0
  326. package/dist/claude/bridge.js +110 -0
  327. package/dist/claude/bridge.js.map +1 -0
  328. package/dist/claude/channels/index.d.ts +6 -0
  329. package/dist/claude/channels/index.d.ts.map +1 -0
  330. package/dist/claude/channels/index.js +5 -0
  331. package/dist/claude/channels/index.js.map +1 -0
  332. package/dist/claude/channels/wotann-channel.d.ts +103 -0
  333. package/dist/claude/channels/wotann-channel.d.ts.map +1 -0
  334. package/dist/claude/channels/wotann-channel.js +224 -0
  335. package/dist/claude/channels/wotann-channel.js.map +1 -0
  336. package/dist/claude/hardening/error-handler.d.ts +52 -0
  337. package/dist/claude/hardening/error-handler.d.ts.map +1 -0
  338. package/dist/claude/hardening/error-handler.js +158 -0
  339. package/dist/claude/hardening/error-handler.js.map +1 -0
  340. package/dist/claude/hardening/feature-flag.d.ts +36 -0
  341. package/dist/claude/hardening/feature-flag.d.ts.map +1 -0
  342. package/dist/claude/hardening/feature-flag.js +70 -0
  343. package/dist/claude/hardening/feature-flag.js.map +1 -0
  344. package/dist/claude/hardening/index.d.ts +8 -0
  345. package/dist/claude/hardening/index.d.ts.map +1 -0
  346. package/dist/claude/hardening/index.js +6 -0
  347. package/dist/claude/hardening/index.js.map +1 -0
  348. package/dist/claude/hardening/telemetry.d.ts +64 -0
  349. package/dist/claude/hardening/telemetry.d.ts.map +1 -0
  350. package/dist/claude/hardening/telemetry.js +129 -0
  351. package/dist/claude/hardening/telemetry.js.map +1 -0
  352. package/dist/claude/hooks/config-builder.d.ts +37 -0
  353. package/dist/claude/hooks/config-builder.d.ts.map +1 -0
  354. package/dist/claude/hooks/config-builder.js +55 -0
  355. package/dist/claude/hooks/config-builder.js.map +1 -0
  356. package/dist/claude/hooks/index.d.ts +19 -0
  357. package/dist/claude/hooks/index.d.ts.map +1 -0
  358. package/dist/claude/hooks/index.js +17 -0
  359. package/dist/claude/hooks/index.js.map +1 -0
  360. package/dist/claude/hooks/post-tool-use.d.ts +16 -0
  361. package/dist/claude/hooks/post-tool-use.d.ts.map +1 -0
  362. package/dist/claude/hooks/post-tool-use.js +91 -0
  363. package/dist/claude/hooks/post-tool-use.js.map +1 -0
  364. package/dist/claude/hooks/pre-compact.d.ts +14 -0
  365. package/dist/claude/hooks/pre-compact.d.ts.map +1 -0
  366. package/dist/claude/hooks/pre-compact.js +30 -0
  367. package/dist/claude/hooks/pre-compact.js.map +1 -0
  368. package/dist/claude/hooks/pre-tool-use.d.ts +24 -0
  369. package/dist/claude/hooks/pre-tool-use.d.ts.map +1 -0
  370. package/dist/claude/hooks/pre-tool-use.js +120 -0
  371. package/dist/claude/hooks/pre-tool-use.js.map +1 -0
  372. package/dist/claude/hooks/server.d.ts +67 -0
  373. package/dist/claude/hooks/server.d.ts.map +1 -0
  374. package/dist/claude/hooks/server.js +396 -0
  375. package/dist/claude/hooks/server.js.map +1 -0
  376. package/dist/claude/hooks/session-start.d.ts +20 -0
  377. package/dist/claude/hooks/session-start.d.ts.map +1 -0
  378. package/dist/claude/hooks/session-start.js +55 -0
  379. package/dist/claude/hooks/session-start.js.map +1 -0
  380. package/dist/claude/hooks/stop.d.ts +19 -0
  381. package/dist/claude/hooks/stop.d.ts.map +1 -0
  382. package/dist/claude/hooks/stop.js +57 -0
  383. package/dist/claude/hooks/stop.js.map +1 -0
  384. package/dist/claude/hooks/user-prompt-submit.d.ts +20 -0
  385. package/dist/claude/hooks/user-prompt-submit.d.ts.map +1 -0
  386. package/dist/claude/hooks/user-prompt-submit.js +59 -0
  387. package/dist/claude/hooks/user-prompt-submit.js.map +1 -0
  388. package/dist/claude/index.d.ts +30 -0
  389. package/dist/claude/index.d.ts.map +1 -0
  390. package/dist/claude/index.js +27 -0
  391. package/dist/claude/index.js.map +1 -0
  392. package/dist/claude/types.d.ts +206 -0
  393. package/dist/claude/types.d.ts.map +1 -0
  394. package/dist/claude/types.js +27 -0
  395. package/dist/claude/types.js.map +1 -0
  396. package/dist/cli/audit.d.ts +17 -0
  397. package/dist/cli/audit.d.ts.map +1 -0
  398. package/dist/cli/audit.js +54 -0
  399. package/dist/cli/audit.js.map +1 -0
  400. package/dist/cli/autofix-pr.d.ts +40 -0
  401. package/dist/cli/autofix-pr.d.ts.map +1 -0
  402. package/dist/cli/autofix-pr.js +199 -0
  403. package/dist/cli/autofix-pr.js.map +1 -0
  404. package/dist/cli/away-summary.d.ts +62 -0
  405. package/dist/cli/away-summary.d.ts.map +1 -0
  406. package/dist/cli/away-summary.js +141 -0
  407. package/dist/cli/away-summary.js.map +1 -0
  408. package/dist/cli/ci-runner.d.ts +52 -0
  409. package/dist/cli/ci-runner.d.ts.map +1 -0
  410. package/dist/cli/ci-runner.js +143 -0
  411. package/dist/cli/ci-runner.js.map +1 -0
  412. package/dist/cli/cli-detection.d.ts +41 -0
  413. package/dist/cli/cli-detection.d.ts.map +1 -0
  414. package/dist/cli/cli-detection.js +148 -0
  415. package/dist/cli/cli-detection.js.map +1 -0
  416. package/dist/cli/commands/acp-register.d.ts +73 -0
  417. package/dist/cli/commands/acp-register.d.ts.map +1 -0
  418. package/dist/cli/commands/acp-register.js +134 -0
  419. package/dist/cli/commands/acp-register.js.map +1 -0
  420. package/dist/cli/commands/best-of-n.d.ts +74 -0
  421. package/dist/cli/commands/best-of-n.d.ts.map +1 -0
  422. package/dist/cli/commands/best-of-n.js +144 -0
  423. package/dist/cli/commands/best-of-n.js.map +1 -0
  424. package/dist/cli/commands/browse.d.ts +46 -0
  425. package/dist/cli/commands/browse.d.ts.map +1 -0
  426. package/dist/cli/commands/browse.js +230 -0
  427. package/dist/cli/commands/browse.js.map +1 -0
  428. package/dist/cli/commands/build.d.ts +92 -0
  429. package/dist/cli/commands/build.d.ts.map +1 -0
  430. package/dist/cli/commands/build.js +238 -0
  431. package/dist/cli/commands/build.js.map +1 -0
  432. package/dist/cli/commands/deploy.d.ts +60 -0
  433. package/dist/cli/commands/deploy.d.ts.map +1 -0
  434. package/dist/cli/commands/deploy.js +107 -0
  435. package/dist/cli/commands/deploy.js.map +1 -0
  436. package/dist/cli/commands/design-apply.d.ts +81 -0
  437. package/dist/cli/commands/design-apply.d.ts.map +1 -0
  438. package/dist/cli/commands/design-apply.js +122 -0
  439. package/dist/cli/commands/design-apply.js.map +1 -0
  440. package/dist/cli/commands/design-export.d.ts +62 -0
  441. package/dist/cli/commands/design-export.d.ts.map +1 -0
  442. package/dist/cli/commands/design-export.js +88 -0
  443. package/dist/cli/commands/design-export.js.map +1 -0
  444. package/dist/cli/commands/design-extract.d.ts +40 -0
  445. package/dist/cli/commands/design-extract.d.ts.map +1 -0
  446. package/dist/cli/commands/design-extract.js +72 -0
  447. package/dist/cli/commands/design-extract.js.map +1 -0
  448. package/dist/cli/commands/design-lint.d.ts +49 -0
  449. package/dist/cli/commands/design-lint.d.ts.map +1 -0
  450. package/dist/cli/commands/design-lint.js +235 -0
  451. package/dist/cli/commands/design-lint.js.map +1 -0
  452. package/dist/cli/commands/design-mode.d.ts +50 -0
  453. package/dist/cli/commands/design-mode.d.ts.map +1 -0
  454. package/dist/cli/commands/design-mode.js +311 -0
  455. package/dist/cli/commands/design-mode.js.map +1 -0
  456. package/dist/cli/commands/design-preview.d.ts +69 -0
  457. package/dist/cli/commands/design-preview.d.ts.map +1 -0
  458. package/dist/cli/commands/design-preview.js +171 -0
  459. package/dist/cli/commands/design-preview.js.map +1 -0
  460. package/dist/cli/commands/design-verify.d.ts +59 -0
  461. package/dist/cli/commands/design-verify.d.ts.map +1 -0
  462. package/dist/cli/commands/design-verify.js +74 -0
  463. package/dist/cli/commands/design-verify.js.map +1 -0
  464. package/dist/cli/commands/exploit.d.ts +126 -0
  465. package/dist/cli/commands/exploit.d.ts.map +1 -0
  466. package/dist/cli/commands/exploit.js +298 -0
  467. package/dist/cli/commands/exploit.js.map +1 -0
  468. package/dist/cli/commands/grep.d.ts +92 -0
  469. package/dist/cli/commands/grep.d.ts.map +1 -0
  470. package/dist/cli/commands/grep.js +221 -0
  471. package/dist/cli/commands/grep.js.map +1 -0
  472. package/dist/cli/commands/intent.d.ts +43 -0
  473. package/dist/cli/commands/intent.d.ts.map +1 -0
  474. package/dist/cli/commands/intent.js +282 -0
  475. package/dist/cli/commands/intent.js.map +1 -0
  476. package/dist/cli/commands/magic.d.ts +41 -0
  477. package/dist/cli/commands/magic.d.ts.map +1 -0
  478. package/dist/cli/commands/magic.js +67 -0
  479. package/dist/cli/commands/magic.js.map +1 -0
  480. package/dist/cli/commands/multitask.d.ts +62 -0
  481. package/dist/cli/commands/multitask.d.ts.map +1 -0
  482. package/dist/cli/commands/multitask.js +111 -0
  483. package/dist/cli/commands/multitask.js.map +1 -0
  484. package/dist/cli/commands/onboard.d.ts +44 -0
  485. package/dist/cli/commands/onboard.d.ts.map +1 -0
  486. package/dist/cli/commands/onboard.js +112 -0
  487. package/dist/cli/commands/onboard.js.map +1 -0
  488. package/dist/cli/commands/review.d.ts +139 -0
  489. package/dist/cli/commands/review.d.ts.map +1 -0
  490. package/dist/cli/commands/review.js +364 -0
  491. package/dist/cli/commands/review.js.map +1 -0
  492. package/dist/cli/commands/rules.d.ts +140 -0
  493. package/dist/cli/commands/rules.d.ts.map +1 -0
  494. package/dist/cli/commands/rules.js +251 -0
  495. package/dist/cli/commands/rules.js.map +1 -0
  496. package/dist/cli/commands/sandbox.d.ts +64 -0
  497. package/dist/cli/commands/sandbox.d.ts.map +1 -0
  498. package/dist/cli/commands/sandbox.js +69 -0
  499. package/dist/cli/commands/sandbox.js.map +1 -0
  500. package/dist/cli/commands/sop.d.ts +70 -0
  501. package/dist/cli/commands/sop.d.ts.map +1 -0
  502. package/dist/cli/commands/sop.js +152 -0
  503. package/dist/cli/commands/sop.js.map +1 -0
  504. package/dist/cli/commands/stuck.d.ts +51 -0
  505. package/dist/cli/commands/stuck.d.ts.map +1 -0
  506. package/dist/cli/commands/stuck.js +249 -0
  507. package/dist/cli/commands/stuck.js.map +1 -0
  508. package/dist/cli/commands/worktree.d.ts +49 -0
  509. package/dist/cli/commands/worktree.d.ts.map +1 -0
  510. package/dist/cli/commands/worktree.js +153 -0
  511. package/dist/cli/commands/worktree.js.map +1 -0
  512. package/dist/cli/commands.d.ts +30 -0
  513. package/dist/cli/commands.d.ts.map +1 -0
  514. package/dist/cli/commands.js +446 -0
  515. package/dist/cli/commands.js.map +1 -0
  516. package/dist/cli/components/AuthModeBanner.d.ts +43 -0
  517. package/dist/cli/components/AuthModeBanner.d.ts.map +1 -0
  518. package/dist/cli/components/AuthModeBanner.js +25 -0
  519. package/dist/cli/components/AuthModeBanner.js.map +1 -0
  520. package/dist/cli/debug-share.d.ts +94 -0
  521. package/dist/cli/debug-share.d.ts.map +1 -0
  522. package/dist/cli/debug-share.js +227 -0
  523. package/dist/cli/debug-share.js.map +1 -0
  524. package/dist/cli/first-run-runner-factory.d.ts +99 -0
  525. package/dist/cli/first-run-runner-factory.d.ts.map +1 -0
  526. package/dist/cli/first-run-runner-factory.js +188 -0
  527. package/dist/cli/first-run-runner-factory.js.map +1 -0
  528. package/dist/cli/first-run-success.d.ts +123 -0
  529. package/dist/cli/first-run-success.d.ts.map +1 -0
  530. package/dist/cli/first-run-success.js +124 -0
  531. package/dist/cli/first-run-success.js.map +1 -0
  532. package/dist/cli/fork.d.ts +80 -0
  533. package/dist/cli/fork.d.ts.map +1 -0
  534. package/dist/cli/fork.js +127 -0
  535. package/dist/cli/fork.js.map +1 -0
  536. package/dist/cli/hooks-browser.d.ts +142 -0
  537. package/dist/cli/hooks-browser.d.ts.map +1 -0
  538. package/dist/cli/hooks-browser.js +238 -0
  539. package/dist/cli/hooks-browser.js.map +1 -0
  540. package/dist/cli/local-status.d.ts +11 -0
  541. package/dist/cli/local-status.d.ts.map +1 -0
  542. package/dist/cli/local-status.js +56 -0
  543. package/dist/cli/local-status.js.map +1 -0
  544. package/dist/cli/loop-command.d.ts +46 -0
  545. package/dist/cli/loop-command.d.ts.map +1 -0
  546. package/dist/cli/loop-command.js +123 -0
  547. package/dist/cli/loop-command.js.map +1 -0
  548. package/dist/cli/onboarding-screens/done-screen.d.ts +23 -0
  549. package/dist/cli/onboarding-screens/done-screen.d.ts.map +1 -0
  550. package/dist/cli/onboarding-screens/done-screen.js +10 -0
  551. package/dist/cli/onboarding-screens/done-screen.js.map +1 -0
  552. package/dist/cli/onboarding-screens/first-run-screen.d.ts +27 -0
  553. package/dist/cli/onboarding-screens/first-run-screen.d.ts.map +1 -0
  554. package/dist/cli/onboarding-screens/first-run-screen.js +62 -0
  555. package/dist/cli/onboarding-screens/first-run-screen.js.map +1 -0
  556. package/dist/cli/onboarding-screens.d.ts +227 -0
  557. package/dist/cli/onboarding-screens.d.ts.map +1 -0
  558. package/dist/cli/onboarding-screens.js +467 -0
  559. package/dist/cli/onboarding-screens.js.map +1 -0
  560. package/dist/cli/onboarding.d.ts +34 -0
  561. package/dist/cli/onboarding.d.ts.map +1 -0
  562. package/dist/cli/onboarding.js +150 -0
  563. package/dist/cli/onboarding.js.map +1 -0
  564. package/dist/cli/orphan-wires/anthropic-write-cmd.d.ts +21 -0
  565. package/dist/cli/orphan-wires/anthropic-write-cmd.d.ts.map +1 -0
  566. package/dist/cli/orphan-wires/anthropic-write-cmd.js +83 -0
  567. package/dist/cli/orphan-wires/anthropic-write-cmd.js.map +1 -0
  568. package/dist/cli/orphan-wires/archon-cmd.d.ts +11 -0
  569. package/dist/cli/orphan-wires/archon-cmd.d.ts.map +1 -0
  570. package/dist/cli/orphan-wires/archon-cmd.js +74 -0
  571. package/dist/cli/orphan-wires/archon-cmd.js.map +1 -0
  572. package/dist/cli/orphan-wires/cli-anything-cmd.d.ts +17 -0
  573. package/dist/cli/orphan-wires/cli-anything-cmd.d.ts.map +1 -0
  574. package/dist/cli/orphan-wires/cli-anything-cmd.js +39 -0
  575. package/dist/cli/orphan-wires/cli-anything-cmd.js.map +1 -0
  576. package/dist/cli/orphan-wires/dev-search-cmd.d.ts +10 -0
  577. package/dist/cli/orphan-wires/dev-search-cmd.d.ts.map +1 -0
  578. package/dist/cli/orphan-wires/dev-search-cmd.js +28 -0
  579. package/dist/cli/orphan-wires/dev-search-cmd.js.map +1 -0
  580. package/dist/cli/orphan-wires/effort-mode-cmd.d.ts +8 -0
  581. package/dist/cli/orphan-wires/effort-mode-cmd.d.ts.map +1 -0
  582. package/dist/cli/orphan-wires/effort-mode-cmd.js +40 -0
  583. package/dist/cli/orphan-wires/effort-mode-cmd.js.map +1 -0
  584. package/dist/cli/orphan-wires/flow-cmd.d.ts +9 -0
  585. package/dist/cli/orphan-wires/flow-cmd.d.ts.map +1 -0
  586. package/dist/cli/orphan-wires/flow-cmd.js +64 -0
  587. package/dist/cli/orphan-wires/flow-cmd.js.map +1 -0
  588. package/dist/cli/orphan-wires/handoff-cmd.d.ts +11 -0
  589. package/dist/cli/orphan-wires/handoff-cmd.d.ts.map +1 -0
  590. package/dist/cli/orphan-wires/handoff-cmd.js +48 -0
  591. package/dist/cli/orphan-wires/handoff-cmd.js.map +1 -0
  592. package/dist/cli/orphan-wires/index.d.ts +20 -0
  593. package/dist/cli/orphan-wires/index.d.ts.map +1 -0
  594. package/dist/cli/orphan-wires/index.js +61 -0
  595. package/dist/cli/orphan-wires/index.js.map +1 -0
  596. package/dist/cli/orphan-wires/markitdown-cmd.d.ts +10 -0
  597. package/dist/cli/orphan-wires/markitdown-cmd.d.ts.map +1 -0
  598. package/dist/cli/orphan-wires/markitdown-cmd.js +44 -0
  599. package/dist/cli/orphan-wires/markitdown-cmd.js.map +1 -0
  600. package/dist/cli/orphan-wires/multitask-cmd.d.ts +8 -0
  601. package/dist/cli/orphan-wires/multitask-cmd.d.ts.map +1 -0
  602. package/dist/cli/orphan-wires/multitask-cmd.js +43 -0
  603. package/dist/cli/orphan-wires/multitask-cmd.js.map +1 -0
  604. package/dist/cli/orphan-wires/n8n-template-cmd.d.ts +7 -0
  605. package/dist/cli/orphan-wires/n8n-template-cmd.d.ts.map +1 -0
  606. package/dist/cli/orphan-wires/n8n-template-cmd.js +81 -0
  607. package/dist/cli/orphan-wires/n8n-template-cmd.js.map +1 -0
  608. package/dist/cli/orphan-wires/onboard-cmd.d.ts +9 -0
  609. package/dist/cli/orphan-wires/onboard-cmd.d.ts.map +1 -0
  610. package/dist/cli/orphan-wires/onboard-cmd.js +60 -0
  611. package/dist/cli/orphan-wires/onboard-cmd.js.map +1 -0
  612. package/dist/cli/orphan-wires/outline-cmd.d.ts +8 -0
  613. package/dist/cli/orphan-wires/outline-cmd.d.ts.map +1 -0
  614. package/dist/cli/orphan-wires/outline-cmd.js +47 -0
  615. package/dist/cli/orphan-wires/outline-cmd.js.map +1 -0
  616. package/dist/cli/orphan-wires/private-mode-cmd.d.ts +8 -0
  617. package/dist/cli/orphan-wires/private-mode-cmd.d.ts.map +1 -0
  618. package/dist/cli/orphan-wires/private-mode-cmd.js +51 -0
  619. package/dist/cli/orphan-wires/private-mode-cmd.js.map +1 -0
  620. package/dist/cli/orphan-wires/prompt-corpus-cmd.d.ts +7 -0
  621. package/dist/cli/orphan-wires/prompt-corpus-cmd.d.ts.map +1 -0
  622. package/dist/cli/orphan-wires/prompt-corpus-cmd.js +32 -0
  623. package/dist/cli/orphan-wires/prompt-corpus-cmd.js.map +1 -0
  624. package/dist/cli/orphan-wires/prompt-files-cmd.d.ts +7 -0
  625. package/dist/cli/orphan-wires/prompt-files-cmd.d.ts.map +1 -0
  626. package/dist/cli/orphan-wires/prompt-files-cmd.js +58 -0
  627. package/dist/cli/orphan-wires/prompt-files-cmd.js.map +1 -0
  628. package/dist/cli/orphan-wires/promptfoo-assert-cmd.d.ts +19 -0
  629. package/dist/cli/orphan-wires/promptfoo-assert-cmd.d.ts.map +1 -0
  630. package/dist/cli/orphan-wires/promptfoo-assert-cmd.js +81 -0
  631. package/dist/cli/orphan-wires/promptfoo-assert-cmd.js.map +1 -0
  632. package/dist/cli/orphan-wires/proof-of-work-cmd.d.ts +25 -0
  633. package/dist/cli/orphan-wires/proof-of-work-cmd.d.ts.map +1 -0
  634. package/dist/cli/orphan-wires/proof-of-work-cmd.js +132 -0
  635. package/dist/cli/orphan-wires/proof-of-work-cmd.js.map +1 -0
  636. package/dist/cli/orphan-wires/redteam-cmd.d.ts +7 -0
  637. package/dist/cli/orphan-wires/redteam-cmd.d.ts.map +1 -0
  638. package/dist/cli/orphan-wires/redteam-cmd.js +26 -0
  639. package/dist/cli/orphan-wires/redteam-cmd.js.map +1 -0
  640. package/dist/cli/orphan-wires/skill-catalog-cmd.d.ts +22 -0
  641. package/dist/cli/orphan-wires/skill-catalog-cmd.d.ts.map +1 -0
  642. package/dist/cli/orphan-wires/skill-catalog-cmd.js +92 -0
  643. package/dist/cli/orphan-wires/skill-catalog-cmd.js.map +1 -0
  644. package/dist/cli/repl-mode.d.ts +62 -0
  645. package/dist/cli/repl-mode.d.ts.map +1 -0
  646. package/dist/cli/repl-mode.js +178 -0
  647. package/dist/cli/repl-mode.js.map +1 -0
  648. package/dist/cli/replay.d.ts +100 -0
  649. package/dist/cli/replay.d.ts.map +1 -0
  650. package/dist/cli/replay.js +147 -0
  651. package/dist/cli/replay.js.map +1 -0
  652. package/dist/cli/run-onboarding-wizard.d.ts +81 -0
  653. package/dist/cli/run-onboarding-wizard.d.ts.map +1 -0
  654. package/dist/cli/run-onboarding-wizard.js +182 -0
  655. package/dist/cli/run-onboarding-wizard.js.map +1 -0
  656. package/dist/cli/runtime-query.d.ts +24 -0
  657. package/dist/cli/runtime-query.d.ts.map +1 -0
  658. package/dist/cli/runtime-query.js +49 -0
  659. package/dist/cli/runtime-query.js.map +1 -0
  660. package/dist/cli/safety/read-only-gate.d.ts +86 -0
  661. package/dist/cli/safety/read-only-gate.d.ts.map +1 -0
  662. package/dist/cli/safety/read-only-gate.js +115 -0
  663. package/dist/cli/safety/read-only-gate.js.map +1 -0
  664. package/dist/cli/self-improve.d.ts +41 -0
  665. package/dist/cli/self-improve.d.ts.map +1 -0
  666. package/dist/cli/self-improve.js +140 -0
  667. package/dist/cli/self-improve.js.map +1 -0
  668. package/dist/cli/session-recap.d.ts +109 -0
  669. package/dist/cli/session-recap.d.ts.map +1 -0
  670. package/dist/cli/session-recap.js +176 -0
  671. package/dist/cli/session-recap.js.map +1 -0
  672. package/dist/cli/team-onboarding.d.ts +51 -0
  673. package/dist/cli/team-onboarding.d.ts.map +1 -0
  674. package/dist/cli/team-onboarding.js +326 -0
  675. package/dist/cli/team-onboarding.js.map +1 -0
  676. package/dist/cli/test-provider.d.ts +6 -0
  677. package/dist/cli/test-provider.d.ts.map +1 -0
  678. package/dist/cli/test-provider.js +100 -0
  679. package/dist/cli/test-provider.js.map +1 -0
  680. package/dist/cli/thin-client.d.ts +86 -0
  681. package/dist/cli/thin-client.d.ts.map +1 -0
  682. package/dist/cli/thin-client.js +237 -0
  683. package/dist/cli/thin-client.js.map +1 -0
  684. package/dist/cli/tricks/completion-checklist.d.ts +58 -0
  685. package/dist/cli/tricks/completion-checklist.d.ts.map +1 -0
  686. package/dist/cli/tricks/completion-checklist.js +121 -0
  687. package/dist/cli/tricks/completion-checklist.js.map +1 -0
  688. package/dist/cli/tricks/image-read.d.ts +45 -0
  689. package/dist/cli/tricks/image-read.d.ts.map +1 -0
  690. package/dist/cli/tricks/image-read.js +74 -0
  691. package/dist/cli/tricks/image-read.js.map +1 -0
  692. package/dist/cli/tricks/terminal-run.d.ts +73 -0
  693. package/dist/cli/tricks/terminal-run.d.ts.map +1 -0
  694. package/dist/cli/tricks/terminal-run.js +91 -0
  695. package/dist/cli/tricks/terminal-run.js.map +1 -0
  696. package/dist/cli/tricks/tmux-pull.d.ts +67 -0
  697. package/dist/cli/tricks/tmux-pull.d.ts.map +1 -0
  698. package/dist/cli/tricks/tmux-pull.js +77 -0
  699. package/dist/cli/tricks/tmux-pull.js.map +1 -0
  700. package/dist/cli/voice-cmds.d.ts +37 -0
  701. package/dist/cli/voice-cmds.d.ts.map +1 -0
  702. package/dist/cli/voice-cmds.js +83 -0
  703. package/dist/cli/voice-cmds.js.map +1 -0
  704. package/dist/cli/voice.d.ts +12 -0
  705. package/dist/cli/voice.d.ts.map +1 -0
  706. package/dist/cli/voice.js +15 -0
  707. package/dist/cli/voice.js.map +1 -0
  708. package/dist/cli/watch-mode.d.ts +64 -0
  709. package/dist/cli/watch-mode.d.ts.map +1 -0
  710. package/dist/cli/watch-mode.js +214 -0
  711. package/dist/cli/watch-mode.js.map +1 -0
  712. package/dist/computer-use/action-repertoire.d.ts +117 -0
  713. package/dist/computer-use/action-repertoire.d.ts.map +1 -0
  714. package/dist/computer-use/action-repertoire.js +214 -0
  715. package/dist/computer-use/action-repertoire.js.map +1 -0
  716. package/dist/computer-use/action-replay.d.ts +103 -0
  717. package/dist/computer-use/action-replay.d.ts.map +1 -0
  718. package/dist/computer-use/action-replay.js +160 -0
  719. package/dist/computer-use/action-replay.js.map +1 -0
  720. package/dist/computer-use/computer-agent.d.ts +124 -0
  721. package/dist/computer-use/computer-agent.d.ts.map +1 -0
  722. package/dist/computer-use/computer-agent.js +378 -0
  723. package/dist/computer-use/computer-agent.js.map +1 -0
  724. package/dist/computer-use/confidence-gate.d.ts +80 -0
  725. package/dist/computer-use/confidence-gate.d.ts.map +1 -0
  726. package/dist/computer-use/confidence-gate.js +111 -0
  727. package/dist/computer-use/confidence-gate.js.map +1 -0
  728. package/dist/computer-use/cursor-sprite.d.ts +103 -0
  729. package/dist/computer-use/cursor-sprite.d.ts.map +1 -0
  730. package/dist/computer-use/cursor-sprite.js +193 -0
  731. package/dist/computer-use/cursor-sprite.js.map +1 -0
  732. package/dist/computer-use/non-stealing-input.d.ts +79 -0
  733. package/dist/computer-use/non-stealing-input.d.ts.map +1 -0
  734. package/dist/computer-use/non-stealing-input.js +133 -0
  735. package/dist/computer-use/non-stealing-input.js.map +1 -0
  736. package/dist/computer-use/perception-adapter.d.ts +56 -0
  737. package/dist/computer-use/perception-adapter.d.ts.map +1 -0
  738. package/dist/computer-use/perception-adapter.js +216 -0
  739. package/dist/computer-use/perception-adapter.js.map +1 -0
  740. package/dist/computer-use/perception-engine.d.ts +203 -0
  741. package/dist/computer-use/perception-engine.d.ts.map +1 -0
  742. package/dist/computer-use/perception-engine.js +886 -0
  743. package/dist/computer-use/perception-engine.js.map +1 -0
  744. package/dist/computer-use/persistent-task-queue.d.ts +85 -0
  745. package/dist/computer-use/persistent-task-queue.d.ts.map +1 -0
  746. package/dist/computer-use/persistent-task-queue.js +182 -0
  747. package/dist/computer-use/persistent-task-queue.js.map +1 -0
  748. package/dist/computer-use/platform-bindings.d.ts +115 -0
  749. package/dist/computer-use/platform-bindings.d.ts.map +1 -0
  750. package/dist/computer-use/platform-bindings.js +783 -0
  751. package/dist/computer-use/platform-bindings.js.map +1 -0
  752. package/dist/computer-use/session-scoped-perception.d.ts +111 -0
  753. package/dist/computer-use/session-scoped-perception.d.ts.map +1 -0
  754. package/dist/computer-use/session-scoped-perception.js +262 -0
  755. package/dist/computer-use/session-scoped-perception.js.map +1 -0
  756. package/dist/computer-use/types.d.ts +157 -0
  757. package/dist/computer-use/types.d.ts.map +1 -0
  758. package/dist/computer-use/types.js +5 -0
  759. package/dist/computer-use/types.js.map +1 -0
  760. package/dist/computer-use/virtual-cursor-pool.d.ts +98 -0
  761. package/dist/computer-use/virtual-cursor-pool.d.ts.map +1 -0
  762. package/dist/computer-use/virtual-cursor-pool.js +231 -0
  763. package/dist/computer-use/virtual-cursor-pool.js.map +1 -0
  764. package/dist/computer-use/vm-isolation.d.ts +90 -0
  765. package/dist/computer-use/vm-isolation.d.ts.map +1 -0
  766. package/dist/computer-use/vm-isolation.js +140 -0
  767. package/dist/computer-use/vm-isolation.js.map +1 -0
  768. package/dist/connectors/confluence.d.ts +32 -0
  769. package/dist/connectors/confluence.d.ts.map +1 -0
  770. package/dist/connectors/confluence.js +132 -0
  771. package/dist/connectors/confluence.js.map +1 -0
  772. package/dist/connectors/connector-registry.d.ts +115 -0
  773. package/dist/connectors/connector-registry.d.ts.map +1 -0
  774. package/dist/connectors/connector-registry.js +166 -0
  775. package/dist/connectors/connector-registry.js.map +1 -0
  776. package/dist/connectors/connector-tools.d.ts +229 -0
  777. package/dist/connectors/connector-tools.d.ts.map +1 -0
  778. package/dist/connectors/connector-tools.js +778 -0
  779. package/dist/connectors/connector-tools.js.map +1 -0
  780. package/dist/connectors/connector-webhook-server.d.ts +138 -0
  781. package/dist/connectors/connector-webhook-server.d.ts.map +1 -0
  782. package/dist/connectors/connector-webhook-server.js +374 -0
  783. package/dist/connectors/connector-webhook-server.js.map +1 -0
  784. package/dist/connectors/connector-writes.d.ts +253 -0
  785. package/dist/connectors/connector-writes.d.ts.map +1 -0
  786. package/dist/connectors/connector-writes.js +1044 -0
  787. package/dist/connectors/connector-writes.js.map +1 -0
  788. package/dist/connectors/google-drive.d.ts +35 -0
  789. package/dist/connectors/google-drive.d.ts.map +1 -0
  790. package/dist/connectors/google-drive.js +222 -0
  791. package/dist/connectors/google-drive.js.map +1 -0
  792. package/dist/connectors/guarded-fetch.d.ts +23 -0
  793. package/dist/connectors/guarded-fetch.d.ts.map +1 -0
  794. package/dist/connectors/guarded-fetch.js +30 -0
  795. package/dist/connectors/guarded-fetch.js.map +1 -0
  796. package/dist/connectors/jira.d.ts +35 -0
  797. package/dist/connectors/jira.d.ts.map +1 -0
  798. package/dist/connectors/jira.js +220 -0
  799. package/dist/connectors/jira.js.map +1 -0
  800. package/dist/connectors/linear.d.ts +32 -0
  801. package/dist/connectors/linear.d.ts.map +1 -0
  802. package/dist/connectors/linear.js +232 -0
  803. package/dist/connectors/linear.js.map +1 -0
  804. package/dist/connectors/notion.d.ts +33 -0
  805. package/dist/connectors/notion.d.ts.map +1 -0
  806. package/dist/connectors/notion.js +244 -0
  807. package/dist/connectors/notion.js.map +1 -0
  808. package/dist/connectors/slack.d.ts +30 -0
  809. package/dist/connectors/slack.d.ts.map +1 -0
  810. package/dist/connectors/slack.js +127 -0
  811. package/dist/connectors/slack.js.map +1 -0
  812. package/dist/context/budget-estimator.d.ts +83 -0
  813. package/dist/context/budget-estimator.d.ts.map +1 -0
  814. package/dist/context/budget-estimator.js +236 -0
  815. package/dist/context/budget-estimator.js.map +1 -0
  816. package/dist/context/compaction.d.ts +64 -0
  817. package/dist/context/compaction.d.ts.map +1 -0
  818. package/dist/context/compaction.js +192 -0
  819. package/dist/context/compaction.js.map +1 -0
  820. package/dist/context/context-replay.d.ts +62 -0
  821. package/dist/context/context-replay.d.ts.map +1 -0
  822. package/dist/context/context-replay.js +220 -0
  823. package/dist/context/context-replay.js.map +1 -0
  824. package/dist/context/context-sharding.d.ts +113 -0
  825. package/dist/context/context-sharding.d.ts.map +1 -0
  826. package/dist/context/context-sharding.js +364 -0
  827. package/dist/context/context-sharding.js.map +1 -0
  828. package/dist/context/importance-compactor.d.ts +74 -0
  829. package/dist/context/importance-compactor.d.ts.map +1 -0
  830. package/dist/context/importance-compactor.js +111 -0
  831. package/dist/context/importance-compactor.js.map +1 -0
  832. package/dist/context/inspector.d.ts +86 -0
  833. package/dist/context/inspector.d.ts.map +1 -0
  834. package/dist/context/inspector.js +170 -0
  835. package/dist/context/inspector.js.map +1 -0
  836. package/dist/context/limits.d.ts +94 -0
  837. package/dist/context/limits.d.ts.map +1 -0
  838. package/dist/context/limits.js +640 -0
  839. package/dist/context/limits.js.map +1 -0
  840. package/dist/context/maximizer.d.ts +138 -0
  841. package/dist/context/maximizer.d.ts.map +1 -0
  842. package/dist/context/maximizer.js +334 -0
  843. package/dist/context/maximizer.js.map +1 -0
  844. package/dist/context/ollama-kv-compression.d.ts +85 -0
  845. package/dist/context/ollama-kv-compression.d.ts.map +1 -0
  846. package/dist/context/ollama-kv-compression.js +263 -0
  847. package/dist/context/ollama-kv-compression.js.map +1 -0
  848. package/dist/context/repo-map.d.ts +38 -0
  849. package/dist/context/repo-map.d.ts.map +1 -0
  850. package/dist/context/repo-map.js +277 -0
  851. package/dist/context/repo-map.js.map +1 -0
  852. package/dist/context/sleep-summarizer.d.ts +77 -0
  853. package/dist/context/sleep-summarizer.d.ts.map +1 -0
  854. package/dist/context/sleep-summarizer.js +161 -0
  855. package/dist/context/sleep-summarizer.js.map +1 -0
  856. package/dist/context/spaces.d.ts +53 -0
  857. package/dist/context/spaces.d.ts.map +1 -0
  858. package/dist/context/spaces.js +92 -0
  859. package/dist/context/spaces.js.map +1 -0
  860. package/dist/context/tiered-loader.d.ts +62 -0
  861. package/dist/context/tiered-loader.d.ts.map +1 -0
  862. package/dist/context/tiered-loader.js +453 -0
  863. package/dist/context/tiered-loader.js.map +1 -0
  864. package/dist/context/tool-arg-truncator.d.ts +69 -0
  865. package/dist/context/tool-arg-truncator.d.ts.map +1 -0
  866. package/dist/context/tool-arg-truncator.js +212 -0
  867. package/dist/context/tool-arg-truncator.js.map +1 -0
  868. package/dist/context/virtual-context.d.ts +89 -0
  869. package/dist/context/virtual-context.d.ts.map +1 -0
  870. package/dist/context/virtual-context.js +289 -0
  871. package/dist/context/virtual-context.js.map +1 -0
  872. package/dist/context/window-intelligence.d.ts +221 -0
  873. package/dist/context/window-intelligence.d.ts.map +1 -0
  874. package/dist/context/window-intelligence.js +485 -0
  875. package/dist/context/window-intelligence.js.map +1 -0
  876. package/dist/core/agent-bridge.d.ts +80 -0
  877. package/dist/core/agent-bridge.d.ts.map +1 -0
  878. package/dist/core/agent-bridge.js +473 -0
  879. package/dist/core/agent-bridge.js.map +1 -0
  880. package/dist/core/agent-profiles.d.ts +65 -0
  881. package/dist/core/agent-profiles.d.ts.map +1 -0
  882. package/dist/core/agent-profiles.js +137 -0
  883. package/dist/core/agent-profiles.js.map +1 -0
  884. package/dist/core/bootstrap-snapshot.d.ts +125 -0
  885. package/dist/core/bootstrap-snapshot.d.ts.map +1 -0
  886. package/dist/core/bootstrap-snapshot.js +513 -0
  887. package/dist/core/bootstrap-snapshot.js.map +1 -0
  888. package/dist/core/config-discovery.d.ts +103 -0
  889. package/dist/core/config-discovery.d.ts.map +1 -0
  890. package/dist/core/config-discovery.js +336 -0
  891. package/dist/core/config-discovery.js.map +1 -0
  892. package/dist/core/config-migration.d.ts +69 -0
  893. package/dist/core/config-migration.d.ts.map +1 -0
  894. package/dist/core/config-migration.js +185 -0
  895. package/dist/core/config-migration.js.map +1 -0
  896. package/dist/core/config.d.ts +22 -0
  897. package/dist/core/config.d.ts.map +1 -0
  898. package/dist/core/config.js +253 -0
  899. package/dist/core/config.js.map +1 -0
  900. package/dist/core/content-cid.d.ts +85 -0
  901. package/dist/core/content-cid.d.ts.map +1 -0
  902. package/dist/core/content-cid.js +135 -0
  903. package/dist/core/content-cid.js.map +1 -0
  904. package/dist/core/conversation-branching.d.ts +93 -0
  905. package/dist/core/conversation-branching.d.ts.map +1 -0
  906. package/dist/core/conversation-branching.js +215 -0
  907. package/dist/core/conversation-branching.js.map +1 -0
  908. package/dist/core/conversation-tree.d.ts +107 -0
  909. package/dist/core/conversation-tree.d.ts.map +1 -0
  910. package/dist/core/conversation-tree.js +211 -0
  911. package/dist/core/conversation-tree.js.map +1 -0
  912. package/dist/core/deep-link.d.ts +50 -0
  913. package/dist/core/deep-link.d.ts.map +1 -0
  914. package/dist/core/deep-link.js +212 -0
  915. package/dist/core/deep-link.js.map +1 -0
  916. package/dist/core/default-provider.d.ts +28 -0
  917. package/dist/core/default-provider.d.ts.map +1 -0
  918. package/dist/core/default-provider.js +90 -0
  919. package/dist/core/default-provider.js.map +1 -0
  920. package/dist/core/effort-mode.d.ts +81 -0
  921. package/dist/core/effort-mode.d.ts.map +1 -0
  922. package/dist/core/effort-mode.js +191 -0
  923. package/dist/core/effort-mode.js.map +1 -0
  924. package/dist/core/execution-modes.d.ts +103 -0
  925. package/dist/core/execution-modes.d.ts.map +1 -0
  926. package/dist/core/execution-modes.js +130 -0
  927. package/dist/core/execution-modes.js.map +1 -0
  928. package/dist/core/handoff.d.ts +184 -0
  929. package/dist/core/handoff.d.ts.map +1 -0
  930. package/dist/core/handoff.js +195 -0
  931. package/dist/core/handoff.js.map +1 -0
  932. package/dist/core/hardware-detect.d.ts +88 -0
  933. package/dist/core/hardware-detect.d.ts.map +1 -0
  934. package/dist/core/hardware-detect.js +182 -0
  935. package/dist/core/hardware-detect.js.map +1 -0
  936. package/dist/core/message-queue.d.ts +68 -0
  937. package/dist/core/message-queue.d.ts.map +1 -0
  938. package/dist/core/message-queue.js +96 -0
  939. package/dist/core/message-queue.js.map +1 -0
  940. package/dist/core/mode-cycling.d.ts +59 -0
  941. package/dist/core/mode-cycling.d.ts.map +1 -0
  942. package/dist/core/mode-cycling.js +259 -0
  943. package/dist/core/mode-cycling.js.map +1 -0
  944. package/dist/core/project-onboarding.d.ts +75 -0
  945. package/dist/core/project-onboarding.d.ts.map +1 -0
  946. package/dist/core/project-onboarding.js +307 -0
  947. package/dist/core/project-onboarding.js.map +1 -0
  948. package/dist/core/prompt-override.d.ts +77 -0
  949. package/dist/core/prompt-override.d.ts.map +1 -0
  950. package/dist/core/prompt-override.js +201 -0
  951. package/dist/core/prompt-override.js.map +1 -0
  952. package/dist/core/runtime/bound-tool-filter.d.ts +39 -0
  953. package/dist/core/runtime/bound-tool-filter.d.ts.map +1 -0
  954. package/dist/core/runtime/bound-tool-filter.js +50 -0
  955. package/dist/core/runtime/bound-tool-filter.js.map +1 -0
  956. package/dist/core/runtime/provider-gates.d.ts +145 -0
  957. package/dist/core/runtime/provider-gates.d.ts.map +1 -0
  958. package/dist/core/runtime/provider-gates.js +194 -0
  959. package/dist/core/runtime/provider-gates.js.map +1 -0
  960. package/dist/core/runtime-intelligence.d.ts +63 -0
  961. package/dist/core/runtime-intelligence.d.ts.map +1 -0
  962. package/dist/core/runtime-intelligence.js +301 -0
  963. package/dist/core/runtime-intelligence.js.map +1 -0
  964. package/dist/core/runtime-tool-dispatch.d.ts +271 -0
  965. package/dist/core/runtime-tool-dispatch.d.ts.map +1 -0
  966. package/dist/core/runtime-tool-dispatch.js +845 -0
  967. package/dist/core/runtime-tool-dispatch.js.map +1 -0
  968. package/dist/core/runtime-tools.d.ts +92 -0
  969. package/dist/core/runtime-tools.d.ts.map +1 -0
  970. package/dist/core/runtime-tools.js +520 -0
  971. package/dist/core/runtime-tools.js.map +1 -0
  972. package/dist/core/runtime.d.ts +1425 -0
  973. package/dist/core/runtime.d.ts.map +1 -0
  974. package/dist/core/runtime.js +6223 -0
  975. package/dist/core/runtime.js.map +1 -0
  976. package/dist/core/schema-migration.d.ts +92 -0
  977. package/dist/core/schema-migration.d.ts.map +1 -0
  978. package/dist/core/schema-migration.js +322 -0
  979. package/dist/core/schema-migration.js.map +1 -0
  980. package/dist/core/session-fork.d.ts +52 -0
  981. package/dist/core/session-fork.d.ts.map +1 -0
  982. package/dist/core/session-fork.js +147 -0
  983. package/dist/core/session-fork.js.map +1 -0
  984. package/dist/core/session-recap.d.ts +51 -0
  985. package/dist/core/session-recap.d.ts.map +1 -0
  986. package/dist/core/session-recap.js +157 -0
  987. package/dist/core/session-recap.js.map +1 -0
  988. package/dist/core/session-resume.d.ts +89 -0
  989. package/dist/core/session-resume.d.ts.map +1 -0
  990. package/dist/core/session-resume.js +181 -0
  991. package/dist/core/session-resume.js.map +1 -0
  992. package/dist/core/session.d.ts +42 -0
  993. package/dist/core/session.d.ts.map +1 -0
  994. package/dist/core/session.js +155 -0
  995. package/dist/core/session.js.map +1 -0
  996. package/dist/core/steering-server.d.ts +66 -0
  997. package/dist/core/steering-server.d.ts.map +1 -0
  998. package/dist/core/steering-server.js +206 -0
  999. package/dist/core/steering-server.js.map +1 -0
  1000. package/dist/core/stream-resume.d.ts +66 -0
  1001. package/dist/core/stream-resume.d.ts.map +1 -0
  1002. package/dist/core/stream-resume.js +162 -0
  1003. package/dist/core/stream-resume.js.map +1 -0
  1004. package/dist/core/tool-path-extractor.d.ts +17 -0
  1005. package/dist/core/tool-path-extractor.d.ts.map +1 -0
  1006. package/dist/core/tool-path-extractor.js +26 -0
  1007. package/dist/core/tool-path-extractor.js.map +1 -0
  1008. package/dist/core/types.d.ts +203 -0
  1009. package/dist/core/types.d.ts.map +1 -0
  1010. package/dist/core/types.js +6 -0
  1011. package/dist/core/types.js.map +1 -0
  1012. package/dist/core/virtual-paths.d.ts +71 -0
  1013. package/dist/core/virtual-paths.d.ts.map +1 -0
  1014. package/dist/core/virtual-paths.js +157 -0
  1015. package/dist/core/virtual-paths.js.map +1 -0
  1016. package/dist/core/workspace.d.ts +20 -0
  1017. package/dist/core/workspace.d.ts.map +1 -0
  1018. package/dist/core/workspace.js +400 -0
  1019. package/dist/core/workspace.js.map +1 -0
  1020. package/dist/core/wotann-yml.d.ts +89 -0
  1021. package/dist/core/wotann-yml.d.ts.map +1 -0
  1022. package/dist/core/wotann-yml.js +328 -0
  1023. package/dist/core/wotann-yml.js.map +1 -0
  1024. package/dist/daemon/auto-update.d.ts +42 -0
  1025. package/dist/daemon/auto-update.d.ts.map +1 -0
  1026. package/dist/daemon/auto-update.js +167 -0
  1027. package/dist/daemon/auto-update.js.map +1 -0
  1028. package/dist/daemon/automations.d.ts +169 -0
  1029. package/dist/daemon/automations.d.ts.map +1 -0
  1030. package/dist/daemon/automations.js +571 -0
  1031. package/dist/daemon/automations.js.map +1 -0
  1032. package/dist/daemon/background-workers.d.ts +73 -0
  1033. package/dist/daemon/background-workers.d.ts.map +1 -0
  1034. package/dist/daemon/background-workers.js +529 -0
  1035. package/dist/daemon/background-workers.js.map +1 -0
  1036. package/dist/daemon/comment-watcher.d.ts +28 -0
  1037. package/dist/daemon/comment-watcher.d.ts.map +1 -0
  1038. package/dist/daemon/comment-watcher.js +81 -0
  1039. package/dist/daemon/comment-watcher.js.map +1 -0
  1040. package/dist/daemon/context-pressure.d.ts +31 -0
  1041. package/dist/daemon/context-pressure.d.ts.map +1 -0
  1042. package/dist/daemon/context-pressure.js +92 -0
  1043. package/dist/daemon/context-pressure.js.map +1 -0
  1044. package/dist/daemon/cron-store.d.ts +186 -0
  1045. package/dist/daemon/cron-store.d.ts.map +1 -0
  1046. package/dist/daemon/cron-store.js +464 -0
  1047. package/dist/daemon/cron-store.js.map +1 -0
  1048. package/dist/daemon/cron-utils.d.ts +35 -0
  1049. package/dist/daemon/cron-utils.d.ts.map +1 -0
  1050. package/dist/daemon/cron-utils.js +67 -0
  1051. package/dist/daemon/cron-utils.js.map +1 -0
  1052. package/dist/daemon/event-triggers.d.ts +106 -0
  1053. package/dist/daemon/event-triggers.d.ts.map +1 -0
  1054. package/dist/daemon/event-triggers.js +337 -0
  1055. package/dist/daemon/event-triggers.js.map +1 -0
  1056. package/dist/daemon/file-dep-graph.d.ts +45 -0
  1057. package/dist/daemon/file-dep-graph.d.ts.map +1 -0
  1058. package/dist/daemon/file-dep-graph.js +190 -0
  1059. package/dist/daemon/file-dep-graph.js.map +1 -0
  1060. package/dist/daemon/kairos-ipc.d.ts +175 -0
  1061. package/dist/daemon/kairos-ipc.d.ts.map +1 -0
  1062. package/dist/daemon/kairos-ipc.js +640 -0
  1063. package/dist/daemon/kairos-ipc.js.map +1 -0
  1064. package/dist/daemon/kairos-rpc.d.ts +389 -0
  1065. package/dist/daemon/kairos-rpc.d.ts.map +1 -0
  1066. package/dist/daemon/kairos-rpc.js +9893 -0
  1067. package/dist/daemon/kairos-rpc.js.map +1 -0
  1068. package/dist/daemon/kairos-tools.d.ts +91 -0
  1069. package/dist/daemon/kairos-tools.d.ts.map +1 -0
  1070. package/dist/daemon/kairos-tools.js +251 -0
  1071. package/dist/daemon/kairos-tools.js.map +1 -0
  1072. package/dist/daemon/kairos.d.ts +480 -0
  1073. package/dist/daemon/kairos.d.ts.map +1 -0
  1074. package/dist/daemon/kairos.js +3016 -0
  1075. package/dist/daemon/kairos.js.map +1 -0
  1076. package/dist/daemon/port-resolver.d.ts +42 -0
  1077. package/dist/daemon/port-resolver.d.ts.map +1 -0
  1078. package/dist/daemon/port-resolver.js +82 -0
  1079. package/dist/daemon/port-resolver.js.map +1 -0
  1080. package/dist/daemon/rpc-handlers/intelligence-rpc.d.ts +125 -0
  1081. package/dist/daemon/rpc-handlers/intelligence-rpc.d.ts.map +1 -0
  1082. package/dist/daemon/rpc-handlers/intelligence-rpc.js +265 -0
  1083. package/dist/daemon/rpc-handlers/intelligence-rpc.js.map +1 -0
  1084. package/dist/daemon/rpc-handlers/orchestration-rpc.d.ts +8 -0
  1085. package/dist/daemon/rpc-handlers/orchestration-rpc.d.ts.map +1 -0
  1086. package/dist/daemon/rpc-handlers/orchestration-rpc.js +258 -0
  1087. package/dist/daemon/rpc-handlers/orchestration-rpc.js.map +1 -0
  1088. package/dist/daemon/rpc-handlers/sandbox-rpc.d.ts +68 -0
  1089. package/dist/daemon/rpc-handlers/sandbox-rpc.d.ts.map +1 -0
  1090. package/dist/daemon/rpc-handlers/sandbox-rpc.js +119 -0
  1091. package/dist/daemon/rpc-handlers/sandbox-rpc.js.map +1 -0
  1092. package/dist/daemon/rpc-subscription.d.ts +177 -0
  1093. package/dist/daemon/rpc-subscription.d.ts.map +1 -0
  1094. package/dist/daemon/rpc-subscription.js +204 -0
  1095. package/dist/daemon/rpc-subscription.js.map +1 -0
  1096. package/dist/daemon/start.d.ts +9 -0
  1097. package/dist/daemon/start.d.ts.map +1 -0
  1098. package/dist/daemon/start.js +267 -0
  1099. package/dist/daemon/start.js.map +1 -0
  1100. package/dist/daemon/terminal-monitor.d.ts +29 -0
  1101. package/dist/daemon/terminal-monitor.d.ts.map +1 -0
  1102. package/dist/daemon/terminal-monitor.js +125 -0
  1103. package/dist/daemon/terminal-monitor.js.map +1 -0
  1104. package/dist/daemon/transport/index.d.ts +17 -0
  1105. package/dist/daemon/transport/index.d.ts.map +1 -0
  1106. package/dist/daemon/transport/index.js +17 -0
  1107. package/dist/daemon/transport/index.js.map +1 -0
  1108. package/dist/daemon/transport/replay-buffer.d.ts +148 -0
  1109. package/dist/daemon/transport/replay-buffer.d.ts.map +1 -0
  1110. package/dist/daemon/transport/replay-buffer.js +180 -0
  1111. package/dist/daemon/transport/replay-buffer.js.map +1 -0
  1112. package/dist/daemon/transport/replay-registry.d.ts +112 -0
  1113. package/dist/daemon/transport/replay-registry.d.ts.map +1 -0
  1114. package/dist/daemon/transport/replay-registry.js +137 -0
  1115. package/dist/daemon/transport/replay-registry.js.map +1 -0
  1116. package/dist/design/bundle-diff.d.ts +96 -0
  1117. package/dist/design/bundle-diff.d.ts.map +1 -0
  1118. package/dist/design/bundle-diff.js +300 -0
  1119. package/dist/design/bundle-diff.js.map +1 -0
  1120. package/dist/design/bundle-writer.d.ts +103 -0
  1121. package/dist/design/bundle-writer.d.ts.map +1 -0
  1122. package/dist/design/bundle-writer.js +157 -0
  1123. package/dist/design/bundle-writer.js.map +1 -0
  1124. package/dist/design/canvas-store.d.ts +84 -0
  1125. package/dist/design/canvas-store.d.ts.map +1 -0
  1126. package/dist/design/canvas-store.js +180 -0
  1127. package/dist/design/canvas-store.js.map +1 -0
  1128. package/dist/design/canvas-to-code.d.ts +56 -0
  1129. package/dist/design/canvas-to-code.d.ts.map +1 -0
  1130. package/dist/design/canvas-to-code.js +238 -0
  1131. package/dist/design/canvas-to-code.js.map +1 -0
  1132. package/dist/design/canvas.d.ts +160 -0
  1133. package/dist/design/canvas.d.ts.map +1 -0
  1134. package/dist/design/canvas.js +405 -0
  1135. package/dist/design/canvas.js.map +1 -0
  1136. package/dist/design/component-importer.d.ts +42 -0
  1137. package/dist/design/component-importer.d.ts.map +1 -0
  1138. package/dist/design/component-importer.js +229 -0
  1139. package/dist/design/component-importer.js.map +1 -0
  1140. package/dist/design/design-md-spec.d.ts +83 -0
  1141. package/dist/design/design-md-spec.d.ts.map +1 -0
  1142. package/dist/design/design-md-spec.js +210 -0
  1143. package/dist/design/design-md-spec.js.map +1 -0
  1144. package/dist/design/design-mode.d.ts +127 -0
  1145. package/dist/design/design-mode.d.ts.map +1 -0
  1146. package/dist/design/design-mode.js +235 -0
  1147. package/dist/design/design-mode.js.map +1 -0
  1148. package/dist/design/design-tokens-parser.d.ts +46 -0
  1149. package/dist/design/design-tokens-parser.d.ts.map +1 -0
  1150. package/dist/design/design-tokens-parser.js +183 -0
  1151. package/dist/design/design-tokens-parser.js.map +1 -0
  1152. package/dist/design/designmd-linter.d.ts +41 -0
  1153. package/dist/design/designmd-linter.d.ts.map +1 -0
  1154. package/dist/design/designmd-linter.js +232 -0
  1155. package/dist/design/designmd-linter.js.map +1 -0
  1156. package/dist/design/designmd-parser.d.ts +96 -0
  1157. package/dist/design/designmd-parser.d.ts.map +1 -0
  1158. package/dist/design/designmd-parser.js +254 -0
  1159. package/dist/design/designmd-parser.js.map +1 -0
  1160. package/dist/design/dtcg-emitter.d.ts +127 -0
  1161. package/dist/design/dtcg-emitter.d.ts.map +1 -0
  1162. package/dist/design/dtcg-emitter.js +225 -0
  1163. package/dist/design/dtcg-emitter.js.map +1 -0
  1164. package/dist/design/extractor.d.ts +150 -0
  1165. package/dist/design/extractor.d.ts.map +1 -0
  1166. package/dist/design/extractor.js +569 -0
  1167. package/dist/design/extractor.js.map +1 -0
  1168. package/dist/design/handoff-receiver.d.ts +65 -0
  1169. package/dist/design/handoff-receiver.d.ts.map +1 -0
  1170. package/dist/design/handoff-receiver.js +144 -0
  1171. package/dist/design/handoff-receiver.js.map +1 -0
  1172. package/dist/design/token-emitters/desktop.d.ts +13 -0
  1173. package/dist/design/token-emitters/desktop.d.ts.map +1 -0
  1174. package/dist/design/token-emitters/desktop.js +152 -0
  1175. package/dist/design/token-emitters/desktop.js.map +1 -0
  1176. package/dist/design/token-emitters/index.d.ts +12 -0
  1177. package/dist/design/token-emitters/index.d.ts.map +1 -0
  1178. package/dist/design/token-emitters/index.js +12 -0
  1179. package/dist/design/token-emitters/index.js.map +1 -0
  1180. package/dist/design/token-emitters/ios.d.ts +15 -0
  1181. package/dist/design/token-emitters/ios.d.ts.map +1 -0
  1182. package/dist/design/token-emitters/ios.js +116 -0
  1183. package/dist/design/token-emitters/ios.js.map +1 -0
  1184. package/dist/design/token-emitters/tui.d.ts +22 -0
  1185. package/dist/design/token-emitters/tui.d.ts.map +1 -0
  1186. package/dist/design/token-emitters/tui.js +23 -0
  1187. package/dist/design/token-emitters/tui.js.map +1 -0
  1188. package/dist/design/token-emitters/w3c-tokens.d.ts +28 -0
  1189. package/dist/design/token-emitters/w3c-tokens.d.ts.map +1 -0
  1190. package/dist/design/token-emitters/w3c-tokens.js +108 -0
  1191. package/dist/design/token-emitters/w3c-tokens.js.map +1 -0
  1192. package/dist/design/tokens.d.ts +154 -0
  1193. package/dist/design/tokens.d.ts.map +1 -0
  1194. package/dist/design/tokens.js +162 -0
  1195. package/dist/design/tokens.js.map +1 -0
  1196. package/dist/design/zip-reader.d.ts +14 -0
  1197. package/dist/design/zip-reader.d.ts.map +1 -0
  1198. package/dist/design/zip-reader.js +125 -0
  1199. package/dist/design/zip-reader.js.map +1 -0
  1200. package/dist/desktop/app-state.d.ts +133 -0
  1201. package/dist/desktop/app-state.d.ts.map +1 -0
  1202. package/dist/desktop/app-state.js +161 -0
  1203. package/dist/desktop/app-state.js.map +1 -0
  1204. package/dist/desktop/artifact-comments.d.ts +94 -0
  1205. package/dist/desktop/artifact-comments.d.ts.map +1 -0
  1206. package/dist/desktop/artifact-comments.js +106 -0
  1207. package/dist/desktop/artifact-comments.js.map +1 -0
  1208. package/dist/desktop/artifacts.d.ts +78 -0
  1209. package/dist/desktop/artifacts.d.ts.map +1 -0
  1210. package/dist/desktop/artifacts.js +187 -0
  1211. package/dist/desktop/artifacts.js.map +1 -0
  1212. package/dist/desktop/command-palette.d.ts +105 -0
  1213. package/dist/desktop/command-palette.d.ts.map +1 -0
  1214. package/dist/desktop/command-palette.js +319 -0
  1215. package/dist/desktop/command-palette.js.map +1 -0
  1216. package/dist/desktop/companion-server.d.ts +494 -0
  1217. package/dist/desktop/companion-server.d.ts.map +1 -0
  1218. package/dist/desktop/companion-server.js +2147 -0
  1219. package/dist/desktop/companion-server.js.map +1 -0
  1220. package/dist/desktop/conversation-manager.d.ts +122 -0
  1221. package/dist/desktop/conversation-manager.d.ts.map +1 -0
  1222. package/dist/desktop/conversation-manager.js +207 -0
  1223. package/dist/desktop/conversation-manager.js.map +1 -0
  1224. package/dist/desktop/desktop-runtime-bridge.d.ts +78 -0
  1225. package/dist/desktop/desktop-runtime-bridge.d.ts.map +1 -0
  1226. package/dist/desktop/desktop-runtime-bridge.js +155 -0
  1227. package/dist/desktop/desktop-runtime-bridge.js.map +1 -0
  1228. package/dist/desktop/keyboard-shortcuts.d.ts +64 -0
  1229. package/dist/desktop/keyboard-shortcuts.d.ts.map +1 -0
  1230. package/dist/desktop/keyboard-shortcuts.js +152 -0
  1231. package/dist/desktop/keyboard-shortcuts.js.map +1 -0
  1232. package/dist/desktop/layout.d.ts +90 -0
  1233. package/dist/desktop/layout.d.ts.map +1 -0
  1234. package/dist/desktop/layout.js +117 -0
  1235. package/dist/desktop/layout.js.map +1 -0
  1236. package/dist/desktop/notification-manager.d.ts +88 -0
  1237. package/dist/desktop/notification-manager.d.ts.map +1 -0
  1238. package/dist/desktop/notification-manager.js +167 -0
  1239. package/dist/desktop/notification-manager.js.map +1 -0
  1240. package/dist/desktop/project-manager.d.ts +80 -0
  1241. package/dist/desktop/project-manager.d.ts.map +1 -0
  1242. package/dist/desktop/project-manager.js +146 -0
  1243. package/dist/desktop/project-manager.js.map +1 -0
  1244. package/dist/desktop/prompt-enhancer.d.ts +65 -0
  1245. package/dist/desktop/prompt-enhancer.d.ts.map +1 -0
  1246. package/dist/desktop/prompt-enhancer.js +177 -0
  1247. package/dist/desktop/prompt-enhancer.js.map +1 -0
  1248. package/dist/desktop/smart-apply-panel.d.ts +78 -0
  1249. package/dist/desktop/smart-apply-panel.d.ts.map +1 -0
  1250. package/dist/desktop/smart-apply-panel.js +140 -0
  1251. package/dist/desktop/smart-apply-panel.js.map +1 -0
  1252. package/dist/desktop/supabase-relay.d.ts +86 -0
  1253. package/dist/desktop/supabase-relay.d.ts.map +1 -0
  1254. package/dist/desktop/supabase-relay.js +335 -0
  1255. package/dist/desktop/supabase-relay.js.map +1 -0
  1256. package/dist/desktop/tauri-config.d.ts +116 -0
  1257. package/dist/desktop/tauri-config.d.ts.map +1 -0
  1258. package/dist/desktop/tauri-config.js +208 -0
  1259. package/dist/desktop/tauri-config.js.map +1 -0
  1260. package/dist/desktop/types.d.ts +135 -0
  1261. package/dist/desktop/types.d.ts.map +1 -0
  1262. package/dist/desktop/types.js +89 -0
  1263. package/dist/desktop/types.js.map +1 -0
  1264. package/dist/evals/g-eval.d.ts +36 -0
  1265. package/dist/evals/g-eval.d.ts.map +1 -0
  1266. package/dist/evals/g-eval.js +147 -0
  1267. package/dist/evals/g-eval.js.map +1 -0
  1268. package/dist/evals/owasp-llm-redteam.d.ts +39 -0
  1269. package/dist/evals/owasp-llm-redteam.d.ts.map +1 -0
  1270. package/dist/evals/owasp-llm-redteam.js +128 -0
  1271. package/dist/evals/owasp-llm-redteam.js.map +1 -0
  1272. package/dist/evals/prompt-eval.d.ts +102 -0
  1273. package/dist/evals/prompt-eval.d.ts.map +1 -0
  1274. package/dist/evals/prompt-eval.js +176 -0
  1275. package/dist/evals/prompt-eval.js.map +1 -0
  1276. package/dist/evals/ragas-metrics.d.ts +23 -0
  1277. package/dist/evals/ragas-metrics.d.ts.map +1 -0
  1278. package/dist/evals/ragas-metrics.js +233 -0
  1279. package/dist/evals/ragas-metrics.js.map +1 -0
  1280. package/dist/evals/types.d.ts +154 -0
  1281. package/dist/evals/types.d.ts.map +1 -0
  1282. package/dist/evals/types.js +43 -0
  1283. package/dist/evals/types.js.map +1 -0
  1284. package/dist/evolution/constraints.d.ts +12 -0
  1285. package/dist/evolution/constraints.d.ts.map +1 -0
  1286. package/dist/evolution/constraints.js +45 -0
  1287. package/dist/evolution/constraints.js.map +1 -0
  1288. package/dist/evolution/evaluator.d.ts +45 -0
  1289. package/dist/evolution/evaluator.d.ts.map +1 -0
  1290. package/dist/evolution/evaluator.js +109 -0
  1291. package/dist/evolution/evaluator.js.map +1 -0
  1292. package/dist/evolution/mutator.d.ts +38 -0
  1293. package/dist/evolution/mutator.d.ts.map +1 -0
  1294. package/dist/evolution/mutator.js +97 -0
  1295. package/dist/evolution/mutator.js.map +1 -0
  1296. package/dist/evolution/optimizer.d.ts +68 -0
  1297. package/dist/evolution/optimizer.d.ts.map +1 -0
  1298. package/dist/evolution/optimizer.js +170 -0
  1299. package/dist/evolution/optimizer.js.map +1 -0
  1300. package/dist/evolution/runner.d.ts +30 -0
  1301. package/dist/evolution/runner.d.ts.map +1 -0
  1302. package/dist/evolution/runner.js +67 -0
  1303. package/dist/evolution/runner.js.map +1 -0
  1304. package/dist/evolution/types.d.ts +76 -0
  1305. package/dist/evolution/types.d.ts.map +1 -0
  1306. package/dist/evolution/types.js +9 -0
  1307. package/dist/evolution/types.js.map +1 -0
  1308. package/dist/exploit/mythos-scaffold.d.ts +230 -0
  1309. package/dist/exploit/mythos-scaffold.d.ts.map +1 -0
  1310. package/dist/exploit/mythos-scaffold.js +517 -0
  1311. package/dist/exploit/mythos-scaffold.js.map +1 -0
  1312. package/dist/git/magic-git.d.ts +62 -0
  1313. package/dist/git/magic-git.d.ts.map +1 -0
  1314. package/dist/git/magic-git.js +260 -0
  1315. package/dist/git/magic-git.js.map +1 -0
  1316. package/dist/hooks/auto-archive.d.ts +65 -0
  1317. package/dist/hooks/auto-archive.d.ts.map +1 -0
  1318. package/dist/hooks/auto-archive.js +137 -0
  1319. package/dist/hooks/auto-archive.js.map +1 -0
  1320. package/dist/hooks/benchmark-engineering.d.ts +174 -0
  1321. package/dist/hooks/benchmark-engineering.d.ts.map +1 -0
  1322. package/dist/hooks/benchmark-engineering.js +484 -0
  1323. package/dist/hooks/benchmark-engineering.js.map +1 -0
  1324. package/dist/hooks/built-in.d.ts +102 -0
  1325. package/dist/hooks/built-in.d.ts.map +1 -0
  1326. package/dist/hooks/built-in.js +1358 -0
  1327. package/dist/hooks/built-in.js.map +1 -0
  1328. package/dist/hooks/compact-snapshot.d.ts +78 -0
  1329. package/dist/hooks/compact-snapshot.d.ts.map +1 -0
  1330. package/dist/hooks/compact-snapshot.js +179 -0
  1331. package/dist/hooks/compact-snapshot.js.map +1 -0
  1332. package/dist/hooks/doom-loop-detector.d.ts +63 -0
  1333. package/dist/hooks/doom-loop-detector.d.ts.map +1 -0
  1334. package/dist/hooks/doom-loop-detector.js +247 -0
  1335. package/dist/hooks/doom-loop-detector.js.map +1 -0
  1336. package/dist/hooks/engine.d.ts +274 -0
  1337. package/dist/hooks/engine.d.ts.map +1 -0
  1338. package/dist/hooks/engine.js +495 -0
  1339. package/dist/hooks/engine.js.map +1 -0
  1340. package/dist/hooks/rate-limit-resume.d.ts +99 -0
  1341. package/dist/hooks/rate-limit-resume.d.ts.map +1 -0
  1342. package/dist/hooks/rate-limit-resume.js +185 -0
  1343. package/dist/hooks/rate-limit-resume.js.map +1 -0
  1344. package/dist/hooks/verifier-gate-helpers.d.ts +126 -0
  1345. package/dist/hooks/verifier-gate-helpers.d.ts.map +1 -0
  1346. package/dist/hooks/verifier-gate-helpers.js +129 -0
  1347. package/dist/hooks/verifier-gate-helpers.js.map +1 -0
  1348. package/dist/identity/persona.d.ts +99 -0
  1349. package/dist/identity/persona.d.ts.map +1 -0
  1350. package/dist/identity/persona.js +312 -0
  1351. package/dist/identity/persona.js.map +1 -0
  1352. package/dist/identity/reasoning-engine.d.ts +88 -0
  1353. package/dist/identity/reasoning-engine.d.ts.map +1 -0
  1354. package/dist/identity/reasoning-engine.js +251 -0
  1355. package/dist/identity/reasoning-engine.js.map +1 -0
  1356. package/dist/identity/role-templates/csm.d.ts +9 -0
  1357. package/dist/identity/role-templates/csm.d.ts.map +1 -0
  1358. package/dist/identity/role-templates/csm.js +42 -0
  1359. package/dist/identity/role-templates/csm.js.map +1 -0
  1360. package/dist/identity/role-templates/devrel.d.ts +9 -0
  1361. package/dist/identity/role-templates/devrel.d.ts.map +1 -0
  1362. package/dist/identity/role-templates/devrel.js +43 -0
  1363. package/dist/identity/role-templates/devrel.js.map +1 -0
  1364. package/dist/identity/role-templates/index.d.ts +40 -0
  1365. package/dist/identity/role-templates/index.d.ts.map +1 -0
  1366. package/dist/identity/role-templates/index.js +62 -0
  1367. package/dist/identity/role-templates/index.js.map +1 -0
  1368. package/dist/identity/role-templates/recruiter.d.ts +10 -0
  1369. package/dist/identity/role-templates/recruiter.d.ts.map +1 -0
  1370. package/dist/identity/role-templates/recruiter.js +42 -0
  1371. package/dist/identity/role-templates/recruiter.js.map +1 -0
  1372. package/dist/identity/role-templates/sdr.d.ts +9 -0
  1373. package/dist/identity/role-templates/sdr.d.ts.map +1 -0
  1374. package/dist/identity/role-templates/sdr.js +41 -0
  1375. package/dist/identity/role-templates/sdr.js.map +1 -0
  1376. package/dist/identity/role-templates/support.d.ts +9 -0
  1377. package/dist/identity/role-templates/support.d.ts.map +1 -0
  1378. package/dist/identity/role-templates/support.js +41 -0
  1379. package/dist/identity/role-templates/support.js.map +1 -0
  1380. package/dist/identity/role-templates/types.d.ts +16 -0
  1381. package/dist/identity/role-templates/types.d.ts.map +1 -0
  1382. package/dist/identity/role-templates/types.js +9 -0
  1383. package/dist/identity/role-templates/types.js.map +1 -0
  1384. package/dist/identity/user-model.d.ts +110 -0
  1385. package/dist/identity/user-model.d.ts.map +1 -0
  1386. package/dist/identity/user-model.js +386 -0
  1387. package/dist/identity/user-model.js.map +1 -0
  1388. package/dist/index.d.ts +7 -0
  1389. package/dist/index.d.ts.map +1 -0
  1390. package/dist/index.js +9117 -0
  1391. package/dist/index.js.map +1 -0
  1392. package/dist/integrations/posthog-events.d.ts +70 -0
  1393. package/dist/integrations/posthog-events.d.ts.map +1 -0
  1394. package/dist/integrations/posthog-events.js +126 -0
  1395. package/dist/integrations/posthog-events.js.map +1 -0
  1396. package/dist/intelligence/12factor/enforcer.d.ts +32 -0
  1397. package/dist/intelligence/12factor/enforcer.d.ts.map +1 -0
  1398. package/dist/intelligence/12factor/enforcer.js +39 -0
  1399. package/dist/intelligence/12factor/enforcer.js.map +1 -0
  1400. package/dist/intelligence/12factor/principles.d.ts +63 -0
  1401. package/dist/intelligence/12factor/principles.d.ts.map +1 -0
  1402. package/dist/intelligence/12factor/principles.js +112 -0
  1403. package/dist/intelligence/12factor/principles.js.map +1 -0
  1404. package/dist/intelligence/12factor/single-binary.d.ts +56 -0
  1405. package/dist/intelligence/12factor/single-binary.d.ts.map +1 -0
  1406. package/dist/intelligence/12factor/single-binary.js +79 -0
  1407. package/dist/intelligence/12factor/single-binary.js.map +1 -0
  1408. package/dist/intelligence/accuracy-boost.d.ts +140 -0
  1409. package/dist/intelligence/accuracy-boost.d.ts.map +1 -0
  1410. package/dist/intelligence/accuracy-boost.js +686 -0
  1411. package/dist/intelligence/accuracy-boost.js.map +1 -0
  1412. package/dist/intelligence/action-item-extractor.d.ts +63 -0
  1413. package/dist/intelligence/action-item-extractor.d.ts.map +1 -0
  1414. package/dist/intelligence/action-item-extractor.js +154 -0
  1415. package/dist/intelligence/action-item-extractor.js.map +1 -0
  1416. package/dist/intelligence/adaptive-prompts.d.ts +43 -0
  1417. package/dist/intelligence/adaptive-prompts.d.ts.map +1 -0
  1418. package/dist/intelligence/adaptive-prompts.js +308 -0
  1419. package/dist/intelligence/adaptive-prompts.js.map +1 -0
  1420. package/dist/intelligence/adversarial-test-generator.d.ts +104 -0
  1421. package/dist/intelligence/adversarial-test-generator.d.ts.map +1 -0
  1422. package/dist/intelligence/adversarial-test-generator.js +242 -0
  1423. package/dist/intelligence/adversarial-test-generator.js.map +1 -0
  1424. package/dist/intelligence/agent-patterns/catalog.d.ts +31 -0
  1425. package/dist/intelligence/agent-patterns/catalog.d.ts.map +1 -0
  1426. package/dist/intelligence/agent-patterns/catalog.js +49 -0
  1427. package/dist/intelligence/agent-patterns/catalog.js.map +1 -0
  1428. package/dist/intelligence/agent-patterns/pattern-mapper.d.ts +56 -0
  1429. package/dist/intelligence/agent-patterns/pattern-mapper.d.ts.map +1 -0
  1430. package/dist/intelligence/agent-patterns/pattern-mapper.js +154 -0
  1431. package/dist/intelligence/agent-patterns/pattern-mapper.js.map +1 -0
  1432. package/dist/intelligence/agent-patterns/patterns-core.d.ts +10 -0
  1433. package/dist/intelligence/agent-patterns/patterns-core.d.ts.map +1 -0
  1434. package/dist/intelligence/agent-patterns/patterns-core.js +125 -0
  1435. package/dist/intelligence/agent-patterns/patterns-core.js.map +1 -0
  1436. package/dist/intelligence/agent-patterns/patterns-extended.d.ts +11 -0
  1437. package/dist/intelligence/agent-patterns/patterns-extended.d.ts.map +1 -0
  1438. package/dist/intelligence/agent-patterns/patterns-extended.js +125 -0
  1439. package/dist/intelligence/agent-patterns/patterns-extended.js.map +1 -0
  1440. package/dist/intelligence/agent-patterns/patterns.d.ts +13 -0
  1441. package/dist/intelligence/agent-patterns/patterns.d.ts.map +1 -0
  1442. package/dist/intelligence/agent-patterns/patterns.js +14 -0
  1443. package/dist/intelligence/agent-patterns/patterns.js.map +1 -0
  1444. package/dist/intelligence/agent-patterns/types.d.ts +35 -0
  1445. package/dist/intelligence/agent-patterns/types.d.ts.map +1 -0
  1446. package/dist/intelligence/agent-patterns/types.js +9 -0
  1447. package/dist/intelligence/agent-patterns/types.js.map +1 -0
  1448. package/dist/intelligence/ai-time-machine.d.ts +105 -0
  1449. package/dist/intelligence/ai-time-machine.d.ts.map +1 -0
  1450. package/dist/intelligence/ai-time-machine.js +234 -0
  1451. package/dist/intelligence/ai-time-machine.js.map +1 -0
  1452. package/dist/intelligence/ambient-awareness.d.ts +102 -0
  1453. package/dist/intelligence/ambient-awareness.d.ts.map +1 -0
  1454. package/dist/intelligence/ambient-awareness.js +355 -0
  1455. package/dist/intelligence/ambient-awareness.js.map +1 -0
  1456. package/dist/intelligence/amplifier.d.ts +101 -0
  1457. package/dist/intelligence/amplifier.d.ts.map +1 -0
  1458. package/dist/intelligence/amplifier.js +236 -0
  1459. package/dist/intelligence/amplifier.js.map +1 -0
  1460. package/dist/intelligence/answer-normalizer.d.ts +67 -0
  1461. package/dist/intelligence/answer-normalizer.d.ts.map +1 -0
  1462. package/dist/intelligence/answer-normalizer.js +221 -0
  1463. package/dist/intelligence/answer-normalizer.js.map +1 -0
  1464. package/dist/intelligence/auto-enhance.d.ts +34 -0
  1465. package/dist/intelligence/auto-enhance.d.ts.map +1 -0
  1466. package/dist/intelligence/auto-enhance.js +99 -0
  1467. package/dist/intelligence/auto-enhance.js.map +1 -0
  1468. package/dist/intelligence/auto-mode-detector.d.ts +32 -0
  1469. package/dist/intelligence/auto-mode-detector.d.ts.map +1 -0
  1470. package/dist/intelligence/auto-mode-detector.js +176 -0
  1471. package/dist/intelligence/auto-mode-detector.js.map +1 -0
  1472. package/dist/intelligence/auto-reviewer.d.ts +105 -0
  1473. package/dist/intelligence/auto-reviewer.d.ts.map +1 -0
  1474. package/dist/intelligence/auto-reviewer.js +477 -0
  1475. package/dist/intelligence/auto-reviewer.js.map +1 -0
  1476. package/dist/intelligence/auto-verify.d.ts +52 -0
  1477. package/dist/intelligence/auto-verify.d.ts.map +1 -0
  1478. package/dist/intelligence/auto-verify.js +153 -0
  1479. package/dist/intelligence/auto-verify.js.map +1 -0
  1480. package/dist/intelligence/away-summary.d.ts +48 -0
  1481. package/dist/intelligence/away-summary.d.ts.map +1 -0
  1482. package/dist/intelligence/away-summary.js +98 -0
  1483. package/dist/intelligence/away-summary.js.map +1 -0
  1484. package/dist/intelligence/bash-classifier.d.ts +19 -0
  1485. package/dist/intelligence/bash-classifier.d.ts.map +1 -0
  1486. package/dist/intelligence/bash-classifier.js +153 -0
  1487. package/dist/intelligence/bash-classifier.js.map +1 -0
  1488. package/dist/intelligence/benchmark-harness.d.ts +152 -0
  1489. package/dist/intelligence/benchmark-harness.d.ts.map +1 -0
  1490. package/dist/intelligence/benchmark-harness.js +534 -0
  1491. package/dist/intelligence/benchmark-harness.js.map +1 -0
  1492. package/dist/intelligence/benchmark-runners/aider-polyglot.d.ts +136 -0
  1493. package/dist/intelligence/benchmark-runners/aider-polyglot.d.ts.map +1 -0
  1494. package/dist/intelligence/benchmark-runners/aider-polyglot.js +389 -0
  1495. package/dist/intelligence/benchmark-runners/aider-polyglot.js.map +1 -0
  1496. package/dist/intelligence/benchmark-runners/code-eval.d.ts +162 -0
  1497. package/dist/intelligence/benchmark-runners/code-eval.d.ts.map +1 -0
  1498. package/dist/intelligence/benchmark-runners/code-eval.js +418 -0
  1499. package/dist/intelligence/benchmark-runners/code-eval.js.map +1 -0
  1500. package/dist/intelligence/benchmark-runners/index.d.ts +15 -0
  1501. package/dist/intelligence/benchmark-runners/index.d.ts.map +1 -0
  1502. package/dist/intelligence/benchmark-runners/index.js +20 -0
  1503. package/dist/intelligence/benchmark-runners/index.js.map +1 -0
  1504. package/dist/intelligence/benchmark-runners/shared.d.ts +98 -0
  1505. package/dist/intelligence/benchmark-runners/shared.d.ts.map +1 -0
  1506. package/dist/intelligence/benchmark-runners/shared.js +119 -0
  1507. package/dist/intelligence/benchmark-runners/shared.js.map +1 -0
  1508. package/dist/intelligence/benchmark-runners/swe-bench.d.ts +139 -0
  1509. package/dist/intelligence/benchmark-runners/swe-bench.d.ts.map +1 -0
  1510. package/dist/intelligence/benchmark-runners/swe-bench.js +374 -0
  1511. package/dist/intelligence/benchmark-runners/swe-bench.js.map +1 -0
  1512. package/dist/intelligence/benchmark-runners/tau-bench.d.ts +137 -0
  1513. package/dist/intelligence/benchmark-runners/tau-bench.d.ts.map +1 -0
  1514. package/dist/intelligence/benchmark-runners/tau-bench.js +378 -0
  1515. package/dist/intelligence/benchmark-runners/tau-bench.js.map +1 -0
  1516. package/dist/intelligence/benchmark-runners/terminal-bench.d.ts +210 -0
  1517. package/dist/intelligence/benchmark-runners/terminal-bench.d.ts.map +1 -0
  1518. package/dist/intelligence/benchmark-runners/terminal-bench.js +600 -0
  1519. package/dist/intelligence/benchmark-runners/terminal-bench.js.map +1 -0
  1520. package/dist/intelligence/budget-enforcer.d.ts +104 -0
  1521. package/dist/intelligence/budget-enforcer.d.ts.map +1 -0
  1522. package/dist/intelligence/budget-enforcer.js +136 -0
  1523. package/dist/intelligence/budget-enforcer.js.map +1 -0
  1524. package/dist/intelligence/bugbot.d.ts +62 -0
  1525. package/dist/intelligence/bugbot.d.ts.map +1 -0
  1526. package/dist/intelligence/bugbot.js +337 -0
  1527. package/dist/intelligence/bugbot.js.map +1 -0
  1528. package/dist/intelligence/chain-of-verification.d.ts +51 -0
  1529. package/dist/intelligence/chain-of-verification.d.ts.map +1 -0
  1530. package/dist/intelligence/chain-of-verification.js +97 -0
  1531. package/dist/intelligence/chain-of-verification.js.map +1 -0
  1532. package/dist/intelligence/code-graph.d.ts +80 -0
  1533. package/dist/intelligence/code-graph.d.ts.map +1 -0
  1534. package/dist/intelligence/code-graph.js +208 -0
  1535. package/dist/intelligence/code-graph.js.map +1 -0
  1536. package/dist/intelligence/code-outline.d.ts +44 -0
  1537. package/dist/intelligence/code-outline.d.ts.map +1 -0
  1538. package/dist/intelligence/code-outline.js +101 -0
  1539. package/dist/intelligence/code-outline.js.map +1 -0
  1540. package/dist/intelligence/codebase-health.d.ts +47 -0
  1541. package/dist/intelligence/codebase-health.d.ts.map +1 -0
  1542. package/dist/intelligence/codebase-health.js +307 -0
  1543. package/dist/intelligence/codebase-health.js.map +1 -0
  1544. package/dist/intelligence/codemaps.d.ts +44 -0
  1545. package/dist/intelligence/codemaps.d.ts.map +1 -0
  1546. package/dist/intelligence/codemaps.js +385 -0
  1547. package/dist/intelligence/codemaps.js.map +1 -0
  1548. package/dist/intelligence/confidence-calibrator.d.ts +86 -0
  1549. package/dist/intelligence/confidence-calibrator.d.ts.map +1 -0
  1550. package/dist/intelligence/confidence-calibrator.js +163 -0
  1551. package/dist/intelligence/confidence-calibrator.js.map +1 -0
  1552. package/dist/intelligence/content-cid.d.ts +63 -0
  1553. package/dist/intelligence/content-cid.d.ts.map +1 -0
  1554. package/dist/intelligence/content-cid.js +91 -0
  1555. package/dist/intelligence/content-cid.js.map +1 -0
  1556. package/dist/intelligence/context-relevance.d.ts +108 -0
  1557. package/dist/intelligence/context-relevance.d.ts.map +1 -0
  1558. package/dist/intelligence/context-relevance.js +325 -0
  1559. package/dist/intelligence/context-relevance.js.map +1 -0
  1560. package/dist/intelligence/courses-index/anthropic.d.ts +39 -0
  1561. package/dist/intelligence/courses-index/anthropic.d.ts.map +1 -0
  1562. package/dist/intelligence/courses-index/anthropic.js +110 -0
  1563. package/dist/intelligence/courses-index/anthropic.js.map +1 -0
  1564. package/dist/intelligence/critic-model.d.ts +56 -0
  1565. package/dist/intelligence/critic-model.d.ts.map +1 -0
  1566. package/dist/intelligence/critic-model.js +152 -0
  1567. package/dist/intelligence/critic-model.js.map +1 -0
  1568. package/dist/intelligence/cross-device-context.d.ts +66 -0
  1569. package/dist/intelligence/cross-device-context.d.ts.map +1 -0
  1570. package/dist/intelligence/cross-device-context.js +122 -0
  1571. package/dist/intelligence/cross-device-context.js.map +1 -0
  1572. package/dist/intelligence/data-loaders/csv.d.ts +16 -0
  1573. package/dist/intelligence/data-loaders/csv.d.ts.map +1 -0
  1574. package/dist/intelligence/data-loaders/csv.js +120 -0
  1575. package/dist/intelligence/data-loaders/csv.js.map +1 -0
  1576. package/dist/intelligence/data-loaders/json.d.ts +12 -0
  1577. package/dist/intelligence/data-loaders/json.d.ts.map +1 -0
  1578. package/dist/intelligence/data-loaders/json.js +65 -0
  1579. package/dist/intelligence/data-loaders/json.js.map +1 -0
  1580. package/dist/intelligence/data-loaders/jsonl.d.ts +15 -0
  1581. package/dist/intelligence/data-loaders/jsonl.d.ts.map +1 -0
  1582. package/dist/intelligence/data-loaders/jsonl.js +62 -0
  1583. package/dist/intelligence/data-loaders/jsonl.js.map +1 -0
  1584. package/dist/intelligence/data-loaders/markdown.d.ts +13 -0
  1585. package/dist/intelligence/data-loaders/markdown.d.ts.map +1 -0
  1586. package/dist/intelligence/data-loaders/markdown.js +40 -0
  1587. package/dist/intelligence/data-loaders/markdown.js.map +1 -0
  1588. package/dist/intelligence/data-loaders/registry.d.ts +57 -0
  1589. package/dist/intelligence/data-loaders/registry.d.ts.map +1 -0
  1590. package/dist/intelligence/data-loaders/registry.js +72 -0
  1591. package/dist/intelligence/data-loaders/registry.js.map +1 -0
  1592. package/dist/intelligence/deep-research.d.ts +90 -0
  1593. package/dist/intelligence/deep-research.d.ts.map +1 -0
  1594. package/dist/intelligence/deep-research.js +495 -0
  1595. package/dist/intelligence/deep-research.js.map +1 -0
  1596. package/dist/intelligence/dev-grounded-search.d.ts +33 -0
  1597. package/dist/intelligence/dev-grounded-search.d.ts.map +1 -0
  1598. package/dist/intelligence/dev-grounded-search.js +84 -0
  1599. package/dist/intelligence/dev-grounded-search.js.map +1 -0
  1600. package/dist/intelligence/devika/engineer-plan.d.ts +54 -0
  1601. package/dist/intelligence/devika/engineer-plan.d.ts.map +1 -0
  1602. package/dist/intelligence/devika/engineer-plan.js +124 -0
  1603. package/dist/intelligence/devika/engineer-plan.js.map +1 -0
  1604. package/dist/intelligence/domain-skill-router.d.ts +24 -0
  1605. package/dist/intelligence/domain-skill-router.d.ts.map +1 -0
  1606. package/dist/intelligence/domain-skill-router.js +143 -0
  1607. package/dist/intelligence/domain-skill-router.js.map +1 -0
  1608. package/dist/intelligence/error-pattern-learner.d.ts +67 -0
  1609. package/dist/intelligence/error-pattern-learner.d.ts.map +1 -0
  1610. package/dist/intelligence/error-pattern-learner.js +230 -0
  1611. package/dist/intelligence/error-pattern-learner.js.map +1 -0
  1612. package/dist/intelligence/eval-frameworks/redteam.d.ts +53 -0
  1613. package/dist/intelligence/eval-frameworks/redteam.d.ts.map +1 -0
  1614. package/dist/intelligence/eval-frameworks/redteam.js +160 -0
  1615. package/dist/intelligence/eval-frameworks/redteam.js.map +1 -0
  1616. package/dist/intelligence/everything-cc/catalog.d.ts +39 -0
  1617. package/dist/intelligence/everything-cc/catalog.d.ts.map +1 -0
  1618. package/dist/intelligence/everything-cc/catalog.js +122 -0
  1619. package/dist/intelligence/everything-cc/catalog.js.map +1 -0
  1620. package/dist/intelligence/everything-cc/tauri-pattern-checks.d.ts +61 -0
  1621. package/dist/intelligence/everything-cc/tauri-pattern-checks.d.ts.map +1 -0
  1622. package/dist/intelligence/everything-cc/tauri-pattern-checks.js +104 -0
  1623. package/dist/intelligence/everything-cc/tauri-pattern-checks.js.map +1 -0
  1624. package/dist/intelligence/fact-extraction.d.ts +92 -0
  1625. package/dist/intelligence/fact-extraction.d.ts.map +1 -0
  1626. package/dist/intelligence/fact-extraction.js +203 -0
  1627. package/dist/intelligence/fact-extraction.js.map +1 -0
  1628. package/dist/intelligence/finance-terminal-shell/shell.d.ts +69 -0
  1629. package/dist/intelligence/finance-terminal-shell/shell.d.ts.map +1 -0
  1630. package/dist/intelligence/finance-terminal-shell/shell.js +130 -0
  1631. package/dist/intelligence/finance-terminal-shell/shell.js.map +1 -0
  1632. package/dist/intelligence/flow-tracker.d.ts +83 -0
  1633. package/dist/intelligence/flow-tracker.d.ts.map +1 -0
  1634. package/dist/intelligence/flow-tracker.js +201 -0
  1635. package/dist/intelligence/flow-tracker.js.map +1 -0
  1636. package/dist/intelligence/follow-up-chips-v2.d.ts +64 -0
  1637. package/dist/intelligence/follow-up-chips-v2.d.ts.map +1 -0
  1638. package/dist/intelligence/follow-up-chips-v2.js +233 -0
  1639. package/dist/intelligence/follow-up-chips-v2.js.map +1 -0
  1640. package/dist/intelligence/forgecode-techniques.d.ts +143 -0
  1641. package/dist/intelligence/forgecode-techniques.d.ts.map +1 -0
  1642. package/dist/intelligence/forgecode-techniques.js +796 -0
  1643. package/dist/intelligence/forgecode-techniques.js.map +1 -0
  1644. package/dist/intelligence/genai-agents/extended-patterns.d.ts +51 -0
  1645. package/dist/intelligence/genai-agents/extended-patterns.d.ts.map +1 -0
  1646. package/dist/intelligence/genai-agents/extended-patterns.js +137 -0
  1647. package/dist/intelligence/genai-agents/extended-patterns.js.map +1 -0
  1648. package/dist/intelligence/guardian.d.ts +119 -0
  1649. package/dist/intelligence/guardian.d.ts.map +1 -0
  1650. package/dist/intelligence/guardian.js +314 -0
  1651. package/dist/intelligence/guardian.js.map +1 -0
  1652. package/dist/intelligence/haystack-patterns/pipeline.d.ts +71 -0
  1653. package/dist/intelligence/haystack-patterns/pipeline.d.ts.map +1 -0
  1654. package/dist/intelligence/haystack-patterns/pipeline.js +98 -0
  1655. package/dist/intelligence/haystack-patterns/pipeline.js.map +1 -0
  1656. package/dist/intelligence/kg-builder.d.ts +181 -0
  1657. package/dist/intelligence/kg-builder.d.ts.map +1 -0
  1658. package/dist/intelligence/kg-builder.js +807 -0
  1659. package/dist/intelligence/kg-builder.js.map +1 -0
  1660. package/dist/intelligence/langchain-patterns/chain.d.ts +64 -0
  1661. package/dist/intelligence/langchain-patterns/chain.d.ts.map +1 -0
  1662. package/dist/intelligence/langchain-patterns/chain.js +109 -0
  1663. package/dist/intelligence/langchain-patterns/chain.js.map +1 -0
  1664. package/dist/intelligence/learning-platform/ppt-generator.d.ts +45 -0
  1665. package/dist/intelligence/learning-platform/ppt-generator.d.ts.map +1 -0
  1666. package/dist/intelligence/learning-platform/ppt-generator.js +91 -0
  1667. package/dist/intelligence/learning-platform/ppt-generator.js.map +1 -0
  1668. package/dist/intelligence/llm-app-catalog/index.d.ts +35 -0
  1669. package/dist/intelligence/llm-app-catalog/index.d.ts.map +1 -0
  1670. package/dist/intelligence/llm-app-catalog/index.js +82 -0
  1671. package/dist/intelligence/llm-app-catalog/index.js.map +1 -0
  1672. package/dist/intelligence/llm-flows.d.ts +103 -0
  1673. package/dist/intelligence/llm-flows.d.ts.map +1 -0
  1674. package/dist/intelligence/llm-flows.js +145 -0
  1675. package/dist/intelligence/llm-flows.js.map +1 -0
  1676. package/dist/intelligence/meeting-capture/transcript-actionable.d.ts +36 -0
  1677. package/dist/intelligence/meeting-capture/transcript-actionable.d.ts.map +1 -0
  1678. package/dist/intelligence/meeting-capture/transcript-actionable.js +69 -0
  1679. package/dist/intelligence/meeting-capture/transcript-actionable.js.map +1 -0
  1680. package/dist/intelligence/micro-eval.d.ts +65 -0
  1681. package/dist/intelligence/micro-eval.d.ts.map +1 -0
  1682. package/dist/intelligence/micro-eval.js +278 -0
  1683. package/dist/intelligence/micro-eval.js.map +1 -0
  1684. package/dist/intelligence/multi-patch-voter.d.ts +71 -0
  1685. package/dist/intelligence/multi-patch-voter.d.ts.map +1 -0
  1686. package/dist/intelligence/multi-patch-voter.js +164 -0
  1687. package/dist/intelligence/multi-patch-voter.js.map +1 -0
  1688. package/dist/intelligence/multimodal-extract.d.ts +87 -0
  1689. package/dist/intelligence/multimodal-extract.d.ts.map +1 -0
  1690. package/dist/intelligence/multimodal-extract.js +164 -0
  1691. package/dist/intelligence/multimodal-extract.js.map +1 -0
  1692. package/dist/intelligence/note-ingest.d.ts +76 -0
  1693. package/dist/intelligence/note-ingest.d.ts.map +1 -0
  1694. package/dist/intelligence/note-ingest.js +217 -0
  1695. package/dist/intelligence/note-ingest.js.map +1 -0
  1696. package/dist/intelligence/overrides.d.ts +53 -0
  1697. package/dist/intelligence/overrides.d.ts.map +1 -0
  1698. package/dist/intelligence/overrides.js +198 -0
  1699. package/dist/intelligence/overrides.js.map +1 -0
  1700. package/dist/intelligence/parallel-search-agent.d.ts +95 -0
  1701. package/dist/intelligence/parallel-search-agent.d.ts.map +1 -0
  1702. package/dist/intelligence/parallel-search-agent.js +155 -0
  1703. package/dist/intelligence/parallel-search-agent.js.map +1 -0
  1704. package/dist/intelligence/parallel-search.d.ts +75 -0
  1705. package/dist/intelligence/parallel-search.d.ts.map +1 -0
  1706. package/dist/intelligence/parallel-search.js +312 -0
  1707. package/dist/intelligence/parallel-search.js.map +1 -0
  1708. package/dist/intelligence/patch-scorer.d.ts +136 -0
  1709. package/dist/intelligence/patch-scorer.d.ts.map +1 -0
  1710. package/dist/intelligence/patch-scorer.js +348 -0
  1711. package/dist/intelligence/patch-scorer.js.map +1 -0
  1712. package/dist/intelligence/perception/element-resolver.d.ts +105 -0
  1713. package/dist/intelligence/perception/element-resolver.d.ts.map +1 -0
  1714. package/dist/intelligence/perception/element-resolver.js +149 -0
  1715. package/dist/intelligence/perception/element-resolver.js.map +1 -0
  1716. package/dist/intelligence/perception/page-comprehension.d.ts +78 -0
  1717. package/dist/intelligence/perception/page-comprehension.d.ts.map +1 -0
  1718. package/dist/intelligence/perception/page-comprehension.js +192 -0
  1719. package/dist/intelligence/perception/page-comprehension.js.map +1 -0
  1720. package/dist/intelligence/perception/screenshot-anchored-memory.d.ts +86 -0
  1721. package/dist/intelligence/perception/screenshot-anchored-memory.d.ts.map +1 -0
  1722. package/dist/intelligence/perception/screenshot-anchored-memory.js +132 -0
  1723. package/dist/intelligence/perception/screenshot-anchored-memory.js.map +1 -0
  1724. package/dist/intelligence/policy-injector.d.ts +96 -0
  1725. package/dist/intelligence/policy-injector.d.ts.map +1 -0
  1726. package/dist/intelligence/policy-injector.js +193 -0
  1727. package/dist/intelligence/policy-injector.js.map +1 -0
  1728. package/dist/intelligence/pre-completion-verifier.d.ts +155 -0
  1729. package/dist/intelligence/pre-completion-verifier.d.ts.map +1 -0
  1730. package/dist/intelligence/pre-completion-verifier.js +373 -0
  1731. package/dist/intelligence/pre-completion-verifier.js.map +1 -0
  1732. package/dist/intelligence/predictive-context.d.ts +56 -0
  1733. package/dist/intelligence/predictive-context.d.ts.map +1 -0
  1734. package/dist/intelligence/predictive-context.js +220 -0
  1735. package/dist/intelligence/predictive-context.js.map +1 -0
  1736. package/dist/intelligence/prefill-continuation.d.ts +36 -0
  1737. package/dist/intelligence/prefill-continuation.d.ts.map +1 -0
  1738. package/dist/intelligence/prefill-continuation.js +137 -0
  1739. package/dist/intelligence/prefill-continuation.js.map +1 -0
  1740. package/dist/intelligence/progressive-budget.d.ts +219 -0
  1741. package/dist/intelligence/progressive-budget.d.ts.map +1 -0
  1742. package/dist/intelligence/progressive-budget.js +270 -0
  1743. package/dist/intelligence/progressive-budget.js.map +1 -0
  1744. package/dist/intelligence/prompt-corpus.d.ts +58 -0
  1745. package/dist/intelligence/prompt-corpus.d.ts.map +1 -0
  1746. package/dist/intelligence/prompt-corpus.js +130 -0
  1747. package/dist/intelligence/prompt-corpus.js.map +1 -0
  1748. package/dist/intelligence/provider-arbitrage.d.ts +50 -0
  1749. package/dist/intelligence/provider-arbitrage.d.ts.map +1 -0
  1750. package/dist/intelligence/provider-arbitrage.js +245 -0
  1751. package/dist/intelligence/provider-arbitrage.js.map +1 -0
  1752. package/dist/intelligence/qlib-patterns/feature-engineering.d.ts +52 -0
  1753. package/dist/intelligence/qlib-patterns/feature-engineering.d.ts.map +1 -0
  1754. package/dist/intelligence/qlib-patterns/feature-engineering.js +168 -0
  1755. package/dist/intelligence/qlib-patterns/feature-engineering.js.map +1 -0
  1756. package/dist/intelligence/quant/time-series.d.ts +83 -0
  1757. package/dist/intelligence/quant/time-series.d.ts.map +1 -0
  1758. package/dist/intelligence/quant/time-series.js +178 -0
  1759. package/dist/intelligence/quant/time-series.js.map +1 -0
  1760. package/dist/intelligence/repo-knowledge/graph.d.ts +67 -0
  1761. package/dist/intelligence/repo-knowledge/graph.d.ts.map +1 -0
  1762. package/dist/intelligence/repo-knowledge/graph.js +99 -0
  1763. package/dist/intelligence/repo-knowledge/graph.js.map +1 -0
  1764. package/dist/intelligence/research-loops/budgeted-research.d.ts +68 -0
  1765. package/dist/intelligence/research-loops/budgeted-research.d.ts.map +1 -0
  1766. package/dist/intelligence/research-loops/budgeted-research.js +130 -0
  1767. package/dist/intelligence/research-loops/budgeted-research.js.map +1 -0
  1768. package/dist/intelligence/research-loops/design-patterns.d.ts +43 -0
  1769. package/dist/intelligence/research-loops/design-patterns.d.ts.map +1 -0
  1770. package/dist/intelligence/research-loops/design-patterns.js +134 -0
  1771. package/dist/intelligence/research-loops/design-patterns.js.map +1 -0
  1772. package/dist/intelligence/research-loops/domain-router.d.ts +56 -0
  1773. package/dist/intelligence/research-loops/domain-router.d.ts.map +1 -0
  1774. package/dist/intelligence/research-loops/domain-router.js +190 -0
  1775. package/dist/intelligence/research-loops/domain-router.js.map +1 -0
  1776. package/dist/intelligence/research-loops/reflective-dialog.d.ts +81 -0
  1777. package/dist/intelligence/research-loops/reflective-dialog.d.ts.map +1 -0
  1778. package/dist/intelligence/research-loops/reflective-dialog.js +132 -0
  1779. package/dist/intelligence/research-loops/reflective-dialog.js.map +1 -0
  1780. package/dist/intelligence/response-validator.d.ts +103 -0
  1781. package/dist/intelligence/response-validator.d.ts.map +1 -0
  1782. package/dist/intelligence/response-validator.js +417 -0
  1783. package/dist/intelligence/response-validator.js.map +1 -0
  1784. package/dist/intelligence/schema-optimizer.d.ts +61 -0
  1785. package/dist/intelligence/schema-optimizer.d.ts.map +1 -0
  1786. package/dist/intelligence/schema-optimizer.js +162 -0
  1787. package/dist/intelligence/schema-optimizer.js.map +1 -0
  1788. package/dist/intelligence/search-providers.d.ts +76 -0
  1789. package/dist/intelligence/search-providers.d.ts.map +1 -0
  1790. package/dist/intelligence/search-providers.js +209 -0
  1791. package/dist/intelligence/search-providers.js.map +1 -0
  1792. package/dist/intelligence/skill-catalog-index.d.ts +49 -0
  1793. package/dist/intelligence/skill-catalog-index.d.ts.map +1 -0
  1794. package/dist/intelligence/skill-catalog-index.js +178 -0
  1795. package/dist/intelligence/skill-catalog-index.js.map +1 -0
  1796. package/dist/intelligence/smart-file-search.d.ts +55 -0
  1797. package/dist/intelligence/smart-file-search.d.ts.map +1 -0
  1798. package/dist/intelligence/smart-file-search.js +268 -0
  1799. package/dist/intelligence/smart-file-search.js.map +1 -0
  1800. package/dist/intelligence/smart-retry.d.ts +57 -0
  1801. package/dist/intelligence/smart-retry.d.ts.map +1 -0
  1802. package/dist/intelligence/smart-retry.js +177 -0
  1803. package/dist/intelligence/smart-retry.js.map +1 -0
  1804. package/dist/intelligence/strict-schema.d.ts +76 -0
  1805. package/dist/intelligence/strict-schema.d.ts.map +1 -0
  1806. package/dist/intelligence/strict-schema.js +287 -0
  1807. package/dist/intelligence/strict-schema.js.map +1 -0
  1808. package/dist/intelligence/task-semantic-router.d.ts +49 -0
  1809. package/dist/intelligence/task-semantic-router.d.ts.map +1 -0
  1810. package/dist/intelligence/task-semantic-router.js +344 -0
  1811. package/dist/intelligence/task-semantic-router.js.map +1 -0
  1812. package/dist/intelligence/tool-pattern-detector.d.ts +68 -0
  1813. package/dist/intelligence/tool-pattern-detector.d.ts.map +1 -0
  1814. package/dist/intelligence/tool-pattern-detector.js +121 -0
  1815. package/dist/intelligence/tool-pattern-detector.js.map +1 -0
  1816. package/dist/intelligence/trace-analyzer.d.ts +90 -0
  1817. package/dist/intelligence/trace-analyzer.d.ts.map +1 -0
  1818. package/dist/intelligence/trace-analyzer.js +287 -0
  1819. package/dist/intelligence/trace-analyzer.js.map +1 -0
  1820. package/dist/intelligence/trajectory-scorer.d.ts +55 -0
  1821. package/dist/intelligence/trajectory-scorer.d.ts.map +1 -0
  1822. package/dist/intelligence/trajectory-scorer.js +235 -0
  1823. package/dist/intelligence/trajectory-scorer.js.map +1 -0
  1824. package/dist/intelligence/user-model.d.ts +93 -0
  1825. package/dist/intelligence/user-model.d.ts.map +1 -0
  1826. package/dist/intelligence/user-model.js +128 -0
  1827. package/dist/intelligence/user-model.js.map +1 -0
  1828. package/dist/intelligence/verification-cascade.d.ts +59 -0
  1829. package/dist/intelligence/verification-cascade.d.ts.map +1 -0
  1830. package/dist/intelligence/verification-cascade.js +258 -0
  1831. package/dist/intelligence/verification-cascade.js.map +1 -0
  1832. package/dist/intelligence/wall-clock-budget.d.ts +55 -0
  1833. package/dist/intelligence/wall-clock-budget.d.ts.map +1 -0
  1834. package/dist/intelligence/wall-clock-budget.js +121 -0
  1835. package/dist/intelligence/wall-clock-budget.js.map +1 -0
  1836. package/dist/intent/byoa-detector.d.ts +109 -0
  1837. package/dist/intent/byoa-detector.d.ts.map +1 -0
  1838. package/dist/intent/byoa-detector.js +208 -0
  1839. package/dist/intent/byoa-detector.js.map +1 -0
  1840. package/dist/intent/living-spec.d.ts +61 -0
  1841. package/dist/intent/living-spec.d.ts.map +1 -0
  1842. package/dist/intent/living-spec.js +301 -0
  1843. package/dist/intent/living-spec.js.map +1 -0
  1844. package/dist/learning/autodream.d.ts +190 -0
  1845. package/dist/learning/autodream.d.ts.map +1 -0
  1846. package/dist/learning/autodream.js +415 -0
  1847. package/dist/learning/autodream.js.map +1 -0
  1848. package/dist/learning/cross-session.d.ts +111 -0
  1849. package/dist/learning/cross-session.d.ts.map +1 -0
  1850. package/dist/learning/cross-session.js +406 -0
  1851. package/dist/learning/cross-session.js.map +1 -0
  1852. package/dist/learning/darwinian-evolver.d.ts +83 -0
  1853. package/dist/learning/darwinian-evolver.d.ts.map +1 -0
  1854. package/dist/learning/darwinian-evolver.js +144 -0
  1855. package/dist/learning/darwinian-evolver.js.map +1 -0
  1856. package/dist/learning/decision-ledger.d.ts +87 -0
  1857. package/dist/learning/decision-ledger.d.ts.map +1 -0
  1858. package/dist/learning/decision-ledger.js +228 -0
  1859. package/dist/learning/decision-ledger.js.map +1 -0
  1860. package/dist/learning/dream-pipeline.d.ts +108 -0
  1861. package/dist/learning/dream-pipeline.d.ts.map +1 -0
  1862. package/dist/learning/dream-pipeline.js +464 -0
  1863. package/dist/learning/dream-pipeline.js.map +1 -0
  1864. package/dist/learning/dream-runner.d.ts +55 -0
  1865. package/dist/learning/dream-runner.d.ts.map +1 -0
  1866. package/dist/learning/dream-runner.js +270 -0
  1867. package/dist/learning/dream-runner.js.map +1 -0
  1868. package/dist/learning/feedback-collector.d.ts +79 -0
  1869. package/dist/learning/feedback-collector.d.ts.map +1 -0
  1870. package/dist/learning/feedback-collector.js +170 -0
  1871. package/dist/learning/feedback-collector.js.map +1 -0
  1872. package/dist/learning/gepa-optimizer.d.ts +100 -0
  1873. package/dist/learning/gepa-optimizer.d.ts.map +1 -0
  1874. package/dist/learning/gepa-optimizer.js +207 -0
  1875. package/dist/learning/gepa-optimizer.js.map +1 -0
  1876. package/dist/learning/instinct-system.d.ts +87 -0
  1877. package/dist/learning/instinct-system.d.ts.map +1 -0
  1878. package/dist/learning/instinct-system.js +286 -0
  1879. package/dist/learning/instinct-system.js.map +1 -0
  1880. package/dist/learning/miprov2-optimizer.d.ts +82 -0
  1881. package/dist/learning/miprov2-optimizer.d.ts.map +1 -0
  1882. package/dist/learning/miprov2-optimizer.js +113 -0
  1883. package/dist/learning/miprov2-optimizer.js.map +1 -0
  1884. package/dist/learning/nightly-consolidator.d.ts +121 -0
  1885. package/dist/learning/nightly-consolidator.d.ts.map +1 -0
  1886. package/dist/learning/nightly-consolidator.js +163 -0
  1887. package/dist/learning/nightly-consolidator.js.map +1 -0
  1888. package/dist/learning/pattern-crystallizer.d.ts +87 -0
  1889. package/dist/learning/pattern-crystallizer.d.ts.map +1 -0
  1890. package/dist/learning/pattern-crystallizer.js +248 -0
  1891. package/dist/learning/pattern-crystallizer.js.map +1 -0
  1892. package/dist/learning/reflection-buffer.d.ts +68 -0
  1893. package/dist/learning/reflection-buffer.d.ts.map +1 -0
  1894. package/dist/learning/reflection-buffer.js +155 -0
  1895. package/dist/learning/reflection-buffer.js.map +1 -0
  1896. package/dist/learning/rl-feedback-export.d.ts +79 -0
  1897. package/dist/learning/rl-feedback-export.d.ts.map +1 -0
  1898. package/dist/learning/rl-feedback-export.js +132 -0
  1899. package/dist/learning/rl-feedback-export.js.map +1 -0
  1900. package/dist/learning/self-evolution.d.ts +86 -0
  1901. package/dist/learning/self-evolution.d.ts.map +1 -0
  1902. package/dist/learning/self-evolution.js +217 -0
  1903. package/dist/learning/self-evolution.js.map +1 -0
  1904. package/dist/learning/skill-forge.d.ts +157 -0
  1905. package/dist/learning/skill-forge.d.ts.map +1 -0
  1906. package/dist/learning/skill-forge.js +515 -0
  1907. package/dist/learning/skill-forge.js.map +1 -0
  1908. package/dist/learning/sleep-time-agent.d.ts +107 -0
  1909. package/dist/learning/sleep-time-agent.d.ts.map +1 -0
  1910. package/dist/learning/sleep-time-agent.js +197 -0
  1911. package/dist/learning/sleep-time-agent.js.map +1 -0
  1912. package/dist/learning/types.d.ts +77 -0
  1913. package/dist/learning/types.d.ts.map +1 -0
  1914. package/dist/learning/types.js +11 -0
  1915. package/dist/learning/types.js.map +1 -0
  1916. package/dist/lib.d.ts +230 -0
  1917. package/dist/lib.d.ts.map +1 -0
  1918. package/dist/lib.js +471 -0
  1919. package/dist/lib.js.map +1 -0
  1920. package/dist/lsp/agent-tools.d.ts +109 -0
  1921. package/dist/lsp/agent-tools.d.ts.map +1 -0
  1922. package/dist/lsp/agent-tools.js +585 -0
  1923. package/dist/lsp/agent-tools.js.map +1 -0
  1924. package/dist/lsp/lsp-tools.d.ts +84 -0
  1925. package/dist/lsp/lsp-tools.d.ts.map +1 -0
  1926. package/dist/lsp/lsp-tools.js +267 -0
  1927. package/dist/lsp/lsp-tools.js.map +1 -0
  1928. package/dist/lsp/server-registry.d.ts +153 -0
  1929. package/dist/lsp/server-registry.d.ts.map +1 -0
  1930. package/dist/lsp/server-registry.js +339 -0
  1931. package/dist/lsp/server-registry.js.map +1 -0
  1932. package/dist/lsp/symbol-operations.d.ts +97 -0
  1933. package/dist/lsp/symbol-operations.d.ts.map +1 -0
  1934. package/dist/lsp/symbol-operations.js +761 -0
  1935. package/dist/lsp/symbol-operations.js.map +1 -0
  1936. package/dist/magic/command-resolver.d.ts +27 -0
  1937. package/dist/magic/command-resolver.d.ts.map +1 -0
  1938. package/dist/magic/command-resolver.js +52 -0
  1939. package/dist/magic/command-resolver.js.map +1 -0
  1940. package/dist/magic/handlers/ai-commit.d.ts +24 -0
  1941. package/dist/magic/handlers/ai-commit.d.ts.map +1 -0
  1942. package/dist/magic/handlers/ai-commit.js +56 -0
  1943. package/dist/magic/handlers/ai-commit.js.map +1 -0
  1944. package/dist/magic/handlers/docstring.d.ts +3 -0
  1945. package/dist/magic/handlers/docstring.d.ts.map +1 -0
  1946. package/dist/magic/handlers/docstring.js +11 -0
  1947. package/dist/magic/handlers/docstring.js.map +1 -0
  1948. package/dist/magic/handlers/explain.d.ts +3 -0
  1949. package/dist/magic/handlers/explain.d.ts.map +1 -0
  1950. package/dist/magic/handlers/explain.js +11 -0
  1951. package/dist/magic/handlers/explain.js.map +1 -0
  1952. package/dist/magic/handlers/fix.d.ts +3 -0
  1953. package/dist/magic/handlers/fix.d.ts.map +1 -0
  1954. package/dist/magic/handlers/fix.js +11 -0
  1955. package/dist/magic/handlers/fix.js.map +1 -0
  1956. package/dist/magic/handlers/format.d.ts +3 -0
  1957. package/dist/magic/handlers/format.d.ts.map +1 -0
  1958. package/dist/magic/handlers/format.js +11 -0
  1959. package/dist/magic/handlers/format.js.map +1 -0
  1960. package/dist/magic/handlers/investigate-issue.d.ts +27 -0
  1961. package/dist/magic/handlers/investigate-issue.d.ts.map +1 -0
  1962. package/dist/magic/handlers/investigate-issue.js +59 -0
  1963. package/dist/magic/handlers/investigate-issue.js.map +1 -0
  1964. package/dist/magic/handlers/investigate-pr.d.ts +24 -0
  1965. package/dist/magic/handlers/investigate-pr.d.ts.map +1 -0
  1966. package/dist/magic/handlers/investigate-pr.js +58 -0
  1967. package/dist/magic/handlers/investigate-pr.js.map +1 -0
  1968. package/dist/magic/handlers/investigate-workflow.d.ts +23 -0
  1969. package/dist/magic/handlers/investigate-workflow.d.ts.map +1 -0
  1970. package/dist/magic/handlers/investigate-workflow.js +56 -0
  1971. package/dist/magic/handlers/investigate-workflow.js.map +1 -0
  1972. package/dist/magic/handlers/merge-conflict.d.ts +27 -0
  1973. package/dist/magic/handlers/merge-conflict.d.ts.map +1 -0
  1974. package/dist/magic/handlers/merge-conflict.js +68 -0
  1975. package/dist/magic/handlers/merge-conflict.js.map +1 -0
  1976. package/dist/magic/handlers/optimize.d.ts +3 -0
  1977. package/dist/magic/handlers/optimize.d.ts.map +1 -0
  1978. package/dist/magic/handlers/optimize.js +11 -0
  1979. package/dist/magic/handlers/optimize.js.map +1 -0
  1980. package/dist/magic/handlers/pr-content.d.ts +23 -0
  1981. package/dist/magic/handlers/pr-content.d.ts.map +1 -0
  1982. package/dist/magic/handlers/pr-content.js +67 -0
  1983. package/dist/magic/handlers/pr-content.js.map +1 -0
  1984. package/dist/magic/handlers/refactor.d.ts +3 -0
  1985. package/dist/magic/handlers/refactor.d.ts.map +1 -0
  1986. package/dist/magic/handlers/refactor.js +11 -0
  1987. package/dist/magic/handlers/refactor.js.map +1 -0
  1988. package/dist/magic/handlers/release-notes.d.ts +28 -0
  1989. package/dist/magic/handlers/release-notes.d.ts.map +1 -0
  1990. package/dist/magic/handlers/release-notes.js +85 -0
  1991. package/dist/magic/handlers/release-notes.js.map +1 -0
  1992. package/dist/magic/handlers/review.d.ts +3 -0
  1993. package/dist/magic/handlers/review.d.ts.map +1 -0
  1994. package/dist/magic/handlers/review.js +11 -0
  1995. package/dist/magic/handlers/review.js.map +1 -0
  1996. package/dist/magic/handlers/test.d.ts +3 -0
  1997. package/dist/magic/handlers/test.d.ts.map +1 -0
  1998. package/dist/magic/handlers/test.js +11 -0
  1999. package/dist/magic/handlers/test.js.map +1 -0
  2000. package/dist/magic/magic-commands.d.ts +17 -0
  2001. package/dist/magic/magic-commands.d.ts.map +1 -0
  2002. package/dist/magic/magic-commands.js +143 -0
  2003. package/dist/magic/magic-commands.js.map +1 -0
  2004. package/dist/magic/types.d.ts +52 -0
  2005. package/dist/magic/types.d.ts.map +1 -0
  2006. package/dist/magic/types.js +10 -0
  2007. package/dist/magic/types.js.map +1 -0
  2008. package/dist/marketplace/acp-agent-registry.d.ts +237 -0
  2009. package/dist/marketplace/acp-agent-registry.d.ts.map +1 -0
  2010. package/dist/marketplace/acp-agent-registry.js +694 -0
  2011. package/dist/marketplace/acp-agent-registry.js.map +1 -0
  2012. package/dist/marketplace/manifest.d.ts +47 -0
  2013. package/dist/marketplace/manifest.d.ts.map +1 -0
  2014. package/dist/marketplace/manifest.js +174 -0
  2015. package/dist/marketplace/manifest.js.map +1 -0
  2016. package/dist/marketplace/mcpb.d.ts +131 -0
  2017. package/dist/marketplace/mcpb.d.ts.map +1 -0
  2018. package/dist/marketplace/mcpb.js +218 -0
  2019. package/dist/marketplace/mcpb.js.map +1 -0
  2020. package/dist/marketplace/plugin-loader.d.ts +126 -0
  2021. package/dist/marketplace/plugin-loader.d.ts.map +1 -0
  2022. package/dist/marketplace/plugin-loader.js +335 -0
  2023. package/dist/marketplace/plugin-loader.js.map +1 -0
  2024. package/dist/marketplace/registry.d.ts +229 -0
  2025. package/dist/marketplace/registry.d.ts.map +1 -0
  2026. package/dist/marketplace/registry.js +875 -0
  2027. package/dist/marketplace/registry.js.map +1 -0
  2028. package/dist/marketplace/skill-quarantine.d.ts +76 -0
  2029. package/dist/marketplace/skill-quarantine.d.ts.map +1 -0
  2030. package/dist/marketplace/skill-quarantine.js +146 -0
  2031. package/dist/marketplace/skill-quarantine.js.map +1 -0
  2032. package/dist/mcp/chrome-devtools.d.ts +91 -0
  2033. package/dist/mcp/chrome-devtools.d.ts.map +1 -0
  2034. package/dist/mcp/chrome-devtools.js +152 -0
  2035. package/dist/mcp/chrome-devtools.js.map +1 -0
  2036. package/dist/mcp/discovery.d.ts +67 -0
  2037. package/dist/mcp/discovery.d.ts.map +1 -0
  2038. package/dist/mcp/discovery.js +188 -0
  2039. package/dist/mcp/discovery.js.map +1 -0
  2040. package/dist/mcp/elicitation.d.ts +128 -0
  2041. package/dist/mcp/elicitation.d.ts.map +1 -0
  2042. package/dist/mcp/elicitation.js +197 -0
  2043. package/dist/mcp/elicitation.js.map +1 -0
  2044. package/dist/mcp/health-probe.d.ts +60 -0
  2045. package/dist/mcp/health-probe.d.ts.map +1 -0
  2046. package/dist/mcp/health-probe.js +208 -0
  2047. package/dist/mcp/health-probe.js.map +1 -0
  2048. package/dist/mcp/mcp-server.d.ts +276 -0
  2049. package/dist/mcp/mcp-server.d.ts.map +1 -0
  2050. package/dist/mcp/mcp-server.js +543 -0
  2051. package/dist/mcp/mcp-server.js.map +1 -0
  2052. package/dist/mcp/memory-tool-shim.d.ts +125 -0
  2053. package/dist/mcp/memory-tool-shim.d.ts.map +1 -0
  2054. package/dist/mcp/memory-tool-shim.js +397 -0
  2055. package/dist/mcp/memory-tool-shim.js.map +1 -0
  2056. package/dist/mcp/servers/design-bridge.d.ts +87 -0
  2057. package/dist/mcp/servers/design-bridge.d.ts.map +1 -0
  2058. package/dist/mcp/servers/design-bridge.js +259 -0
  2059. package/dist/mcp/servers/design-bridge.js.map +1 -0
  2060. package/dist/mcp/servers/wotann-tools.d.ts +133 -0
  2061. package/dist/mcp/servers/wotann-tools.d.ts.map +1 -0
  2062. package/dist/mcp/servers/wotann-tools.js +452 -0
  2063. package/dist/mcp/servers/wotann-tools.js.map +1 -0
  2064. package/dist/mcp/skills-as-prompts.d.ts +126 -0
  2065. package/dist/mcp/skills-as-prompts.d.ts.map +1 -0
  2066. package/dist/mcp/skills-as-prompts.js +212 -0
  2067. package/dist/mcp/skills-as-prompts.js.map +1 -0
  2068. package/dist/mcp/tool-loader.d.ts +116 -0
  2069. package/dist/mcp/tool-loader.d.ts.map +1 -0
  2070. package/dist/mcp/tool-loader.js +368 -0
  2071. package/dist/mcp/tool-loader.js.map +1 -0
  2072. package/dist/mcp/ui-resources.d.ts +79 -0
  2073. package/dist/mcp/ui-resources.d.ts.map +1 -0
  2074. package/dist/mcp/ui-resources.js +193 -0
  2075. package/dist/mcp/ui-resources.js.map +1 -0
  2076. package/dist/meet/coaching-engine.d.ts +35 -0
  2077. package/dist/meet/coaching-engine.d.ts.map +1 -0
  2078. package/dist/meet/coaching-engine.js +101 -0
  2079. package/dist/meet/coaching-engine.js.map +1 -0
  2080. package/dist/meet/meeting-pipeline.d.ts +85 -0
  2081. package/dist/meet/meeting-pipeline.d.ts.map +1 -0
  2082. package/dist/meet/meeting-pipeline.js +156 -0
  2083. package/dist/meet/meeting-pipeline.js.map +1 -0
  2084. package/dist/meet/meeting-runtime.d.ts +90 -0
  2085. package/dist/meet/meeting-runtime.d.ts.map +1 -0
  2086. package/dist/meet/meeting-runtime.js +189 -0
  2087. package/dist/meet/meeting-runtime.js.map +1 -0
  2088. package/dist/meet/meeting-store.d.ts +37 -0
  2089. package/dist/meet/meeting-store.d.ts.map +1 -0
  2090. package/dist/meet/meeting-store.js +158 -0
  2091. package/dist/meet/meeting-store.js.map +1 -0
  2092. package/dist/memory/abstention.d.ts +132 -0
  2093. package/dist/memory/abstention.d.ts.map +1 -0
  2094. package/dist/memory/abstention.js +192 -0
  2095. package/dist/memory/abstention.js.map +1 -0
  2096. package/dist/memory/active-memory.d.ts +153 -0
  2097. package/dist/memory/active-memory.d.ts.map +1 -0
  2098. package/dist/memory/active-memory.js +431 -0
  2099. package/dist/memory/active-memory.js.map +1 -0
  2100. package/dist/memory/agent-facts.d.ts +121 -0
  2101. package/dist/memory/agent-facts.d.ts.map +1 -0
  2102. package/dist/memory/agent-facts.js +225 -0
  2103. package/dist/memory/agent-facts.js.map +1 -0
  2104. package/dist/memory/asmr-voter.d.ts +106 -0
  2105. package/dist/memory/asmr-voter.d.ts.map +1 -0
  2106. package/dist/memory/asmr-voter.js +143 -0
  2107. package/dist/memory/asmr-voter.js.map +1 -0
  2108. package/dist/memory/atomic-memory.d.ts +122 -0
  2109. package/dist/memory/atomic-memory.d.ts.map +1 -0
  2110. package/dist/memory/atomic-memory.js +232 -0
  2111. package/dist/memory/atomic-memory.js.map +1 -0
  2112. package/dist/memory/bi-temporal-edges.d.ts +154 -0
  2113. package/dist/memory/bi-temporal-edges.d.ts.map +1 -0
  2114. package/dist/memory/bi-temporal-edges.js +177 -0
  2115. package/dist/memory/bi-temporal-edges.js.map +1 -0
  2116. package/dist/memory/block-memory.d.ts +60 -0
  2117. package/dist/memory/block-memory.d.ts.map +1 -0
  2118. package/dist/memory/block-memory.js +195 -0
  2119. package/dist/memory/block-memory.js.map +1 -0
  2120. package/dist/memory/cloud-sync.d.ts +86 -0
  2121. package/dist/memory/cloud-sync.d.ts.map +1 -0
  2122. package/dist/memory/cloud-sync.js +195 -0
  2123. package/dist/memory/cloud-sync.js.map +1 -0
  2124. package/dist/memory/community-detection.d.ts +104 -0
  2125. package/dist/memory/community-detection.d.ts.map +1 -0
  2126. package/dist/memory/community-detection.js +287 -0
  2127. package/dist/memory/community-detection.js.map +1 -0
  2128. package/dist/memory/context-builder.d.ts +112 -0
  2129. package/dist/memory/context-builder.d.ts.map +1 -0
  2130. package/dist/memory/context-builder.js +251 -0
  2131. package/dist/memory/context-builder.js.map +1 -0
  2132. package/dist/memory/context-fence.d.ts +88 -0
  2133. package/dist/memory/context-fence.d.ts.map +1 -0
  2134. package/dist/memory/context-fence.js +166 -0
  2135. package/dist/memory/context-fence.js.map +1 -0
  2136. package/dist/memory/context-loader.d.ts +111 -0
  2137. package/dist/memory/context-loader.d.ts.map +1 -0
  2138. package/dist/memory/context-loader.js +215 -0
  2139. package/dist/memory/context-loader.js.map +1 -0
  2140. package/dist/memory/context-tree-files.d.ts +56 -0
  2141. package/dist/memory/context-tree-files.d.ts.map +1 -0
  2142. package/dist/memory/context-tree-files.js +185 -0
  2143. package/dist/memory/context-tree-files.js.map +1 -0
  2144. package/dist/memory/context-tree.d.ts +75 -0
  2145. package/dist/memory/context-tree.d.ts.map +1 -0
  2146. package/dist/memory/context-tree.js +302 -0
  2147. package/dist/memory/context-tree.js.map +1 -0
  2148. package/dist/memory/contextual-embeddings.d.ts +106 -0
  2149. package/dist/memory/contextual-embeddings.d.ts.map +1 -0
  2150. package/dist/memory/contextual-embeddings.js +210 -0
  2151. package/dist/memory/contextual-embeddings.js.map +1 -0
  2152. package/dist/memory/contradiction-detector.d.ts +81 -0
  2153. package/dist/memory/contradiction-detector.d.ts.map +1 -0
  2154. package/dist/memory/contradiction-detector.js +248 -0
  2155. package/dist/memory/contradiction-detector.js.map +1 -0
  2156. package/dist/memory/conversation-miner.d.ts +53 -0
  2157. package/dist/memory/conversation-miner.d.ts.map +1 -0
  2158. package/dist/memory/conversation-miner.js +416 -0
  2159. package/dist/memory/conversation-miner.js.map +1 -0
  2160. package/dist/memory/cross-encoder.d.ts +78 -0
  2161. package/dist/memory/cross-encoder.d.ts.map +1 -0
  2162. package/dist/memory/cross-encoder.js +124 -0
  2163. package/dist/memory/cross-encoder.js.map +1 -0
  2164. package/dist/memory/dual-timestamp.d.ts +115 -0
  2165. package/dist/memory/dual-timestamp.d.ts.map +1 -0
  2166. package/dist/memory/dual-timestamp.js +253 -0
  2167. package/dist/memory/dual-timestamp.js.map +1 -0
  2168. package/dist/memory/embedding-profiles.d.ts +98 -0
  2169. package/dist/memory/embedding-profiles.d.ts.map +1 -0
  2170. package/dist/memory/embedding-profiles.js +193 -0
  2171. package/dist/memory/embedding-profiles.js.map +1 -0
  2172. package/dist/memory/entity-types.d.ts +271 -0
  2173. package/dist/memory/entity-types.d.ts.map +1 -0
  2174. package/dist/memory/entity-types.js +205 -0
  2175. package/dist/memory/entity-types.js.map +1 -0
  2176. package/dist/memory/episodic-memory.d.ts +149 -0
  2177. package/dist/memory/episodic-memory.d.ts.map +1 -0
  2178. package/dist/memory/episodic-memory.js +399 -0
  2179. package/dist/memory/episodic-memory.js.map +1 -0
  2180. package/dist/memory/evals/longmemeval/corpus.d.ts +115 -0
  2181. package/dist/memory/evals/longmemeval/corpus.d.ts.map +1 -0
  2182. package/dist/memory/evals/longmemeval/corpus.js +419 -0
  2183. package/dist/memory/evals/longmemeval/corpus.js.map +1 -0
  2184. package/dist/memory/evals/longmemeval/index.d.ts +31 -0
  2185. package/dist/memory/evals/longmemeval/index.d.ts.map +1 -0
  2186. package/dist/memory/evals/longmemeval/index.js +31 -0
  2187. package/dist/memory/evals/longmemeval/index.js.map +1 -0
  2188. package/dist/memory/evals/longmemeval/runner.d.ts +81 -0
  2189. package/dist/memory/evals/longmemeval/runner.d.ts.map +1 -0
  2190. package/dist/memory/evals/longmemeval/runner.js +258 -0
  2191. package/dist/memory/evals/longmemeval/runner.js.map +1 -0
  2192. package/dist/memory/evals/longmemeval/scorer.d.ts +135 -0
  2193. package/dist/memory/evals/longmemeval/scorer.d.ts.map +1 -0
  2194. package/dist/memory/evals/longmemeval/scorer.js +452 -0
  2195. package/dist/memory/evals/longmemeval/scorer.js.map +1 -0
  2196. package/dist/memory/extended-search-types.d.ts +96 -0
  2197. package/dist/memory/extended-search-types.d.ts.map +1 -0
  2198. package/dist/memory/extended-search-types.js +245 -0
  2199. package/dist/memory/extended-search-types.js.map +1 -0
  2200. package/dist/memory/folded-context.d.ts +80 -0
  2201. package/dist/memory/folded-context.d.ts.map +1 -0
  2202. package/dist/memory/folded-context.js +196 -0
  2203. package/dist/memory/folded-context.js.map +1 -0
  2204. package/dist/memory/freshness-decay.d.ts +89 -0
  2205. package/dist/memory/freshness-decay.d.ts.map +1 -0
  2206. package/dist/memory/freshness-decay.js +134 -0
  2207. package/dist/memory/freshness-decay.js.map +1 -0
  2208. package/dist/memory/graph-rag.d.ts +166 -0
  2209. package/dist/memory/graph-rag.d.ts.map +1 -0
  2210. package/dist/memory/graph-rag.js +573 -0
  2211. package/dist/memory/graph-rag.js.map +1 -0
  2212. package/dist/memory/guidance-whisper.d.ts +37 -0
  2213. package/dist/memory/guidance-whisper.d.ts.map +1 -0
  2214. package/dist/memory/guidance-whisper.js +76 -0
  2215. package/dist/memory/guidance-whisper.js.map +1 -0
  2216. package/dist/memory/hybrid-retrieval-v2.d.ts +154 -0
  2217. package/dist/memory/hybrid-retrieval-v2.d.ts.map +1 -0
  2218. package/dist/memory/hybrid-retrieval-v2.js +295 -0
  2219. package/dist/memory/hybrid-retrieval-v2.js.map +1 -0
  2220. package/dist/memory/hybrid-retrieval.d.ts +87 -0
  2221. package/dist/memory/hybrid-retrieval.d.ts.map +1 -0
  2222. package/dist/memory/hybrid-retrieval.js +244 -0
  2223. package/dist/memory/hybrid-retrieval.js.map +1 -0
  2224. package/dist/memory/incremental-indexer.d.ts +117 -0
  2225. package/dist/memory/incremental-indexer.d.ts.map +1 -0
  2226. package/dist/memory/incremental-indexer.js +200 -0
  2227. package/dist/memory/incremental-indexer.js.map +1 -0
  2228. package/dist/memory/knowledge-update-dynamics.d.ts +95 -0
  2229. package/dist/memory/knowledge-update-dynamics.d.ts.map +1 -0
  2230. package/dist/memory/knowledge-update-dynamics.js +154 -0
  2231. package/dist/memory/knowledge-update-dynamics.js.map +1 -0
  2232. package/dist/memory/mem-palace.d.ts +99 -0
  2233. package/dist/memory/mem-palace.d.ts.map +1 -0
  2234. package/dist/memory/mem-palace.js +215 -0
  2235. package/dist/memory/mem-palace.js.map +1 -0
  2236. package/dist/memory/mem0-add-only.d.ts +140 -0
  2237. package/dist/memory/mem0-add-only.d.ts.map +1 -0
  2238. package/dist/memory/mem0-add-only.js +279 -0
  2239. package/dist/memory/mem0-add-only.js.map +1 -0
  2240. package/dist/memory/memory-benchmark.d.ts +99 -0
  2241. package/dist/memory/memory-benchmark.d.ts.map +1 -0
  2242. package/dist/memory/memory-benchmark.js +393 -0
  2243. package/dist/memory/memory-benchmark.js.map +1 -0
  2244. package/dist/memory/memory-tools.d.ts +147 -0
  2245. package/dist/memory/memory-tools.d.ts.map +1 -0
  2246. package/dist/memory/memory-tools.js +415 -0
  2247. package/dist/memory/memory-tools.js.map +1 -0
  2248. package/dist/memory/memvid-backend.d.ts +122 -0
  2249. package/dist/memory/memvid-backend.d.ts.map +1 -0
  2250. package/dist/memory/memvid-backend.js +302 -0
  2251. package/dist/memory/memvid-backend.js.map +1 -0
  2252. package/dist/memory/multi-tier.d.ts +87 -0
  2253. package/dist/memory/multi-tier.d.ts.map +1 -0
  2254. package/dist/memory/multi-tier.js +186 -0
  2255. package/dist/memory/multi-tier.js.map +1 -0
  2256. package/dist/memory/observation-extractor.d.ts +122 -0
  2257. package/dist/memory/observation-extractor.d.ts.map +1 -0
  2258. package/dist/memory/observation-extractor.js +529 -0
  2259. package/dist/memory/observation-extractor.js.map +1 -0
  2260. package/dist/memory/observer.d.ts +159 -0
  2261. package/dist/memory/observer.d.ts.map +1 -0
  2262. package/dist/memory/observer.js +273 -0
  2263. package/dist/memory/observer.js.map +1 -0
  2264. package/dist/memory/omega-layers.d.ts +136 -0
  2265. package/dist/memory/omega-layers.d.ts.map +1 -0
  2266. package/dist/memory/omega-layers.js +263 -0
  2267. package/dist/memory/omega-layers.js.map +1 -0
  2268. package/dist/memory/onnx-cross-encoder.d.ts +239 -0
  2269. package/dist/memory/onnx-cross-encoder.d.ts.map +1 -0
  2270. package/dist/memory/onnx-cross-encoder.js +627 -0
  2271. package/dist/memory/onnx-cross-encoder.js.map +1 -0
  2272. package/dist/memory/persona-tree.d.ts +102 -0
  2273. package/dist/memory/persona-tree.d.ts.map +1 -0
  2274. package/dist/memory/persona-tree.js +269 -0
  2275. package/dist/memory/persona-tree.js.map +1 -0
  2276. package/dist/memory/pluggable-provider.d.ts +140 -0
  2277. package/dist/memory/pluggable-provider.d.ts.map +1 -0
  2278. package/dist/memory/pluggable-provider.js +253 -0
  2279. package/dist/memory/pluggable-provider.js.map +1 -0
  2280. package/dist/memory/proactive-memory.d.ts +59 -0
  2281. package/dist/memory/proactive-memory.d.ts.map +1 -0
  2282. package/dist/memory/proactive-memory.js +296 -0
  2283. package/dist/memory/proactive-memory.js.map +1 -0
  2284. package/dist/memory/progressive-context-loader.d.ts +153 -0
  2285. package/dist/memory/progressive-context-loader.d.ts.map +1 -0
  2286. package/dist/memory/progressive-context-loader.js +212 -0
  2287. package/dist/memory/progressive-context-loader.js.map +1 -0
  2288. package/dist/memory/qmd-integration.d.ts +23 -0
  2289. package/dist/memory/qmd-integration.d.ts.map +1 -0
  2290. package/dist/memory/qmd-integration.js +149 -0
  2291. package/dist/memory/qmd-integration.js.map +1 -0
  2292. package/dist/memory/quantized-vector-store.d.ts +126 -0
  2293. package/dist/memory/quantized-vector-store.d.ts.map +1 -0
  2294. package/dist/memory/quantized-vector-store.js +151 -0
  2295. package/dist/memory/quantized-vector-store.js.map +1 -0
  2296. package/dist/memory/reflector.d.ts +158 -0
  2297. package/dist/memory/reflector.d.ts.map +1 -0
  2298. package/dist/memory/reflector.js +315 -0
  2299. package/dist/memory/reflector.js.map +1 -0
  2300. package/dist/memory/relationship-types.d.ts +117 -0
  2301. package/dist/memory/relationship-types.d.ts.map +1 -0
  2302. package/dist/memory/relationship-types.js +215 -0
  2303. package/dist/memory/relationship-types.js.map +1 -0
  2304. package/dist/memory/retrieval-modes/authority-weight.d.ts +17 -0
  2305. package/dist/memory/retrieval-modes/authority-weight.d.ts.map +1 -0
  2306. package/dist/memory/retrieval-modes/authority-weight.js +40 -0
  2307. package/dist/memory/retrieval-modes/authority-weight.js.map +1 -0
  2308. package/dist/memory/retrieval-modes/cross-session-bridge.d.ts +16 -0
  2309. package/dist/memory/retrieval-modes/cross-session-bridge.d.ts.map +1 -0
  2310. package/dist/memory/retrieval-modes/cross-session-bridge.js +68 -0
  2311. package/dist/memory/retrieval-modes/cross-session-bridge.js.map +1 -0
  2312. package/dist/memory/retrieval-modes/fact-time-travel.d.ts +19 -0
  2313. package/dist/memory/retrieval-modes/fact-time-travel.d.ts.map +1 -0
  2314. package/dist/memory/retrieval-modes/fact-time-travel.js +89 -0
  2315. package/dist/memory/retrieval-modes/fact-time-travel.js.map +1 -0
  2316. package/dist/memory/retrieval-modes/fuzzy-match.d.ts +16 -0
  2317. package/dist/memory/retrieval-modes/fuzzy-match.d.ts.map +1 -0
  2318. package/dist/memory/retrieval-modes/fuzzy-match.js +67 -0
  2319. package/dist/memory/retrieval-modes/fuzzy-match.js.map +1 -0
  2320. package/dist/memory/retrieval-modes/graph-traversal.d.ts +16 -0
  2321. package/dist/memory/retrieval-modes/graph-traversal.d.ts.map +1 -0
  2322. package/dist/memory/retrieval-modes/graph-traversal.js +88 -0
  2323. package/dist/memory/retrieval-modes/graph-traversal.js.map +1 -0
  2324. package/dist/memory/retrieval-modes/ingest-time-travel.d.ts +21 -0
  2325. package/dist/memory/retrieval-modes/ingest-time-travel.d.ts.map +1 -0
  2326. package/dist/memory/retrieval-modes/ingest-time-travel.js +73 -0
  2327. package/dist/memory/retrieval-modes/ingest-time-travel.js.map +1 -0
  2328. package/dist/memory/retrieval-modes/path-based.d.ts +16 -0
  2329. package/dist/memory/retrieval-modes/path-based.d.ts.map +1 -0
  2330. package/dist/memory/retrieval-modes/path-based.js +110 -0
  2331. package/dist/memory/retrieval-modes/path-based.js.map +1 -0
  2332. package/dist/memory/retrieval-modes/semantic-cluster.d.ts +20 -0
  2333. package/dist/memory/retrieval-modes/semantic-cluster.d.ts.map +1 -0
  2334. package/dist/memory/retrieval-modes/semantic-cluster.js +159 -0
  2335. package/dist/memory/retrieval-modes/semantic-cluster.js.map +1 -0
  2336. package/dist/memory/retrieval-modes/summary-first.d.ts +17 -0
  2337. package/dist/memory/retrieval-modes/summary-first.d.ts.map +1 -0
  2338. package/dist/memory/retrieval-modes/summary-first.js +82 -0
  2339. package/dist/memory/retrieval-modes/summary-first.js.map +1 -0
  2340. package/dist/memory/retrieval-modes/temporal-window.d.ts +15 -0
  2341. package/dist/memory/retrieval-modes/temporal-window.d.ts.map +1 -0
  2342. package/dist/memory/retrieval-modes/temporal-window.js +52 -0
  2343. package/dist/memory/retrieval-modes/temporal-window.js.map +1 -0
  2344. package/dist/memory/retrieval-modes/time-decay.d.ts +16 -0
  2345. package/dist/memory/retrieval-modes/time-decay.d.ts.map +1 -0
  2346. package/dist/memory/retrieval-modes/time-decay.js +54 -0
  2347. package/dist/memory/retrieval-modes/time-decay.js.map +1 -0
  2348. package/dist/memory/retrieval-modes/typed-entity.d.ts +15 -0
  2349. package/dist/memory/retrieval-modes/typed-entity.d.ts.map +1 -0
  2350. package/dist/memory/retrieval-modes/typed-entity.js +75 -0
  2351. package/dist/memory/retrieval-modes/typed-entity.js.map +1 -0
  2352. package/dist/memory/retrieval-modes/types.d.ts +98 -0
  2353. package/dist/memory/retrieval-modes/types.d.ts.map +1 -0
  2354. package/dist/memory/retrieval-modes/types.js +24 -0
  2355. package/dist/memory/retrieval-modes/types.js.map +1 -0
  2356. package/dist/memory/retrieval-quality.d.ts +73 -0
  2357. package/dist/memory/retrieval-quality.d.ts.map +1 -0
  2358. package/dist/memory/retrieval-quality.js +117 -0
  2359. package/dist/memory/retrieval-quality.js.map +1 -0
  2360. package/dist/memory/retrieval-registry.d.ts +51 -0
  2361. package/dist/memory/retrieval-registry.d.ts.map +1 -0
  2362. package/dist/memory/retrieval-registry.js +73 -0
  2363. package/dist/memory/retrieval-registry.js.map +1 -0
  2364. package/dist/memory/rrf.d.ts +65 -0
  2365. package/dist/memory/rrf.d.ts.map +1 -0
  2366. package/dist/memory/rrf.js +84 -0
  2367. package/dist/memory/rrf.js.map +1 -0
  2368. package/dist/memory/semantic-cache.d.ts +77 -0
  2369. package/dist/memory/semantic-cache.d.ts.map +1 -0
  2370. package/dist/memory/semantic-cache.js +182 -0
  2371. package/dist/memory/semantic-cache.js.map +1 -0
  2372. package/dist/memory/semantic-search.d.ts +93 -0
  2373. package/dist/memory/semantic-search.d.ts.map +1 -0
  2374. package/dist/memory/semantic-search.js +276 -0
  2375. package/dist/memory/semantic-search.js.map +1 -0
  2376. package/dist/memory/session-ingestion.d.ts +209 -0
  2377. package/dist/memory/session-ingestion.d.ts.map +1 -0
  2378. package/dist/memory/session-ingestion.js +314 -0
  2379. package/dist/memory/session-ingestion.js.map +1 -0
  2380. package/dist/memory/sqlite-vec-backend.d.ts +77 -0
  2381. package/dist/memory/sqlite-vec-backend.d.ts.map +1 -0
  2382. package/dist/memory/sqlite-vec-backend.js +255 -0
  2383. package/dist/memory/sqlite-vec-backend.js.map +1 -0
  2384. package/dist/memory/stable-prefix.d.ts +123 -0
  2385. package/dist/memory/stable-prefix.d.ts.map +1 -0
  2386. package/dist/memory/stable-prefix.js +209 -0
  2387. package/dist/memory/stable-prefix.js.map +1 -0
  2388. package/dist/memory/store.d.ts +1090 -0
  2389. package/dist/memory/store.d.ts.map +1 -0
  2390. package/dist/memory/store.js +3571 -0
  2391. package/dist/memory/store.js.map +1 -0
  2392. package/dist/memory/temporal-memory.d.ts +113 -0
  2393. package/dist/memory/temporal-memory.d.ts.map +1 -0
  2394. package/dist/memory/temporal-memory.js +358 -0
  2395. package/dist/memory/temporal-memory.js.map +1 -0
  2396. package/dist/memory/tempr.d.ts +129 -0
  2397. package/dist/memory/tempr.d.ts.map +1 -0
  2398. package/dist/memory/tempr.js +175 -0
  2399. package/dist/memory/tempr.js.map +1 -0
  2400. package/dist/memory/tunnel-detector.d.ts +82 -0
  2401. package/dist/memory/tunnel-detector.d.ts.map +1 -0
  2402. package/dist/memory/tunnel-detector.js +122 -0
  2403. package/dist/memory/tunnel-detector.js.map +1 -0
  2404. package/dist/memory/unified-knowledge.d.ts +58 -0
  2405. package/dist/memory/unified-knowledge.d.ts.map +1 -0
  2406. package/dist/memory/unified-knowledge.js +85 -0
  2407. package/dist/memory/unified-knowledge.js.map +1 -0
  2408. package/dist/memory/vector-store.d.ts +140 -0
  2409. package/dist/memory/vector-store.d.ts.map +1 -0
  2410. package/dist/memory/vector-store.js +399 -0
  2411. package/dist/memory/vector-store.js.map +1 -0
  2412. package/dist/memory/web-history-bank.d.ts +70 -0
  2413. package/dist/memory/web-history-bank.d.ts.map +1 -0
  2414. package/dist/memory/web-history-bank.js +175 -0
  2415. package/dist/memory/web-history-bank.js.map +1 -0
  2416. package/dist/memory/whisper-hook.d.ts +19 -0
  2417. package/dist/memory/whisper-hook.d.ts.map +1 -0
  2418. package/dist/memory/whisper-hook.js +35 -0
  2419. package/dist/memory/whisper-hook.js.map +1 -0
  2420. package/dist/memory/wings-rooms-halls.d.ts +107 -0
  2421. package/dist/memory/wings-rooms-halls.d.ts.map +1 -0
  2422. package/dist/memory/wings-rooms-halls.js +214 -0
  2423. package/dist/memory/wings-rooms-halls.js.map +1 -0
  2424. package/dist/middleware/auto-install.d.ts +94 -0
  2425. package/dist/middleware/auto-install.d.ts.map +1 -0
  2426. package/dist/middleware/auto-install.js +254 -0
  2427. package/dist/middleware/auto-install.js.map +1 -0
  2428. package/dist/middleware/dangling-tool-call.d.ts +59 -0
  2429. package/dist/middleware/dangling-tool-call.d.ts.map +1 -0
  2430. package/dist/middleware/dangling-tool-call.js +124 -0
  2431. package/dist/middleware/dangling-tool-call.js.map +1 -0
  2432. package/dist/middleware/deferred-tool-filter.d.ts +149 -0
  2433. package/dist/middleware/deferred-tool-filter.d.ts.map +1 -0
  2434. package/dist/middleware/deferred-tool-filter.js +321 -0
  2435. package/dist/middleware/deferred-tool-filter.js.map +1 -0
  2436. package/dist/middleware/doom-loop.d.ts +119 -0
  2437. package/dist/middleware/doom-loop.d.ts.map +1 -0
  2438. package/dist/middleware/doom-loop.js +362 -0
  2439. package/dist/middleware/doom-loop.js.map +1 -0
  2440. package/dist/middleware/file-type-gate.d.ts +140 -0
  2441. package/dist/middleware/file-type-gate.d.ts.map +1 -0
  2442. package/dist/middleware/file-type-gate.js +486 -0
  2443. package/dist/middleware/file-type-gate.js.map +1 -0
  2444. package/dist/middleware/guardrail-provider.d.ts +125 -0
  2445. package/dist/middleware/guardrail-provider.d.ts.map +1 -0
  2446. package/dist/middleware/guardrail-provider.js +216 -0
  2447. package/dist/middleware/guardrail-provider.js.map +1 -0
  2448. package/dist/middleware/intent-gate.d.ts +8 -0
  2449. package/dist/middleware/intent-gate.d.ts.map +1 -0
  2450. package/dist/middleware/intent-gate.js +184 -0
  2451. package/dist/middleware/intent-gate.js.map +1 -0
  2452. package/dist/middleware/layers.d.ts +71 -0
  2453. package/dist/middleware/layers.d.ts.map +1 -0
  2454. package/dist/middleware/layers.js +529 -0
  2455. package/dist/middleware/layers.js.map +1 -0
  2456. package/dist/middleware/llm-error-handling.d.ts +98 -0
  2457. package/dist/middleware/llm-error-handling.d.ts.map +1 -0
  2458. package/dist/middleware/llm-error-handling.js +315 -0
  2459. package/dist/middleware/llm-error-handling.js.map +1 -0
  2460. package/dist/middleware/local-context.d.ts +47 -0
  2461. package/dist/middleware/local-context.d.ts.map +1 -0
  2462. package/dist/middleware/local-context.js +237 -0
  2463. package/dist/middleware/local-context.js.map +1 -0
  2464. package/dist/middleware/loop-detection.d.ts +87 -0
  2465. package/dist/middleware/loop-detection.d.ts.map +1 -0
  2466. package/dist/middleware/loop-detection.js +168 -0
  2467. package/dist/middleware/loop-detection.js.map +1 -0
  2468. package/dist/middleware/model-call-limit.d.ts +98 -0
  2469. package/dist/middleware/model-call-limit.d.ts.map +1 -0
  2470. package/dist/middleware/model-call-limit.js +160 -0
  2471. package/dist/middleware/model-call-limit.js.map +1 -0
  2472. package/dist/middleware/non-interactive.d.ts +82 -0
  2473. package/dist/middleware/non-interactive.d.ts.map +1 -0
  2474. package/dist/middleware/non-interactive.js +195 -0
  2475. package/dist/middleware/non-interactive.js.map +1 -0
  2476. package/dist/middleware/output-truncation.d.ts +72 -0
  2477. package/dist/middleware/output-truncation.d.ts.map +1 -0
  2478. package/dist/middleware/output-truncation.js +152 -0
  2479. package/dist/middleware/output-truncation.js.map +1 -0
  2480. package/dist/middleware/pipeline.d.ts +142 -0
  2481. package/dist/middleware/pipeline.d.ts.map +1 -0
  2482. package/dist/middleware/pipeline.js +426 -0
  2483. package/dist/middleware/pipeline.js.map +1 -0
  2484. package/dist/middleware/plan-enforcement.d.ts +102 -0
  2485. package/dist/middleware/plan-enforcement.d.ts.map +1 -0
  2486. package/dist/middleware/plan-enforcement.js +247 -0
  2487. package/dist/middleware/plan-enforcement.js.map +1 -0
  2488. package/dist/middleware/pre-completion-checklist.d.ts +124 -0
  2489. package/dist/middleware/pre-completion-checklist.d.ts.map +1 -0
  2490. package/dist/middleware/pre-completion-checklist.js +401 -0
  2491. package/dist/middleware/pre-completion-checklist.js.map +1 -0
  2492. package/dist/middleware/reasoning-sandwich.d.ts +131 -0
  2493. package/dist/middleware/reasoning-sandwich.d.ts.map +1 -0
  2494. package/dist/middleware/reasoning-sandwich.js +476 -0
  2495. package/dist/middleware/reasoning-sandwich.js.map +1 -0
  2496. package/dist/middleware/response-cache.d.ts +118 -0
  2497. package/dist/middleware/response-cache.d.ts.map +1 -0
  2498. package/dist/middleware/response-cache.js +267 -0
  2499. package/dist/middleware/response-cache.js.map +1 -0
  2500. package/dist/middleware/sandbox-audit.d.ts +124 -0
  2501. package/dist/middleware/sandbox-audit.d.ts.map +1 -0
  2502. package/dist/middleware/sandbox-audit.js +319 -0
  2503. package/dist/middleware/sandbox-audit.js.map +1 -0
  2504. package/dist/middleware/sanitize-tool-inputs.d.ts +84 -0
  2505. package/dist/middleware/sanitize-tool-inputs.d.ts.map +1 -0
  2506. package/dist/middleware/sanitize-tool-inputs.js +235 -0
  2507. package/dist/middleware/sanitize-tool-inputs.js.map +1 -0
  2508. package/dist/middleware/stale-detection.d.ts +103 -0
  2509. package/dist/middleware/stale-detection.d.ts.map +1 -0
  2510. package/dist/middleware/stale-detection.js +211 -0
  2511. package/dist/middleware/stale-detection.js.map +1 -0
  2512. package/dist/middleware/system-notifications.d.ts +92 -0
  2513. package/dist/middleware/system-notifications.d.ts.map +1 -0
  2514. package/dist/middleware/system-notifications.js +280 -0
  2515. package/dist/middleware/system-notifications.js.map +1 -0
  2516. package/dist/middleware/title.d.ts +83 -0
  2517. package/dist/middleware/title.d.ts.map +1 -0
  2518. package/dist/middleware/title.js +162 -0
  2519. package/dist/middleware/title.js.map +1 -0
  2520. package/dist/middleware/tool-flow-gate.d.ts +74 -0
  2521. package/dist/middleware/tool-flow-gate.d.ts.map +1 -0
  2522. package/dist/middleware/tool-flow-gate.js +105 -0
  2523. package/dist/middleware/tool-flow-gate.js.map +1 -0
  2524. package/dist/middleware/tool-pair-validator.d.ts +61 -0
  2525. package/dist/middleware/tool-pair-validator.d.ts.map +1 -0
  2526. package/dist/middleware/tool-pair-validator.js +127 -0
  2527. package/dist/middleware/tool-pair-validator.js.map +1 -0
  2528. package/dist/middleware/trifecta-guard.d.ts +132 -0
  2529. package/dist/middleware/trifecta-guard.d.ts.map +1 -0
  2530. package/dist/middleware/trifecta-guard.js +261 -0
  2531. package/dist/middleware/trifecta-guard.js.map +1 -0
  2532. package/dist/middleware/ttsr.d.ts +40 -0
  2533. package/dist/middleware/ttsr.d.ts.map +1 -0
  2534. package/dist/middleware/ttsr.js +107 -0
  2535. package/dist/middleware/ttsr.js.map +1 -0
  2536. package/dist/middleware/types.d.ts +68 -0
  2537. package/dist/middleware/types.d.ts.map +1 -0
  2538. package/dist/middleware/types.js +7 -0
  2539. package/dist/middleware/types.js.map +1 -0
  2540. package/dist/middleware/verification-enforcement.d.ts +89 -0
  2541. package/dist/middleware/verification-enforcement.d.ts.map +1 -0
  2542. package/dist/middleware/verification-enforcement.js +192 -0
  2543. package/dist/middleware/verification-enforcement.js.map +1 -0
  2544. package/dist/middleware/verifier.d.ts +44 -0
  2545. package/dist/middleware/verifier.d.ts.map +1 -0
  2546. package/dist/middleware/verifier.js +103 -0
  2547. package/dist/middleware/verifier.js.map +1 -0
  2548. package/dist/mobile/haptic-feedback.d.ts +25 -0
  2549. package/dist/mobile/haptic-feedback.d.ts.map +1 -0
  2550. package/dist/mobile/haptic-feedback.js +46 -0
  2551. package/dist/mobile/haptic-feedback.js.map +1 -0
  2552. package/dist/mobile/ios-app.d.ts +285 -0
  2553. package/dist/mobile/ios-app.d.ts.map +1 -0
  2554. package/dist/mobile/ios-app.js +539 -0
  2555. package/dist/mobile/ios-app.js.map +1 -0
  2556. package/dist/mobile/ios-types.d.ts +185 -0
  2557. package/dist/mobile/ios-types.d.ts.map +1 -0
  2558. package/dist/mobile/ios-types.js +117 -0
  2559. package/dist/mobile/ios-types.js.map +1 -0
  2560. package/dist/mobile/secure-auth.d.ts +123 -0
  2561. package/dist/mobile/secure-auth.d.ts.map +1 -0
  2562. package/dist/mobile/secure-auth.js +220 -0
  2563. package/dist/mobile/secure-auth.js.map +1 -0
  2564. package/dist/modes/agentless/localize.d.ts +52 -0
  2565. package/dist/modes/agentless/localize.d.ts.map +1 -0
  2566. package/dist/modes/agentless/localize.js +200 -0
  2567. package/dist/modes/agentless/localize.js.map +1 -0
  2568. package/dist/modes/agentless/orchestrator.d.ts +49 -0
  2569. package/dist/modes/agentless/orchestrator.d.ts.map +1 -0
  2570. package/dist/modes/agentless/orchestrator.js +94 -0
  2571. package/dist/modes/agentless/orchestrator.js.map +1 -0
  2572. package/dist/modes/agentless/repair.d.ts +45 -0
  2573. package/dist/modes/agentless/repair.d.ts.map +1 -0
  2574. package/dist/modes/agentless/repair.js +122 -0
  2575. package/dist/modes/agentless/repair.js.map +1 -0
  2576. package/dist/modes/agentless/types.d.ts +126 -0
  2577. package/dist/modes/agentless/types.d.ts.map +1 -0
  2578. package/dist/modes/agentless/types.js +13 -0
  2579. package/dist/modes/agentless/types.js.map +1 -0
  2580. package/dist/modes/agentless/validate.d.ts +46 -0
  2581. package/dist/modes/agentless/validate.d.ts.map +1 -0
  2582. package/dist/modes/agentless/validate.js +125 -0
  2583. package/dist/modes/agentless/validate.js.map +1 -0
  2584. package/dist/monitoring/source-monitor.d.ts +53 -0
  2585. package/dist/monitoring/source-monitor.d.ts.map +1 -0
  2586. package/dist/monitoring/source-monitor.js +251 -0
  2587. package/dist/monitoring/source-monitor.js.map +1 -0
  2588. package/dist/observability/openinference.d.ts +213 -0
  2589. package/dist/observability/openinference.d.ts.map +1 -0
  2590. package/dist/observability/openinference.js +336 -0
  2591. package/dist/observability/openinference.js.map +1 -0
  2592. package/dist/observability/otel-exporter.d.ts +142 -0
  2593. package/dist/observability/otel-exporter.d.ts.map +1 -0
  2594. package/dist/observability/otel-exporter.js +336 -0
  2595. package/dist/observability/otel-exporter.js.map +1 -0
  2596. package/dist/optimize/ripple-test-scope.d.ts +75 -0
  2597. package/dist/optimize/ripple-test-scope.d.ts.map +1 -0
  2598. package/dist/optimize/ripple-test-scope.js +121 -0
  2599. package/dist/optimize/ripple-test-scope.js.map +1 -0
  2600. package/dist/optimize/textgrad-critic.d.ts +46 -0
  2601. package/dist/optimize/textgrad-critic.d.ts.map +1 -0
  2602. package/dist/optimize/textgrad-critic.js +185 -0
  2603. package/dist/optimize/textgrad-critic.js.map +1 -0
  2604. package/dist/optimize/textgrad-optimizer.d.ts +119 -0
  2605. package/dist/optimize/textgrad-optimizer.d.ts.map +1 -0
  2606. package/dist/optimize/textgrad-optimizer.js +320 -0
  2607. package/dist/optimize/textgrad-optimizer.js.map +1 -0
  2608. package/dist/optimize/textgrad-types.d.ts +122 -0
  2609. package/dist/optimize/textgrad-types.d.ts.map +1 -0
  2610. package/dist/optimize/textgrad-types.js +61 -0
  2611. package/dist/optimize/textgrad-types.js.map +1 -0
  2612. package/dist/orchestration/agent-flows/command-blocks.d.ts +68 -0
  2613. package/dist/orchestration/agent-flows/command-blocks.d.ts.map +1 -0
  2614. package/dist/orchestration/agent-flows/command-blocks.js +94 -0
  2615. package/dist/orchestration/agent-flows/command-blocks.js.map +1 -0
  2616. package/dist/orchestration/agent-hierarchy.d.ts +75 -0
  2617. package/dist/orchestration/agent-hierarchy.d.ts.map +1 -0
  2618. package/dist/orchestration/agent-hierarchy.js +165 -0
  2619. package/dist/orchestration/agent-hierarchy.js.map +1 -0
  2620. package/dist/orchestration/agent-registry.d.ts +224 -0
  2621. package/dist/orchestration/agent-registry.d.ts.map +1 -0
  2622. package/dist/orchestration/agent-registry.js +753 -0
  2623. package/dist/orchestration/agent-registry.js.map +1 -0
  2624. package/dist/orchestration/agent-workspace.d.ts +60 -0
  2625. package/dist/orchestration/agent-workspace.d.ts.map +1 -0
  2626. package/dist/orchestration/agent-workspace.js +174 -0
  2627. package/dist/orchestration/agent-workspace.js.map +1 -0
  2628. package/dist/orchestration/architect-editor.d.ts +80 -0
  2629. package/dist/orchestration/architect-editor.d.ts.map +1 -0
  2630. package/dist/orchestration/architect-editor.js +130 -0
  2631. package/dist/orchestration/architect-editor.js.map +1 -0
  2632. package/dist/orchestration/architect-implement.d.ts +38 -0
  2633. package/dist/orchestration/architect-implement.d.ts.map +1 -0
  2634. package/dist/orchestration/architect-implement.js +88 -0
  2635. package/dist/orchestration/architect-implement.js.map +1 -0
  2636. package/dist/orchestration/archon-workflow-loader.d.ts +63 -0
  2637. package/dist/orchestration/archon-workflow-loader.d.ts.map +1 -0
  2638. package/dist/orchestration/archon-workflow-loader.js +202 -0
  2639. package/dist/orchestration/archon-workflow-loader.js.map +1 -0
  2640. package/dist/orchestration/arena.d.ts +69 -0
  2641. package/dist/orchestration/arena.d.ts.map +1 -0
  2642. package/dist/orchestration/arena.js +157 -0
  2643. package/dist/orchestration/arena.js.map +1 -0
  2644. package/dist/orchestration/auto-commit.d.ts +60 -0
  2645. package/dist/orchestration/auto-commit.d.ts.map +1 -0
  2646. package/dist/orchestration/auto-commit.js +223 -0
  2647. package/dist/orchestration/auto-commit.js.map +1 -0
  2648. package/dist/orchestration/autonomous-context.d.ts +105 -0
  2649. package/dist/orchestration/autonomous-context.d.ts.map +1 -0
  2650. package/dist/orchestration/autonomous-context.js +246 -0
  2651. package/dist/orchestration/autonomous-context.js.map +1 -0
  2652. package/dist/orchestration/autonomous.d.ts +386 -0
  2653. package/dist/orchestration/autonomous.d.ts.map +1 -0
  2654. package/dist/orchestration/autonomous.js +1163 -0
  2655. package/dist/orchestration/autonomous.js.map +1 -0
  2656. package/dist/orchestration/canary-monitor.d.ts +66 -0
  2657. package/dist/orchestration/canary-monitor.d.ts.map +1 -0
  2658. package/dist/orchestration/canary-monitor.js +157 -0
  2659. package/dist/orchestration/canary-monitor.js.map +1 -0
  2660. package/dist/orchestration/code-mode.d.ts +63 -0
  2661. package/dist/orchestration/code-mode.d.ts.map +1 -0
  2662. package/dist/orchestration/code-mode.js +218 -0
  2663. package/dist/orchestration/code-mode.js.map +1 -0
  2664. package/dist/orchestration/coordinator.d.ts +129 -0
  2665. package/dist/orchestration/coordinator.d.ts.map +1 -0
  2666. package/dist/orchestration/coordinator.js +355 -0
  2667. package/dist/orchestration/coordinator.js.map +1 -0
  2668. package/dist/orchestration/council.d.ts +163 -0
  2669. package/dist/orchestration/council.d.ts.map +1 -0
  2670. package/dist/orchestration/council.js +391 -0
  2671. package/dist/orchestration/council.js.map +1 -0
  2672. package/dist/orchestration/cowork.d.ts +198 -0
  2673. package/dist/orchestration/cowork.d.ts.map +1 -0
  2674. package/dist/orchestration/cowork.js +185 -0
  2675. package/dist/orchestration/cowork.js.map +1 -0
  2676. package/dist/orchestration/coze-flow/flow.d.ts +68 -0
  2677. package/dist/orchestration/coze-flow/flow.d.ts.map +1 -0
  2678. package/dist/orchestration/coze-flow/flow.js +126 -0
  2679. package/dist/orchestration/coze-flow/flow.js.map +1 -0
  2680. package/dist/orchestration/crew.d.ts +68 -0
  2681. package/dist/orchestration/crew.d.ts.map +1 -0
  2682. package/dist/orchestration/crew.js +130 -0
  2683. package/dist/orchestration/crew.js.map +1 -0
  2684. package/dist/orchestration/critic-rerank.d.ts +119 -0
  2685. package/dist/orchestration/critic-rerank.d.ts.map +1 -0
  2686. package/dist/orchestration/critic-rerank.js +207 -0
  2687. package/dist/orchestration/critic-rerank.js.map +1 -0
  2688. package/dist/orchestration/dag-runner.d.ts +78 -0
  2689. package/dist/orchestration/dag-runner.d.ts.map +1 -0
  2690. package/dist/orchestration/dag-runner.js +176 -0
  2691. package/dist/orchestration/dag-runner.js.map +1 -0
  2692. package/dist/orchestration/dify-flow/builder.d.ts +64 -0
  2693. package/dist/orchestration/dify-flow/builder.d.ts.map +1 -0
  2694. package/dist/orchestration/dify-flow/builder.js +125 -0
  2695. package/dist/orchestration/dify-flow/builder.js.map +1 -0
  2696. package/dist/orchestration/dify-flow/langflow-engine.d.ts +71 -0
  2697. package/dist/orchestration/dify-flow/langflow-engine.d.ts.map +1 -0
  2698. package/dist/orchestration/dify-flow/langflow-engine.js +133 -0
  2699. package/dist/orchestration/dify-flow/langflow-engine.js.map +1 -0
  2700. package/dist/orchestration/dual-persona-reviewer.d.ts +131 -0
  2701. package/dist/orchestration/dual-persona-reviewer.d.ts.map +1 -0
  2702. package/dist/orchestration/dual-persona-reviewer.js +242 -0
  2703. package/dist/orchestration/dual-persona-reviewer.js.map +1 -0
  2704. package/dist/orchestration/durable-execution.d.ts +85 -0
  2705. package/dist/orchestration/durable-execution.d.ts.map +1 -0
  2706. package/dist/orchestration/durable-execution.js +221 -0
  2707. package/dist/orchestration/durable-execution.js.map +1 -0
  2708. package/dist/orchestration/dynamic-replan.d.ts +80 -0
  2709. package/dist/orchestration/dynamic-replan.d.ts.map +1 -0
  2710. package/dist/orchestration/dynamic-replan.js +109 -0
  2711. package/dist/orchestration/dynamic-replan.js.map +1 -0
  2712. package/dist/orchestration/file-transport.d.ts +44 -0
  2713. package/dist/orchestration/file-transport.d.ts.map +1 -0
  2714. package/dist/orchestration/file-transport.js +126 -0
  2715. package/dist/orchestration/file-transport.js.map +1 -0
  2716. package/dist/orchestration/flow-primitives.d.ts +99 -0
  2717. package/dist/orchestration/flow-primitives.d.ts.map +1 -0
  2718. package/dist/orchestration/flow-primitives.js +175 -0
  2719. package/dist/orchestration/flow-primitives.js.map +1 -0
  2720. package/dist/orchestration/flowise-canvas/canvas.d.ts +63 -0
  2721. package/dist/orchestration/flowise-canvas/canvas.d.ts.map +1 -0
  2722. package/dist/orchestration/flowise-canvas/canvas.js +137 -0
  2723. package/dist/orchestration/flowise-canvas/canvas.js.map +1 -0
  2724. package/dist/orchestration/generative-agents-deep/observation-stream.d.ts +69 -0
  2725. package/dist/orchestration/generative-agents-deep/observation-stream.d.ts.map +1 -0
  2726. package/dist/orchestration/generative-agents-deep/observation-stream.js +115 -0
  2727. package/dist/orchestration/generative-agents-deep/observation-stream.js.map +1 -0
  2728. package/dist/orchestration/generator-agent-loop.d.ts +136 -0
  2729. package/dist/orchestration/generator-agent-loop.d.ts.map +1 -0
  2730. package/dist/orchestration/generator-agent-loop.js +144 -0
  2731. package/dist/orchestration/generator-agent-loop.js.map +1 -0
  2732. package/dist/orchestration/goal-drift.d.ts +87 -0
  2733. package/dist/orchestration/goal-drift.d.ts.map +1 -0
  2734. package/dist/orchestration/goal-drift.js +278 -0
  2735. package/dist/orchestration/goal-drift.js.map +1 -0
  2736. package/dist/orchestration/graph-dsl.d.ts +47 -0
  2737. package/dist/orchestration/graph-dsl.d.ts.map +1 -0
  2738. package/dist/orchestration/graph-dsl.js +148 -0
  2739. package/dist/orchestration/graph-dsl.js.map +1 -0
  2740. package/dist/orchestration/handoffs.d.ts +118 -0
  2741. package/dist/orchestration/handoffs.d.ts.map +1 -0
  2742. package/dist/orchestration/handoffs.js +145 -0
  2743. package/dist/orchestration/handoffs.js.map +1 -0
  2744. package/dist/orchestration/issue-graph.d.ts +176 -0
  2745. package/dist/orchestration/issue-graph.d.ts.map +1 -0
  2746. package/dist/orchestration/issue-graph.js +313 -0
  2747. package/dist/orchestration/issue-graph.js.map +1 -0
  2748. package/dist/orchestration/jean-orchestrator.d.ts +79 -0
  2749. package/dist/orchestration/jean-orchestrator.d.ts.map +1 -0
  2750. package/dist/orchestration/jean-orchestrator.js +253 -0
  2751. package/dist/orchestration/jean-orchestrator.js.map +1 -0
  2752. package/dist/orchestration/jean-registries/command-registry.d.ts +85 -0
  2753. package/dist/orchestration/jean-registries/command-registry.d.ts.map +1 -0
  2754. package/dist/orchestration/jean-registries/command-registry.js +120 -0
  2755. package/dist/orchestration/jean-registries/command-registry.js.map +1 -0
  2756. package/dist/orchestration/jean-registries/event-registry.d.ts +80 -0
  2757. package/dist/orchestration/jean-registries/event-registry.d.ts.map +1 -0
  2758. package/dist/orchestration/jean-registries/event-registry.js +147 -0
  2759. package/dist/orchestration/jean-registries/event-registry.js.map +1 -0
  2760. package/dist/orchestration/jean-registries/process-registry.d.ts +71 -0
  2761. package/dist/orchestration/jean-registries/process-registry.d.ts.map +1 -0
  2762. package/dist/orchestration/jean-registries/process-registry.js +104 -0
  2763. package/dist/orchestration/jean-registries/process-registry.js.map +1 -0
  2764. package/dist/orchestration/jean-registries/result-registry.d.ts +71 -0
  2765. package/dist/orchestration/jean-registries/result-registry.d.ts.map +1 -0
  2766. package/dist/orchestration/jean-registries/result-registry.js +97 -0
  2767. package/dist/orchestration/jean-registries/result-registry.js.map +1 -0
  2768. package/dist/orchestration/librechat-multi/config.d.ts +61 -0
  2769. package/dist/orchestration/librechat-multi/config.d.ts.map +1 -0
  2770. package/dist/orchestration/librechat-multi/config.js +128 -0
  2771. package/dist/orchestration/librechat-multi/config.js.map +1 -0
  2772. package/dist/orchestration/living-spec.d.ts +49 -0
  2773. package/dist/orchestration/living-spec.d.ts.map +1 -0
  2774. package/dist/orchestration/living-spec.js +306 -0
  2775. package/dist/orchestration/living-spec.js.map +1 -0
  2776. package/dist/orchestration/long-horizon-orchestrator.d.ts +217 -0
  2777. package/dist/orchestration/long-horizon-orchestrator.d.ts.map +1 -0
  2778. package/dist/orchestration/long-horizon-orchestrator.js +543 -0
  2779. package/dist/orchestration/long-horizon-orchestrator.js.map +1 -0
  2780. package/dist/orchestration/long-horizon-runner.d.ts +88 -0
  2781. package/dist/orchestration/long-horizon-runner.d.ts.map +1 -0
  2782. package/dist/orchestration/long-horizon-runner.js +198 -0
  2783. package/dist/orchestration/long-horizon-runner.js.map +1 -0
  2784. package/dist/orchestration/loop-detector.d.ts +80 -0
  2785. package/dist/orchestration/loop-detector.d.ts.map +1 -0
  2786. package/dist/orchestration/loop-detector.js +225 -0
  2787. package/dist/orchestration/loop-detector.js.map +1 -0
  2788. package/dist/orchestration/meta-harness.d.ts +182 -0
  2789. package/dist/orchestration/meta-harness.d.ts.map +1 -0
  2790. package/dist/orchestration/meta-harness.js +499 -0
  2791. package/dist/orchestration/meta-harness.js.map +1 -0
  2792. package/dist/orchestration/multi-agent-society/agent.d.ts +88 -0
  2793. package/dist/orchestration/multi-agent-society/agent.d.ts.map +1 -0
  2794. package/dist/orchestration/multi-agent-society/agent.js +133 -0
  2795. package/dist/orchestration/multi-agent-society/agent.js.map +1 -0
  2796. package/dist/orchestration/multi-agent-society/society.d.ts +72 -0
  2797. package/dist/orchestration/multi-agent-society/society.d.ts.map +1 -0
  2798. package/dist/orchestration/multi-agent-society/society.js +114 -0
  2799. package/dist/orchestration/multi-agent-society/society.js.map +1 -0
  2800. package/dist/orchestration/multi-agent-society/world.d.ts +62 -0
  2801. package/dist/orchestration/multi-agent-society/world.d.ts.map +1 -0
  2802. package/dist/orchestration/multi-agent-society/world.js +109 -0
  2803. package/dist/orchestration/multi-agent-society/world.js.map +1 -0
  2804. package/dist/orchestration/owl/debate.d.ts +59 -0
  2805. package/dist/orchestration/owl/debate.d.ts.map +1 -0
  2806. package/dist/orchestration/owl/debate.js +84 -0
  2807. package/dist/orchestration/owl/debate.js.map +1 -0
  2808. package/dist/orchestration/parallel-coordinator.d.ts +55 -0
  2809. package/dist/orchestration/parallel-coordinator.d.ts.map +1 -0
  2810. package/dist/orchestration/parallel-coordinator.js +99 -0
  2811. package/dist/orchestration/parallel-coordinator.js.map +1 -0
  2812. package/dist/orchestration/paused-state.d.ts +81 -0
  2813. package/dist/orchestration/paused-state.d.ts.map +1 -0
  2814. package/dist/orchestration/paused-state.js +129 -0
  2815. package/dist/orchestration/paused-state.js.map +1 -0
  2816. package/dist/orchestration/persistence-policy.d.ts +97 -0
  2817. package/dist/orchestration/persistence-policy.d.ts.map +1 -0
  2818. package/dist/orchestration/persistence-policy.js +103 -0
  2819. package/dist/orchestration/persistence-policy.js.map +1 -0
  2820. package/dist/orchestration/phase-gate.d.ts +98 -0
  2821. package/dist/orchestration/phase-gate.d.ts.map +1 -0
  2822. package/dist/orchestration/phase-gate.js +146 -0
  2823. package/dist/orchestration/phase-gate.js.map +1 -0
  2824. package/dist/orchestration/phased-executor.d.ts +121 -0
  2825. package/dist/orchestration/phased-executor.d.ts.map +1 -0
  2826. package/dist/orchestration/phased-executor.js +188 -0
  2827. package/dist/orchestration/phased-executor.js.map +1 -0
  2828. package/dist/orchestration/plan-store.d.ts +167 -0
  2829. package/dist/orchestration/plan-store.d.ts.map +1 -0
  2830. package/dist/orchestration/plan-store.js +649 -0
  2831. package/dist/orchestration/plan-store.js.map +1 -0
  2832. package/dist/orchestration/plateau-detector.d.ts +63 -0
  2833. package/dist/orchestration/plateau-detector.d.ts.map +1 -0
  2834. package/dist/orchestration/plateau-detector.js +162 -0
  2835. package/dist/orchestration/plateau-detector.js.map +1 -0
  2836. package/dist/orchestration/proof-bundles.d.ts +71 -0
  2837. package/dist/orchestration/proof-bundles.d.ts.map +1 -0
  2838. package/dist/orchestration/proof-bundles.js +73 -0
  2839. package/dist/orchestration/proof-bundles.js.map +1 -0
  2840. package/dist/orchestration/pwr-cycle.d.ts +61 -0
  2841. package/dist/orchestration/pwr-cycle.d.ts.map +1 -0
  2842. package/dist/orchestration/pwr-cycle.js +141 -0
  2843. package/dist/orchestration/pwr-cycle.js.map +1 -0
  2844. package/dist/orchestration/ralph-mode.d.ts +50 -0
  2845. package/dist/orchestration/ralph-mode.d.ts.map +1 -0
  2846. package/dist/orchestration/ralph-mode.js +131 -0
  2847. package/dist/orchestration/ralph-mode.js.map +1 -0
  2848. package/dist/orchestration/red-blue-testing.d.ts +65 -0
  2849. package/dist/orchestration/red-blue-testing.d.ts.map +1 -0
  2850. package/dist/orchestration/red-blue-testing.js +178 -0
  2851. package/dist/orchestration/red-blue-testing.js.map +1 -0
  2852. package/dist/orchestration/self-healing-pipeline.d.ts +104 -0
  2853. package/dist/orchestration/self-healing-pipeline.d.ts.map +1 -0
  2854. package/dist/orchestration/self-healing-pipeline.js +376 -0
  2855. package/dist/orchestration/self-healing-pipeline.js.map +1 -0
  2856. package/dist/orchestration/skill-rules-provider.d.ts +88 -0
  2857. package/dist/orchestration/skill-rules-provider.d.ts.map +1 -0
  2858. package/dist/orchestration/skill-rules-provider.js +134 -0
  2859. package/dist/orchestration/skill-rules-provider.js.map +1 -0
  2860. package/dist/orchestration/sleep-time-consumer.d.ts +63 -0
  2861. package/dist/orchestration/sleep-time-consumer.d.ts.map +1 -0
  2862. package/dist/orchestration/sleep-time-consumer.js +86 -0
  2863. package/dist/orchestration/sleep-time-consumer.js.map +1 -0
  2864. package/dist/orchestration/spec-to-ship.d.ts +118 -0
  2865. package/dist/orchestration/spec-to-ship.d.ts.map +1 -0
  2866. package/dist/orchestration/spec-to-ship.js +383 -0
  2867. package/dist/orchestration/spec-to-ship.js.map +1 -0
  2868. package/dist/orchestration/speculative-execution.d.ts +45 -0
  2869. package/dist/orchestration/speculative-execution.d.ts.map +1 -0
  2870. package/dist/orchestration/speculative-execution.js +94 -0
  2871. package/dist/orchestration/speculative-execution.js.map +1 -0
  2872. package/dist/orchestration/symphony/conductor.d.ts +69 -0
  2873. package/dist/orchestration/symphony/conductor.d.ts.map +1 -0
  2874. package/dist/orchestration/symphony/conductor.js +106 -0
  2875. package/dist/orchestration/symphony/conductor.js.map +1 -0
  2876. package/dist/orchestration/task-delegation.d.ts +90 -0
  2877. package/dist/orchestration/task-delegation.d.ts.map +1 -0
  2878. package/dist/orchestration/task-delegation.js +93 -0
  2879. package/dist/orchestration/task-delegation.js.map +1 -0
  2880. package/dist/orchestration/team-templates.d.ts +46 -0
  2881. package/dist/orchestration/team-templates.d.ts.map +1 -0
  2882. package/dist/orchestration/team-templates.js +347 -0
  2883. package/dist/orchestration/team-templates.js.map +1 -0
  2884. package/dist/orchestration/todo-provider.d.ts +93 -0
  2885. package/dist/orchestration/todo-provider.d.ts.map +1 -0
  2886. package/dist/orchestration/todo-provider.js +139 -0
  2887. package/dist/orchestration/todo-provider.js.map +1 -0
  2888. package/dist/orchestration/todo-tracker.d.ts +138 -0
  2889. package/dist/orchestration/todo-tracker.d.ts.map +1 -0
  2890. package/dist/orchestration/todo-tracker.js +481 -0
  2891. package/dist/orchestration/todo-tracker.js.map +1 -0
  2892. package/dist/orchestration/tool-rules.d.ts +106 -0
  2893. package/dist/orchestration/tool-rules.d.ts.map +1 -0
  2894. package/dist/orchestration/tool-rules.js +151 -0
  2895. package/dist/orchestration/tool-rules.js.map +1 -0
  2896. package/dist/orchestration/two-state-spec.d.ts +75 -0
  2897. package/dist/orchestration/two-state-spec.d.ts.map +1 -0
  2898. package/dist/orchestration/two-state-spec.js +160 -0
  2899. package/dist/orchestration/two-state-spec.js.map +1 -0
  2900. package/dist/orchestration/ultraplan.d.ts +93 -0
  2901. package/dist/orchestration/ultraplan.d.ts.map +1 -0
  2902. package/dist/orchestration/ultraplan.js +195 -0
  2903. package/dist/orchestration/ultraplan.js.map +1 -0
  2904. package/dist/orchestration/virtual-cursor-consumer.d.ts +82 -0
  2905. package/dist/orchestration/virtual-cursor-consumer.d.ts.map +1 -0
  2906. package/dist/orchestration/virtual-cursor-consumer.js +94 -0
  2907. package/dist/orchestration/virtual-cursor-consumer.js.map +1 -0
  2908. package/dist/orchestration/visual-builders/canonical-schema.d.ts +98 -0
  2909. package/dist/orchestration/visual-builders/canonical-schema.d.ts.map +1 -0
  2910. package/dist/orchestration/visual-builders/canonical-schema.js +157 -0
  2911. package/dist/orchestration/visual-builders/canonical-schema.js.map +1 -0
  2912. package/dist/orchestration/wall-clock-budget.d.ts +63 -0
  2913. package/dist/orchestration/wall-clock-budget.d.ts.map +1 -0
  2914. package/dist/orchestration/wall-clock-budget.js +74 -0
  2915. package/dist/orchestration/wall-clock-budget.js.map +1 -0
  2916. package/dist/orchestration/wave-executor.d.ts +69 -0
  2917. package/dist/orchestration/wave-executor.d.ts.map +1 -0
  2918. package/dist/orchestration/wave-executor.js +158 -0
  2919. package/dist/orchestration/wave-executor.js.map +1 -0
  2920. package/dist/orchestration/webhook-trigger-bridge.d.ts +98 -0
  2921. package/dist/orchestration/webhook-trigger-bridge.d.ts.map +1 -0
  2922. package/dist/orchestration/webhook-trigger-bridge.js +119 -0
  2923. package/dist/orchestration/webhook-trigger-bridge.js.map +1 -0
  2924. package/dist/orchestration/workflow-dag.d.ts +117 -0
  2925. package/dist/orchestration/workflow-dag.d.ts.map +1 -0
  2926. package/dist/orchestration/workflow-dag.js +530 -0
  2927. package/dist/orchestration/workflow-dag.js.map +1 -0
  2928. package/dist/orchestration/worktree-kanban.d.ts +53 -0
  2929. package/dist/orchestration/worktree-kanban.d.ts.map +1 -0
  2930. package/dist/orchestration/worktree-kanban.js +140 -0
  2931. package/dist/orchestration/worktree-kanban.js.map +1 -0
  2932. package/dist/orchestration/worktree-manager.d.ts +129 -0
  2933. package/dist/orchestration/worktree-manager.d.ts.map +1 -0
  2934. package/dist/orchestration/worktree-manager.js +285 -0
  2935. package/dist/orchestration/worktree-manager.js.map +1 -0
  2936. package/dist/plugins/lifecycle.d.ts +146 -0
  2937. package/dist/plugins/lifecycle.d.ts.map +1 -0
  2938. package/dist/plugins/lifecycle.js +167 -0
  2939. package/dist/plugins/lifecycle.js.map +1 -0
  2940. package/dist/plugins/manager.d.ts +27 -0
  2941. package/dist/plugins/manager.d.ts.map +1 -0
  2942. package/dist/plugins/manager.js +148 -0
  2943. package/dist/plugins/manager.js.map +1 -0
  2944. package/dist/ports/chatdev-waterfall.d.ts +120 -0
  2945. package/dist/ports/chatdev-waterfall.d.ts.map +1 -0
  2946. package/dist/ports/chatdev-waterfall.js +211 -0
  2947. package/dist/ports/chatdev-waterfall.js.map +1 -0
  2948. package/dist/ports/deer-flow-research.d.ts +137 -0
  2949. package/dist/ports/deer-flow-research.d.ts.map +1 -0
  2950. package/dist/ports/deer-flow-research.js +163 -0
  2951. package/dist/ports/deer-flow-research.js.map +1 -0
  2952. package/dist/ports/mem0-graph-memory.d.ts +143 -0
  2953. package/dist/ports/mem0-graph-memory.d.ts.map +1 -0
  2954. package/dist/ports/mem0-graph-memory.js +271 -0
  2955. package/dist/ports/mem0-graph-memory.js.map +1 -0
  2956. package/dist/ports/promptfoo-assertions.d.ts +153 -0
  2957. package/dist/ports/promptfoo-assertions.d.ts.map +1 -0
  2958. package/dist/ports/promptfoo-assertions.js +339 -0
  2959. package/dist/ports/promptfoo-assertions.js.map +1 -0
  2960. package/dist/ports/scrapling-adaptive.d.ts +129 -0
  2961. package/dist/ports/scrapling-adaptive.d.ts.map +1 -0
  2962. package/dist/ports/scrapling-adaptive.js +254 -0
  2963. package/dist/ports/scrapling-adaptive.js.map +1 -0
  2964. package/dist/pr-checks/check-emitter.d.ts +75 -0
  2965. package/dist/pr-checks/check-emitter.d.ts.map +1 -0
  2966. package/dist/pr-checks/check-emitter.js +198 -0
  2967. package/dist/pr-checks/check-emitter.js.map +1 -0
  2968. package/dist/pr-checks/diff-loader.d.ts +65 -0
  2969. package/dist/pr-checks/diff-loader.d.ts.map +1 -0
  2970. package/dist/pr-checks/diff-loader.js +123 -0
  2971. package/dist/pr-checks/diff-loader.js.map +1 -0
  2972. package/dist/pr-checks/pr-runner.d.ts +106 -0
  2973. package/dist/pr-checks/pr-runner.d.ts.map +1 -0
  2974. package/dist/pr-checks/pr-runner.js +300 -0
  2975. package/dist/pr-checks/pr-runner.js.map +1 -0
  2976. package/dist/pr-checks/pr-types.d.ts +82 -0
  2977. package/dist/pr-checks/pr-types.d.ts.map +1 -0
  2978. package/dist/pr-checks/pr-types.js +10 -0
  2979. package/dist/pr-checks/pr-types.js.map +1 -0
  2980. package/dist/prompt/engine.d.ts +126 -0
  2981. package/dist/prompt/engine.d.ts.map +1 -0
  2982. package/dist/prompt/engine.js +567 -0
  2983. package/dist/prompt/engine.js.map +1 -0
  2984. package/dist/prompt/instruction-provenance.d.ts +52 -0
  2985. package/dist/prompt/instruction-provenance.d.ts.map +1 -0
  2986. package/dist/prompt/instruction-provenance.js +92 -0
  2987. package/dist/prompt/instruction-provenance.js.map +1 -0
  2988. package/dist/prompt/model-formatter.d.ts +59 -0
  2989. package/dist/prompt/model-formatter.d.ts.map +1 -0
  2990. package/dist/prompt/model-formatter.js +200 -0
  2991. package/dist/prompt/model-formatter.js.map +1 -0
  2992. package/dist/prompt/modules/capabilities.d.ts +7 -0
  2993. package/dist/prompt/modules/capabilities.d.ts.map +1 -0
  2994. package/dist/prompt/modules/capabilities.js +141 -0
  2995. package/dist/prompt/modules/capabilities.js.map +1 -0
  2996. package/dist/prompt/modules/channels.d.ts +8 -0
  2997. package/dist/prompt/modules/channels.d.ts.map +1 -0
  2998. package/dist/prompt/modules/channels.js +19 -0
  2999. package/dist/prompt/modules/channels.js.map +1 -0
  3000. package/dist/prompt/modules/conventions.d.ts +8 -0
  3001. package/dist/prompt/modules/conventions.d.ts.map +1 -0
  3002. package/dist/prompt/modules/conventions.js +90 -0
  3003. package/dist/prompt/modules/conventions.js.map +1 -0
  3004. package/dist/prompt/modules/cost.d.ts +6 -0
  3005. package/dist/prompt/modules/cost.d.ts.map +1 -0
  3006. package/dist/prompt/modules/cost.js +24 -0
  3007. package/dist/prompt/modules/cost.js.map +1 -0
  3008. package/dist/prompt/modules/history.d.ts +7 -0
  3009. package/dist/prompt/modules/history.d.ts.map +1 -0
  3010. package/dist/prompt/modules/history.js +29 -0
  3011. package/dist/prompt/modules/history.js.map +1 -0
  3012. package/dist/prompt/modules/identity.d.ts +17 -0
  3013. package/dist/prompt/modules/identity.d.ts.map +1 -0
  3014. package/dist/prompt/modules/identity.js +67 -0
  3015. package/dist/prompt/modules/identity.js.map +1 -0
  3016. package/dist/prompt/modules/index.d.ts +45 -0
  3017. package/dist/prompt/modules/index.d.ts.map +1 -0
  3018. package/dist/prompt/modules/index.js +99 -0
  3019. package/dist/prompt/modules/index.js.map +1 -0
  3020. package/dist/prompt/modules/llms-txt.d.ts +12 -0
  3021. package/dist/prompt/modules/llms-txt.d.ts.map +1 -0
  3022. package/dist/prompt/modules/llms-txt.js +51 -0
  3023. package/dist/prompt/modules/llms-txt.js.map +1 -0
  3024. package/dist/prompt/modules/memory.d.ts +17 -0
  3025. package/dist/prompt/modules/memory.d.ts.map +1 -0
  3026. package/dist/prompt/modules/memory.js +110 -0
  3027. package/dist/prompt/modules/memory.js.map +1 -0
  3028. package/dist/prompt/modules/mode.d.ts +7 -0
  3029. package/dist/prompt/modules/mode.d.ts.map +1 -0
  3030. package/dist/prompt/modules/mode.js +78 -0
  3031. package/dist/prompt/modules/mode.js.map +1 -0
  3032. package/dist/prompt/modules/phone.d.ts +8 -0
  3033. package/dist/prompt/modules/phone.d.ts.map +1 -0
  3034. package/dist/prompt/modules/phone.js +35 -0
  3035. package/dist/prompt/modules/phone.js.map +1 -0
  3036. package/dist/prompt/modules/project.d.ts +7 -0
  3037. package/dist/prompt/modules/project.d.ts.map +1 -0
  3038. package/dist/prompt/modules/project.js +29 -0
  3039. package/dist/prompt/modules/project.js.map +1 -0
  3040. package/dist/prompt/modules/safety.d.ts +7 -0
  3041. package/dist/prompt/modules/safety.d.ts.map +1 -0
  3042. package/dist/prompt/modules/safety.js +37 -0
  3043. package/dist/prompt/modules/safety.js.map +1 -0
  3044. package/dist/prompt/modules/security.d.ts +9 -0
  3045. package/dist/prompt/modules/security.d.ts.map +1 -0
  3046. package/dist/prompt/modules/security.js +121 -0
  3047. package/dist/prompt/modules/security.js.map +1 -0
  3048. package/dist/prompt/modules/skills.d.ts +7 -0
  3049. package/dist/prompt/modules/skills.d.ts.map +1 -0
  3050. package/dist/prompt/modules/skills.js +22 -0
  3051. package/dist/prompt/modules/skills.js.map +1 -0
  3052. package/dist/prompt/modules/surfaces.d.ts +7 -0
  3053. package/dist/prompt/modules/surfaces.d.ts.map +1 -0
  3054. package/dist/prompt/modules/surfaces.js +29 -0
  3055. package/dist/prompt/modules/surfaces.js.map +1 -0
  3056. package/dist/prompt/modules/tools.d.ts +16 -0
  3057. package/dist/prompt/modules/tools.d.ts.map +1 -0
  3058. package/dist/prompt/modules/tools.js +101 -0
  3059. package/dist/prompt/modules/tools.js.map +1 -0
  3060. package/dist/prompt/modules/user.d.ts +16 -0
  3061. package/dist/prompt/modules/user.d.ts.map +1 -0
  3062. package/dist/prompt/modules/user.js +23 -0
  3063. package/dist/prompt/modules/user.js.map +1 -0
  3064. package/dist/prompt/reasoning-sandwich.d.ts +145 -0
  3065. package/dist/prompt/reasoning-sandwich.d.ts.map +1 -0
  3066. package/dist/prompt/reasoning-sandwich.js +215 -0
  3067. package/dist/prompt/reasoning-sandwich.js.map +1 -0
  3068. package/dist/prompt/system-prompt.d.ts +101 -0
  3069. package/dist/prompt/system-prompt.d.ts.map +1 -0
  3070. package/dist/prompt/system-prompt.js +129 -0
  3071. package/dist/prompt/system-prompt.js.map +1 -0
  3072. package/dist/prompt/template-compiler.d.ts +44 -0
  3073. package/dist/prompt/template-compiler.d.ts.map +1 -0
  3074. package/dist/prompt/template-compiler.js +228 -0
  3075. package/dist/prompt/template-compiler.js.map +1 -0
  3076. package/dist/prompt/think-in-code.d.ts +86 -0
  3077. package/dist/prompt/think-in-code.d.ts.map +1 -0
  3078. package/dist/prompt/think-in-code.js +110 -0
  3079. package/dist/prompt/think-in-code.js.map +1 -0
  3080. package/dist/providers/account-pool.d.ts +94 -0
  3081. package/dist/providers/account-pool.d.ts.map +1 -0
  3082. package/dist/providers/account-pool.js +240 -0
  3083. package/dist/providers/account-pool.js.map +1 -0
  3084. package/dist/providers/anthropic-adapter.d.ts +47 -0
  3085. package/dist/providers/anthropic-adapter.d.ts.map +1 -0
  3086. package/dist/providers/anthropic-adapter.js +567 -0
  3087. package/dist/providers/anthropic-adapter.js.map +1 -0
  3088. package/dist/providers/anthropic-stream-decoder.d.ts +79 -0
  3089. package/dist/providers/anthropic-stream-decoder.d.ts.map +1 -0
  3090. package/dist/providers/anthropic-stream-decoder.js +281 -0
  3091. package/dist/providers/anthropic-stream-decoder.js.map +1 -0
  3092. package/dist/providers/bedrock-eventstream.d.ts +107 -0
  3093. package/dist/providers/bedrock-eventstream.d.ts.map +1 -0
  3094. package/dist/providers/bedrock-eventstream.js +246 -0
  3095. package/dist/providers/bedrock-eventstream.js.map +1 -0
  3096. package/dist/providers/bedrock-signer.d.ts +23 -0
  3097. package/dist/providers/bedrock-signer.d.ts.map +1 -0
  3098. package/dist/providers/bedrock-signer.js +439 -0
  3099. package/dist/providers/bedrock-signer.js.map +1 -0
  3100. package/dist/providers/budget-downgrader.d.ts +65 -0
  3101. package/dist/providers/budget-downgrader.d.ts.map +1 -0
  3102. package/dist/providers/budget-downgrader.js +109 -0
  3103. package/dist/providers/budget-downgrader.js.map +1 -0
  3104. package/dist/providers/capability-augmenter.d.ts +63 -0
  3105. package/dist/providers/capability-augmenter.d.ts.map +1 -0
  3106. package/dist/providers/capability-augmenter.js +202 -0
  3107. package/dist/providers/capability-augmenter.js.map +1 -0
  3108. package/dist/providers/capability-equalizer.d.ts +63 -0
  3109. package/dist/providers/capability-equalizer.d.ts.map +1 -0
  3110. package/dist/providers/capability-equalizer.js +532 -0
  3111. package/dist/providers/capability-equalizer.js.map +1 -0
  3112. package/dist/providers/capability-fingerprint.d.ts +66 -0
  3113. package/dist/providers/capability-fingerprint.d.ts.map +1 -0
  3114. package/dist/providers/capability-fingerprint.js +227 -0
  3115. package/dist/providers/capability-fingerprint.js.map +1 -0
  3116. package/dist/providers/circuit-breaker.d.ts +65 -0
  3117. package/dist/providers/circuit-breaker.d.ts.map +1 -0
  3118. package/dist/providers/circuit-breaker.js +137 -0
  3119. package/dist/providers/circuit-breaker.js.map +1 -0
  3120. package/dist/providers/claude-cli-backend.d.ts +213 -0
  3121. package/dist/providers/claude-cli-backend.d.ts.map +1 -0
  3122. package/dist/providers/claude-cli-backend.js +590 -0
  3123. package/dist/providers/claude-cli-backend.js.map +1 -0
  3124. package/dist/providers/cli-registry.d.ts +39 -0
  3125. package/dist/providers/cli-registry.d.ts.map +1 -0
  3126. package/dist/providers/cli-registry.js +217 -0
  3127. package/dist/providers/cli-registry.js.map +1 -0
  3128. package/dist/providers/cloud-offload/adapter.d.ts +118 -0
  3129. package/dist/providers/cloud-offload/adapter.d.ts.map +1 -0
  3130. package/dist/providers/cloud-offload/adapter.js +61 -0
  3131. package/dist/providers/cloud-offload/adapter.js.map +1 -0
  3132. package/dist/providers/cloud-offload/anthropic-managed.d.ts +169 -0
  3133. package/dist/providers/cloud-offload/anthropic-managed.d.ts.map +1 -0
  3134. package/dist/providers/cloud-offload/anthropic-managed.js +627 -0
  3135. package/dist/providers/cloud-offload/anthropic-managed.js.map +1 -0
  3136. package/dist/providers/cloud-offload/cloudflare-agents.d.ts +174 -0
  3137. package/dist/providers/cloud-offload/cloudflare-agents.d.ts.map +1 -0
  3138. package/dist/providers/cloud-offload/cloudflare-agents.js +583 -0
  3139. package/dist/providers/cloud-offload/cloudflare-agents.js.map +1 -0
  3140. package/dist/providers/cloud-offload/fly-sprites.d.ts +147 -0
  3141. package/dist/providers/cloud-offload/fly-sprites.d.ts.map +1 -0
  3142. package/dist/providers/cloud-offload/fly-sprites.js +563 -0
  3143. package/dist/providers/cloud-offload/fly-sprites.js.map +1 -0
  3144. package/dist/providers/cloud-offload/session-handle.d.ts +62 -0
  3145. package/dist/providers/cloud-offload/session-handle.d.ts.map +1 -0
  3146. package/dist/providers/cloud-offload/session-handle.js +109 -0
  3147. package/dist/providers/cloud-offload/session-handle.js.map +1 -0
  3148. package/dist/providers/cloud-offload/snapshot.d.ts +97 -0
  3149. package/dist/providers/cloud-offload/snapshot.d.ts.map +1 -0
  3150. package/dist/providers/cloud-offload/snapshot.js +303 -0
  3151. package/dist/providers/cloud-offload/snapshot.js.map +1 -0
  3152. package/dist/providers/codex-adapter.d.ts +25 -0
  3153. package/dist/providers/codex-adapter.d.ts.map +1 -0
  3154. package/dist/providers/codex-adapter.js +493 -0
  3155. package/dist/providers/codex-adapter.js.map +1 -0
  3156. package/dist/providers/codex-detector.d.ts +73 -0
  3157. package/dist/providers/codex-detector.d.ts.map +1 -0
  3158. package/dist/providers/codex-detector.js +162 -0
  3159. package/dist/providers/codex-detector.js.map +1 -0
  3160. package/dist/providers/codex-models.d.ts +117 -0
  3161. package/dist/providers/codex-models.d.ts.map +1 -0
  3162. package/dist/providers/codex-models.js +398 -0
  3163. package/dist/providers/codex-models.js.map +1 -0
  3164. package/dist/providers/copilot-adapter.d.ts +40 -0
  3165. package/dist/providers/copilot-adapter.d.ts.map +1 -0
  3166. package/dist/providers/copilot-adapter.js +512 -0
  3167. package/dist/providers/copilot-adapter.js.map +1 -0
  3168. package/dist/providers/credential-pool.d.ts +247 -0
  3169. package/dist/providers/credential-pool.d.ts.map +1 -0
  3170. package/dist/providers/credential-pool.js +577 -0
  3171. package/dist/providers/credential-pool.js.map +1 -0
  3172. package/dist/providers/discovery.d.ts +103 -0
  3173. package/dist/providers/discovery.d.ts.map +1 -0
  3174. package/dist/providers/discovery.js +601 -0
  3175. package/dist/providers/discovery.js.map +1 -0
  3176. package/dist/providers/dynamic-discovery.d.ts +35 -0
  3177. package/dist/providers/dynamic-discovery.d.ts.map +1 -0
  3178. package/dist/providers/dynamic-discovery.js +240 -0
  3179. package/dist/providers/dynamic-discovery.js.map +1 -0
  3180. package/dist/providers/extended-thinking.d.ts +69 -0
  3181. package/dist/providers/extended-thinking.d.ts.map +1 -0
  3182. package/dist/providers/extended-thinking.js +233 -0
  3183. package/dist/providers/extended-thinking.js.map +1 -0
  3184. package/dist/providers/fallback-chain.d.ts +34 -0
  3185. package/dist/providers/fallback-chain.d.ts.map +1 -0
  3186. package/dist/providers/fallback-chain.js +116 -0
  3187. package/dist/providers/fallback-chain.js.map +1 -0
  3188. package/dist/providers/format-translator.d.ts +115 -0
  3189. package/dist/providers/format-translator.d.ts.map +1 -0
  3190. package/dist/providers/format-translator.js +347 -0
  3191. package/dist/providers/format-translator.js.map +1 -0
  3192. package/dist/providers/gemini-native-adapter.d.ts +51 -0
  3193. package/dist/providers/gemini-native-adapter.d.ts.map +1 -0
  3194. package/dist/providers/gemini-native-adapter.js +505 -0
  3195. package/dist/providers/gemini-native-adapter.js.map +1 -0
  3196. package/dist/providers/harness-profiles.d.ts +70 -0
  3197. package/dist/providers/harness-profiles.d.ts.map +1 -0
  3198. package/dist/providers/harness-profiles.js +210 -0
  3199. package/dist/providers/harness-profiles.js.map +1 -0
  3200. package/dist/providers/header-injection.d.ts +24 -0
  3201. package/dist/providers/header-injection.d.ts.map +1 -0
  3202. package/dist/providers/header-injection.js +109 -0
  3203. package/dist/providers/header-injection.js.map +1 -0
  3204. package/dist/providers/health-check.d.ts +80 -0
  3205. package/dist/providers/health-check.d.ts.map +1 -0
  3206. package/dist/providers/health-check.js +465 -0
  3207. package/dist/providers/health-check.js.map +1 -0
  3208. package/dist/providers/model-defaults.d.ts +60 -0
  3209. package/dist/providers/model-defaults.d.ts.map +1 -0
  3210. package/dist/providers/model-defaults.js +257 -0
  3211. package/dist/providers/model-defaults.js.map +1 -0
  3212. package/dist/providers/model-discovery.d.ts +85 -0
  3213. package/dist/providers/model-discovery.d.ts.map +1 -0
  3214. package/dist/providers/model-discovery.js +325 -0
  3215. package/dist/providers/model-discovery.js.map +1 -0
  3216. package/dist/providers/model-performance.d.ts +30 -0
  3217. package/dist/providers/model-performance.d.ts.map +1 -0
  3218. package/dist/providers/model-performance.js +57 -0
  3219. package/dist/providers/model-performance.js.map +1 -0
  3220. package/dist/providers/model-router.d.ts +119 -0
  3221. package/dist/providers/model-router.d.ts.map +1 -0
  3222. package/dist/providers/model-router.js +550 -0
  3223. package/dist/providers/model-router.js.map +1 -0
  3224. package/dist/providers/model-switcher.d.ts +116 -0
  3225. package/dist/providers/model-switcher.d.ts.map +1 -0
  3226. package/dist/providers/model-switcher.js +298 -0
  3227. package/dist/providers/model-switcher.js.map +1 -0
  3228. package/dist/providers/ollama-adapter.d.ts +66 -0
  3229. package/dist/providers/ollama-adapter.d.ts.map +1 -0
  3230. package/dist/providers/ollama-adapter.js +423 -0
  3231. package/dist/providers/ollama-adapter.js.map +1 -0
  3232. package/dist/providers/ollama-host.d.ts +66 -0
  3233. package/dist/providers/ollama-host.d.ts.map +1 -0
  3234. package/dist/providers/ollama-host.js +90 -0
  3235. package/dist/providers/ollama-host.js.map +1 -0
  3236. package/dist/providers/openai-compat-adapter.d.ts +20 -0
  3237. package/dist/providers/openai-compat-adapter.d.ts.map +1 -0
  3238. package/dist/providers/openai-compat-adapter.js +513 -0
  3239. package/dist/providers/openai-compat-adapter.js.map +1 -0
  3240. package/dist/providers/opencode-sst-adapter.d.ts +131 -0
  3241. package/dist/providers/opencode-sst-adapter.d.ts.map +1 -0
  3242. package/dist/providers/opencode-sst-adapter.js +385 -0
  3243. package/dist/providers/opencode-sst-adapter.js.map +1 -0
  3244. package/dist/providers/peer-tool-auth.d.ts +87 -0
  3245. package/dist/providers/peer-tool-auth.d.ts.map +1 -0
  3246. package/dist/providers/peer-tool-auth.js +254 -0
  3247. package/dist/providers/peer-tool-auth.js.map +1 -0
  3248. package/dist/providers/preset-library.d.ts +55 -0
  3249. package/dist/providers/preset-library.d.ts.map +1 -0
  3250. package/dist/providers/preset-library.js +299 -0
  3251. package/dist/providers/preset-library.js.map +1 -0
  3252. package/dist/providers/prompt-cache-warmup.d.ts +139 -0
  3253. package/dist/providers/prompt-cache-warmup.d.ts.map +1 -0
  3254. package/dist/providers/prompt-cache-warmup.js +233 -0
  3255. package/dist/providers/prompt-cache-warmup.js.map +1 -0
  3256. package/dist/providers/provider-brain.d.ts +79 -0
  3257. package/dist/providers/provider-brain.d.ts.map +1 -0
  3258. package/dist/providers/provider-brain.js +208 -0
  3259. package/dist/providers/provider-brain.js.map +1 -0
  3260. package/dist/providers/provider-ladder.d.ts +100 -0
  3261. package/dist/providers/provider-ladder.d.ts.map +1 -0
  3262. package/dist/providers/provider-ladder.js +220 -0
  3263. package/dist/providers/provider-ladder.js.map +1 -0
  3264. package/dist/providers/provider-service.d.ts +340 -0
  3265. package/dist/providers/provider-service.d.ts.map +1 -0
  3266. package/dist/providers/provider-service.js +1270 -0
  3267. package/dist/providers/provider-service.js.map +1 -0
  3268. package/dist/providers/public-tier/fallback-chain.d.ts +58 -0
  3269. package/dist/providers/public-tier/fallback-chain.d.ts.map +1 -0
  3270. package/dist/providers/public-tier/fallback-chain.js +160 -0
  3271. package/dist/providers/public-tier/fallback-chain.js.map +1 -0
  3272. package/dist/providers/public-tier/horde.d.ts +42 -0
  3273. package/dist/providers/public-tier/horde.d.ts.map +1 -0
  3274. package/dist/providers/public-tier/horde.js +203 -0
  3275. package/dist/providers/public-tier/horde.js.map +1 -0
  3276. package/dist/providers/public-tier/huggingface-free.d.ts +55 -0
  3277. package/dist/providers/public-tier/huggingface-free.d.ts.map +1 -0
  3278. package/dist/providers/public-tier/huggingface-free.js +85 -0
  3279. package/dist/providers/public-tier/huggingface-free.js.map +1 -0
  3280. package/dist/providers/public-tier/llm7.d.ts +48 -0
  3281. package/dist/providers/public-tier/llm7.d.ts.map +1 -0
  3282. package/dist/providers/public-tier/llm7.js +197 -0
  3283. package/dist/providers/public-tier/llm7.js.map +1 -0
  3284. package/dist/providers/public-tier/opencode-zen-research.d.ts +59 -0
  3285. package/dist/providers/public-tier/opencode-zen-research.d.ts.map +1 -0
  3286. package/dist/providers/public-tier/opencode-zen-research.js +57 -0
  3287. package/dist/providers/public-tier/opencode-zen-research.js.map +1 -0
  3288. package/dist/providers/public-tier/ovhcloud.d.ts +57 -0
  3289. package/dist/providers/public-tier/ovhcloud.d.ts.map +1 -0
  3290. package/dist/providers/public-tier/ovhcloud.js +210 -0
  3291. package/dist/providers/public-tier/ovhcloud.js.map +1 -0
  3292. package/dist/providers/public-tier/pollinations.d.ts +60 -0
  3293. package/dist/providers/public-tier/pollinations.d.ts.map +1 -0
  3294. package/dist/providers/public-tier/pollinations.js +252 -0
  3295. package/dist/providers/public-tier/pollinations.js.map +1 -0
  3296. package/dist/providers/rate-limiter.d.ts +55 -0
  3297. package/dist/providers/rate-limiter.d.ts.map +1 -0
  3298. package/dist/providers/rate-limiter.js +141 -0
  3299. package/dist/providers/rate-limiter.js.map +1 -0
  3300. package/dist/providers/registry.d.ts +19 -0
  3301. package/dist/providers/registry.d.ts.map +1 -0
  3302. package/dist/providers/registry.js +315 -0
  3303. package/dist/providers/registry.js.map +1 -0
  3304. package/dist/providers/retry-strategies.d.ts +78 -0
  3305. package/dist/providers/retry-strategies.d.ts.map +1 -0
  3306. package/dist/providers/retry-strategies.js +161 -0
  3307. package/dist/providers/retry-strategies.js.map +1 -0
  3308. package/dist/providers/thinking-preserver.d.ts +74 -0
  3309. package/dist/providers/thinking-preserver.d.ts.map +1 -0
  3310. package/dist/providers/thinking-preserver.js +109 -0
  3311. package/dist/providers/thinking-preserver.js.map +1 -0
  3312. package/dist/providers/tool-parsers/index.d.ts +7 -0
  3313. package/dist/providers/tool-parsers/index.d.ts.map +1 -0
  3314. package/dist/providers/tool-parsers/index.js +7 -0
  3315. package/dist/providers/tool-parsers/index.js.map +1 -0
  3316. package/dist/providers/tool-parsers/parsers.d.ts +78 -0
  3317. package/dist/providers/tool-parsers/parsers.d.ts.map +1 -0
  3318. package/dist/providers/tool-parsers/parsers.js +622 -0
  3319. package/dist/providers/tool-parsers/parsers.js.map +1 -0
  3320. package/dist/providers/tool-serializer.d.ts +221 -0
  3321. package/dist/providers/tool-serializer.d.ts.map +1 -0
  3322. package/dist/providers/tool-serializer.js +335 -0
  3323. package/dist/providers/tool-serializer.js.map +1 -0
  3324. package/dist/providers/types.d.ts +181 -0
  3325. package/dist/providers/types.d.ts.map +1 -0
  3326. package/dist/providers/types.js +5 -0
  3327. package/dist/providers/types.js.map +1 -0
  3328. package/dist/providers/usage-intelligence.d.ts +50 -0
  3329. package/dist/providers/usage-intelligence.d.ts.map +1 -0
  3330. package/dist/providers/usage-intelligence.js +146 -0
  3331. package/dist/providers/usage-intelligence.js.map +1 -0
  3332. package/dist/providers/vertex-oauth.d.ts +21 -0
  3333. package/dist/providers/vertex-oauth.d.ts.map +1 -0
  3334. package/dist/providers/vertex-oauth.js +393 -0
  3335. package/dist/providers/vertex-oauth.js.map +1 -0
  3336. package/dist/rag/chunker.d.ts +42 -0
  3337. package/dist/rag/chunker.d.ts.map +1 -0
  3338. package/dist/rag/chunker.js +247 -0
  3339. package/dist/rag/chunker.js.map +1 -0
  3340. package/dist/rag/reranker.d.ts +59 -0
  3341. package/dist/rag/reranker.d.ts.map +1 -0
  3342. package/dist/rag/reranker.js +79 -0
  3343. package/dist/rag/reranker.js.map +1 -0
  3344. package/dist/rag/visual-flow.d.ts +66 -0
  3345. package/dist/rag/visual-flow.d.ts.map +1 -0
  3346. package/dist/rag/visual-flow.js +203 -0
  3347. package/dist/rag/visual-flow.js.map +1 -0
  3348. package/dist/recipes/recipe-loader.d.ts +37 -0
  3349. package/dist/recipes/recipe-loader.d.ts.map +1 -0
  3350. package/dist/recipes/recipe-loader.js +434 -0
  3351. package/dist/recipes/recipe-loader.js.map +1 -0
  3352. package/dist/recipes/recipe-runtime.d.ts +33 -0
  3353. package/dist/recipes/recipe-runtime.d.ts.map +1 -0
  3354. package/dist/recipes/recipe-runtime.js +349 -0
  3355. package/dist/recipes/recipe-runtime.js.map +1 -0
  3356. package/dist/recipes/recipe-types.d.ts +178 -0
  3357. package/dist/recipes/recipe-types.d.ts.map +1 -0
  3358. package/dist/recipes/recipe-types.js +19 -0
  3359. package/dist/recipes/recipe-types.js.map +1 -0
  3360. package/dist/runtime-hooks/dead-code-hooks.d.ts +201 -0
  3361. package/dist/runtime-hooks/dead-code-hooks.d.ts.map +1 -0
  3362. package/dist/runtime-hooks/dead-code-hooks.js +176 -0
  3363. package/dist/runtime-hooks/dead-code-hooks.js.map +1 -0
  3364. package/dist/sandbox/approval-rules.d.ts +107 -0
  3365. package/dist/sandbox/approval-rules.d.ts.map +1 -0
  3366. package/dist/sandbox/approval-rules.js +253 -0
  3367. package/dist/sandbox/approval-rules.js.map +1 -0
  3368. package/dist/sandbox/backends/cloud-auth.d.ts +50 -0
  3369. package/dist/sandbox/backends/cloud-auth.d.ts.map +1 -0
  3370. package/dist/sandbox/backends/cloud-auth.js +93 -0
  3371. package/dist/sandbox/backends/cloud-auth.js.map +1 -0
  3372. package/dist/sandbox/backends/landlock-linux.d.ts +44 -0
  3373. package/dist/sandbox/backends/landlock-linux.d.ts.map +1 -0
  3374. package/dist/sandbox/backends/landlock-linux.js +284 -0
  3375. package/dist/sandbox/backends/landlock-linux.js.map +1 -0
  3376. package/dist/sandbox/backends/seatbelt-macos.d.ts +31 -0
  3377. package/dist/sandbox/backends/seatbelt-macos.d.ts.map +1 -0
  3378. package/dist/sandbox/backends/seatbelt-macos.js +248 -0
  3379. package/dist/sandbox/backends/seatbelt-macos.js.map +1 -0
  3380. package/dist/sandbox/backends/windows-jobobject.d.ts +92 -0
  3381. package/dist/sandbox/backends/windows-jobobject.d.ts.map +1 -0
  3382. package/dist/sandbox/backends/windows-jobobject.js +158 -0
  3383. package/dist/sandbox/backends/windows-jobobject.js.map +1 -0
  3384. package/dist/sandbox/cloud-sandbox-types.d.ts +48 -0
  3385. package/dist/sandbox/cloud-sandbox-types.d.ts.map +1 -0
  3386. package/dist/sandbox/cloud-sandbox-types.js +9 -0
  3387. package/dist/sandbox/cloud-sandbox-types.js.map +1 -0
  3388. package/dist/sandbox/composite-backend.d.ts +61 -0
  3389. package/dist/sandbox/composite-backend.d.ts.map +1 -0
  3390. package/dist/sandbox/composite-backend.js +145 -0
  3391. package/dist/sandbox/composite-backend.js.map +1 -0
  3392. package/dist/sandbox/docker-backend.d.ts +184 -0
  3393. package/dist/sandbox/docker-backend.d.ts.map +1 -0
  3394. package/dist/sandbox/docker-backend.js +457 -0
  3395. package/dist/sandbox/docker-backend.js.map +1 -0
  3396. package/dist/sandbox/execution-environments.d.ts +77 -0
  3397. package/dist/sandbox/execution-environments.d.ts.map +1 -0
  3398. package/dist/sandbox/execution-environments.js +183 -0
  3399. package/dist/sandbox/execution-environments.js.map +1 -0
  3400. package/dist/sandbox/executor.d.ts +35 -0
  3401. package/dist/sandbox/executor.d.ts.map +1 -0
  3402. package/dist/sandbox/executor.js +120 -0
  3403. package/dist/sandbox/executor.js.map +1 -0
  3404. package/dist/sandbox/extended-backends.d.ts +58 -0
  3405. package/dist/sandbox/extended-backends.d.ts.map +1 -0
  3406. package/dist/sandbox/extended-backends.js +199 -0
  3407. package/dist/sandbox/extended-backends.js.map +1 -0
  3408. package/dist/sandbox/flyio-backend.d.ts +22 -0
  3409. package/dist/sandbox/flyio-backend.d.ts.map +1 -0
  3410. package/dist/sandbox/flyio-backend.js +119 -0
  3411. package/dist/sandbox/flyio-backend.js.map +1 -0
  3412. package/dist/sandbox/kernel-sandbox.d.ts +91 -0
  3413. package/dist/sandbox/kernel-sandbox.d.ts.map +1 -0
  3414. package/dist/sandbox/kernel-sandbox.js +260 -0
  3415. package/dist/sandbox/kernel-sandbox.js.map +1 -0
  3416. package/dist/sandbox/modal-backend.d.ts +15 -0
  3417. package/dist/sandbox/modal-backend.d.ts.map +1 -0
  3418. package/dist/sandbox/modal-backend.js +110 -0
  3419. package/dist/sandbox/modal-backend.js.map +1 -0
  3420. package/dist/sandbox/no-change-timeout.d.ts +81 -0
  3421. package/dist/sandbox/no-change-timeout.d.ts.map +1 -0
  3422. package/dist/sandbox/no-change-timeout.js +105 -0
  3423. package/dist/sandbox/no-change-timeout.js.map +1 -0
  3424. package/dist/sandbox/output-isolator.d.ts +104 -0
  3425. package/dist/sandbox/output-isolator.d.ts.map +1 -0
  3426. package/dist/sandbox/output-isolator.js +220 -0
  3427. package/dist/sandbox/output-isolator.js.map +1 -0
  3428. package/dist/sandbox/request-rule.d.ts +105 -0
  3429. package/dist/sandbox/request-rule.d.ts.map +1 -0
  3430. package/dist/sandbox/request-rule.js +328 -0
  3431. package/dist/sandbox/request-rule.js.map +1 -0
  3432. package/dist/sandbox/sandbox-policy.d.ts +147 -0
  3433. package/dist/sandbox/sandbox-policy.d.ts.map +1 -0
  3434. package/dist/sandbox/sandbox-policy.js +156 -0
  3435. package/dist/sandbox/sandbox-policy.js.map +1 -0
  3436. package/dist/sandbox/security.d.ts +98 -0
  3437. package/dist/sandbox/security.d.ts.map +1 -0
  3438. package/dist/sandbox/security.js +449 -0
  3439. package/dist/sandbox/security.js.map +1 -0
  3440. package/dist/sandbox/task-isolation.d.ts +86 -0
  3441. package/dist/sandbox/task-isolation.d.ts.map +1 -0
  3442. package/dist/sandbox/task-isolation.js +240 -0
  3443. package/dist/sandbox/task-isolation.js.map +1 -0
  3444. package/dist/sandbox/terminal-backends.d.ts +189 -0
  3445. package/dist/sandbox/terminal-backends.d.ts.map +1 -0
  3446. package/dist/sandbox/terminal-backends.js +699 -0
  3447. package/dist/sandbox/terminal-backends.js.map +1 -0
  3448. package/dist/sandbox/unified-exec.d.ts +127 -0
  3449. package/dist/sandbox/unified-exec.d.ts.map +1 -0
  3450. package/dist/sandbox/unified-exec.js +446 -0
  3451. package/dist/sandbox/unified-exec.js.map +1 -0
  3452. package/dist/sandbox/virtual-paths.d.ts +91 -0
  3453. package/dist/sandbox/virtual-paths.d.ts.map +1 -0
  3454. package/dist/sandbox/virtual-paths.js +213 -0
  3455. package/dist/sandbox/virtual-paths.js.map +1 -0
  3456. package/dist/scheduler/cron-scheduler.d.ts +204 -0
  3457. package/dist/scheduler/cron-scheduler.d.ts.map +1 -0
  3458. package/dist/scheduler/cron-scheduler.js +423 -0
  3459. package/dist/scheduler/cron-scheduler.js.map +1 -0
  3460. package/dist/scheduler/schedule-store.d.ts +135 -0
  3461. package/dist/scheduler/schedule-store.d.ts.map +1 -0
  3462. package/dist/scheduler/schedule-store.js +293 -0
  3463. package/dist/scheduler/schedule-store.js.map +1 -0
  3464. package/dist/search/warp-grep.d.ts +127 -0
  3465. package/dist/search/warp-grep.d.ts.map +1 -0
  3466. package/dist/search/warp-grep.js +306 -0
  3467. package/dist/search/warp-grep.js.map +1 -0
  3468. package/dist/security/anti-distillation.d.ts +46 -0
  3469. package/dist/security/anti-distillation.d.ts.map +1 -0
  3470. package/dist/security/anti-distillation.js +358 -0
  3471. package/dist/security/anti-distillation.js.map +1 -0
  3472. package/dist/security/archive-preflight.d.ts +31 -0
  3473. package/dist/security/archive-preflight.d.ts.map +1 -0
  3474. package/dist/security/archive-preflight.js +200 -0
  3475. package/dist/security/archive-preflight.js.map +1 -0
  3476. package/dist/security/auto-classifier.d.ts +76 -0
  3477. package/dist/security/auto-classifier.d.ts.map +1 -0
  3478. package/dist/security/auto-classifier.js +319 -0
  3479. package/dist/security/auto-classifier.js.map +1 -0
  3480. package/dist/security/command-sanitizer.d.ts +93 -0
  3481. package/dist/security/command-sanitizer.d.ts.map +1 -0
  3482. package/dist/security/command-sanitizer.js +442 -0
  3483. package/dist/security/command-sanitizer.js.map +1 -0
  3484. package/dist/security/confirm-action.d.ts +70 -0
  3485. package/dist/security/confirm-action.d.ts.map +1 -0
  3486. package/dist/security/confirm-action.js +216 -0
  3487. package/dist/security/confirm-action.js.map +1 -0
  3488. package/dist/security/file-freeze.d.ts +86 -0
  3489. package/dist/security/file-freeze.d.ts.map +1 -0
  3490. package/dist/security/file-freeze.js +213 -0
  3491. package/dist/security/file-freeze.js.map +1 -0
  3492. package/dist/security/file-type-validator.d.ts +37 -0
  3493. package/dist/security/file-type-validator.d.ts.map +1 -0
  3494. package/dist/security/file-type-validator.js +176 -0
  3495. package/dist/security/file-type-validator.js.map +1 -0
  3496. package/dist/security/guardrails-off.d.ts +244 -0
  3497. package/dist/security/guardrails-off.d.ts.map +1 -0
  3498. package/dist/security/guardrails-off.js +592 -0
  3499. package/dist/security/guardrails-off.js.map +1 -0
  3500. package/dist/security/hash-audit-chain.d.ts +98 -0
  3501. package/dist/security/hash-audit-chain.d.ts.map +1 -0
  3502. package/dist/security/hash-audit-chain.js +198 -0
  3503. package/dist/security/hash-audit-chain.js.map +1 -0
  3504. package/dist/security/hidden-text-detector.d.ts +112 -0
  3505. package/dist/security/hidden-text-detector.d.ts.map +1 -0
  3506. package/dist/security/hidden-text-detector.js +258 -0
  3507. package/dist/security/hidden-text-detector.js.map +1 -0
  3508. package/dist/security/human-approval.d.ts +92 -0
  3509. package/dist/security/human-approval.d.ts.map +1 -0
  3510. package/dist/security/human-approval.js +199 -0
  3511. package/dist/security/human-approval.js.map +1 -0
  3512. package/dist/security/intent-verifier.d.ts +97 -0
  3513. package/dist/security/intent-verifier.d.ts.map +1 -0
  3514. package/dist/security/intent-verifier.js +250 -0
  3515. package/dist/security/intent-verifier.js.map +1 -0
  3516. package/dist/security/multi-encoding-decoder.d.ts +47 -0
  3517. package/dist/security/multi-encoding-decoder.d.ts.map +1 -0
  3518. package/dist/security/multi-encoding-decoder.js +336 -0
  3519. package/dist/security/multi-encoding-decoder.js.map +1 -0
  3520. package/dist/security/origin-validator.d.ts +52 -0
  3521. package/dist/security/origin-validator.d.ts.map +1 -0
  3522. package/dist/security/origin-validator.js +135 -0
  3523. package/dist/security/origin-validator.js.map +1 -0
  3524. package/dist/security/pii-redactor.d.ts +60 -0
  3525. package/dist/security/pii-redactor.d.ts.map +1 -0
  3526. package/dist/security/pii-redactor.js +364 -0
  3527. package/dist/security/pii-redactor.js.map +1 -0
  3528. package/dist/security/plugin-scanner.d.ts +103 -0
  3529. package/dist/security/plugin-scanner.d.ts.map +1 -0
  3530. package/dist/security/plugin-scanner.js +241 -0
  3531. package/dist/security/plugin-scanner.js.map +1 -0
  3532. package/dist/security/policy-language.d.ts +47 -0
  3533. package/dist/security/policy-language.d.ts.map +1 -0
  3534. package/dist/security/policy-language.js +103 -0
  3535. package/dist/security/policy-language.js.map +1 -0
  3536. package/dist/security/privacy-router.d.ts +129 -0
  3537. package/dist/security/privacy-router.d.ts.map +1 -0
  3538. package/dist/security/privacy-router.js +344 -0
  3539. package/dist/security/privacy-router.js.map +1 -0
  3540. package/dist/security/private-mode.d.ts +48 -0
  3541. package/dist/security/private-mode.d.ts.map +1 -0
  3542. package/dist/security/private-mode.js +80 -0
  3543. package/dist/security/private-mode.js.map +1 -0
  3544. package/dist/security/prompt-injection-quarantine.d.ts +181 -0
  3545. package/dist/security/prompt-injection-quarantine.d.ts.map +1 -0
  3546. package/dist/security/prompt-injection-quarantine.js +279 -0
  3547. package/dist/security/prompt-injection-quarantine.js.map +1 -0
  3548. package/dist/security/prompt-quarantine.d.ts +50 -0
  3549. package/dist/security/prompt-quarantine.d.ts.map +1 -0
  3550. package/dist/security/prompt-quarantine.js +61 -0
  3551. package/dist/security/prompt-quarantine.js.map +1 -0
  3552. package/dist/security/recon-osint/username-search.d.ts +48 -0
  3553. package/dist/security/recon-osint/username-search.d.ts.map +1 -0
  3554. package/dist/security/recon-osint/username-search.js +88 -0
  3555. package/dist/security/recon-osint/username-search.js.map +1 -0
  3556. package/dist/security/redact-overlapping-spans.d.ts +87 -0
  3557. package/dist/security/redact-overlapping-spans.d.ts.map +1 -0
  3558. package/dist/security/redact-overlapping-spans.js +159 -0
  3559. package/dist/security/redact-overlapping-spans.js.map +1 -0
  3560. package/dist/security/rules-of-engagement.d.ts +94 -0
  3561. package/dist/security/rules-of-engagement.d.ts.map +1 -0
  3562. package/dist/security/rules-of-engagement.js +290 -0
  3563. package/dist/security/rules-of-engagement.js.map +1 -0
  3564. package/dist/security/secret-scanner.d.ts +81 -0
  3565. package/dist/security/secret-scanner.d.ts.map +1 -0
  3566. package/dist/security/secret-scanner.js +336 -0
  3567. package/dist/security/secret-scanner.js.map +1 -0
  3568. package/dist/security/signed-audit.d.ts +50 -0
  3569. package/dist/security/signed-audit.d.ts.map +1 -0
  3570. package/dist/security/signed-audit.js +110 -0
  3571. package/dist/security/signed-audit.js.map +1 -0
  3572. package/dist/security/skills-guard.d.ts +74 -0
  3573. package/dist/security/skills-guard.d.ts.map +1 -0
  3574. package/dist/security/skills-guard.js +367 -0
  3575. package/dist/security/skills-guard.js.map +1 -0
  3576. package/dist/security/ssrf-guard.d.ts +70 -0
  3577. package/dist/security/ssrf-guard.d.ts.map +1 -0
  3578. package/dist/security/ssrf-guard.js +275 -0
  3579. package/dist/security/ssrf-guard.js.map +1 -0
  3580. package/dist/security/url-instruction-guard.d.ts +80 -0
  3581. package/dist/security/url-instruction-guard.d.ts.map +1 -0
  3582. package/dist/security/url-instruction-guard.js +476 -0
  3583. package/dist/security/url-instruction-guard.js.map +1 -0
  3584. package/dist/security/write-audit.d.ts +52 -0
  3585. package/dist/security/write-audit.d.ts.map +1 -0
  3586. package/dist/security/write-audit.js +64 -0
  3587. package/dist/security/write-audit.js.map +1 -0
  3588. package/dist/session/approval-queue.d.ts +307 -0
  3589. package/dist/session/approval-queue.d.ts.map +1 -0
  3590. package/dist/session/approval-queue.js +469 -0
  3591. package/dist/session/approval-queue.js.map +1 -0
  3592. package/dist/session/carplay-dispatch.d.ts +259 -0
  3593. package/dist/session/carplay-dispatch.d.ts.map +1 -0
  3594. package/dist/session/carplay-dispatch.js +459 -0
  3595. package/dist/session/carplay-dispatch.js.map +1 -0
  3596. package/dist/session/computer-session-store.d.ts +332 -0
  3597. package/dist/session/computer-session-store.d.ts.map +1 -0
  3598. package/dist/session/computer-session-store.js +758 -0
  3599. package/dist/session/computer-session-store.js.map +1 -0
  3600. package/dist/session/creations.d.ts +328 -0
  3601. package/dist/session/creations.d.ts.map +1 -0
  3602. package/dist/session/creations.js +667 -0
  3603. package/dist/session/creations.js.map +1 -0
  3604. package/dist/session/cursor-stream.d.ts +191 -0
  3605. package/dist/session/cursor-stream.d.ts.map +1 -0
  3606. package/dist/session/cursor-stream.js +328 -0
  3607. package/dist/session/cursor-stream.js.map +1 -0
  3608. package/dist/session/dispatch/companion-bridge.d.ts +116 -0
  3609. package/dist/session/dispatch/companion-bridge.d.ts.map +1 -0
  3610. package/dist/session/dispatch/companion-bridge.js +213 -0
  3611. package/dist/session/dispatch/companion-bridge.js.map +1 -0
  3612. package/dist/session/file-delivery.d.ts +365 -0
  3613. package/dist/session/file-delivery.d.ts.map +1 -0
  3614. package/dist/session/file-delivery.js +557 -0
  3615. package/dist/session/file-delivery.js.map +1 -0
  3616. package/dist/session/file-get-handler.d.ts +236 -0
  3617. package/dist/session/file-get-handler.d.ts.map +1 -0
  3618. package/dist/session/file-get-handler.js +476 -0
  3619. package/dist/session/file-get-handler.js.map +1 -0
  3620. package/dist/session/fleet-view.d.ts +245 -0
  3621. package/dist/session/fleet-view.d.ts.map +1 -0
  3622. package/dist/session/fleet-view.js +422 -0
  3623. package/dist/session/fleet-view.js.map +1 -0
  3624. package/dist/session/live-activity.d.ts +312 -0
  3625. package/dist/session/live-activity.d.ts.map +1 -0
  3626. package/dist/session/live-activity.js +473 -0
  3627. package/dist/session/live-activity.js.map +1 -0
  3628. package/dist/session/session-handoff.d.ts +150 -0
  3629. package/dist/session/session-handoff.d.ts.map +1 -0
  3630. package/dist/session/session-handoff.js +223 -0
  3631. package/dist/session/session-handoff.js.map +1 -0
  3632. package/dist/session/surface-subscribers.d.ts +139 -0
  3633. package/dist/session/surface-subscribers.d.ts.map +1 -0
  3634. package/dist/session/surface-subscribers.js +206 -0
  3635. package/dist/session/surface-subscribers.js.map +1 -0
  3636. package/dist/session/voice-intent.d.ts +144 -0
  3637. package/dist/session/voice-intent.d.ts.map +1 -0
  3638. package/dist/session/voice-intent.js +211 -0
  3639. package/dist/session/voice-intent.js.map +1 -0
  3640. package/dist/session/watch-dispatch.d.ts +207 -0
  3641. package/dist/session/watch-dispatch.d.ts.map +1 -0
  3642. package/dist/session/watch-dispatch.js +399 -0
  3643. package/dist/session/watch-dispatch.js.map +1 -0
  3644. package/dist/skills/agentskills-registry.d.ts +102 -0
  3645. package/dist/skills/agentskills-registry.d.ts.map +1 -0
  3646. package/dist/skills/agentskills-registry.js +157 -0
  3647. package/dist/skills/agentskills-registry.js.map +1 -0
  3648. package/dist/skills/anthropic-imports/docx-writer.d.ts +59 -0
  3649. package/dist/skills/anthropic-imports/docx-writer.d.ts.map +1 -0
  3650. package/dist/skills/anthropic-imports/docx-writer.js +239 -0
  3651. package/dist/skills/anthropic-imports/docx-writer.js.map +1 -0
  3652. package/dist/skills/anthropic-imports/pdf-writer.d.ts +63 -0
  3653. package/dist/skills/anthropic-imports/pdf-writer.d.ts.map +1 -0
  3654. package/dist/skills/anthropic-imports/pdf-writer.js +277 -0
  3655. package/dist/skills/anthropic-imports/pdf-writer.js.map +1 -0
  3656. package/dist/skills/anthropic-imports/pptx-writer.d.ts +50 -0
  3657. package/dist/skills/anthropic-imports/pptx-writer.d.ts.map +1 -0
  3658. package/dist/skills/anthropic-imports/pptx-writer.js +334 -0
  3659. package/dist/skills/anthropic-imports/pptx-writer.js.map +1 -0
  3660. package/dist/skills/anthropic-imports/xlsx-writer.d.ts +63 -0
  3661. package/dist/skills/anthropic-imports/xlsx-writer.d.ts.map +1 -0
  3662. package/dist/skills/anthropic-imports/xlsx-writer.js +289 -0
  3663. package/dist/skills/anthropic-imports/xlsx-writer.js.map +1 -0
  3664. package/dist/skills/awesome-imports/entries-domains.d.ts +10 -0
  3665. package/dist/skills/awesome-imports/entries-domains.d.ts.map +1 -0
  3666. package/dist/skills/awesome-imports/entries-domains.js +137 -0
  3667. package/dist/skills/awesome-imports/entries-domains.js.map +1 -0
  3668. package/dist/skills/awesome-imports/entries-skills.d.ts +10 -0
  3669. package/dist/skills/awesome-imports/entries-skills.d.ts.map +1 -0
  3670. package/dist/skills/awesome-imports/entries-skills.js +145 -0
  3671. package/dist/skills/awesome-imports/entries-skills.js.map +1 -0
  3672. package/dist/skills/awesome-imports/entries.d.ts +13 -0
  3673. package/dist/skills/awesome-imports/entries.d.ts.map +1 -0
  3674. package/dist/skills/awesome-imports/entries.js +14 -0
  3675. package/dist/skills/awesome-imports/entries.js.map +1 -0
  3676. package/dist/skills/awesome-imports/index.d.ts +36 -0
  3677. package/dist/skills/awesome-imports/index.d.ts.map +1 -0
  3678. package/dist/skills/awesome-imports/index.js +53 -0
  3679. package/dist/skills/awesome-imports/index.js.map +1 -0
  3680. package/dist/skills/awesome-imports/types.d.ts +33 -0
  3681. package/dist/skills/awesome-imports/types.d.ts.map +1 -0
  3682. package/dist/skills/awesome-imports/types.js +9 -0
  3683. package/dist/skills/awesome-imports/types.js.map +1 -0
  3684. package/dist/skills/cli-anything.d.ts +75 -0
  3685. package/dist/skills/cli-anything.d.ts.map +1 -0
  3686. package/dist/skills/cli-anything.js +156 -0
  3687. package/dist/skills/cli-anything.js.map +1 -0
  3688. package/dist/skills/eval.d.ts +70 -0
  3689. package/dist/skills/eval.d.ts.map +1 -0
  3690. package/dist/skills/eval.js +178 -0
  3691. package/dist/skills/eval.js.map +1 -0
  3692. package/dist/skills/input-sanitizer.d.ts +25 -0
  3693. package/dist/skills/input-sanitizer.d.ts.map +1 -0
  3694. package/dist/skills/input-sanitizer.js +55 -0
  3695. package/dist/skills/input-sanitizer.js.map +1 -0
  3696. package/dist/skills/loader.d.ts +189 -0
  3697. package/dist/skills/loader.d.ts.map +1 -0
  3698. package/dist/skills/loader.js +839 -0
  3699. package/dist/skills/loader.js.map +1 -0
  3700. package/dist/skills/prompt-file-loader.d.ts +55 -0
  3701. package/dist/skills/prompt-file-loader.d.ts.map +1 -0
  3702. package/dist/skills/prompt-file-loader.js +94 -0
  3703. package/dist/skills/prompt-file-loader.js.map +1 -0
  3704. package/dist/skills/self-crystallization.d.ts +62 -0
  3705. package/dist/skills/self-crystallization.d.ts.map +1 -0
  3706. package/dist/skills/self-crystallization.js +143 -0
  3707. package/dist/skills/self-crystallization.js.map +1 -0
  3708. package/dist/skills/skill-compositor.d.ts +66 -0
  3709. package/dist/skills/skill-compositor.d.ts.map +1 -0
  3710. package/dist/skills/skill-compositor.js +143 -0
  3711. package/dist/skills/skill-compositor.js.map +1 -0
  3712. package/dist/skills/skill-merger.d.ts +104 -0
  3713. package/dist/skills/skill-merger.d.ts.map +1 -0
  3714. package/dist/skills/skill-merger.js +369 -0
  3715. package/dist/skills/skill-merger.js.map +1 -0
  3716. package/dist/skills/skill-optimizer.d.ts +83 -0
  3717. package/dist/skills/skill-optimizer.d.ts.map +1 -0
  3718. package/dist/skills/skill-optimizer.js +131 -0
  3719. package/dist/skills/skill-optimizer.js.map +1 -0
  3720. package/dist/skills/skill-source-adapter.d.ts +184 -0
  3721. package/dist/skills/skill-source-adapter.d.ts.map +1 -0
  3722. package/dist/skills/skill-source-adapter.js +0 -0
  3723. package/dist/skills/skill-source-adapter.js.map +1 -0
  3724. package/dist/skills/skill-standard.d.ts +78 -0
  3725. package/dist/skills/skill-standard.d.ts.map +1 -0
  3726. package/dist/skills/skill-standard.js +198 -0
  3727. package/dist/skills/skill-standard.js.map +1 -0
  3728. package/dist/skills/tool-rules-parser.d.ts +51 -0
  3729. package/dist/skills/tool-rules-parser.d.ts.map +1 -0
  3730. package/dist/skills/tool-rules-parser.js +168 -0
  3731. package/dist/skills/tool-rules-parser.js.map +1 -0
  3732. package/dist/skills/wotann-skills-registry.d.ts +88 -0
  3733. package/dist/skills/wotann-skills-registry.d.ts.map +1 -0
  3734. package/dist/skills/wotann-skills-registry.js +533 -0
  3735. package/dist/skills/wotann-skills-registry.js.map +1 -0
  3736. package/dist/snippets/snippet-store.d.ts +121 -0
  3737. package/dist/snippets/snippet-store.d.ts.map +1 -0
  3738. package/dist/snippets/snippet-store.js +267 -0
  3739. package/dist/snippets/snippet-store.js.map +1 -0
  3740. package/dist/sop/pipeline.d.ts +60 -0
  3741. package/dist/sop/pipeline.d.ts.map +1 -0
  3742. package/dist/sop/pipeline.js +214 -0
  3743. package/dist/sop/pipeline.js.map +1 -0
  3744. package/dist/sop/stages/code-generator.d.ts +22 -0
  3745. package/dist/sop/stages/code-generator.d.ts.map +1 -0
  3746. package/dist/sop/stages/code-generator.js +106 -0
  3747. package/dist/sop/stages/code-generator.js.map +1 -0
  3748. package/dist/sop/stages/design-writer.d.ts +21 -0
  3749. package/dist/sop/stages/design-writer.d.ts.map +1 -0
  3750. package/dist/sop/stages/design-writer.js +96 -0
  3751. package/dist/sop/stages/design-writer.js.map +1 -0
  3752. package/dist/sop/stages/prd-writer.d.ts +22 -0
  3753. package/dist/sop/stages/prd-writer.d.ts.map +1 -0
  3754. package/dist/sop/stages/prd-writer.js +88 -0
  3755. package/dist/sop/stages/prd-writer.js.map +1 -0
  3756. package/dist/sop/stages/qa.d.ts +64 -0
  3757. package/dist/sop/stages/qa.d.ts.map +1 -0
  3758. package/dist/sop/stages/qa.js +241 -0
  3759. package/dist/sop/stages/qa.js.map +1 -0
  3760. package/dist/sop/types.d.ts +94 -0
  3761. package/dist/sop/types.d.ts.map +1 -0
  3762. package/dist/sop/types.js +13 -0
  3763. package/dist/sop/types.js.map +1 -0
  3764. package/dist/storage/checkpoint-supersede.d.ts +78 -0
  3765. package/dist/storage/checkpoint-supersede.d.ts.map +1 -0
  3766. package/dist/storage/checkpoint-supersede.js +85 -0
  3767. package/dist/storage/checkpoint-supersede.js.map +1 -0
  3768. package/dist/storage/index.d.ts +80 -0
  3769. package/dist/storage/index.d.ts.map +1 -0
  3770. package/dist/storage/index.js +95 -0
  3771. package/dist/storage/index.js.map +1 -0
  3772. package/dist/storage/sqlite-better-backend.d.ts +64 -0
  3773. package/dist/storage/sqlite-better-backend.d.ts.map +1 -0
  3774. package/dist/storage/sqlite-better-backend.js +169 -0
  3775. package/dist/storage/sqlite-better-backend.js.map +1 -0
  3776. package/dist/storage/sqlite-node-backend.d.ts +69 -0
  3777. package/dist/storage/sqlite-node-backend.d.ts.map +1 -0
  3778. package/dist/storage/sqlite-node-backend.js +195 -0
  3779. package/dist/storage/sqlite-node-backend.js.map +1 -0
  3780. package/dist/storage/storage-adapter.d.ts +184 -0
  3781. package/dist/storage/storage-adapter.d.ts.map +1 -0
  3782. package/dist/storage/storage-adapter.js +62 -0
  3783. package/dist/storage/storage-adapter.js.map +1 -0
  3784. package/dist/telemetry/audit-trail.d.ts +124 -0
  3785. package/dist/telemetry/audit-trail.d.ts.map +1 -0
  3786. package/dist/telemetry/audit-trail.js +280 -0
  3787. package/dist/telemetry/audit-trail.js.map +1 -0
  3788. package/dist/telemetry/benchmarks.d.ts +65 -0
  3789. package/dist/telemetry/benchmarks.d.ts.map +1 -0
  3790. package/dist/telemetry/benchmarks.js +171 -0
  3791. package/dist/telemetry/benchmarks.js.map +1 -0
  3792. package/dist/telemetry/cost-oracle.d.ts +53 -0
  3793. package/dist/telemetry/cost-oracle.d.ts.map +1 -0
  3794. package/dist/telemetry/cost-oracle.js +206 -0
  3795. package/dist/telemetry/cost-oracle.js.map +1 -0
  3796. package/dist/telemetry/cost-tracker.d.ts +318 -0
  3797. package/dist/telemetry/cost-tracker.d.ts.map +1 -0
  3798. package/dist/telemetry/cost-tracker.js +887 -0
  3799. package/dist/telemetry/cost-tracker.js.map +1 -0
  3800. package/dist/telemetry/daily-cost-store.d.ts +43 -0
  3801. package/dist/telemetry/daily-cost-store.d.ts.map +1 -0
  3802. package/dist/telemetry/daily-cost-store.js +140 -0
  3803. package/dist/telemetry/daily-cost-store.js.map +1 -0
  3804. package/dist/telemetry/eval-observability.d.ts +105 -0
  3805. package/dist/telemetry/eval-observability.d.ts.map +1 -0
  3806. package/dist/telemetry/eval-observability.js +182 -0
  3807. package/dist/telemetry/eval-observability.js.map +1 -0
  3808. package/dist/telemetry/observability-export.d.ts +145 -0
  3809. package/dist/telemetry/observability-export.d.ts.map +1 -0
  3810. package/dist/telemetry/observability-export.js +339 -0
  3811. package/dist/telemetry/observability-export.js.map +1 -0
  3812. package/dist/telemetry/opt-out.d.ts +31 -0
  3813. package/dist/telemetry/opt-out.d.ts.map +1 -0
  3814. package/dist/telemetry/opt-out.js +58 -0
  3815. package/dist/telemetry/opt-out.js.map +1 -0
  3816. package/dist/telemetry/session-analytics.d.ts +94 -0
  3817. package/dist/telemetry/session-analytics.d.ts.map +1 -0
  3818. package/dist/telemetry/session-analytics.js +152 -0
  3819. package/dist/telemetry/session-analytics.js.map +1 -0
  3820. package/dist/telemetry/session-replay.d.ts +132 -0
  3821. package/dist/telemetry/session-replay.d.ts.map +1 -0
  3822. package/dist/telemetry/session-replay.js +245 -0
  3823. package/dist/telemetry/session-replay.js.map +1 -0
  3824. package/dist/telemetry/token-estimator.d.ts +72 -0
  3825. package/dist/telemetry/token-estimator.d.ts.map +1 -0
  3826. package/dist/telemetry/token-estimator.js +86 -0
  3827. package/dist/telemetry/token-estimator.js.map +1 -0
  3828. package/dist/telemetry/traceparent.d.ts +139 -0
  3829. package/dist/telemetry/traceparent.d.ts.map +1 -0
  3830. package/dist/telemetry/traceparent.js +249 -0
  3831. package/dist/telemetry/traceparent.js.map +1 -0
  3832. package/dist/telemetry/wotann-compute-unit.d.ts +82 -0
  3833. package/dist/telemetry/wotann-compute-unit.d.ts.map +1 -0
  3834. package/dist/telemetry/wotann-compute-unit.js +112 -0
  3835. package/dist/telemetry/wotann-compute-unit.js.map +1 -0
  3836. package/dist/testing/prompt-regression.d.ts +73 -0
  3837. package/dist/testing/prompt-regression.d.ts.map +1 -0
  3838. package/dist/testing/prompt-regression.js +170 -0
  3839. package/dist/testing/prompt-regression.js.map +1 -0
  3840. package/dist/testing/screen-aware.d.ts +55 -0
  3841. package/dist/testing/screen-aware.d.ts.map +1 -0
  3842. package/dist/testing/screen-aware.js +137 -0
  3843. package/dist/testing/screen-aware.js.map +1 -0
  3844. package/dist/testing/visual-diff-theater.d.ts +86 -0
  3845. package/dist/testing/visual-diff-theater.d.ts.map +1 -0
  3846. package/dist/testing/visual-diff-theater.js +262 -0
  3847. package/dist/testing/visual-diff-theater.js.map +1 -0
  3848. package/dist/testing/visual-verifier.d.ts +61 -0
  3849. package/dist/testing/visual-verifier.d.ts.map +1 -0
  3850. package/dist/testing/visual-verifier.js +201 -0
  3851. package/dist/testing/visual-verifier.js.map +1 -0
  3852. package/dist/tools/aux-tools.d.ts +39 -0
  3853. package/dist/tools/aux-tools.d.ts.map +1 -0
  3854. package/dist/tools/aux-tools.js +301 -0
  3855. package/dist/tools/aux-tools.js.map +1 -0
  3856. package/dist/tools/composio-adapter.d.ts +99 -0
  3857. package/dist/tools/composio-adapter.d.ts.map +1 -0
  3858. package/dist/tools/composio-adapter.js +140 -0
  3859. package/dist/tools/composio-adapter.js.map +1 -0
  3860. package/dist/tools/deep-research-loop.d.ts +91 -0
  3861. package/dist/tools/deep-research-loop.d.ts.map +1 -0
  3862. package/dist/tools/deep-research-loop.js +129 -0
  3863. package/dist/tools/deep-research-loop.js.map +1 -0
  3864. package/dist/tools/docx-processor.d.ts +54 -0
  3865. package/dist/tools/docx-processor.d.ts.map +1 -0
  3866. package/dist/tools/docx-processor.js +183 -0
  3867. package/dist/tools/docx-processor.js.map +1 -0
  3868. package/dist/tools/encoding-detector.d.ts +25 -0
  3869. package/dist/tools/encoding-detector.d.ts.map +1 -0
  3870. package/dist/tools/encoding-detector.js +147 -0
  3871. package/dist/tools/encoding-detector.js.map +1 -0
  3872. package/dist/tools/grep-subagent.d.ts +85 -0
  3873. package/dist/tools/grep-subagent.d.ts.map +1 -0
  3874. package/dist/tools/grep-subagent.js +414 -0
  3875. package/dist/tools/grep-subagent.js.map +1 -0
  3876. package/dist/tools/hash-anchored-edit.d.ts +100 -0
  3877. package/dist/tools/hash-anchored-edit.d.ts.map +1 -0
  3878. package/dist/tools/hash-anchored-edit.js +161 -0
  3879. package/dist/tools/hash-anchored-edit.js.map +1 -0
  3880. package/dist/tools/hashline-edit.d.ts +79 -0
  3881. package/dist/tools/hashline-edit.d.ts.map +1 -0
  3882. package/dist/tools/hashline-edit.js +174 -0
  3883. package/dist/tools/hashline-edit.js.map +1 -0
  3884. package/dist/tools/hashline-edits.d.ts +169 -0
  3885. package/dist/tools/hashline-edits.d.ts.map +1 -0
  3886. package/dist/tools/hashline-edits.js +594 -0
  3887. package/dist/tools/hashline-edits.js.map +1 -0
  3888. package/dist/tools/image-gen-router.d.ts +39 -0
  3889. package/dist/tools/image-gen-router.d.ts.map +1 -0
  3890. package/dist/tools/image-gen-router.js +288 -0
  3891. package/dist/tools/image-gen-router.js.map +1 -0
  3892. package/dist/tools/markitdown-bridge.d.ts +42 -0
  3893. package/dist/tools/markitdown-bridge.d.ts.map +1 -0
  3894. package/dist/tools/markitdown-bridge.js +249 -0
  3895. package/dist/tools/markitdown-bridge.js.map +1 -0
  3896. package/dist/tools/monitor-bg.d.ts +73 -0
  3897. package/dist/tools/monitor-bg.d.ts.map +1 -0
  3898. package/dist/tools/monitor-bg.js +275 -0
  3899. package/dist/tools/monitor-bg.js.map +1 -0
  3900. package/dist/tools/monitor.d.ts +58 -0
  3901. package/dist/tools/monitor.d.ts.map +1 -0
  3902. package/dist/tools/monitor.js +204 -0
  3903. package/dist/tools/monitor.js.map +1 -0
  3904. package/dist/tools/parallel-grep.d.ts +72 -0
  3905. package/dist/tools/parallel-grep.d.ts.map +1 -0
  3906. package/dist/tools/parallel-grep.js +154 -0
  3907. package/dist/tools/parallel-grep.js.map +1 -0
  3908. package/dist/tools/pdf-processor.d.ts +47 -0
  3909. package/dist/tools/pdf-processor.d.ts.map +1 -0
  3910. package/dist/tools/pdf-processor.js +214 -0
  3911. package/dist/tools/pdf-processor.js.map +1 -0
  3912. package/dist/tools/post-callback.d.ts +62 -0
  3913. package/dist/tools/post-callback.d.ts.map +1 -0
  3914. package/dist/tools/post-callback.js +153 -0
  3915. package/dist/tools/post-callback.js.map +1 -0
  3916. package/dist/tools/rtk-compressor.d.ts +59 -0
  3917. package/dist/tools/rtk-compressor.d.ts.map +1 -0
  3918. package/dist/tools/rtk-compressor.js +236 -0
  3919. package/dist/tools/rtk-compressor.js.map +1 -0
  3920. package/dist/tools/task-tool.d.ts +80 -0
  3921. package/dist/tools/task-tool.d.ts.map +1 -0
  3922. package/dist/tools/task-tool.js +309 -0
  3923. package/dist/tools/task-tool.js.map +1 -0
  3924. package/dist/tools/tool-timing.d.ts +99 -0
  3925. package/dist/tools/tool-timing.d.ts.map +1 -0
  3926. package/dist/tools/tool-timing.js +196 -0
  3927. package/dist/tools/tool-timing.js.map +1 -0
  3928. package/dist/tools/web-fetch.d.ts +116 -0
  3929. package/dist/tools/web-fetch.d.ts.map +1 -0
  3930. package/dist/tools/web-fetch.js +501 -0
  3931. package/dist/tools/web-fetch.js.map +1 -0
  3932. package/dist/tools/xlsx-processor.d.ts +57 -0
  3933. package/dist/tools/xlsx-processor.d.ts.map +1 -0
  3934. package/dist/tools/xlsx-processor.js +274 -0
  3935. package/dist/tools/xlsx-processor.js.map +1 -0
  3936. package/dist/training/autoresearch.d.ts +129 -0
  3937. package/dist/training/autoresearch.d.ts.map +1 -0
  3938. package/dist/training/autoresearch.js +307 -0
  3939. package/dist/training/autoresearch.js.map +1 -0
  3940. package/dist/training/llm-modification-generator.d.ts +45 -0
  3941. package/dist/training/llm-modification-generator.d.ts.map +1 -0
  3942. package/dist/training/llm-modification-generator.js +207 -0
  3943. package/dist/training/llm-modification-generator.js.map +1 -0
  3944. package/dist/training/pipeline.d.ts +120 -0
  3945. package/dist/training/pipeline.d.ts.map +1 -0
  3946. package/dist/training/pipeline.js +272 -0
  3947. package/dist/training/pipeline.js.map +1 -0
  3948. package/dist/training/rl-environment.d.ts +148 -0
  3949. package/dist/training/rl-environment.d.ts.map +1 -0
  3950. package/dist/training/rl-environment.js +264 -0
  3951. package/dist/training/rl-environment.js.map +1 -0
  3952. package/dist/training/session-extractor.d.ts +55 -0
  3953. package/dist/training/session-extractor.d.ts.map +1 -0
  3954. package/dist/training/session-extractor.js +177 -0
  3955. package/dist/training/session-extractor.js.map +1 -0
  3956. package/dist/training/trajectory-extractor.d.ts +83 -0
  3957. package/dist/training/trajectory-extractor.d.ts.map +1 -0
  3958. package/dist/training/trajectory-extractor.js +211 -0
  3959. package/dist/training/trajectory-extractor.js.map +1 -0
  3960. package/dist/ui/App.d.ts +24 -0
  3961. package/dist/ui/App.d.ts.map +1 -0
  3962. package/dist/ui/App.js +3248 -0
  3963. package/dist/ui/App.js.map +1 -0
  3964. package/dist/ui/accessibility.d.ts +157 -0
  3965. package/dist/ui/accessibility.d.ts.map +1 -0
  3966. package/dist/ui/accessibility.js +232 -0
  3967. package/dist/ui/accessibility.js.map +1 -0
  3968. package/dist/ui/agent-fleet-dashboard.d.ts +59 -0
  3969. package/dist/ui/agent-fleet-dashboard.d.ts.map +1 -0
  3970. package/dist/ui/agent-fleet-dashboard.js +143 -0
  3971. package/dist/ui/agent-fleet-dashboard.js.map +1 -0
  3972. package/dist/ui/alt-buffer.d.ts +73 -0
  3973. package/dist/ui/alt-buffer.d.ts.map +1 -0
  3974. package/dist/ui/alt-buffer.js +151 -0
  3975. package/dist/ui/alt-buffer.js.map +1 -0
  3976. package/dist/ui/animations/RavensFlight.d.ts +56 -0
  3977. package/dist/ui/animations/RavensFlight.d.ts.map +1 -0
  3978. package/dist/ui/animations/RavensFlight.js +103 -0
  3979. package/dist/ui/animations/RavensFlight.js.map +1 -0
  3980. package/dist/ui/animations/SigilStamp.d.ts +89 -0
  3981. package/dist/ui/animations/SigilStamp.d.ts.map +1 -0
  3982. package/dist/ui/animations/SigilStamp.js +142 -0
  3983. package/dist/ui/animations/SigilStamp.js.map +1 -0
  3984. package/dist/ui/animations.d.ts +102 -0
  3985. package/dist/ui/animations.d.ts.map +1 -0
  3986. package/dist/ui/animations.js +277 -0
  3987. package/dist/ui/animations.js.map +1 -0
  3988. package/dist/ui/bootstrap.d.ts +25 -0
  3989. package/dist/ui/bootstrap.d.ts.map +1 -0
  3990. package/dist/ui/bootstrap.js +51 -0
  3991. package/dist/ui/bootstrap.js.map +1 -0
  3992. package/dist/ui/canvas.d.ts +85 -0
  3993. package/dist/ui/canvas.d.ts.map +1 -0
  3994. package/dist/ui/canvas.js +210 -0
  3995. package/dist/ui/canvas.js.map +1 -0
  3996. package/dist/ui/command-registry.d.ts +64 -0
  3997. package/dist/ui/command-registry.d.ts.map +1 -0
  3998. package/dist/ui/command-registry.js +148 -0
  3999. package/dist/ui/command-registry.js.map +1 -0
  4000. package/dist/ui/components/AgentStatusPanel.d.ts +25 -0
  4001. package/dist/ui/components/AgentStatusPanel.d.ts.map +1 -0
  4002. package/dist/ui/components/AgentStatusPanel.js +32 -0
  4003. package/dist/ui/components/AgentStatusPanel.js.map +1 -0
  4004. package/dist/ui/components/AuditLogPanel.d.ts +22 -0
  4005. package/dist/ui/components/AuditLogPanel.d.ts.map +1 -0
  4006. package/dist/ui/components/AuditLogPanel.js +158 -0
  4007. package/dist/ui/components/AuditLogPanel.js.map +1 -0
  4008. package/dist/ui/components/AutomationsPanel.d.ts +28 -0
  4009. package/dist/ui/components/AutomationsPanel.d.ts.map +1 -0
  4010. package/dist/ui/components/AutomationsPanel.js +298 -0
  4011. package/dist/ui/components/AutomationsPanel.js.map +1 -0
  4012. package/dist/ui/components/ChatView.d.ts +27 -0
  4013. package/dist/ui/components/ChatView.d.ts.map +1 -0
  4014. package/dist/ui/components/ChatView.js +49 -0
  4015. package/dist/ui/components/ChatView.js.map +1 -0
  4016. package/dist/ui/components/CommandPalette.d.ts +39 -0
  4017. package/dist/ui/components/CommandPalette.d.ts.map +1 -0
  4018. package/dist/ui/components/CommandPalette.js +95 -0
  4019. package/dist/ui/components/CommandPalette.js.map +1 -0
  4020. package/dist/ui/components/CommandPaletteCommands.d.ts +70 -0
  4021. package/dist/ui/components/CommandPaletteCommands.d.ts.map +1 -0
  4022. package/dist/ui/components/CommandPaletteCommands.js +267 -0
  4023. package/dist/ui/components/CommandPaletteCommands.js.map +1 -0
  4024. package/dist/ui/components/ContextHUD.d.ts +24 -0
  4025. package/dist/ui/components/ContextHUD.d.ts.map +1 -0
  4026. package/dist/ui/components/ContextHUD.js +27 -0
  4027. package/dist/ui/components/ContextHUD.js.map +1 -0
  4028. package/dist/ui/components/ContextSourcePanel.d.ts +20 -0
  4029. package/dist/ui/components/ContextSourcePanel.d.ts.map +1 -0
  4030. package/dist/ui/components/ContextSourcePanel.js +91 -0
  4031. package/dist/ui/components/ContextSourcePanel.js.map +1 -0
  4032. package/dist/ui/components/DesignPreview.d.ts +66 -0
  4033. package/dist/ui/components/DesignPreview.d.ts.map +1 -0
  4034. package/dist/ui/components/DesignPreview.js +39 -0
  4035. package/dist/ui/components/DesignPreview.js.map +1 -0
  4036. package/dist/ui/components/DiffTimeline.d.ts +38 -0
  4037. package/dist/ui/components/DiffTimeline.d.ts.map +1 -0
  4038. package/dist/ui/components/DiffTimeline.js +65 -0
  4039. package/dist/ui/components/DiffTimeline.js.map +1 -0
  4040. package/dist/ui/components/DiffViewer.d.ts +35 -0
  4041. package/dist/ui/components/DiffViewer.d.ts.map +1 -0
  4042. package/dist/ui/components/DiffViewer.js +115 -0
  4043. package/dist/ui/components/DiffViewer.js.map +1 -0
  4044. package/dist/ui/components/DispatchInbox.d.ts +32 -0
  4045. package/dist/ui/components/DispatchInbox.d.ts.map +1 -0
  4046. package/dist/ui/components/DispatchInbox.js +89 -0
  4047. package/dist/ui/components/DispatchInbox.js.map +1 -0
  4048. package/dist/ui/components/GdprPanel.d.ts +22 -0
  4049. package/dist/ui/components/GdprPanel.d.ts.map +1 -0
  4050. package/dist/ui/components/GdprPanel.js +165 -0
  4051. package/dist/ui/components/GdprPanel.js.map +1 -0
  4052. package/dist/ui/components/HistoryPicker.d.ts +19 -0
  4053. package/dist/ui/components/HistoryPicker.d.ts.map +1 -0
  4054. package/dist/ui/components/HistoryPicker.js +129 -0
  4055. package/dist/ui/components/HistoryPicker.js.map +1 -0
  4056. package/dist/ui/components/MemoryInspector.d.ts +19 -0
  4057. package/dist/ui/components/MemoryInspector.d.ts.map +1 -0
  4058. package/dist/ui/components/MemoryInspector.js +129 -0
  4059. package/dist/ui/components/MemoryInspector.js.map +1 -0
  4060. package/dist/ui/components/MessageActions.d.ts +15 -0
  4061. package/dist/ui/components/MessageActions.d.ts.map +1 -0
  4062. package/dist/ui/components/MessageActions.js +84 -0
  4063. package/dist/ui/components/MessageActions.js.map +1 -0
  4064. package/dist/ui/components/ModelPicker.d.ts +61 -0
  4065. package/dist/ui/components/ModelPicker.d.ts.map +1 -0
  4066. package/dist/ui/components/ModelPicker.js +224 -0
  4067. package/dist/ui/components/ModelPicker.js.map +1 -0
  4068. package/dist/ui/components/OptionPicker.d.ts +38 -0
  4069. package/dist/ui/components/OptionPicker.d.ts.map +1 -0
  4070. package/dist/ui/components/OptionPicker.js +146 -0
  4071. package/dist/ui/components/OptionPicker.js.map +1 -0
  4072. package/dist/ui/components/PermissionPrompt.d.ts +22 -0
  4073. package/dist/ui/components/PermissionPrompt.d.ts.map +1 -0
  4074. package/dist/ui/components/PermissionPrompt.js +68 -0
  4075. package/dist/ui/components/PermissionPrompt.js.map +1 -0
  4076. package/dist/ui/components/PromptInput.d.ts +31 -0
  4077. package/dist/ui/components/PromptInput.d.ts.map +1 -0
  4078. package/dist/ui/components/PromptInput.js +244 -0
  4079. package/dist/ui/components/PromptInput.js.map +1 -0
  4080. package/dist/ui/components/ProofViewer.d.ts +30 -0
  4081. package/dist/ui/components/ProofViewer.d.ts.map +1 -0
  4082. package/dist/ui/components/ProofViewer.js +62 -0
  4083. package/dist/ui/components/ProofViewer.js.map +1 -0
  4084. package/dist/ui/components/Sparkline.d.ts +81 -0
  4085. package/dist/ui/components/Sparkline.d.ts.map +1 -0
  4086. package/dist/ui/components/Sparkline.js +102 -0
  4087. package/dist/ui/components/Sparkline.js.map +1 -0
  4088. package/dist/ui/components/StartupScreen.d.ts +31 -0
  4089. package/dist/ui/components/StartupScreen.d.ts.map +1 -0
  4090. package/dist/ui/components/StartupScreen.js +29 -0
  4091. package/dist/ui/components/StartupScreen.js.map +1 -0
  4092. package/dist/ui/components/StatusBar.d.ts +51 -0
  4093. package/dist/ui/components/StatusBar.d.ts.map +1 -0
  4094. package/dist/ui/components/StatusBar.js +74 -0
  4095. package/dist/ui/components/StatusBar.js.map +1 -0
  4096. package/dist/ui/components/TerminalBlocksView.d.ts +31 -0
  4097. package/dist/ui/components/TerminalBlocksView.d.ts.map +1 -0
  4098. package/dist/ui/components/TerminalBlocksView.js +149 -0
  4099. package/dist/ui/components/TerminalBlocksView.js.map +1 -0
  4100. package/dist/ui/components/TrustPanel.d.ts +26 -0
  4101. package/dist/ui/components/TrustPanel.d.ts.map +1 -0
  4102. package/dist/ui/components/TrustPanel.js +173 -0
  4103. package/dist/ui/components/TrustPanel.js.map +1 -0
  4104. package/dist/ui/components/UnifiedStatusBar.d.ts +65 -0
  4105. package/dist/ui/components/UnifiedStatusBar.d.ts.map +1 -0
  4106. package/dist/ui/components/UnifiedStatusBar.js +60 -0
  4107. package/dist/ui/components/UnifiedStatusBar.js.map +1 -0
  4108. package/dist/ui/components/primitives/Banner.d.ts +47 -0
  4109. package/dist/ui/components/primitives/Banner.d.ts.map +1 -0
  4110. package/dist/ui/components/primitives/Banner.js +29 -0
  4111. package/dist/ui/components/primitives/Banner.js.map +1 -0
  4112. package/dist/ui/components/primitives/Card.d.ts +58 -0
  4113. package/dist/ui/components/primitives/Card.d.ts.map +1 -0
  4114. package/dist/ui/components/primitives/Card.js +20 -0
  4115. package/dist/ui/components/primitives/Card.js.map +1 -0
  4116. package/dist/ui/components/primitives/KeyHint.d.ts +58 -0
  4117. package/dist/ui/components/primitives/KeyHint.d.ts.map +1 -0
  4118. package/dist/ui/components/primitives/KeyHint.js +21 -0
  4119. package/dist/ui/components/primitives/KeyHint.js.map +1 -0
  4120. package/dist/ui/components/primitives/Notification.d.ts +26 -0
  4121. package/dist/ui/components/primitives/Notification.d.ts.map +1 -0
  4122. package/dist/ui/components/primitives/Notification.js +24 -0
  4123. package/dist/ui/components/primitives/Notification.js.map +1 -0
  4124. package/dist/ui/components/primitives/ProgressMeter.d.ts +47 -0
  4125. package/dist/ui/components/primitives/ProgressMeter.d.ts.map +1 -0
  4126. package/dist/ui/components/primitives/ProgressMeter.js +46 -0
  4127. package/dist/ui/components/primitives/ProgressMeter.js.map +1 -0
  4128. package/dist/ui/components/primitives/Spinner.d.ts +28 -0
  4129. package/dist/ui/components/primitives/Spinner.d.ts.map +1 -0
  4130. package/dist/ui/components/primitives/Spinner.js +32 -0
  4131. package/dist/ui/components/primitives/Spinner.js.map +1 -0
  4132. package/dist/ui/components/primitives/StatusBadge.d.ts +38 -0
  4133. package/dist/ui/components/primitives/StatusBadge.d.ts.map +1 -0
  4134. package/dist/ui/components/primitives/StatusBadge.js +28 -0
  4135. package/dist/ui/components/primitives/StatusBadge.js.map +1 -0
  4136. package/dist/ui/components/primitives/index.d.ts +24 -0
  4137. package/dist/ui/components/primitives/index.d.ts.map +1 -0
  4138. package/dist/ui/components/primitives/index.js +17 -0
  4139. package/dist/ui/components/primitives/index.js.map +1 -0
  4140. package/dist/ui/context-meter.d.ts +46 -0
  4141. package/dist/ui/context-meter.d.ts.map +1 -0
  4142. package/dist/ui/context-meter.js +111 -0
  4143. package/dist/ui/context-meter.js.map +1 -0
  4144. package/dist/ui/context-references.d.ts +62 -0
  4145. package/dist/ui/context-references.d.ts.map +1 -0
  4146. package/dist/ui/context-references.js +559 -0
  4147. package/dist/ui/context-references.js.map +1 -0
  4148. package/dist/ui/cost-readout.d.ts +60 -0
  4149. package/dist/ui/cost-readout.d.ts.map +1 -0
  4150. package/dist/ui/cost-readout.js +101 -0
  4151. package/dist/ui/cost-readout.js.map +1 -0
  4152. package/dist/ui/diff-engine.d.ts +110 -0
  4153. package/dist/ui/diff-engine.d.ts.map +1 -0
  4154. package/dist/ui/diff-engine.js +274 -0
  4155. package/dist/ui/diff-engine.js.map +1 -0
  4156. package/dist/ui/follow-ups.d.ts +39 -0
  4157. package/dist/ui/follow-ups.d.ts.map +1 -0
  4158. package/dist/ui/follow-ups.js +226 -0
  4159. package/dist/ui/follow-ups.js.map +1 -0
  4160. package/dist/ui/helpers.d.ts +33 -0
  4161. package/dist/ui/helpers.d.ts.map +1 -0
  4162. package/dist/ui/helpers.js +97 -0
  4163. package/dist/ui/helpers.js.map +1 -0
  4164. package/dist/ui/input/mouse.d.ts +139 -0
  4165. package/dist/ui/input/mouse.d.ts.map +1 -0
  4166. package/dist/ui/input/mouse.js +239 -0
  4167. package/dist/ui/input/mouse.js.map +1 -0
  4168. package/dist/ui/keybindings.d.ts +26 -0
  4169. package/dist/ui/keybindings.d.ts.map +1 -0
  4170. package/dist/ui/keybindings.js +76 -0
  4171. package/dist/ui/keybindings.js.map +1 -0
  4172. package/dist/ui/raven/raven-state.d.ts +69 -0
  4173. package/dist/ui/raven/raven-state.d.ts.map +1 -0
  4174. package/dist/ui/raven/raven-state.js +185 -0
  4175. package/dist/ui/raven/raven-state.js.map +1 -0
  4176. package/dist/ui/sound.d.ts +85 -0
  4177. package/dist/ui/sound.d.ts.map +1 -0
  4178. package/dist/ui/sound.js +126 -0
  4179. package/dist/ui/sound.js.map +1 -0
  4180. package/dist/ui/statusline.d.ts +74 -0
  4181. package/dist/ui/statusline.d.ts.map +1 -0
  4182. package/dist/ui/statusline.js +111 -0
  4183. package/dist/ui/statusline.js.map +1 -0
  4184. package/dist/ui/string-width-cache.d.ts +204 -0
  4185. package/dist/ui/string-width-cache.d.ts.map +1 -0
  4186. package/dist/ui/string-width-cache.js +374 -0
  4187. package/dist/ui/string-width-cache.js.map +1 -0
  4188. package/dist/ui/terminal-blocks/block.d.ts +90 -0
  4189. package/dist/ui/terminal-blocks/block.d.ts.map +1 -0
  4190. package/dist/ui/terminal-blocks/block.js +183 -0
  4191. package/dist/ui/terminal-blocks/block.js.map +1 -0
  4192. package/dist/ui/terminal-blocks/init-snippets.d.ts +32 -0
  4193. package/dist/ui/terminal-blocks/init-snippets.d.ts.map +1 -0
  4194. package/dist/ui/terminal-blocks/init-snippets.js +163 -0
  4195. package/dist/ui/terminal-blocks/init-snippets.js.map +1 -0
  4196. package/dist/ui/terminal-blocks/osc-133-parser.d.ts +98 -0
  4197. package/dist/ui/terminal-blocks/osc-133-parser.d.ts.map +1 -0
  4198. package/dist/ui/terminal-blocks/osc-133-parser.js +230 -0
  4199. package/dist/ui/terminal-blocks/osc-133-parser.js.map +1 -0
  4200. package/dist/ui/theme/tokens.d.ts +198 -0
  4201. package/dist/ui/theme/tokens.d.ts.map +1 -0
  4202. package/dist/ui/theme/tokens.js +199 -0
  4203. package/dist/ui/theme/tokens.js.map +1 -0
  4204. package/dist/ui/themes/colorblind.d.ts +74 -0
  4205. package/dist/ui/themes/colorblind.d.ts.map +1 -0
  4206. package/dist/ui/themes/colorblind.js +162 -0
  4207. package/dist/ui/themes/colorblind.js.map +1 -0
  4208. package/dist/ui/themes.d.ts +158 -0
  4209. package/dist/ui/themes.d.ts.map +1 -0
  4210. package/dist/ui/themes.js +425 -0
  4211. package/dist/ui/themes.js.map +1 -0
  4212. package/dist/ui/turn-finalize.d.ts +66 -0
  4213. package/dist/ui/turn-finalize.d.ts.map +1 -0
  4214. package/dist/ui/turn-finalize.js +79 -0
  4215. package/dist/ui/turn-finalize.js.map +1 -0
  4216. package/dist/ui/voice-controller.d.ts +32 -0
  4217. package/dist/ui/voice-controller.d.ts.map +1 -0
  4218. package/dist/ui/voice-controller.js +72 -0
  4219. package/dist/ui/voice-controller.js.map +1 -0
  4220. package/dist/utils/atomic-io.d.ts +83 -0
  4221. package/dist/utils/atomic-io.d.ts.map +1 -0
  4222. package/dist/utils/atomic-io.js +219 -0
  4223. package/dist/utils/atomic-io.js.map +1 -0
  4224. package/dist/utils/atomic-write.d.ts +60 -0
  4225. package/dist/utils/atomic-write.d.ts.map +1 -0
  4226. package/dist/utils/atomic-write.js +144 -0
  4227. package/dist/utils/atomic-write.js.map +1 -0
  4228. package/dist/utils/execFileNoThrow.d.ts +19 -0
  4229. package/dist/utils/execFileNoThrow.d.ts.map +1 -0
  4230. package/dist/utils/execFileNoThrow.js +31 -0
  4231. package/dist/utils/execFileNoThrow.js.map +1 -0
  4232. package/dist/utils/json-parse.d.ts +52 -0
  4233. package/dist/utils/json-parse.d.ts.map +1 -0
  4234. package/dist/utils/json-parse.js +259 -0
  4235. package/dist/utils/json-parse.js.map +1 -0
  4236. package/dist/utils/marker-polling.d.ts +216 -0
  4237. package/dist/utils/marker-polling.d.ts.map +1 -0
  4238. package/dist/utils/marker-polling.js +324 -0
  4239. package/dist/utils/marker-polling.js.map +1 -0
  4240. package/dist/utils/path-realpath.d.ts +81 -0
  4241. package/dist/utils/path-realpath.d.ts.map +1 -0
  4242. package/dist/utils/path-realpath.js +210 -0
  4243. package/dist/utils/path-realpath.js.map +1 -0
  4244. package/dist/utils/process-handlers.d.ts +65 -0
  4245. package/dist/utils/process-handlers.d.ts.map +1 -0
  4246. package/dist/utils/process-handlers.js +102 -0
  4247. package/dist/utils/process-handlers.js.map +1 -0
  4248. package/dist/utils/proxy-setup.d.ts +56 -0
  4249. package/dist/utils/proxy-setup.d.ts.map +1 -0
  4250. package/dist/utils/proxy-setup.js +109 -0
  4251. package/dist/utils/proxy-setup.js.map +1 -0
  4252. package/dist/utils/schema-drift.d.ts +99 -0
  4253. package/dist/utils/schema-drift.d.ts.map +1 -0
  4254. package/dist/utils/schema-drift.js +123 -0
  4255. package/dist/utils/schema-drift.js.map +1 -0
  4256. package/dist/utils/shadow-git.d.ts +111 -0
  4257. package/dist/utils/shadow-git.d.ts.map +1 -0
  4258. package/dist/utils/shadow-git.js +392 -0
  4259. package/dist/utils/shadow-git.js.map +1 -0
  4260. package/dist/utils/sidecar-downloader.d.ts +54 -0
  4261. package/dist/utils/sidecar-downloader.d.ts.map +1 -0
  4262. package/dist/utils/sidecar-downloader.js +185 -0
  4263. package/dist/utils/sidecar-downloader.js.map +1 -0
  4264. package/dist/utils/sqlite-kv-store.d.ts +91 -0
  4265. package/dist/utils/sqlite-kv-store.d.ts.map +1 -0
  4266. package/dist/utils/sqlite-kv-store.js +229 -0
  4267. package/dist/utils/sqlite-kv-store.js.map +1 -0
  4268. package/dist/utils/sqlite-store-init.d.ts +33 -0
  4269. package/dist/utils/sqlite-store-init.d.ts.map +1 -0
  4270. package/dist/utils/sqlite-store-init.js +31 -0
  4271. package/dist/utils/sqlite-store-init.js.map +1 -0
  4272. package/dist/utils/stub-detection.d.ts +18 -0
  4273. package/dist/utils/stub-detection.d.ts.map +1 -0
  4274. package/dist/utils/stub-detection.js +32 -0
  4275. package/dist/utils/stub-detection.js.map +1 -0
  4276. package/dist/utils/transcript-shrinker.d.ts +51 -0
  4277. package/dist/utils/transcript-shrinker.d.ts.map +1 -0
  4278. package/dist/utils/transcript-shrinker.js +124 -0
  4279. package/dist/utils/transcript-shrinker.js.map +1 -0
  4280. package/dist/utils/trusted-workspaces.d.ts +106 -0
  4281. package/dist/utils/trusted-workspaces.d.ts.map +1 -0
  4282. package/dist/utils/trusted-workspaces.js +175 -0
  4283. package/dist/utils/trusted-workspaces.js.map +1 -0
  4284. package/dist/utils/vision-ocr.d.ts +46 -0
  4285. package/dist/utils/vision-ocr.d.ts.map +1 -0
  4286. package/dist/utils/vision-ocr.js +225 -0
  4287. package/dist/utils/vision-ocr.js.map +1 -0
  4288. package/dist/utils/wasm-bypass.d.ts +23 -0
  4289. package/dist/utils/wasm-bypass.d.ts.map +1 -0
  4290. package/dist/utils/wasm-bypass.js +63 -0
  4291. package/dist/utils/wasm-bypass.js.map +1 -0
  4292. package/dist/utils/wotann-home.d.ts +39 -0
  4293. package/dist/utils/wotann-home.d.ts.map +1 -0
  4294. package/dist/utils/wotann-home.js +49 -0
  4295. package/dist/utils/wotann-home.js.map +1 -0
  4296. package/dist/verification/index.d.ts +56 -0
  4297. package/dist/verification/index.d.ts.map +1 -0
  4298. package/dist/verification/index.js +86 -0
  4299. package/dist/verification/index.js.map +1 -0
  4300. package/dist/verification/judge-adapter.d.ts +32 -0
  4301. package/dist/verification/judge-adapter.d.ts.map +1 -0
  4302. package/dist/verification/judge-adapter.js +72 -0
  4303. package/dist/verification/judge-adapter.js.map +1 -0
  4304. package/dist/verification/pre-commit.d.ts +22 -0
  4305. package/dist/verification/pre-commit.d.ts.map +1 -0
  4306. package/dist/verification/pre-commit.js +66 -0
  4307. package/dist/verification/pre-commit.js.map +1 -0
  4308. package/dist/verification/strategies/cove-wrapper.d.ts +23 -0
  4309. package/dist/verification/strategies/cove-wrapper.d.ts.map +1 -0
  4310. package/dist/verification/strategies/cove-wrapper.js +108 -0
  4311. package/dist/verification/strategies/cove-wrapper.js.map +1 -0
  4312. package/dist/verification/strategies/faithfulness.d.ts +15 -0
  4313. package/dist/verification/strategies/faithfulness.d.ts.map +1 -0
  4314. package/dist/verification/strategies/faithfulness.js +102 -0
  4315. package/dist/verification/strategies/faithfulness.js.map +1 -0
  4316. package/dist/verification/strategies/format.d.ts +16 -0
  4317. package/dist/verification/strategies/format.d.ts.map +1 -0
  4318. package/dist/verification/strategies/format.js +116 -0
  4319. package/dist/verification/strategies/format.js.map +1 -0
  4320. package/dist/verification/strategies/four-perspective-wrapper.d.ts +21 -0
  4321. package/dist/verification/strategies/four-perspective-wrapper.d.ts.map +1 -0
  4322. package/dist/verification/strategies/four-perspective-wrapper.js +109 -0
  4323. package/dist/verification/strategies/four-perspective-wrapper.js.map +1 -0
  4324. package/dist/verification/strategies/guardian-wrapper.d.ts +20 -0
  4325. package/dist/verification/strategies/guardian-wrapper.d.ts.map +1 -0
  4326. package/dist/verification/strategies/guardian-wrapper.js +78 -0
  4327. package/dist/verification/strategies/guardian-wrapper.js.map +1 -0
  4328. package/dist/verification/strategies/hallucination.d.ts +25 -0
  4329. package/dist/verification/strategies/hallucination.d.ts.map +1 -0
  4330. package/dist/verification/strategies/hallucination.js +153 -0
  4331. package/dist/verification/strategies/hallucination.js.map +1 -0
  4332. package/dist/verification/strategies/plan-action-match.d.ts +16 -0
  4333. package/dist/verification/strategies/plan-action-match.d.ts.map +1 -0
  4334. package/dist/verification/strategies/plan-action-match.js +120 -0
  4335. package/dist/verification/strategies/plan-action-match.js.map +1 -0
  4336. package/dist/verification/strategies/safety.d.ts +18 -0
  4337. package/dist/verification/strategies/safety.d.ts.map +1 -0
  4338. package/dist/verification/strategies/safety.js +115 -0
  4339. package/dist/verification/strategies/safety.js.map +1 -0
  4340. package/dist/verification/types.d.ts +201 -0
  4341. package/dist/verification/types.d.ts.map +1 -0
  4342. package/dist/verification/types.js +42 -0
  4343. package/dist/verification/types.js.map +1 -0
  4344. package/dist/verification/verifier-engine.d.ts +36 -0
  4345. package/dist/verification/verifier-engine.d.ts.map +1 -0
  4346. package/dist/verification/verifier-engine.js +226 -0
  4347. package/dist/verification/verifier-engine.js.map +1 -0
  4348. package/dist/vision/cache.d.ts +50 -0
  4349. package/dist/vision/cache.d.ts.map +1 -0
  4350. package/dist/vision/cache.js +95 -0
  4351. package/dist/vision/cache.js.map +1 -0
  4352. package/dist/vision/ingest.d.ts +61 -0
  4353. package/dist/vision/ingest.d.ts.map +1 -0
  4354. package/dist/vision/ingest.js +162 -0
  4355. package/dist/vision/ingest.js.map +1 -0
  4356. package/dist/vision/keyframes.d.ts +53 -0
  4357. package/dist/vision/keyframes.d.ts.map +1 -0
  4358. package/dist/vision/keyframes.js +203 -0
  4359. package/dist/vision/keyframes.js.map +1 -0
  4360. package/dist/vision/mime-sniff.d.ts +38 -0
  4361. package/dist/vision/mime-sniff.d.ts.map +1 -0
  4362. package/dist/vision/mime-sniff.js +55 -0
  4363. package/dist/vision/mime-sniff.js.map +1 -0
  4364. package/dist/vision/resize.d.ts +60 -0
  4365. package/dist/vision/resize.d.ts.map +1 -0
  4366. package/dist/vision/resize.js +138 -0
  4367. package/dist/vision/resize.js.map +1 -0
  4368. package/dist/vision/size-policy.d.ts +53 -0
  4369. package/dist/vision/size-policy.d.ts.map +1 -0
  4370. package/dist/vision/size-policy.js +159 -0
  4371. package/dist/vision/size-policy.js.map +1 -0
  4372. package/dist/vision/types.d.ts +119 -0
  4373. package/dist/vision/types.d.ts.map +1 -0
  4374. package/dist/vision/types.js +41 -0
  4375. package/dist/vision/types.js.map +1 -0
  4376. package/dist/voice/edge-tts-backend.d.ts +65 -0
  4377. package/dist/voice/edge-tts-backend.d.ts.map +1 -0
  4378. package/dist/voice/edge-tts-backend.js +150 -0
  4379. package/dist/voice/edge-tts-backend.js.map +1 -0
  4380. package/dist/voice/stt-detector.d.ts +100 -0
  4381. package/dist/voice/stt-detector.d.ts.map +1 -0
  4382. package/dist/voice/stt-detector.js +484 -0
  4383. package/dist/voice/stt-detector.js.map +1 -0
  4384. package/dist/voice/tts-engine.d.ts +123 -0
  4385. package/dist/voice/tts-engine.d.ts.map +1 -0
  4386. package/dist/voice/tts-engine.js +602 -0
  4387. package/dist/voice/tts-engine.js.map +1 -0
  4388. package/dist/voice/vibevoice-backend.d.ts +113 -0
  4389. package/dist/voice/vibevoice-backend.d.ts.map +1 -0
  4390. package/dist/voice/vibevoice-backend.js +340 -0
  4391. package/dist/voice/vibevoice-backend.js.map +1 -0
  4392. package/dist/voice/voice-mode.d.ts +96 -0
  4393. package/dist/voice/voice-mode.d.ts.map +1 -0
  4394. package/dist/voice/voice-mode.js +627 -0
  4395. package/dist/voice/voice-mode.js.map +1 -0
  4396. package/dist/voice/voice-pipeline.d.ts +140 -0
  4397. package/dist/voice/voice-pipeline.d.ts.map +1 -0
  4398. package/dist/voice/voice-pipeline.js +658 -0
  4399. package/dist/voice/voice-pipeline.js.map +1 -0
  4400. package/dist/workflows/workflow-runner.d.ts +96 -0
  4401. package/dist/workflows/workflow-runner.d.ts.map +1 -0
  4402. package/dist/workflows/workflow-runner.js +362 -0
  4403. package/dist/workflows/workflow-runner.js.map +1 -0
  4404. package/install.sh +261 -0
  4405. package/package.json +121 -0
  4406. package/skills/a2ui.md +37 -0
  4407. package/skills/agent-autonomy-kit.md +168 -0
  4408. package/skills/agent-reach.md +58 -0
  4409. package/skills/ai-humanizer.md +204 -0
  4410. package/skills/ai-slop-cleaner.md +63 -0
  4411. package/skills/angular-architect.md +67 -0
  4412. package/skills/anthropic-imports/docx-create.md +61 -0
  4413. package/skills/anthropic-imports/pdf-create.md +63 -0
  4414. package/skills/anthropic-imports/pptx-create.md +61 -0
  4415. package/skills/anthropic-imports/xlsx-create.md +67 -0
  4416. package/skills/api-design-rest.md +112 -0
  4417. package/skills/api-design.md +40 -0
  4418. package/skills/batch-processing.md +36 -0
  4419. package/skills/benchmark-engineering.md +45 -0
  4420. package/skills/boost-prompt.md +182 -0
  4421. package/skills/branch-management.md +57 -0
  4422. package/skills/brooks-lint.md +101 -0
  4423. package/skills/canvas-mode.md +40 -0
  4424. package/skills/capability-evolver.md +141 -0
  4425. package/skills/chain-of-thought.md +48 -0
  4426. package/skills/cicd-engineer.md +68 -0
  4427. package/skills/cloud-architect.md +59 -0
  4428. package/skills/code-review-deep.md +82 -0
  4429. package/skills/code-reviewer.md +32 -0
  4430. package/skills/code-simplifier.md +35 -0
  4431. package/skills/codebase-recon.md +101 -0
  4432. package/skills/command-block-replay.md +58 -0
  4433. package/skills/compaction-ui-enhancements.md +169 -0
  4434. package/skills/compare-providers.md +66 -0
  4435. package/skills/compliance-checker.md +62 -0
  4436. package/skills/constitutional-ai.md +44 -0
  4437. package/skills/context-engine.md +186 -0
  4438. package/skills/context-management.md +59 -0
  4439. package/skills/conventional-commit.md +43 -0
  4440. package/skills/cost-intelligence.md +50 -0
  4441. package/skills/cpp-pro.md +72 -0
  4442. package/skills/csharp-developer.md +70 -0
  4443. package/skills/debug-hypothesis-tree.md +56 -0
  4444. package/skills/dependency-auditor.md +50 -0
  4445. package/skills/design-doc-template.md +82 -0
  4446. package/skills/django-expert.md +66 -0
  4447. package/skills/docker-expert.md +41 -0
  4448. package/skills/documentation.md +65 -0
  4449. package/skills/dotnet-core.md +69 -0
  4450. package/skills/dream-cycle.md +59 -0
  4451. package/skills/elite-longterm-memory.md +144 -0
  4452. package/skills/evaluate-prompt.md +71 -0
  4453. package/skills/event-driven.md +21 -0
  4454. package/skills/example-tool-rules.md +56 -0
  4455. package/skills/express-api.md +70 -0
  4456. package/skills/fastapi-expert.md +76 -0
  4457. package/skills/file-based-planning.md +49 -0
  4458. package/skills/find-missing-tests.md +75 -0
  4459. package/skills/flutter-expert.md +23 -0
  4460. package/skills/frontend-design-system.md +35 -0
  4461. package/skills/generator-critic-loop.md +63 -0
  4462. package/skills/golang-pro.md +26 -0
  4463. package/skills/governance.md +175 -0
  4464. package/skills/incident-postmortem.md +89 -0
  4465. package/skills/incident-response.md +196 -0
  4466. package/skills/integration-testing.md +67 -0
  4467. package/skills/java-architect.md +23 -0
  4468. package/skills/karpathy-principles.md +62 -0
  4469. package/skills/kotlin-specialist.md +64 -0
  4470. package/skills/kubernetes-specialist.md +68 -0
  4471. package/skills/lsp-operations.md +40 -0
  4472. package/skills/marketing-conversion-ops.md +36 -0
  4473. package/skills/marketing-expert-panel.md +33 -0
  4474. package/skills/marketing-growth-engine.md +33 -0
  4475. package/skills/marketing-outbound-engine.md +27 -0
  4476. package/skills/marketing-seo-ops.md +32 -0
  4477. package/skills/mcp-marketplace.md +51 -0
  4478. package/skills/memory-stack.md +24 -0
  4479. package/skills/microservices-architect.md +60 -0
  4480. package/skills/mongodb-expert.md +58 -0
  4481. package/skills/monitoring-expert.md +69 -0
  4482. package/skills/multi-source-research.md +56 -0
  4483. package/skills/nestjs-expert.md +69 -0
  4484. package/skills/nextjs-developer.md +23 -0
  4485. package/skills/pack-astro-static.md +225 -0
  4486. package/skills/pack-expo.md +304 -0
  4487. package/skills/pack-hono-react-edge.md +237 -0
  4488. package/skills/pack-nextjs-app-router.md +219 -0
  4489. package/skills/pentest-patterns.md +61 -0
  4490. package/skills/performance-profiler.md +22 -0
  4491. package/skills/php-pro.md +78 -0
  4492. package/skills/playwright-expert.md +23 -0
  4493. package/skills/postgres-pro.md +61 -0
  4494. package/skills/postmortem-template.md +89 -0
  4495. package/skills/pr-creation.md +64 -0
  4496. package/skills/proactive-agent-v3.md +138 -0
  4497. package/skills/prompt-master.md +61 -0
  4498. package/skills/prompt-testing.md +58 -0
  4499. package/skills/python-pro.md +33 -0
  4500. package/skills/rails-expert.md +23 -0
  4501. package/skills/react-expert.md +34 -0
  4502. package/skills/react-native-expert.md +70 -0
  4503. package/skills/redis-expert.md +58 -0
  4504. package/skills/refactor-safely.md +73 -0
  4505. package/skills/refactor-with-tests.md +57 -0
  4506. package/skills/rust-engineer.md +24 -0
  4507. package/skills/scientific-method.md +54 -0
  4508. package/skills/search-first.md +32 -0
  4509. package/skills/security-recon-checklist.md +63 -0
  4510. package/skills/security-reviewer.md +37 -0
  4511. package/skills/self-healing.md +52 -0
  4512. package/skills/setup-audit.md +56 -0
  4513. package/skills/skeleton-of-thought.md +53 -0
  4514. package/skills/skill-creator.md +28 -0
  4515. package/skills/spec-driven-workflow.md +23 -0
  4516. package/skills/spring-boot.md +67 -0
  4517. package/skills/sql-pro.md +34 -0
  4518. package/skills/superpowers-dispatcher.md +234 -0
  4519. package/skills/svelte-expert.md +66 -0
  4520. package/skills/swift-expert.md +77 -0
  4521. package/skills/system-design-interview.md +69 -0
  4522. package/skills/system-design.md +58 -0
  4523. package/skills/systematic-debugging.md +33 -0
  4524. package/skills/tdd-workflow.md +32 -0
  4525. package/skills/terraform-engineer.md +72 -0
  4526. package/skills/think-in-code.md +147 -0
  4527. package/skills/trace-analysis.md +65 -0
  4528. package/skills/tree-search.md +21 -0
  4529. package/skills/turing-pyramid.md +113 -0
  4530. package/skills/typescript-deep.md +70 -0
  4531. package/skills/typescript-pro.md +33 -0
  4532. package/skills/ultraplan.md +61 -0
  4533. package/skills/vue-expert.md +71 -0
  4534. package/skills/web-scraper.md +35 -0
@@ -0,0 +1,3016 @@
1
+ /**
2
+ * KAIROS — Always-On Daemon.
3
+ * Tick system with 15-second budget, heartbeat runner, cron service.
4
+ * Daily log as append-only JSONL audit trail.
5
+ */
6
+ import { appendFileSync, existsSync, readFileSync, mkdirSync, readdirSync, statSync, unlinkSync, } from "node:fs";
7
+ import { join } from "node:path";
8
+ import { execFile } from "node:child_process";
9
+ import { resolveWotannHome, resolveWotannHomeSubdir } from "../utils/wotann-home.js";
10
+ import { promisify } from "node:util";
11
+ import { ChannelGateway } from "../channels/gateway.js";
12
+ import { UnifiedDispatchPlane } from "../channels/unified-dispatch.js";
13
+ import { wrapLegacyAdapter } from "../channels/integration.js";
14
+ import { createAvailableAdapters } from "../channels/auto-detect.js";
15
+ import { RoutePolicyEngine, createDefaultPolicy } from "../channels/route-policies.js";
16
+ import { runWorkspaceDreamIfDue } from "../learning/dream-runner.js";
17
+ import { KairosRPCHandler } from "./kairos-rpc.js";
18
+ import { KairosIPCServer, writeSessionToken } from "./kairos-ipc.js";
19
+ import { WotannRuntime } from "../core/runtime.js";
20
+ import { loadConfig } from "../core/config.js";
21
+ import { CompanionServer } from "../desktop/companion-server.js";
22
+ import { SupabaseRelay } from "../desktop/supabase-relay.js";
23
+ import { createCompanionBridge, } from "../session/dispatch/companion-bridge.js";
24
+ import { createReplayRegistry } from "./transport/index.js";
25
+ import { BackgroundWorkerManager } from "./background-workers.js";
26
+ import { PatternCrystallizer } from "../learning/pattern-crystallizer.js";
27
+ import { FeedbackCollector } from "../learning/feedback-collector.js";
28
+ import { SelfEvolutionEngine } from "../learning/self-evolution.js";
29
+ import { TrajectoryExtractor } from "../training/trajectory-extractor.js";
30
+ import { DreamPipeline } from "../learning/dream-pipeline.js";
31
+ import { EventTriggerSystem } from "./event-triggers.js";
32
+ import { AmbientAwareness } from "../intelligence/ambient-awareness.js";
33
+ import { pushNotification, proactiveCheck, proactiveHeartbeatCheck } from "./kairos-tools.js";
34
+ import { AutomationEngine } from "./automations.js";
35
+ import { BackgroundAgentManager } from "../agents/background-agent.js";
36
+ import { SmartFileSearch } from "../intelligence/smart-file-search.js";
37
+ import { CostOracle } from "../telemetry/cost-oracle.js";
38
+ import { IdleDetector } from "../intelligence/away-summary.js";
39
+ import { FlowTracker } from "../intelligence/flow-tracker.js";
40
+ import { CrossDeviceContextManager } from "../intelligence/cross-device-context.js";
41
+ import { analyzeCodebaseHealth, } from "../intelligence/codebase-health.js";
42
+ import { PWREngine } from "../orchestration/pwr-cycle.js";
43
+ import { runRalphMode } from "../orchestration/ralph-mode.js";
44
+ import { GitHubBot } from "../channels/github-bot.js";
45
+ import { IDEBridge } from "../channels/ide-bridge.js";
46
+ import { LivingSpecManager, } from "../orchestration/living-spec.js";
47
+ import { WorkflowDAGEngine } from "../orchestration/workflow-dag.js";
48
+ import { ContextPressureMonitor } from "./context-pressure.js";
49
+ import { TerminalMonitor } from "./terminal-monitor.js";
50
+ import { FileDependencyGraph } from "./file-dep-graph.js";
51
+ import { CronStore } from "./cron-store.js";
52
+ import { resolveCompanionPort } from "./port-resolver.js";
53
+ import { CronScheduler } from "../scheduler/cron-scheduler.js";
54
+ import { ScheduleStore } from "../scheduler/schedule-store.js";
55
+ import { discoverModels } from "../providers/dynamic-discovery.js";
56
+ import { optimizeSkillPrompt, createLlmPromptMutator, buildBasicEvaluator, } from "../skills/skill-optimizer.js";
57
+ import { bootstrapFewShot } from "../learning/miprov2-optimizer.js";
58
+ // S5-3: MCPMarketplace removed — hardcoded 5 entries + fake registry URL
59
+ // (`registry.wotann.com` never existed). The real integration is
60
+ // MCPRegistry in ../marketplace/registry.ts, which actually imports MCP
61
+ // servers from the user's Claude Code / Cursor / Windsurf / Codex configs.
62
+ import { MCPRegistry, SkillMarketplace } from "../marketplace/registry.js";
63
+ import { DockerSandbox } from "../sandbox/docker-backend.js";
64
+ import { TaskIsolationManager } from "../sandbox/task-isolation.js";
65
+ import { TerminalManager } from "../sandbox/terminal-backends.js";
66
+ // TIER 2 cleanup: PluginScanner import removed — zombie instance stripped.
67
+ // Class stays exported via src/lib.ts for external scanning use cases.
68
+ import { ReasoningEngine } from "../identity/reasoning-engine.js";
69
+ import { UserModel } from "../identity/user-model.js";
70
+ import { PerceptionEngine } from "../computer-use/perception-engine.js";
71
+ import { MeetingRuntime } from "../meet/meeting-runtime.js";
72
+ import { AutoArchiveHook } from "../hooks/auto-archive.js";
73
+ import { RateLimitResumeManager } from "../hooks/rate-limit-resume.js";
74
+ // GA-09 / V9 T11.1 + T11.2 — wire orphan virtual-cursor pool/consumer
75
+ // and sleep-time agent/consumer into daemon lifecycle.
76
+ import { createVirtualCursorPool, } from "../computer-use/virtual-cursor-pool.js";
77
+ import { createVirtualCursorConsumer, } from "../orchestration/virtual-cursor-consumer.js";
78
+ import { createSleepTimeAgent, } from "../learning/sleep-time-agent.js";
79
+ import { createSleepTimeConsumer, } from "../orchestration/sleep-time-consumer.js";
80
+ const execFileAsync = promisify(execFile);
81
+ // ── Cron Schedule Matching ──────────────────────────────────
82
+ // Implementation now lives in ./cron-utils.ts to break a fragile circular
83
+ // value import between this file and ./event-triggers.ts (S0-14).
84
+ // The re-export keeps back-compat for existing callers/tests that import
85
+ // `matchesCronSchedule` from "./kairos".
86
+ import { matchesCronSchedule, matchCronField } from "./cron-utils.js";
87
+ export { matchesCronSchedule, matchCronField };
88
+ // ── Daemon Implementation ───────────────────────────────────
89
+ export class KairosDaemon {
90
+ state;
91
+ tickInterval = null;
92
+ logDir;
93
+ workingDir;
94
+ gateway = null;
95
+ dispatchPlane = null;
96
+ // Phase-C wire-up: per-channel auth/rate/escalation policy engine.
97
+ // Lives on the daemon (not inside the gateway) so the same instance
98
+ // can also back RPC handlers that list/mutate policies at runtime.
99
+ routePolicyEngine = null;
100
+ // Phase A: Runtime hosting
101
+ runtime = null;
102
+ rpcHandler = null;
103
+ ipcServer = null;
104
+ companionServer = null;
105
+ // T5 cross-surface dispatch bridge — translates UnifiedDispatchPlane
106
+ // events into JSON-RPC notifications on the iOS-subscribed topic strings
107
+ // (`approvals.notify`, `creations.updated`, `cursor.stream`, `live.activity`,
108
+ // `delivery`, `computer.session.events`, etc). Without this, iOS's
109
+ // `rpcClient.subscribe(...)` calls never see plane-emitted events because
110
+ // the daemon only emits `method:"stream"` over the WS surface. Bridge is
111
+ // minted after the runtime + companion server are alive (runtime owns the
112
+ // dispatch plane) and torn down before either is closed.
113
+ companionBridge = null;
114
+ // T12.18 ReplayRegistry singleton — minted at start(), torn down at
115
+ // stop(). Single capture point for outgoing WebSocket frames; emit
116
+ // sites in CompanionServer / RpcSubscription forwarders call
117
+ // `replayRegistry.append(sessionId, payload)` so reconnecting clients
118
+ // can drain missed frames via `replayRegistry.since(sessionId, lastSeq)`.
119
+ // Holding the instance on the daemon keeps the registry per-daemon
120
+ // (QB #7 — no module-global singleton) and threads it via DI from the
121
+ // composition root rather than parallel-constructing buffers at each
122
+ // emit site (QB #10 — sibling-site safety).
123
+ replayRegistry = null;
124
+ // Self-improvement subsystems (wired at start, accessible from all surfaces via RPC)
125
+ backgroundWorkers = new BackgroundWorkerManager();
126
+ patternCrystallizer = new PatternCrystallizer();
127
+ feedbackCollector = new FeedbackCollector();
128
+ selfEvolution = new SelfEvolutionEngine();
129
+ trajectoryExtractor = new TrajectoryExtractor();
130
+ supabaseRelay = null;
131
+ skillMerger = null;
132
+ // GA-09 / V9 T11.1 — Virtual cursor pool + consumer wire. The pool
133
+ // (src/computer-use/virtual-cursor-pool.ts) was an audit-flagged
134
+ // 4-file island with ZERO production importers; this field plus the
135
+ // consumer below close that gap. The consumer is driven from
136
+ // tick() — every daemon tick advances the pool by one frame and
137
+ // dispatches the resulting cursor frames through the companion
138
+ // server's broadcast topic ("cursor.stream") so iOS RemoteDesktopView
139
+ // / desktop overlays can render the multi-session cursors.
140
+ //
141
+ // Instantiated AFTER the companion server in start() so the
142
+ // dispatcher closure captures a live broadcastNotification target;
143
+ // torn down BEFORE the registry / WS so disposeAll doesn't race a
144
+ // pending tick.
145
+ virtualCursorPool = null;
146
+ virtualCursorConsumer = null;
147
+ // GA-09 / V9 T11.2 — Sleep-time agent + consumer wire. The agent
148
+ // (src/learning/sleep-time-agent.ts) was orphan: zero non-test
149
+ // consumers in src/. The consumer fires the agent's runIdleSession
150
+ // when the existing IdleDetector flips to idle, draining the queue
151
+ // against budget + duration caps. Opportunity is built from the
152
+ // detector's signals so policy lives in one place (the agent), not
153
+ // duplicated here.
154
+ //
155
+ // Both are instantiated at start() and torn down at stop(). The
156
+ // agent's taskExecutor closure captures the runtime so submitted
157
+ // tasks can route through the model; without a runtime (daemon-only
158
+ // mode) the executor returns an honest-stub `ok:false` result rather
159
+ // than silently succeeding.
160
+ sleepTimeAgent = null;
161
+ sleepTimeConsumer = null;
162
+ // Track when we last fired a sleep session so we don't re-trigger on
163
+ // every 15s tick during a long idle window. One opportunity per
164
+ // active->idle transition is the right cadence — we re-arm only
165
+ // after the user returns and the detector flips back to active.
166
+ lastSleepSessionAt = null;
167
+ // Track C additions: dream pipeline, event triggers, ambient awareness
168
+ dreamPipeline = null;
169
+ eventTriggerSystem = new EventTriggerSystem();
170
+ ambientAwareness = new AmbientAwareness();
171
+ backgroundAgents = new BackgroundAgentManager();
172
+ automationEngine = new AutomationEngine();
173
+ fileSearch = null;
174
+ costOracle = new CostOracle();
175
+ idleDetector = new IdleDetector();
176
+ flowTracker = new FlowTracker();
177
+ crossDeviceContext = new CrossDeviceContextManager();
178
+ lastHealthCheckDate = null;
179
+ lastHealthReport = null;
180
+ ambientTickCounter = 0;
181
+ heartbeatTickCounter = 0;
182
+ lastDreamDate = null;
183
+ lastSkillOptDate = null;
184
+ // Wave 4-Y: daily prune state (per-instance per QB#7).
185
+ // pruneAutoCaptures is a MemoryStore method (src/memory/store.ts:3945),
186
+ // pruneOlderThan is on AuditTrail (src/telemetry/audit-trail.ts:166).
187
+ // Both default to 30 days; we override AuditTrail to 90 days to retain
188
+ // a longer compliance window for tool-call audit while bounding growth.
189
+ lastAutoCapturesPruneDay = null;
190
+ lastAuditTrailPruneDay = null;
191
+ // PWR cycle: discuss→plan→implement→review→uat→ship phase transitions
192
+ pwrEngine = new PWREngine();
193
+ // GitHub Bot: webhook-based @wotann mention handler
194
+ githubBot = null;
195
+ // IDE Bridge: JSON-RPC server for VS Code/Cursor integration
196
+ ideBridge = null;
197
+ // Knowledge connectors: external data source registry for RAG
198
+ connectorRegistry = null;
199
+ // Living Spec: tracks divergence between SPEC.md and codebase
200
+ livingSpecManager = new LivingSpecManager();
201
+ livingSpec = null;
202
+ specTickCounter = 0;
203
+ // Workflow DAG Engine: YAML-based workflow execution
204
+ workflowEngine = new WorkflowDAGEngine();
205
+ // ── Marketplace + Sandbox + Identity (previously unwired) ──────────
206
+ // S5-3: mcpMarketplace field removed (vaporware). Use mcpRegistry instead.
207
+ mcpRegistry = new MCPRegistry();
208
+ skillMarketplace = new SkillMarketplace();
209
+ dockerSandbox = new DockerSandbox();
210
+ taskIsolation = null;
211
+ terminalManager = new TerminalManager();
212
+ // TIER 2 cleanup: PluginScanner zombie instance removed (per META-AUDIT-I).
213
+ // The class itself remains exported from src/lib.ts; no production caller
214
+ // ever invoked .scanPlugin() through the kairos getter. Construct directly
215
+ // when the marketplace plugin loader gets wired in TIER 1.
216
+ reasoningEngine = null;
217
+ userModel = null;
218
+ perceptionEngine = new PerceptionEngine();
219
+ // Phase C: Meeting runtime composes meeting-pipeline + meeting-store +
220
+ // coaching-engine. Owns the SQLite connection for transcripts; exposed
221
+ // through getMeetingStore() so kairos-rpc `meet.summarize` can resolve
222
+ // transcripts by id instead of silently returning null (4-session bug).
223
+ meetingRuntime = null;
224
+ // Session-13: Auto-archive (Jean-inspired) + Rate-limit-resume
225
+ // (oh-my-claudecode-inspired) service handles. The daemon owns these
226
+ // so PR-merge events (via github-bot) and rate-limit hits (via router)
227
+ // can route into one honest state store instead of being swallowed.
228
+ autoArchiveHook = new AutoArchiveHook({
229
+ archiveDir: resolveWotannHomeSubdir("archives"),
230
+ });
231
+ rateLimitResume = new RateLimitResumeManager();
232
+ // ── Tier 2A: Gap Analysis Modules ──────────────
233
+ contextPressure = new ContextPressureMonitor();
234
+ terminalMonitor = new TerminalMonitor();
235
+ fileDependencyGraph = new FileDependencyGraph();
236
+ // Wave 4F: SQLite-backed cron persistence. Null until start() opens
237
+ // the `.wotann/cron.db` connection; tests that only exercise in-memory
238
+ // semantics (see `tests/unit/kairos.test.ts`) leave it null so the
239
+ // existing `state.cronJobs` array remains the source of truth.
240
+ cronStore = null;
241
+ // P1-C2 Hermes cron port: sibling scheduler with at-most-once
242
+ // semantics. Distinct from cronStore — cronStore is at-least-once
243
+ // exec-based (legacy Wave-4F), scheduler is at-most-once
244
+ // handler-based (Hermes §4.4). Exposes `schedule.*` RPC family.
245
+ // Null until start() opens `.wotann/schedule.db`.
246
+ scheduleStore = null;
247
+ cronScheduler = null;
248
+ // Wave 4F: heartbeat telemetry tick counter. At the 15s daemon
249
+ // interval, every 2nd tick (~30s) writes PID + uptime + tickCount +
250
+ // activeProviders + memoryMb to `.wotann/daemon.status.json` and
251
+ // appends a `heartbeat` event to the daily JSONL log. Callers
252
+ // (CLI `wotann engine status`, TUI dashboard, mobile) read the JSON
253
+ // file for a cheap snapshot without paying the IPC round-trip cost.
254
+ telemetryTickCounter = 0;
255
+ statusJsonPath = null;
256
+ fileWatcher = null;
257
+ contextPressureTickCounter = 0;
258
+ modelRefreshTickCounter = 0;
259
+ // Phase B Bug #1 fix: run the auto_capture -> memory_entries
260
+ // consolidation pipeline on a cadence so structured memory_entries exist
261
+ // even when no user queries land. Without this, a daemon that does
262
+ // lifecycle-only work (session_start / session_end) produces 1990+
263
+ // auto_capture rows and 0 memory_entries.
264
+ consolidationTickCounter = 0;
265
+ // Wave 4-AA: tick() reentrancy guard. The tick body fires async work
266
+ // (proactiveCheck, dreamPipeline, codebase health, sleep-time consumer)
267
+ // and the daemon interval is 15s — when downstream work crosses the
268
+ // next interval, two ticks would interleave. That double-fires cron
269
+ // jobs (state.cronJobs.shouldRunCron), corrupts tickCount, and races
270
+ // against this.state assignment. Skip the new tick if the prior one
271
+ // is still running; the next interval picks up cleanly.
272
+ tickInFlight = false;
273
+ // Phase B Bug #2 fix: track shutdown handlers so we install them at most
274
+ // once per daemon instance (tests that spin up multiple daemons would
275
+ // otherwise leak SIGINT/SIGTERM/exit listeners across the process).
276
+ shutdownHandlersInstalled = false;
277
+ shutdownHandlers = null;
278
+ constructor(logDir, workingDir) {
279
+ this.workingDir = workingDir ?? process.cwd();
280
+ this.logDir = logDir ?? join(this.workingDir, ".wotann", "logs");
281
+ this.state = {
282
+ status: "stopped",
283
+ tickCount: 0,
284
+ heartbeatTasks: [],
285
+ cronJobs: [],
286
+ };
287
+ }
288
+ /**
289
+ * Start the daemon with full runtime hosting.
290
+ * Initializes: WotannRuntime → RPC handler → IPC server → CompanionServer.
291
+ * After this, CLI/Desktop/iOS can connect and send real queries.
292
+ */
293
+ start(tickIntervalMs = 15_000) {
294
+ if (this.state.status === "running")
295
+ return;
296
+ if (!existsSync(this.logDir)) {
297
+ mkdirSync(this.logDir, { recursive: true });
298
+ }
299
+ this.state = {
300
+ ...this.state,
301
+ status: "starting",
302
+ startedAt: new Date(),
303
+ };
304
+ // PHASE D — H-K4 OAuth rotator wire-up. The rotator sweeps every
305
+ // sweepIntervalMs and refreshes any credential whose expiresAt is
306
+ // within windowMs (5 min default). The listCredentials callback
307
+ // currently returns an empty array because the credential pool's
308
+ // expiresAt surface isn't yet exposed to the daemon — when the
309
+ // pool gains a public listExpiringCredentials() method (TIER 1
310
+ // follow-up tracked separately), wire it here.
311
+ void import("../auth/oauth-rotator.js").then(({ startOAuthRotator }) => {
312
+ startOAuthRotator({
313
+ listCredentials: () => [],
314
+ refresh: async () => {
315
+ /* no-op until pool exposes refresh hook */
316
+ },
317
+ log: (level, msg) => {
318
+ this.appendLog({ type: level === "error" ? "error" : "heartbeat", message: msg });
319
+ },
320
+ });
321
+ });
322
+ // Phase B Bug #2 fix: sweep orphan .tmp.* + stranded WAL/SHM from the
323
+ // last crashed run BEFORE opening any new SQLite connections. Running
324
+ // the sweep pre-runtime means the fresh SQLite instance doesn't get
325
+ // confused by leftover WAL files pointing at a different journal.
326
+ const sweepResult = this.sweepOrphanFiles();
327
+ if (sweepResult.tmpRemoved + sweepResult.walRemoved + sweepResult.shmRemoved > 0) {
328
+ this.appendLog({
329
+ type: "start",
330
+ message: `Orphan file sweep: ${sweepResult.tmpRemoved} tmp, ${sweepResult.walRemoved} wal, ${sweepResult.shmRemoved} shm removed`,
331
+ data: { ...sweepResult },
332
+ });
333
+ }
334
+ // Phase B Bug #2 fix (cont'd): install signal + exit handlers so the
335
+ // daemon flushes + cleans up even on SIGINT/SIGTERM. Previously a
336
+ // Ctrl-C mid-write left a stranded .tmp.*; now stop() runs in the
337
+ // handler before the process exits.
338
+ //
339
+ // V9 Wave 6.7 (M-N6) — SIGINT dedupe: when the daemon is launched via
340
+ // src/daemon/start.ts (the Tauri sidecar entry), start.ts owns the
341
+ // SIGINT/SIGTERM cleanup because it has additional responsibilities
342
+ // the daemon can't see (pidPath unlink, statusPath atomic rewrite,
343
+ // process.exit). In that mode start.ts sets WOTANN_DAEMON_OWNS_SIGNALS=1
344
+ // BEFORE constructing KairosDaemon, and we skip installing competing
345
+ // process-level handlers here. In every other entry point (in-process
346
+ // tests, embedded library use, `wotann engine`) the daemon retains
347
+ // ownership of its own teardown — which is the safe default.
348
+ if (process.env["WOTANN_DAEMON_OWNS_SIGNALS"] !== "1") {
349
+ this.installShutdownHandlers();
350
+ }
351
+ // Phase A1: Initialize WotannRuntime with discovered providers
352
+ try {
353
+ const config = loadConfig(this.workingDir);
354
+ this.runtime = new WotannRuntime({ ...config, workingDir: this.workingDir });
355
+ // Phase A2: Create RPC handler wired to daemon and runtime
356
+ this.rpcHandler = new KairosRPCHandler();
357
+ this.rpcHandler.setDaemon(this);
358
+ this.rpcHandler.setRuntime(this.runtime);
359
+ // Wire WorkflowDAGEngine to route agent calls through runtime.query()
360
+ const runtimeRef = this.runtime;
361
+ this.workflowEngine.setAgentExecutor(async (prompt, context) => {
362
+ const fullPrompt = context ? `${context}\n\n${prompt}` : prompt;
363
+ let output = "";
364
+ for await (const chunk of runtimeRef.query({ prompt: fullPrompt })) {
365
+ if (chunk.type === "text")
366
+ output += chunk.content;
367
+ }
368
+ return output;
369
+ });
370
+ // Phase A3: Start IPC server on Unix Domain Socket
371
+ const wotannDir = resolveWotannHome();
372
+ if (!existsSync(wotannDir)) {
373
+ // V9 Wave 6.7 (M-N9) — sensitive directory: mode 0o700 so the
374
+ // session-token.json (mode 0600), copilot-token.json (mode 0600),
375
+ // and other credential artifacts created below are protected by
376
+ // the parent dir's perms too. Without 0o700 a co-tenant on the
377
+ // same machine could `ls` the dir and learn the token filenames
378
+ // even if they couldn't read the contents.
379
+ mkdirSync(wotannDir, { recursive: true, mode: 0o700 });
380
+ }
381
+ // SECURITY (B1): mint a fresh session token at daemon startup and
382
+ // persist it to ~/.wotann/session-token.json with mode 0600. The CLI,
383
+ // Desktop shell, and iOS (via the auth.handshake RPC after ECDH pair)
384
+ // read this token and include it on every subsequent request.
385
+ writeSessionToken(join(wotannDir, "session-token.json"));
386
+ this.ipcServer = new KairosIPCServer(this.rpcHandler, {
387
+ socketPath: join(wotannDir, "kairos.sock"),
388
+ maxConnections: 10,
389
+ keepAliveMs: 60_000,
390
+ });
391
+ this.ipcServer.start();
392
+ // T12.18: mint the per-daemon ReplayRegistry BEFORE the WS server
393
+ // starts so any emit site that captures the registry on construction
394
+ // (CompanionServer / RPC subscription forwarders) picks up a live
395
+ // instance rather than null. The registry holds per-session bounded
396
+ // buffers — a reconnecting client can drain missed frames via
397
+ // `replayRegistry.since(sessionId, lastSeq)` after calling
398
+ // `auth.handshake` to re-bind its sessionId. defaultCapacity left at
399
+ // the module default (64) — large enough for typical reconnect
400
+ // windows without flooding memory under abusive clients.
401
+ this.replayRegistry = createReplayRegistry();
402
+ // Phase A5: Start CompanionServer for iOS connections.
403
+ //
404
+ // Round 9: route through resolveCompanionPort() so multiple
405
+ // worktrees / parallel checkouts each get their own deterministic
406
+ // port (3849-3949 range) instead of colliding on a hardcoded
407
+ // 3849. Same cwd → same port across launches; WOTANN_COMPANION_PORT
408
+ // env var is a hard override.
409
+ const companionPort = resolveCompanionPort(this.workingDir);
410
+ this.companionServer = new CompanionServer({ port: companionPort });
411
+ this.companionServer.setRuntime(this.runtime);
412
+ this.companionServer.setBridgeRPCHandler(this.rpcHandler);
413
+ this.companionServer.start();
414
+ // T5 cross-surface dispatch bridge — wire the runtime's
415
+ // UnifiedDispatchPlane to the CompanionServer's WS broadcast so iOS
416
+ // subscribers on `approvals.notify`, `creations.updated`,
417
+ // `cursor.stream`, `live.activity`, `delivery`,
418
+ // `computer.session.events`, `computer.session.handoff`, and
419
+ // `watch.dispatch` actually receive the events the plane already
420
+ // emits in-process. Closes the silent dead-letter at the WS boundary
421
+ // for every F-series cross-surface feature (T5.5/6/7/9/10/11/12/13).
422
+ try {
423
+ const plane = this.runtime.getDispatchPlane();
424
+ this.companionBridge = createCompanionBridge(plane, this.companionServer);
425
+ this.appendLog({
426
+ type: "start",
427
+ message: "T5 companion bridge wired (UnifiedDispatchPlane -> WS topics)",
428
+ });
429
+ }
430
+ catch (err) {
431
+ this.appendLog({
432
+ type: "error",
433
+ message: `Failed to wire companion bridge: ${err instanceof Error ? err.message : String(err)}`,
434
+ });
435
+ }
436
+ // GA-09 / V9 T11.1 — virtual cursor pool + consumer wire.
437
+ // The pool was an audit-flagged 4-file island with zero production
438
+ // importers; this is the SOLE production wire that drives it.
439
+ // Each daemon tick advances the pool by one frame and dispatches
440
+ // the resulting cursor frames through the companion server's
441
+ // broadcast topic so iOS RemoteDesktopView and desktop overlays
442
+ // can render the multi-session cursors.
443
+ try {
444
+ const cursorPool = createVirtualCursorPool();
445
+ const companionRef = this.companionServer;
446
+ const cursorConsumer = createVirtualCursorConsumer({
447
+ pool: cursorPool,
448
+ dispatcher: (frames) => {
449
+ // QB #6 honest stub — when the companion server isn't up
450
+ // (test mode or shutdown race) we drop the dispatch
451
+ // silently because the consumer's diagnostics still
452
+ // surface the tick count + last error.
453
+ if (!companionRef || frames.length === 0)
454
+ return;
455
+ companionRef.broadcastNotification({
456
+ jsonrpc: "2.0",
457
+ method: "cursor.stream",
458
+ params: {
459
+ frames: frames.map((f) => ({
460
+ sessionId: f.sessionId,
461
+ x: f.x,
462
+ y: f.y,
463
+ timestamp: f.timestamp,
464
+ trail: f.trail,
465
+ })),
466
+ },
467
+ });
468
+ },
469
+ });
470
+ this.virtualCursorPool = cursorPool;
471
+ this.virtualCursorConsumer = cursorConsumer;
472
+ this.appendLog({
473
+ type: "start",
474
+ message: "GA-09 T11.1 virtual cursor pool + consumer wired",
475
+ });
476
+ }
477
+ catch (err) {
478
+ this.appendLog({
479
+ type: "error",
480
+ message: `Failed to wire virtual cursor pool: ${err instanceof Error ? err.message : String(err)}`,
481
+ });
482
+ }
483
+ // GA-09 / V9 T11.2 — sleep-time agent + consumer wire.
484
+ // The agent was orphan (zero non-test consumers in src/). This is
485
+ // the SOLE production wire. The consumer fires runIdleSession()
486
+ // when the existing IdleDetector flips to idle (see tick() below),
487
+ // draining the queue against budget + duration caps.
488
+ try {
489
+ const runtimeRef2 = this.runtime;
490
+ // Honest task executor: when the runtime is alive, route the
491
+ // task's payload through runtime.query(). When the runtime
492
+ // failed to initialize (daemon-only mode) we return ok:false
493
+ // with an explicit error rather than silently succeeding —
494
+ // QB #6 honest stub.
495
+ const sleepAgent = createSleepTimeAgent({
496
+ taskExecutor: async (task) => {
497
+ if (!runtimeRef2) {
498
+ return {
499
+ taskId: task.id,
500
+ ok: false,
501
+ outputSummary: "",
502
+ durationMs: 0,
503
+ costUsd: 0,
504
+ error: "runtime-unavailable",
505
+ };
506
+ }
507
+ const startedAt = Date.now();
508
+ try {
509
+ const prompt = typeof task.payload?.prompt === "string"
510
+ ? task.payload.prompt
511
+ : `Sleep-time task: ${task.kind}`;
512
+ let collected = "";
513
+ for await (const chunk of runtimeRef2.query({ prompt })) {
514
+ if (chunk.type === "text")
515
+ collected += chunk.content;
516
+ }
517
+ return {
518
+ taskId: task.id,
519
+ ok: true,
520
+ outputSummary: collected.slice(0, 200),
521
+ durationMs: Date.now() - startedAt,
522
+ // Cost accounting is the runtime's responsibility; we
523
+ // record the floor (estimated cost) here so a silently
524
+ // expensive runtime cycle is caught by aggregate budget.
525
+ costUsd: task.estimatedCostUsd,
526
+ };
527
+ }
528
+ catch (err) {
529
+ return {
530
+ taskId: task.id,
531
+ ok: false,
532
+ outputSummary: "",
533
+ durationMs: Date.now() - startedAt,
534
+ costUsd: task.estimatedCostUsd,
535
+ error: err instanceof Error ? err.message : String(err),
536
+ };
537
+ }
538
+ },
539
+ });
540
+ const sleepConsumer = createSleepTimeConsumer({
541
+ agent: sleepAgent,
542
+ log: (msg) => {
543
+ this.appendLog({ type: "heartbeat", message: msg });
544
+ },
545
+ });
546
+ this.sleepTimeAgent = sleepAgent;
547
+ this.sleepTimeConsumer = sleepConsumer;
548
+ this.appendLog({
549
+ type: "start",
550
+ message: "GA-09 T11.2 sleep-time agent + consumer wired",
551
+ });
552
+ }
553
+ catch (err) {
554
+ this.appendLog({
555
+ type: "error",
556
+ message: `Failed to wire sleep-time agent: ${err instanceof Error ? err.message : String(err)}`,
557
+ });
558
+ }
559
+ // Phase A6: Start Supabase Relay for remote iOS access
560
+ this.supabaseRelay = new SupabaseRelay();
561
+ if (this.supabaseRelay.loadConfig()) {
562
+ void this.supabaseRelay.connect().catch(() => {
563
+ this.appendLog({ type: "error", message: "Supabase relay connection failed" });
564
+ });
565
+ }
566
+ // Phase A6b: Initialize Background Agents (Codex-style task execution)
567
+ this.backgroundAgents.loadPersistedTasks();
568
+ this.backgroundAgents.onStatusChange((status) => {
569
+ this.appendLog({
570
+ type: "heartbeat",
571
+ message: `Agent ${status.id}: ${status.status} (${status.progress}%)`,
572
+ });
573
+ });
574
+ // Phase A6c: Initialize Automations Engine (event-driven agents)
575
+ this.automationEngine.loadConfig();
576
+ this.automationEngine.start();
577
+ // Phase A6d: Initialize Smart File Search (frecency-based)
578
+ this.fileSearch = new SmartFileSearch(this.workingDir);
579
+ // Phase A6e: Build file dependency graph for workspace
580
+ void this.fileDependencyGraph
581
+ .buildFromDirectory(this.workingDir)
582
+ .then(() => {
583
+ this.appendLog({ type: "heartbeat", message: "File dependency graph built" });
584
+ })
585
+ .catch(() => {
586
+ this.appendLog({ type: "error", message: "File dependency graph build failed" });
587
+ });
588
+ // Phase A6f: File watcher DISABLED — fs.watch with recursive:true blocks
589
+ // daemon startup for 2-3 minutes on large workspaces. File change detection
590
+ // is handled by the FileDependencyGraph rebuild on heartbeat instead.
591
+ // TODO: Re-enable with chokidar (non-blocking) or targeted directory watching.
592
+ this.appendLog({
593
+ type: "heartbeat",
594
+ message: "File watcher disabled (use heartbeat-based detection)",
595
+ });
596
+ // Phase A7: Initialize previously-unwired subsystems
597
+ // Marketplace: MCP plugin discovery + skill marketplace
598
+ this.appendLog({ type: "heartbeat", message: "MCP Marketplace initialized" });
599
+ // Sandbox: Task isolation for parallel agent execution
600
+ this.taskIsolation = new TaskIsolationManager(this.workingDir, resolveWotannHomeSubdir("isolation"));
601
+ // Identity: User model for preference learning + reasoning engine for thought process
602
+ this.userModel = new UserModel(resolveWotannHome());
603
+ this.reasoningEngine = new ReasoningEngine();
604
+ // Phase C: Meeting runtime — owns MeetingStore (SQLite at
605
+ // ~/.wotann/meetings.db by default). Coaching is disabled by default
606
+ // (no llmQuery) so transcripts are captured + persisted without
607
+ // spinning the coaching timer on every daemon. Opt-in via
608
+ // MEET_COACHING=1 — when set, a lazy callable routed through
609
+ // WotannRuntime.query() is passed so coaching cycles can consult
610
+ // the model.
611
+ try {
612
+ const coachingEnabled = process.env["MEET_COACHING"] === "1";
613
+ const runtime = this.runtime;
614
+ const baseOpts = { dbPath: join(wotannDir, "meetings.db") };
615
+ const meetOpts = coachingEnabled && runtime
616
+ ? {
617
+ ...baseOpts,
618
+ llmQuery: async (prompt) => {
619
+ let out = "";
620
+ for await (const chunk of runtime.query({ prompt })) {
621
+ if (chunk.type === "text")
622
+ out += chunk.content;
623
+ }
624
+ return out;
625
+ },
626
+ }
627
+ : baseOpts;
628
+ this.meetingRuntime = new MeetingRuntime(meetOpts);
629
+ this.appendLog({
630
+ type: "heartbeat",
631
+ message: `Phase C: MeetingRuntime initialized (transcripts persisted, coaching ${coachingEnabled && runtime ? "on" : "off"})`,
632
+ });
633
+ }
634
+ catch (err) {
635
+ this.appendLog({
636
+ type: "error",
637
+ message: `MeetingRuntime init failed: ${err instanceof Error ? err.message : String(err)}`,
638
+ });
639
+ }
640
+ this.appendLog({
641
+ type: "heartbeat",
642
+ message: "Phase A7 complete: marketplace, sandbox, identity wired",
643
+ });
644
+ // Phase A8: Auto-start channel gateway if any channel credentials are configured.
645
+ // Check for common channel env vars (Slack, Telegram, Discord, etc.)
646
+ const hasChannelCreds = [
647
+ "SLACK_BOT_TOKEN",
648
+ "TELEGRAM_BOT_TOKEN",
649
+ "DISCORD_BOT_TOKEN",
650
+ "WOTANN_WEBCHAT_PORT",
651
+ "GITHUB_WEBHOOK_SECRET",
652
+ ].some((key) => !!process.env[key]);
653
+ if (hasChannelCreds && this.runtime) {
654
+ const rt = this.runtime;
655
+ this.startChannelGateway(async (msg) => {
656
+ let response = "";
657
+ for await (const chunk of rt.query({ prompt: msg.content })) {
658
+ if (chunk.type === "text")
659
+ response += chunk.content;
660
+ }
661
+ return response;
662
+ })
663
+ .then(() => {
664
+ this.appendLog({
665
+ type: "heartbeat",
666
+ message: "Channel gateway auto-started (credentials detected)",
667
+ });
668
+ })
669
+ .catch((err) => {
670
+ this.appendLog({ type: "error", message: `Channel gateway auto-start failed: ${err}` });
671
+ });
672
+ }
673
+ // Phase A7: Wire background workers to runtime and register heartbeat tasks
674
+ if (this.runtime) {
675
+ this.backgroundWorkers.setRuntime(this.runtime);
676
+ }
677
+ const workerTasks = this.backgroundWorkers.toHeartbeatTasks();
678
+ for (const task of workerTasks) {
679
+ this.state = {
680
+ ...this.state,
681
+ heartbeatTasks: [...this.state.heartbeatTasks, task],
682
+ };
683
+ }
684
+ // Phase A8: Run nightly pattern pruning
685
+ this.patternCrystallizer.prune();
686
+ // Phase A9: Wire DreamPipeline to MemoryStore (deferred — async init)
687
+ void this.initDreamPipeline(wotannDir).catch(() => {
688
+ this.appendLog({ type: "error", message: "DreamPipeline initialization failed" });
689
+ });
690
+ // Phase A9b: Load Living Spec if .wotann/SPEC.md exists
691
+ const specPath = join(this.workingDir, ".wotann", "SPEC.md");
692
+ if (existsSync(specPath)) {
693
+ try {
694
+ this.livingSpec = this.livingSpecManager.loadSpec(specPath);
695
+ this.appendLog({
696
+ type: "start",
697
+ message: `Living Spec loaded: "${this.livingSpec.title}" v${this.livingSpec.version} (${this.livingSpec.items.length} items)`,
698
+ });
699
+ }
700
+ catch (err) {
701
+ this.appendLog({
702
+ type: "error",
703
+ message: `Living Spec load failed: ${err instanceof Error ? err.message : String(err)}`,
704
+ });
705
+ }
706
+ }
707
+ // Wave 4F: record the status JSON path so tick() can emit
708
+ // heartbeat telemetry without recomputing it every 30 seconds.
709
+ this.statusJsonPath = join(wotannDir, "daemon.status.json");
710
+ // ── Wave 4F: SQLite-backed cron persistence ───────────
711
+ // Open the cron store BEFORE the tick loop starts so any
712
+ // persisted jobs are visible to getCronJobs() callers and the
713
+ // first tick can fire them. The store manages its own 60s
714
+ // interval — the daemon tick (15s) doesn't try to double-fire.
715
+ try {
716
+ this.cronStore = new CronStore(join(wotannDir, "cron.db"));
717
+ // When the store fires a job, route execution through the
718
+ // daemon's existing execFile path so we benefit from the
719
+ // identical timeout + cwd semantics already used by
720
+ // `executeCronJob()`. This is the one place execFile touches
721
+ // user input, so it stays inside the daemon (not the store).
722
+ this.cronStore.setExecuteHandler((job) => {
723
+ return this.executeCronStoreJob(job);
724
+ });
725
+ // Audit log stuck-job detection: write a "cron" entry with
726
+ // the gap so it shows up alongside normal fire events.
727
+ this.cronStore.setStuckJobHandler((job, gapMs) => {
728
+ this.appendLog({
729
+ type: "cron",
730
+ message: `Stuck cron job detected: "${job.name}" (${Math.floor(gapMs / 3_600_000)}h behind)`,
731
+ data: { jobId: job.id, schedule: job.schedule, gapMs },
732
+ });
733
+ });
734
+ this.cronStore.start();
735
+ // Project persisted jobs into the in-memory state so
736
+ // `getStatus().cronJobs` continues to reflect the full schedule
737
+ // set — CLI and tests shouldn't need to care whether a job came
738
+ // from disk or from addCronJob().
739
+ const persisted = this.cronStore.list();
740
+ if (persisted.length > 0) {
741
+ this.state = {
742
+ ...this.state,
743
+ cronJobs: [...this.state.cronJobs, ...persisted.map(projectRecord)],
744
+ };
745
+ this.appendLog({
746
+ type: "start",
747
+ message: `Cron store loaded: ${persisted.length} jobs rehydrated`,
748
+ data: { enabled: this.cronStore.countEnabled() },
749
+ });
750
+ }
751
+ }
752
+ catch (err) {
753
+ // CronStore init failure must not kill the daemon — fall back
754
+ // to the in-memory cron path that was there before Wave 4F.
755
+ this.appendLog({
756
+ type: "error",
757
+ message: `CronStore init failed (in-memory fallback): ${err instanceof Error ? err.message : String(err)}`,
758
+ });
759
+ this.cronStore = null;
760
+ }
761
+ // ── P1-C2: Hermes-style Cron Scheduler (at-most-once) ──
762
+ // Distinct from the Wave-4F CronStore above. This one owns the
763
+ // `schedule.*` RPC family and uses handler callbacks (not
764
+ // child_process). Persists to `.wotann/schedule.db` so
765
+ // registrations survive restart; handlers are re-registered at
766
+ // boot by their owning modules.
767
+ try {
768
+ this.scheduleStore = new ScheduleStore(join(wotannDir, "schedule.db"));
769
+ this.cronScheduler = new CronScheduler(this.scheduleStore);
770
+ // Wire scheduler events into the daemon audit log so
771
+ // fire/skip/success/failure appear alongside cron rows.
772
+ this.cronScheduler.on("event", (evt) => {
773
+ this.appendLog({
774
+ type: "cron",
775
+ message: `Schedule ${evt.type}: ${evt.taskId}${evt.reason ? ` (${evt.reason})` : ""}${evt.error ? ` — ${evt.error}` : ""}`,
776
+ data: {
777
+ taskId: evt.taskId,
778
+ eventType: evt.type,
779
+ ...(evt.reason !== undefined ? { reason: evt.reason } : {}),
780
+ ...(evt.error !== undefined ? { error: evt.error } : {}),
781
+ ...(evt.durationMs !== undefined ? { durationMs: evt.durationMs } : {}),
782
+ },
783
+ });
784
+ });
785
+ this.cronScheduler.start();
786
+ if (this.scheduleStore.count() > 0) {
787
+ this.appendLog({
788
+ type: "start",
789
+ message: `Schedule registry loaded: ${this.scheduleStore.count()} schedules (${this.scheduleStore.countEnabled()} enabled)`,
790
+ });
791
+ }
792
+ }
793
+ catch (err) {
794
+ // Scheduler init failure mustn't kill the daemon. Legacy
795
+ // CronStore stays intact for any caller that doesn't need
796
+ // at-most-once semantics.
797
+ this.appendLog({
798
+ type: "error",
799
+ message: `CronScheduler init failed: ${err instanceof Error ? err.message : String(err)}`,
800
+ });
801
+ this.scheduleStore = null;
802
+ this.cronScheduler = null;
803
+ }
804
+ // Phase A10: Load event triggers from config
805
+ const triggersPath = join(wotannDir, "triggers.yaml");
806
+ void this.eventTriggerSystem.loadConfig(triggersPath).then((count) => {
807
+ if (count > 0) {
808
+ this.eventTriggerSystem.registerFilesystemTriggers(this.workingDir);
809
+ this.appendLog({
810
+ type: "start",
811
+ message: `Event triggers loaded: ${count} triggers registered`,
812
+ });
813
+ }
814
+ });
815
+ // Phase A11: Wire event trigger result listener to daemon log
816
+ this.eventTriggerSystem.onResult((result) => {
817
+ this.appendLog({
818
+ type: "heartbeat",
819
+ message: `Trigger "${result.triggerName}" ${result.success ? "succeeded" : "failed"}: ${result.message.slice(0, 200)}`,
820
+ data: { source: result.source, durationMs: result.durationMs },
821
+ });
822
+ });
823
+ // Phase A-CONN: Initialize knowledge connector registry (async — deferred)
824
+ void import("../connectors/connector-registry.js")
825
+ .then(({ ConnectorRegistry }) => {
826
+ this.connectorRegistry = new ConnectorRegistry();
827
+ this.appendLog({
828
+ type: "heartbeat",
829
+ message: `Knowledge connectors: registry initialized (${this.connectorRegistry.list().length} registered)`,
830
+ });
831
+ })
832
+ .catch((err) => {
833
+ this.appendLog({
834
+ type: "error",
835
+ message: `Knowledge connectors failed: ${err instanceof Error ? err.message : String(err)}`,
836
+ });
837
+ });
838
+ this.appendLog({
839
+ type: "start",
840
+ message: "KAIROS daemon started with full runtime hosting + self-improvement subsystems + Track C",
841
+ data: {
842
+ ipcSocket: join(wotannDir, "kairos.sock"),
843
+ // Round 9: surface the resolved companion port so the daily
844
+ // log + status panels reflect what the daemon actually bound.
845
+ // CompanionServer.start() may auto-bump on EADDRINUSE — that
846
+ // bump is into the same hash range and visible via the same
847
+ // detail field if a status reader needs it.
848
+ companionPort,
849
+ },
850
+ });
851
+ }
852
+ catch (err) {
853
+ // Runtime initialization failed — daemon still runs for cron/heartbeat
854
+ this.appendLog({
855
+ type: "error",
856
+ message: `Runtime initialization failed: ${err instanceof Error ? err.message : String(err)}. Running in daemon-only mode.`,
857
+ });
858
+ }
859
+ this.state = {
860
+ ...this.state,
861
+ status: "running",
862
+ };
863
+ this.runHeartbeatTasks(new Date(), ["on-wake"]);
864
+ this.tickInterval = setInterval(() => {
865
+ this.tick();
866
+ }, tickIntervalMs);
867
+ }
868
+ stop() {
869
+ if (this.tickInterval) {
870
+ clearInterval(this.tickInterval);
871
+ this.tickInterval = null;
872
+ }
873
+ // Disconnect unified dispatch plane channels on shutdown.
874
+ //
875
+ // V9 Wave 6.7 (M-N5) — explicit catch with logging. Previously the
876
+ // `.catch(() => {})` swallowed disconnect failures silently, so a
877
+ // hung adapter (e.g. a Slack WebSocket frozen mid-close) left no
878
+ // trace in the daemon log. Now we record the failure so post-mortem
879
+ // diagnostics can correlate stranded connections with daemon shutdown.
880
+ if (this.dispatchPlane) {
881
+ void this.dispatchPlane.disconnectAll().catch((err) => {
882
+ this.appendLog({
883
+ type: "error",
884
+ message: `Dispatch plane disconnectAll failed during stop(): ${err instanceof Error ? err.message : String(err)}`,
885
+ });
886
+ });
887
+ this.dispatchPlane = null;
888
+ }
889
+ // Track C: Shut down event triggers and clear ambient signals
890
+ this.eventTriggerSystem.shutdown();
891
+ this.ambientAwareness.clear();
892
+ // Shut down channel servers (GitHub Bot + IDE Bridge)
893
+ if (this.githubBot) {
894
+ this.githubBot.stop();
895
+ this.githubBot = null;
896
+ }
897
+ if (this.ideBridge) {
898
+ this.ideBridge.stop();
899
+ this.ideBridge = null;
900
+ }
901
+ // Phase A6f: Clean up file watcher
902
+ this.fileWatcher?.close();
903
+ this.fileWatcher = null;
904
+ // Phase A: Clean up runtime hosting
905
+ if (this.ipcServer) {
906
+ this.ipcServer.stop();
907
+ this.ipcServer = null;
908
+ }
909
+ // T5 — tear down the companion bridge BEFORE the companion server
910
+ // closes so any in-flight plane events that try to broadcast via the
911
+ // bridge see the dispose'd bridge (no-op) rather than racing a
912
+ // partially-shut WS server. The bridge unsubscribes from the plane
913
+ // and clears its surface-subscriber registry on dispose().
914
+ if (this.companionBridge) {
915
+ try {
916
+ this.companionBridge.dispose();
917
+ }
918
+ catch {
919
+ /* best-effort */
920
+ }
921
+ this.companionBridge = null;
922
+ }
923
+ // GA-09 / V9 T11.1 — tear down virtual cursor pool + consumer BEFORE
924
+ // the companion server closes so any in-flight tick that's
925
+ // dispatching through `companionRef.broadcastNotification` (see
926
+ // start() L527-546) lands in a still-live WS rather than racing the
927
+ // server shutdown. The pool/consumer have no .stop() / .dispose()
928
+ // method (pure-state modules per their own design notes), so we
929
+ // despawn all sessions to release per-cursor state and null the
930
+ // fields. The tickInterval was already cleared at the top of
931
+ // stop() so no in-flight advance() can race this teardown.
932
+ if (this.virtualCursorPool) {
933
+ try {
934
+ // Snapshot is frozen — iterate and despawn each session so the
935
+ // pool's internal Map is empty before we drop the reference.
936
+ for (const cursor of this.virtualCursorPool.snapshot()) {
937
+ this.virtualCursorPool.despawn(cursor.sessionId);
938
+ }
939
+ }
940
+ catch {
941
+ /* best-effort */
942
+ }
943
+ this.virtualCursorPool = null;
944
+ }
945
+ this.virtualCursorConsumer = null;
946
+ if (this.companionServer) {
947
+ this.companionServer.stop();
948
+ this.companionServer = null;
949
+ }
950
+ // T12.18: tear down the replay registry AFTER the WS server has
951
+ // stopped so any in-flight close-handler emits land in the buffer
952
+ // before disposeAll() forbids further appends. disposeAll() clears
953
+ // every per-session buffer and flips the registry into a state where
954
+ // every subsequent append returns `{ok:false, reason:"registry-disposed"}`.
955
+ if (this.replayRegistry) {
956
+ this.replayRegistry.disposeAll();
957
+ this.replayRegistry = null;
958
+ }
959
+ if (this.runtime) {
960
+ this.runtime.close();
961
+ this.runtime = null;
962
+ }
963
+ // Phase C: close the meeting SQLite connection + clear coaching timer
964
+ if (this.meetingRuntime) {
965
+ this.meetingRuntime.close();
966
+ this.meetingRuntime = null;
967
+ }
968
+ // Wave 4F: close the cron store so its WAL checkpoints flush.
969
+ if (this.cronStore) {
970
+ this.cronStore.close();
971
+ this.cronStore = null;
972
+ }
973
+ // P1-C2: stop scheduler ticker and close its SQLite connection.
974
+ if (this.cronScheduler) {
975
+ this.cronScheduler.stop();
976
+ this.cronScheduler = null;
977
+ }
978
+ if (this.scheduleStore) {
979
+ this.scheduleStore.close();
980
+ this.scheduleStore = null;
981
+ }
982
+ // Wave 4-Z: dream-pipeline lifecycle hook. close() is a no-op today
983
+ // (DreamPipeline only holds a shared MemoryStore reference + path
984
+ // string), but we call it for symmetry — future revisions adding a
985
+ // worker pool / interval / preparedStatement won't need to touch
986
+ // this stop() body.
987
+ if (this.dreamPipeline) {
988
+ try {
989
+ this.dreamPipeline.close();
990
+ }
991
+ catch (err) {
992
+ this.appendLog({
993
+ type: "error",
994
+ message: `Dream pipeline close failed: ${err instanceof Error ? err.message : String(err)}`,
995
+ });
996
+ }
997
+ this.dreamPipeline = null;
998
+ }
999
+ // GA-09 / V9 T11.2 — tear down sleep-time agent + consumer. The
1000
+ // agent's taskExecutor closure captured `this.runtime`, which is
1001
+ // now closed (above at L1036-1039); any future task would receive
1002
+ // a runtime-unavailable error from the closure's null guard. The
1003
+ // agent has no .stop() / .dispose() method (pure-logic module per
1004
+ // its design notes); we drain the pending task queue so any
1005
+ // unsubmitted work is reported via clearQueue's count, then null
1006
+ // the fields. The tickInterval was already cleared at the top of
1007
+ // stop() so no in-flight maybeRun() can race this teardown.
1008
+ if (this.sleepTimeAgent) {
1009
+ try {
1010
+ const drained = this.sleepTimeAgent.clearQueue();
1011
+ if (drained > 0) {
1012
+ this.appendLog({
1013
+ type: "stop",
1014
+ message: `Sleep-time agent torn down with ${drained} pending tasks dropped`,
1015
+ });
1016
+ }
1017
+ }
1018
+ catch {
1019
+ /* best-effort */
1020
+ }
1021
+ this.sleepTimeAgent = null;
1022
+ }
1023
+ this.sleepTimeConsumer = null;
1024
+ this.lastSleepSessionAt = null;
1025
+ // V9 Wave 6.7 (M-N3 + M-N4) — dispose the RPC handler so its
1026
+ // subscription-sweep timer is cleared and every remaining polling
1027
+ // subscriber is drained. Idempotent; safe to call even if no
1028
+ // subscribers ever connected.
1029
+ if (this.rpcHandler) {
1030
+ try {
1031
+ this.rpcHandler.dispose();
1032
+ }
1033
+ catch (err) {
1034
+ this.appendLog({
1035
+ type: "error",
1036
+ message: `RPC handler dispose failed: ${err instanceof Error ? err.message : String(err)}`,
1037
+ });
1038
+ }
1039
+ }
1040
+ this.rpcHandler = null;
1041
+ this.appendLog({ type: "stop", message: "KAIROS daemon stopped" });
1042
+ this.state = { ...this.state, status: "stopped" };
1043
+ }
1044
+ /**
1045
+ * Get the hosted WotannRuntime instance.
1046
+ * Returns null if runtime initialization failed.
1047
+ */
1048
+ getRuntime() {
1049
+ return this.runtime;
1050
+ }
1051
+ /**
1052
+ * Get the IPC server for external monitoring.
1053
+ */
1054
+ getIPCServer() {
1055
+ return this.ipcServer;
1056
+ }
1057
+ /**
1058
+ * Get the CompanionServer for iOS connections.
1059
+ */
1060
+ getCompanionServer() {
1061
+ return this.companionServer;
1062
+ }
1063
+ /**
1064
+ * T12.18: Get the per-daemon ReplayRegistry for WebSocket frame
1065
+ * replay. Emit sites (CompanionServer push handlers, RPC subscription
1066
+ * forwarders) that want to capture outgoing frames pull the registry
1067
+ * here and call `append(sessionId, payload)`. Reconnect logic resolves
1068
+ * `since(sessionId, lastSeq)` to drain missed frames.
1069
+ *
1070
+ * Returns null when the daemon hasn't started yet or has already
1071
+ * stopped — callers must branch on null and treat it as "no replay
1072
+ * available, fall back to fresh subscribe".
1073
+ */
1074
+ getReplayRegistry() {
1075
+ return this.replayRegistry;
1076
+ }
1077
+ getStatus() {
1078
+ return this.state;
1079
+ }
1080
+ // ── Self-Improvement Subsystem Getters ──────────────
1081
+ // Accessible from all surfaces via KAIROS RPC
1082
+ getPatternCrystallizer() {
1083
+ return this.patternCrystallizer;
1084
+ }
1085
+ getFeedbackCollector() {
1086
+ return this.feedbackCollector;
1087
+ }
1088
+ getSelfEvolution() {
1089
+ return this.selfEvolution;
1090
+ }
1091
+ getTrajectoryExtractor() {
1092
+ return this.trajectoryExtractor;
1093
+ }
1094
+ getBackgroundWorkers() {
1095
+ return this.backgroundWorkers;
1096
+ }
1097
+ getWorkflowEngine() {
1098
+ return this.workflowEngine;
1099
+ }
1100
+ getSupabaseRelay() {
1101
+ return this.supabaseRelay;
1102
+ }
1103
+ getBackgroundAgents() {
1104
+ return this.backgroundAgents;
1105
+ }
1106
+ getAutomationEngine() {
1107
+ return this.automationEngine;
1108
+ }
1109
+ getFileSearch() {
1110
+ return this.fileSearch;
1111
+ }
1112
+ getCostOracle() {
1113
+ return this.costOracle;
1114
+ }
1115
+ getSkillMerger() {
1116
+ return this.skillMerger;
1117
+ }
1118
+ getDreamPipeline() {
1119
+ return this.dreamPipeline;
1120
+ }
1121
+ // ── Phase A7 Getters (marketplace, sandbox, identity, perception) ──
1122
+ // S5-3: getMCPMarketplace removed — callers should use getMCPRegistry.
1123
+ getMCPRegistry() {
1124
+ return this.mcpRegistry;
1125
+ }
1126
+ getSkillMarketplace() {
1127
+ return this.skillMarketplace;
1128
+ }
1129
+ getDockerSandbox() {
1130
+ return this.dockerSandbox;
1131
+ }
1132
+ getTaskIsolation() {
1133
+ return this.taskIsolation;
1134
+ }
1135
+ getTerminalManager() {
1136
+ return this.terminalManager;
1137
+ }
1138
+ // TIER 2 cleanup: getPluginScanner() removed alongside the zombie instance
1139
+ // (0 callers verified per QB#19). Call sites should construct
1140
+ // PluginScanner directly from src/lib.ts when wiring plugin scanning.
1141
+ getReasoningEngine() {
1142
+ return this.reasoningEngine;
1143
+ }
1144
+ getUserModel() {
1145
+ return this.userModel;
1146
+ }
1147
+ getPerceptionEngine() {
1148
+ return this.perceptionEngine;
1149
+ }
1150
+ /**
1151
+ * Get the MeetingRuntime adapter for RPC callers.
1152
+ *
1153
+ * Returns `null` (not a silent stub) when the runtime hasn't been
1154
+ * initialized yet — callers must check and degrade gracefully. This is
1155
+ * the channel the `getMeetingStore?` ext() callback in kairos-rpc.ts
1156
+ * reads, making `meet.summarize` actually resolve transcripts from
1157
+ * SQLite instead of returning undefined.
1158
+ */
1159
+ getMeetingStore() {
1160
+ return this.meetingRuntime;
1161
+ }
1162
+ getEventTriggerSystem() {
1163
+ return this.eventTriggerSystem;
1164
+ }
1165
+ getAmbientAwareness() {
1166
+ return this.ambientAwareness;
1167
+ }
1168
+ /**
1169
+ * Get the PWR engine for phase cycle management.
1170
+ */
1171
+ getPWREngine() {
1172
+ return this.pwrEngine;
1173
+ }
1174
+ /**
1175
+ * Get the GitHub Bot adapter (null if not started).
1176
+ */
1177
+ getGitHubBot() {
1178
+ return this.githubBot;
1179
+ }
1180
+ /**
1181
+ * Get the IDE Bridge adapter (null if not started).
1182
+ */
1183
+ getIDEBridge() {
1184
+ return this.ideBridge;
1185
+ }
1186
+ /**
1187
+ * Run Ralph mode: persistent verify-fix loop until all tests pass.
1188
+ * Exposed for CLI `wotann ralph` command.
1189
+ */
1190
+ async runRalph(config, verifier, fixer) {
1191
+ this.appendLog({ type: "heartbeat", message: `Ralph mode started: ${config.description}` });
1192
+ const result = await runRalphMode(config, verifier, fixer);
1193
+ this.appendLog({
1194
+ type: "heartbeat",
1195
+ message: `Ralph mode ${result.success ? "succeeded" : "failed"} after ${result.cycles} cycles (${result.hud.totalDurationMs}ms)`,
1196
+ });
1197
+ return result;
1198
+ }
1199
+ /**
1200
+ * Forward a GitHub event to the event trigger system.
1201
+ * Called by the webhook channel adapter when a GitHub event arrives.
1202
+ */
1203
+ handleGithubEvent(event) {
1204
+ this.eventTriggerSystem.handleGithubEvent(event);
1205
+ // Session-13: PR-merge events → AutoArchiveHook for session archive +
1206
+ // branch cleanup. Honest: we only trigger on pull_request.closed
1207
+ // events whose payload declares merged=true. Missing payload fields
1208
+ // leave the archive unrun rather than silently succeeding.
1209
+ if (event.type === "pull_request.closed") {
1210
+ const payload = event.payload;
1211
+ const prNumber = typeof payload?.["number"] === "number" ? payload["number"] : undefined;
1212
+ const merged = payload?.["merged"] === true;
1213
+ if (merged && prNumber !== undefined) {
1214
+ const branchName = typeof payload["branch"] === "string" ? payload["branch"] : `pr-${prNumber}`;
1215
+ void this.autoArchiveHook
1216
+ .onPRMerge(prNumber, branchName)
1217
+ .then((result) => {
1218
+ this.appendLog({
1219
+ type: "heartbeat",
1220
+ message: `Auto-archive PR #${prNumber}: session=${result.sessionArchived} worktree=${result.worktreeRemoved}`,
1221
+ });
1222
+ })
1223
+ .catch((err) => {
1224
+ this.appendLog({
1225
+ type: "error",
1226
+ message: `Auto-archive PR #${prNumber} failed: ${err instanceof Error ? err.message : String(err)}`,
1227
+ });
1228
+ });
1229
+ }
1230
+ }
1231
+ }
1232
+ /**
1233
+ * Session-13: record a rate-limit hit into RateLimitResumeManager so
1234
+ * the manager can plan a fallback provider or exponential backoff.
1235
+ * Invoked by the router / adapter error path when a 429 lands.
1236
+ */
1237
+ recordRateLimit(provider, retryAfterMs, snapshot) {
1238
+ try {
1239
+ const state = this.rateLimitResume.onRateLimit(provider, retryAfterMs, snapshot);
1240
+ this.appendLog({
1241
+ type: "heartbeat",
1242
+ message: `Rate-limit: ${provider} retry#${state.retryCount} in ${retryAfterMs}ms`,
1243
+ });
1244
+ }
1245
+ catch (err) {
1246
+ this.appendLog({
1247
+ type: "error",
1248
+ message: `Rate-limit record failed: ${err instanceof Error ? err.message : String(err)}`,
1249
+ });
1250
+ }
1251
+ }
1252
+ getRateLimitResumeManager() {
1253
+ return this.rateLimitResume;
1254
+ }
1255
+ getAutoArchiveHook() {
1256
+ return this.autoArchiveHook;
1257
+ }
1258
+ /**
1259
+ * Start the channel gateway for multi-channel messaging.
1260
+ * Channels connect to the gateway, which routes messages to the agent.
1261
+ * Returns the gateway instance for external control.
1262
+ */
1263
+ async startChannelGateway(messageHandler, options = {}) {
1264
+ this.gateway = new ChannelGateway({ requirePairing: options.requirePairing ?? true });
1265
+ this.gateway.setMessageHandler(async (msg) => {
1266
+ // PWR cycle: auto-detect phase transitions from inbound messages
1267
+ const pwrResult = this.pwrEngine.processMessage(msg.content);
1268
+ if (pwrResult.transitioned) {
1269
+ this.appendLog({
1270
+ type: "heartbeat",
1271
+ message: `PWR phase transition: ${pwrResult.direction} → ${pwrResult.newPhase}`,
1272
+ });
1273
+ }
1274
+ return messageHandler(msg);
1275
+ });
1276
+ const selections = resolveChannelSelections(options);
1277
+ if (selections.webchat) {
1278
+ try {
1279
+ const { WebChatAdapter } = await import("../channels/webchat.js");
1280
+ this.gateway.registerAdapter(new WebChatAdapter({
1281
+ port: options.webchatPort ?? 3847,
1282
+ host: options.webchatHost ?? "127.0.0.1",
1283
+ }));
1284
+ }
1285
+ catch {
1286
+ /* webchat not available */
1287
+ }
1288
+ }
1289
+ if (selections.telegram) {
1290
+ try {
1291
+ const { TelegramAdapter } = await import("../channels/telegram.js");
1292
+ this.gateway.registerAdapter(wrapLegacyAdapter(new TelegramAdapter()));
1293
+ }
1294
+ catch {
1295
+ /* telegram not available */
1296
+ }
1297
+ }
1298
+ if (selections.slack) {
1299
+ try {
1300
+ const { SlackAdapter } = await import("../channels/slack.js");
1301
+ this.gateway.registerAdapter(wrapLegacyAdapter(new SlackAdapter()));
1302
+ }
1303
+ catch {
1304
+ /* slack not available */
1305
+ }
1306
+ }
1307
+ if (selections.discord) {
1308
+ try {
1309
+ const { DiscordAdapter } = await import("../channels/discord.js");
1310
+ this.gateway.registerAdapter(wrapLegacyAdapter(new DiscordAdapter()));
1311
+ }
1312
+ catch {
1313
+ /* discord not available */
1314
+ }
1315
+ }
1316
+ // Extended channels — gateway-native adapters (import from gateway.js)
1317
+ if (selections.signal) {
1318
+ try {
1319
+ const { SignalAdapter } = await import("../channels/signal.js");
1320
+ this.gateway.registerAdapter(new SignalAdapter());
1321
+ }
1322
+ catch {
1323
+ /* signal-cli not available */
1324
+ }
1325
+ }
1326
+ if (selections.whatsapp) {
1327
+ try {
1328
+ const { WhatsAppAdapter } = await import("../channels/whatsapp.js");
1329
+ const { wrapLegacyAdapter } = await import("../channels/integration.js");
1330
+ this.gateway.registerAdapter(wrapLegacyAdapter(new WhatsAppAdapter()));
1331
+ }
1332
+ catch {
1333
+ /* baileys not available */
1334
+ }
1335
+ }
1336
+ if (selections.email) {
1337
+ try {
1338
+ const { EmailAdapter } = await import("../channels/email.js");
1339
+ this.gateway.registerAdapter(new EmailAdapter());
1340
+ }
1341
+ catch {
1342
+ /* email config not available */
1343
+ }
1344
+ }
1345
+ if (selections.webhook) {
1346
+ try {
1347
+ const { WebhookAdapter } = await import("../channels/webhook.js");
1348
+ this.gateway.registerAdapter(new WebhookAdapter());
1349
+ }
1350
+ catch {
1351
+ /* webhook not configured */
1352
+ }
1353
+ }
1354
+ // Extended channels — legacy adapters (import from adapter.js, need wrapping)
1355
+ if (selections.sms) {
1356
+ try {
1357
+ const { SMSAdapter } = await import("../channels/sms.js");
1358
+ this.gateway.registerAdapter(wrapLegacyAdapter(new SMSAdapter()));
1359
+ }
1360
+ catch {
1361
+ /* twilio not configured */
1362
+ }
1363
+ }
1364
+ if (selections.matrix) {
1365
+ try {
1366
+ const { MatrixAdapter } = await import("../channels/matrix.js");
1367
+ this.gateway.registerAdapter(wrapLegacyAdapter(new MatrixAdapter()));
1368
+ }
1369
+ catch {
1370
+ /* matrix not configured */
1371
+ }
1372
+ }
1373
+ if (selections.teams) {
1374
+ try {
1375
+ const { TeamsAdapter } = await import("../channels/teams.js");
1376
+ this.gateway.registerAdapter(wrapLegacyAdapter(new TeamsAdapter()));
1377
+ }
1378
+ catch {
1379
+ /* teams not configured */
1380
+ }
1381
+ }
1382
+ // iMessage adapter (macOS only — uses AppleScript + chat.db)
1383
+ try {
1384
+ const { IMessageGatewayAdapter } = await import("../channels/imessage-gateway-adapter.js");
1385
+ const imsgAdapter = new IMessageGatewayAdapter();
1386
+ if (imsgAdapter.connected || process.platform === "darwin") {
1387
+ this.gateway.registerAdapter(imsgAdapter);
1388
+ this.appendLog({ type: "heartbeat", message: "Channel: iMessage adapter registered" });
1389
+ }
1390
+ }
1391
+ catch {
1392
+ /* imessage not available — non-macOS or chat.db inaccessible */
1393
+ }
1394
+ // IRC adapter (E9): opt-in via IRC_SERVER + IRC_NICK env vars.
1395
+ // IRCAdapter implements gateway.ChannelAdapter directly — no wrap needed.
1396
+ if (process.env["IRC_SERVER"] && process.env["IRC_NICK"]) {
1397
+ try {
1398
+ const { IRCAdapter } = await import("../channels/irc.js");
1399
+ const ircAdapter = new IRCAdapter({
1400
+ server: process.env["IRC_SERVER"],
1401
+ port: parseInt(process.env["IRC_PORT"] ?? "6697", 10),
1402
+ nick: process.env["IRC_NICK"],
1403
+ user: process.env["IRC_USER"] ?? process.env["IRC_NICK"],
1404
+ realname: process.env["IRC_REALNAME"] ?? "WOTANN",
1405
+ channels: (process.env["IRC_CHANNELS"] ?? "").split(",").filter((c) => c.length > 0),
1406
+ useTLS: process.env["IRC_TLS"] !== "false",
1407
+ });
1408
+ this.gateway.registerAdapter(ircAdapter);
1409
+ this.appendLog({ type: "heartbeat", message: "Channel: IRC adapter registered" });
1410
+ }
1411
+ catch (err) {
1412
+ this.appendLog({
1413
+ type: "heartbeat",
1414
+ message: `Channel: IRC registration failed — ${err instanceof Error ? err.message : String(err)}`,
1415
+ });
1416
+ }
1417
+ }
1418
+ // Google Chat adapter (E9): opt-in via GOOGLE_CHAT_WEBHOOK env var.
1419
+ // GoogleChatAdapter implements gateway.ChannelAdapter directly — no wrap needed.
1420
+ if (process.env["GOOGLE_CHAT_WEBHOOK"] || process.env["GOOGLE_CHAT_SERVICE_ACCOUNT"]) {
1421
+ try {
1422
+ const { GoogleChatAdapter } = await import("../channels/google-chat.js");
1423
+ const gchat = new GoogleChatAdapter({
1424
+ webhookUrl: process.env["GOOGLE_CHAT_WEBHOOK"],
1425
+ serviceAccountKey: process.env["GOOGLE_CHAT_SERVICE_ACCOUNT"],
1426
+ spaceName: process.env["GOOGLE_CHAT_SPACE"],
1427
+ });
1428
+ this.gateway.registerAdapter(gchat);
1429
+ this.appendLog({ type: "heartbeat", message: "Channel: Google Chat adapter registered" });
1430
+ }
1431
+ catch (err) {
1432
+ this.appendLog({
1433
+ type: "heartbeat",
1434
+ message: `Channel: Google Chat registration failed — ${err instanceof Error ? err.message : String(err)}`,
1435
+ });
1436
+ }
1437
+ }
1438
+ // GitHub Bot: start webhook server for @wotann mentions in issues/PRs
1439
+ if (process.env["GITHUB_WEBHOOK_SECRET"] || options.webhook) {
1440
+ try {
1441
+ this.githubBot = new GitHubBot({
1442
+ webhookSecret: process.env["GITHUB_WEBHOOK_SECRET"],
1443
+ port: 7743,
1444
+ });
1445
+ this.githubBot.onMention((event) => {
1446
+ this.handleGithubEvent({
1447
+ type: `${event.type}.${event.action}`,
1448
+ repo: event.repo,
1449
+ sender: event.author,
1450
+ payload: { body: event.body, number: event.number, url: event.url },
1451
+ receivedAt: event.timestamp,
1452
+ });
1453
+ });
1454
+ void this.githubBot.start().catch(() => {
1455
+ this.appendLog({ type: "error", message: "GitHub Bot webhook server failed to start" });
1456
+ });
1457
+ }
1458
+ catch {
1459
+ /* github bot not available */
1460
+ }
1461
+ }
1462
+ // IDE Bridge: start JSON-RPC server for VS Code/Cursor integration
1463
+ try {
1464
+ this.ideBridge = new IDEBridge({ port: 7742 });
1465
+ void this.ideBridge.start().catch(() => {
1466
+ this.appendLog({ type: "error", message: "IDE Bridge server failed to start" });
1467
+ });
1468
+ }
1469
+ catch {
1470
+ /* ide bridge not available */
1471
+ }
1472
+ // NB-5 fix: register any credentials-discovered adapters that the
1473
+ // hand-curated `selections` switchboard above didn't cover. These are
1474
+ // the 6 channel types whose adapter classes existed but were only
1475
+ // instantiated by `createAvailableAdapters` for credential-based
1476
+ // discovery and never registered with the gateway: Mastodon, WeChat,
1477
+ // Line, Viber, DingTalk, Feishu. Without this loop the gateway code
1478
+ // path is dead for all 6. Skipping types already registered by the
1479
+ // selections switchboard above preserves explicit configuration.
1480
+ try {
1481
+ const alreadyRegistered = new Set(this.gateway.getRegisteredChannels());
1482
+ const extra = createAvailableAdapters();
1483
+ let extraRegistered = 0;
1484
+ for (const result of extra) {
1485
+ if (!result.adapter)
1486
+ continue;
1487
+ if (alreadyRegistered.has(result.type))
1488
+ continue;
1489
+ try {
1490
+ this.gateway.registerAdapter(wrapLegacyAdapter(result.adapter));
1491
+ extraRegistered += 1;
1492
+ }
1493
+ catch {
1494
+ /* skip on registration failure */
1495
+ }
1496
+ }
1497
+ if (extraRegistered > 0) {
1498
+ this.appendLog({
1499
+ type: "heartbeat",
1500
+ message: `Channel: registered ${extraRegistered} additional credentialed adapter(s) via auto-detect`,
1501
+ });
1502
+ }
1503
+ }
1504
+ catch {
1505
+ /* auto-detect not available or no extra adapters */
1506
+ }
1507
+ // Phase-C wire-up: now that every adapter is registered on the
1508
+ // gateway, stand up the route-policy engine with a default policy
1509
+ // for each channel. This activates the 412-LOC policy module
1510
+ // (auth/pairing/rate-limit/escalation/response-formatting) that
1511
+ // was previously unreachable from the gateway code path.
1512
+ //
1513
+ // TODO(channels.setPolicy RPC): the richer RoutePolicy type here
1514
+ // differs from kairos-rpc.ts's DispatchRoutePolicy (which only
1515
+ // covers provider/model routing). Once the RPC surface is
1516
+ // unified, expose `channels.setPolicy(channel, policy)` via
1517
+ // kairos-rpc.ts to let CLI/Desktop mutate these policies at
1518
+ // runtime — matching the existing channels.policy.{list,add,remove}
1519
+ // pattern but targeting this engine instead of the dispatch plane's.
1520
+ this.routePolicyEngine = new RoutePolicyEngine();
1521
+ for (const channel of this.gateway.getRegisteredChannels()) {
1522
+ this.routePolicyEngine.registerChannel(channel, createDefaultPolicy(channel));
1523
+ }
1524
+ this.gateway.setRoutePolicyEngine(this.routePolicyEngine);
1525
+ this.appendLog({
1526
+ type: "heartbeat",
1527
+ message: `Route policy engine wired: ${this.gateway.getRegisteredChannels().length} channels with default policies`,
1528
+ });
1529
+ await this.gateway.connectAll();
1530
+ this.appendLog({
1531
+ type: "start",
1532
+ message: `Channel gateway started with ${this.gateway.getAdapterCount()} adapters`,
1533
+ });
1534
+ return this.gateway;
1535
+ }
1536
+ getGateway() {
1537
+ return this.gateway;
1538
+ }
1539
+ /**
1540
+ * Get the route-policy engine backing the channel gateway (null until
1541
+ * startChannelGateway has run). Exposed for RPC handlers and tests.
1542
+ */
1543
+ getRoutePolicyEngine() {
1544
+ return this.routePolicyEngine;
1545
+ }
1546
+ /**
1547
+ * Start the unified dispatch plane for task-based channel routing.
1548
+ * The dispatch plane supersedes the legacy gateway with a task inbox,
1549
+ * cross-channel routing, health dashboard, and policy management.
1550
+ */
1551
+ async startDispatchPlane(messageHandler, options = {}) {
1552
+ this.dispatchPlane = new UnifiedDispatchPlane({
1553
+ requirePairing: options.requirePairing ?? true,
1554
+ });
1555
+ this.dispatchPlane.setMessageHandler(async (msg) => messageHandler(msg));
1556
+ const selections = resolveChannelSelections(options);
1557
+ if (selections.webchat) {
1558
+ try {
1559
+ const { WebChatAdapter } = await import("../channels/webchat.js");
1560
+ this.dispatchPlane.registerAdapter(new WebChatAdapter({
1561
+ port: options.webchatPort ?? 3847,
1562
+ host: options.webchatHost ?? "127.0.0.1",
1563
+ }));
1564
+ }
1565
+ catch {
1566
+ /* webchat not available */
1567
+ }
1568
+ }
1569
+ if (selections.telegram) {
1570
+ try {
1571
+ const { TelegramAdapter } = await import("../channels/telegram.js");
1572
+ this.dispatchPlane.registerAdapter(wrapLegacyAdapter(new TelegramAdapter()));
1573
+ }
1574
+ catch {
1575
+ /* telegram not available */
1576
+ }
1577
+ }
1578
+ if (selections.slack) {
1579
+ try {
1580
+ const { SlackAdapter } = await import("../channels/slack.js");
1581
+ this.dispatchPlane.registerAdapter(wrapLegacyAdapter(new SlackAdapter()));
1582
+ }
1583
+ catch {
1584
+ /* slack not available */
1585
+ }
1586
+ }
1587
+ if (selections.discord) {
1588
+ try {
1589
+ const { DiscordAdapter } = await import("../channels/discord.js");
1590
+ this.dispatchPlane.registerAdapter(wrapLegacyAdapter(new DiscordAdapter()));
1591
+ }
1592
+ catch {
1593
+ /* discord not available */
1594
+ }
1595
+ }
1596
+ // Extended channels — gateway-native adapters
1597
+ if (selections.signal) {
1598
+ try {
1599
+ const { SignalAdapter } = await import("../channels/signal.js");
1600
+ this.dispatchPlane.registerAdapter(new SignalAdapter());
1601
+ }
1602
+ catch {
1603
+ /* signal not available */
1604
+ }
1605
+ }
1606
+ if (selections.whatsapp) {
1607
+ try {
1608
+ const { WhatsAppAdapter } = await import("../channels/whatsapp.js");
1609
+ const { wrapLegacyAdapter } = await import("../channels/integration.js");
1610
+ this.dispatchPlane.registerAdapter(wrapLegacyAdapter(new WhatsAppAdapter()));
1611
+ }
1612
+ catch {
1613
+ /* whatsapp not available */
1614
+ }
1615
+ }
1616
+ if (selections.email) {
1617
+ try {
1618
+ const { EmailAdapter } = await import("../channels/email.js");
1619
+ this.dispatchPlane.registerAdapter(new EmailAdapter());
1620
+ }
1621
+ catch {
1622
+ /* email not available */
1623
+ }
1624
+ }
1625
+ if (selections.webhook) {
1626
+ try {
1627
+ const { WebhookAdapter } = await import("../channels/webhook.js");
1628
+ this.dispatchPlane.registerAdapter(new WebhookAdapter());
1629
+ }
1630
+ catch {
1631
+ /* webhook not available */
1632
+ }
1633
+ }
1634
+ // Extended channels — legacy adapters
1635
+ if (selections.sms) {
1636
+ try {
1637
+ const { SMSAdapter } = await import("../channels/sms.js");
1638
+ this.dispatchPlane.registerAdapter(wrapLegacyAdapter(new SMSAdapter()));
1639
+ }
1640
+ catch {
1641
+ /* sms not available */
1642
+ }
1643
+ }
1644
+ if (selections.matrix) {
1645
+ try {
1646
+ const { MatrixAdapter } = await import("../channels/matrix.js");
1647
+ this.dispatchPlane.registerAdapter(wrapLegacyAdapter(new MatrixAdapter()));
1648
+ }
1649
+ catch {
1650
+ /* matrix not available */
1651
+ }
1652
+ }
1653
+ if (selections.teams) {
1654
+ try {
1655
+ const { TeamsAdapter } = await import("../channels/teams.js");
1656
+ this.dispatchPlane.registerAdapter(wrapLegacyAdapter(new TeamsAdapter()));
1657
+ }
1658
+ catch {
1659
+ /* teams not available */
1660
+ }
1661
+ }
1662
+ // iMessage adapter (macOS only — uses AppleScript + chat.db)
1663
+ try {
1664
+ const { IMessageGatewayAdapter } = await import("../channels/imessage-gateway-adapter.js");
1665
+ const imsgAdapter = new IMessageGatewayAdapter();
1666
+ if (imsgAdapter.connected || process.platform === "darwin") {
1667
+ this.dispatchPlane.registerAdapter(imsgAdapter);
1668
+ this.appendLog({ type: "heartbeat", message: "Dispatch: iMessage adapter registered" });
1669
+ }
1670
+ }
1671
+ catch {
1672
+ /* imessage not available — non-macOS or chat.db inaccessible */
1673
+ }
1674
+ const result = await this.dispatchPlane.connectAll();
1675
+ const totalAdapters = result.connected.length + result.failed.length;
1676
+ this.appendLog({
1677
+ type: "start",
1678
+ message: `Unified dispatch plane started: ${result.connected.length}/${totalAdapters} adapters connected`,
1679
+ data: { connected: result.connected, failed: result.failed },
1680
+ });
1681
+ // Wire the computer-session store from the RPC handler into the dispatch
1682
+ // plane so session events propagate to every connected surface (Phase 3
1683
+ // P1-F1). The store remains owned by KairosRPCHandler (single source of
1684
+ // truth per QB #7); the plane is the bus.
1685
+ if (this.rpcHandler) {
1686
+ try {
1687
+ const sessionStore = this.rpcHandler.getComputerSessionStore();
1688
+ this.dispatchPlane.attachComputerSessionStore(sessionStore);
1689
+ }
1690
+ catch {
1691
+ // RPC handler method may not exist in old builds — ignore to keep
1692
+ // startup resilient.
1693
+ }
1694
+ }
1695
+ return this.dispatchPlane;
1696
+ }
1697
+ getDispatchPlane() {
1698
+ return this.dispatchPlane;
1699
+ }
1700
+ tick() {
1701
+ // Wave 4-AA: reentrancy guard. If the prior tick's async work is still
1702
+ // running (e.g. dream pipeline, codebase health, sleep-time consumer),
1703
+ // skip this scheduled invocation rather than double-fire. The setInterval
1704
+ // contract is "every Nms attempt a tick", not "every Nms guarantee a tick",
1705
+ // so dropping a single tick under load is the honest behaviour.
1706
+ if (this.tickInFlight) {
1707
+ console.warn("[KAIROS] skip tick — previous tick still running");
1708
+ return;
1709
+ }
1710
+ this.tickInFlight = true;
1711
+ try {
1712
+ this.tickBody();
1713
+ }
1714
+ finally {
1715
+ this.tickInFlight = false;
1716
+ }
1717
+ }
1718
+ tickBody() {
1719
+ this.state = {
1720
+ ...this.state,
1721
+ tickCount: this.state.tickCount + 1,
1722
+ };
1723
+ const now = new Date();
1724
+ this.appendLog({ type: "tick", message: `Tick ${this.state.tickCount}` });
1725
+ this.runHeartbeatTasks(now, ["periodic", "nightly"]);
1726
+ // ── Wave 4F: heartbeat telemetry (~30s cadence) ────────
1727
+ // At the 15s default tick, every 2nd tick writes a snapshot to
1728
+ // `.wotann/daemon.status.json` so external callers (CLI status,
1729
+ // TUI dashboard, mobile surface) can read a cheap record without
1730
+ // paying the IPC round-trip. The heartbeat log entry makes the
1731
+ // cadence visible in the daily JSONL for post-hoc analysis.
1732
+ this.telemetryTickCounter++;
1733
+ if (this.telemetryTickCounter % 2 === 0) {
1734
+ this.emitHeartbeatTelemetry(now);
1735
+ }
1736
+ // FlowTracker: record tick event for developer flow state tracking
1737
+ this.flowTracker.track({
1738
+ type: "terminal_command",
1739
+ timestamp: Date.now(),
1740
+ details: { tick: this.state.tickCount },
1741
+ command: "daemon-tick",
1742
+ });
1743
+ // IdleDetector: check if user is idle and generate away summary on return
1744
+ const wasIdle = this.idleDetector.checkIdle();
1745
+ if (wasIdle && this.idleDetector.getIdleDurationMs() > 0) {
1746
+ const idleDuration = this.idleDetector.getIdleDurationMs();
1747
+ const idleMinutes = Math.floor(idleDuration / 60_000);
1748
+ if (idleMinutes >= 5) {
1749
+ this.appendLog({
1750
+ type: "heartbeat",
1751
+ message: `User idle for ${idleMinutes} minutes`,
1752
+ data: { idleDurationMs: idleDuration },
1753
+ });
1754
+ // Surface idle notification via push
1755
+ pushNotification({
1756
+ title: "WOTANN — Away Summary",
1757
+ body: `You've been away for ${idleMinutes} minutes.`,
1758
+ urgency: "low",
1759
+ });
1760
+ }
1761
+ }
1762
+ // Check cron jobs
1763
+ for (const job of this.state.cronJobs) {
1764
+ if (job.enabled && this.shouldRunCron(job, now)) {
1765
+ this.executeCronJob(job);
1766
+ }
1767
+ }
1768
+ // Track C: Check event trigger cron schedules
1769
+ this.eventTriggerSystem.checkCronTriggers(now);
1770
+ // Track C: Ambient awareness — check signals every 4th tick (~1 min at 15s ticks)
1771
+ this.ambientTickCounter++;
1772
+ if (this.ambientTickCounter % 4 === 0) {
1773
+ const suggestion = this.ambientAwareness.getProactiveSuggestion();
1774
+ if (suggestion) {
1775
+ this.appendLog({
1776
+ type: "heartbeat",
1777
+ message: `Ambient signal: ${suggestion.slice(0, 200)}`,
1778
+ data: { signalCount: this.ambientAwareness.getSignalCount() },
1779
+ });
1780
+ // Surface ambient suggestion as a desktop notification
1781
+ pushNotification({
1782
+ title: "WOTANN — Ambient",
1783
+ body: suggestion.slice(0, 200),
1784
+ urgency: "low",
1785
+ });
1786
+ }
1787
+ // FlowTracker: check for developer struggle signals
1788
+ if (this.flowTracker.detectStruggle()) {
1789
+ this.appendLog({
1790
+ type: "heartbeat",
1791
+ message: "FlowTracker: developer appears to be struggling (3+ error-fix cycles)",
1792
+ data: { velocity: this.flowTracker.getVelocity() },
1793
+ });
1794
+ pushNotification({
1795
+ title: "WOTANN — Flow",
1796
+ body: "Rapid error-fix cycles detected. Consider a different approach.",
1797
+ urgency: "normal",
1798
+ });
1799
+ }
1800
+ // Proactive health checks (cost, CI, stale approvals).
1801
+ //
1802
+ // V9 Wave 6.7 (M-N11) — wrap with explicit logging. The check is
1803
+ // non-fatal, but a silent swallow makes it impossible to notice
1804
+ // when (e.g.) the cost oracle's CI poll is rate-limited 100% of
1805
+ // the time. We log at heartbeat level — not error — to keep the
1806
+ // signal calm but visible.
1807
+ void proactiveCheck(this.costOracle).catch((err) => {
1808
+ this.appendLog({
1809
+ type: "heartbeat",
1810
+ message: `proactiveCheck failed (non-fatal): ${err instanceof Error ? err.message : String(err)}`,
1811
+ });
1812
+ });
1813
+ }
1814
+ // Proactive heartbeat — every 20th tick (~5 min at 15s intervals)
1815
+ this.heartbeatTickCounter++;
1816
+ if (this.heartbeatTickCounter % 20 === 0) {
1817
+ // V9 Wave 6.7 (M-N11) — explicit catch with heartbeat-level log
1818
+ // (mirrors the proactiveCheck wire above). Non-fatal but observable.
1819
+ void proactiveHeartbeatCheck({
1820
+ activeTasks: this.backgroundAgents.listTasks(),
1821
+ }).catch((err) => {
1822
+ this.appendLog({
1823
+ type: "heartbeat",
1824
+ message: `proactiveHeartbeatCheck failed (non-fatal): ${err instanceof Error ? err.message : String(err)}`,
1825
+ });
1826
+ });
1827
+ }
1828
+ // Model discovery — refresh provider model lists every 400th tick (~100 minutes at 15s intervals)
1829
+ this.modelRefreshTickCounter++;
1830
+ if (this.modelRefreshTickCounter % 400 === 0) {
1831
+ const creds = {
1832
+ anthropicKey: process.env["ANTHROPIC_API_KEY"],
1833
+ openaiKey: process.env["OPENAI_API_KEY"],
1834
+ geminiKey: process.env["GEMINI_API_KEY"],
1835
+ githubToken: process.env["GITHUB_TOKEN"],
1836
+ ollamaHost: process.env["OLLAMA_HOST"],
1837
+ groqKey: process.env["GROQ_API_KEY"],
1838
+ };
1839
+ void discoverModels(creds)
1840
+ .then((models) => {
1841
+ if (models.length > 0) {
1842
+ this.appendLog({
1843
+ type: "heartbeat",
1844
+ message: `Model discovery: ${models.length} models found`,
1845
+ });
1846
+ }
1847
+ })
1848
+ .catch(() => {
1849
+ /* non-fatal */
1850
+ });
1851
+ }
1852
+ // Track C: Dream pipeline — run nightly (between 02:00-04:00 UTC, once per day)
1853
+ // UTC for DST-safety per Wave 3-Q — local-time windows skip the
1854
+ // spring-forward hour and double-fire the fall-back hour.
1855
+ if (this.dreamPipeline && now.getUTCHours() >= 2 && now.getUTCHours() < 4) {
1856
+ this.checkAndRunDreamPipeline(now);
1857
+ }
1858
+ // Codebase health check — run once per day (between 03:00-05:00 UTC)
1859
+ // UTC for DST-safety per Wave 3-Q
1860
+ if (now.getUTCHours() >= 3 && now.getUTCHours() < 5) {
1861
+ this.checkAndRunCodebaseHealth(now);
1862
+ }
1863
+ // Skill prompt optimization — nightly, once per day (between 02:00-04:00 UTC)
1864
+ // UTC for DST-safety per Wave 3-Q
1865
+ if (this.runtime && now.getUTCHours() >= 2 && now.getUTCHours() < 4) {
1866
+ this.checkAndRunSkillOptimization(now);
1867
+ }
1868
+ // Wave 4-Y: nightly retention prune — runs in the same 02:00-04:00 UTC
1869
+ // window so SQLite contention overlaps the existing dream-pipeline
1870
+ // window instead of opening a second I/O hot zone. Both helpers
1871
+ // self-gate via lastXxxPruneDay so per-tick re-entry is a no-op.
1872
+ if (now.getUTCHours() >= 2 && now.getUTCHours() < 4) {
1873
+ void this.pruneAutoCapturesIfDue(now);
1874
+ void this.pruneAuditTrailIfDue(now);
1875
+ }
1876
+ // Living Spec divergence check — every 100th tick (~25 minutes at 15s intervals)
1877
+ this.specTickCounter++;
1878
+ if (this.specTickCounter % 100 === 0) {
1879
+ this.checkLivingSpecDivergence();
1880
+ }
1881
+ // ── Phase B Bug #1 fix: Consolidate auto_capture -> memory_entries ──
1882
+ // Every 8th tick (~2 min at 15s) run a small consolidation pass. Keeps
1883
+ // the work queue bounded and produces structured memory even when no
1884
+ // real user queries are happening. Cheap when the queue is empty.
1885
+ this.consolidationTickCounter++;
1886
+ if (this.consolidationTickCounter % 8 === 0 && this.runtime) {
1887
+ try {
1888
+ const report = this.runtime.consolidateObservations(200);
1889
+ if (report && report.read > 0) {
1890
+ this.appendLog({
1891
+ type: "heartbeat",
1892
+ message: `Consolidation: read ${report.read}, routed ${report.routed}, failed ${report.classificationFailed}, decisions ${report.decisionLogged}`,
1893
+ data: {
1894
+ byBlock: report.byBlock,
1895
+ },
1896
+ });
1897
+ }
1898
+ }
1899
+ catch (err) {
1900
+ this.appendLog({
1901
+ type: "error",
1902
+ message: `Consolidation tick failed: ${err instanceof Error ? err.message : String(err)}`,
1903
+ });
1904
+ }
1905
+ }
1906
+ // ── Tier 2A: Context Pressure — check every 4th tick (~1 min) ──
1907
+ this.contextPressureTickCounter++;
1908
+ if (this.contextPressureTickCounter % 4 === 0) {
1909
+ const rt = this.runtime;
1910
+ const tokensUsed = rt?.["getTokensUsed"]?.() ?? 0;
1911
+ const maxTokens = rt?.["getMaxTokens"]?.() ?? 200_000;
1912
+ const pressure = this.contextPressure.check(tokensUsed, maxTokens);
1913
+ if (pressure) {
1914
+ const pressureData = {
1915
+ level: pressure.level,
1916
+ utilizationPercent: pressure.utilizationPercent,
1917
+ tokensUsed: pressure.tokensUsed,
1918
+ tokensRemaining: pressure.tokensRemaining,
1919
+ recommendation: pressure.recommendation,
1920
+ timestamp: pressure.timestamp,
1921
+ };
1922
+ this.appendLog({
1923
+ type: "heartbeat",
1924
+ message: `Context pressure: ${pressure.level} (${Math.round(pressure.utilizationPercent)}%)`,
1925
+ data: pressureData,
1926
+ });
1927
+ // Broadcast to all connected CLI sessions. GA-11 / Wave 2-L: use
1928
+ // discriminated stream method name so iOS/desktop clients can route
1929
+ // by method instead of peeking at params.type. Chunk type is "text"
1930
+ // here so the canonical method is "stream.text".
1931
+ this.ipcServer?.broadcast({
1932
+ jsonrpc: "2.0",
1933
+ method: "stream.text",
1934
+ params: {
1935
+ type: "text",
1936
+ content: JSON.stringify({ type: "context-pressure", ...pressureData }),
1937
+ sessionId: "daemon",
1938
+ },
1939
+ });
1940
+ }
1941
+ }
1942
+ // ── GA-09 / V9 T11.1 — virtual cursor pool advance ──
1943
+ // The wires at lines 240/518 promise that "every daemon tick advances
1944
+ // the pool by one frame and dispatches the resulting cursor frames."
1945
+ // This is the actual invocation that makes that comment TRUE.
1946
+ //
1947
+ // advance() returns a Promise<readonly CursorFrame[]> — fire-and-forget
1948
+ // because (a) the consumer has its own try/catch around pool.tick()
1949
+ // and the dispatcher (see virtual-cursor-consumer.ts L108-130), and
1950
+ // (b) blocking the daemon tick on a downstream WebSocket broadcast
1951
+ // would couple cursor smoothness to network latency. The consumer's
1952
+ // diagnostics surface any failures via getDiagnostics().lastDispatchError
1953
+ // for post-hoc inspection. QB #6: outer try/catch is belt-and-braces
1954
+ // for the synchronous portion (consumer construction validates inputs
1955
+ // at create-time, so this should never throw — but if a future change
1956
+ // makes advance() throw synchronously, it must NOT crash the daemon).
1957
+ if (this.virtualCursorConsumer) {
1958
+ try {
1959
+ void this.virtualCursorConsumer.advance().catch((err) => {
1960
+ this.appendLog({
1961
+ type: "error",
1962
+ message: `virtualCursorConsumer.advance() rejected: ${err instanceof Error ? err.message : String(err)}`,
1963
+ });
1964
+ });
1965
+ }
1966
+ catch (err) {
1967
+ this.appendLog({
1968
+ type: "error",
1969
+ message: `virtualCursorConsumer.advance() threw synchronously: ${err instanceof Error ? err.message : String(err)}`,
1970
+ });
1971
+ }
1972
+ }
1973
+ // ── GA-09 / V9 T11.2 — sleep-time consumer drain on idle transition ──
1974
+ // The wire at line 252 promises that "the consumer fires the agent's
1975
+ // runIdleSession when the existing IdleDetector flips to idle." This
1976
+ // is the actual invocation that makes that comment TRUE.
1977
+ //
1978
+ // We re-use `wasIdle` from line 1781 (the existing IdleDetector check
1979
+ // for away-summary) so we don't double-call checkIdle(). The
1980
+ // `lastSleepSessionAt` field (declared at L271) gates re-firing: we
1981
+ // only run a session ONCE per active->idle transition. When the user
1982
+ // returns and the detector flips back to active (recordActivity()
1983
+ // resets isIdle), `lastSleepSessionAt` is cleared and the next idle
1984
+ // window can fire again.
1985
+ //
1986
+ // QB #6 honest stub: maybeRun() returns null on agent error and
1987
+ // already swallows internal exceptions; we still wrap in try/catch
1988
+ // for the construction step (e.g. opportunity object validation).
1989
+ if (this.sleepTimeConsumer) {
1990
+ if (wasIdle) {
1991
+ const idleDurationMs = this.idleDetector.getIdleDurationMs();
1992
+ // Only fire when the idle window is actually established (avoids
1993
+ // spurious sub-tick flicker) and we haven't already drained the
1994
+ // queue for this idle window.
1995
+ if (idleDurationMs > 0 && this.lastSleepSessionAt === null) {
1996
+ this.lastSleepSessionAt = now.getTime();
1997
+ try {
1998
+ const opportunity = {
1999
+ signal: "user-away",
2000
+ detectedAt: now.getTime(),
2001
+ estimatedIdleMs: idleDurationMs,
2002
+ lastSeenActivity: now.getTime() - idleDurationMs,
2003
+ };
2004
+ void this.sleepTimeConsumer.maybeRun(opportunity).catch((err) => {
2005
+ this.appendLog({
2006
+ type: "error",
2007
+ message: `sleepTimeConsumer.maybeRun() rejected: ${err instanceof Error ? err.message : String(err)}`,
2008
+ });
2009
+ });
2010
+ this.appendLog({
2011
+ type: "heartbeat",
2012
+ message: `Sleep-time session triggered (idle ${Math.floor(idleDurationMs / 60_000)}min)`,
2013
+ });
2014
+ }
2015
+ catch (err) {
2016
+ this.appendLog({
2017
+ type: "error",
2018
+ message: `sleepTimeConsumer.maybeRun() threw synchronously: ${err instanceof Error ? err.message : String(err)}`,
2019
+ });
2020
+ }
2021
+ }
2022
+ }
2023
+ else {
2024
+ // Detector says NOT idle. Re-arm so the next active->idle
2025
+ // transition can fire a fresh session. Cheap to re-set every
2026
+ // tick when already null.
2027
+ if (this.lastSleepSessionAt !== null) {
2028
+ this.lastSleepSessionAt = null;
2029
+ }
2030
+ }
2031
+ }
2032
+ }
2033
+ /**
2034
+ * Check Living Spec divergence and push notifications for high-severity issues.
2035
+ * Reloads the spec from disk to catch edits, then compares against the codebase.
2036
+ */
2037
+ checkLivingSpecDivergence() {
2038
+ const specPath = join(this.workingDir, ".wotann", "SPEC.md");
2039
+ if (!existsSync(specPath))
2040
+ return;
2041
+ try {
2042
+ // Reload spec to pick up any edits since last check
2043
+ this.livingSpec = this.livingSpecManager.loadSpec(specPath);
2044
+ const divergences = this.livingSpecManager.checkDivergence(this.livingSpec);
2045
+ if (divergences.length === 0)
2046
+ return;
2047
+ const highSeverity = divergences.filter((d) => d.severity === "error");
2048
+ const warnings = divergences.filter((d) => d.severity === "warning");
2049
+ this.appendLog({
2050
+ type: "heartbeat",
2051
+ message: `Living Spec divergence: ${highSeverity.length} errors, ${warnings.length} warnings, ${divergences.length} total`,
2052
+ data: {
2053
+ errors: highSeverity.map((d) => d.description),
2054
+ warnings: warnings.map((d) => d.description),
2055
+ },
2056
+ });
2057
+ // Push desktop notifications for high-severity divergences
2058
+ if (highSeverity.length > 0) {
2059
+ pushNotification({
2060
+ title: "WOTANN — Spec Divergence",
2061
+ body: `${highSeverity.length} spec violation(s): ${highSeverity[0].description.slice(0, 120)}${highSeverity.length > 1 ? ` (+${highSeverity.length - 1} more)` : ""}`,
2062
+ urgency: "critical",
2063
+ sound: true,
2064
+ });
2065
+ }
2066
+ }
2067
+ catch (err) {
2068
+ this.appendLog({
2069
+ type: "error",
2070
+ message: `Living Spec divergence check failed: ${err instanceof Error ? err.message : String(err)}`,
2071
+ });
2072
+ }
2073
+ }
2074
+ /**
2075
+ * Get the LivingSpecManager for external access.
2076
+ */
2077
+ getLivingSpecManager() {
2078
+ return this.livingSpecManager;
2079
+ }
2080
+ /**
2081
+ * Get the currently loaded Living Spec, if any.
2082
+ */
2083
+ getLivingSpec() {
2084
+ return this.livingSpec;
2085
+ }
2086
+ async initDreamPipeline(wotannDir) {
2087
+ const dreamsDir = join(wotannDir, ".dreams");
2088
+ const dbPath = join(this.workingDir, ".wotann", "memory.db");
2089
+ const { MemoryStore } = await import("../memory/store.js");
2090
+ const memStore = new MemoryStore(dbPath);
2091
+ this.dreamPipeline = new DreamPipeline(memStore, dreamsDir);
2092
+ this.appendLog({ type: "start", message: "DreamPipeline initialized" });
2093
+ }
2094
+ checkAndRunDreamPipeline(now) {
2095
+ const today = now.toISOString().slice(0, 10);
2096
+ if (this.lastDreamDate === today)
2097
+ return; // Already dreamed today
2098
+ if (!this.dreamPipeline)
2099
+ return;
2100
+ this.lastDreamDate = today;
2101
+ void Promise.resolve(this.dreamPipeline.runPipelineSync())
2102
+ .then((result) => {
2103
+ this.appendLog({
2104
+ type: "heartbeat",
2105
+ message: `Dream pipeline completed: ${result.deep.promoted} promoted, ${result.deep.rejected} rejected`,
2106
+ data: {
2107
+ lightCandidates: result.light.candidates.length,
2108
+ remDomains: result.rem.domainCount,
2109
+ durationMs: result.durationMs,
2110
+ },
2111
+ });
2112
+ })
2113
+ .catch((err) => {
2114
+ this.appendLog({
2115
+ type: "error",
2116
+ message: `Dream pipeline failed: ${err instanceof Error ? err.message : String(err)}`,
2117
+ });
2118
+ });
2119
+ }
2120
+ checkAndRunCodebaseHealth(now) {
2121
+ const today = now.toISOString().slice(0, 10);
2122
+ if (this.lastHealthCheckDate === today)
2123
+ return;
2124
+ this.lastHealthCheckDate = today;
2125
+ try {
2126
+ const report = analyzeCodebaseHealth(this.workingDir);
2127
+ this.lastHealthReport = report;
2128
+ this.appendLog({
2129
+ type: "heartbeat",
2130
+ message: `Codebase health check: score=${report.healthScore}/100, tests=${report.testCoverage}%, todos=${report.todoCount}, typeErrors=${report.typeErrors}`,
2131
+ data: {
2132
+ healthScore: report.healthScore,
2133
+ testCoverage: report.testCoverage,
2134
+ todoCount: report.todoCount,
2135
+ typeErrors: report.typeErrors,
2136
+ lintWarnings: report.lintWarnings,
2137
+ },
2138
+ });
2139
+ }
2140
+ catch (err) {
2141
+ this.appendLog({
2142
+ type: "error",
2143
+ message: `Codebase health check failed: ${err instanceof Error ? err.message : String(err)}`,
2144
+ });
2145
+ }
2146
+ }
2147
+ /**
2148
+ * Nightly skill prompt optimization — wires `skills/skill-optimizer.ts`
2149
+ * into the daemon. Picks the first N registered skills (no invocation
2150
+ * tracking source yet — honest note; pending a dedicated usage meter)
2151
+ * and logs a report. Full GEPA optimization is opt-in via
2152
+ * `WOTANN_SKILL_OPT=gepa`; absent the flag the run is a dry-enumeration
2153
+ * so the hook is live without spinning LLM calls every night.
2154
+ */
2155
+ checkAndRunSkillOptimization(now) {
2156
+ const today = now.toISOString().slice(0, 10);
2157
+ if (this.lastSkillOptDate === today)
2158
+ return;
2159
+ if (!this.runtime)
2160
+ return;
2161
+ this.lastSkillOptDate = today;
2162
+ try {
2163
+ const registry = this.runtime.getSkillRegistry();
2164
+ const summaries = registry.getSummaries().slice(0, 3);
2165
+ // Phase-13 wire: `WOTANN_OPTIMIZER=miprov2` swaps GEPA for DSPy
2166
+ // MIPROv2 bootstrap-fewshot. Both respect the `WOTANN_SKILL_OPT`
2167
+ // gate. Dry-enumeration stays the default.
2168
+ const optimizer = process.env["WOTANN_OPTIMIZER"] === "miprov2" ? "miprov2" : "gepa";
2169
+ const mode = process.env["WOTANN_SKILL_OPT"] === "gepa" ? optimizer : "dry";
2170
+ this.appendLog({
2171
+ type: "heartbeat",
2172
+ message: `Nightly skill-optimizer ${mode}: picked top ${summaries.length} skills (no invocation-count source yet)`,
2173
+ data: { skills: summaries.map((s) => s.name), mode },
2174
+ });
2175
+ if (mode === "gepa")
2176
+ void this.runSkillOptimizationGepa(summaries.map((s) => s.name));
2177
+ if (mode === "miprov2")
2178
+ void this.runSkillOptimizationMiprov2(summaries.map((s) => s.name));
2179
+ }
2180
+ catch (err) {
2181
+ this.appendLog({
2182
+ type: "error",
2183
+ message: `Skill optimization failed: ${err instanceof Error ? err.message : String(err)}`,
2184
+ });
2185
+ }
2186
+ }
2187
+ /**
2188
+ * Wave 4-Y: nightly auto_capture retention prune.
2189
+ *
2190
+ * QB#15 note: the audit task referenced `pruneAutoCaptures in
2191
+ * src/learning/autodream.ts`, but that helper actually lives on
2192
+ * `MemoryStore` in `src/memory/store.ts:3945`. We wire the real one;
2193
+ * autodream has no equivalent. The auto_capture table grows ~one row
2194
+ * per tool call and was uncapped before this wire.
2195
+ *
2196
+ * Default retention: 30 days (matches the helper's own default and the
2197
+ * memory.db growth profile documented at store.ts:3936-3941).
2198
+ *
2199
+ * QB#6: any DB error (locked file, missing column from older schema,
2200
+ * etc.) is caught and logged; we never crash the daemon. The day-stamp
2201
+ * is set BEFORE the call, so a failed prune doesn't keep retrying every
2202
+ * tick — it'll re-attempt tomorrow.
2203
+ */
2204
+ async pruneAutoCapturesIfDue(now) {
2205
+ const today = now.toISOString().slice(0, 10);
2206
+ if (this.lastAutoCapturesPruneDay === today)
2207
+ return;
2208
+ this.lastAutoCapturesPruneDay = today;
2209
+ try {
2210
+ const dbPath = resolveWotannHomeSubdir("memory.db");
2211
+ if (!existsSync(dbPath))
2212
+ return; // no DB yet — nothing to prune
2213
+ const { MemoryStore } = await import("../memory/store.js");
2214
+ const store = new MemoryStore(dbPath);
2215
+ try {
2216
+ const removed = store.pruneAutoCaptures(30);
2217
+ if (removed > 0) {
2218
+ this.appendLog({
2219
+ type: "heartbeat",
2220
+ message: `auto_capture prune: removed ${removed} rows older than 30 days`,
2221
+ data: { removed, retentionDays: 30 },
2222
+ });
2223
+ }
2224
+ }
2225
+ finally {
2226
+ store.close();
2227
+ }
2228
+ }
2229
+ catch (err) {
2230
+ this.appendLog({
2231
+ type: "error",
2232
+ message: `auto_capture prune failed: ${err instanceof Error ? err.message : String(err)}`,
2233
+ });
2234
+ }
2235
+ }
2236
+ /**
2237
+ * Wave 4-Y: nightly audit_trail retention prune.
2238
+ *
2239
+ * Default retention: 90 days. The audit_trail is the tool-call audit
2240
+ * surface (see src/telemetry/audit-trail.ts:157-165) — a longer
2241
+ * retention than auto_capture is appropriate for compliance/debugging,
2242
+ * but it must be bounded or the table grows unboundedly (43k+ rows per
2243
+ * 30-day session per the helper's own docs).
2244
+ *
2245
+ * Targets the canonical singleton DB at `~/.wotann/audit.db` (matches
2246
+ * `pipeline.ts:120` and `kairos-rpc.ts:4466`).
2247
+ */
2248
+ async pruneAuditTrailIfDue(now) {
2249
+ const today = now.toISOString().slice(0, 10);
2250
+ if (this.lastAuditTrailPruneDay === today)
2251
+ return;
2252
+ this.lastAuditTrailPruneDay = today;
2253
+ try {
2254
+ const dbPath = resolveWotannHomeSubdir("audit.db");
2255
+ if (!existsSync(dbPath))
2256
+ return; // no audit DB — nothing to prune
2257
+ const { AuditTrail } = await import("../telemetry/audit-trail.js");
2258
+ const trail = new AuditTrail(dbPath);
2259
+ try {
2260
+ const removed = trail.pruneOlderThan(90);
2261
+ if (removed > 0) {
2262
+ this.appendLog({
2263
+ type: "heartbeat",
2264
+ message: `audit_trail prune: removed ${removed} rows older than 90 days`,
2265
+ data: { removed, retentionDays: 90 },
2266
+ });
2267
+ }
2268
+ }
2269
+ finally {
2270
+ trail.close();
2271
+ }
2272
+ }
2273
+ catch (err) {
2274
+ this.appendLog({
2275
+ type: "error",
2276
+ message: `audit_trail prune failed: ${err instanceof Error ? err.message : String(err)}`,
2277
+ });
2278
+ }
2279
+ }
2280
+ /**
2281
+ * Phase-13 wire: MIPROv2 bootstrap-fewshot optimizer. Alternative to
2282
+ * GEPA's genetic loop — collects successful demos from the training
2283
+ * set and rebuilds the prompt with exemplars. Honest: on any failure
2284
+ * we log and continue to the next skill rather than silent skip.
2285
+ */
2286
+ async runSkillOptimizationMiprov2(skillNames) {
2287
+ if (!this.runtime)
2288
+ return;
2289
+ const rt = this.runtime;
2290
+ const runAgent = async (prompt, _input) => {
2291
+ let accum = "";
2292
+ for await (const chunk of rt.query({ prompt })) {
2293
+ if (chunk.type === "text")
2294
+ accum += chunk.content;
2295
+ }
2296
+ return accum;
2297
+ };
2298
+ for (const name of skillNames) {
2299
+ const loaded = rt.getSkillRegistry().loadSkill(name);
2300
+ if (!loaded)
2301
+ continue;
2302
+ try {
2303
+ const result = await bootstrapFewShot({
2304
+ instruction: loaded.content,
2305
+ trainingSet: [{ input: "ping", expectedOutput: "pong" }],
2306
+ runAgent,
2307
+ maxDemos: 2,
2308
+ });
2309
+ this.appendLog({
2310
+ type: "heartbeat",
2311
+ message: `Skill-optimizer(miprov2): ${name} baseline=${result.baselineScore.toFixed(2)} optimized=${result.optimizedScore.toFixed(2)}, demos=${result.demosCollected}`,
2312
+ });
2313
+ }
2314
+ catch (err) {
2315
+ this.appendLog({
2316
+ type: "error",
2317
+ message: `Miprov2 failed for ${name}: ${err instanceof Error ? err.message : String(err)}`,
2318
+ });
2319
+ }
2320
+ }
2321
+ }
2322
+ async runSkillOptimizationGepa(skillNames) {
2323
+ if (!this.runtime)
2324
+ return;
2325
+ const rt = this.runtime;
2326
+ const llmQuery = async (prompt, opts) => {
2327
+ let accum = "";
2328
+ for await (const chunk of rt.query({ prompt, maxTokens: opts.maxTokens })) {
2329
+ if (chunk.type === "text")
2330
+ accum += chunk.content;
2331
+ }
2332
+ return accum;
2333
+ };
2334
+ const mutate = createLlmPromptMutator(llmQuery);
2335
+ const evaluate = buildBasicEvaluator({
2336
+ query: async (p) => {
2337
+ let out = "";
2338
+ for await (const c of rt.query({ prompt: p }))
2339
+ if (c.type === "text")
2340
+ out += c.content;
2341
+ return out;
2342
+ },
2343
+ }, [{ input: "ping", expectedContains: "pong" }]);
2344
+ for (const name of skillNames) {
2345
+ const loaded = rt.getSkillRegistry().loadSkill(name);
2346
+ if (!loaded)
2347
+ continue;
2348
+ try {
2349
+ const result = await optimizeSkillPrompt({
2350
+ initialPrompt: loaded.content,
2351
+ mutate,
2352
+ evaluate,
2353
+ maxGenerations: 2,
2354
+ populationSize: 2,
2355
+ });
2356
+ this.appendLog({
2357
+ type: "heartbeat",
2358
+ message: `Skill-optimizer: ${name} improved=${result.improved} fitness ${result.baselineFitness.toFixed(2)} -> ${result.fitness.toFixed(2)}`,
2359
+ });
2360
+ }
2361
+ catch (err) {
2362
+ this.appendLog({
2363
+ type: "error",
2364
+ message: `Skill-optimizer failed for ${name}: ${err instanceof Error ? err.message : String(err)}`,
2365
+ });
2366
+ }
2367
+ }
2368
+ }
2369
+ getCrossDeviceContext() {
2370
+ return this.crossDeviceContext;
2371
+ }
2372
+ getLastHealthReport() {
2373
+ return this.lastHealthReport;
2374
+ }
2375
+ getFlowTracker() {
2376
+ return this.flowTracker;
2377
+ }
2378
+ getIdleDetector() {
2379
+ return this.idleDetector;
2380
+ }
2381
+ getSmartFileSearch() {
2382
+ return this.fileSearch;
2383
+ }
2384
+ getContextPressure() {
2385
+ return this.contextPressure;
2386
+ }
2387
+ getTerminalMonitor() {
2388
+ return this.terminalMonitor;
2389
+ }
2390
+ getFileDependencyGraph() {
2391
+ return this.fileDependencyGraph;
2392
+ }
2393
+ addCronJob(job) {
2394
+ this.state = {
2395
+ ...this.state,
2396
+ cronJobs: [...this.state.cronJobs, job],
2397
+ };
2398
+ }
2399
+ removeCronJob(id) {
2400
+ this.state = {
2401
+ ...this.state,
2402
+ cronJobs: this.state.cronJobs.filter((j) => j.id !== id),
2403
+ };
2404
+ // Wave 4F: keep the persistent store aligned so a job removed via
2405
+ // the in-memory API also disappears from `.wotann/cron.db`. Missing
2406
+ // from the store is fine (jobs that were added via `addCronJob`
2407
+ // before the store existed, or in tests).
2408
+ if (this.cronStore) {
2409
+ this.cronStore.remove(id);
2410
+ }
2411
+ }
2412
+ /**
2413
+ * Wave 4F: add a cron job that survives daemon restarts. Delegates to
2414
+ * the SQLite-backed CronStore and mirrors the job into in-memory
2415
+ * state so `getStatus().cronJobs` stays honest.
2416
+ *
2417
+ * Returns the store's assigned id so callers can reference the job
2418
+ * later. Throws if the store isn't open (daemon not started, or
2419
+ * init failed) — honest failure beats silently writing to an
2420
+ * unreachable column.
2421
+ */
2422
+ addCronJobPersistent(params) {
2423
+ if (!this.cronStore) {
2424
+ throw new Error("Cron store not available — daemon not started or init failed. " +
2425
+ "Call addCronJob() for in-memory only state.");
2426
+ }
2427
+ const record = this.cronStore.add(params);
2428
+ this.state = {
2429
+ ...this.state,
2430
+ cronJobs: [...this.state.cronJobs, projectRecord(record)],
2431
+ };
2432
+ this.appendLog({
2433
+ type: "cron",
2434
+ message: `Persistent cron job added: "${record.name}" (${record.schedule})`,
2435
+ data: { jobId: record.id, nextFireAt: record.nextFireAt },
2436
+ });
2437
+ return record;
2438
+ }
2439
+ /** Wave 4F: expose the store for RPC/CLI callers. Null if not started. */
2440
+ getCronStore() {
2441
+ return this.cronStore;
2442
+ }
2443
+ /**
2444
+ * P1-C2: expose the Hermes-style cron scheduler. Null until
2445
+ * daemon.start() opens the schedule.db connection. Callers
2446
+ * (kairos-rpc, tests, runtime modules) use this to register
2447
+ * at-most-once handler-backed schedules.
2448
+ */
2449
+ getCronScheduler() {
2450
+ return this.cronScheduler;
2451
+ }
2452
+ /**
2453
+ * Wave 4F: fire a cron job sourced from the CronStore. Same execFile
2454
+ * semantics as `executeCronJob()` but surfaces the log entry with the
2455
+ * store-specific job id so operators can correlate audit entries.
2456
+ *
2457
+ * Throws through to the store so it records a "failure" row; the
2458
+ * appendLog call remains synchronous so the trace is durable even if
2459
+ * execFile rejects asynchronously.
2460
+ */
2461
+ async executeCronStoreJob(job) {
2462
+ const parts = job.command.split(/\s+/);
2463
+ const cmd = parts[0];
2464
+ const args = parts.slice(1);
2465
+ if (!cmd) {
2466
+ // Honest failure — don't pretend success for an empty command.
2467
+ this.appendLog({
2468
+ type: "error",
2469
+ message: `Cron job "${job.name}" has empty command`,
2470
+ data: { jobId: job.id },
2471
+ });
2472
+ throw new Error("empty command");
2473
+ }
2474
+ this.appendLog({
2475
+ type: "cron",
2476
+ message: `Executing persistent cron job: ${job.name}`,
2477
+ data: { jobId: job.id, command: job.command },
2478
+ });
2479
+ // Short timeout (30s) matches the legacy executeCronJob path. Fire
2480
+ // execFile — store records success/failure based on whether this
2481
+ // promise rejects.
2482
+ await execFileAsync(cmd, args, { timeout: 30_000, cwd: this.workingDir });
2483
+ }
2484
+ addHeartbeatTask(task) {
2485
+ this.state = {
2486
+ ...this.state,
2487
+ heartbeatTasks: [...this.state.heartbeatTasks, task],
2488
+ };
2489
+ }
2490
+ loadHeartbeatTasksFromFile(heartbeatPath) {
2491
+ if (!existsSync(heartbeatPath)) {
2492
+ this.state = { ...this.state, heartbeatTasks: [] };
2493
+ return 0;
2494
+ }
2495
+ const markdown = readFileSync(heartbeatPath, "utf-8");
2496
+ const tasks = parseHeartbeatTasks(markdown);
2497
+ this.state = { ...this.state, heartbeatTasks: tasks };
2498
+ return tasks.length;
2499
+ }
2500
+ shouldRunCron(job, now) {
2501
+ // Don't re-run if already ran this minute
2502
+ if (job.lastRun) {
2503
+ const lastRunMinute = Math.floor(job.lastRun.getTime() / 60_000);
2504
+ const nowMinute = Math.floor(now.getTime() / 60_000);
2505
+ if (lastRunMinute === nowMinute)
2506
+ return false;
2507
+ }
2508
+ return matchesCronSchedule(job.schedule, now);
2509
+ }
2510
+ executeCronJob(job) {
2511
+ const parts = job.command.split(/\s+/);
2512
+ const cmd = parts[0];
2513
+ const args = parts.slice(1);
2514
+ if (!cmd)
2515
+ return;
2516
+ this.appendLog({
2517
+ type: "cron",
2518
+ message: `Executing cron job: ${job.name}`,
2519
+ data: { jobId: job.id, command: job.command },
2520
+ });
2521
+ execFileAsync(cmd, args, { timeout: 30_000, cwd: process.cwd() })
2522
+ .then(() => {
2523
+ this.updateCronJobResult(job.id, "success");
2524
+ })
2525
+ .catch(() => {
2526
+ this.updateCronJobResult(job.id, "failure");
2527
+ });
2528
+ }
2529
+ updateCronJobResult(jobId, result) {
2530
+ this.state = {
2531
+ ...this.state,
2532
+ cronJobs: this.state.cronJobs.map((j) => j.id === jobId ? { ...j, lastRun: new Date(), lastResult: result } : j),
2533
+ };
2534
+ }
2535
+ runHeartbeatTasks(now, schedules) {
2536
+ for (const task of this.state.heartbeatTasks) {
2537
+ if (!isHeartbeatSchedule(task.schedule))
2538
+ continue;
2539
+ if (!schedules.includes(task.schedule))
2540
+ continue;
2541
+ if (!this.shouldRunHeartbeatTask(task, now))
2542
+ continue;
2543
+ this.executeHeartbeatTask(task, now);
2544
+ }
2545
+ }
2546
+ shouldRunHeartbeatTask(task, now) {
2547
+ if (!task.enabled || !isHeartbeatSchedule(task.schedule)) {
2548
+ return false;
2549
+ }
2550
+ if (task.schedule === "on-wake") {
2551
+ return !task.lastRun;
2552
+ }
2553
+ if (task.schedule === "periodic") {
2554
+ return !task.lastRun || now.getTime() - task.lastRun.getTime() >= 15 * 60_000;
2555
+ }
2556
+ // UTC for DST-safety per Wave 3-Q — local-time gate skips
2557
+ // spring-forward and double-fires fall-back. The "is today" comparator
2558
+ // already uses toISOString() (UTC), so the hour gate must match.
2559
+ if (!task.lastRun) {
2560
+ return now.getUTCHours() >= 2;
2561
+ }
2562
+ const lastRunDay = task.lastRun.toISOString().slice(0, 10);
2563
+ const today = now.toISOString().slice(0, 10);
2564
+ return lastRunDay !== today && now.getUTCHours() >= 2;
2565
+ }
2566
+ executeHeartbeatTask(task, now) {
2567
+ if (!isHeartbeatSchedule(task.schedule)) {
2568
+ return;
2569
+ }
2570
+ this.appendLog({
2571
+ type: "heartbeat",
2572
+ message: `Running heartbeat task: ${task.name}`,
2573
+ data: { schedule: task.schedule },
2574
+ });
2575
+ this.updateHeartbeatTaskState(task.name, task.schedule, now, computeNextRun(task.schedule, now));
2576
+ if (/consolidate|dream|gotchas|memory/i.test(task.name)) {
2577
+ const result = runWorkspaceDreamIfDue(process.cwd(), { quiet: true });
2578
+ this.appendLog({
2579
+ type: "heartbeat",
2580
+ message: result
2581
+ ? `autoDream executed from heartbeat: ${task.name}`
2582
+ : `autoDream skipped (not due): ${task.name}`,
2583
+ data: result
2584
+ ? {
2585
+ gotchasAdded: result.gotchasAdded,
2586
+ instinctsUpdated: result.instinctsUpdated,
2587
+ rulesUpdated: result.rulesUpdated,
2588
+ }
2589
+ : undefined,
2590
+ });
2591
+ return;
2592
+ }
2593
+ if (/git status|monitor file changes/i.test(task.name)) {
2594
+ execFileAsync("git", ["status", "--short"], { timeout: 10_000, cwd: process.cwd() })
2595
+ .then(({ stdout }) => {
2596
+ this.appendLog({
2597
+ type: "heartbeat",
2598
+ message: `Git status heartbeat: ${task.name}`,
2599
+ data: { changedEntries: stdout.trim().split("\n").filter(Boolean).length },
2600
+ });
2601
+ })
2602
+ .catch(() => {
2603
+ this.appendLog({
2604
+ type: "heartbeat",
2605
+ message: `Git status heartbeat failed: ${task.name}`,
2606
+ });
2607
+ });
2608
+ return;
2609
+ }
2610
+ this.appendLog({
2611
+ type: "heartbeat",
2612
+ message: `Heartbeat task completed: ${task.name}`,
2613
+ });
2614
+ }
2615
+ updateHeartbeatTaskState(taskName, schedule, lastRun, nextRun) {
2616
+ this.state = {
2617
+ ...this.state,
2618
+ heartbeatTasks: this.state.heartbeatTasks.map((task) => task.name === taskName && task.schedule === schedule ? { ...task, lastRun, nextRun } : task),
2619
+ };
2620
+ }
2621
+ /**
2622
+ * Phase B Bug #2 fix: install shutdown handlers so the daemon flushes
2623
+ * state and cleans up its `.tmp.*` / WAL files even on SIGINT/SIGTERM.
2624
+ *
2625
+ * Previously Ctrl-C mid-write left a stranded `knowledge-graph.json.tmp.*`.
2626
+ * Now the handler calls `stop()` (idempotent) before the process exits.
2627
+ * Registered once per daemon instance; subsequent start()s don't re-add
2628
+ * listeners (the `shutdownHandlersInstalled` flag prevents leak).
2629
+ */
2630
+ installShutdownHandlers() {
2631
+ if (this.shutdownHandlersInstalled)
2632
+ return;
2633
+ this.shutdownHandlersInstalled = true;
2634
+ // Keep a reference so tests / external code can remove these if they
2635
+ // need clean teardown (process-wide listeners leak across vitest runs
2636
+ // otherwise).
2637
+ const handleShutdown = (signal) => {
2638
+ if (this.state.status === "stopped")
2639
+ return;
2640
+ this.appendLog({
2641
+ type: "stop",
2642
+ message: `Shutdown signal received: ${signal}`,
2643
+ });
2644
+ try {
2645
+ this.stop();
2646
+ }
2647
+ catch (err) {
2648
+ this.appendLog({
2649
+ type: "error",
2650
+ message: `stop() threw during ${signal}: ${err instanceof Error ? err.message : String(err)}`,
2651
+ });
2652
+ }
2653
+ };
2654
+ const sigintHandler = () => handleShutdown("SIGINT");
2655
+ const sigtermHandler = () => handleShutdown("SIGTERM");
2656
+ const exitHandler = () => {
2657
+ // 'exit' fires synchronously after all work is done. stop() is
2658
+ // idempotent — if SIGINT already fired we're a no-op.
2659
+ if (this.state.status !== "stopped") {
2660
+ try {
2661
+ this.stop();
2662
+ }
2663
+ catch {
2664
+ /* process is dying — nothing to do */
2665
+ }
2666
+ }
2667
+ };
2668
+ process.on("SIGINT", sigintHandler);
2669
+ process.on("SIGTERM", sigtermHandler);
2670
+ process.on("exit", exitHandler);
2671
+ this.shutdownHandlers = { sigintHandler, sigtermHandler, exitHandler };
2672
+ }
2673
+ /**
2674
+ * Remove signal handlers. Called from stop() when the caller asks for a
2675
+ * clean teardown (tests, second start()).
2676
+ */
2677
+ removeShutdownHandlers() {
2678
+ if (!this.shutdownHandlersInstalled || !this.shutdownHandlers)
2679
+ return;
2680
+ process.removeListener("SIGINT", this.shutdownHandlers.sigintHandler);
2681
+ process.removeListener("SIGTERM", this.shutdownHandlers.sigtermHandler);
2682
+ process.removeListener("exit", this.shutdownHandlers.exitHandler);
2683
+ this.shutdownHandlersInstalled = false;
2684
+ this.shutdownHandlers = null;
2685
+ }
2686
+ /**
2687
+ * Phase B Bug #2 fix: clean up orphan `.tmp.*` files and stranded
2688
+ * WAL/SHM files from previous daemon runs.
2689
+ *
2690
+ * Symptoms that triggered this fix:
2691
+ * - `.wotann/knowledge-graph.json.tmp.*` × 30+ (leaked atomic-write temps)
2692
+ * - `.wotann/memory 2.db-wal`, `memory 3.db-shm`, etc. — 6 orphan
2693
+ * pairs from duplicate SQLite instances opened by crashed processes.
2694
+ * They have no matching `.db` so they're dead weight.
2695
+ *
2696
+ * Sweeps:
2697
+ * 1. Remove all `*.tmp.*` files in `.wotann/` root (dead atomic-write temps).
2698
+ * 2. Remove all `memory N.db-wal` / `memory N.db-shm` whose corresponding
2699
+ * `memory N.db` does NOT exist.
2700
+ *
2701
+ * Safe to run on every daemon start. Never touches files that are in-use
2702
+ * by a live SQLite connection (no matching bare `.db` means nothing owns them).
2703
+ *
2704
+ * @returns the number of files removed, split by bucket.
2705
+ */
2706
+ sweepOrphanFiles() {
2707
+ const wotannDirs = [join(this.workingDir, ".wotann"), resolveWotannHome()];
2708
+ let tmpRemoved = 0;
2709
+ let walRemoved = 0;
2710
+ let shmRemoved = 0;
2711
+ for (const dir of wotannDirs) {
2712
+ if (!existsSync(dir))
2713
+ continue;
2714
+ let entries = [];
2715
+ try {
2716
+ entries = readdirSync(dir);
2717
+ }
2718
+ catch {
2719
+ continue;
2720
+ }
2721
+ // Build a set of live `.db` files so we know which WAL/SHM pairs
2722
+ // are safe to remove. A WAL/SHM with a corresponding `.db` is still
2723
+ // in use and must NOT be touched.
2724
+ const liveDbNames = new Set(entries.filter((name) => name.endsWith(".db")).map((name) => name));
2725
+ // V9 T1.10 age gate: only treat .tmp.<pid>.<ts> files older than 1
2726
+ // hour as orphans. Anything newer could belong to an in-progress
2727
+ // atomic-write from this very boot (pre-handler-install race), and
2728
+ // unlinking it would corrupt in-flight data.
2729
+ const TMP_AGE_MIN_MS = 60 * 60 * 1000;
2730
+ const now = Date.now();
2731
+ for (const name of entries) {
2732
+ const full = join(dir, name);
2733
+ // Pass 1: remove stale atomic-write temps. Pattern is
2734
+ // `<base>.tmp.<pid>.<ts>` (e.g. `knowledge-graph.json.tmp.12345.67890`).
2735
+ // Match `.tmp.` followed by a digit to avoid false positives like
2736
+ // `.tmpl` or `.tmp` (with no suffix). Age-gated per V9 T1.10.
2737
+ if (/\.tmp\.\d+/.test(name)) {
2738
+ try {
2739
+ const st = statSync(full);
2740
+ if (now - st.mtimeMs >= TMP_AGE_MIN_MS) {
2741
+ unlinkSync(full);
2742
+ tmpRemoved++;
2743
+ }
2744
+ }
2745
+ catch {
2746
+ /* may have been deleted by a race — ignore */
2747
+ }
2748
+ continue;
2749
+ }
2750
+ // Pass 2: orphan SQLite WAL files. A `.db-wal` without a matching
2751
+ // `.db` is from a crashed process that can never finish the
2752
+ // checkpoint.
2753
+ if (name.endsWith(".db-wal")) {
2754
+ const baseDb = name.slice(0, -"-wal".length);
2755
+ if (!liveDbNames.has(baseDb)) {
2756
+ try {
2757
+ unlinkSync(full);
2758
+ walRemoved++;
2759
+ }
2760
+ catch {
2761
+ /* race — ignore */
2762
+ }
2763
+ }
2764
+ continue;
2765
+ }
2766
+ // Pass 3: orphan SQLite SHM files. Same rule.
2767
+ if (name.endsWith(".db-shm")) {
2768
+ const baseDb = name.slice(0, -"-shm".length);
2769
+ if (!liveDbNames.has(baseDb)) {
2770
+ try {
2771
+ unlinkSync(full);
2772
+ shmRemoved++;
2773
+ }
2774
+ catch {
2775
+ /* race — ignore */
2776
+ }
2777
+ }
2778
+ continue;
2779
+ }
2780
+ }
2781
+ }
2782
+ return { tmpRemoved, walRemoved, shmRemoved };
2783
+ }
2784
+ // ── Wave 4F: Heartbeat Telemetry ──────────────────────────
2785
+ /**
2786
+ * Write a heartbeat snapshot to `.wotann/daemon.status.json` and
2787
+ * append a `heartbeat` event to the daily JSONL log. Called from
2788
+ * tick() at the 30-second cadence (every 2nd tick at 15s interval).
2789
+ *
2790
+ * Surfaced fields:
2791
+ * - pid: process id — matches `.wotann/daemon.pid`
2792
+ * - uptime: seconds since start()
2793
+ * - tickCount: monotonic count (helps detect stalled daemons)
2794
+ * - activeProviders: number of providers the runtime currently has
2795
+ * - memoryMb: RSS in MB
2796
+ * - cronJobsEnabled: store-backed enabled count
2797
+ * - status: "running" | "starting" | "stopping" | "stopped"
2798
+ *
2799
+ * Failure is non-fatal — a broken filesystem must not crash the
2800
+ * daemon. The error is swallowed silently because the log path
2801
+ * already reports status.
2802
+ */
2803
+ emitHeartbeatTelemetry(now) {
2804
+ if (!this.statusJsonPath)
2805
+ return;
2806
+ const startedAt = this.state.startedAt;
2807
+ const uptimeSec = startedAt ? Math.floor((now.getTime() - startedAt.getTime()) / 1000) : 0;
2808
+ const memUsage = process.memoryUsage();
2809
+ const memoryMb = Math.round(memUsage.rss / 1024 / 1024);
2810
+ // Active provider count pulled directly from runtime when
2811
+ // available. Falls back to 0 when runtime init failed so the
2812
+ // JSON file remains structurally stable.
2813
+ let activeProviders = 0;
2814
+ try {
2815
+ const rt = this.runtime;
2816
+ const status = rt?.getStatus?.();
2817
+ if (status?.providers)
2818
+ activeProviders = status.providers.length;
2819
+ }
2820
+ catch {
2821
+ activeProviders = 0;
2822
+ }
2823
+ const cronJobsEnabled = this.cronStore?.countEnabled() ?? 0;
2824
+ const snapshot = {
2825
+ pid: process.pid,
2826
+ status: this.state.status,
2827
+ startedAt: startedAt?.toISOString() ?? null,
2828
+ updatedAt: now.toISOString(),
2829
+ uptime: uptimeSec,
2830
+ tickCount: this.state.tickCount,
2831
+ activeProviders,
2832
+ memoryMb,
2833
+ cronJobsEnabled,
2834
+ heartbeatTasks: this.state.heartbeatTasks.length,
2835
+ };
2836
+ try {
2837
+ // Wave 6.5-UU (H-22) — atomic write via shared utils/atomic-io helper.
2838
+ // Replaces the inline tmp + rename block; the helper additionally
2839
+ // fsyncs the tmp file before rename so the snapshot survives a
2840
+ // power-loss window the previous version did not cover.
2841
+ const { writeFileAtomic } = require("../utils/atomic-io.js");
2842
+ writeFileAtomic(this.statusJsonPath, JSON.stringify(snapshot, null, 2));
2843
+ }
2844
+ catch {
2845
+ // Telemetry failure must never crash the daemon.
2846
+ }
2847
+ this.appendLog({
2848
+ type: "heartbeat",
2849
+ message: `Heartbeat: uptime ${uptimeSec}s, ticks ${this.state.tickCount}, providers ${activeProviders}, mem ${memoryMb}MB`,
2850
+ data: {
2851
+ pid: process.pid,
2852
+ uptime: uptimeSec,
2853
+ tickCount: this.state.tickCount,
2854
+ activeProviders,
2855
+ memoryMb,
2856
+ cronJobsEnabled,
2857
+ },
2858
+ });
2859
+ }
2860
+ // ── Daily Log (append-only JSONL) ───────────────────────────
2861
+ appendLog(entry) {
2862
+ const fullEntry = {
2863
+ timestamp: new Date().toISOString(),
2864
+ ...entry,
2865
+ };
2866
+ const today = new Date().toISOString().slice(0, 10);
2867
+ const logFile = join(this.logDir, `${today}.jsonl`);
2868
+ try {
2869
+ appendFileSync(logFile, JSON.stringify(fullEntry) + "\n");
2870
+ }
2871
+ catch {
2872
+ // Fail silently — logging should never crash the daemon
2873
+ }
2874
+ }
2875
+ getLogs(date) {
2876
+ const targetDate = date ?? new Date().toISOString().slice(0, 10);
2877
+ const logFile = join(this.logDir, `${targetDate}.jsonl`);
2878
+ if (!existsSync(logFile))
2879
+ return [];
2880
+ try {
2881
+ const content = readFileSync(logFile, "utf-8");
2882
+ return content
2883
+ .trim()
2884
+ .split("\n")
2885
+ .filter(Boolean)
2886
+ .map((line) => JSON.parse(line));
2887
+ }
2888
+ catch {
2889
+ // Best-effort path — caller gets a safe fallback, no user-facing error.
2890
+ return [];
2891
+ }
2892
+ }
2893
+ }
2894
+ function resolveChannelSelections(options) {
2895
+ const allOptions = [
2896
+ options.webchat,
2897
+ options.telegram,
2898
+ options.slack,
2899
+ options.discord,
2900
+ options.signal,
2901
+ options.whatsapp,
2902
+ options.email,
2903
+ options.webhook,
2904
+ options.sms,
2905
+ options.matrix,
2906
+ options.teams,
2907
+ ];
2908
+ const explicitSelection = allOptions.some((value) => value !== undefined);
2909
+ if (explicitSelection) {
2910
+ return {
2911
+ webchat: options.webchat ?? false,
2912
+ telegram: options.telegram ?? false,
2913
+ slack: options.slack ?? false,
2914
+ discord: options.discord ?? false,
2915
+ signal: options.signal ?? false,
2916
+ whatsapp: options.whatsapp ?? false,
2917
+ email: options.email ?? false,
2918
+ webhook: options.webhook ?? false,
2919
+ sms: options.sms ?? false,
2920
+ matrix: options.matrix ?? false,
2921
+ teams: options.teams ?? false,
2922
+ };
2923
+ }
2924
+ // Auto-detect based on environment variables
2925
+ return {
2926
+ webchat: true,
2927
+ telegram: Boolean(process.env["TELEGRAM_BOT_TOKEN"]),
2928
+ slack: Boolean(process.env["SLACK_BOT_TOKEN"] && process.env["SLACK_APP_TOKEN"]),
2929
+ discord: Boolean(process.env["DISCORD_BOT_TOKEN"]),
2930
+ signal: Boolean(process.env["SIGNAL_CLI_PATH"] || process.env["SIGNAL_PHONE_NUMBER"]),
2931
+ whatsapp: Boolean(process.env["WHATSAPP_SESSION_DIR"]),
2932
+ email: Boolean(process.env["IMAP_HOST"] && process.env["SMTP_HOST"]),
2933
+ webhook: Boolean(process.env["WOTANN_WEBHOOK_SECRET"]),
2934
+ sms: Boolean(process.env["TWILIO_ACCOUNT_SID"]),
2935
+ matrix: Boolean(process.env["MATRIX_ACCESS_TOKEN"]),
2936
+ teams: Boolean(process.env["TEAMS_APP_ID"]),
2937
+ };
2938
+ }
2939
+ export function parseHeartbeatTasks(markdown, now = new Date()) {
2940
+ const tasks = [];
2941
+ let schedule = null;
2942
+ for (const rawLine of markdown.split(/\r?\n/)) {
2943
+ const line = rawLine.trim();
2944
+ if (!line)
2945
+ continue;
2946
+ if (line.startsWith("## ")) {
2947
+ const heading = line.toLowerCase();
2948
+ if (heading.includes("on wake"))
2949
+ schedule = "on-wake";
2950
+ else if (heading.includes("periodic"))
2951
+ schedule = "periodic";
2952
+ else if (heading.includes("nightly"))
2953
+ schedule = "nightly";
2954
+ else
2955
+ schedule = null;
2956
+ continue;
2957
+ }
2958
+ const taskMatch = line.match(/^- \[(?: |x)\] (.+)$/i);
2959
+ if (!taskMatch || !schedule)
2960
+ continue;
2961
+ tasks.push({
2962
+ name: taskMatch[1].trim(),
2963
+ schedule,
2964
+ enabled: true,
2965
+ nextRun: schedule === "on-wake" ? now : computeNextRun(schedule, now),
2966
+ });
2967
+ }
2968
+ return tasks;
2969
+ }
2970
+ function isHeartbeatSchedule(schedule) {
2971
+ return schedule === "on-wake" || schedule === "periodic" || schedule === "nightly";
2972
+ }
2973
+ /**
2974
+ * Wave 4F: project a persistent `CronJobRecord` into the in-memory
2975
+ * `CronJob` shape carried by `DaemonState.cronJobs`. Kept as a free
2976
+ * function so tests can exercise it without constructing a daemon.
2977
+ *
2978
+ * The store tracks timestamps as absolute ms numbers; the in-memory
2979
+ * shape wants a JS Date for `lastRun`. We pass `lastResult` through
2980
+ * verbatim when non-null; otherwise omit so the in-memory shape
2981
+ * cleanly reflects "never run yet".
2982
+ */
2983
+ function projectRecord(record) {
2984
+ const base = {
2985
+ id: record.id,
2986
+ name: record.name,
2987
+ schedule: record.schedule,
2988
+ command: record.command,
2989
+ enabled: record.enabled,
2990
+ };
2991
+ if (record.lastFiredAt !== null) {
2992
+ return {
2993
+ ...base,
2994
+ lastRun: new Date(record.lastFiredAt),
2995
+ ...(record.lastResult !== null ? { lastResult: record.lastResult } : {}),
2996
+ };
2997
+ }
2998
+ return base;
2999
+ }
3000
+ function computeNextRun(schedule, now) {
3001
+ if (schedule === "on-wake") {
3002
+ return undefined;
3003
+ }
3004
+ if (schedule === "periodic") {
3005
+ return new Date(now.getTime() + 15 * 60_000);
3006
+ }
3007
+ // UTC for DST-safety per Wave 3-Q — local setHours(2) on a spring-forward
3008
+ // day rolls forward past 02:00 entirely (the hour is skipped), and on a
3009
+ // fall-back day produces an ambiguous wall time. UTC has no DST so 02:00
3010
+ // UTC reliably exists exactly once per calendar day.
3011
+ const next = new Date(now);
3012
+ next.setUTCDate(next.getUTCHours() >= 2 ? next.getUTCDate() + 1 : next.getUTCDate());
3013
+ next.setUTCHours(2, 0, 0, 0);
3014
+ return next;
3015
+ }
3016
+ //# sourceMappingURL=kairos.js.map