@spinabot/brigade 0.1.1 → 1.0.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 (1931) hide show
  1. package/LICENSE +1 -1
  2. package/README.md +746 -93
  3. package/brigade.mjs +150 -73
  4. package/dist/agents/a2a-policy-canonicalize.d.ts +60 -0
  5. package/dist/agents/a2a-policy-canonicalize.d.ts.map +1 -0
  6. package/dist/agents/a2a-policy-canonicalize.js +103 -0
  7. package/dist/agents/a2a-policy-canonicalize.js.map +1 -0
  8. package/dist/agents/agent-event-bus.d.ts +221 -0
  9. package/dist/agents/agent-event-bus.d.ts.map +1 -0
  10. package/dist/agents/agent-event-bus.js +88 -0
  11. package/dist/agents/agent-event-bus.js.map +1 -0
  12. package/dist/agents/agent-events.d.ts +84 -0
  13. package/dist/agents/agent-events.d.ts.map +1 -0
  14. package/dist/agents/agent-events.js +309 -0
  15. package/dist/agents/agent-events.js.map +1 -0
  16. package/dist/agents/agent-events.types.d.ts +139 -0
  17. package/dist/agents/agent-events.types.d.ts.map +1 -0
  18. package/dist/agents/agent-events.types.js +27 -0
  19. package/dist/agents/agent-events.types.js.map +1 -0
  20. package/dist/agents/agent-loop.d.ts +145 -0
  21. package/dist/agents/agent-loop.d.ts.map +1 -0
  22. package/dist/agents/agent-loop.js +1938 -0
  23. package/dist/agents/agent-loop.js.map +1 -0
  24. package/dist/agents/agent-scope.d.ts +28 -0
  25. package/dist/agents/agent-scope.d.ts.map +1 -0
  26. package/dist/agents/agent-scope.js +39 -0
  27. package/dist/agents/agent-scope.js.map +1 -0
  28. package/dist/agents/approval-bridge.d.ts +139 -0
  29. package/dist/agents/approval-bridge.d.ts.map +1 -0
  30. package/dist/agents/approval-bridge.js +178 -0
  31. package/dist/agents/approval-bridge.js.map +1 -0
  32. package/dist/agents/carrow.d.ts +49 -0
  33. package/dist/agents/carrow.d.ts.map +1 -0
  34. package/dist/agents/carrow.js +57 -0
  35. package/dist/agents/carrow.js.map +1 -0
  36. package/dist/agents/channels/abort-triggers.d.ts +17 -0
  37. package/dist/agents/channels/abort-triggers.d.ts.map +1 -0
  38. package/dist/agents/channels/abort-triggers.js +52 -0
  39. package/dist/agents/channels/abort-triggers.js.map +1 -0
  40. package/dist/agents/channels/access-control/index.d.ts +5 -0
  41. package/dist/agents/channels/access-control/index.d.ts.map +1 -0
  42. package/dist/agents/channels/access-control/index.js +4 -0
  43. package/dist/agents/channels/access-control/index.js.map +1 -0
  44. package/dist/agents/channels/access-control/policy.d.ts +69 -0
  45. package/dist/agents/channels/access-control/policy.d.ts.map +1 -0
  46. package/dist/agents/channels/access-control/policy.js +123 -0
  47. package/dist/agents/channels/access-control/policy.js.map +1 -0
  48. package/dist/agents/channels/access-control/store.d.ts +86 -0
  49. package/dist/agents/channels/access-control/store.d.ts.map +1 -0
  50. package/dist/agents/channels/access-control/store.js +482 -0
  51. package/dist/agents/channels/access-control/store.js.map +1 -0
  52. package/dist/agents/channels/access-control/types.d.ts +52 -0
  53. package/dist/agents/channels/access-control/types.d.ts.map +1 -0
  54. package/dist/agents/channels/access-control/types.js +20 -0
  55. package/dist/agents/channels/access-control/types.js.map +1 -0
  56. package/dist/agents/channels/active-manager.d.ts +31 -0
  57. package/dist/agents/channels/active-manager.d.ts.map +1 -0
  58. package/dist/agents/channels/active-manager.js +41 -0
  59. package/dist/agents/channels/active-manager.js.map +1 -0
  60. package/dist/agents/channels/agent-switch-command.d.ts +53 -0
  61. package/dist/agents/channels/agent-switch-command.d.ts.map +1 -0
  62. package/dist/agents/channels/agent-switch-command.js +349 -0
  63. package/dist/agents/channels/agent-switch-command.js.map +1 -0
  64. package/dist/agents/channels/approval-router.d.ts +158 -0
  65. package/dist/agents/channels/approval-router.d.ts.map +1 -0
  66. package/dist/agents/channels/approval-router.js +446 -0
  67. package/dist/agents/channels/approval-router.js.map +1 -0
  68. package/dist/agents/channels/channel-entry-contract.d.ts +70 -0
  69. package/dist/agents/channels/channel-entry-contract.d.ts.map +1 -0
  70. package/dist/agents/channels/channel-entry-contract.js +48 -0
  71. package/dist/agents/channels/channel-entry-contract.js.map +1 -0
  72. package/dist/agents/channels/channel-plugin-manager.d.ts +86 -0
  73. package/dist/agents/channels/channel-plugin-manager.d.ts.map +1 -0
  74. package/dist/agents/channels/channel-plugin-manager.js +345 -0
  75. package/dist/agents/channels/channel-plugin-manager.js.map +1 -0
  76. package/dist/agents/channels/chat-type.d.ts +27 -0
  77. package/dist/agents/channels/chat-type.d.ts.map +1 -0
  78. package/dist/agents/channels/chat-type.js +33 -0
  79. package/dist/agents/channels/chat-type.js.map +1 -0
  80. package/dist/agents/channels/dedupe.d.ts +44 -0
  81. package/dist/agents/channels/dedupe.d.ts.map +1 -0
  82. package/dist/agents/channels/dedupe.js +80 -0
  83. package/dist/agents/channels/dedupe.js.map +1 -0
  84. package/dist/agents/channels/inbound-pipeline.d.ts +90 -0
  85. package/dist/agents/channels/inbound-pipeline.d.ts.map +1 -0
  86. package/dist/agents/channels/inbound-pipeline.js +721 -0
  87. package/dist/agents/channels/inbound-pipeline.js.map +1 -0
  88. package/dist/agents/channels/last-channel.d.ts +56 -0
  89. package/dist/agents/channels/last-channel.d.ts.map +1 -0
  90. package/dist/agents/channels/last-channel.js +65 -0
  91. package/dist/agents/channels/last-channel.js.map +1 -0
  92. package/dist/agents/channels/manager.d.ts +76 -0
  93. package/dist/agents/channels/manager.d.ts.map +1 -0
  94. package/dist/agents/channels/manager.js +132 -0
  95. package/dist/agents/channels/manager.js.map +1 -0
  96. package/dist/agents/channels/media-capture.d.ts +23 -0
  97. package/dist/agents/channels/media-capture.d.ts.map +1 -0
  98. package/dist/agents/channels/media-capture.js +40 -0
  99. package/dist/agents/channels/media-capture.js.map +1 -0
  100. package/dist/agents/channels/plugin-channel-manager-facade.d.ts +18 -0
  101. package/dist/agents/channels/plugin-channel-manager-facade.d.ts.map +1 -0
  102. package/dist/agents/channels/plugin-channel-manager-facade.js +52 -0
  103. package/dist/agents/channels/plugin-channel-manager-facade.js.map +1 -0
  104. package/dist/agents/channels/reply-sanitizer.d.ts +38 -0
  105. package/dist/agents/channels/reply-sanitizer.d.ts.map +1 -0
  106. package/dist/agents/channels/reply-sanitizer.js +94 -0
  107. package/dist/agents/channels/reply-sanitizer.js.map +1 -0
  108. package/dist/agents/channels/retryable-inbound.d.ts +31 -0
  109. package/dist/agents/channels/retryable-inbound.d.ts.map +1 -0
  110. package/dist/agents/channels/retryable-inbound.js +37 -0
  111. package/dist/agents/channels/retryable-inbound.js.map +1 -0
  112. package/dist/agents/channels/types.adapters.d.ts +399 -0
  113. package/dist/agents/channels/types.adapters.d.ts.map +1 -0
  114. package/dist/agents/channels/types.adapters.js +33 -0
  115. package/dist/agents/channels/types.adapters.js.map +1 -0
  116. package/dist/agents/channels/types.core.d.ts +134 -0
  117. package/dist/agents/channels/types.core.d.ts.map +1 -0
  118. package/dist/agents/channels/types.core.js +32 -0
  119. package/dist/agents/channels/types.core.js.map +1 -0
  120. package/dist/agents/channels/types.plugin.d.ts +78 -0
  121. package/dist/agents/channels/types.plugin.d.ts.map +1 -0
  122. package/dist/agents/channels/types.plugin.js +30 -0
  123. package/dist/agents/channels/types.plugin.js.map +1 -0
  124. package/dist/agents/channels/whatsapp/account-config.d.ts +50 -0
  125. package/dist/agents/channels/whatsapp/account-config.d.ts.map +1 -0
  126. package/dist/agents/channels/whatsapp/account-config.js +105 -0
  127. package/dist/agents/channels/whatsapp/account-config.js.map +1 -0
  128. package/dist/agents/channels/whatsapp/adapter.d.ts +22 -0
  129. package/dist/agents/channels/whatsapp/adapter.d.ts.map +1 -0
  130. package/dist/agents/channels/whatsapp/adapter.js +270 -0
  131. package/dist/agents/channels/whatsapp/adapter.js.map +1 -0
  132. package/dist/agents/channels/whatsapp/chunk.d.ts +26 -0
  133. package/dist/agents/channels/whatsapp/chunk.d.ts.map +1 -0
  134. package/dist/agents/channels/whatsapp/chunk.js +123 -0
  135. package/dist/agents/channels/whatsapp/chunk.js.map +1 -0
  136. package/dist/agents/channels/whatsapp/connection.d.ts +249 -0
  137. package/dist/agents/channels/whatsapp/connection.d.ts.map +1 -0
  138. package/dist/agents/channels/whatsapp/connection.js +1628 -0
  139. package/dist/agents/channels/whatsapp/connection.js.map +1 -0
  140. package/dist/agents/channels/whatsapp/convex-auth-state.d.ts +34 -0
  141. package/dist/agents/channels/whatsapp/convex-auth-state.d.ts.map +1 -0
  142. package/dist/agents/channels/whatsapp/convex-auth-state.js +168 -0
  143. package/dist/agents/channels/whatsapp/convex-auth-state.js.map +1 -0
  144. package/dist/agents/channels/whatsapp/format.d.ts +15 -0
  145. package/dist/agents/channels/whatsapp/format.d.ts.map +1 -0
  146. package/dist/agents/channels/whatsapp/format.js +66 -0
  147. package/dist/agents/channels/whatsapp/format.js.map +1 -0
  148. package/dist/agents/channels/whatsapp/inbound-extras.d.ts +30 -0
  149. package/dist/agents/channels/whatsapp/inbound-extras.d.ts.map +1 -0
  150. package/dist/agents/channels/whatsapp/inbound-extras.js +146 -0
  151. package/dist/agents/channels/whatsapp/inbound-extras.js.map +1 -0
  152. package/dist/agents/channels/whatsapp/index.d.ts +7 -0
  153. package/dist/agents/channels/whatsapp/index.d.ts.map +1 -0
  154. package/dist/agents/channels/whatsapp/index.js +7 -0
  155. package/dist/agents/channels/whatsapp/index.js.map +1 -0
  156. package/dist/agents/channels/whatsapp/media.d.ts +47 -0
  157. package/dist/agents/channels/whatsapp/media.d.ts.map +1 -0
  158. package/dist/agents/channels/whatsapp/media.js +192 -0
  159. package/dist/agents/channels/whatsapp/media.js.map +1 -0
  160. package/dist/agents/channels/whatsapp/module.d.ts +10 -0
  161. package/dist/agents/channels/whatsapp/module.d.ts.map +1 -0
  162. package/dist/agents/channels/whatsapp/module.js +17 -0
  163. package/dist/agents/channels/whatsapp/module.js.map +1 -0
  164. package/dist/agents/channels/whatsapp/plugin.d.ts +60 -0
  165. package/dist/agents/channels/whatsapp/plugin.d.ts.map +1 -0
  166. package/dist/agents/channels/whatsapp/plugin.js +238 -0
  167. package/dist/agents/channels/whatsapp/plugin.js.map +1 -0
  168. package/dist/agents/cmd-ism-guard.d.ts +47 -0
  169. package/dist/agents/cmd-ism-guard.d.ts.map +1 -0
  170. package/dist/agents/cmd-ism-guard.js +100 -0
  171. package/dist/agents/cmd-ism-guard.js.map +1 -0
  172. package/dist/agents/config-write-guard.d.ts +25 -0
  173. package/dist/agents/config-write-guard.d.ts.map +1 -0
  174. package/dist/agents/config-write-guard.js +95 -0
  175. package/dist/agents/config-write-guard.js.map +1 -0
  176. package/dist/agents/content-quality-retry.d.ts +66 -0
  177. package/dist/agents/content-quality-retry.d.ts.map +1 -0
  178. package/dist/agents/content-quality-retry.js +140 -0
  179. package/dist/agents/content-quality-retry.js.map +1 -0
  180. package/dist/agents/error-classifier.d.ts +89 -0
  181. package/dist/agents/error-classifier.d.ts.map +1 -0
  182. package/dist/agents/error-classifier.js +630 -0
  183. package/dist/agents/error-classifier.js.map +1 -0
  184. package/dist/agents/exec-gate.d.ts +113 -0
  185. package/dist/agents/exec-gate.d.ts.map +1 -0
  186. package/dist/agents/exec-gate.js +335 -0
  187. package/dist/agents/exec-gate.js.map +1 -0
  188. package/dist/agents/exec-session-allow.d.ts +30 -0
  189. package/dist/agents/exec-session-allow.d.ts.map +1 -0
  190. package/dist/agents/exec-session-allow.js +50 -0
  191. package/dist/agents/exec-session-allow.js.map +1 -0
  192. package/dist/agents/extensions/active-registry.d.ts +4 -0
  193. package/dist/agents/extensions/active-registry.d.ts.map +1 -0
  194. package/dist/agents/extensions/active-registry.js +18 -0
  195. package/dist/agents/extensions/active-registry.js.map +1 -0
  196. package/dist/agents/extensions/discovery.d.ts +84 -0
  197. package/dist/agents/extensions/discovery.d.ts.map +1 -0
  198. package/dist/agents/extensions/discovery.js +249 -0
  199. package/dist/agents/extensions/discovery.js.map +1 -0
  200. package/dist/agents/extensions/hook-runner.d.ts +67 -0
  201. package/dist/agents/extensions/hook-runner.d.ts.map +1 -0
  202. package/dist/agents/extensions/hook-runner.js +155 -0
  203. package/dist/agents/extensions/hook-runner.js.map +1 -0
  204. package/dist/agents/extensions/index.d.ts +15 -0
  205. package/dist/agents/extensions/index.d.ts.map +1 -0
  206. package/dist/agents/extensions/index.js +14 -0
  207. package/dist/agents/extensions/index.js.map +1 -0
  208. package/dist/agents/extensions/loader.d.ts +38 -0
  209. package/dist/agents/extensions/loader.d.ts.map +1 -0
  210. package/dist/agents/extensions/loader.js +142 -0
  211. package/dist/agents/extensions/loader.js.map +1 -0
  212. package/dist/agents/extensions/modules/arxiv.d.ts +28 -0
  213. package/dist/agents/extensions/modules/arxiv.d.ts.map +1 -0
  214. package/dist/agents/extensions/modules/arxiv.js +145 -0
  215. package/dist/agents/extensions/modules/arxiv.js.map +1 -0
  216. package/dist/agents/extensions/modules/brave.d.ts +28 -0
  217. package/dist/agents/extensions/modules/brave.d.ts.map +1 -0
  218. package/dist/agents/extensions/modules/brave.js +489 -0
  219. package/dist/agents/extensions/modules/brave.js.map +1 -0
  220. package/dist/agents/extensions/modules/duckduckgo.d.ts +27 -0
  221. package/dist/agents/extensions/modules/duckduckgo.d.ts.map +1 -0
  222. package/dist/agents/extensions/modules/duckduckgo.js +263 -0
  223. package/dist/agents/extensions/modules/duckduckgo.js.map +1 -0
  224. package/dist/agents/extensions/modules/exa.d.ts +19 -0
  225. package/dist/agents/extensions/modules/exa.d.ts.map +1 -0
  226. package/dist/agents/extensions/modules/exa.js +208 -0
  227. package/dist/agents/extensions/modules/exa.js.map +1 -0
  228. package/dist/agents/extensions/modules/firecrawl.d.ts +51 -0
  229. package/dist/agents/extensions/modules/firecrawl.d.ts.map +1 -0
  230. package/dist/agents/extensions/modules/firecrawl.js +280 -0
  231. package/dist/agents/extensions/modules/firecrawl.js.map +1 -0
  232. package/dist/agents/extensions/modules/github-search.d.ts +29 -0
  233. package/dist/agents/extensions/modules/github-search.d.ts.map +1 -0
  234. package/dist/agents/extensions/modules/github-search.js +197 -0
  235. package/dist/agents/extensions/modules/github-search.js.map +1 -0
  236. package/dist/agents/extensions/modules/hackernews.d.ts +17 -0
  237. package/dist/agents/extensions/modules/hackernews.d.ts.map +1 -0
  238. package/dist/agents/extensions/modules/hackernews.js +144 -0
  239. package/dist/agents/extensions/modules/hackernews.js.map +1 -0
  240. package/dist/agents/extensions/modules/index.d.ts +11 -0
  241. package/dist/agents/extensions/modules/index.d.ts.map +1 -0
  242. package/dist/agents/extensions/modules/index.js +64 -0
  243. package/dist/agents/extensions/modules/index.js.map +1 -0
  244. package/dist/agents/extensions/modules/npm-search.d.ts +15 -0
  245. package/dist/agents/extensions/modules/npm-search.d.ts.map +1 -0
  246. package/dist/agents/extensions/modules/npm-search.js +126 -0
  247. package/dist/agents/extensions/modules/npm-search.js.map +1 -0
  248. package/dist/agents/extensions/modules/ollama-search.d.ts +30 -0
  249. package/dist/agents/extensions/modules/ollama-search.d.ts.map +1 -0
  250. package/dist/agents/extensions/modules/ollama-search.js +171 -0
  251. package/dist/agents/extensions/modules/ollama-search.js.map +1 -0
  252. package/dist/agents/extensions/modules/perplexity.d.ts +19 -0
  253. package/dist/agents/extensions/modules/perplexity.d.ts.map +1 -0
  254. package/dist/agents/extensions/modules/perplexity.js +358 -0
  255. package/dist/agents/extensions/modules/perplexity.js.map +1 -0
  256. package/dist/agents/extensions/modules/searxng.d.ts +43 -0
  257. package/dist/agents/extensions/modules/searxng.d.ts.map +1 -0
  258. package/dist/agents/extensions/modules/searxng.js +191 -0
  259. package/dist/agents/extensions/modules/searxng.js.map +1 -0
  260. package/dist/agents/extensions/modules/tavily.d.ts +71 -0
  261. package/dist/agents/extensions/modules/tavily.d.ts.map +1 -0
  262. package/dist/agents/extensions/modules/tavily.js +330 -0
  263. package/dist/agents/extensions/modules/tavily.js.map +1 -0
  264. package/dist/agents/extensions/modules/web-provider-helpers.d.ts +89 -0
  265. package/dist/agents/extensions/modules/web-provider-helpers.d.ts.map +1 -0
  266. package/dist/agents/extensions/modules/web-provider-helpers.js +146 -0
  267. package/dist/agents/extensions/modules/web-provider-helpers.js.map +1 -0
  268. package/dist/agents/extensions/modules/web-search-filters.d.ts +62 -0
  269. package/dist/agents/extensions/modules/web-search-filters.d.ts.map +1 -0
  270. package/dist/agents/extensions/modules/web-search-filters.js +179 -0
  271. package/dist/agents/extensions/modules/web-search-filters.js.map +1 -0
  272. package/dist/agents/extensions/modules/wikipedia.d.ts +16 -0
  273. package/dist/agents/extensions/modules/wikipedia.d.ts.map +1 -0
  274. package/dist/agents/extensions/modules/wikipedia.js +138 -0
  275. package/dist/agents/extensions/modules/wikipedia.js.map +1 -0
  276. package/dist/agents/extensions/registry-cache.d.ts +74 -0
  277. package/dist/agents/extensions/registry-cache.d.ts.map +1 -0
  278. package/dist/agents/extensions/registry-cache.js +117 -0
  279. package/dist/agents/extensions/registry-cache.js.map +1 -0
  280. package/dist/agents/extensions/registry.d.ts +184 -0
  281. package/dist/agents/extensions/registry.d.ts.map +1 -0
  282. package/dist/agents/extensions/registry.js +512 -0
  283. package/dist/agents/extensions/registry.js.map +1 -0
  284. package/dist/agents/extensions/types.d.ts +1195 -0
  285. package/dist/agents/extensions/types.d.ts.map +1 -0
  286. package/dist/agents/extensions/types.js +28 -0
  287. package/dist/agents/extensions/types.js.map +1 -0
  288. package/dist/agents/gateway-call.d.ts +171 -0
  289. package/dist/agents/gateway-call.d.ts.map +1 -0
  290. package/dist/agents/gateway-call.js +74 -0
  291. package/dist/agents/gateway-call.js.map +1 -0
  292. package/dist/agents/heartbeat-runner.d.ts +100 -0
  293. package/dist/agents/heartbeat-runner.d.ts.map +1 -0
  294. package/dist/agents/heartbeat-runner.js +268 -0
  295. package/dist/agents/heartbeat-runner.js.map +1 -0
  296. package/dist/agents/heartbeat-scheduler.d.ts +56 -0
  297. package/dist/agents/heartbeat-scheduler.d.ts.map +1 -0
  298. package/dist/agents/heartbeat-scheduler.js +366 -0
  299. package/dist/agents/heartbeat-scheduler.js.map +1 -0
  300. package/dist/agents/heartbeat-wake.d.ts +99 -0
  301. package/dist/agents/heartbeat-wake.d.ts.map +1 -0
  302. package/dist/agents/heartbeat-wake.js +304 -0
  303. package/dist/agents/heartbeat-wake.js.map +1 -0
  304. package/dist/agents/identity-file.d.ts +26 -0
  305. package/dist/agents/identity-file.d.ts.map +1 -0
  306. package/dist/agents/identity-file.js +86 -0
  307. package/dist/agents/identity-file.js.map +1 -0
  308. package/dist/agents/identity-links.d.ts +44 -0
  309. package/dist/agents/identity-links.d.ts.map +1 -0
  310. package/dist/agents/identity-links.js +51 -0
  311. package/dist/agents/identity-links.js.map +1 -0
  312. package/dist/agents/loop/autonomous-agent.d.ts +55 -0
  313. package/dist/agents/loop/autonomous-agent.d.ts.map +1 -0
  314. package/dist/agents/loop/autonomous-agent.js +91 -0
  315. package/dist/agents/loop/autonomous-agent.js.map +1 -0
  316. package/dist/agents/loop/loop-guards.d.ts +95 -0
  317. package/dist/agents/loop/loop-guards.d.ts.map +1 -0
  318. package/dist/agents/loop/loop-guards.js +169 -0
  319. package/dist/agents/loop/loop-guards.js.map +1 -0
  320. package/dist/agents/loop/loop-runner.d.ts +72 -0
  321. package/dist/agents/loop/loop-runner.d.ts.map +1 -0
  322. package/dist/agents/loop/loop-runner.js +114 -0
  323. package/dist/agents/loop/loop-runner.js.map +1 -0
  324. package/dist/agents/memory/auto-recall.d.ts +69 -0
  325. package/dist/agents/memory/auto-recall.d.ts.map +1 -0
  326. package/dist/agents/memory/auto-recall.js +147 -0
  327. package/dist/agents/memory/auto-recall.js.map +1 -0
  328. package/dist/agents/memory/behavior-review.d.ts +68 -0
  329. package/dist/agents/memory/behavior-review.d.ts.map +1 -0
  330. package/dist/agents/memory/behavior-review.js +131 -0
  331. package/dist/agents/memory/behavior-review.js.map +1 -0
  332. package/dist/agents/memory/consolidate.d.ts +62 -0
  333. package/dist/agents/memory/consolidate.d.ts.map +1 -0
  334. package/dist/agents/memory/consolidate.js +275 -0
  335. package/dist/agents/memory/consolidate.js.map +1 -0
  336. package/dist/agents/memory/contradiction.d.ts +44 -0
  337. package/dist/agents/memory/contradiction.d.ts.map +1 -0
  338. package/dist/agents/memory/contradiction.js +86 -0
  339. package/dist/agents/memory/contradiction.js.map +1 -0
  340. package/dist/agents/memory/curator.d.ts +22 -0
  341. package/dist/agents/memory/curator.d.ts.map +1 -0
  342. package/dist/agents/memory/curator.js +52 -0
  343. package/dist/agents/memory/curator.js.map +1 -0
  344. package/dist/agents/memory/decay.d.ts +32 -0
  345. package/dist/agents/memory/decay.d.ts.map +1 -0
  346. package/dist/agents/memory/decay.js +86 -0
  347. package/dist/agents/memory/decay.js.map +1 -0
  348. package/dist/agents/memory/dream.d.ts +52 -0
  349. package/dist/agents/memory/dream.d.ts.map +1 -0
  350. package/dist/agents/memory/dream.js +192 -0
  351. package/dist/agents/memory/dream.js.map +1 -0
  352. package/dist/agents/memory/embedder-providers.d.ts +114 -0
  353. package/dist/agents/memory/embedder-providers.d.ts.map +1 -0
  354. package/dist/agents/memory/embedder-providers.js +213 -0
  355. package/dist/agents/memory/embedder-providers.js.map +1 -0
  356. package/dist/agents/memory/embedder.d.ts +84 -0
  357. package/dist/agents/memory/embedder.d.ts.map +1 -0
  358. package/dist/agents/memory/embedder.js +218 -0
  359. package/dist/agents/memory/embedder.js.map +1 -0
  360. package/dist/agents/memory/eval/asr-bench.d.ts +33 -0
  361. package/dist/agents/memory/eval/asr-bench.d.ts.map +1 -0
  362. package/dist/agents/memory/eval/asr-bench.js +129 -0
  363. package/dist/agents/memory/eval/asr-bench.js.map +1 -0
  364. package/dist/agents/memory/eval/capabilities.d.ts +97 -0
  365. package/dist/agents/memory/eval/capabilities.d.ts.map +1 -0
  366. package/dist/agents/memory/eval/capabilities.js +210 -0
  367. package/dist/agents/memory/eval/capabilities.js.map +1 -0
  368. package/dist/agents/memory/eval/gold-export.d.ts +44 -0
  369. package/dist/agents/memory/eval/gold-export.d.ts.map +1 -0
  370. package/dist/agents/memory/eval/gold-export.js +85 -0
  371. package/dist/agents/memory/eval/gold-export.js.map +1 -0
  372. package/dist/agents/memory/eval/gold-hard.d.ts +35 -0
  373. package/dist/agents/memory/eval/gold-hard.d.ts.map +1 -0
  374. package/dist/agents/memory/eval/gold-hard.js +113 -0
  375. package/dist/agents/memory/eval/gold-hard.js.map +1 -0
  376. package/dist/agents/memory/eval/gold-rich.d.ts +33 -0
  377. package/dist/agents/memory/eval/gold-rich.d.ts.map +1 -0
  378. package/dist/agents/memory/eval/gold-rich.js +82 -0
  379. package/dist/agents/memory/eval/gold-rich.js.map +1 -0
  380. package/dist/agents/memory/eval/gold-synthetic.d.ts +19 -0
  381. package/dist/agents/memory/eval/gold-synthetic.d.ts.map +1 -0
  382. package/dist/agents/memory/eval/gold-synthetic.js +65 -0
  383. package/dist/agents/memory/eval/gold-synthetic.js.map +1 -0
  384. package/dist/agents/memory/eval/gold.d.ts +73 -0
  385. package/dist/agents/memory/eval/gold.d.ts.map +1 -0
  386. package/dist/agents/memory/eval/gold.js +174 -0
  387. package/dist/agents/memory/eval/gold.js.map +1 -0
  388. package/dist/agents/memory/eval/harness.d.ts +110 -0
  389. package/dist/agents/memory/eval/harness.d.ts.map +1 -0
  390. package/dist/agents/memory/eval/harness.js +123 -0
  391. package/dist/agents/memory/eval/harness.js.map +1 -0
  392. package/dist/agents/memory/eval/metrics.d.ts +71 -0
  393. package/dist/agents/memory/eval/metrics.d.ts.map +1 -0
  394. package/dist/agents/memory/eval/metrics.js +169 -0
  395. package/dist/agents/memory/eval/metrics.js.map +1 -0
  396. package/dist/agents/memory/event-log.d.ts +52 -0
  397. package/dist/agents/memory/event-log.d.ts.map +1 -0
  398. package/dist/agents/memory/event-log.js +65 -0
  399. package/dist/agents/memory/event-log.js.map +1 -0
  400. package/dist/agents/memory/extract.d.ts +155 -0
  401. package/dist/agents/memory/extract.d.ts.map +1 -0
  402. package/dist/agents/memory/extract.js +571 -0
  403. package/dist/agents/memory/extract.js.map +1 -0
  404. package/dist/agents/memory/governance.d.ts +45 -0
  405. package/dist/agents/memory/governance.d.ts.map +1 -0
  406. package/dist/agents/memory/governance.js +113 -0
  407. package/dist/agents/memory/governance.js.map +1 -0
  408. package/dist/agents/memory/graph-export.d.ts +59 -0
  409. package/dist/agents/memory/graph-export.d.ts.map +1 -0
  410. package/dist/agents/memory/graph-export.js +181 -0
  411. package/dist/agents/memory/graph-export.js.map +1 -0
  412. package/dist/agents/memory/graph-recall.d.ts +42 -0
  413. package/dist/agents/memory/graph-recall.d.ts.map +1 -0
  414. package/dist/agents/memory/graph-recall.js +165 -0
  415. package/dist/agents/memory/graph-recall.js.map +1 -0
  416. package/dist/agents/memory/graph.d.ts +92 -0
  417. package/dist/agents/memory/graph.d.ts.map +1 -0
  418. package/dist/agents/memory/graph.js +266 -0
  419. package/dist/agents/memory/graph.js.map +1 -0
  420. package/dist/agents/memory/host-ports.d.ts +27 -0
  421. package/dist/agents/memory/host-ports.d.ts.map +1 -0
  422. package/dist/agents/memory/host-ports.js +31 -0
  423. package/dist/agents/memory/host-ports.js.map +1 -0
  424. package/dist/agents/memory/hybrid.d.ts +46 -0
  425. package/dist/agents/memory/hybrid.d.ts.map +1 -0
  426. package/dist/agents/memory/hybrid.js +184 -0
  427. package/dist/agents/memory/hybrid.js.map +1 -0
  428. package/dist/agents/memory/index.d.ts +13 -0
  429. package/dist/agents/memory/index.d.ts.map +1 -0
  430. package/dist/agents/memory/index.js +13 -0
  431. package/dist/agents/memory/index.js.map +1 -0
  432. package/dist/agents/memory/json-scan.d.ts +14 -0
  433. package/dist/agents/memory/json-scan.d.ts.map +1 -0
  434. package/dist/agents/memory/json-scan.js +47 -0
  435. package/dist/agents/memory/json-scan.js.map +1 -0
  436. package/dist/agents/memory/links.d.ts +92 -0
  437. package/dist/agents/memory/links.d.ts.map +1 -0
  438. package/dist/agents/memory/links.js +140 -0
  439. package/dist/agents/memory/links.js.map +1 -0
  440. package/dist/agents/memory/maintenance.d.ts +18 -0
  441. package/dist/agents/memory/maintenance.d.ts.map +1 -0
  442. package/dist/agents/memory/maintenance.js +66 -0
  443. package/dist/agents/memory/maintenance.js.map +1 -0
  444. package/dist/agents/memory/memory-mcp-server.d.ts +39 -0
  445. package/dist/agents/memory/memory-mcp-server.d.ts.map +1 -0
  446. package/dist/agents/memory/memory-mcp-server.js +122 -0
  447. package/dist/agents/memory/memory-mcp-server.js.map +1 -0
  448. package/dist/agents/memory/memory-mcp.d.ts +34 -0
  449. package/dist/agents/memory/memory-mcp.d.ts.map +1 -0
  450. package/dist/agents/memory/memory-mcp.js +130 -0
  451. package/dist/agents/memory/memory-mcp.js.map +1 -0
  452. package/dist/agents/memory/plugin-runtime.d.ts +133 -0
  453. package/dist/agents/memory/plugin-runtime.d.ts.map +1 -0
  454. package/dist/agents/memory/plugin-runtime.js +149 -0
  455. package/dist/agents/memory/plugin-runtime.js.map +1 -0
  456. package/dist/agents/memory/query.d.ts +50 -0
  457. package/dist/agents/memory/query.d.ts.map +1 -0
  458. package/dist/agents/memory/query.js +94 -0
  459. package/dist/agents/memory/query.js.map +1 -0
  460. package/dist/agents/memory/records.d.ts +617 -0
  461. package/dist/agents/memory/records.d.ts.map +1 -0
  462. package/dist/agents/memory/records.js +1327 -0
  463. package/dist/agents/memory/records.js.map +1 -0
  464. package/dist/agents/memory/reembed.d.ts +42 -0
  465. package/dist/agents/memory/reembed.d.ts.map +1 -0
  466. package/dist/agents/memory/reembed.js +60 -0
  467. package/dist/agents/memory/reembed.js.map +1 -0
  468. package/dist/agents/memory/relationship-extract.d.ts +259 -0
  469. package/dist/agents/memory/relationship-extract.d.ts.map +1 -0
  470. package/dist/agents/memory/relationship-extract.js +454 -0
  471. package/dist/agents/memory/relationship-extract.js.map +1 -0
  472. package/dist/agents/memory/rerank.d.ts +37 -0
  473. package/dist/agents/memory/rerank.d.ts.map +1 -0
  474. package/dist/agents/memory/rerank.js +43 -0
  475. package/dist/agents/memory/rerank.js.map +1 -0
  476. package/dist/agents/memory/scoring.d.ts +85 -0
  477. package/dist/agents/memory/scoring.d.ts.map +1 -0
  478. package/dist/agents/memory/scoring.js +139 -0
  479. package/dist/agents/memory/scoring.js.map +1 -0
  480. package/dist/agents/memory/self-improve.d.ts +56 -0
  481. package/dist/agents/memory/self-improve.d.ts.map +1 -0
  482. package/dist/agents/memory/self-improve.js +98 -0
  483. package/dist/agents/memory/self-improve.js.map +1 -0
  484. package/dist/agents/memory/self-review.d.ts +68 -0
  485. package/dist/agents/memory/self-review.d.ts.map +1 -0
  486. package/dist/agents/memory/self-review.js +109 -0
  487. package/dist/agents/memory/self-review.js.map +1 -0
  488. package/dist/agents/memory/storage.d.ts +156 -0
  489. package/dist/agents/memory/storage.d.ts.map +1 -0
  490. package/dist/agents/memory/storage.js +359 -0
  491. package/dist/agents/memory/storage.js.map +1 -0
  492. package/dist/agents/memory/tideline.d.ts +203 -0
  493. package/dist/agents/memory/tideline.d.ts.map +1 -0
  494. package/dist/agents/memory/tideline.js +189 -0
  495. package/dist/agents/memory/tideline.js.map +1 -0
  496. package/dist/agents/memory/vault.d.ts +142 -0
  497. package/dist/agents/memory/vault.d.ts.map +1 -0
  498. package/dist/agents/memory/vault.js +787 -0
  499. package/dist/agents/memory/vault.js.map +1 -0
  500. package/dist/agents/memory/write-gate.d.ts +76 -0
  501. package/dist/agents/memory/write-gate.d.ts.map +1 -0
  502. package/dist/agents/memory/write-gate.js +140 -0
  503. package/dist/agents/memory/write-gate.js.map +1 -0
  504. package/dist/agents/mid-turn-switch.d.ts +25 -0
  505. package/dist/agents/mid-turn-switch.d.ts.map +1 -0
  506. package/dist/agents/mid-turn-switch.js +103 -0
  507. package/dist/agents/mid-turn-switch.js.map +1 -0
  508. package/dist/agents/model-fallback.d.ts +50 -0
  509. package/dist/agents/model-fallback.d.ts.map +1 -0
  510. package/dist/agents/model-fallback.js +226 -0
  511. package/dist/agents/model-fallback.js.map +1 -0
  512. package/dist/agents/model-resolution.d.ts +38 -0
  513. package/dist/agents/model-resolution.d.ts.map +1 -0
  514. package/dist/agents/model-resolution.js +155 -0
  515. package/dist/agents/model-resolution.js.map +1 -0
  516. package/dist/agents/org/a2a-adapter.d.ts +49 -0
  517. package/dist/agents/org/a2a-adapter.d.ts.map +1 -0
  518. package/dist/agents/org/a2a-adapter.js +92 -0
  519. package/dist/agents/org/a2a-adapter.js.map +1 -0
  520. package/dist/agents/org/assets/mascots/README.md +34 -0
  521. package/dist/agents/org/assets/mascots/Untitled-1.png +0 -0
  522. package/dist/agents/org/assets/mascots/brigade_biceps.png +0 -0
  523. package/dist/agents/org/audit-log.d.ts +22 -0
  524. package/dist/agents/org/audit-log.d.ts.map +1 -0
  525. package/dist/agents/org/audit-log.js +37 -0
  526. package/dist/agents/org/audit-log.js.map +1 -0
  527. package/dist/agents/org/auto-derive.d.ts +22 -0
  528. package/dist/agents/org/auto-derive.d.ts.map +1 -0
  529. package/dist/agents/org/auto-derive.js +66 -0
  530. package/dist/agents/org/auto-derive.js.map +1 -0
  531. package/dist/agents/org/delivery-kind.d.ts +89 -0
  532. package/dist/agents/org/delivery-kind.d.ts.map +1 -0
  533. package/dist/agents/org/delivery-kind.js +149 -0
  534. package/dist/agents/org/delivery-kind.js.map +1 -0
  535. package/dist/agents/org/derive-graph.d.ts +34 -0
  536. package/dist/agents/org/derive-graph.d.ts.map +1 -0
  537. package/dist/agents/org/derive-graph.js +266 -0
  538. package/dist/agents/org/derive-graph.js.map +1 -0
  539. package/dist/agents/org/lints.d.ts +21 -0
  540. package/dist/agents/org/lints.d.ts.map +1 -0
  541. package/dist/agents/org/lints.js +133 -0
  542. package/dist/agents/org/lints.js.map +1 -0
  543. package/dist/agents/org/pride-html.d.ts +61 -0
  544. package/dist/agents/org/pride-html.d.ts.map +1 -0
  545. package/dist/agents/org/pride-html.js +565 -0
  546. package/dist/agents/org/pride-html.js.map +1 -0
  547. package/dist/agents/org/pride-image.d.ts +101 -0
  548. package/dist/agents/org/pride-image.d.ts.map +1 -0
  549. package/dist/agents/org/pride-image.js +210 -0
  550. package/dist/agents/org/pride-image.js.map +1 -0
  551. package/dist/agents/org/pride-taunts.d.ts +47 -0
  552. package/dist/agents/org/pride-taunts.d.ts.map +1 -0
  553. package/dist/agents/org/pride-taunts.js +411 -0
  554. package/dist/agents/org/pride-taunts.js.map +1 -0
  555. package/dist/agents/org/pride-template.d.ts +272 -0
  556. package/dist/agents/org/pride-template.d.ts.map +1 -0
  557. package/dist/agents/org/pride-template.js +892 -0
  558. package/dist/agents/org/pride-template.js.map +1 -0
  559. package/dist/agents/org/pride-themes.d.ts +80 -0
  560. package/dist/agents/org/pride-themes.d.ts.map +1 -0
  561. package/dist/agents/org/pride-themes.js +7596 -0
  562. package/dist/agents/org/pride-themes.js.map +1 -0
  563. package/dist/agents/org/structured-errors.d.ts +47 -0
  564. package/dist/agents/org/structured-errors.d.ts.map +1 -0
  565. package/dist/agents/org/structured-errors.js +97 -0
  566. package/dist/agents/org/structured-errors.js.map +1 -0
  567. package/dist/agents/org/types.d.ts +139 -0
  568. package/dist/agents/org/types.d.ts.map +1 -0
  569. package/dist/agents/org/types.js +43 -0
  570. package/dist/agents/org/types.js.map +1 -0
  571. package/dist/agents/org/validate.d.ts +36 -0
  572. package/dist/agents/org/validate.d.ts.map +1 -0
  573. package/dist/agents/org/validate.js +135 -0
  574. package/dist/agents/org/validate.js.map +1 -0
  575. package/dist/agents/path-write-guard.d.ts +82 -0
  576. package/dist/agents/path-write-guard.d.ts.map +1 -0
  577. package/dist/agents/path-write-guard.js +722 -0
  578. package/dist/agents/path-write-guard.js.map +1 -0
  579. package/dist/agents/payload-mutators.d.ts +175 -0
  580. package/dist/agents/payload-mutators.d.ts.map +1 -0
  581. package/dist/agents/payload-mutators.js +994 -0
  582. package/dist/agents/payload-mutators.js.map +1 -0
  583. package/dist/agents/pending-system-events.d.ts +76 -0
  584. package/dist/agents/pending-system-events.d.ts.map +1 -0
  585. package/dist/agents/pending-system-events.js +115 -0
  586. package/dist/agents/pending-system-events.js.map +1 -0
  587. package/dist/agents/provider-attribution.d.ts +19 -0
  588. package/dist/agents/provider-attribution.d.ts.map +1 -0
  589. package/dist/agents/provider-attribution.js +62 -0
  590. package/dist/agents/provider-attribution.js.map +1 -0
  591. package/dist/agents/quality/slop-detector.d.ts +40 -0
  592. package/dist/agents/quality/slop-detector.d.ts.map +1 -0
  593. package/dist/agents/quality/slop-detector.js +108 -0
  594. package/dist/agents/quality/slop-detector.js.map +1 -0
  595. package/dist/agents/quality/slop-index.d.ts +27 -0
  596. package/dist/agents/quality/slop-index.d.ts.map +1 -0
  597. package/dist/agents/quality/slop-index.js +124 -0
  598. package/dist/agents/quality/slop-index.js.map +1 -0
  599. package/dist/agents/retry-policy.d.ts +38 -0
  600. package/dist/agents/retry-policy.d.ts.map +1 -0
  601. package/dist/agents/retry-policy.js +276 -0
  602. package/dist/agents/retry-policy.js.map +1 -0
  603. package/dist/agents/routing/account-id.d.ts +43 -0
  604. package/dist/agents/routing/account-id.d.ts.map +1 -0
  605. package/dist/agents/routing/account-id.js +103 -0
  606. package/dist/agents/routing/account-id.js.map +1 -0
  607. package/dist/agents/routing/bindings.d.ts +20 -0
  608. package/dist/agents/routing/bindings.d.ts.map +1 -0
  609. package/dist/agents/routing/bindings.js +22 -0
  610. package/dist/agents/routing/bindings.js.map +1 -0
  611. package/dist/agents/routing/dm-scope-warning.d.ts +37 -0
  612. package/dist/agents/routing/dm-scope-warning.d.ts.map +1 -0
  613. package/dist/agents/routing/dm-scope-warning.js +110 -0
  614. package/dist/agents/routing/dm-scope-warning.js.map +1 -0
  615. package/dist/agents/routing/identity-links.d.ts +45 -0
  616. package/dist/agents/routing/identity-links.d.ts.map +1 -0
  617. package/dist/agents/routing/identity-links.js +85 -0
  618. package/dist/agents/routing/identity-links.js.map +1 -0
  619. package/dist/agents/routing/resolve-route.d.ts +91 -0
  620. package/dist/agents/routing/resolve-route.d.ts.map +1 -0
  621. package/dist/agents/routing/resolve-route.js +653 -0
  622. package/dist/agents/routing/resolve-route.js.map +1 -0
  623. package/dist/agents/routing/session-key.d.ts +168 -0
  624. package/dist/agents/routing/session-key.d.ts.map +1 -0
  625. package/dist/agents/routing/session-key.js +268 -0
  626. package/dist/agents/routing/session-key.js.map +1 -0
  627. package/dist/agents/sanitize-surrogates.d.ts +30 -0
  628. package/dist/agents/sanitize-surrogates.d.ts.map +1 -0
  629. package/dist/agents/sanitize-surrogates.js +56 -0
  630. package/dist/agents/sanitize-surrogates.js.map +1 -0
  631. package/dist/agents/session-context.d.ts +80 -0
  632. package/dist/agents/session-context.d.ts.map +1 -0
  633. package/dist/agents/session-context.js +76 -0
  634. package/dist/agents/session-context.js.map +1 -0
  635. package/dist/agents/session-event-prompt.d.ts +124 -0
  636. package/dist/agents/session-event-prompt.d.ts.map +1 -0
  637. package/dist/agents/session-event-prompt.js +179 -0
  638. package/dist/agents/session-event-prompt.js.map +1 -0
  639. package/dist/agents/session-inbox.d.ts +129 -0
  640. package/dist/agents/session-inbox.d.ts.map +1 -0
  641. package/dist/agents/session-inbox.js +492 -0
  642. package/dist/agents/session-inbox.js.map +1 -0
  643. package/dist/agents/session-registry.d.ts +148 -0
  644. package/dist/agents/session-registry.d.ts.map +1 -0
  645. package/dist/agents/session-registry.js +405 -0
  646. package/dist/agents/session-registry.js.map +1 -0
  647. package/dist/agents/session-wiring.d.ts +214 -0
  648. package/dist/agents/session-wiring.d.ts.map +1 -0
  649. package/dist/agents/session-wiring.js +278 -0
  650. package/dist/agents/session-wiring.js.map +1 -0
  651. package/dist/agents/session-write-lock.d.ts +15 -0
  652. package/dist/agents/session-write-lock.d.ts.map +1 -0
  653. package/dist/agents/session-write-lock.js +15 -0
  654. package/dist/agents/session-write-lock.js.map +1 -0
  655. package/dist/agents/skills/agent-filter.d.ts +43 -0
  656. package/dist/agents/skills/agent-filter.d.ts.map +1 -0
  657. package/dist/agents/skills/agent-filter.js +89 -0
  658. package/dist/agents/skills/agent-filter.js.map +1 -0
  659. package/dist/agents/skills/discovery.d.ts +97 -0
  660. package/dist/agents/skills/discovery.d.ts.map +1 -0
  661. package/dist/agents/skills/discovery.js +136 -0
  662. package/dist/agents/skills/discovery.js.map +1 -0
  663. package/dist/agents/skills/eligibility.d.ts +118 -0
  664. package/dist/agents/skills/eligibility.d.ts.map +1 -0
  665. package/dist/agents/skills/eligibility.js +280 -0
  666. package/dist/agents/skills/eligibility.js.map +1 -0
  667. package/dist/agents/skills/grant.d.ts +70 -0
  668. package/dist/agents/skills/grant.d.ts.map +1 -0
  669. package/dist/agents/skills/grant.js +106 -0
  670. package/dist/agents/skills/grant.js.map +1 -0
  671. package/dist/agents/skills/index.d.ts +35 -0
  672. package/dist/agents/skills/index.d.ts.map +1 -0
  673. package/dist/agents/skills/index.js +88 -0
  674. package/dist/agents/skills/index.js.map +1 -0
  675. package/dist/agents/skills/install-spec.d.ts +51 -0
  676. package/dist/agents/skills/install-spec.d.ts.map +1 -0
  677. package/dist/agents/skills/install-spec.js +21 -0
  678. package/dist/agents/skills/install-spec.js.map +1 -0
  679. package/dist/agents/skills/install.d.ts +68 -0
  680. package/dist/agents/skills/install.d.ts.map +1 -0
  681. package/dist/agents/skills/install.js +206 -0
  682. package/dist/agents/skills/install.js.map +1 -0
  683. package/dist/agents/skills/org-access.d.ts +27 -0
  684. package/dist/agents/skills/org-access.d.ts.map +1 -0
  685. package/dist/agents/skills/org-access.js +87 -0
  686. package/dist/agents/skills/org-access.js.map +1 -0
  687. package/dist/agents/skills/skill-consolidate.d.ts +76 -0
  688. package/dist/agents/skills/skill-consolidate.d.ts.map +1 -0
  689. package/dist/agents/skills/skill-consolidate.js +264 -0
  690. package/dist/agents/skills/skill-consolidate.js.map +1 -0
  691. package/dist/agents/skills/skill-curator.d.ts +91 -0
  692. package/dist/agents/skills/skill-curator.d.ts.map +1 -0
  693. package/dist/agents/skills/skill-curator.js +239 -0
  694. package/dist/agents/skills/skill-curator.js.map +1 -0
  695. package/dist/agents/skills/skill-manifest.d.ts +35 -0
  696. package/dist/agents/skills/skill-manifest.d.ts.map +1 -0
  697. package/dist/agents/skills/skill-manifest.js +82 -0
  698. package/dist/agents/skills/skill-manifest.js.map +1 -0
  699. package/dist/agents/skills/skill-review.d.ts +91 -0
  700. package/dist/agents/skills/skill-review.d.ts.map +1 -0
  701. package/dist/agents/skills/skill-review.js +271 -0
  702. package/dist/agents/skills/skill-review.js.map +1 -0
  703. package/dist/agents/skills/skill-usage.d.ts +81 -0
  704. package/dist/agents/skills/skill-usage.d.ts.map +1 -0
  705. package/dist/agents/skills/skill-usage.js +208 -0
  706. package/dist/agents/skills/skill-usage.js.map +1 -0
  707. package/dist/agents/skills/status.d.ts +68 -0
  708. package/dist/agents/skills/status.d.ts.map +1 -0
  709. package/dist/agents/skills/status.js +147 -0
  710. package/dist/agents/skills/status.js.map +1 -0
  711. package/dist/agents/skills/update-config.d.ts +32 -0
  712. package/dist/agents/skills/update-config.d.ts.map +1 -0
  713. package/dist/agents/skills/update-config.js +53 -0
  714. package/dist/agents/skills/update-config.js.map +1 -0
  715. package/dist/agents/slash-commands.d.ts +25 -0
  716. package/dist/agents/slash-commands.d.ts.map +1 -0
  717. package/dist/agents/slash-commands.js +151 -0
  718. package/dist/agents/slash-commands.js.map +1 -0
  719. package/dist/agents/smart-compaction.d.ts +105 -0
  720. package/dist/agents/smart-compaction.d.ts.map +1 -0
  721. package/dist/agents/smart-compaction.js +355 -0
  722. package/dist/agents/smart-compaction.js.map +1 -0
  723. package/dist/agents/stream-wrappers.d.ts +20 -0
  724. package/dist/agents/stream-wrappers.d.ts.map +1 -0
  725. package/dist/agents/stream-wrappers.js +307 -0
  726. package/dist/agents/stream-wrappers.js.map +1 -0
  727. package/dist/agents/subagent-abort-cascade.d.ts +31 -0
  728. package/dist/agents/subagent-abort-cascade.d.ts.map +1 -0
  729. package/dist/agents/subagent-abort-cascade.js +124 -0
  730. package/dist/agents/subagent-abort-cascade.js.map +1 -0
  731. package/dist/agents/subagent-announce-delivery.d.ts +83 -0
  732. package/dist/agents/subagent-announce-delivery.d.ts.map +1 -0
  733. package/dist/agents/subagent-announce-delivery.js +159 -0
  734. package/dist/agents/subagent-announce-delivery.js.map +1 -0
  735. package/dist/agents/subagent-budget.d.ts +36 -0
  736. package/dist/agents/subagent-budget.d.ts.map +1 -0
  737. package/dist/agents/subagent-budget.js +93 -0
  738. package/dist/agents/subagent-budget.js.map +1 -0
  739. package/dist/agents/subagent-completion-bridge.d.ts +42 -0
  740. package/dist/agents/subagent-completion-bridge.d.ts.map +1 -0
  741. package/dist/agents/subagent-completion-bridge.js +338 -0
  742. package/dist/agents/subagent-completion-bridge.js.map +1 -0
  743. package/dist/agents/subagent-lifecycle-events.d.ts +31 -0
  744. package/dist/agents/subagent-lifecycle-events.d.ts.map +1 -0
  745. package/dist/agents/subagent-lifecycle-events.js +21 -0
  746. package/dist/agents/subagent-lifecycle-events.js.map +1 -0
  747. package/dist/agents/subagent-policy.d.ts +206 -0
  748. package/dist/agents/subagent-policy.d.ts.map +1 -0
  749. package/dist/agents/subagent-policy.js +295 -0
  750. package/dist/agents/subagent-policy.js.map +1 -0
  751. package/dist/agents/subagent-registry-completion.d.ts +69 -0
  752. package/dist/agents/subagent-registry-completion.d.ts.map +1 -0
  753. package/dist/agents/subagent-registry-completion.js +128 -0
  754. package/dist/agents/subagent-registry-completion.js.map +1 -0
  755. package/dist/agents/subagent-registry.d.ts +85 -0
  756. package/dist/agents/subagent-registry.d.ts.map +1 -0
  757. package/dist/agents/subagent-registry.js +215 -0
  758. package/dist/agents/subagent-registry.js.map +1 -0
  759. package/dist/agents/subagent-registry.types.d.ts +94 -0
  760. package/dist/agents/subagent-registry.types.d.ts.map +1 -0
  761. package/dist/agents/subagent-registry.types.js +19 -0
  762. package/dist/agents/subagent-registry.types.js.map +1 -0
  763. package/dist/agents/subagent-runner.d.ts +75 -0
  764. package/dist/agents/subagent-runner.d.ts.map +1 -0
  765. package/dist/agents/subagent-runner.js +358 -0
  766. package/dist/agents/subagent-runner.js.map +1 -0
  767. package/dist/agents/subagent-spawn-abort-marker.d.ts +46 -0
  768. package/dist/agents/subagent-spawn-abort-marker.d.ts.map +1 -0
  769. package/dist/agents/subagent-spawn-abort-marker.js +81 -0
  770. package/dist/agents/subagent-spawn-abort-marker.js.map +1 -0
  771. package/dist/agents/subagent-spawn.d.ts +104 -0
  772. package/dist/agents/subagent-spawn.d.ts.map +1 -0
  773. package/dist/agents/subagent-spawn.js +358 -0
  774. package/dist/agents/subagent-spawn.js.map +1 -0
  775. package/dist/agents/thinking-fallback.d.ts +49 -0
  776. package/dist/agents/thinking-fallback.d.ts.map +1 -0
  777. package/dist/agents/thinking-fallback.js +97 -0
  778. package/dist/agents/thinking-fallback.js.map +1 -0
  779. package/dist/agents/tool-guard.d.ts +71 -0
  780. package/dist/agents/tool-guard.d.ts.map +1 -0
  781. package/dist/agents/tool-guard.js +154 -0
  782. package/dist/agents/tool-guard.js.map +1 -0
  783. package/dist/agents/tool-loop-detector.d.ts +115 -0
  784. package/dist/agents/tool-loop-detector.d.ts.map +1 -0
  785. package/dist/agents/tool-loop-detector.js +0 -0
  786. package/dist/agents/tool-loop-detector.js.map +1 -0
  787. package/dist/agents/tool-summaries.d.ts +3 -0
  788. package/dist/agents/tool-summaries.d.ts.map +1 -0
  789. package/dist/agents/tool-summaries.js +78 -0
  790. package/dist/agents/tool-summaries.js.map +1 -0
  791. package/dist/agents/tools/agents-list-tool.d.ts +51 -0
  792. package/dist/agents/tools/agents-list-tool.d.ts.map +1 -0
  793. package/dist/agents/tools/agents-list-tool.js +167 -0
  794. package/dist/agents/tools/agents-list-tool.js.map +1 -0
  795. package/dist/agents/tools/browser.d.ts +144 -0
  796. package/dist/agents/tools/browser.d.ts.map +1 -0
  797. package/dist/agents/tools/browser.js +1538 -0
  798. package/dist/agents/tools/browser.js.map +1 -0
  799. package/dist/agents/tools/common.d.ts +208 -0
  800. package/dist/agents/tools/common.d.ts.map +1 -0
  801. package/dist/agents/tools/common.js +405 -0
  802. package/dist/agents/tools/common.js.map +1 -0
  803. package/dist/agents/tools/composio-tool.d.ts +179 -0
  804. package/dist/agents/tools/composio-tool.d.ts.map +1 -0
  805. package/dist/agents/tools/composio-tool.js +474 -0
  806. package/dist/agents/tools/composio-tool.js.map +1 -0
  807. package/dist/agents/tools/cron-tool.d.ts +187 -0
  808. package/dist/agents/tools/cron-tool.d.ts.map +1 -0
  809. package/dist/agents/tools/cron-tool.js +985 -0
  810. package/dist/agents/tools/cron-tool.js.map +1 -0
  811. package/dist/agents/tools/find-tool.d.ts +55 -0
  812. package/dist/agents/tools/find-tool.d.ts.map +1 -0
  813. package/dist/agents/tools/find-tool.js +163 -0
  814. package/dist/agents/tools/find-tool.js.map +1 -0
  815. package/dist/agents/tools/generate-image-tool.d.ts +77 -0
  816. package/dist/agents/tools/generate-image-tool.d.ts.map +1 -0
  817. package/dist/agents/tools/generate-image-tool.js +421 -0
  818. package/dist/agents/tools/generate-image-tool.js.map +1 -0
  819. package/dist/agents/tools/index.d.ts +14 -0
  820. package/dist/agents/tools/index.d.ts.map +1 -0
  821. package/dist/agents/tools/index.js +12 -0
  822. package/dist/agents/tools/index.js.map +1 -0
  823. package/dist/agents/tools/manage-access-tool.d.ts +64 -0
  824. package/dist/agents/tools/manage-access-tool.d.ts.map +1 -0
  825. package/dist/agents/tools/manage-access-tool.js +188 -0
  826. package/dist/agents/tools/manage-access-tool.js.map +1 -0
  827. package/dist/agents/tools/manage-agent-tool.d.ts +50 -0
  828. package/dist/agents/tools/manage-agent-tool.d.ts.map +1 -0
  829. package/dist/agents/tools/manage-agent-tool.js +232 -0
  830. package/dist/agents/tools/manage-agent-tool.js.map +1 -0
  831. package/dist/agents/tools/manage-channel-access-tool.d.ts +44 -0
  832. package/dist/agents/tools/manage-channel-access-tool.d.ts.map +1 -0
  833. package/dist/agents/tools/manage-channel-access-tool.js +144 -0
  834. package/dist/agents/tools/manage-channel-access-tool.js.map +1 -0
  835. package/dist/agents/tools/manage-memory-tool.d.ts +30 -0
  836. package/dist/agents/tools/manage-memory-tool.d.ts.map +1 -0
  837. package/dist/agents/tools/manage-memory-tool.js +309 -0
  838. package/dist/agents/tools/manage-memory-tool.js.map +1 -0
  839. package/dist/agents/tools/manage-provider-tool.d.ts +65 -0
  840. package/dist/agents/tools/manage-provider-tool.d.ts.map +1 -0
  841. package/dist/agents/tools/manage-provider-tool.js +249 -0
  842. package/dist/agents/tools/manage-provider-tool.js.map +1 -0
  843. package/dist/agents/tools/manage-skill-tool.d.ts +121 -0
  844. package/dist/agents/tools/manage-skill-tool.d.ts.map +1 -0
  845. package/dist/agents/tools/manage-skill-tool.js +722 -0
  846. package/dist/agents/tools/manage-skill-tool.js.map +1 -0
  847. package/dist/agents/tools/memory-tools.d.ts +172 -0
  848. package/dist/agents/tools/memory-tools.d.ts.map +1 -0
  849. package/dist/agents/tools/memory-tools.js +561 -0
  850. package/dist/agents/tools/memory-tools.js.map +1 -0
  851. package/dist/agents/tools/oauth-authorize-tool.d.ts +94 -0
  852. package/dist/agents/tools/oauth-authorize-tool.d.ts.map +1 -0
  853. package/dist/agents/tools/oauth-authorize-tool.js +670 -0
  854. package/dist/agents/tools/oauth-authorize-tool.js.map +1 -0
  855. package/dist/agents/tools/org-tool.d.ts +208 -0
  856. package/dist/agents/tools/org-tool.d.ts.map +1 -0
  857. package/dist/agents/tools/org-tool.js +790 -0
  858. package/dist/agents/tools/org-tool.js.map +1 -0
  859. package/dist/agents/tools/registry.d.ts +146 -0
  860. package/dist/agents/tools/registry.d.ts.map +1 -0
  861. package/dist/agents/tools/registry.js +396 -0
  862. package/dist/agents/tools/registry.js.map +1 -0
  863. package/dist/agents/tools/send-media-tool.d.ts +92 -0
  864. package/dist/agents/tools/send-media-tool.d.ts.map +1 -0
  865. package/dist/agents/tools/send-media-tool.js +512 -0
  866. package/dist/agents/tools/send-media-tool.js.map +1 -0
  867. package/dist/agents/tools/send-message-tool.d.ts +84 -0
  868. package/dist/agents/tools/send-message-tool.d.ts.map +1 -0
  869. package/dist/agents/tools/send-message-tool.js +226 -0
  870. package/dist/agents/tools/send-message-tool.js.map +1 -0
  871. package/dist/agents/tools/sessions/history.d.ts +53 -0
  872. package/dist/agents/tools/sessions/history.d.ts.map +1 -0
  873. package/dist/agents/tools/sessions/history.js +138 -0
  874. package/dist/agents/tools/sessions/history.js.map +1 -0
  875. package/dist/agents/tools/sessions/index.d.ts +92 -0
  876. package/dist/agents/tools/sessions/index.d.ts.map +1 -0
  877. package/dist/agents/tools/sessions/index.js +125 -0
  878. package/dist/agents/tools/sessions/index.js.map +1 -0
  879. package/dist/agents/tools/sessions/list.d.ts +53 -0
  880. package/dist/agents/tools/sessions/list.d.ts.map +1 -0
  881. package/dist/agents/tools/sessions/list.js +134 -0
  882. package/dist/agents/tools/sessions/list.js.map +1 -0
  883. package/dist/agents/tools/sessions/resolve-access.d.ts +34 -0
  884. package/dist/agents/tools/sessions/resolve-access.d.ts.map +1 -0
  885. package/dist/agents/tools/sessions/resolve-access.js +67 -0
  886. package/dist/agents/tools/sessions/resolve-access.js.map +1 -0
  887. package/dist/agents/tools/sessions/send.d.ts +68 -0
  888. package/dist/agents/tools/sessions/send.d.ts.map +1 -0
  889. package/dist/agents/tools/sessions/send.js +556 -0
  890. package/dist/agents/tools/sessions/send.js.map +1 -0
  891. package/dist/agents/tools/sessions/shared.d.ts +145 -0
  892. package/dist/agents/tools/sessions/shared.d.ts.map +1 -0
  893. package/dist/agents/tools/sessions/shared.js +352 -0
  894. package/dist/agents/tools/sessions/shared.js.map +1 -0
  895. package/dist/agents/tools/sessions/spawn.d.ts +71 -0
  896. package/dist/agents/tools/sessions/spawn.d.ts.map +1 -0
  897. package/dist/agents/tools/sessions/spawn.js +132 -0
  898. package/dist/agents/tools/sessions/spawn.js.map +1 -0
  899. package/dist/agents/tools/spawn-agent-tool.d.ts +87 -0
  900. package/dist/agents/tools/spawn-agent-tool.d.ts.map +1 -0
  901. package/dist/agents/tools/spawn-agent-tool.js +189 -0
  902. package/dist/agents/tools/spawn-agent-tool.js.map +1 -0
  903. package/dist/agents/tools/spawn-agents-tool.d.ts +75 -0
  904. package/dist/agents/tools/spawn-agents-tool.d.ts.map +1 -0
  905. package/dist/agents/tools/spawn-agents-tool.js +267 -0
  906. package/dist/agents/tools/spawn-agents-tool.js.map +1 -0
  907. package/dist/agents/tools/types.d.ts +55 -0
  908. package/dist/agents/tools/types.d.ts.map +1 -0
  909. package/dist/agents/tools/types.js +28 -0
  910. package/dist/agents/tools/types.js.map +1 -0
  911. package/dist/agents/tools/web-fetch-utils.d.ts +114 -0
  912. package/dist/agents/tools/web-fetch-utils.d.ts.map +1 -0
  913. package/dist/agents/tools/web-fetch-utils.js +560 -0
  914. package/dist/agents/tools/web-fetch-utils.js.map +1 -0
  915. package/dist/agents/tools/web-fetch.d.ts +97 -0
  916. package/dist/agents/tools/web-fetch.d.ts.map +1 -0
  917. package/dist/agents/tools/web-fetch.js +369 -0
  918. package/dist/agents/tools/web-fetch.js.map +1 -0
  919. package/dist/agents/tools/web-retry.d.ts +55 -0
  920. package/dist/agents/tools/web-retry.d.ts.map +1 -0
  921. package/dist/agents/tools/web-retry.js +172 -0
  922. package/dist/agents/tools/web-retry.js.map +1 -0
  923. package/dist/agents/tools/web-search.d.ts +96 -0
  924. package/dist/agents/tools/web-search.d.ts.map +1 -0
  925. package/dist/agents/tools/web-search.js +459 -0
  926. package/dist/agents/tools/web-search.js.map +1 -0
  927. package/dist/agents/tools/web-shared.d.ts +123 -0
  928. package/dist/agents/tools/web-shared.d.ts.map +1 -0
  929. package/dist/agents/tools/web-shared.js +207 -0
  930. package/dist/agents/tools/web-shared.js.map +1 -0
  931. package/dist/assets/brigade-favicon.png +0 -0
  932. package/dist/auth/profile-cooldown.d.ts +105 -0
  933. package/dist/auth/profile-cooldown.d.ts.map +1 -0
  934. package/dist/auth/profile-cooldown.js +466 -0
  935. package/dist/auth/profile-cooldown.js.map +1 -0
  936. package/dist/auth/profiles.d.ts +93 -0
  937. package/dist/auth/profiles.d.ts.map +1 -0
  938. package/dist/auth/profiles.js +321 -0
  939. package/dist/auth/profiles.js.map +1 -0
  940. package/dist/buildstamp.json +1 -0
  941. package/dist/cli/argv.d.ts +20 -0
  942. package/dist/cli/argv.d.ts.map +1 -0
  943. package/dist/cli/argv.js +47 -0
  944. package/dist/cli/argv.js.map +1 -0
  945. package/dist/cli/commands/agent.d.ts +19 -0
  946. package/dist/cli/commands/agent.d.ts.map +1 -0
  947. package/dist/cli/commands/agent.js +297 -0
  948. package/dist/cli/commands/agent.js.map +1 -0
  949. package/dist/cli/commands/agents-bindings.d.ts +80 -0
  950. package/dist/cli/commands/agents-bindings.d.ts.map +1 -0
  951. package/dist/cli/commands/agents-bindings.js +252 -0
  952. package/dist/cli/commands/agents-bindings.js.map +1 -0
  953. package/dist/cli/commands/agents-cmd.d.ts +160 -0
  954. package/dist/cli/commands/agents-cmd.d.ts.map +1 -0
  955. package/dist/cli/commands/agents-cmd.js +1199 -0
  956. package/dist/cli/commands/agents-cmd.js.map +1 -0
  957. package/dist/cli/commands/agents-config.d.ts +102 -0
  958. package/dist/cli/commands/agents-config.d.ts.map +1 -0
  959. package/dist/cli/commands/agents-config.js +294 -0
  960. package/dist/cli/commands/agents-config.js.map +1 -0
  961. package/dist/cli/commands/agents-shared.d.ts +57 -0
  962. package/dist/cli/commands/agents-shared.d.ts.map +1 -0
  963. package/dist/cli/commands/agents-shared.js +83 -0
  964. package/dist/cli/commands/agents-shared.js.map +1 -0
  965. package/dist/cli/commands/backup.d.ts +36 -0
  966. package/dist/cli/commands/backup.d.ts.map +1 -0
  967. package/dist/cli/commands/backup.js +244 -0
  968. package/dist/cli/commands/backup.js.map +1 -0
  969. package/dist/cli/commands/channels.d.ts +106 -0
  970. package/dist/cli/commands/channels.d.ts.map +1 -0
  971. package/dist/cli/commands/channels.js +830 -0
  972. package/dist/cli/commands/channels.js.map +1 -0
  973. package/dist/cli/commands/chat.d.ts +43 -0
  974. package/dist/cli/commands/chat.d.ts.map +1 -0
  975. package/dist/cli/commands/chat.js +84 -0
  976. package/dist/cli/commands/chat.js.map +1 -0
  977. package/dist/cli/commands/config-cmd.d.ts +62 -0
  978. package/dist/cli/commands/config-cmd.d.ts.map +1 -0
  979. package/dist/cli/commands/config-cmd.js +404 -0
  980. package/dist/cli/commands/config-cmd.js.map +1 -0
  981. package/dist/cli/commands/connect.d.ts +73 -0
  982. package/dist/cli/commands/connect.d.ts.map +1 -0
  983. package/dist/cli/commands/connect.js +1952 -0
  984. package/dist/cli/commands/connect.js.map +1 -0
  985. package/dist/cli/commands/cron.d.ts +58 -0
  986. package/dist/cli/commands/cron.d.ts.map +1 -0
  987. package/dist/cli/commands/cron.js +250 -0
  988. package/dist/cli/commands/cron.js.map +1 -0
  989. package/dist/cli/commands/doctor.d.ts +25 -0
  990. package/dist/cli/commands/doctor.d.ts.map +1 -0
  991. package/dist/cli/commands/doctor.js +618 -0
  992. package/dist/cli/commands/doctor.js.map +1 -0
  993. package/dist/cli/commands/encrypt-cmd.d.ts +12 -0
  994. package/dist/cli/commands/encrypt-cmd.d.ts.map +1 -0
  995. package/dist/cli/commands/encrypt-cmd.js +119 -0
  996. package/dist/cli/commands/encrypt-cmd.js.map +1 -0
  997. package/dist/cli/commands/exec-cmd.d.ts +55 -0
  998. package/dist/cli/commands/exec-cmd.d.ts.map +1 -0
  999. package/dist/cli/commands/exec-cmd.js +253 -0
  1000. package/dist/cli/commands/exec-cmd.js.map +1 -0
  1001. package/dist/cli/commands/gateway-install.d.ts +21 -0
  1002. package/dist/cli/commands/gateway-install.d.ts.map +1 -0
  1003. package/dist/cli/commands/gateway-install.js +71 -0
  1004. package/dist/cli/commands/gateway-install.js.map +1 -0
  1005. package/dist/cli/commands/gateway-supervise.d.ts +102 -0
  1006. package/dist/cli/commands/gateway-supervise.d.ts.map +1 -0
  1007. package/dist/cli/commands/gateway-supervise.js +194 -0
  1008. package/dist/cli/commands/gateway-supervise.js.map +1 -0
  1009. package/dist/cli/commands/gateway.d.ts +58 -0
  1010. package/dist/cli/commands/gateway.d.ts.map +1 -0
  1011. package/dist/cli/commands/gateway.js +497 -0
  1012. package/dist/cli/commands/gateway.js.map +1 -0
  1013. package/dist/cli/commands/logs.d.ts +14 -0
  1014. package/dist/cli/commands/logs.d.ts.map +1 -0
  1015. package/dist/cli/commands/logs.js +93 -0
  1016. package/dist/cli/commands/logs.js.map +1 -0
  1017. package/dist/cli/commands/mcp-cmd.d.ts +4 -0
  1018. package/dist/cli/commands/mcp-cmd.d.ts.map +1 -0
  1019. package/dist/cli/commands/mcp-cmd.js +30 -0
  1020. package/dist/cli/commands/mcp-cmd.js.map +1 -0
  1021. package/dist/cli/commands/onboard-config.d.ts +23 -0
  1022. package/dist/cli/commands/onboard-config.d.ts.map +1 -0
  1023. package/dist/cli/commands/onboard-config.js +33 -0
  1024. package/dist/cli/commands/onboard-config.js.map +1 -0
  1025. package/dist/cli/commands/onboard.d.ts +48 -0
  1026. package/dist/cli/commands/onboard.d.ts.map +1 -0
  1027. package/dist/cli/commands/onboard.js +397 -0
  1028. package/dist/cli/commands/onboard.js.map +1 -0
  1029. package/dist/cli/commands/org-cmd.d.ts +87 -0
  1030. package/dist/cli/commands/org-cmd.d.ts.map +1 -0
  1031. package/dist/cli/commands/org-cmd.js +394 -0
  1032. package/dist/cli/commands/org-cmd.js.map +1 -0
  1033. package/dist/cli/commands/org-cmd.templates.d.ts +66 -0
  1034. package/dist/cli/commands/org-cmd.templates.d.ts.map +1 -0
  1035. package/dist/cli/commands/org-cmd.templates.js +145 -0
  1036. package/dist/cli/commands/org-cmd.templates.js.map +1 -0
  1037. package/dist/cli/commands/org-slash.d.ts +107 -0
  1038. package/dist/cli/commands/org-slash.d.ts.map +1 -0
  1039. package/dist/cli/commands/org-slash.js +263 -0
  1040. package/dist/cli/commands/org-slash.js.map +1 -0
  1041. package/dist/cli/commands/pairing.d.ts +33 -0
  1042. package/dist/cli/commands/pairing.d.ts.map +1 -0
  1043. package/dist/cli/commands/pairing.js +155 -0
  1044. package/dist/cli/commands/pairing.js.map +1 -0
  1045. package/dist/cli/commands/secrets-audit.d.ts +17 -0
  1046. package/dist/cli/commands/secrets-audit.d.ts.map +1 -0
  1047. package/dist/cli/commands/secrets-audit.js +109 -0
  1048. package/dist/cli/commands/secrets-audit.js.map +1 -0
  1049. package/dist/cli/commands/sessions.d.ts +22 -0
  1050. package/dist/cli/commands/sessions.d.ts.map +1 -0
  1051. package/dist/cli/commands/sessions.js +99 -0
  1052. package/dist/cli/commands/sessions.js.map +1 -0
  1053. package/dist/cli/commands/skills.d.ts +17 -0
  1054. package/dist/cli/commands/skills.d.ts.map +1 -0
  1055. package/dist/cli/commands/skills.js +100 -0
  1056. package/dist/cli/commands/skills.js.map +1 -0
  1057. package/dist/cli/commands/status.d.ts +26 -0
  1058. package/dist/cli/commands/status.d.ts.map +1 -0
  1059. package/dist/cli/commands/status.js +252 -0
  1060. package/dist/cli/commands/status.js.map +1 -0
  1061. package/dist/cli/commands/store-cmd.d.ts +36 -0
  1062. package/dist/cli/commands/store-cmd.d.ts.map +1 -0
  1063. package/dist/cli/commands/store-cmd.js +405 -0
  1064. package/dist/cli/commands/store-cmd.js.map +1 -0
  1065. package/dist/cli/flows/web-setup.d.ts +47 -0
  1066. package/dist/cli/flows/web-setup.d.ts.map +1 -0
  1067. package/dist/cli/flows/web-setup.js +324 -0
  1068. package/dist/cli/flows/web-setup.js.map +1 -0
  1069. package/dist/cli/program/build-program.d.ts +3 -0
  1070. package/dist/cli/program/build-program.d.ts.map +1 -0
  1071. package/dist/cli/program/build-program.js +1326 -0
  1072. package/dist/cli/program/build-program.js.map +1 -0
  1073. package/dist/cli/run-main.d.ts +2 -0
  1074. package/dist/cli/run-main.d.ts.map +1 -0
  1075. package/dist/cli/run-main.js +63 -0
  1076. package/dist/cli/run-main.js.map +1 -0
  1077. package/dist/config/agent-limits.d.ts +22 -0
  1078. package/dist/config/agent-limits.d.ts.map +1 -0
  1079. package/dist/config/agent-limits.js +34 -0
  1080. package/dist/config/agent-limits.js.map +1 -0
  1081. package/dist/config/io.d.ts +378 -0
  1082. package/dist/config/io.d.ts.map +1 -0
  1083. package/dist/config/io.js +602 -0
  1084. package/dist/config/io.js.map +1 -0
  1085. package/dist/config/paths.d.ts +80 -0
  1086. package/dist/config/paths.d.ts.map +1 -0
  1087. package/dist/config/paths.js +342 -0
  1088. package/dist/config/paths.js.map +1 -0
  1089. package/dist/config/types.d.ts +12 -0
  1090. package/dist/config/types.d.ts.map +1 -0
  1091. package/dist/config/types.js +12 -0
  1092. package/dist/config/types.js.map +1 -0
  1093. package/dist/core/agent-dispatcher.d.ts +91 -0
  1094. package/dist/core/agent-dispatcher.d.ts.map +1 -0
  1095. package/dist/core/agent-dispatcher.js +251 -0
  1096. package/dist/core/agent-dispatcher.js.map +1 -0
  1097. package/dist/core/agent-events-stream.d.ts +76 -0
  1098. package/dist/core/agent-events-stream.d.ts.map +1 -0
  1099. package/dist/core/agent-events-stream.js +185 -0
  1100. package/dist/core/agent-events-stream.js.map +1 -0
  1101. package/dist/core/agent-runtime-persist.d.ts +53 -0
  1102. package/dist/core/agent-runtime-persist.d.ts.map +1 -0
  1103. package/dist/core/agent-runtime-persist.js +114 -0
  1104. package/dist/core/agent-runtime-persist.js.map +1 -0
  1105. package/dist/core/auth-bridge.d.ts +8 -0
  1106. package/dist/core/auth-bridge.d.ts.map +1 -0
  1107. package/dist/core/auth-bridge.js +102 -0
  1108. package/dist/core/auth-bridge.js.map +1 -0
  1109. package/dist/core/auth-error.d.ts +49 -0
  1110. package/dist/core/auth-error.d.ts.map +1 -0
  1111. package/dist/core/auth-error.js.map +1 -0
  1112. package/dist/core/brigade-config.d.ts +205 -0
  1113. package/dist/core/brigade-config.d.ts.map +1 -0
  1114. package/dist/core/brigade-config.js +58 -6
  1115. package/dist/core/brigade-config.js.map +1 -0
  1116. package/dist/core/config.d.ts +17 -0
  1117. package/dist/core/config.d.ts.map +1 -0
  1118. package/dist/core/config.js +92 -246
  1119. package/dist/core/config.js.map +1 -0
  1120. package/dist/core/console-stream.d.ts +52 -0
  1121. package/dist/core/console-stream.d.ts.map +1 -0
  1122. package/dist/core/console-stream.js +49 -3
  1123. package/dist/core/console-stream.js.map +1 -0
  1124. package/dist/core/daemon/launchd.d.ts +19 -0
  1125. package/dist/core/daemon/launchd.d.ts.map +1 -0
  1126. package/dist/core/daemon/launchd.js +117 -0
  1127. package/dist/core/daemon/launchd.js.map +1 -0
  1128. package/dist/core/daemon/schtasks.d.ts +23 -0
  1129. package/dist/core/daemon/schtasks.d.ts.map +1 -0
  1130. package/dist/core/daemon/schtasks.js +139 -0
  1131. package/dist/core/daemon/schtasks.js.map +1 -0
  1132. package/dist/core/daemon/service.d.ts +56 -0
  1133. package/dist/core/daemon/service.d.ts.map +1 -0
  1134. package/dist/core/daemon/service.js +54 -0
  1135. package/dist/core/daemon/service.js.map +1 -0
  1136. package/dist/core/daemon/systemd.d.ts +19 -0
  1137. package/dist/core/daemon/systemd.d.ts.map +1 -0
  1138. package/dist/core/daemon/systemd.js +117 -0
  1139. package/dist/core/daemon/systemd.js.map +1 -0
  1140. package/dist/core/event-logger.d.ts +74 -0
  1141. package/dist/core/event-logger.d.ts.map +1 -0
  1142. package/dist/core/event-logger.js +299 -6
  1143. package/dist/core/event-logger.js.map +1 -0
  1144. package/dist/core/exec-approvals.d.ts +178 -0
  1145. package/dist/core/exec-approvals.d.ts.map +1 -0
  1146. package/dist/core/exec-approvals.js +591 -266
  1147. package/dist/core/exec-approvals.js.map +1 -0
  1148. package/dist/core/extension-lifecycle.d.ts +27 -0
  1149. package/dist/core/extension-lifecycle.d.ts.map +1 -0
  1150. package/dist/core/extension-lifecycle.js +45 -0
  1151. package/dist/core/extension-lifecycle.js.map +1 -0
  1152. package/dist/core/gateway-caller-impl.d.ts +42 -0
  1153. package/dist/core/gateway-caller-impl.d.ts.map +1 -0
  1154. package/dist/core/gateway-caller-impl.js +95 -0
  1155. package/dist/core/gateway-caller-impl.js.map +1 -0
  1156. package/dist/core/gateway-lock.d.ts +88 -0
  1157. package/dist/core/gateway-lock.d.ts.map +1 -0
  1158. package/dist/core/gateway-lock.js +204 -0
  1159. package/dist/core/gateway-lock.js.map +1 -0
  1160. package/dist/core/gateway-probe.d.ts +148 -0
  1161. package/dist/core/gateway-probe.d.ts.map +1 -0
  1162. package/dist/core/gateway-probe.js +319 -0
  1163. package/dist/core/gateway-probe.js.map +1 -0
  1164. package/dist/core/gateway-spawn.d.ts +40 -0
  1165. package/dist/core/gateway-spawn.d.ts.map +1 -0
  1166. package/dist/core/gateway-spawn.js +156 -0
  1167. package/dist/core/gateway-spawn.js.map +1 -0
  1168. package/dist/core/model-caps.d.ts +85 -0
  1169. package/dist/core/model-caps.d.ts.map +1 -0
  1170. package/dist/core/model-caps.js +88 -2
  1171. package/dist/core/model-caps.js.map +1 -0
  1172. package/dist/core/port-inspect.d.ts +37 -0
  1173. package/dist/core/port-inspect.d.ts.map +1 -0
  1174. package/dist/core/port-inspect.js +165 -0
  1175. package/dist/core/port-inspect.js.map +1 -0
  1176. package/dist/core/server-lanes.d.ts +25 -0
  1177. package/dist/core/server-lanes.d.ts.map +1 -0
  1178. package/dist/core/server-lanes.js +31 -0
  1179. package/dist/core/server-lanes.js.map +1 -0
  1180. package/dist/core/server-methods/cron.d.ts +104 -0
  1181. package/dist/core/server-methods/cron.d.ts.map +1 -0
  1182. package/dist/core/server-methods/cron.js +183 -0
  1183. package/dist/core/server-methods/cron.js.map +1 -0
  1184. package/dist/core/server-methods/health.d.ts +36 -0
  1185. package/dist/core/server-methods/health.d.ts.map +1 -0
  1186. package/dist/core/server-methods/health.js +51 -0
  1187. package/dist/core/server-methods/health.js.map +1 -0
  1188. package/dist/core/server-methods/org.d.ts +93 -0
  1189. package/dist/core/server-methods/org.d.ts.map +1 -0
  1190. package/dist/core/server-methods/org.js +95 -0
  1191. package/dist/core/server-methods/org.js.map +1 -0
  1192. package/dist/core/server-methods/sessions.d.ts +133 -0
  1193. package/dist/core/server-methods/sessions.d.ts.map +1 -0
  1194. package/dist/core/server-methods/sessions.js +209 -0
  1195. package/dist/core/server-methods/sessions.js.map +1 -0
  1196. package/dist/core/server.d.ts +46 -0
  1197. package/dist/core/server.d.ts.map +1 -0
  1198. package/dist/core/server.js +4716 -249
  1199. package/dist/core/server.js.map +1 -0
  1200. package/dist/core/system-prompt.d.ts +92 -0
  1201. package/dist/core/system-prompt.d.ts.map +1 -0
  1202. package/dist/core/system-prompt.js +180 -1584
  1203. package/dist/core/system-prompt.js.map +1 -0
  1204. package/dist/core/version.d.ts +4 -0
  1205. package/dist/core/version.d.ts.map +1 -0
  1206. package/dist/core/version.js +8 -13
  1207. package/dist/core/version.js.map +1 -0
  1208. package/dist/core/webhook-guards.d.ts +131 -0
  1209. package/dist/core/webhook-guards.d.ts.map +1 -0
  1210. package/dist/core/webhook-guards.js +283 -0
  1211. package/dist/core/webhook-guards.js.map +1 -0
  1212. package/dist/core/ws-subscription-filter.d.ts +9 -0
  1213. package/dist/core/ws-subscription-filter.d.ts.map +1 -0
  1214. package/dist/core/ws-subscription-filter.js +39 -0
  1215. package/dist/core/ws-subscription-filter.js.map +1 -0
  1216. package/dist/cron/active-service.d.ts +30 -0
  1217. package/dist/cron/active-service.d.ts.map +1 -0
  1218. package/dist/cron/active-service.js +48 -0
  1219. package/dist/cron/active-service.js.map +1 -0
  1220. package/dist/cron/isolated-agent/run-executor.d.ts +49 -0
  1221. package/dist/cron/isolated-agent/run-executor.d.ts.map +1 -0
  1222. package/dist/cron/isolated-agent/run-executor.js +343 -0
  1223. package/dist/cron/isolated-agent/run-executor.js.map +1 -0
  1224. package/dist/cron/isolated-agent/run.d.ts +27 -0
  1225. package/dist/cron/isolated-agent/run.d.ts.map +1 -0
  1226. package/dist/cron/isolated-agent/run.js +29 -0
  1227. package/dist/cron/isolated-agent/run.js.map +1 -0
  1228. package/dist/cron/normalize.d.ts +103 -0
  1229. package/dist/cron/normalize.d.ts.map +1 -0
  1230. package/dist/cron/normalize.js +376 -0
  1231. package/dist/cron/normalize.js.map +1 -0
  1232. package/dist/cron/parse.d.ts +27 -0
  1233. package/dist/cron/parse.d.ts.map +1 -0
  1234. package/dist/cron/parse.js +55 -0
  1235. package/dist/cron/parse.js.map +1 -0
  1236. package/dist/cron/reminder-context.d.ts +78 -0
  1237. package/dist/cron/reminder-context.d.ts.map +1 -0
  1238. package/dist/cron/reminder-context.js +167 -0
  1239. package/dist/cron/reminder-context.js.map +1 -0
  1240. package/dist/cron/run-log.d.ts +48 -0
  1241. package/dist/cron/run-log.d.ts.map +1 -0
  1242. package/dist/cron/run-log.js +225 -0
  1243. package/dist/cron/run-log.js.map +1 -0
  1244. package/dist/cron/schedule.d.ts +46 -0
  1245. package/dist/cron/schedule.d.ts.map +1 -0
  1246. package/dist/cron/schedule.js +144 -0
  1247. package/dist/cron/schedule.js.map +1 -0
  1248. package/dist/cron/service/jobs.d.ts +138 -0
  1249. package/dist/cron/service/jobs.d.ts.map +1 -0
  1250. package/dist/cron/service/jobs.js +370 -0
  1251. package/dist/cron/service/jobs.js.map +1 -0
  1252. package/dist/cron/service/locked.d.ts +46 -0
  1253. package/dist/cron/service/locked.d.ts.map +1 -0
  1254. package/dist/cron/service/locked.js +54 -0
  1255. package/dist/cron/service/locked.js.map +1 -0
  1256. package/dist/cron/service/ops.d.ts +124 -0
  1257. package/dist/cron/service/ops.d.ts.map +1 -0
  1258. package/dist/cron/service/ops.js +415 -0
  1259. package/dist/cron/service/ops.js.map +1 -0
  1260. package/dist/cron/service/state.d.ts +254 -0
  1261. package/dist/cron/service/state.d.ts.map +1 -0
  1262. package/dist/cron/service/state.js +50 -0
  1263. package/dist/cron/service/state.js.map +1 -0
  1264. package/dist/cron/service/store.d.ts +65 -0
  1265. package/dist/cron/service/store.d.ts.map +1 -0
  1266. package/dist/cron/service/store.js +350 -0
  1267. package/dist/cron/service/store.js.map +1 -0
  1268. package/dist/cron/service/timer.d.ts +113 -0
  1269. package/dist/cron/service/timer.d.ts.map +1 -0
  1270. package/dist/cron/service/timer.js +1081 -0
  1271. package/dist/cron/service/timer.js.map +1 -0
  1272. package/dist/cron/session-reaper.d.ts +62 -0
  1273. package/dist/cron/session-reaper.d.ts.map +1 -0
  1274. package/dist/cron/session-reaper.js +152 -0
  1275. package/dist/cron/session-reaper.js.map +1 -0
  1276. package/dist/cron/session-target.d.ts +56 -0
  1277. package/dist/cron/session-target.d.ts.map +1 -0
  1278. package/dist/cron/session-target.js +96 -0
  1279. package/dist/cron/session-target.js.map +1 -0
  1280. package/dist/cron/stagger.d.ts +34 -0
  1281. package/dist/cron/stagger.d.ts.map +1 -0
  1282. package/dist/cron/stagger.js +69 -0
  1283. package/dist/cron/stagger.js.map +1 -0
  1284. package/dist/cron/types.d.ts +287 -0
  1285. package/dist/cron/types.d.ts.map +1 -0
  1286. package/dist/cron/types.js +22 -0
  1287. package/dist/cron/types.js.map +1 -0
  1288. package/dist/cron/validate-timestamp.d.ts +33 -0
  1289. package/dist/cron/validate-timestamp.d.ts.map +1 -0
  1290. package/dist/cron/validate-timestamp.js +54 -0
  1291. package/dist/cron/validate-timestamp.js.map +1 -0
  1292. package/dist/entry.d.ts +2 -0
  1293. package/dist/entry.d.ts.map +1 -0
  1294. package/dist/entry.js +57 -0
  1295. package/dist/entry.js.map +1 -0
  1296. package/dist/extension-sdk.d.ts +28 -0
  1297. package/dist/extension-sdk.d.ts.map +1 -0
  1298. package/dist/extension-sdk.js +26 -0
  1299. package/dist/extension-sdk.js.map +1 -0
  1300. package/dist/identity/device.d.ts +19 -0
  1301. package/dist/identity/device.d.ts.map +1 -0
  1302. package/dist/identity/device.js +88 -0
  1303. package/dist/identity/device.js.map +1 -0
  1304. package/dist/infra/backoff.d.ts +24 -0
  1305. package/dist/infra/backoff.d.ts.map +1 -0
  1306. package/dist/infra/backoff.js +48 -0
  1307. package/dist/infra/backoff.js.map +1 -0
  1308. package/dist/infra/errors.d.ts +35 -0
  1309. package/dist/infra/errors.d.ts.map +1 -0
  1310. package/dist/infra/errors.js +54 -0
  1311. package/dist/infra/errors.js.map +1 -0
  1312. package/dist/infra/fs/atomic-rename.d.ts +31 -0
  1313. package/dist/infra/fs/atomic-rename.d.ts.map +1 -0
  1314. package/dist/infra/fs/atomic-rename.js +75 -0
  1315. package/dist/infra/fs/atomic-rename.js.map +1 -0
  1316. package/dist/infra/json-file.d.ts +25 -0
  1317. package/dist/infra/json-file.d.ts.map +1 -0
  1318. package/dist/infra/json-file.js +49 -0
  1319. package/dist/infra/json-file.js.map +1 -0
  1320. package/dist/infra/json-utf8-bytes.d.ts +14 -0
  1321. package/dist/infra/json-utf8-bytes.d.ts.map +1 -0
  1322. package/dist/infra/json-utf8-bytes.js +20 -0
  1323. package/dist/infra/json-utf8-bytes.js.map +1 -0
  1324. package/dist/infra/net/dns-pinning.d.ts +66 -0
  1325. package/dist/infra/net/dns-pinning.d.ts.map +1 -0
  1326. package/dist/infra/net/dns-pinning.js +128 -0
  1327. package/dist/infra/net/dns-pinning.js.map +1 -0
  1328. package/dist/infra/net/fetch-guard.d.ts +85 -0
  1329. package/dist/infra/net/fetch-guard.d.ts.map +1 -0
  1330. package/dist/infra/net/fetch-guard.js +439 -0
  1331. package/dist/infra/net/fetch-guard.js.map +1 -0
  1332. package/dist/infra/prototype-keys.d.ts +19 -0
  1333. package/dist/infra/prototype-keys.d.ts.map +1 -0
  1334. package/dist/infra/prototype-keys.js +22 -0
  1335. package/dist/infra/prototype-keys.js.map +1 -0
  1336. package/dist/integrations/ollama.d.ts +67 -0
  1337. package/dist/integrations/ollama.d.ts.map +1 -0
  1338. package/dist/integrations/ollama.js +53 -0
  1339. package/dist/integrations/ollama.js.map +1 -0
  1340. package/dist/integrations/provider-discovery.d.ts +66 -0
  1341. package/dist/integrations/provider-discovery.d.ts.map +1 -0
  1342. package/dist/integrations/provider-discovery.js +166 -0
  1343. package/dist/integrations/provider-discovery.js.map +1 -0
  1344. package/dist/logging/redact.d.ts +28 -0
  1345. package/dist/logging/redact.d.ts.map +1 -0
  1346. package/dist/logging/redact.js +51 -0
  1347. package/dist/logging/redact.js.map +1 -0
  1348. package/dist/logging/subsystem-logger.d.ts +77 -0
  1349. package/dist/logging/subsystem-logger.d.ts.map +1 -0
  1350. package/dist/logging/subsystem-logger.js +577 -0
  1351. package/dist/logging/subsystem-logger.js.map +1 -0
  1352. package/dist/logging/subsystem.d.ts +13 -0
  1353. package/dist/logging/subsystem.d.ts.map +1 -0
  1354. package/dist/logging/subsystem.js +12 -0
  1355. package/dist/logging/subsystem.js.map +1 -0
  1356. package/dist/process/command-queue.d.ts +152 -0
  1357. package/dist/process/command-queue.d.ts.map +1 -0
  1358. package/dist/process/command-queue.js +420 -0
  1359. package/dist/process/command-queue.js.map +1 -0
  1360. package/dist/process/lanes.d.ts +102 -0
  1361. package/dist/process/lanes.d.ts.map +1 -0
  1362. package/dist/process/lanes.js +117 -0
  1363. package/dist/process/lanes.js.map +1 -0
  1364. package/dist/process/session-lane.d.ts +31 -0
  1365. package/dist/process/session-lane.d.ts.map +1 -0
  1366. package/dist/process/session-lane.js +45 -0
  1367. package/dist/process/session-lane.js.map +1 -0
  1368. package/dist/protocol/errors.d.ts +35 -0
  1369. package/dist/protocol/errors.d.ts.map +1 -0
  1370. package/dist/protocol/errors.js +36 -0
  1371. package/dist/protocol/errors.js.map +1 -0
  1372. package/dist/protocol/handshake.d.ts +101 -0
  1373. package/dist/protocol/handshake.d.ts.map +1 -0
  1374. package/dist/protocol/handshake.js +49 -0
  1375. package/dist/protocol/handshake.js.map +1 -0
  1376. package/dist/protocol/messages.d.ts +68 -0
  1377. package/dist/protocol/messages.d.ts.map +1 -0
  1378. package/dist/protocol/messages.js +20 -0
  1379. package/dist/protocol/messages.js.map +1 -0
  1380. package/dist/protocol/methods.d.ts +312 -0
  1381. package/dist/protocol/methods.d.ts.map +1 -0
  1382. package/dist/protocol/methods.js +16 -0
  1383. package/dist/protocol/methods.js.map +1 -0
  1384. package/dist/protocol.d.ts +598 -0
  1385. package/dist/protocol.d.ts.map +1 -0
  1386. package/dist/protocol.js +12 -0
  1387. package/dist/protocol.js.map +1 -0
  1388. package/dist/providers/auth-methods.d.ts +82 -0
  1389. package/dist/providers/auth-methods.d.ts.map +1 -0
  1390. package/dist/providers/auth-methods.js +180 -0
  1391. package/dist/providers/auth-methods.js.map +1 -0
  1392. package/dist/providers/catalog.d.ts +85 -0
  1393. package/dist/providers/catalog.d.ts.map +1 -0
  1394. package/dist/providers/catalog.js +41 -0
  1395. package/dist/providers/catalog.js.map +1 -0
  1396. package/dist/providers/validate-key.d.ts +42 -0
  1397. package/dist/providers/validate-key.d.ts.map +1 -0
  1398. package/dist/providers/validate-key.js.map +1 -0
  1399. package/dist/security/external-content.d.ts +67 -0
  1400. package/dist/security/external-content.d.ts.map +1 -0
  1401. package/dist/security/external-content.js +80 -0
  1402. package/dist/security/external-content.js.map +1 -0
  1403. package/dist/security/injection-patterns.d.ts +33 -0
  1404. package/dist/security/injection-patterns.d.ts.map +1 -0
  1405. package/dist/security/injection-patterns.js +97 -0
  1406. package/dist/security/injection-patterns.js.map +1 -0
  1407. package/dist/security/media-path-guard.d.ts +25 -0
  1408. package/dist/security/media-path-guard.d.ts.map +1 -0
  1409. package/dist/security/media-path-guard.js +98 -0
  1410. package/dist/security/media-path-guard.js.map +1 -0
  1411. package/dist/security/terminal-input-sanitizer.d.ts +30 -0
  1412. package/dist/security/terminal-input-sanitizer.d.ts.map +1 -0
  1413. package/dist/security/terminal-input-sanitizer.js +70 -0
  1414. package/dist/security/terminal-input-sanitizer.js.map +1 -0
  1415. package/dist/sessions/bootstrap-marker.d.ts +5 -0
  1416. package/dist/sessions/bootstrap-marker.d.ts.map +1 -0
  1417. package/dist/sessions/bootstrap-marker.js +120 -0
  1418. package/dist/sessions/bootstrap-marker.js.map +1 -0
  1419. package/dist/sessions/session-file-repair.d.ts +12 -0
  1420. package/dist/sessions/session-file-repair.d.ts.map +1 -0
  1421. package/dist/sessions/session-file-repair.js +155 -0
  1422. package/dist/sessions/session-file-repair.js.map +1 -0
  1423. package/dist/sessions/session-key-utils.d.ts +54 -0
  1424. package/dist/sessions/session-key-utils.d.ts.map +1 -0
  1425. package/dist/sessions/session-key-utils.js +133 -0
  1426. package/dist/sessions/session-key-utils.js.map +1 -0
  1427. package/dist/sessions/session-manager-factory.d.ts +21 -0
  1428. package/dist/sessions/session-manager-factory.d.ts.map +1 -0
  1429. package/dist/sessions/session-manager-factory.js +142 -0
  1430. package/dist/sessions/session-manager-factory.js.map +1 -0
  1431. package/dist/sessions/session-store.d.ts +154 -0
  1432. package/dist/sessions/session-store.d.ts.map +1 -0
  1433. package/dist/sessions/session-store.js +498 -0
  1434. package/dist/sessions/session-store.js.map +1 -0
  1435. package/dist/sessions/session-write-lock.d.ts +10 -0
  1436. package/dist/sessions/session-write-lock.d.ts.map +1 -0
  1437. package/dist/sessions/session-write-lock.js +167 -0
  1438. package/dist/sessions/session-write-lock.js.map +1 -0
  1439. package/dist/sessions/transcript-reader.d.ts +37 -0
  1440. package/dist/sessions/transcript-reader.d.ts.map +1 -0
  1441. package/dist/sessions/transcript-reader.js +136 -0
  1442. package/dist/sessions/transcript-reader.js.map +1 -0
  1443. package/dist/sessions/transcript-repair.d.ts +16 -0
  1444. package/dist/sessions/transcript-repair.d.ts.map +1 -0
  1445. package/dist/sessions/transcript-repair.js +214 -0
  1446. package/dist/sessions/transcript-repair.js.map +1 -0
  1447. package/dist/shared/global-singleton.d.ts +27 -0
  1448. package/dist/shared/global-singleton.d.ts.map +1 -0
  1449. package/dist/shared/global-singleton.js +35 -0
  1450. package/dist/shared/global-singleton.js.map +1 -0
  1451. package/dist/shared/string-coerce.d.ts +12 -0
  1452. package/dist/shared/string-coerce.d.ts.map +1 -0
  1453. package/dist/shared/string-coerce.js +12 -0
  1454. package/dist/shared/string-coerce.js.map +1 -0
  1455. package/dist/storage/boot.d.ts +28 -0
  1456. package/dist/storage/boot.d.ts.map +1 -0
  1457. package/dist/storage/boot.js +588 -0
  1458. package/dist/storage/boot.js.map +1 -0
  1459. package/dist/storage/config-cache.d.ts +23 -0
  1460. package/dist/storage/config-cache.d.ts.map +1 -0
  1461. package/dist/storage/config-cache.js +58 -0
  1462. package/dist/storage/config-cache.js.map +1 -0
  1463. package/dist/storage/convex/auth-store.d.ts +52 -0
  1464. package/dist/storage/convex/auth-store.d.ts.map +1 -0
  1465. package/dist/storage/convex/auth-store.js +282 -0
  1466. package/dist/storage/convex/auth-store.js.map +1 -0
  1467. package/dist/storage/convex/blob-store.d.ts +20 -0
  1468. package/dist/storage/convex/blob-store.d.ts.map +1 -0
  1469. package/dist/storage/convex/blob-store.js +74 -0
  1470. package/dist/storage/convex/blob-store.js.map +1 -0
  1471. package/dist/storage/convex/channel-store.d.ts +112 -0
  1472. package/dist/storage/convex/channel-store.d.ts.map +1 -0
  1473. package/dist/storage/convex/channel-store.js +267 -0
  1474. package/dist/storage/convex/channel-store.js.map +1 -0
  1475. package/dist/storage/convex/client.d.ts +53 -0
  1476. package/dist/storage/convex/client.d.ts.map +1 -0
  1477. package/dist/storage/convex/client.js +121 -0
  1478. package/dist/storage/convex/client.js.map +1 -0
  1479. package/dist/storage/convex/config-store.d.ts +29 -0
  1480. package/dist/storage/convex/config-store.d.ts.map +1 -0
  1481. package/dist/storage/convex/config-store.js +205 -0
  1482. package/dist/storage/convex/config-store.js.map +1 -0
  1483. package/dist/storage/convex/cron-store.d.ts +86 -0
  1484. package/dist/storage/convex/cron-store.d.ts.map +1 -0
  1485. package/dist/storage/convex/cron-store.js +428 -0
  1486. package/dist/storage/convex/cron-store.js.map +1 -0
  1487. package/dist/storage/convex/exec-approval-store.d.ts +38 -0
  1488. package/dist/storage/convex/exec-approval-store.d.ts.map +1 -0
  1489. package/dist/storage/convex/exec-approval-store.js +147 -0
  1490. package/dist/storage/convex/exec-approval-store.js.map +1 -0
  1491. package/dist/storage/convex/extension-store.d.ts +28 -0
  1492. package/dist/storage/convex/extension-store.d.ts.map +1 -0
  1493. package/dist/storage/convex/extension-store.js +39 -0
  1494. package/dist/storage/convex/extension-store.js.map +1 -0
  1495. package/dist/storage/convex/index.d.ts +35 -0
  1496. package/dist/storage/convex/index.d.ts.map +1 -0
  1497. package/dist/storage/convex/index.js +141 -0
  1498. package/dist/storage/convex/index.js.map +1 -0
  1499. package/dist/storage/convex/instance-store.d.ts +37 -0
  1500. package/dist/storage/convex/instance-store.d.ts.map +1 -0
  1501. package/dist/storage/convex/instance-store.js +88 -0
  1502. package/dist/storage/convex/instance-store.js.map +1 -0
  1503. package/dist/storage/convex/log-store.d.ts +36 -0
  1504. package/dist/storage/convex/log-store.d.ts.map +1 -0
  1505. package/dist/storage/convex/log-store.js +213 -0
  1506. package/dist/storage/convex/log-store.js.map +1 -0
  1507. package/dist/storage/convex/memory-store.d.ts +50 -0
  1508. package/dist/storage/convex/memory-store.d.ts.map +1 -0
  1509. package/dist/storage/convex/memory-store.js +537 -0
  1510. package/dist/storage/convex/memory-store.js.map +1 -0
  1511. package/dist/storage/convex/message-store.d.ts +32 -0
  1512. package/dist/storage/convex/message-store.d.ts.map +1 -0
  1513. package/dist/storage/convex/message-store.js +272 -0
  1514. package/dist/storage/convex/message-store.js.map +1 -0
  1515. package/dist/storage/convex/org-store.d.ts +46 -0
  1516. package/dist/storage/convex/org-store.d.ts.map +1 -0
  1517. package/dist/storage/convex/org-store.js +101 -0
  1518. package/dist/storage/convex/org-store.js.map +1 -0
  1519. package/dist/storage/convex/session-store.d.ts +44 -0
  1520. package/dist/storage/convex/session-store.d.ts.map +1 -0
  1521. package/dist/storage/convex/session-store.js +257 -0
  1522. package/dist/storage/convex/session-store.js.map +1 -0
  1523. package/dist/storage/convex/skill-store.d.ts +49 -0
  1524. package/dist/storage/convex/skill-store.d.ts.map +1 -0
  1525. package/dist/storage/convex/skill-store.js +84 -0
  1526. package/dist/storage/convex/skill-store.js.map +1 -0
  1527. package/dist/storage/convex/subagent-store.d.ts +28 -0
  1528. package/dist/storage/convex/subagent-store.d.ts.map +1 -0
  1529. package/dist/storage/convex/subagent-store.js +83 -0
  1530. package/dist/storage/convex/subagent-store.js.map +1 -0
  1531. package/dist/storage/convex/workspace-store.d.ts +25 -0
  1532. package/dist/storage/convex/workspace-store.d.ts.map +1 -0
  1533. package/dist/storage/convex/workspace-store.js +127 -0
  1534. package/dist/storage/convex/workspace-store.js.map +1 -0
  1535. package/dist/storage/cron-cache.d.ts +17 -0
  1536. package/dist/storage/cron-cache.d.ts.map +1 -0
  1537. package/dist/storage/cron-cache.js +67 -0
  1538. package/dist/storage/cron-cache.js.map +1 -0
  1539. package/dist/storage/encryption.d.ts +69 -0
  1540. package/dist/storage/encryption.d.ts.map +1 -0
  1541. package/dist/storage/encryption.js +389 -0
  1542. package/dist/storage/encryption.js.map +1 -0
  1543. package/dist/storage/factory-reset.d.ts +7 -0
  1544. package/dist/storage/factory-reset.d.ts.map +1 -0
  1545. package/dist/storage/factory-reset.js +34 -0
  1546. package/dist/storage/factory-reset.js.map +1 -0
  1547. package/dist/storage/facts-cache.d.ts +24 -0
  1548. package/dist/storage/facts-cache.d.ts.map +1 -0
  1549. package/dist/storage/facts-cache.js +110 -0
  1550. package/dist/storage/facts-cache.js.map +1 -0
  1551. package/dist/storage/flush.d.ts +4 -0
  1552. package/dist/storage/flush.d.ts.map +1 -0
  1553. package/dist/storage/flush.js +128 -0
  1554. package/dist/storage/flush.js.map +1 -0
  1555. package/dist/storage/instance-admin.d.ts +52 -0
  1556. package/dist/storage/instance-admin.d.ts.map +1 -0
  1557. package/dist/storage/instance-admin.js +90 -0
  1558. package/dist/storage/instance-admin.js.map +1 -0
  1559. package/dist/storage/local/auth-store.d.ts +44 -0
  1560. package/dist/storage/local/auth-store.d.ts.map +1 -0
  1561. package/dist/storage/local/auth-store.js +252 -0
  1562. package/dist/storage/local/auth-store.js.map +1 -0
  1563. package/dist/storage/local/blob-store.d.ts +14 -0
  1564. package/dist/storage/local/blob-store.d.ts.map +1 -0
  1565. package/dist/storage/local/blob-store.js +87 -0
  1566. package/dist/storage/local/blob-store.js.map +1 -0
  1567. package/dist/storage/local/channel-store.d.ts +107 -0
  1568. package/dist/storage/local/channel-store.d.ts.map +1 -0
  1569. package/dist/storage/local/channel-store.js +147 -0
  1570. package/dist/storage/local/channel-store.js.map +1 -0
  1571. package/dist/storage/local/config-store.d.ts +23 -0
  1572. package/dist/storage/local/config-store.d.ts.map +1 -0
  1573. package/dist/storage/local/config-store.js +98 -0
  1574. package/dist/storage/local/config-store.js.map +1 -0
  1575. package/dist/storage/local/cron-store.d.ts +30 -0
  1576. package/dist/storage/local/cron-store.d.ts.map +1 -0
  1577. package/dist/storage/local/cron-store.js +186 -0
  1578. package/dist/storage/local/cron-store.js.map +1 -0
  1579. package/dist/storage/local/exec-approval-store.d.ts +41 -0
  1580. package/dist/storage/local/exec-approval-store.d.ts.map +1 -0
  1581. package/dist/storage/local/exec-approval-store.js +78 -0
  1582. package/dist/storage/local/exec-approval-store.js.map +1 -0
  1583. package/dist/storage/local/extension-store.d.ts +13 -0
  1584. package/dist/storage/local/extension-store.d.ts.map +1 -0
  1585. package/dist/storage/local/extension-store.js +36 -0
  1586. package/dist/storage/local/extension-store.js.map +1 -0
  1587. package/dist/storage/local/file-watcher.d.ts +24 -0
  1588. package/dist/storage/local/file-watcher.d.ts.map +1 -0
  1589. package/dist/storage/local/file-watcher.js +141 -0
  1590. package/dist/storage/local/file-watcher.js.map +1 -0
  1591. package/dist/storage/local/index.d.ts +33 -0
  1592. package/dist/storage/local/index.d.ts.map +1 -0
  1593. package/dist/storage/local/index.js +143 -0
  1594. package/dist/storage/local/index.js.map +1 -0
  1595. package/dist/storage/local/instance-store.d.ts +30 -0
  1596. package/dist/storage/local/instance-store.d.ts.map +1 -0
  1597. package/dist/storage/local/instance-store.js +83 -0
  1598. package/dist/storage/local/instance-store.js.map +1 -0
  1599. package/dist/storage/local/log-store.d.ts +27 -0
  1600. package/dist/storage/local/log-store.d.ts.map +1 -0
  1601. package/dist/storage/local/log-store.js +185 -0
  1602. package/dist/storage/local/log-store.js.map +1 -0
  1603. package/dist/storage/local/memory-store.d.ts +39 -0
  1604. package/dist/storage/local/memory-store.d.ts.map +1 -0
  1605. package/dist/storage/local/memory-store.js +258 -0
  1606. package/dist/storage/local/memory-store.js.map +1 -0
  1607. package/dist/storage/local/message-store.d.ts +27 -0
  1608. package/dist/storage/local/message-store.d.ts.map +1 -0
  1609. package/dist/storage/local/message-store.js +253 -0
  1610. package/dist/storage/local/message-store.js.map +1 -0
  1611. package/dist/storage/local/org-store.d.ts +39 -0
  1612. package/dist/storage/local/org-store.d.ts.map +1 -0
  1613. package/dist/storage/local/org-store.js +155 -0
  1614. package/dist/storage/local/org-store.js.map +1 -0
  1615. package/dist/storage/local/session-store.d.ts +30 -0
  1616. package/dist/storage/local/session-store.d.ts.map +1 -0
  1617. package/dist/storage/local/session-store.js +82 -0
  1618. package/dist/storage/local/session-store.js.map +1 -0
  1619. package/dist/storage/local/skill-store.d.ts +40 -0
  1620. package/dist/storage/local/skill-store.d.ts.map +1 -0
  1621. package/dist/storage/local/skill-store.js +121 -0
  1622. package/dist/storage/local/skill-store.js.map +1 -0
  1623. package/dist/storage/local/subagent-store.d.ts +20 -0
  1624. package/dist/storage/local/subagent-store.d.ts.map +1 -0
  1625. package/dist/storage/local/subagent-store.js +71 -0
  1626. package/dist/storage/local/subagent-store.js.map +1 -0
  1627. package/dist/storage/local/workspace-store.d.ts +22 -0
  1628. package/dist/storage/local/workspace-store.d.ts.map +1 -0
  1629. package/dist/storage/local/workspace-store.js +190 -0
  1630. package/dist/storage/local/workspace-store.js.map +1 -0
  1631. package/dist/storage/migrate.d.ts +64 -0
  1632. package/dist/storage/migrate.d.ts.map +1 -0
  1633. package/dist/storage/migrate.js +581 -0
  1634. package/dist/storage/migrate.js.map +1 -0
  1635. package/dist/storage/runtime-context.d.ts +35 -0
  1636. package/dist/storage/runtime-context.d.ts.map +1 -0
  1637. package/dist/storage/runtime-context.js +145 -0
  1638. package/dist/storage/runtime-context.js.map +1 -0
  1639. package/dist/storage/sentinel.d.ts +28 -0
  1640. package/dist/storage/sentinel.d.ts.map +1 -0
  1641. package/dist/storage/sentinel.js +98 -0
  1642. package/dist/storage/sentinel.js.map +1 -0
  1643. package/dist/storage/session-cache.d.ts +15 -0
  1644. package/dist/storage/session-cache.d.ts.map +1 -0
  1645. package/dist/storage/session-cache.js +81 -0
  1646. package/dist/storage/session-cache.js.map +1 -0
  1647. package/dist/storage/store.d.ts +745 -0
  1648. package/dist/storage/store.d.ts.map +1 -0
  1649. package/dist/storage/store.js +36 -0
  1650. package/dist/storage/store.js.map +1 -0
  1651. package/dist/storage/strict-guard.d.ts +17 -0
  1652. package/dist/storage/strict-guard.d.ts.map +1 -0
  1653. package/dist/storage/strict-guard.js +200 -0
  1654. package/dist/storage/strict-guard.js.map +1 -0
  1655. package/dist/storage/workspace-live-mirror.d.ts +33 -0
  1656. package/dist/storage/workspace-live-mirror.d.ts.map +1 -0
  1657. package/dist/storage/workspace-live-mirror.js +207 -0
  1658. package/dist/storage/workspace-live-mirror.js.map +1 -0
  1659. package/dist/system-prompt/assembler.d.ts +113 -0
  1660. package/dist/system-prompt/assembler.d.ts.map +1 -0
  1661. package/dist/system-prompt/assembler.js +649 -0
  1662. package/dist/system-prompt/assembler.js.map +1 -0
  1663. package/dist/system-prompt/bootstrap-budget.d.ts +22 -0
  1664. package/dist/system-prompt/bootstrap-budget.d.ts.map +1 -0
  1665. package/dist/system-prompt/bootstrap-budget.js +83 -0
  1666. package/dist/system-prompt/bootstrap-budget.js.map +1 -0
  1667. package/dist/system-prompt/cache-boundary.d.ts +13 -0
  1668. package/dist/system-prompt/cache-boundary.d.ts.map +1 -0
  1669. package/dist/system-prompt/cache-boundary.js +56 -0
  1670. package/dist/system-prompt/cache-boundary.js.map +1 -0
  1671. package/dist/system-prompt/cache-stability.d.ts +3 -0
  1672. package/dist/system-prompt/cache-stability.d.ts.map +1 -0
  1673. package/dist/system-prompt/cache-stability.js +18 -0
  1674. package/dist/system-prompt/cache-stability.js.map +1 -0
  1675. package/dist/system-prompt/guidance.d.ts +147 -0
  1676. package/dist/system-prompt/guidance.d.ts.map +1 -0
  1677. package/dist/system-prompt/guidance.js +352 -0
  1678. package/dist/system-prompt/guidance.js.map +1 -0
  1679. package/dist/system-prompt/identity-defaults.d.ts +50 -0
  1680. package/dist/system-prompt/identity-defaults.d.ts.map +1 -0
  1681. package/dist/system-prompt/identity-defaults.js +119 -0
  1682. package/dist/system-prompt/identity-defaults.js.map +1 -0
  1683. package/dist/system-prompt/org/escalation-inbox.d.ts +53 -0
  1684. package/dist/system-prompt/org/escalation-inbox.d.ts.map +1 -0
  1685. package/dist/system-prompt/org/escalation-inbox.js +71 -0
  1686. package/dist/system-prompt/org/escalation-inbox.js.map +1 -0
  1687. package/dist/system-prompt/org/receiver-hint.d.ts +72 -0
  1688. package/dist/system-prompt/org/receiver-hint.d.ts.map +1 -0
  1689. package/dist/system-prompt/org/receiver-hint.js +116 -0
  1690. package/dist/system-prompt/org/receiver-hint.js.map +1 -0
  1691. package/dist/system-prompt/org/render-org-block.d.ts +42 -0
  1692. package/dist/system-prompt/org/render-org-block.d.ts.map +1 -0
  1693. package/dist/system-prompt/org/render-org-block.js +57 -0
  1694. package/dist/system-prompt/org/render-org-block.js.map +1 -0
  1695. package/dist/system-prompt/org/sub-agent-anchor.d.ts +30 -0
  1696. package/dist/system-prompt/org/sub-agent-anchor.d.ts.map +1 -0
  1697. package/dist/system-prompt/org/sub-agent-anchor.js +36 -0
  1698. package/dist/system-prompt/org/sub-agent-anchor.js.map +1 -0
  1699. package/dist/system-prompt/override.d.ts +7 -0
  1700. package/dist/system-prompt/override.d.ts.map +1 -0
  1701. package/dist/system-prompt/override.js +13 -0
  1702. package/dist/system-prompt/override.js.map +1 -0
  1703. package/dist/system-prompt/pi-injection.d.ts +5 -0
  1704. package/dist/system-prompt/pi-injection.d.ts.map +1 -0
  1705. package/dist/system-prompt/pi-injection.js +33 -0
  1706. package/dist/system-prompt/pi-injection.js.map +1 -0
  1707. package/dist/system-prompt/runtime-params.d.ts +34 -0
  1708. package/dist/system-prompt/runtime-params.d.ts.map +1 -0
  1709. package/dist/system-prompt/runtime-params.js +108 -0
  1710. package/dist/system-prompt/runtime-params.js.map +1 -0
  1711. package/dist/system-prompt/sanitize.d.ts +7 -0
  1712. package/dist/system-prompt/sanitize.d.ts.map +1 -0
  1713. package/dist/system-prompt/sanitize.js +31 -0
  1714. package/dist/system-prompt/sanitize.js.map +1 -0
  1715. package/dist/system-prompt/types.d.ts +7 -0
  1716. package/dist/system-prompt/types.d.ts.map +1 -0
  1717. package/dist/system-prompt/types.js +3 -0
  1718. package/dist/system-prompt/types.js.map +1 -0
  1719. package/dist/system-prompt/workspace-loader.d.ts +12 -0
  1720. package/dist/system-prompt/workspace-loader.d.ts.map +1 -0
  1721. package/dist/system-prompt/workspace-loader.js +115 -0
  1722. package/dist/system-prompt/workspace-loader.js.map +1 -0
  1723. package/dist/tideline/advanced.d.ts +25 -0
  1724. package/dist/tideline/advanced.d.ts.map +1 -0
  1725. package/dist/tideline/advanced.js +34 -0
  1726. package/dist/tideline/advanced.js.map +1 -0
  1727. package/dist/tideline/eval.d.ts +19 -0
  1728. package/dist/tideline/eval.d.ts.map +1 -0
  1729. package/dist/tideline/eval.js +24 -0
  1730. package/dist/tideline/eval.js.map +1 -0
  1731. package/dist/tideline/host-ports.standalone.d.ts +49 -0
  1732. package/dist/tideline/host-ports.standalone.d.ts.map +1 -0
  1733. package/dist/tideline/host-ports.standalone.js +61 -0
  1734. package/dist/tideline/host-ports.standalone.js.map +1 -0
  1735. package/dist/tideline/index.d.ts +34 -0
  1736. package/dist/tideline/index.d.ts.map +1 -0
  1737. package/dist/tideline/index.js +42 -0
  1738. package/dist/tideline/index.js.map +1 -0
  1739. package/dist/tui/approval-prompt.d.ts +73 -0
  1740. package/dist/tui/approval-prompt.d.ts.map +1 -0
  1741. package/dist/tui/approval-prompt.js +272 -0
  1742. package/dist/tui/approval-prompt.js.map +1 -0
  1743. package/dist/tui/client.d.ts +89 -0
  1744. package/dist/tui/client.d.ts.map +1 -0
  1745. package/dist/tui/client.js.map +1 -0
  1746. package/dist/ui/brand-frames-cli.d.ts +19 -0
  1747. package/dist/ui/brand-frames-cli.d.ts.map +1 -0
  1748. package/dist/ui/brand-frames-cli.js +8 -13
  1749. package/dist/ui/brand-frames-cli.js.map +1 -0
  1750. package/dist/ui/brand.d.ts +41 -0
  1751. package/dist/ui/brand.d.ts.map +1 -0
  1752. package/dist/ui/brand.js +28 -6
  1753. package/dist/ui/brand.js.map +1 -0
  1754. package/dist/ui/editor.d.ts +30 -0
  1755. package/dist/ui/editor.d.ts.map +1 -0
  1756. package/dist/ui/editor.js +73 -0
  1757. package/dist/ui/editor.js.map +1 -0
  1758. package/dist/ui/format-session.d.ts +68 -0
  1759. package/dist/ui/format-session.d.ts.map +1 -0
  1760. package/dist/ui/format-session.js +181 -0
  1761. package/dist/ui/format-session.js.map +1 -0
  1762. package/dist/ui/markdown.d.ts +48 -0
  1763. package/dist/ui/markdown.d.ts.map +1 -0
  1764. package/dist/ui/markdown.js +60 -0
  1765. package/dist/ui/markdown.js.map +1 -0
  1766. package/dist/ui/onboard-storage-mode.d.ts +17 -0
  1767. package/dist/ui/onboard-storage-mode.d.ts.map +1 -0
  1768. package/dist/ui/onboard-storage-mode.js +638 -0
  1769. package/dist/ui/onboard-storage-mode.js.map +1 -0
  1770. package/dist/ui/onboarding.d.ts +97 -0
  1771. package/dist/ui/onboarding.d.ts.map +1 -0
  1772. package/dist/ui/onboarding.js +259 -111
  1773. package/dist/ui/onboarding.js.map +1 -0
  1774. package/dist/ui/searchable-select.d.ts +48 -0
  1775. package/dist/ui/searchable-select.d.ts.map +1 -0
  1776. package/dist/ui/searchable-select.js +108 -0
  1777. package/dist/ui/searchable-select.js.map +1 -0
  1778. package/dist/ui/syntax-theme.d.ts +30 -0
  1779. package/dist/ui/syntax-theme.d.ts.map +1 -0
  1780. package/dist/ui/syntax-theme.js +72 -0
  1781. package/dist/ui/syntax-theme.js.map +1 -0
  1782. package/dist/ui/terminal-cleanup.d.ts +46 -0
  1783. package/dist/ui/terminal-cleanup.d.ts.map +1 -0
  1784. package/dist/ui/terminal-cleanup.js +17 -5
  1785. package/dist/ui/terminal-cleanup.js.map +1 -0
  1786. package/dist/ui/theme.d.ts +21 -0
  1787. package/dist/ui/theme.d.ts.map +1 -0
  1788. package/dist/ui/theme.js +66 -2
  1789. package/dist/ui/theme.js.map +1 -0
  1790. package/dist/ui/tool-result.d.ts +47 -0
  1791. package/dist/ui/tool-result.d.ts.map +1 -0
  1792. package/dist/ui/tool-result.js +100 -0
  1793. package/dist/ui/tool-result.js.map +1 -0
  1794. package/dist/utils/delivery-context.d.ts +50 -0
  1795. package/dist/utils/delivery-context.d.ts.map +1 -0
  1796. package/dist/utils/delivery-context.js +82 -0
  1797. package/dist/utils/delivery-context.js.map +1 -0
  1798. package/dist/utils/message-channel.d.ts +60 -0
  1799. package/dist/utils/message-channel.d.ts.map +1 -0
  1800. package/dist/utils/message-channel.js +103 -0
  1801. package/dist/utils/message-channel.js.map +1 -0
  1802. package/dist/utils/string-coerce.d.ts +50 -0
  1803. package/dist/utils/string-coerce.d.ts.map +1 -0
  1804. package/dist/utils/string-coerce.js +101 -0
  1805. package/dist/utils/string-coerce.js.map +1 -0
  1806. package/dist/version.d.ts +20 -0
  1807. package/dist/version.d.ts.map +1 -0
  1808. package/dist/version.js +54 -0
  1809. package/dist/version.js.map +1 -0
  1810. package/dist/workspace/bootstrap.d.ts +12 -0
  1811. package/dist/workspace/bootstrap.d.ts.map +1 -0
  1812. package/dist/workspace/bootstrap.js +123 -0
  1813. package/dist/workspace/bootstrap.js.map +1 -0
  1814. package/dist/workspace/fs-utils.d.ts +2 -0
  1815. package/dist/workspace/fs-utils.d.ts.map +1 -0
  1816. package/dist/workspace/fs-utils.js +14 -0
  1817. package/dist/workspace/fs-utils.js.map +1 -0
  1818. package/dist/workspace/git-init.d.ts +5 -0
  1819. package/dist/workspace/git-init.d.ts.map +1 -0
  1820. package/dist/workspace/git-init.js +71 -0
  1821. package/dist/workspace/git-init.js.map +1 -0
  1822. package/dist/workspace/state.d.ts +13 -0
  1823. package/dist/workspace/state.d.ts.map +1 -0
  1824. package/dist/workspace/state.js +128 -0
  1825. package/dist/workspace/state.js.map +1 -0
  1826. package/dist/workspace/template-loader.d.ts +15 -0
  1827. package/dist/workspace/template-loader.d.ts.map +1 -0
  1828. package/dist/workspace/template-loader.js +214 -0
  1829. package/dist/workspace/template-loader.js.map +1 -0
  1830. package/package.json +173 -68
  1831. package/scripts/build-done.mjs +125 -0
  1832. package/scripts/run-brigade.mjs +208 -0
  1833. package/skills/1password/SKILL.md +70 -0
  1834. package/skills/1password/references/cli-examples.md +29 -0
  1835. package/skills/1password/references/get-started.md +17 -0
  1836. package/skills/apple-notes/SKILL.md +77 -0
  1837. package/skills/apple-reminders/SKILL.md +118 -0
  1838. package/skills/bear-notes/SKILL.md +107 -0
  1839. package/skills/blogwatcher/SKILL.md +69 -0
  1840. package/skills/blucli/SKILL.md +47 -0
  1841. package/skills/bluebubbles/SKILL.md +136 -0
  1842. package/skills/camsnap/SKILL.md +45 -0
  1843. package/skills/canvas/SKILL.md +204 -0
  1844. package/skills/coding-agent/SKILL.md +316 -0
  1845. package/skills/discord/SKILL.md +197 -0
  1846. package/skills/eightctl/SKILL.md +50 -0
  1847. package/skills/gemini/SKILL.md +43 -0
  1848. package/skills/gh-issues/SKILL.md +885 -0
  1849. package/skills/gifgrep/SKILL.md +79 -0
  1850. package/skills/git-commit/SKILL.md +40 -0
  1851. package/skills/github/SKILL.md +163 -0
  1852. package/skills/gog/SKILL.md +116 -0
  1853. package/skills/goplaces/SKILL.md +52 -0
  1854. package/skills/healthcheck/SKILL.md +245 -0
  1855. package/skills/himalaya/SKILL.md +257 -0
  1856. package/skills/himalaya/references/configuration.md +184 -0
  1857. package/skills/himalaya/references/message-composition.md +199 -0
  1858. package/skills/imsg/SKILL.md +122 -0
  1859. package/skills/lead-scout/SKILL.md +46 -0
  1860. package/skills/mcporter/SKILL.md +61 -0
  1861. package/skills/model-usage/SKILL.md +69 -0
  1862. package/skills/nano-pdf/SKILL.md +38 -0
  1863. package/skills/node-connect/SKILL.md +142 -0
  1864. package/skills/notion/SKILL.md +174 -0
  1865. package/skills/oauth-setup/SKILL.md +55 -0
  1866. package/skills/obsidian/SKILL.md +81 -0
  1867. package/skills/openai-whisper/SKILL.md +38 -0
  1868. package/skills/openai-whisper-api/SKILL.md +62 -0
  1869. package/skills/openai-whisper-api/scripts/transcribe.sh +88 -0
  1870. package/skills/openhue/SKILL.md +112 -0
  1871. package/skills/oracle/SKILL.md +125 -0
  1872. package/skills/ordercli/SKILL.md +78 -0
  1873. package/skills/peekaboo/SKILL.md +190 -0
  1874. package/skills/sag/SKILL.md +87 -0
  1875. package/skills/session-logs/SKILL.md +151 -0
  1876. package/skills/share-skills/SKILL.md +72 -0
  1877. package/skills/sherpa-onnx-tts/SKILL.md +109 -0
  1878. package/skills/sherpa-onnx-tts/bin/sherpa-onnx-tts +178 -0
  1879. package/skills/skill-creator/SKILL.md +372 -0
  1880. package/skills/skill-creator/license.txt +202 -0
  1881. package/skills/skill-creator/scripts/init_skill.py +378 -0
  1882. package/skills/skill-creator/scripts/package_skill.py +139 -0
  1883. package/skills/skill-creator/scripts/quick_validate.py +159 -0
  1884. package/skills/skill-creator/scripts/test_package_skill.py +160 -0
  1885. package/skills/skill-creator/scripts/test_quick_validate.py +72 -0
  1886. package/skills/slack/SKILL.md +144 -0
  1887. package/skills/songsee/SKILL.md +49 -0
  1888. package/skills/sonoscli/SKILL.md +65 -0
  1889. package/skills/spotify-player/SKILL.md +64 -0
  1890. package/skills/summarize/SKILL.md +87 -0
  1891. package/skills/taskflow/SKILL.md +149 -0
  1892. package/skills/taskflow-inbox-triage/SKILL.md +119 -0
  1893. package/skills/things-mac/SKILL.md +86 -0
  1894. package/skills/tmux/SKILL.md +170 -0
  1895. package/skills/tmux/scripts/find-sessions.sh +112 -0
  1896. package/skills/tmux/scripts/wait-for-text.sh +83 -0
  1897. package/skills/trello/SKILL.md +108 -0
  1898. package/skills/video-frames/SKILL.md +46 -0
  1899. package/skills/video-frames/scripts/frame.sh +81 -0
  1900. package/skills/voice-call/SKILL.md +45 -0
  1901. package/skills/wacli/SKILL.md +72 -0
  1902. package/skills/weather/SKILL.md +129 -0
  1903. package/skills/xurl/SKILL.md +461 -0
  1904. package/templates/workspace/AGENTS.md +223 -0
  1905. package/templates/workspace/BOOTSTRAP.md +64 -0
  1906. package/templates/workspace/HEARTBEAT.md +15 -0
  1907. package/templates/workspace/IDENTITY.md +31 -0
  1908. package/templates/workspace/SOUL.md +47 -0
  1909. package/templates/workspace/TOOLS.md +48 -0
  1910. package/templates/workspace/USER.md +25 -0
  1911. package/CHANGELOG.md +0 -41
  1912. package/SECURITY.md +0 -208
  1913. package/assets/brigade-wordmark.png +0 -0
  1914. package/dist/cli/chat-cmd.js +0 -191
  1915. package/dist/cli/config-cmd.js +0 -171
  1916. package/dist/cli/connect-cmd.js +0 -487
  1917. package/dist/cli/doctor-cmd.js +0 -387
  1918. package/dist/cli/gateway-cmd.js +0 -155
  1919. package/dist/cli.js +0 -328
  1920. package/dist/core/agent.js +0 -1123
  1921. package/dist/core/auth-label.js +0 -147
  1922. package/dist/core/cli-error.js +0 -94
  1923. package/dist/core/error-classifier.js +0 -354
  1924. package/dist/core/provider-payload-mutators.js +0 -517
  1925. package/dist/core/provider-quirks.js +0 -285
  1926. package/dist/core/smart-compaction.js +0 -209
  1927. package/dist/core/system-prompt-defaults.js +0 -264
  1928. package/dist/core/system-prompt-guidance.js +0 -271
  1929. package/dist/index.js +0 -32
  1930. package/dist/ui/brand-frames.js +0 -36
  1931. package/dist/ui/chat.js +0 -1008
@@ -0,0 +1 @@
1
+ {"version":3,"file":"decay.js","sourceRoot":"","sources":["../../../src/agents/memory/decay.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;AAEH,OAAO,EAAE,SAAS,EAAqB,MAAM,cAAc,CAAC;AAE5D,MAAM,MAAM,GAAG,UAAU,CAAC;AAC1B,uDAAuD;AACvD,MAAM,mBAAmB,GAAG,KAAK,CAAC;AAClC,MAAM,UAAU,GAAG,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M,GAAG,SAAS,CAAC,MAAM;KACvD,CAAC;AACH,CAAC"}
@@ -0,0 +1,52 @@
1
+ import { FactStore, type MemoryStatus, type RecordOriginFilter } from "./records.js";
2
+ export interface DreamOpts {
3
+ /** Reflect over just this principal's facts (default: every origin). */
4
+ origin?: RecordOriginFilter;
5
+ /** Assertions (accessCount + 1) needed to confirm a belief. Default 3. */
6
+ confirmCount?: number;
7
+ /** Confidence to stamp on a confirmed belief. Default 0.9. */
8
+ confirmConfidence?: number;
9
+ /** Cosine bar for merging near-identical duplicates. Default 0.95. */
10
+ consolidateThreshold?: number;
11
+ /** Cosine bar for persisting a generic `relates` edge between two facts that are
12
+ * related but NOT merged (the synonymy band below the merge bar — Step 19). Default
13
+ * 0.8. Must be < consolidateThreshold. Set to 1 to disable relatedness linking. */
14
+ relatesThreshold?: number;
15
+ /** effectiveScore floor below which a fact is eligible for eviction. Default 0.05. */
16
+ evictBelowScore?: number;
17
+ /** Only evict facts older than this (ms). Default 30 days. */
18
+ evictMinAgeMs?: number;
19
+ /** Injectable wall-clock (epoch ms). Defaults to `Date.now()`. Pin in tests
20
+ * to make the pass fully deterministic (same value flows to every effectiveScore
21
+ * call and the evict age gate). The curator always passes `now` so all
22
+ * per-origin passes share one pinned instant. */
23
+ now?: number;
24
+ }
25
+ export interface DreamResult {
26
+ /** How many active facts were examined. */
27
+ reflected: number;
28
+ /** Beliefs promoted to confirmed (with the prior values, for reversal). */
29
+ confirmed: Array<{
30
+ memoryId: string;
31
+ prior: {
32
+ confidence?: number;
33
+ status?: MemoryStatus;
34
+ importance?: number;
35
+ };
36
+ }>;
37
+ /** Near-identical merges: keeper ← duplicate. */
38
+ consolidated: Array<{
39
+ kept: string;
40
+ merged: string;
41
+ }>;
42
+ /** Archived (decayed) ids. */
43
+ evicted: string[];
44
+ /** New `relates` association edges persisted this pass (Step 19 synonymy links). */
45
+ related: number;
46
+ }
47
+ /**
48
+ * Run one dream pass over `store`. Pass `origin` to scope it to a single
49
+ * principal (the cron fans this out per-origin). Returns what it changed.
50
+ */
51
+ export declare function runDream(store: FactStore, opts?: DreamOpts): DreamResult;
52
+ //# sourceMappingURL=dream.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"dream.d.ts","sourceRoot":"","sources":["../../../src/agents/memory/dream.ts"],"names":[],"mappings":"AAwBA,OAAO,EAEN,SAAS,EAIT,KAAK,YAAY,EACjB,KAAK,kBAAkB,EACvB,MAAM,cAAc,CAAC;AAKtB,MAAM,WAAW,SAAS;IACzB,wEAAwE;IACxE,MAAM,CAAC,EAAE,kBAAkB,CAAC;IAC5B,0EAA0E;IAC1E,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,8DAA8D;IAC9D,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAC3B,sEAAsE;IACtE,oBAAoB,CAAC,EAAE,MAAM,CAAC;IAC9B;;wFAEoF;IACpF,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAC1B,sFAAsF;IACtF,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,8DAA8D;IAC9D,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB;;;sDAGkD;IAClD,GAAG,CAAC,EAAE,MAAM,CAAC;CACb;AAED,MAAM,WAAW,WAAW;IAC3B,2CAA2C;IAC3C,SAAS,EAAE,MAAM,CAAC;IAClB,2EAA2E;IAC3E,SAAS,EAAE,KAAK,CAAC;QAAE,QAAQ,EAAE,MAAM,CAAC;QAAC,KAAK,EAAE;YAAE,UAAU,CAAC,EAAE,MAAM,CAAC;YAAC,MAAM,CAAC,EAAE,YAAY,CAAC;YAAC,UAAU,CAAC,EAAE,MAAM,CAAA;SAAE,CAAA;KAAE,CAAC,CAAC;IACnH,iDAAiD;IACjD,YAAY,EAAE,KAAK,CAAC;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,MAAM,EAAE,MAAM,CAAA;KAAE,CAAC,CAAC;IACtD,8BAA8B;IAC9B,OAAO,EAAE,MAAM,EAAE,CAAC;IAClB,oFAAoF;IACpF,OAAO,EAAE,MAAM,CAAC;CAChB;AAED;;;GAGG;AACH,wBAAgB,QAAQ,CAAC,KAAK,EAAE,SAAS,EAAE,IAAI,GAAE,SAAc,GAAG,WAAW,CA2J5E"}
@@ -0,0 +1,192 @@
1
+ // src/agents/memory/dream.ts
2
+ //
3
+ // Tideline Step 22 — the nightly dream (Lane A reflection, per-origin).
4
+ //
5
+ // A periodic, deterministic reflection over an origin's facts that lets memory
6
+ // AUTO-EVOLVE — Lane A is reversible and changes NO agent behaviour:
7
+ // • CONFIRM — a belief asserted/reinforced ≥ N times (a "3× repeated
8
+ // correction") is promoted to a CONFIRMED preference
9
+ // (status="confirmed" + confidence ↑). The marquee outcome.
10
+ // • CONSOLIDATE— near-identical active facts (embedding cosine ≥ a high bar)
11
+ // are merged: the stronger keeper bi-temporally supersedes the
12
+ // duplicate. Per-origin only (the candidate set is origin-
13
+ // filtered first), so it never crosses principals.
14
+ // • EVICT — active facts whose effectiveScore has decayed below a floor
15
+ // (old enough, NOT confirmed) are archived.
16
+ //
17
+ // REVERSIBLE: confirms log their `prior` (a future pass / the operator restores
18
+ // it); consolidations + evictions ARCHIVE, never delete. The "reflection with
19
+ // citations" + an NLI confirm are SEAMS — an LLM adapter can gate/justify each
20
+ // promotion; the v1 default is the deterministic rules above so it runs offline
21
+ // on a cron with zero model cost.
22
+ import { effectiveScore } from "./decay.js";
23
+ import { synonymyEdges } from "./graph.js";
24
+ import { compareRichness, originBucketKey, recordMatchesOriginFilter, } from "./records.js";
25
+ import { isTrustedTarget } from "./write-gate.js";
26
+ const DAY_MS = 86_400_000;
27
+ /**
28
+ * Run one dream pass over `store`. Pass `origin` to scope it to a single
29
+ * principal (the cron fans this out per-origin). Returns what it changed.
30
+ */
31
+ export function runDream(store, opts = {}) {
32
+ const now = opts.now ?? Date.now();
33
+ const confirmCount = opts.confirmCount ?? 3;
34
+ const confirmConfidence = opts.confirmConfidence ?? 0.9;
35
+ const consolidateThreshold = opts.consolidateThreshold ?? 0.95;
36
+ const relatesThreshold = opts.relatesThreshold ?? 0.8;
37
+ const evictBelow = opts.evictBelowScore ?? 0.05;
38
+ const evictMinAge = opts.evictMinAgeMs ?? 30 * DAY_MS;
39
+ const inOrigin = (r) => !opts.origin || recordMatchesOriginFilter(r, opts.origin);
40
+ const activeNow = () => store.list({ limit: 100_000 }).filter(inOrigin);
41
+ let active = activeNow();
42
+ const result = { reflected: active.length, confirmed: [], consolidated: [], evicted: [], related: 0 };
43
+ // ── CONFIRM: a subjectKey belief is confirmed when EITHER the same value was
44
+ // asserted/reinforced ≥ confirmCount (assertions = accessCount + 1), OR the
45
+ // subject was CORRECTED ≥ confirmCount times (archived same-subject,
46
+ // same-origin predecessors). So both "said X three times" and "revised the
47
+ // value over three corrections, now settled" promote the current belief.
48
+ // GENUINE same-slot user corrections only. A write-time supersede stamps the
49
+ // SUPERSEDER with contradicts/transition edges at the prior it replaced, and the
50
+ // write path only supersedes priors sharing its subjectKey AND origin — so a
51
+ // genuine correction is an edge whose source occupies the SAME [origin, subjectKey]
52
+ // slot as its archived target (true even mid-chain: each link in M←T←W←Th joins two
53
+ // same-slot values, and an earlier superseder may itself be archived by a later one).
54
+ // Pure decay/eviction archive WITHOUT any such edge. Consolidation DOES add
55
+ // contradicts/transition edges (it archives via invalidate(... supersededBy ...)),
56
+ // but it merges embedding near-duplicates that generally DON'T share a subjectKey/
57
+ // slot — so the same-slot requirement structurally excludes a system merge that
58
+ // would otherwise inflate the count and falsely CONFIRM a belief whose slot merely
59
+ // churned (status="confirmed", confidence ↑, eviction-immune) off a system-initiated,
60
+ // not user-driven, change.
61
+ const recordById = new Map(store.readAll().map((r) => [r.memoryId, r]));
62
+ const slotOf = (r) => JSON.stringify([originBucketKey(r), r.subjectKey]);
63
+ const supersededTargets = new Set();
64
+ for (const a of store.readAll()) {
65
+ if (!a.subjectKey)
66
+ continue;
67
+ const srcSlot = slotOf(a);
68
+ for (const l of a.links ?? []) {
69
+ if (l.kind !== "contradicts" && l.kind !== "transition")
70
+ continue;
71
+ const target = recordById.get(l.target);
72
+ // Only a same-slot supersede (the source shares the target's origin +
73
+ // subjectKey) is a genuine user correction; this structurally excludes a
74
+ // consolidation merge of cross-slot near-duplicates.
75
+ if (target?.subjectKey && slotOf(target) === srcSlot)
76
+ supersededTargets.add(l.target);
77
+ }
78
+ }
79
+ const correctionDepth = new Map();
80
+ for (const a of store.readAll()) {
81
+ if (a.lifecycle === "active" || !a.subjectKey || !supersededTargets.has(a.memoryId))
82
+ continue;
83
+ const k = JSON.stringify([originBucketKey(a), a.subjectKey]);
84
+ correctionDepth.set(k, (correctionDepth.get(k) ?? 0) + 1);
85
+ }
86
+ for (const r of active) {
87
+ if (!r.subjectKey || r.status === "confirmed")
88
+ continue;
89
+ const assertions = r.accessCount + 1;
90
+ const corrections = correctionDepth.get(JSON.stringify([originBucketKey(r), r.subjectKey])) ?? 0;
91
+ if (Math.max(assertions, corrections) < confirmCount)
92
+ continue;
93
+ const prior = store.promote(r.memoryId, { status: "confirmed", confidence: confirmConfidence, importance: Math.max(r.importance, 0.8) }, { now });
94
+ if (prior)
95
+ result.confirmed.push({ memoryId: r.memoryId, prior });
96
+ }
97
+ if (result.confirmed.length > 0)
98
+ active = activeNow();
99
+ // ── CONSOLIDATE: near-identical active pairs → keep stronger, supersede dup.
100
+ // Bucket by origin FIRST so a merge NEVER crosses principals — even in a
101
+ // whole-store pass (opts.origin undefined): synonymyEdges runs PER origin
102
+ // bucket, so an owner fact can't dissolve into a channel peer's identical one
103
+ // (which would leak a cross-principal contradicts/transition edge).
104
+ const byId = new Map(active.map((r) => [r.memoryId, r]));
105
+ const merged = new Set();
106
+ const buckets = new Map();
107
+ for (const r of active) {
108
+ const k = originBucketKey(r);
109
+ const arr = buckets.get(k);
110
+ if (arr)
111
+ arr.push(r);
112
+ else
113
+ buckets.set(k, [r]);
114
+ }
115
+ // Step 19 relatedness edges — collected across buckets, persisted once after merges.
116
+ const relatedPairs = [];
117
+ for (const bucket of buckets.values()) {
118
+ // A pair that's BOTH confirmed is a supersede we DECLINE below — record it so the
119
+ // relatedness scan doesn't then mint a `relates` edge between two near-identical
120
+ // confirmed facts (graph-recall noise, not a genuine association).
121
+ const bothConfirmedPairs = new Set();
122
+ for (const e of synonymyEdges(bucket, { threshold: consolidateThreshold })) {
123
+ if (merged.has(e.from) || merged.has(e.to))
124
+ continue;
125
+ const a = byId.get(e.from);
126
+ const b = byId.get(e.to);
127
+ if (!a || !b)
128
+ continue;
129
+ // Keeper precedence, each dominating the next: (1) TRUST — an untrusted fact
130
+ // must NEVER supersede a trusted owner-authored one (write-gate Rule 2: the
131
+ // write path enforces it, so the dream must too — else attacker-influenceable
132
+ // content archives an owner belief); (2) RICHNESS (Fix 3) — the metadata-richer
133
+ // fact (has subjectKey, more-specific segment, importance, confirmations) wins,
134
+ // so a reworded subject-less `knowledge` copy can NEVER archive a subject-bearing
135
+ // `identity`/`preference` original; (3) CONFIRMED — a confirmed belief outranks a
136
+ // non-confirmed near-duplicate; (4) effectiveScore.
137
+ const trust = (r) => (isTrustedTarget(r.sourceType) ? 1 : 0);
138
+ const conf = (r) => (r.status === "confirmed" ? 1 : 0);
139
+ const richer = compareRichness(a, b); // >0 a richer, <0 b richer, 0 tie
140
+ const aWins = trust(a) !== trust(b)
141
+ ? trust(a) > trust(b)
142
+ : richer !== 0
143
+ ? richer > 0
144
+ : conf(a) !== conf(b)
145
+ ? conf(a) > conf(b)
146
+ : effectiveScore(a, now) >= effectiveScore(b, now);
147
+ const [keep, drop] = aWins ? [a, b] : [b, a];
148
+ // Don't dissolve one confirmed belief into ANOTHER — both are load-bearing.
149
+ if (keep.status === "confirmed" && drop.status === "confirmed") {
150
+ bothConfirmedPairs.add(`${e.from}|${e.to}`); // a declined supersede ⇒ not a relation either
151
+ continue;
152
+ }
153
+ // Preserve metadata (Fix 2): the keeper inherits the richer of each field
154
+ // from the duplicate BEFORE it's archived, so a merge never silently drops a
155
+ // subjectKey / more-specific segment / higher importance the loser carried.
156
+ store.mergeMetadataInto(keep.memoryId, drop.memoryId);
157
+ store.invalidate(drop.memoryId, { supersededBy: keep.memoryId, now });
158
+ merged.add(drop.memoryId);
159
+ result.consolidated.push({ kept: keep.memoryId, merged: drop.memoryId });
160
+ }
161
+ // RELATE (Step 19): synonymy pairs in the relatedness band (>= relatesThreshold)
162
+ // that we did NOT merge become persistent `relates` edges, so graph-recall pulls
163
+ // in associated — not just duplicate — facts. Inside the per-origin bucket, so
164
+ // every edge is same-origin (no cross-principal leak).
165
+ if (relatesThreshold < 1) {
166
+ for (const e of synonymyEdges(bucket, { threshold: relatesThreshold })) {
167
+ if (merged.has(e.from) || merged.has(e.to))
168
+ continue; // a merged pair is a supersede, not a relation
169
+ if (bothConfirmedPairs.has(`${e.from}|${e.to}`))
170
+ continue; // declined confirmed-vs-confirmed supersede: not an association
171
+ relatedPairs.push({ a: e.from, b: e.to });
172
+ }
173
+ }
174
+ }
175
+ if (result.consolidated.length > 0)
176
+ active = activeNow();
177
+ // Persist relatedness edges once (post-merge ⇒ linkRelated skips any now-archived).
178
+ if (relatedPairs.length > 0) {
179
+ result.related = store.linkRelated(relatedPairs);
180
+ if (result.related > 0)
181
+ active = activeNow();
182
+ }
183
+ // ── EVICT: decayed below the floor, old enough, never a confirmed belief.
184
+ const toEvict = active
185
+ .filter((r) => r.status !== "confirmed")
186
+ .filter((r) => now - r.createdAt >= evictMinAge)
187
+ .filter((r) => effectiveScore(r, now) < evictBelow)
188
+ .map((r) => r.memoryId);
189
+ result.evicted = store.evict(toEvict, { now });
190
+ return result;
191
+ }
192
+ //# sourceMappingURL=dream.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"dream.js","sourceRoot":"","sources":["../../../src/agents/memory/dream.ts"],"names":[],"mappings":"AAAA,6BAA6B;AAC7B,EAAE;AACF,wEAAwE;AACxE,EAAE;AACF,+EAA+E;AAC/E,qEAAqE;AACrE,0EAA0E;AAC1E,sEAAsE;AACtE,6EAA6E;AAC7E,+EAA+E;AAC/E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AAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,QAAQ,CAAC,CAAC;IACzB,MAAM,CAAC,OAAO,GAAG,KAAK,CAAC,KAAK,CAAC,OAAO,EAAE,EAAE,GAAG,EAAE,CAAC,CAAC;IAE/C,OAAO,MAAM,CAAC;AACf,CAAC"}
@@ -0,0 +1,114 @@
1
+ /**
2
+ * Embedder PROVIDER registry — the pluggable, lazy, optional, graceful-degrading
3
+ * embedder selection: a registry of adapters, each of which LAZILY creates an
4
+ * embedder or returns `null` to degrade. The heavy local backend
5
+ * (`node-llama-cpp` → `embeddinggemma`) is an OPTIONAL dependency, lazy-imported,
6
+ * never top-level — so the default install never pays for it and air-gap stays
7
+ * intact. When no learned embedder is available (no key, dep not installed),
8
+ * resolution falls back to the zero-dep model-free {@link HrrEmbedder} — recall
9
+ * ALWAYS works, degrading to lexical-only like any robust hybrid engine.
10
+ *
11
+ * The model-free HRR is the always-available floor; this module adds the
12
+ * learned-embedder path on top (a learned model lifts true-synonymy recall).
13
+ *
14
+ * Provider tiers (three transports):
15
+ * - "model-free" → HrrEmbedder (zero-dep, offline, sync) — the always-available floor.
16
+ * - "local" → embeddinggemma via node-llama-cpp (offline, air-gap, async).
17
+ * - "remote" → OpenAI text-embedding-3-small @ 256 dims (network, async).
18
+ *
19
+ * DIMS: every adapter emits 256-dim L2-normalised vectors so they're drop-in for
20
+ * the existing convex `by_embedding` vectorIndex (no schema migration) and
21
+ * cosine-comparable with the bundled HRR. The learned models are truncated via
22
+ * Matryoshka (text-embedding-3-small `dimensions:256`; embeddinggemma 768→256)
23
+ * then re-normalised. (NOTE: switching embedder FAMILIES requires re-embedding
24
+ * stored facts — cross-family cosine is meaningless — i.e. re-index on model
25
+ * change. That re-embed pass + async write/recall wiring is the activation step
26
+ * that turns a registered adapter into live recall.)
27
+ */
28
+ import { type Embedder } from "./embedder.js";
29
+ /** Vectors every adapter emits at this width (matches the convex vectorIndex + HRR). */
30
+ export declare const EMBEDDER_DIMS = 256;
31
+ /** L2-normalise (and optionally Matryoshka-truncate) a raw model vector to unit
32
+ * length at `dims` — so cosine = dot and short/long texts compare fairly. A
33
+ * near-zero vector maps to all-zeros (cosine() then returns 0). Standard
34
+ * embedding sanitize-and-normalize. */
35
+ export declare function normalizeTo(raw: readonly number[], dims?: number): number[];
36
+ /**
37
+ * An embedder adapter (a memory-embedding provider adapter): lazily make
38
+ * an {@link Embedder}, or return `null` to gracefully degrade (missing key /
39
+ * uninstalled optional dep). `create` MUST return null — never throw — for a
40
+ * missing-credential / missing-dep case, so resolution can fall through.
41
+ */
42
+ export interface EmbedderAdapter {
43
+ readonly id: string;
44
+ readonly transport: "model-free" | "local" | "remote";
45
+ /** Lower = tried first in auto-select; omit to exclude from auto-select. */
46
+ readonly autoSelectPriority?: number;
47
+ create(): Promise<Embedder | null>;
48
+ /** One-line setup hint shown when this adapter was requested but unavailable. */
49
+ formatSetupError?(): string;
50
+ }
51
+ export declare function registerEmbedderAdapter(adapter: EmbedderAdapter): void;
52
+ export declare function listEmbedderAdapters(): EmbedderAdapter[];
53
+ export declare function getEmbedderAdapter(id: string): EmbedderAdapter | undefined;
54
+ /** Test-only. */
55
+ export declare function __resetEmbedderRegistryForTests(): void;
56
+ /**
57
+ * Resolve the embedder for a `selection`:
58
+ * - "model-free" (default) → always the zero-dep HRR (air-gap, no network).
59
+ * - a specific adapter id → that adapter; falls back to HRR if it yields null.
60
+ * - "auto" → highest-priority adapter that creates successfully,
61
+ * else HRR.
62
+ * NEVER throws and ALWAYS returns a working embedder (graceful degrade) — the
63
+ * the always-fallback invariant: a missing model/key downgrades, never breaks.
64
+ */
65
+ export declare function resolveEmbedder(selection?: string): Promise<Embedder>;
66
+ /** OpenAI text-embedding-3-small, requesting `dimensions:256` (Matryoshka) so it
67
+ * drops into the existing 256-dim vectorIndex. Async; L2-normalised on output. */
68
+ export declare class OpenAiEmbedder implements Embedder {
69
+ private readonly apiKey;
70
+ private readonly model;
71
+ private readonly fetchImpl;
72
+ readonly id = "openai:text-embedding-3-small:256";
73
+ readonly dims = 256;
74
+ constructor(apiKey: string, model?: string, fetchImpl?: typeof fetch);
75
+ embed(texts: string[]): Promise<number[][]>;
76
+ }
77
+ /** Adapter: enabled only when an OpenAI key is present (env or injected). Returns
78
+ * null (degrade) when absent — never throws on a missing key. */
79
+ export declare function openAiEmbedderAdapter(opts?: {
80
+ apiKey?: string;
81
+ }): EmbedderAdapter;
82
+ /** Default local embedding model (Q8 GGUF, auto-resolved/downloaded). */
83
+ export declare const DEFAULT_LOCAL_EMBED_MODEL = "hf:ggml-org/embeddinggemma-300m-qat-q8_0-GGUF/embeddinggemma-300m-qat-Q8_0.gguf";
84
+ /**
85
+ * Local embedder over `node-llama-cpp` + embeddinggemma (768-dim → 256 Matryoshka).
86
+ * OFFLINE / AIR-GAP once the model is cached. The model + context init is memoised
87
+ * behind a shared promise (an init-promise guard) so concurrent calls share one load.
88
+ * Runs only when the optional `node-llama-cpp` dep is installed.
89
+ */
90
+ export declare class LocalLlamaEmbedder implements Embedder {
91
+ private readonly loadCtx;
92
+ readonly id = "local:embeddinggemma-300m:256";
93
+ readonly dims = 256;
94
+ private ctx;
95
+ constructor(loadCtx: () => Promise<{
96
+ getEmbeddingFor: (t: string) => Promise<{
97
+ vector: number[];
98
+ }>;
99
+ }>);
100
+ private ensure;
101
+ embed(texts: string[]): Promise<number[][]>;
102
+ }
103
+ /** Adapter: lazy-imports `node-llama-cpp` (an OPTIONAL dep). Returns null (degrade
104
+ * to HRR) when the dep isn't installed — the optional-dependency
105
+ * pattern, so air-gap installs that haven't added it simply fall back. */
106
+ export declare function localLlamaEmbedderAdapter(opts?: {
107
+ model?: string;
108
+ cacheDir?: string;
109
+ }): EmbedderAdapter;
110
+ /** Register the built-in adapters. Idempotent-ish (overwrites by id). The
111
+ * model-free HRR is the implicit fallback in resolveEmbedder, so it's not an
112
+ * auto-select adapter; the two LEARNED adapters are (local first, then remote). */
113
+ export declare function registerBuiltInEmbedderAdapters(): void;
114
+ //# sourceMappingURL=embedder-providers.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"embedder-providers.d.ts","sourceRoot":"","sources":["../../../src/agents/memory/embedder-providers.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;GA0BG;AAEH,OAAO,EAAE,KAAK,QAAQ,EAAe,MAAM,eAAe,CAAC;AAE3D,wFAAwF;AACxF,eAAO,MAAM,aAAa,MAAM,CAAC;AAEjC;;;wCAGwC;AACxC,wBAAgB,WAAW,CAAC,GAAG,EAAE,SAAS,MAAM,EAAE,EAAE,IAAI,GAAE,MAAsB,GAAG,MAAM,EAAE,CAO1F;AAED;;;;;GAKG;AACH,MAAM,WAAW,eAAe;IAC/B,QAAQ,CAAC,EAAE,EAAE,MAAM,CAAC;IACpB,QAAQ,CAAC,SAAS,EAAE,YAAY,GAAG,OAAO,GAAG,QAAQ,CAAC;IACtD,4EAA4E;IAC5E,QAAQ,CAAC,kBAAkB,CAAC,EAAE,MAAM,CAAC;IACrC,MAAM,IAAI,OAAO,CAAC,QAAQ,GAAG,IAAI,CAAC,CAAC;IACnC,iFAAiF;IACjF,gBAAgB,CAAC,IAAI,MAAM,CAAC;CAC5B;AAID,wBAAgB,uBAAuB,CAAC,OAAO,EAAE,eAAe,GAAG,IAAI,CAEtE;AACD,wBAAgB,oBAAoB,IAAI,eAAe,EAAE,CAExD;AACD,wBAAgB,kBAAkB,CAAC,EAAE,EAAE,MAAM,GAAG,eAAe,GAAG,SAAS,CAE1E;AACD,iBAAiB;AACjB,wBAAgB,+BAA+B,IAAI,IAAI,CAGtD;AAED;;;;;;;;GAQG;AACH,wBAAsB,eAAe,CAAC,SAAS,GAAE,MAAqB,GAAG,OAAO,CAAC,QAAQ,CAAC,CAsBzF;AAID;mFACmF;AACnF,qBAAa,cAAe,YAAW,QAAQ;IAO7C,OAAO,CAAC,QAAQ,CAAC,MAAM;IACvB,OAAO,CAAC,QAAQ,CAAC,KAAK;IACtB,OAAO,CAAC,QAAQ,CAAC,SAAS;IAR3B,QAAQ,CAAC,EAAE,uCAAuC;IAClD,QAAQ,CAAC,IAAI,OAAiB;gBAKZ,MAAM,EAAE,MAAM,EACd,KAAK,SAA2B,EAChC,SAAS,GAAE,OAAO,KAAa;IAG3C,KAAK,CAAC,KAAK,EAAE,MAAM,EAAE,GAAG,OAAO,CAAC,MAAM,EAAE,EAAE,CAAC;CAajD;AAED;kEACkE;AAClE,wBAAgB,qBAAqB,CAAC,IAAI,GAAE;IAAE,MAAM,CAAC,EAAE,MAAM,CAAA;CAAO,GAAG,eAAe,CAWrF;AAID,yEAAyE;AACzE,eAAO,MAAM,yBAAyB,oFAC4C,CAAC;AAEnF;;;;;GAKG;AACH,qBAAa,kBAAmB,YAAW,QAAQ;IAMjD,OAAO,CAAC,QAAQ,CAAC,OAAO;IALzB,QAAQ,CAAC,EAAE,mCAAmC;IAC9C,QAAQ,CAAC,IAAI,OAAiB;IAC9B,OAAO,CAAC,GAAG,CAA2F;gBAGpF,OAAO,EAAE,MAAM,OAAO,CAAC;QAAE,eAAe,EAAE,CAAC,CAAC,EAAE,MAAM,KAAK,OAAO,CAAC;YAAE,MAAM,EAAE,MAAM,EAAE,CAAA;SAAE,CAAC,CAAA;KAAE,CAAC;IAG3G,OAAO,CAAC,MAAM;IAKR,KAAK,CAAC,KAAK,EAAE,MAAM,EAAE,GAAG,OAAO,CAAC,MAAM,EAAE,EAAE,CAAC;CAQjD;AAED;;2EAE2E;AAC3E,wBAAgB,yBAAyB,CAAC,IAAI,GAAE;IAAE,KAAK,CAAC,EAAE,MAAM,CAAC;IAAC,QAAQ,CAAC,EAAE,MAAM,CAAA;CAAO,GAAG,eAAe,CAkC3G;AAED;;oFAEoF;AACpF,wBAAgB,+BAA+B,IAAI,IAAI,CAGtD"}
@@ -0,0 +1,213 @@
1
+ /**
2
+ * Embedder PROVIDER registry — the pluggable, lazy, optional, graceful-degrading
3
+ * embedder selection: a registry of adapters, each of which LAZILY creates an
4
+ * embedder or returns `null` to degrade. The heavy local backend
5
+ * (`node-llama-cpp` → `embeddinggemma`) is an OPTIONAL dependency, lazy-imported,
6
+ * never top-level — so the default install never pays for it and air-gap stays
7
+ * intact. When no learned embedder is available (no key, dep not installed),
8
+ * resolution falls back to the zero-dep model-free {@link HrrEmbedder} — recall
9
+ * ALWAYS works, degrading to lexical-only like any robust hybrid engine.
10
+ *
11
+ * The model-free HRR is the always-available floor; this module adds the
12
+ * learned-embedder path on top (a learned model lifts true-synonymy recall).
13
+ *
14
+ * Provider tiers (three transports):
15
+ * - "model-free" → HrrEmbedder (zero-dep, offline, sync) — the always-available floor.
16
+ * - "local" → embeddinggemma via node-llama-cpp (offline, air-gap, async).
17
+ * - "remote" → OpenAI text-embedding-3-small @ 256 dims (network, async).
18
+ *
19
+ * DIMS: every adapter emits 256-dim L2-normalised vectors so they're drop-in for
20
+ * the existing convex `by_embedding` vectorIndex (no schema migration) and
21
+ * cosine-comparable with the bundled HRR. The learned models are truncated via
22
+ * Matryoshka (text-embedding-3-small `dimensions:256`; embeddinggemma 768→256)
23
+ * then re-normalised. (NOTE: switching embedder FAMILIES requires re-embedding
24
+ * stored facts — cross-family cosine is meaningless — i.e. re-index on model
25
+ * change. That re-embed pass + async write/recall wiring is the activation step
26
+ * that turns a registered adapter into live recall.)
27
+ */
28
+ import { HrrEmbedder } from "./embedder.js";
29
+ /** Vectors every adapter emits at this width (matches the convex vectorIndex + HRR). */
30
+ export const EMBEDDER_DIMS = 256;
31
+ /** L2-normalise (and optionally Matryoshka-truncate) a raw model vector to unit
32
+ * length at `dims` — so cosine = dot and short/long texts compare fairly. A
33
+ * near-zero vector maps to all-zeros (cosine() then returns 0). Standard
34
+ * embedding sanitize-and-normalize. */
35
+ export function normalizeTo(raw, dims = EMBEDDER_DIMS) {
36
+ const v = raw.length > dims ? raw.slice(0, dims) : raw.slice();
37
+ let mag = 0;
38
+ for (const x of v)
39
+ mag += (Number.isFinite(x) ? x : 0) ** 2;
40
+ mag = Math.sqrt(mag);
41
+ if (mag < 1e-10)
42
+ return new Array(v.length).fill(0);
43
+ return v.map((x) => (Number.isFinite(x) ? x : 0) / mag);
44
+ }
45
+ const registry = new Map();
46
+ export function registerEmbedderAdapter(adapter) {
47
+ registry.set(adapter.id, adapter);
48
+ }
49
+ export function listEmbedderAdapters() {
50
+ return [...registry.values()];
51
+ }
52
+ export function getEmbedderAdapter(id) {
53
+ return registry.get(id);
54
+ }
55
+ /** Test-only. */
56
+ export function __resetEmbedderRegistryForTests() {
57
+ registry.clear();
58
+ registerBuiltInEmbedderAdapters();
59
+ }
60
+ /**
61
+ * Resolve the embedder for a `selection`:
62
+ * - "model-free" (default) → always the zero-dep HRR (air-gap, no network).
63
+ * - a specific adapter id → that adapter; falls back to HRR if it yields null.
64
+ * - "auto" → highest-priority adapter that creates successfully,
65
+ * else HRR.
66
+ * NEVER throws and ALWAYS returns a working embedder (graceful degrade) — the
67
+ * the always-fallback invariant: a missing model/key downgrades, never breaks.
68
+ */
69
+ export async function resolveEmbedder(selection = "model-free") {
70
+ const fallback = () => new HrrEmbedder(128);
71
+ if (selection === "model-free")
72
+ return fallback();
73
+ if (selection !== "auto") {
74
+ const adapter = registry.get(selection);
75
+ if (adapter) {
76
+ const e = await adapter.create().catch(() => null);
77
+ if (e)
78
+ return e;
79
+ }
80
+ return fallback();
81
+ }
82
+ // auto: try learned adapters by priority (lowest first), degrade to HRR.
83
+ const ordered = [...registry.values()]
84
+ .filter((a) => a.autoSelectPriority !== undefined)
85
+ .sort((x, y) => (x.autoSelectPriority ?? 1e9) - (y.autoSelectPriority ?? 1e9));
86
+ for (const a of ordered) {
87
+ const e = await a.create().catch(() => null);
88
+ if (e)
89
+ return e;
90
+ }
91
+ return fallback();
92
+ }
93
+ /* ─────────────────────────── remote: OpenAI ─────────────────────────── */
94
+ /** OpenAI text-embedding-3-small, requesting `dimensions:256` (Matryoshka) so it
95
+ * drops into the existing 256-dim vectorIndex. Async; L2-normalised on output. */
96
+ export class OpenAiEmbedder {
97
+ apiKey;
98
+ model;
99
+ fetchImpl;
100
+ id = "openai:text-embedding-3-small:256";
101
+ dims = EMBEDDER_DIMS;
102
+ // A learned model's cosine tracks MEANING not tokens, so unrelated text scores
103
+ // ~0 and true paraphrases clear a low floor — a clean 0.3 default works (no
104
+ // HRR-style high floor needed). Left at the hybrid default by omitting minSim.
105
+ constructor(apiKey, model = "text-embedding-3-small", fetchImpl = fetch) {
106
+ this.apiKey = apiKey;
107
+ this.model = model;
108
+ this.fetchImpl = fetchImpl;
109
+ }
110
+ async embed(texts) {
111
+ if (texts.length === 0)
112
+ return [];
113
+ const res = await this.fetchImpl("https://api.openai.com/v1/embeddings", {
114
+ method: "POST",
115
+ headers: { authorization: `Bearer ${this.apiKey}`, "content-type": "application/json" },
116
+ body: JSON.stringify({ model: this.model, input: texts, dimensions: EMBEDDER_DIMS }),
117
+ });
118
+ if (!res.ok)
119
+ throw new Error(`openai embeddings HTTP ${res.status}`);
120
+ const data = (await res.json());
121
+ const rows = data.data ?? [];
122
+ // Preserve input order (OpenAI returns in order); normalise each.
123
+ return texts.map((_, i) => normalizeTo(rows[i]?.embedding ?? []));
124
+ }
125
+ }
126
+ /** Adapter: enabled only when an OpenAI key is present (env or injected). Returns
127
+ * null (degrade) when absent — never throws on a missing key. */
128
+ export function openAiEmbedderAdapter(opts = {}) {
129
+ return {
130
+ id: "openai-256",
131
+ transport: "remote",
132
+ autoSelectPriority: 20, // after local (10)
133
+ async create() {
134
+ const key = opts.apiKey ?? process.env.OPENAI_API_KEY ?? "";
135
+ return key.trim() ? new OpenAiEmbedder(key.trim()) : null;
136
+ },
137
+ formatSetupError: () => "set OPENAI_API_KEY to use the OpenAI text-embedding-3-small (256-dim) embedder",
138
+ };
139
+ }
140
+ /* ──────────────────── local: node-llama-cpp / embeddinggemma ──────────────────── */
141
+ /** Default local embedding model (Q8 GGUF, auto-resolved/downloaded). */
142
+ export const DEFAULT_LOCAL_EMBED_MODEL = "hf:ggml-org/embeddinggemma-300m-qat-q8_0-GGUF/embeddinggemma-300m-qat-Q8_0.gguf";
143
+ /**
144
+ * Local embedder over `node-llama-cpp` + embeddinggemma (768-dim → 256 Matryoshka).
145
+ * OFFLINE / AIR-GAP once the model is cached. The model + context init is memoised
146
+ * behind a shared promise (an init-promise guard) so concurrent calls share one load.
147
+ * Runs only when the optional `node-llama-cpp` dep is installed.
148
+ */
149
+ export class LocalLlamaEmbedder {
150
+ loadCtx;
151
+ id = "local:embeddinggemma-300m:256";
152
+ dims = EMBEDDER_DIMS;
153
+ ctx = null;
154
+ constructor(loadCtx) {
155
+ this.loadCtx = loadCtx;
156
+ }
157
+ ensure() {
158
+ if (!this.ctx)
159
+ this.ctx = this.loadCtx();
160
+ return this.ctx;
161
+ }
162
+ async embed(texts) {
163
+ if (texts.length === 0)
164
+ return [];
165
+ const ctx = await this.ensure();
166
+ // Per-text (batch via Promise.all).
167
+ return Promise.all(texts.map(async (t) => normalizeTo(Array.from((await ctx.getEmbeddingFor(t)).vector ?? []))));
168
+ }
169
+ }
170
+ /** Adapter: lazy-imports `node-llama-cpp` (an OPTIONAL dep). Returns null (degrade
171
+ * to HRR) when the dep isn't installed — the optional-dependency
172
+ * pattern, so air-gap installs that haven't added it simply fall back. */
173
+ export function localLlamaEmbedderAdapter(opts = {}) {
174
+ return {
175
+ id: "local-embeddinggemma",
176
+ transport: "local",
177
+ autoSelectPriority: 10, // tried FIRST in auto (local before remote)
178
+ async create() {
179
+ let mod;
180
+ try {
181
+ // Optional dep — never a top-level import; a NON-LITERAL specifier so
182
+ // the type-checker doesn't try to resolve an uninstalled module, and
183
+ // absence at runtime ⇒ graceful null (the optional-dependency pattern).
184
+ const optionalModule = "node-llama-cpp";
185
+ mod = (await import(optionalModule));
186
+ }
187
+ catch {
188
+ return null;
189
+ }
190
+ const getLlama = mod.getLlama;
191
+ const resolveModelFile = mod.resolveModelFile;
192
+ if (typeof getLlama !== "function" || typeof resolveModelFile !== "function")
193
+ return null;
194
+ const loadCtx = async () => {
195
+ const llama = (await getLlama());
196
+ const modelPath = await resolveModelFile(opts.model ?? DEFAULT_LOCAL_EMBED_MODEL, opts.cacheDir);
197
+ const model = await llama.loadModel({ modelPath });
198
+ return model.createEmbeddingContext();
199
+ };
200
+ return new LocalLlamaEmbedder(loadCtx);
201
+ },
202
+ formatSetupError: () => "install the optional `node-llama-cpp` dependency to use the local embeddinggemma embedder (offline/air-gap)",
203
+ };
204
+ }
205
+ /** Register the built-in adapters. Idempotent-ish (overwrites by id). The
206
+ * model-free HRR is the implicit fallback in resolveEmbedder, so it's not an
207
+ * auto-select adapter; the two LEARNED adapters are (local first, then remote). */
208
+ export function registerBuiltInEmbedderAdapters() {
209
+ registerEmbedderAdapter(localLlamaEmbedderAdapter());
210
+ registerEmbedderAdapter(openAiEmbedderAdapter());
211
+ }
212
+ registerBuiltInEmbedderAdapters();
213
+ //# sourceMappingURL=embedder-providers.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"embedder-providers.js","sourceRoot":"","sources":["../../../src/agents/memory/embedder-providers.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;GA0BG;AAEH,OAAO,EAAiB,WAAW,EAAE,MAAM,eAAe,CAAC;AAE3D,wFAAwF;AACxF,MAAM,CAAC,MAAM,aAAa,GAAG,GAAG,CAAC;AAEjC;;;wCAGwC;AACxC,MAAM,UAAU,WAAW,CAAC,GAAsB,EAAE,OAAe,aAAa;IAC/E,MAAM,CAAC,GAAG,GAAG,CAAC,MAAM,GAAG,IAAI,CAAC,CAAC,CAAC,GAAG,CAAC,KAAK,CAAC,CAAC,EAAE,IAAI,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,KAAK,EAAE,CAAC;IAC/D,IAAI,GAAG,GAAG,CAAC,CAAC;IACZ,KAAK,MAAM,CAAC,IAAI,CAAC;QAAE,GAAG,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,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