@hasna/mementos 0.14.86 → 0.14.87

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 (565) hide show
  1. package/dist/cli/__fixtures__/clean-fallback-stub-server.d.ts +2 -0
  2. package/dist/cli/__fixtures__/clean-fallback-stub-server.d.ts.map +1 -0
  3. package/dist/cli/__fixtures__/io-restore-stub-server.d.ts +2 -0
  4. package/dist/cli/__fixtures__/io-restore-stub-server.d.ts.map +1 -0
  5. package/dist/cli/brains.d.ts +3 -0
  6. package/dist/cli/brains.d.ts.map +1 -0
  7. package/dist/cli/commands/agent.d.ts +3 -0
  8. package/dist/cli/commands/agent.d.ts.map +1 -0
  9. package/dist/cli/commands/consolidation.d.ts +3 -0
  10. package/dist/cli/commands/consolidation.d.ts.map +1 -0
  11. package/dist/cli/commands/entity.d.ts +3 -0
  12. package/dist/cli/commands/entity.d.ts.map +1 -0
  13. package/dist/cli/commands/graph.d.ts +3 -0
  14. package/dist/cli/commands/graph.d.ts.map +1 -0
  15. package/dist/cli/commands/info-context.d.ts +3 -0
  16. package/dist/cli/commands/info-context.d.ts.map +1 -0
  17. package/dist/cli/commands/info-history.d.ts +3 -0
  18. package/dist/cli/commands/info-history.d.ts.map +1 -0
  19. package/dist/cli/commands/info-report.d.ts +3 -0
  20. package/dist/cli/commands/info-report.d.ts.map +1 -0
  21. package/dist/cli/commands/info-stale.d.ts +3 -0
  22. package/dist/cli/commands/info-stale.d.ts.map +1 -0
  23. package/dist/cli/commands/info-stats.d.ts +3 -0
  24. package/dist/cli/commands/info-stats.d.ts.map +1 -0
  25. package/dist/cli/commands/info.d.ts +12 -0
  26. package/dist/cli/commands/info.d.ts.map +1 -0
  27. package/dist/cli/commands/init.d.ts +3 -0
  28. package/dist/cli/commands/init.d.ts.map +1 -0
  29. package/dist/cli/commands/io-backup.d.ts +3 -0
  30. package/dist/cli/commands/io-backup.d.ts.map +1 -0
  31. package/dist/cli/commands/io-clean.d.ts +3 -0
  32. package/dist/cli/commands/io-clean.d.ts.map +1 -0
  33. package/dist/cli/commands/io-export.d.ts +3 -0
  34. package/dist/cli/commands/io-export.d.ts.map +1 -0
  35. package/dist/cli/commands/io-import.d.ts +3 -0
  36. package/dist/cli/commands/io-import.d.ts.map +1 -0
  37. package/dist/cli/commands/io-restore.d.ts +3 -0
  38. package/dist/cli/commands/io-restore.d.ts.map +1 -0
  39. package/dist/cli/commands/io.d.ts +12 -0
  40. package/dist/cli/commands/io.d.ts.map +1 -0
  41. package/dist/cli/commands/memory-cmd-bulk.d.ts +3 -0
  42. package/dist/cli/commands/memory-cmd-bulk.d.ts.map +1 -0
  43. package/dist/cli/commands/memory-cmd-chain.d.ts +3 -0
  44. package/dist/cli/commands/memory-cmd-chain.d.ts.map +1 -0
  45. package/dist/cli/commands/memory-cmd-crud.d.ts +3 -0
  46. package/dist/cli/commands/memory-cmd-crud.d.ts.map +1 -0
  47. package/dist/cli/commands/memory-cmd-diff.d.ts +3 -0
  48. package/dist/cli/commands/memory-cmd-diff.d.ts.map +1 -0
  49. package/dist/cli/commands/memory-cmd-list.d.ts +3 -0
  50. package/dist/cli/commands/memory-cmd-list.d.ts.map +1 -0
  51. package/dist/cli/commands/memory-cmd-recall-exit.d.ts +3 -0
  52. package/dist/cli/commands/memory-cmd-recall-exit.d.ts.map +1 -0
  53. package/dist/cli/commands/memory-cmd-recall.d.ts +3 -0
  54. package/dist/cli/commands/memory-cmd-recall.d.ts.map +1 -0
  55. package/dist/cli/commands/memory-cmd-remove.d.ts +3 -0
  56. package/dist/cli/commands/memory-cmd-remove.d.ts.map +1 -0
  57. package/dist/cli/commands/memory-cmd-search.d.ts +3 -0
  58. package/dist/cli/commands/memory-cmd-search.d.ts.map +1 -0
  59. package/dist/cli/commands/memory-cmd-tail.d.ts +3 -0
  60. package/dist/cli/commands/memory-cmd-tail.d.ts.map +1 -0
  61. package/dist/cli/commands/memory-cmd-util.d.ts +3 -0
  62. package/dist/cli/commands/memory-cmd-util.d.ts.map +1 -0
  63. package/dist/cli/commands/memory-cmd-view.d.ts +3 -0
  64. package/dist/cli/commands/memory-cmd-view.d.ts.map +1 -0
  65. package/dist/cli/commands/memory-cmd-watch.d.ts +3 -0
  66. package/dist/cli/commands/memory-cmd-watch.d.ts.map +1 -0
  67. package/dist/cli/commands/memory-cmd-when-to-use.d.ts +3 -0
  68. package/dist/cli/commands/memory-cmd-when-to-use.d.ts.map +1 -0
  69. package/dist/cli/commands/memory.d.ts +3 -0
  70. package/dist/cli/commands/memory.d.ts.map +1 -0
  71. package/dist/cli/commands/project-panel.d.ts +3 -0
  72. package/dist/cli/commands/project-panel.d.ts.map +1 -0
  73. package/dist/cli/commands/project.d.ts +3 -0
  74. package/dist/cli/commands/project.d.ts.map +1 -0
  75. package/dist/cli/commands/relation.d.ts +3 -0
  76. package/dist/cli/commands/relation.d.ts.map +1 -0
  77. package/dist/cli/commands/storage.d.ts +3 -0
  78. package/dist/cli/commands/storage.d.ts.map +1 -0
  79. package/dist/cli/commands/system-auto-memory.d.ts +3 -0
  80. package/dist/cli/commands/system-auto-memory.d.ts.map +1 -0
  81. package/dist/cli/commands/system-completions.d.ts +13 -0
  82. package/dist/cli/commands/system-completions.d.ts.map +1 -0
  83. package/dist/cli/commands/system-config.d.ts +3 -0
  84. package/dist/cli/commands/system-config.d.ts.map +1 -0
  85. package/dist/cli/commands/system-doctor.d.ts +3 -0
  86. package/dist/cli/commands/system-doctor.d.ts.map +1 -0
  87. package/dist/cli/commands/system-hooks.d.ts +3 -0
  88. package/dist/cli/commands/system-hooks.d.ts.map +1 -0
  89. package/dist/cli/commands/system-mcp.d.ts +3 -0
  90. package/dist/cli/commands/system-mcp.d.ts.map +1 -0
  91. package/dist/cli/commands/system-misc.d.ts +3 -0
  92. package/dist/cli/commands/system-misc.d.ts.map +1 -0
  93. package/dist/cli/commands/system-profile.d.ts +3 -0
  94. package/dist/cli/commands/system-profile.d.ts.map +1 -0
  95. package/dist/cli/commands/system-session.d.ts +3 -0
  96. package/dist/cli/commands/system-session.d.ts.map +1 -0
  97. package/dist/cli/commands/system-sessions.d.ts +3 -0
  98. package/dist/cli/commands/system-sessions.d.ts.map +1 -0
  99. package/dist/cli/commands/system-synthesis.d.ts +3 -0
  100. package/dist/cli/commands/system-synthesis.d.ts.map +1 -0
  101. package/dist/cli/commands/system-synthesized-profile.d.ts +3 -0
  102. package/dist/cli/commands/system-synthesized-profile.d.ts.map +1 -0
  103. package/dist/cli/commands/system-tools.d.ts +3 -0
  104. package/dist/cli/commands/system-tools.d.ts.map +1 -0
  105. package/dist/cli/commands/system-watch.d.ts +3 -0
  106. package/dist/cli/commands/system-watch.d.ts.map +1 -0
  107. package/dist/cli/commands/system.d.ts +3 -0
  108. package/dist/cli/commands/system.d.ts.map +1 -0
  109. package/dist/cli/exit-codes.d.ts +13 -0
  110. package/dist/cli/exit-codes.d.ts.map +1 -0
  111. package/dist/cli/global-options.d.ts +27 -0
  112. package/dist/cli/global-options.d.ts.map +1 -0
  113. package/dist/cli/helpers.d.ts +150 -0
  114. package/dist/cli/helpers.d.ts.map +1 -0
  115. package/dist/cli/index.d.ts +3 -0
  116. package/dist/cli/index.d.ts.map +1 -0
  117. package/dist/cli/index.js +204 -20
  118. package/dist/cli/register-all.d.ts +17 -0
  119. package/dist/cli/register-all.d.ts.map +1 -0
  120. package/dist/cli/startup-side-effects.d.ts +9 -0
  121. package/dist/cli/startup-side-effects.d.ts.map +1 -0
  122. package/dist/db/__fixtures__/fail-closed-stub-server.d.ts +2 -0
  123. package/dist/db/__fixtures__/fail-closed-stub-server.d.ts.map +1 -0
  124. package/dist/db/__fixtures__/list-filter-capture-server.d.ts +2 -0
  125. package/dist/db/__fixtures__/list-filter-capture-server.d.ts.map +1 -0
  126. package/dist/db/__fixtures__/list-filter-client-runner.d.ts +2 -0
  127. package/dist/db/__fixtures__/list-filter-client-runner.d.ts.map +1 -0
  128. package/dist/db/acl.d.ts +34 -0
  129. package/dist/db/acl.d.ts.map +1 -0
  130. package/dist/db/agents.d.ts +35 -0
  131. package/dist/db/agents.d.ts.map +1 -0
  132. package/dist/db/analytics.d.ts +124 -0
  133. package/dist/db/analytics.d.ts.map +1 -0
  134. package/dist/db/api-mode.d.ts +127 -0
  135. package/dist/db/api-mode.d.ts.map +1 -0
  136. package/dist/db/audit.d.ts +53 -0
  137. package/dist/db/audit.d.ts.map +1 -0
  138. package/dist/db/database.d.ts +26 -0
  139. package/dist/db/database.d.ts.map +1 -0
  140. package/dist/db/entities.d.ts +62 -0
  141. package/dist/db/entities.d.ts.map +1 -0
  142. package/dist/db/entity-memories.d.ts +34 -0
  143. package/dist/db/entity-memories.d.ts.map +1 -0
  144. package/dist/db/feedback.d.ts +9 -0
  145. package/dist/db/feedback.d.ts.map +1 -0
  146. package/dist/db/locks.d.ts +63 -0
  147. package/dist/db/locks.d.ts.map +1 -0
  148. package/dist/db/machines.d.ts +23 -0
  149. package/dist/db/machines.d.ts.map +1 -0
  150. package/dist/db/memories.d.ts +199 -0
  151. package/dist/db/memories.d.ts.map +1 -0
  152. package/dist/db/memory-links.d.ts +21 -0
  153. package/dist/db/memory-links.d.ts.map +1 -0
  154. package/dist/db/memory-project-link.d.ts +13 -0
  155. package/dist/db/memory-project-link.d.ts.map +1 -0
  156. package/dist/db/migrations.d.ts +3 -0
  157. package/dist/db/migrations.d.ts.map +1 -0
  158. package/dist/db/pg-migrate.d.ts +27 -0
  159. package/dist/db/pg-migrate.d.ts.map +1 -0
  160. package/dist/db/pg-migrations.d.ts +2 -0
  161. package/dist/db/pg-migrations.d.ts.map +1 -0
  162. package/dist/db/projects.d.ts +27 -0
  163. package/dist/db/projects.d.ts.map +1 -0
  164. package/dist/db/ratings.d.ts +23 -0
  165. package/dist/db/ratings.d.ts.map +1 -0
  166. package/dist/db/relations.d.ts +49 -0
  167. package/dist/db/relations.d.ts.map +1 -0
  168. package/dist/db/session-jobs.d.ts +67 -0
  169. package/dist/db/session-jobs.d.ts.map +1 -0
  170. package/dist/db/store-backend.d.ts +42 -0
  171. package/dist/db/store-backend.d.ts.map +1 -0
  172. package/dist/db/subscriptions.d.ts +24 -0
  173. package/dist/db/subscriptions.d.ts.map +1 -0
  174. package/dist/db/synthesis.d.ts +101 -0
  175. package/dist/db/synthesis.d.ts.map +1 -0
  176. package/dist/db/tasks.d.ts +89 -0
  177. package/dist/db/tasks.d.ts.map +1 -0
  178. package/dist/db/tool-events.d.ts +27 -0
  179. package/dist/db/tool-events.d.ts.map +1 -0
  180. package/dist/db/webhook_hooks.d.ts +48 -0
  181. package/dist/db/webhook_hooks.d.ts.map +1 -0
  182. package/dist/diagnostics/historical-project-registration-receipt.d.ts +39 -0
  183. package/dist/diagnostics/historical-project-registration-receipt.d.ts.map +1 -0
  184. package/dist/generated/storage-kit/backend.d.ts +20 -0
  185. package/dist/generated/storage-kit/backend.d.ts.map +1 -0
  186. package/dist/generated/storage-kit/health.d.ts +20 -0
  187. package/dist/generated/storage-kit/health.d.ts.map +1 -0
  188. package/dist/generated/storage-kit/index.d.ts +8 -0
  189. package/dist/generated/storage-kit/index.d.ts.map +1 -0
  190. package/dist/generated/storage-kit/migrations.d.ts +48 -0
  191. package/dist/generated/storage-kit/migrations.d.ts.map +1 -0
  192. package/dist/generated/storage-kit/own.d.ts +11 -0
  193. package/dist/generated/storage-kit/own.d.ts.map +1 -0
  194. package/dist/generated/storage-kit/pool.d.ts +35 -0
  195. package/dist/generated/storage-kit/pool.d.ts.map +1 -0
  196. package/dist/generated/storage-kit/query.d.ts +36 -0
  197. package/dist/generated/storage-kit/query.d.ts.map +1 -0
  198. package/dist/generated/storage-kit/tls.d.ts +53 -0
  199. package/dist/generated/storage-kit/tls.d.ts.map +1 -0
  200. package/dist/index.d.ts +45 -0
  201. package/dist/index.d.ts.map +1 -0
  202. package/dist/index.js +2 -2
  203. package/dist/lib/activation-matcher.d.ts +17 -0
  204. package/dist/lib/activation-matcher.d.ts.map +1 -0
  205. package/dist/lib/asmr/categorizer.d.ts +31 -0
  206. package/dist/lib/asmr/categorizer.d.ts.map +1 -0
  207. package/dist/lib/asmr/context-agent.d.ts +4 -0
  208. package/dist/lib/asmr/context-agent.d.ts.map +1 -0
  209. package/dist/lib/asmr/ensemble.d.ts +23 -0
  210. package/dist/lib/asmr/ensemble.d.ts.map +1 -0
  211. package/dist/lib/asmr/fact-agent.d.ts +4 -0
  212. package/dist/lib/asmr/fact-agent.d.ts.map +1 -0
  213. package/dist/lib/asmr/index.d.ts +7 -0
  214. package/dist/lib/asmr/index.d.ts.map +1 -0
  215. package/dist/lib/asmr/orchestrator.d.ts +4 -0
  216. package/dist/lib/asmr/orchestrator.d.ts.map +1 -0
  217. package/dist/lib/asmr/recall.d.ts +3 -0
  218. package/dist/lib/asmr/recall.d.ts.map +1 -0
  219. package/dist/lib/asmr/temporal-agent.d.ts +4 -0
  220. package/dist/lib/asmr/temporal-agent.d.ts.map +1 -0
  221. package/dist/lib/asmr/types.d.ts +27 -0
  222. package/dist/lib/asmr/types.d.ts.map +1 -0
  223. package/dist/lib/auto-inject-orchestrator.d.ts +57 -0
  224. package/dist/lib/auto-inject-orchestrator.d.ts.map +1 -0
  225. package/dist/lib/auto-memory-queue.d.ts +48 -0
  226. package/dist/lib/auto-memory-queue.d.ts.map +1 -0
  227. package/dist/lib/auto-memory.d.ts +19 -0
  228. package/dist/lib/auto-memory.d.ts.map +1 -0
  229. package/dist/lib/bench.d.ts +20 -0
  230. package/dist/lib/bench.d.ts.map +1 -0
  231. package/dist/lib/built-in-hooks.d.ts +32 -0
  232. package/dist/lib/built-in-hooks.d.ts.map +1 -0
  233. package/dist/lib/channel-pusher.d.ts +39 -0
  234. package/dist/lib/channel-pusher.d.ts.map +1 -0
  235. package/dist/lib/config.d.ts +9 -0
  236. package/dist/lib/config.d.ts.map +1 -0
  237. package/dist/lib/connectors/files.d.ts +8 -0
  238. package/dist/lib/connectors/files.d.ts.map +1 -0
  239. package/dist/lib/connectors/github.d.ts +7 -0
  240. package/dist/lib/connectors/github.d.ts.map +1 -0
  241. package/dist/lib/connectors/index.d.ts +12 -0
  242. package/dist/lib/connectors/index.d.ts.map +1 -0
  243. package/dist/lib/connectors/notion.d.ts +7 -0
  244. package/dist/lib/connectors/notion.d.ts.map +1 -0
  245. package/dist/lib/connectors/types.d.ts +27 -0
  246. package/dist/lib/connectors/types.d.ts.map +1 -0
  247. package/dist/lib/consolidation.d.ts +52 -0
  248. package/dist/lib/consolidation.d.ts.map +1 -0
  249. package/dist/lib/context-extractor.d.ts +14 -0
  250. package/dist/lib/context-extractor.d.ts.map +1 -0
  251. package/dist/lib/context.d.ts +36 -0
  252. package/dist/lib/context.d.ts.map +1 -0
  253. package/dist/lib/contradiction.d.ts +50 -0
  254. package/dist/lib/contradiction.d.ts.map +1 -0
  255. package/dist/lib/decay.d.ts +35 -0
  256. package/dist/lib/decay.d.ts.map +1 -0
  257. package/dist/lib/dedup.d.ts +33 -0
  258. package/dist/lib/dedup.d.ts.map +1 -0
  259. package/dist/lib/duration.d.ts +28 -0
  260. package/dist/lib/duration.d.ts.map +1 -0
  261. package/dist/lib/embeddings.d.ts +20 -0
  262. package/dist/lib/embeddings.d.ts.map +1 -0
  263. package/dist/lib/enum-validation.d.ts +20 -0
  264. package/dist/lib/enum-validation.d.ts.map +1 -0
  265. package/dist/lib/export-v1.d.ts +30 -0
  266. package/dist/lib/export-v1.d.ts.map +1 -0
  267. package/dist/lib/extractor.d.ts +9 -0
  268. package/dist/lib/extractor.d.ts.map +1 -0
  269. package/dist/lib/extractors/audio.d.ts +8 -0
  270. package/dist/lib/extractors/audio.d.ts.map +1 -0
  271. package/dist/lib/extractors/index.d.ts +12 -0
  272. package/dist/lib/extractors/index.d.ts.map +1 -0
  273. package/dist/lib/extractors/ocr.d.ts +7 -0
  274. package/dist/lib/extractors/ocr.d.ts.map +1 -0
  275. package/dist/lib/extractors/pdf.d.ts +7 -0
  276. package/dist/lib/extractors/pdf.d.ts.map +1 -0
  277. package/dist/lib/extractors/types.d.ts +12 -0
  278. package/dist/lib/extractors/types.d.ts.map +1 -0
  279. package/dist/lib/file-deps.d.ts +27 -0
  280. package/dist/lib/file-deps.d.ts.map +1 -0
  281. package/dist/lib/focus.d.ts +58 -0
  282. package/dist/lib/focus.d.ts.map +1 -0
  283. package/dist/lib/gatherer.d.ts +16 -0
  284. package/dist/lib/gatherer.d.ts.map +1 -0
  285. package/dist/lib/gdpr.d.ts +39 -0
  286. package/dist/lib/gdpr.d.ts.map +1 -0
  287. package/dist/lib/hooks.d.ts +50 -0
  288. package/dist/lib/hooks.d.ts.map +1 -0
  289. package/dist/lib/importers/index.d.ts +38 -0
  290. package/dist/lib/importers/index.d.ts.map +1 -0
  291. package/dist/lib/injector.d.ts +89 -0
  292. package/dist/lib/injector.d.ts.map +1 -0
  293. package/dist/lib/machine-visibility.d.ts +6 -0
  294. package/dist/lib/machine-visibility.d.ts.map +1 -0
  295. package/dist/lib/matryoshka.d.ts +50 -0
  296. package/dist/lib/matryoshka.d.ts.map +1 -0
  297. package/dist/lib/memory-lock.d.ts +58 -0
  298. package/dist/lib/memory-lock.d.ts.map +1 -0
  299. package/dist/lib/model-config.d.ts +14 -0
  300. package/dist/lib/model-config.d.ts.map +1 -0
  301. package/dist/lib/open-sessions-connector.d.ts +60 -0
  302. package/dist/lib/open-sessions-connector.d.ts.map +1 -0
  303. package/dist/lib/package-version.d.ts +3 -0
  304. package/dist/lib/package-version.d.ts.map +1 -0
  305. package/dist/lib/poisoning.d.ts +19 -0
  306. package/dist/lib/poisoning.d.ts.map +1 -0
  307. package/dist/lib/poll.d.ts +17 -0
  308. package/dist/lib/poll.d.ts.map +1 -0
  309. package/dist/lib/procedural-extractor.d.ts +21 -0
  310. package/dist/lib/procedural-extractor.d.ts.map +1 -0
  311. package/dist/lib/profile-sync.d.ts +20 -0
  312. package/dist/lib/profile-sync.d.ts.map +1 -0
  313. package/dist/lib/profile-synthesizer.d.ts +20 -0
  314. package/dist/lib/profile-synthesizer.d.ts.map +1 -0
  315. package/dist/lib/project-detect.d.ts +18 -0
  316. package/dist/lib/project-detect.d.ts.map +1 -0
  317. package/dist/lib/project-panel.d.ts +7 -0
  318. package/dist/lib/project-panel.d.ts.map +1 -0
  319. package/dist/lib/providers/anthropic.d.ts +21 -0
  320. package/dist/lib/providers/anthropic.d.ts.map +1 -0
  321. package/dist/lib/providers/base.d.ts +96 -0
  322. package/dist/lib/providers/base.d.ts.map +1 -0
  323. package/dist/lib/providers/cerebras.d.ts +20 -0
  324. package/dist/lib/providers/cerebras.d.ts.map +1 -0
  325. package/dist/lib/providers/grok.d.ts +19 -0
  326. package/dist/lib/providers/grok.d.ts.map +1 -0
  327. package/dist/lib/providers/index.d.ts +7 -0
  328. package/dist/lib/providers/index.d.ts.map +1 -0
  329. package/dist/lib/providers/openai-compat.d.ts +18 -0
  330. package/dist/lib/providers/openai-compat.d.ts.map +1 -0
  331. package/dist/lib/providers/openai.d.ts +20 -0
  332. package/dist/lib/providers/openai.d.ts.map +1 -0
  333. package/dist/lib/providers/registry.d.ts +38 -0
  334. package/dist/lib/providers/registry.d.ts.map +1 -0
  335. package/dist/lib/quality.d.ts +16 -0
  336. package/dist/lib/quality.d.ts.map +1 -0
  337. package/dist/lib/redact.d.ts +26 -0
  338. package/dist/lib/redact.d.ts.map +1 -0
  339. package/dist/lib/reflection.d.ts +83 -0
  340. package/dist/lib/reflection.d.ts.map +1 -0
  341. package/dist/lib/retention.d.ts +17 -0
  342. package/dist/lib/retention.d.ts.map +1 -0
  343. package/dist/lib/retired-storage-mode.d.ts +11 -0
  344. package/dist/lib/retired-storage-mode.d.ts.map +1 -0
  345. package/dist/lib/search.d.ts +52 -0
  346. package/dist/lib/search.d.ts.map +1 -0
  347. package/dist/lib/session-auto-resolve.d.ts +28 -0
  348. package/dist/lib/session-auto-resolve.d.ts.map +1 -0
  349. package/dist/lib/session-processor.d.ts +38 -0
  350. package/dist/lib/session-processor.d.ts.map +1 -0
  351. package/dist/lib/session-queue.d.ts +28 -0
  352. package/dist/lib/session-queue.d.ts.map +1 -0
  353. package/dist/lib/session-registry.d.ts +47 -0
  354. package/dist/lib/session-registry.d.ts.map +1 -0
  355. package/dist/lib/session-start-briefing.d.ts +10 -0
  356. package/dist/lib/session-start-briefing.d.ts.map +1 -0
  357. package/dist/lib/session-watcher.d.ts +30 -0
  358. package/dist/lib/session-watcher.d.ts.map +1 -0
  359. package/dist/lib/storage-sync.d.ts +45 -0
  360. package/dist/lib/storage-sync.d.ts.map +1 -0
  361. package/dist/lib/sync.d.ts +10 -0
  362. package/dist/lib/sync.d.ts.map +1 -0
  363. package/dist/lib/synthesis/corpus-builder.d.ts +30 -0
  364. package/dist/lib/synthesis/corpus-builder.d.ts.map +1 -0
  365. package/dist/lib/synthesis/executor.d.ts +14 -0
  366. package/dist/lib/synthesis/executor.d.ts.map +1 -0
  367. package/dist/lib/synthesis/index.d.ts +37 -0
  368. package/dist/lib/synthesis/index.d.ts.map +1 -0
  369. package/dist/lib/synthesis/llm-analyzer.d.ts +18 -0
  370. package/dist/lib/synthesis/llm-analyzer.d.ts.map +1 -0
  371. package/dist/lib/synthesis/metrics.d.ts +13 -0
  372. package/dist/lib/synthesis/metrics.d.ts.map +1 -0
  373. package/dist/lib/synthesis/scheduler.d.ts +18 -0
  374. package/dist/lib/synthesis/scheduler.d.ts.map +1 -0
  375. package/dist/lib/synthesis/validator.d.ts +19 -0
  376. package/dist/lib/synthesis/validator.d.ts.map +1 -0
  377. package/dist/lib/task-runner.d.ts +37 -0
  378. package/dist/lib/task-runner.d.ts.map +1 -0
  379. package/dist/lib/tool-lesson-extractor.d.ts +24 -0
  380. package/dist/lib/tool-lesson-extractor.d.ts.map +1 -0
  381. package/dist/lib/tool-memory-synthesizer.d.ts +28 -0
  382. package/dist/lib/tool-memory-synthesizer.d.ts.map +1 -0
  383. package/dist/lib/topic-clusterer.d.ts +21 -0
  384. package/dist/lib/topic-clusterer.d.ts.map +1 -0
  385. package/dist/lib/when-to-use-generator.d.ts +22 -0
  386. package/dist/lib/when-to-use-generator.d.ts.map +1 -0
  387. package/dist/mcp/http.d.ts +17 -0
  388. package/dist/mcp/http.d.ts.map +1 -0
  389. package/dist/mcp/index.d.ts +6 -0
  390. package/dist/mcp/index.d.ts.map +1 -0
  391. package/dist/mcp/index.js +167 -10
  392. package/dist/mcp/memory-broadcast.d.ts +12 -0
  393. package/dist/mcp/memory-broadcast.d.ts.map +1 -0
  394. package/dist/mcp/tools/agent-tools.d.ts +3 -0
  395. package/dist/mcp/tools/agent-tools.d.ts.map +1 -0
  396. package/dist/mcp/tools/auto-memory-tools.d.ts +5 -0
  397. package/dist/mcp/tools/auto-memory-tools.d.ts.map +1 -0
  398. package/dist/mcp/tools/bulk-tools.d.ts +3 -0
  399. package/dist/mcp/tools/bulk-tools.d.ts.map +1 -0
  400. package/dist/mcp/tools/consolidation-tools.d.ts +3 -0
  401. package/dist/mcp/tools/consolidation-tools.d.ts.map +1 -0
  402. package/dist/mcp/tools/focus-tools.d.ts +3 -0
  403. package/dist/mcp/tools/focus-tools.d.ts.map +1 -0
  404. package/dist/mcp/tools/graph-entity-tools.d.ts +3 -0
  405. package/dist/mcp/tools/graph-entity-tools.d.ts.map +1 -0
  406. package/dist/mcp/tools/graph-query-tools.d.ts +3 -0
  407. package/dist/mcp/tools/graph-query-tools.d.ts.map +1 -0
  408. package/dist/mcp/tools/graph-relation-tools.d.ts +3 -0
  409. package/dist/mcp/tools/graph-relation-tools.d.ts.map +1 -0
  410. package/dist/mcp/tools/graph-tools.d.ts +3 -0
  411. package/dist/mcp/tools/graph-tools.d.ts.map +1 -0
  412. package/dist/mcp/tools/graph-utils.d.ts +5 -0
  413. package/dist/mcp/tools/graph-utils.d.ts.map +1 -0
  414. package/dist/mcp/tools/hook-tools.d.ts +3 -0
  415. package/dist/mcp/tools/hook-tools.d.ts.map +1 -0
  416. package/dist/mcp/tools/lock-tools.d.ts +3 -0
  417. package/dist/mcp/tools/lock-tools.d.ts.map +1 -0
  418. package/dist/mcp/tools/memory-audit.d.ts +3 -0
  419. package/dist/mcp/tools/memory-audit.d.ts.map +1 -0
  420. package/dist/mcp/tools/memory-crud.d.ts +3 -0
  421. package/dist/mcp/tools/memory-crud.d.ts.map +1 -0
  422. package/dist/mcp/tools/memory-health.d.ts +3 -0
  423. package/dist/mcp/tools/memory-health.d.ts.map +1 -0
  424. package/dist/mcp/tools/memory-history.d.ts +3 -0
  425. package/dist/mcp/tools/memory-history.d.ts.map +1 -0
  426. package/dist/mcp/tools/memory-inject.d.ts +3 -0
  427. package/dist/mcp/tools/memory-inject.d.ts.map +1 -0
  428. package/dist/mcp/tools/memory-io.d.ts +3 -0
  429. package/dist/mcp/tools/memory-io.d.ts.map +1 -0
  430. package/dist/mcp/tools/memory-lifecycle.d.ts +3 -0
  431. package/dist/mcp/tools/memory-lifecycle.d.ts.map +1 -0
  432. package/dist/mcp/tools/memory-search.d.ts +3 -0
  433. package/dist/mcp/tools/memory-search.d.ts.map +1 -0
  434. package/dist/mcp/tools/memory-stats.d.ts +3 -0
  435. package/dist/mcp/tools/memory-stats.d.ts.map +1 -0
  436. package/dist/mcp/tools/memory-tools.d.ts +17 -0
  437. package/dist/mcp/tools/memory-tools.d.ts.map +1 -0
  438. package/dist/mcp/tools/memory-utils.d.ts +27 -0
  439. package/dist/mcp/tools/memory-utils.d.ts.map +1 -0
  440. package/dist/mcp/tools/memory-validation.d.ts +3 -0
  441. package/dist/mcp/tools/memory-validation.d.ts.map +1 -0
  442. package/dist/mcp/tools/project-tools.d.ts +3 -0
  443. package/dist/mcp/tools/project-tools.d.ts.map +1 -0
  444. package/dist/mcp/tools/session-tools.d.ts +3 -0
  445. package/dist/mcp/tools/session-tools.d.ts.map +1 -0
  446. package/dist/mcp/tools/storage-tools.d.ts +3 -0
  447. package/dist/mcp/tools/storage-tools.d.ts.map +1 -0
  448. package/dist/mcp/tools/synthesis-tools.d.ts +3 -0
  449. package/dist/mcp/tools/synthesis-tools.d.ts.map +1 -0
  450. package/dist/mcp/tools/system-tools-events.d.ts +3 -0
  451. package/dist/mcp/tools/system-tools-events.d.ts.map +1 -0
  452. package/dist/mcp/tools/system-tools-memory-admin.d.ts +3 -0
  453. package/dist/mcp/tools/system-tools-memory-admin.d.ts.map +1 -0
  454. package/dist/mcp/tools/system-tools-shared.d.ts +23 -0
  455. package/dist/mcp/tools/system-tools-shared.d.ts.map +1 -0
  456. package/dist/mcp/tools/system-tools.d.ts +3 -0
  457. package/dist/mcp/tools/system-tools.d.ts.map +1 -0
  458. package/dist/mcp/tools/tool-registry.d.ts +30 -0
  459. package/dist/mcp/tools/tool-registry.d.ts.map +1 -0
  460. package/dist/mcp/tools/utility-tools.d.ts +3 -0
  461. package/dist/mcp/tools/utility-tools.d.ts.map +1 -0
  462. package/dist/memory-project-link/index.d.ts +2 -0
  463. package/dist/memory-project-link/index.d.ts.map +1 -0
  464. package/dist/memory-project-link/schema.d.ts +5 -0
  465. package/dist/memory-project-link/schema.d.ts.map +1 -0
  466. package/dist/pg-sync-worker.d.ts +2 -0
  467. package/dist/pg-sync-worker.d.ts.map +1 -0
  468. package/dist/project-registration/authority.d.ts +43 -0
  469. package/dist/project-registration/authority.d.ts.map +1 -0
  470. package/dist/project-registration/historical-receipt.d.ts +38 -0
  471. package/dist/project-registration/historical-receipt.d.ts.map +1 -0
  472. package/dist/project-registration/http.d.ts +32 -0
  473. package/dist/project-registration/http.d.ts.map +1 -0
  474. package/dist/project-registration/identity.d.ts +20 -0
  475. package/dist/project-registration/identity.d.ts.map +1 -0
  476. package/dist/project-registration/index.d.ts +11 -0
  477. package/dist/project-registration/index.d.ts.map +1 -0
  478. package/dist/project-registration/project-references.d.ts +71 -0
  479. package/dist/project-registration/project-references.d.ts.map +1 -0
  480. package/dist/project-registration/project-resources.d.ts +22 -0
  481. package/dist/project-registration/project-resources.d.ts.map +1 -0
  482. package/dist/project-registration/schema.d.ts +5 -0
  483. package/dist/project-registration/schema.d.ts.map +1 -0
  484. package/dist/project-registration/types.d.ts +319 -0
  485. package/dist/project-registration/types.d.ts.map +1 -0
  486. package/dist/project-registration.d.ts +2 -0
  487. package/dist/project-registration.d.ts.map +1 -0
  488. package/dist/sdk/index.d.ts +987 -0
  489. package/dist/sdk/index.d.ts.map +1 -0
  490. package/dist/server/auth.d.ts +11 -0
  491. package/dist/server/auth.d.ts.map +1 -0
  492. package/dist/server/helpers.d.ts +22 -0
  493. package/dist/server/helpers.d.ts.map +1 -0
  494. package/dist/server/index.d.ts +14 -0
  495. package/dist/server/index.d.ts.map +1 -0
  496. package/dist/server/index.js +179 -19
  497. package/dist/server/openapi.d.ts +2 -0
  498. package/dist/server/openapi.d.ts.map +1 -0
  499. package/dist/server/router.d.ts +17 -0
  500. package/dist/server/router.d.ts.map +1 -0
  501. package/dist/server/routes/agents.d.ts +2 -0
  502. package/dist/server/routes/agents.d.ts.map +1 -0
  503. package/dist/server/routes/entities.d.ts +2 -0
  504. package/dist/server/routes/entities.d.ts.map +1 -0
  505. package/dist/server/routes/memories-bulk.d.ts +2 -0
  506. package/dist/server/routes/memories-bulk.d.ts.map +1 -0
  507. package/dist/server/routes/memories-crud.d.ts +2 -0
  508. package/dist/server/routes/memories-crud.d.ts.map +1 -0
  509. package/dist/server/routes/memories-io.d.ts +2 -0
  510. package/dist/server/routes/memories-io.d.ts.map +1 -0
  511. package/dist/server/routes/memories-misc.d.ts +2 -0
  512. package/dist/server/routes/memories-misc.d.ts.map +1 -0
  513. package/dist/server/routes/memories-search.d.ts +2 -0
  514. package/dist/server/routes/memories-search.d.ts.map +1 -0
  515. package/dist/server/routes/memories-stats.d.ts +2 -0
  516. package/dist/server/routes/memories-stats.d.ts.map +1 -0
  517. package/dist/server/routes/memories.d.ts +19 -0
  518. package/dist/server/routes/memories.d.ts.map +1 -0
  519. package/dist/server/routes/memory-project-link.d.ts +2 -0
  520. package/dist/server/routes/memory-project-link.d.ts.map +1 -0
  521. package/dist/server/routes/project-registration.d.ts +2 -0
  522. package/dist/server/routes/project-registration.d.ts.map +1 -0
  523. package/dist/server/routes/projects.d.ts +2 -0
  524. package/dist/server/routes/projects.d.ts.map +1 -0
  525. package/dist/server/routes/system-auto-memory.d.ts +2 -0
  526. package/dist/server/routes/system-auto-memory.d.ts.map +1 -0
  527. package/dist/server/routes/system-chain.d.ts +2 -0
  528. package/dist/server/routes/system-chain.d.ts.map +1 -0
  529. package/dist/server/routes/system-consolidation.d.ts +2 -0
  530. package/dist/server/routes/system-consolidation.d.ts.map +1 -0
  531. package/dist/server/routes/system-hooks.d.ts +2 -0
  532. package/dist/server/routes/system-hooks.d.ts.map +1 -0
  533. package/dist/server/routes/system-sessions.d.ts +2 -0
  534. package/dist/server/routes/system-sessions.d.ts.map +1 -0
  535. package/dist/server/routes/system-subscriptions.d.ts +2 -0
  536. package/dist/server/routes/system-subscriptions.d.ts.map +1 -0
  537. package/dist/server/routes/system-synthesis.d.ts +2 -0
  538. package/dist/server/routes/system-synthesis.d.ts.map +1 -0
  539. package/dist/server/routes/system-tools.d.ts +2 -0
  540. package/dist/server/routes/system-tools.d.ts.map +1 -0
  541. package/dist/server/routes/system.d.ts +2 -0
  542. package/dist/server/routes/system.d.ts.map +1 -0
  543. package/dist/server/routes/tasks.d.ts +2 -0
  544. package/dist/server/routes/tasks.d.ts.map +1 -0
  545. package/dist/storage.d.ts +280 -0
  546. package/dist/storage.d.ts.map +1 -0
  547. package/dist/test-support/memories-page-stub-server.d.ts +2 -0
  548. package/dist/test-support/memories-page-stub-server.d.ts.map +1 -0
  549. package/dist/test-support/memories-page-stub.d.ts +28 -0
  550. package/dist/test-support/memories-page-stub.d.ts.map +1 -0
  551. package/dist/test-support/pg-sync-stub-worker.d.ts +2 -0
  552. package/dist/test-support/pg-sync-stub-worker.d.ts.map +1 -0
  553. package/dist/test-support/preload-local-store.d.ts +2 -0
  554. package/dist/test-support/preload-local-store.d.ts.map +1 -0
  555. package/dist/test-support/project-authority-identity.d.ts +8 -0
  556. package/dist/test-support/project-authority-identity.d.ts.map +1 -0
  557. package/dist/test-support/store-isolation.d.ts +108 -0
  558. package/dist/test-support/store-isolation.d.ts.map +1 -0
  559. package/dist/test-support/strip-ansi.d.ts +3 -0
  560. package/dist/test-support/strip-ansi.d.ts.map +1 -0
  561. package/dist/types/hooks.d.ts +136 -0
  562. package/dist/types/hooks.d.ts.map +1 -0
  563. package/dist/types/index.d.ts +482 -0
  564. package/dist/types/index.d.ts.map +1 -0
  565. package/package.json +2 -2
@@ -0,0 +1,987 @@
1
+ /**
2
+ * @hasna/mementos/sdk — Zero-dependency TypeScript client for @hasna/mementos REST API.
3
+ *
4
+ * Import: `import { MementosClient } from "@hasna/mementos/sdk"`
5
+ *
6
+ * Works in Node.js, Bun, Deno, and browsers. No external dependencies beyond fetch.
7
+ */
8
+ export type MemoryScope = "global" | "shared" | "private" | "working";
9
+ export type MemoryCategory = "preference" | "fact" | "knowledge" | "history" | "procedural" | "resource";
10
+ export type MemorySource = "user" | "agent" | "system" | "auto" | "imported";
11
+ export type MemoryStatus = "active" | "archived" | "expired";
12
+ export type EntityType = "person" | "place" | "thing" | "concept" | "project" | "agent" | "file" | "url";
13
+ export type RelationType = "uses" | "knows" | "depends_on" | "created_by" | "related_to" | "contradicts" | "part_of" | "implements" | "happened_before" | "happened_after" | "caused_by" | "resulted_in" | "supersedes" | "version_of";
14
+ export type EntityRole = "subject" | "object" | "context" | "author" | "target";
15
+ export type TaskStatus = "pending" | "in_progress" | "completed" | "failed" | "cancelled";
16
+ export type TaskPriority = "critical" | "high" | "medium" | "low";
17
+ export interface Task {
18
+ id: string;
19
+ subject: string;
20
+ description: string;
21
+ status: TaskStatus;
22
+ priority: TaskPriority;
23
+ tags: string[];
24
+ assigned_agent_id: string | null;
25
+ project_id: string | null;
26
+ session_id: string | null;
27
+ parent_task_id: string | null;
28
+ metadata: Record<string, unknown>;
29
+ progress: number;
30
+ due_at: string | null;
31
+ started_at: string | null;
32
+ completed_at: string | null;
33
+ failed_at: string | null;
34
+ error: string | null;
35
+ created_at: string;
36
+ updated_at: string;
37
+ }
38
+ export interface TaskComment {
39
+ id: string;
40
+ task_id: string;
41
+ agent_id: string | null;
42
+ body: string;
43
+ created_at: string;
44
+ }
45
+ export interface CreateTaskInput {
46
+ subject: string;
47
+ description?: string;
48
+ priority?: TaskPriority;
49
+ tags?: string[];
50
+ assigned_agent_id?: string;
51
+ project_id?: string;
52
+ session_id?: string;
53
+ parent_task_id?: string;
54
+ metadata?: Record<string, unknown>;
55
+ due_at?: string;
56
+ }
57
+ export interface UpdateTaskInput {
58
+ subject?: string;
59
+ description?: string;
60
+ status?: TaskStatus;
61
+ priority?: TaskPriority;
62
+ tags?: string[];
63
+ assigned_agent_id?: string | null;
64
+ metadata?: Record<string, unknown>;
65
+ progress?: number;
66
+ due_at?: string | null;
67
+ error?: string | null;
68
+ }
69
+ export interface TaskStats {
70
+ total: number;
71
+ by_status: Record<TaskStatus, number>;
72
+ by_priority: Record<TaskPriority, number>;
73
+ overdue: number;
74
+ }
75
+ export interface Memory {
76
+ id: string;
77
+ key: string;
78
+ value: string;
79
+ category: MemoryCategory;
80
+ scope: MemoryScope;
81
+ summary: string | null;
82
+ tags: string[];
83
+ importance: number;
84
+ source: MemorySource;
85
+ status: MemoryStatus;
86
+ pinned: boolean;
87
+ agent_id: string | null;
88
+ project_id: string | null;
89
+ session_id: string | null;
90
+ metadata: Record<string, unknown>;
91
+ access_count: number;
92
+ version: number;
93
+ expires_at: string | null;
94
+ created_at: string;
95
+ updated_at: string;
96
+ accessed_at: string | null;
97
+ }
98
+ export interface MemoryVersion {
99
+ id: string;
100
+ memory_id: string;
101
+ version: number;
102
+ value: string;
103
+ importance: number;
104
+ scope: MemoryScope;
105
+ category: MemoryCategory;
106
+ tags: string[];
107
+ summary: string | null;
108
+ pinned: boolean;
109
+ status: MemoryStatus;
110
+ created_at: string;
111
+ }
112
+ export interface Agent {
113
+ id: string;
114
+ name: string;
115
+ role: string | null;
116
+ description: string | null;
117
+ active_project_id?: string | null;
118
+ created_at: string;
119
+ last_seen_at: string | null;
120
+ }
121
+ export interface Project {
122
+ id: string;
123
+ name: string;
124
+ path: string | null;
125
+ description: string | null;
126
+ memory_prefix: string | null;
127
+ created_at: string;
128
+ updated_at: string;
129
+ }
130
+ export type MementosProjectResourceKind = "project" | "knowledge" | "memory" | "session";
131
+ export interface MementosProjectResourceAuthority {
132
+ authority: "mementos";
133
+ authority_id: string;
134
+ tenant_id: string;
135
+ corpus_id: string;
136
+ package_version: string;
137
+ }
138
+ export interface MementosProjectResource {
139
+ authority: "mementos";
140
+ source_package: "@hasna/mementos";
141
+ project_id: string;
142
+ resource_kind: MementosProjectResourceKind;
143
+ stable_id: string;
144
+ revision: string;
145
+ digest: string;
146
+ membership: "project_aggregate" | "explicit_project_id_or_focus";
147
+ }
148
+ export interface MementosProjectResourcePage {
149
+ schema: "mementos.project-resources.v1";
150
+ authority: MementosProjectResourceAuthority;
151
+ project_id: string;
152
+ project_revision: string;
153
+ collection_revision: string;
154
+ resource_kinds: MementosProjectResourceKind[];
155
+ resources: MementosProjectResource[];
156
+ count: number;
157
+ total: number;
158
+ limit: number;
159
+ cursor: string | null;
160
+ next_cursor: string | null;
161
+ has_more: boolean;
162
+ complete: true;
163
+ truncated: false;
164
+ }
165
+ export interface MementosProjectResourceExactResult {
166
+ schema: "mementos.project-resource.v1";
167
+ authority: MementosProjectResourceAuthority;
168
+ project_id: string;
169
+ project_revision: string;
170
+ collection_revision: string;
171
+ resource: MementosProjectResource;
172
+ complete: true;
173
+ truncated: false;
174
+ }
175
+ export interface ListMementosProjectResourcesOptions {
176
+ limit?: number;
177
+ cursor?: string;
178
+ resource_kinds?: MementosProjectResourceKind[];
179
+ }
180
+ export interface ListAllMementosProjectResourcesOptions {
181
+ page_size?: number;
182
+ resource_kinds?: MementosProjectResourceKind[];
183
+ }
184
+ export interface UpdateProjectInput {
185
+ name?: string;
186
+ path?: string;
187
+ description?: string | null;
188
+ memory_prefix?: string | null;
189
+ }
190
+ export interface ProjectAuthorityIdentity {
191
+ authority_id: string;
192
+ tenant_id: string;
193
+ corpus_id: string;
194
+ }
195
+ export interface ProjectGuardedUpdateRequest extends ProjectAuthorityIdentity {
196
+ operation_id: string;
197
+ step_id: string;
198
+ idempotency_key: string;
199
+ expected_revision: string;
200
+ updates: UpdateProjectInput;
201
+ }
202
+ export interface ProjectGuardedRollbackRequest extends ProjectAuthorityIdentity {
203
+ operation_id: string;
204
+ step_id: string;
205
+ idempotency_key: string;
206
+ expected_revision: string;
207
+ accepted_receipt_id: string;
208
+ }
209
+ export interface ProjectUpdateReceipt {
210
+ receipt_id: string;
211
+ authority: "mementos";
212
+ route: "mementos.project-guarded-update.v1";
213
+ package_version: string;
214
+ authority_id: string;
215
+ tenant_id: string;
216
+ corpus_id: string;
217
+ operation_id: string;
218
+ step_id: string;
219
+ direction: "forward" | "rollback";
220
+ idempotency_key: string;
221
+ request_digest: string;
222
+ outcome: "accepted";
223
+ target_id: string;
224
+ expected_revision: string;
225
+ result_revision: string;
226
+ result_digest: string;
227
+ accepted_receipt_id: string | null;
228
+ before_project: Project;
229
+ after_project: Project;
230
+ created_at: string;
231
+ }
232
+ export interface ProjectGuardedUpdateResult {
233
+ dry_run: boolean;
234
+ applied: boolean;
235
+ project: Project;
236
+ receipt: ProjectUpdateReceipt | null;
237
+ }
238
+ export interface MemoryProjectLinkSnapshot {
239
+ memory_id: string;
240
+ project_id: string | null;
241
+ memory_version: number;
242
+ memory_revision: string;
243
+ memory_digest: string;
244
+ }
245
+ export interface MemoryProjectLinkRequest extends ProjectAuthorityIdentity {
246
+ operation_id: string;
247
+ step_id: string;
248
+ idempotency_key: string;
249
+ expected_memory_version: number;
250
+ expected_memory_revision: string;
251
+ target_project_id: string;
252
+ expected_project_revision: string;
253
+ }
254
+ export interface MemoryProjectLinkRollbackRequest extends ProjectAuthorityIdentity {
255
+ operation_id: string;
256
+ step_id: string;
257
+ idempotency_key: string;
258
+ expected_memory_version: number;
259
+ expected_memory_revision: string;
260
+ accepted_receipt_id: string;
261
+ }
262
+ export interface MemoryProjectLinkReceipt {
263
+ receipt_id: string;
264
+ authority: "mementos";
265
+ route: "mementos.memory-project-link.v1";
266
+ package_version: string;
267
+ authority_id: string;
268
+ tenant_id: string;
269
+ corpus_id: string;
270
+ operation_id: string;
271
+ step_id: string;
272
+ direction: "forward" | "rollback";
273
+ idempotency_key: string;
274
+ request_digest: string;
275
+ outcome: "accepted" | "no_change";
276
+ target_memory_id: string;
277
+ requested_project_id: string;
278
+ expected_memory_version: number;
279
+ expected_memory_revision: string;
280
+ expected_project_revision: string | null;
281
+ result_memory_version: number;
282
+ result_memory_revision: string;
283
+ result_memory_digest: string;
284
+ result_project_revision: string | null;
285
+ result_project_digest: string | null;
286
+ accepted_receipt_id: string | null;
287
+ before_link: MemoryProjectLinkSnapshot;
288
+ after_link: MemoryProjectLinkSnapshot;
289
+ before_project_revision: string | null;
290
+ before_project_digest: string | null;
291
+ after_project_revision: string | null;
292
+ after_project_digest: string | null;
293
+ created_at: string;
294
+ }
295
+ export interface MemoryProjectLinkResult {
296
+ dry_run: boolean;
297
+ applied: boolean;
298
+ no_change: boolean;
299
+ memory: Memory;
300
+ project: Project | null;
301
+ receipt: MemoryProjectLinkReceipt | null;
302
+ }
303
+ export interface Entity {
304
+ id: string;
305
+ name: string;
306
+ type: EntityType;
307
+ description: string | null;
308
+ metadata: Record<string, unknown>;
309
+ project_id: string | null;
310
+ created_at: string;
311
+ updated_at: string;
312
+ }
313
+ export interface Relation {
314
+ id: string;
315
+ source_entity_id: string;
316
+ target_entity_id: string;
317
+ relation_type: RelationType;
318
+ weight: number;
319
+ metadata: Record<string, unknown>;
320
+ created_at: string;
321
+ }
322
+ export type ResourceType = "project" | "memory" | "entity" | "agent" | "connector" | "file";
323
+ export type LockType = "advisory" | "exclusive";
324
+ export interface ResourceLock {
325
+ id: string;
326
+ resource_type: ResourceType;
327
+ resource_id: string;
328
+ agent_id: string;
329
+ lock_type: LockType;
330
+ locked_at: string;
331
+ expires_at: string;
332
+ }
333
+ export interface AcquireLockInput {
334
+ agent_id: string;
335
+ resource_type: ResourceType;
336
+ resource_id: string;
337
+ lock_type?: LockType;
338
+ ttl_seconds?: number;
339
+ }
340
+ export interface MemoryStats {
341
+ total: number;
342
+ by_scope: Record<MemoryScope, number>;
343
+ by_category: Record<MemoryCategory, number>;
344
+ by_status: Record<MemoryStatus, number>;
345
+ by_agent: Record<string, number>;
346
+ pinned_count: number;
347
+ /** Rows with status = 'expired' — exactly what `--status expired` returns. */
348
+ expired_count: number;
349
+ /** Rows carrying any expires_at date (future or past). */
350
+ expires_at_count: number;
351
+ /** Retention backlog: status = 'expired' OR expires_at in the past. */
352
+ expired_due_count: number;
353
+ }
354
+ export interface CreateMemoryInput {
355
+ key: string;
356
+ value: string;
357
+ category?: MemoryCategory;
358
+ scope?: MemoryScope;
359
+ summary?: string;
360
+ tags?: string[];
361
+ importance?: number;
362
+ source?: MemorySource;
363
+ agent_id?: string;
364
+ project_id?: string;
365
+ session_id?: string;
366
+ metadata?: Record<string, unknown>;
367
+ expires_at?: string;
368
+ ttl?: string;
369
+ }
370
+ export interface UpdateMemoryInput {
371
+ value?: string;
372
+ category?: MemoryCategory;
373
+ scope?: MemoryScope;
374
+ summary?: string | null;
375
+ tags?: string[];
376
+ importance?: number;
377
+ pinned?: boolean;
378
+ status?: MemoryStatus;
379
+ metadata?: Record<string, unknown>;
380
+ expires_at?: string | null;
381
+ version?: number;
382
+ }
383
+ export interface ListMemoriesFilter {
384
+ scope?: MemoryScope;
385
+ category?: MemoryCategory;
386
+ tags?: string[];
387
+ min_importance?: number;
388
+ pinned?: boolean;
389
+ agent_id?: string;
390
+ project_id?: string;
391
+ session_id?: string;
392
+ namespace?: string;
393
+ status?: MemoryStatus;
394
+ limit?: number;
395
+ offset?: number;
396
+ fields?: string[];
397
+ }
398
+ export interface SearchMemoriesInput {
399
+ query: string;
400
+ scope?: MemoryScope;
401
+ category?: MemoryCategory;
402
+ tags?: string[];
403
+ session_id?: string;
404
+ namespace?: string;
405
+ limit?: number;
406
+ }
407
+ export interface ExportMemoriesInput {
408
+ scope?: MemoryScope;
409
+ category?: MemoryCategory;
410
+ agent_id?: string;
411
+ project_id?: string;
412
+ tags?: string[];
413
+ limit?: number;
414
+ }
415
+ export interface ImportMemoriesInput {
416
+ memories: Partial<Memory>[];
417
+ overwrite?: boolean;
418
+ }
419
+ export interface CreateEntityInput {
420
+ name: string;
421
+ type: EntityType;
422
+ description?: string;
423
+ metadata?: Record<string, unknown>;
424
+ project_id?: string;
425
+ }
426
+ export interface UpdateEntityInput {
427
+ name?: string;
428
+ type?: EntityType;
429
+ description?: string | null;
430
+ metadata?: Record<string, unknown>;
431
+ }
432
+ export interface CreateRelationInput {
433
+ source_entity_id: string;
434
+ target_entity_id: string;
435
+ relation_type: RelationType;
436
+ weight?: number;
437
+ metadata?: Record<string, unknown>;
438
+ }
439
+ export interface ListTasksFilter {
440
+ status?: TaskStatus;
441
+ priority?: TaskPriority;
442
+ assigned_agent_id?: string;
443
+ project_id?: string;
444
+ session_id?: string;
445
+ parent_task_id?: string | null;
446
+ tags?: string[];
447
+ limit?: number;
448
+ offset?: number;
449
+ }
450
+ export interface MementosClientConfig {
451
+ baseUrl?: string;
452
+ fetch?: typeof globalThis.fetch;
453
+ /**
454
+ * API key issued by `contracts issue-key --app mementos`. Sent as both
455
+ * `Authorization: Bearer <key>` and `x-api-key`. Required against a
456
+ * self_hosted deployment with API-key auth enabled.
457
+ */
458
+ apiKey?: string;
459
+ /**
460
+ * Versioned route prefix. Defaults to the canonical `/v1`. The deployed
461
+ * service also serves the legacy `/api` prefix; set `prefix: "/api"` to target
462
+ * it explicitly.
463
+ */
464
+ prefix?: string;
465
+ }
466
+ export declare class MementosError extends Error {
467
+ readonly status: number;
468
+ readonly details?: unknown | undefined;
469
+ constructor(message: string, status: number, details?: unknown | undefined);
470
+ }
471
+ export interface AutoMemoryQueueStats {
472
+ pending: number;
473
+ processing: number;
474
+ processed: number;
475
+ failed: number;
476
+ dropped: number;
477
+ }
478
+ export interface AutoMemoryConfig {
479
+ provider: "anthropic" | "openai" | "cerebras" | "grok";
480
+ model?: string;
481
+ enabled: boolean;
482
+ minImportance: number;
483
+ autoEntityLink: boolean;
484
+ fallback?: Array<"anthropic" | "openai" | "cerebras" | "grok">;
485
+ }
486
+ export interface SdkExtractedMemory {
487
+ content: string;
488
+ category: "preference" | "fact" | "knowledge" | "history";
489
+ importance: number;
490
+ tags: string[];
491
+ suggestedScope: "private" | "shared" | "global";
492
+ reasoning?: string;
493
+ }
494
+ export interface SdkHook {
495
+ id: string;
496
+ type: string;
497
+ blocking: boolean;
498
+ priority: number;
499
+ builtin: boolean;
500
+ agentId?: string;
501
+ projectId?: string;
502
+ description?: string;
503
+ }
504
+ export interface SdkWebhook {
505
+ id: string;
506
+ type: string;
507
+ handlerUrl: string;
508
+ priority: number;
509
+ blocking: boolean;
510
+ agentId?: string;
511
+ projectId?: string;
512
+ description?: string;
513
+ enabled: boolean;
514
+ createdAt: string;
515
+ invocationCount: number;
516
+ failureCount: number;
517
+ }
518
+ export interface SynthesisRun {
519
+ id: string;
520
+ triggered_by: string;
521
+ project_id: string | null;
522
+ agent_id: string | null;
523
+ corpus_size: number;
524
+ proposals_generated: number;
525
+ proposals_accepted: number;
526
+ proposals_rejected: number;
527
+ status: "pending" | "running" | "completed" | "failed" | "rolled_back";
528
+ error: string | null;
529
+ started_at: string;
530
+ completed_at: string | null;
531
+ }
532
+ export interface SynthesisResult {
533
+ run: SynthesisRun;
534
+ proposals: unknown[];
535
+ executed: number;
536
+ metrics: {
537
+ corpusReduction: number;
538
+ deduplicationRate: number;
539
+ } | null;
540
+ dryRun: boolean;
541
+ }
542
+ export interface SessionMemoryJob {
543
+ id: string;
544
+ session_id: string;
545
+ agent_id: string | null;
546
+ project_id: string | null;
547
+ source: string;
548
+ status: "pending" | "processing" | "completed" | "failed";
549
+ transcript: string;
550
+ chunk_count: number;
551
+ memories_extracted: number;
552
+ error: string | null;
553
+ metadata: Record<string, unknown>;
554
+ created_at: string;
555
+ started_at: string | null;
556
+ completed_at: string | null;
557
+ }
558
+ export declare class MementosClient {
559
+ private baseUrl;
560
+ private _fetch;
561
+ private apiKey?;
562
+ private prefix;
563
+ constructor(config?: MementosClientConfig);
564
+ static fromEnv(overrides?: Partial<MementosClientConfig>): MementosClient;
565
+ private request;
566
+ private get;
567
+ private post;
568
+ private patch;
569
+ private delete;
570
+ listMemories(filter?: ListMemoriesFilter): Promise<{
571
+ memories: Memory[];
572
+ count: number;
573
+ total?: number;
574
+ has_more?: boolean;
575
+ next_cursor?: number | null;
576
+ }>;
577
+ getStats(): Promise<MemoryStats>;
578
+ getHealth(): Promise<{
579
+ status: "ok" | "warn";
580
+ version: string;
581
+ mode: "local" | "cloud";
582
+ profile: string;
583
+ db_path: string;
584
+ hostname: string;
585
+ memories: {
586
+ total: number;
587
+ /** Rows with status = 'expired' — exactly what `--status expired` returns. */
588
+ expired: number;
589
+ /** Retention backlog: status = 'expired' OR expires_at in the past (drives the warn gate). */
590
+ expired_due: number;
591
+ pinned: number;
592
+ };
593
+ agents: number;
594
+ projects: number;
595
+ }>;
596
+ /** Liveness/readiness probe — verifies backing-store connectivity. */
597
+ getReady(): Promise<{
598
+ status: "ready" | "not_ready";
599
+ version: string;
600
+ mode: "local" | "cloud";
601
+ }>;
602
+ /** Service version + storage mode. */
603
+ getVersion(): Promise<{
604
+ status: "ok";
605
+ version: string;
606
+ mode: "local" | "cloud";
607
+ }>;
608
+ getReport(options?: {
609
+ days?: number;
610
+ project_id?: string;
611
+ agent_id?: string;
612
+ }): Promise<{
613
+ total: number;
614
+ pinned: number;
615
+ days: number;
616
+ recent: {
617
+ total: number;
618
+ activity: {
619
+ date: string;
620
+ memories_created: number;
621
+ }[];
622
+ };
623
+ by_scope: Record<string, number>;
624
+ by_category: Record<string, number>;
625
+ top_memories: {
626
+ id: string;
627
+ key: string;
628
+ value: string;
629
+ importance: number;
630
+ scope: string;
631
+ category: string;
632
+ }[];
633
+ top_agents: {
634
+ agent_id: string;
635
+ c: number;
636
+ }[];
637
+ }>;
638
+ getStaleMemories(options?: {
639
+ days?: number;
640
+ pinned?: boolean;
641
+ project_id?: string;
642
+ agent_id?: string;
643
+ limit?: number;
644
+ offset?: number;
645
+ }): Promise<{
646
+ memories: Memory[];
647
+ count: number;
648
+ days: number;
649
+ total?: number;
650
+ has_more?: boolean;
651
+ next_cursor?: number | null;
652
+ }>;
653
+ getActivity(options?: {
654
+ days?: number;
655
+ scope?: MemoryScope;
656
+ agent_id?: string;
657
+ project_id?: string;
658
+ }): Promise<{
659
+ activity: {
660
+ date: string;
661
+ memories_created: number;
662
+ global_count: number;
663
+ shared_count: number;
664
+ private_count: number;
665
+ avg_importance: number;
666
+ }[];
667
+ days: number;
668
+ total: number;
669
+ }>;
670
+ searchMemories(input: SearchMemoriesInput | string): Promise<{
671
+ results: Memory[];
672
+ count: number;
673
+ }>;
674
+ exportMemories(input?: ExportMemoriesInput): Promise<{
675
+ memories: Memory[];
676
+ count: number;
677
+ }>;
678
+ importMemories(input: ImportMemoriesInput): Promise<{
679
+ imported: number;
680
+ errors: string[];
681
+ total: number;
682
+ }>;
683
+ cleanExpired(): Promise<{
684
+ cleaned: number;
685
+ }>;
686
+ extractFromSession(input: {
687
+ session_id: string;
688
+ title?: string;
689
+ project?: string;
690
+ model?: string;
691
+ messages?: number;
692
+ key_topics?: string[];
693
+ summary?: string;
694
+ agent_id?: string;
695
+ project_id?: string;
696
+ memories?: Partial<CreateMemoryInput>[];
697
+ }): Promise<{
698
+ created: number;
699
+ memory_ids: string[];
700
+ errors: string[];
701
+ session_id: string;
702
+ }>;
703
+ saveMemory(input: CreateMemoryInput): Promise<Memory>;
704
+ getMemory(id: string): Promise<Memory>;
705
+ getMemoryVersions(id: string): Promise<{
706
+ versions: MemoryVersion[];
707
+ count: number;
708
+ current_version: number;
709
+ }>;
710
+ updateMemory(id: string, input: UpdateMemoryInput): Promise<Memory>;
711
+ deleteMemory(id: string): Promise<{
712
+ deleted: boolean;
713
+ }>;
714
+ listAgents(): Promise<{
715
+ agents: Agent[];
716
+ }>;
717
+ registerAgent(input: {
718
+ name: string;
719
+ role?: string;
720
+ description?: string;
721
+ }): Promise<Agent>;
722
+ getAgent(idOrName: string): Promise<Agent>;
723
+ updateAgent(idOrName: string, updates: {
724
+ name?: string;
725
+ role?: string;
726
+ description?: string;
727
+ metadata?: Record<string, unknown>;
728
+ active_project_id?: string | null;
729
+ }): Promise<Agent>;
730
+ listAgentsByProject(projectId: string): Promise<{
731
+ agents: Agent[];
732
+ count: number;
733
+ }>;
734
+ listProjects(): Promise<{
735
+ projects: Project[];
736
+ }>;
737
+ registerProject(input: {
738
+ name: string;
739
+ path?: string;
740
+ description?: string;
741
+ memory_prefix?: string;
742
+ }): Promise<Project>;
743
+ getProject(idOrName: string): Promise<Project>;
744
+ listProjectResources(projectId: string, options?: ListMementosProjectResourcesOptions): Promise<MementosProjectResourcePage>;
745
+ listAllProjectResources(projectId: string, options?: ListAllMementosProjectResourcesOptions): Promise<MementosProjectResourcePage>;
746
+ getProjectResource(projectId: string, resourceKind: MementosProjectResourceKind, stableId: string): Promise<MementosProjectResourceExactResult>;
747
+ updateProject(id: string, request: ProjectGuardedUpdateRequest): Promise<ProjectGuardedUpdateResult>;
748
+ previewProjectUpdate(id: string, request: ProjectGuardedUpdateRequest): Promise<ProjectGuardedUpdateResult>;
749
+ rollbackProjectUpdate(id: string, request: ProjectGuardedRollbackRequest): Promise<ProjectGuardedUpdateResult>;
750
+ getProjectUpdateReceipt(id: string, receiptId: string, identity: ProjectAuthorityIdentity): Promise<ProjectUpdateReceipt>;
751
+ linkMemoryProject(memoryId: string, request: MemoryProjectLinkRequest): Promise<MemoryProjectLinkResult>;
752
+ previewMemoryProjectLink(memoryId: string, request: MemoryProjectLinkRequest): Promise<MemoryProjectLinkResult>;
753
+ rollbackMemoryProjectLink(memoryId: string, request: MemoryProjectLinkRollbackRequest): Promise<MemoryProjectLinkResult>;
754
+ getMemoryProjectLinkReceipt(memoryId: string, receiptId: string, identity: ProjectAuthorityIdentity): Promise<MemoryProjectLinkReceipt>;
755
+ getProjectAgents(idOrName: string): Promise<{
756
+ agents: Agent[];
757
+ count: number;
758
+ }>;
759
+ listEntities(filter?: {
760
+ type?: EntityType;
761
+ limit?: number;
762
+ offset?: number;
763
+ }): Promise<{
764
+ entities: Entity[];
765
+ count: number;
766
+ }>;
767
+ createEntity(input: CreateEntityInput): Promise<Entity>;
768
+ mergeEntities(input: {
769
+ source_id: string;
770
+ target_id: string;
771
+ }): Promise<Entity>;
772
+ getEntity(id: string): Promise<Entity>;
773
+ updateEntity(id: string, input: UpdateEntityInput): Promise<Entity>;
774
+ deleteEntity(id: string): Promise<{
775
+ deleted: boolean;
776
+ }>;
777
+ getEntityMemories(entityId: string): Promise<{
778
+ memories: Memory[];
779
+ count: number;
780
+ }>;
781
+ linkEntityMemory(entityId: string, input: {
782
+ memory_id: string;
783
+ role?: EntityRole;
784
+ }): Promise<{
785
+ linked: boolean;
786
+ }>;
787
+ unlinkEntityMemory(entityId: string, memoryId: string): Promise<{
788
+ unlinked: boolean;
789
+ }>;
790
+ getEntityRelations(entityId: string, filter?: {
791
+ relation_type?: RelationType;
792
+ direction?: "from" | "to" | "both";
793
+ }): Promise<{
794
+ relations: Relation[];
795
+ }>;
796
+ createRelation(input: CreateRelationInput): Promise<Relation>;
797
+ getRelation(id: string): Promise<Relation>;
798
+ deleteRelation(id: string): Promise<{
799
+ deleted: boolean;
800
+ }>;
801
+ getGraph(entityId: string, options?: {
802
+ depth?: number;
803
+ relation_types?: RelationType[];
804
+ }): Promise<{
805
+ nodes: Entity[];
806
+ edges: Relation[];
807
+ }>;
808
+ findPath(fromId: string, toId: string): Promise<{
809
+ path: Entity[];
810
+ found: boolean;
811
+ }>;
812
+ getGraphStats(): Promise<{
813
+ entity_count: number;
814
+ relation_count: number;
815
+ by_type: Record<string, number>;
816
+ }>;
817
+ acquireLock(input: AcquireLockInput): Promise<ResourceLock | null>;
818
+ checkLock(resourceType: ResourceType, resourceId: string, lockType?: LockType): Promise<ResourceLock[]>;
819
+ releaseLock(lockId: string, agentId: string): Promise<{
820
+ released: boolean;
821
+ }>;
822
+ listAgentLocks(agentId: string): Promise<ResourceLock[]>;
823
+ releaseAllAgentLocks(agentId: string): Promise<{
824
+ released: number;
825
+ }>;
826
+ cleanExpiredLocks(): Promise<{
827
+ cleaned: number;
828
+ }>;
829
+ /** Create a task. */
830
+ createTask(input: CreateTaskInput): Promise<Task>;
831
+ /** List tasks with optional filters. */
832
+ listTasks(filter?: ListTasksFilter): Promise<{
833
+ tasks: Task[];
834
+ count: number;
835
+ }>;
836
+ /** Get task stats (by status, priority, overdue). */
837
+ getTaskStats(options?: {
838
+ project_id?: string;
839
+ agent_id?: string;
840
+ }): Promise<TaskStats>;
841
+ /** Get a task by ID. */
842
+ getTask(id: string): Promise<Task>;
843
+ /** Update a task. */
844
+ updateTask(id: string, input: UpdateTaskInput): Promise<Task>;
845
+ /** Delete a task. */
846
+ deleteTask(id: string): Promise<{
847
+ deleted: boolean;
848
+ }>;
849
+ /** List comments on a task. */
850
+ listTaskComments(taskId: string): Promise<{
851
+ comments: TaskComment[];
852
+ count: number;
853
+ }>;
854
+ /** Add a comment to a task. */
855
+ addTaskComment(taskId: string, body: string, agentId?: string): Promise<TaskComment>;
856
+ /** Delete a task comment. */
857
+ deleteTaskComment(taskId: string, commentId: string): Promise<{
858
+ deleted: boolean;
859
+ }>;
860
+ getContext(options?: {
861
+ agent_id?: string;
862
+ project_id?: string;
863
+ max_tokens?: number;
864
+ format?: "xml" | "markdown" | "compact" | "json";
865
+ }): Promise<{
866
+ context: string;
867
+ memories_count: number;
868
+ }>;
869
+ processConversationTurn(turn: string, context?: {
870
+ agent_id?: string;
871
+ project_id?: string;
872
+ session_id?: string;
873
+ }): Promise<{
874
+ queued: boolean;
875
+ queue: AutoMemoryQueueStats;
876
+ }>;
877
+ getAutoMemoryStatus(): Promise<{
878
+ queue: AutoMemoryQueueStats;
879
+ config: AutoMemoryConfig;
880
+ providers: Record<string, {
881
+ available: boolean;
882
+ model: string;
883
+ }>;
884
+ }>;
885
+ configureAutoMemory(config: Partial<AutoMemoryConfig> & {
886
+ min_importance?: number;
887
+ auto_entity_link?: boolean;
888
+ }): Promise<{
889
+ updated: boolean;
890
+ config: AutoMemoryConfig;
891
+ }>;
892
+ testExtraction(turn: string, options?: {
893
+ provider?: "anthropic" | "openai" | "cerebras" | "grok";
894
+ agent_id?: string;
895
+ project_id?: string;
896
+ }): Promise<{
897
+ provider: string;
898
+ model: string;
899
+ extracted: SdkExtractedMemory[];
900
+ count: number;
901
+ note: string;
902
+ }>;
903
+ listHooks(type?: string): Promise<SdkHook[]>;
904
+ getHookStats(): Promise<{
905
+ total: number;
906
+ byType: Record<string, number>;
907
+ blocking: number;
908
+ nonBlocking: number;
909
+ }>;
910
+ listWebhooks(filter?: {
911
+ type?: string;
912
+ enabled?: boolean;
913
+ }): Promise<SdkWebhook[]>;
914
+ createWebhook(input: {
915
+ type: string;
916
+ handler_url: string;
917
+ priority?: number;
918
+ blocking?: boolean;
919
+ agent_id?: string;
920
+ project_id?: string;
921
+ description?: string;
922
+ }): Promise<SdkWebhook>;
923
+ getWebhook(id: string): Promise<SdkWebhook>;
924
+ updateWebhook(id: string, updates: {
925
+ enabled?: boolean;
926
+ priority?: number;
927
+ description?: string;
928
+ }): Promise<SdkWebhook>;
929
+ deleteWebhook(id: string): Promise<void>;
930
+ enableWebhook(id: string): Promise<SdkWebhook>;
931
+ disableWebhook(id: string): Promise<SdkWebhook>;
932
+ runSynthesis(options?: {
933
+ project_id?: string;
934
+ agent_id?: string;
935
+ dry_run?: boolean;
936
+ max_proposals?: number;
937
+ provider?: string;
938
+ }): Promise<SynthesisResult>;
939
+ listSynthesisRuns(filter?: {
940
+ project_id?: string;
941
+ limit?: number;
942
+ }): Promise<{
943
+ runs: SynthesisRun[];
944
+ count: number;
945
+ }>;
946
+ getSynthesisStatus(options?: {
947
+ project_id?: string;
948
+ run_id?: string;
949
+ }): Promise<{
950
+ lastRun: SynthesisRun | null;
951
+ recentRuns: SynthesisRun[];
952
+ }>;
953
+ rollbackSynthesis(runId: string): Promise<{
954
+ rolled_back: number;
955
+ errors: string[];
956
+ }>;
957
+ ingestSession(input: {
958
+ transcript: string;
959
+ session_id: string;
960
+ agent_id?: string;
961
+ project_id?: string;
962
+ source?: "claude-code" | "codex" | "manual" | "open-sessions";
963
+ metadata?: Record<string, unknown>;
964
+ }): Promise<{
965
+ job_id: string;
966
+ status: string;
967
+ message: string;
968
+ }>;
969
+ getSessionJob(jobId: string): Promise<SessionMemoryJob>;
970
+ listSessionJobs(filter?: {
971
+ agent_id?: string;
972
+ project_id?: string;
973
+ status?: string;
974
+ limit?: number;
975
+ }): Promise<{
976
+ jobs: SessionMemoryJob[];
977
+ count: number;
978
+ }>;
979
+ getSessionQueueStats(): Promise<{
980
+ pending: number;
981
+ processing: number;
982
+ completed: number;
983
+ failed: number;
984
+ }>;
985
+ }
986
+ export default MementosClient;
987
+ //# sourceMappingURL=index.d.ts.map