@remnic/core 9.15.3 → 9.16.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 (311) hide show
  1. package/dist/access-admin-ops-surface.d.ts +8 -8
  2. package/dist/access-admin-ops-surface.js +7 -7
  3. package/dist/access-boundary.d.ts +8 -8
  4. package/dist/access-boundary.js +7 -7
  5. package/dist/access-cli.js +31 -30
  6. package/dist/access-cli.js.map +1 -1
  7. package/dist/access-http.d.ts +8 -8
  8. package/dist/access-http.js +11 -11
  9. package/dist/access-identity-continuity-surface.d.ts +6 -6
  10. package/dist/access-identity-continuity-surface.js +7 -7
  11. package/dist/access-lcm-surface.d.ts +8 -8
  12. package/dist/access-lcm-surface.js +7 -7
  13. package/dist/access-mcp.d.ts +8 -8
  14. package/dist/access-mcp.js +10 -10
  15. package/dist/access-memory-search-fanout.d.ts +2 -2
  16. package/dist/{access-namespace-preflight-B9e5GnyZ.d.ts → access-namespace-preflight-DwhEFYy3.d.ts} +1 -1
  17. package/dist/access-namespace-preflight.d.ts +3 -3
  18. package/dist/access-namespace-preflight.js +7 -7
  19. package/dist/access-observe-write-surface.d.ts +8 -8
  20. package/dist/access-observe-write-surface.js +7 -7
  21. package/dist/access-operations-batch.js +8 -8
  22. package/dist/access-operations.d.ts +8 -8
  23. package/dist/access-operations.js +9 -9
  24. package/dist/access-recall-concurrency.d.ts +8 -8
  25. package/dist/access-recall-concurrency.js +7 -7
  26. package/dist/access-recall-response.d.ts +8 -8
  27. package/dist/access-recall-response.js +7 -7
  28. package/dist/access-recall-surface.d.ts +8 -8
  29. package/dist/access-recall-surface.js +7 -7
  30. package/dist/{access-service-DgmJd_A-.d.ts → access-service-CSq1Wp2Z.d.ts} +6 -6
  31. package/dist/access-service.d.ts +8 -8
  32. package/dist/access-service.js +7 -7
  33. package/dist/access-surface-catalog.d.ts +8 -8
  34. package/dist/action-confidence.d.ts +1 -1
  35. package/dist/active-memory-bridge.d.ts +1 -1
  36. package/dist/active-recall.d.ts +1 -1
  37. package/dist/active-recall.js +2 -1
  38. package/dist/active-recall.js.map +1 -1
  39. package/dist/behavior-learner.d.ts +1 -1
  40. package/dist/behavior-signals.d.ts +1 -1
  41. package/dist/bootstrap.d.ts +6 -6
  42. package/dist/briefing.d.ts +2 -2
  43. package/dist/briefing.js +3 -3
  44. package/dist/buffer-surprise-report.d.ts +1 -1
  45. package/dist/buffer.d.ts +2 -2
  46. package/dist/bulk-import/index.d.ts +3 -3
  47. package/dist/calibration.d.ts +1 -1
  48. package/dist/capabilities.d.ts +1 -1
  49. package/dist/{catalog-g_dfT6oL.d.ts → catalog-B9uga4sG.d.ts} +1 -1
  50. package/dist/causal-behavior.d.ts +1 -1
  51. package/dist/causal-consolidation.d.ts +1 -1
  52. package/dist/causal-consolidation.js +4 -4
  53. package/dist/causal-trajectory-graph.d.ts +1 -1
  54. package/dist/{chunk-IRX5UCGN.js → chunk-2OH3ZRYH.js} +3 -3
  55. package/dist/{chunk-YXTSUIXC.js → chunk-5EKOBRCA.js} +6 -1
  56. package/dist/chunk-5EKOBRCA.js.map +1 -0
  57. package/dist/{chunk-42DJZZUB.js → chunk-7LXSPIVG.js} +2 -2
  58. package/dist/{chunk-47WFEKT7.js → chunk-7PK4W4RN.js} +2 -2
  59. package/dist/{chunk-O7ACJAHR.js → chunk-7YJLCNPF.js} +2 -2
  60. package/dist/{chunk-6EJL2O3G.js → chunk-AFH7PIFU.js} +2 -2
  61. package/dist/{chunk-JN4N2TMQ.js → chunk-ANGUOE2N.js} +7 -7
  62. package/dist/{chunk-GQOKO77V.js → chunk-AWT7SCWQ.js} +2 -2
  63. package/dist/{chunk-PXJEL55X.js → chunk-BIRPR5N7.js} +2 -2
  64. package/dist/{chunk-NAY25BGS.js → chunk-BTK2PIFL.js} +6 -6
  65. package/dist/{chunk-SYCVU556.js → chunk-C2RMQRPN.js} +3 -3
  66. package/dist/{chunk-T4EAQPQQ.js → chunk-G2WCVFDC.js} +2 -2
  67. package/dist/{chunk-UJIBXOJA.js → chunk-GEDBTSYU.js} +5 -5
  68. package/dist/{chunk-CXFVZ3PK.js → chunk-GRJ5UOFO.js} +84 -658
  69. package/dist/chunk-GRJ5UOFO.js.map +1 -0
  70. package/dist/chunk-GSQASASV.js +429 -0
  71. package/dist/chunk-GSQASASV.js.map +1 -0
  72. package/dist/{chunk-WIKOHCQZ.js → chunk-I6ODVWQB.js} +2 -2
  73. package/dist/{chunk-H4MDUPER.js → chunk-IZHXSLO7.js} +2 -2
  74. package/dist/{chunk-RRS5CDB6.js → chunk-JOCXI2O5.js} +2 -2
  75. package/dist/{chunk-EEUZQQRJ.js → chunk-KGKYTCDO.js} +2 -2
  76. package/dist/{chunk-JTW4TGPV.js → chunk-L3HAUO7K.js} +2 -2
  77. package/dist/{chunk-P53HGVJS.js → chunk-LMVAIZR5.js} +2 -2
  78. package/dist/{chunk-KLXG4BBO.js → chunk-M6TZQDTX.js} +2 -2
  79. package/dist/{chunk-FJ5IQ3SI.js → chunk-N7DK67GZ.js} +1 -1
  80. package/dist/chunk-N7DK67GZ.js.map +1 -0
  81. package/dist/{chunk-U6QWUFSM.js → chunk-OXT5TQDS.js} +2 -2
  82. package/dist/{chunk-T4OTDMX4.js → chunk-QDTEH6BS.js} +2 -2
  83. package/dist/{chunk-5MDE5MIC.js → chunk-SESF64QR.js} +2 -2
  84. package/dist/{chunk-4E5H4FPC.js → chunk-TUNI4GB3.js} +3 -3
  85. package/dist/{chunk-XJT6LNLY.js → chunk-V6LYAXGW.js} +834 -25
  86. package/dist/chunk-V6LYAXGW.js.map +1 -0
  87. package/dist/{chunk-5HFIHWOF.js → chunk-VLIY55Q5.js} +17 -17
  88. package/dist/{chunk-BNH2VVWP.js → chunk-WIS5JTJR.js} +2 -2
  89. package/dist/{chunk-OOGGUXAG.js → chunk-WQ2I6ODB.js} +2 -2
  90. package/dist/{cli-BXCd2cgK.d.ts → cli-DYLGXxuu.d.ts} +5 -5
  91. package/dist/cli.d.ts +10 -10
  92. package/dist/cli.js +25 -24
  93. package/dist/compounding/engine.d.ts +2 -2
  94. package/dist/compounding/engine.js +3 -3
  95. package/dist/compounding/preference-consolidator.d.ts +1 -1
  96. package/dist/compression-optimizer.d.ts +1 -1
  97. package/dist/config.d.ts +1 -1
  98. package/dist/config.js +2 -1
  99. package/dist/connectors/codex-materialize-runner.d.ts +1 -1
  100. package/dist/connectors/codex-materialize-runner.js +3 -3
  101. package/dist/connectors/codex-materialize.d.ts +1 -1
  102. package/dist/connectors/index.d.ts +1 -1
  103. package/dist/connectors/index.js +3 -3
  104. package/dist/consolidation-provenance-check.d.ts +2 -2
  105. package/dist/consolidation-undo.d.ts +2 -2
  106. package/dist/contradiction/index.d.ts +2 -2
  107. package/dist/conversation-index/backend.d.ts +1 -1
  108. package/dist/conversation-index/chunker.d.ts +1 -1
  109. package/dist/conversation-index/faiss-adapter.d.ts +1 -1
  110. package/dist/conversation-index/indexer.d.ts +1 -1
  111. package/dist/conversation-index/search.d.ts +1 -1
  112. package/dist/day-summary.d.ts +1 -1
  113. package/dist/delinearize.d.ts +1 -1
  114. package/dist/direct-answer-wiring.d.ts +1 -1
  115. package/dist/direct-answer.d.ts +1 -1
  116. package/dist/embedding-fallback.d.ts +1 -1
  117. package/dist/enrichment/index.d.ts +1 -1
  118. package/dist/entity-retrieval.d.ts +2 -2
  119. package/dist/entity-retrieval.js +3 -3
  120. package/dist/entity-schema.d.ts +1 -1
  121. package/dist/explicit-capture.d.ts +6 -6
  122. package/dist/extraction-faithfulness.d.ts +1 -1
  123. package/dist/extraction-judge-telemetry.d.ts +1 -1
  124. package/dist/extraction-judge-training.d.ts +1 -1
  125. package/dist/extraction-judge.d.ts +1 -1
  126. package/dist/extraction.d.ts +1 -1
  127. package/dist/fallback-llm.d.ts +1 -1
  128. package/dist/graph-dashboard-diff.d.ts +1 -1
  129. package/dist/graph-dashboard-key.d.ts +1 -1
  130. package/dist/graph-dashboard-parser.d.ts +1 -1
  131. package/dist/graph-edge-reinforcement.d.ts +1 -1
  132. package/dist/graph-snapshot.d.ts +1 -1
  133. package/dist/graph.d.ts +1 -1
  134. package/dist/importance.d.ts +1 -1
  135. package/dist/importers/index.d.ts +1 -1
  136. package/dist/in-flight-reads.d.ts +1 -1
  137. package/dist/index.d.ts +289 -99
  138. package/dist/index.js +70 -45
  139. package/dist/intent.d.ts +1 -1
  140. package/dist/lcm/engine.d.ts +1 -1
  141. package/dist/lcm/index.d.ts +1 -1
  142. package/dist/lcm/tools.d.ts +1 -1
  143. package/dist/lifecycle.d.ts +1 -1
  144. package/dist/live-connectors-runner.d.ts +1 -1
  145. package/dist/local-llm.d.ts +1 -1
  146. package/dist/local-model-endpoint.d.ts +1 -1
  147. package/dist/maintenance/memory-governance.d.ts +1 -1
  148. package/dist/maintenance/memory-governance.js +3 -3
  149. package/dist/maintenance/rebuild-memory-lifecycle-ledger.d.ts +2 -2
  150. package/dist/maintenance/rebuild-memory-lifecycle-ledger.js +3 -3
  151. package/dist/maintenance/rebuild-memory-projection.js +4 -4
  152. package/dist/mcp-memory-inspector-app.d.ts +8 -8
  153. package/dist/memory-action-policy.d.ts +1 -1
  154. package/dist/memory-cache.d.ts +1 -1
  155. package/dist/memory-lifecycle-ledger-utils.d.ts +1 -1
  156. package/dist/memory-projection-store.d.ts +1 -1
  157. package/dist/memory-provenance.d.ts +1 -1
  158. package/dist/memory-worth-outcomes.d.ts +2 -2
  159. package/dist/models-json.d.ts +1 -1
  160. package/dist/namespaces/migrate.d.ts +3 -3
  161. package/dist/namespaces/migrate.js +4 -4
  162. package/dist/namespaces/principal.d.ts +1 -1
  163. package/dist/namespaces/search.d.ts +1 -1
  164. package/dist/namespaces/storage.d.ts +3 -3
  165. package/dist/namespaces/storage.js +3 -3
  166. package/dist/native-knowledge.d.ts +1 -1
  167. package/dist/offline-sync-impression-drain.d.ts +1 -1
  168. package/dist/operator-toolkit.d.ts +2 -2
  169. package/dist/operator-toolkit.js +9 -8
  170. package/dist/orchestration/compression-guideline-coordinator.d.ts +2 -2
  171. package/dist/orchestration/maintenance.d.ts +10 -7
  172. package/dist/orchestration/maintenance.js +7 -6
  173. package/dist/{orchestrator-BHfWtvEJ.d.ts → orchestrator-BHx-DWCa.d.ts} +7 -5
  174. package/dist/orchestrator.d.ts +6 -6
  175. package/dist/orchestrator.js +31 -30
  176. package/dist/patterns-cli.d.ts +1 -1
  177. package/dist/{pipeline-CBYcnmDC.d.ts → pipeline-DDHSE876.d.ts} +1 -1
  178. package/dist/policy-runtime.d.ts +1 -1
  179. package/dist/proactive-contention.d.ts +1 -1
  180. package/dist/provenance.d.ts +1 -1
  181. package/dist/{qmd-BIq-jrV4.d.ts → qmd-C4WVh6BM.d.ts} +1 -1
  182. package/dist/qmd-preflight.d.ts +2 -2
  183. package/dist/qmd-recall-cache.d.ts +1 -1
  184. package/dist/qmd.d.ts +2 -2
  185. package/dist/recall-concurrency-config.d.ts +1 -1
  186. package/dist/recall-disclosure-escalation.d.ts +1 -1
  187. package/dist/recall-explain-renderer.d.ts +1 -1
  188. package/dist/recall-explain-renderer.js +3 -3
  189. package/dist/recall-memory-map.d.ts +1 -1
  190. package/dist/recall-planner-llm.d.ts +1 -1
  191. package/dist/recall-state.d.ts +1 -1
  192. package/dist/recall-tag-filter.d.ts +1 -1
  193. package/dist/recall-timings.d.ts +1 -1
  194. package/dist/recall-xray-cli.d.ts +1 -1
  195. package/dist/recall-xray-cli.js +4 -4
  196. package/dist/recall-xray-renderer.d.ts +1 -1
  197. package/dist/recall-xray-renderer.js +3 -3
  198. package/dist/recall-xray.d.ts +1 -1
  199. package/dist/recall-xray.js +2 -2
  200. package/dist/replay/normalizers/chatgpt.d.ts +1 -1
  201. package/dist/replay/normalizers/claude.d.ts +1 -1
  202. package/dist/replay/normalizers/openclaw.d.ts +1 -1
  203. package/dist/replay/normalizers/shared.d.ts +1 -1
  204. package/dist/replay/runner.d.ts +1 -1
  205. package/dist/replay/types.d.ts +1 -1
  206. package/dist/resolve-auth-token.d.ts +1 -1
  207. package/dist/resume-bundles.js +3 -2
  208. package/dist/retrieval-agents.d.ts +2 -2
  209. package/dist/retrieval-tiers.d.ts +1 -1
  210. package/dist/routing/engine.d.ts +1 -1
  211. package/dist/routing/store.d.ts +1 -1
  212. package/dist/salvage-envelope.d.ts +1 -1
  213. package/dist/{scope-profiles-DDno-uvy.d.ts → scope-profiles-EqMXwzCz.d.ts} +1 -1
  214. package/dist/search/embed-helper.d.ts +1 -1
  215. package/dist/search/factory.d.ts +1 -1
  216. package/dist/search/index.d.ts +1 -1
  217. package/dist/search/lancedb-backend.d.ts +1 -1
  218. package/dist/search/meilisearch-backend.d.ts +1 -1
  219. package/dist/search/noop-backend.d.ts +1 -1
  220. package/dist/search/orama-backend.d.ts +1 -1
  221. package/dist/search/port.d.ts +1 -1
  222. package/dist/search/remote-backend.d.ts +1 -1
  223. package/dist/{semantic-consolidation-7RIJFDwY.d.ts → semantic-consolidation-CYpvwmQc.d.ts} +1 -1
  224. package/dist/semantic-consolidation.d.ts +2 -2
  225. package/dist/semantic-consolidation.js +4 -4
  226. package/dist/semantic-rule-promotion.js +3 -3
  227. package/dist/semantic-rule-verifier.d.ts +1 -1
  228. package/dist/semantic-rule-verifier.js +3 -3
  229. package/dist/session-observer-bands.d.ts +1 -1
  230. package/dist/session-observer-state.d.ts +1 -1
  231. package/dist/shared-context/manager.d.ts +1 -1
  232. package/dist/signal.d.ts +1 -1
  233. package/dist/{storage-DkphZiOJ.d.ts → storage-Dxd7zVZH.d.ts} +1 -1
  234. package/dist/storage.d.ts +2 -2
  235. package/dist/storage.js +2 -2
  236. package/dist/summarizer.d.ts +1 -1
  237. package/dist/summary-snapshot.d.ts +1 -1
  238. package/dist/temporal-supersession.d.ts +2 -2
  239. package/dist/temporal-timeline-recall.d.ts +1 -1
  240. package/dist/temporal-validity.d.ts +1 -1
  241. package/dist/threading.d.ts +1 -1
  242. package/dist/tier-migration.d.ts +2 -2
  243. package/dist/tier-routing.d.ts +1 -1
  244. package/dist/topics.d.ts +1 -1
  245. package/dist/transcript.d.ts +1 -1
  246. package/dist/trust-score-stage.d.ts +1 -1
  247. package/dist/trust-score.d.ts +1 -1
  248. package/dist/{types-2q_MRFcM.d.ts → types-OUCJALBK.d.ts} +98 -1
  249. package/dist/types.d.ts +1 -1
  250. package/dist/types.js +1 -1
  251. package/dist/utility-runtime.d.ts +1 -1
  252. package/dist/verified-recall.js +3 -3
  253. package/dist/write-envelope.d.ts +1 -1
  254. package/package.json +2 -2
  255. package/src/activity/config.test.ts +113 -0
  256. package/src/activity/config.ts +111 -0
  257. package/src/activity/digest.ts +2 -2
  258. package/src/activity/index.ts +6 -0
  259. package/src/activity/pipeline.test.ts +379 -0
  260. package/src/activity/pipeline.ts +223 -0
  261. package/src/activity/reindex.test.ts +97 -0
  262. package/src/activity/reindex.ts +40 -0
  263. package/src/activity/runner.test.ts +452 -0
  264. package/src/activity/runner.ts +237 -0
  265. package/src/activity/scheduler.test.ts +303 -0
  266. package/src/activity/scheduler.ts +147 -0
  267. package/src/activity/source-client.test.ts +208 -0
  268. package/src/activity/source-client.ts +159 -0
  269. package/src/activity/sync-registration.test.ts +134 -0
  270. package/src/activity/sync-registration.ts +139 -0
  271. package/src/activity/types.ts +17 -0
  272. package/src/config.test.ts +19 -0
  273. package/src/config.ts +3 -0
  274. package/src/orchestration/maintenance.test.ts +42 -42
  275. package/src/orchestration/maintenance.ts +37 -5
  276. package/src/orchestration/orchestrator-helpers.ts +36 -1
  277. package/src/orchestration/recall-internal.ts +6 -6
  278. package/src/orchestration/recall-search-pipeline.ts +15 -7
  279. package/src/orchestrator-background-writes.test.ts +2 -2
  280. package/src/orchestrator.ts +3 -3
  281. package/src/types.ts +4 -1
  282. package/dist/chunk-CXFVZ3PK.js.map +0 -1
  283. package/dist/chunk-FJ5IQ3SI.js.map +0 -1
  284. package/dist/chunk-XJT6LNLY.js.map +0 -1
  285. package/dist/chunk-YXTSUIXC.js.map +0 -1
  286. /package/dist/{chunk-IRX5UCGN.js.map → chunk-2OH3ZRYH.js.map} +0 -0
  287. /package/dist/{chunk-42DJZZUB.js.map → chunk-7LXSPIVG.js.map} +0 -0
  288. /package/dist/{chunk-47WFEKT7.js.map → chunk-7PK4W4RN.js.map} +0 -0
  289. /package/dist/{chunk-O7ACJAHR.js.map → chunk-7YJLCNPF.js.map} +0 -0
  290. /package/dist/{chunk-6EJL2O3G.js.map → chunk-AFH7PIFU.js.map} +0 -0
  291. /package/dist/{chunk-JN4N2TMQ.js.map → chunk-ANGUOE2N.js.map} +0 -0
  292. /package/dist/{chunk-GQOKO77V.js.map → chunk-AWT7SCWQ.js.map} +0 -0
  293. /package/dist/{chunk-PXJEL55X.js.map → chunk-BIRPR5N7.js.map} +0 -0
  294. /package/dist/{chunk-NAY25BGS.js.map → chunk-BTK2PIFL.js.map} +0 -0
  295. /package/dist/{chunk-SYCVU556.js.map → chunk-C2RMQRPN.js.map} +0 -0
  296. /package/dist/{chunk-T4EAQPQQ.js.map → chunk-G2WCVFDC.js.map} +0 -0
  297. /package/dist/{chunk-UJIBXOJA.js.map → chunk-GEDBTSYU.js.map} +0 -0
  298. /package/dist/{chunk-WIKOHCQZ.js.map → chunk-I6ODVWQB.js.map} +0 -0
  299. /package/dist/{chunk-H4MDUPER.js.map → chunk-IZHXSLO7.js.map} +0 -0
  300. /package/dist/{chunk-RRS5CDB6.js.map → chunk-JOCXI2O5.js.map} +0 -0
  301. /package/dist/{chunk-EEUZQQRJ.js.map → chunk-KGKYTCDO.js.map} +0 -0
  302. /package/dist/{chunk-JTW4TGPV.js.map → chunk-L3HAUO7K.js.map} +0 -0
  303. /package/dist/{chunk-P53HGVJS.js.map → chunk-LMVAIZR5.js.map} +0 -0
  304. /package/dist/{chunk-KLXG4BBO.js.map → chunk-M6TZQDTX.js.map} +0 -0
  305. /package/dist/{chunk-U6QWUFSM.js.map → chunk-OXT5TQDS.js.map} +0 -0
  306. /package/dist/{chunk-T4OTDMX4.js.map → chunk-QDTEH6BS.js.map} +0 -0
  307. /package/dist/{chunk-5MDE5MIC.js.map → chunk-SESF64QR.js.map} +0 -0
  308. /package/dist/{chunk-4E5H4FPC.js.map → chunk-TUNI4GB3.js.map} +0 -0
  309. /package/dist/{chunk-5HFIHWOF.js.map → chunk-VLIY55Q5.js.map} +0 -0
  310. /package/dist/{chunk-BNH2VVWP.js.map → chunk-WIS5JTJR.js.map} +0 -0
  311. /package/dist/{chunk-OOGGUXAG.js.map → chunk-WQ2I6ODB.js.map} +0 -0
@@ -84,6 +84,102 @@ declare function isImportRole(value: unknown): value is ImportSourceRole;
84
84
  declare function parseIsoTimestamp(value: string): number | null;
85
85
  declare function validateImportTurn(turn: ImportTurn, index?: number): ImportTurnValidationIssue[];
86
86
 
87
+ /**
88
+ * Screen-activity subsystem — shared types (issue #1899).
89
+ *
90
+ * A third ingestion modality alongside wearables (conversations) and live
91
+ * connectors (documents). Screen text has no speakers and is high-volume, so it
92
+ * gets its own store and day-digest rather than being forced into the wearable
93
+ * conversation shape. Capture daemons live in the à-la-carte `@remnic/capture-screen`
94
+ * package; this core subsystem is host-agnostic and consumes snapshots over a
95
+ * loopback HTTP client.
96
+ *
97
+ * All timestamps are UTC ISO-8601; day bucketing is half-open [start, end).
98
+ */
99
+ /** One captured on-screen text snapshot (a single window at a single instant). */
100
+ interface ActivitySnapshot {
101
+ /** Store row id (assigned on insert; absent before persistence). */
102
+ id?: number;
103
+ /** Capture-machine label (disambiguates multi-machine stores). */
104
+ machine: string;
105
+ /** UTC ISO-8601 capture instant. */
106
+ capturedAtUtc: string;
107
+ /** Frontmost application name. */
108
+ app: string;
109
+ /** Frontmost window title. */
110
+ windowTitle: string;
111
+ /** Browser tab URL, when the frontmost window is a known browser. */
112
+ browserUrl?: string;
113
+ /** Extracted visible text (accessibility tree or OCR). */
114
+ text: string;
115
+ /** Where the text came from. */
116
+ textSource: "ax" | "ocr";
117
+ /** SHA-256 of the normalized snapshot content (idempotency key). */
118
+ contentHash: string;
119
+ /** 64-bit SimHash (hex) for near-duplicate detection, when computed. */
120
+ simhash?: string;
121
+ }
122
+ /** Frontmatter persisted on a rendered day digest. */
123
+ interface ActivityDayMeta {
124
+ kind: "activity-digest";
125
+ /** Local day, YYYY-MM-DD. */
126
+ date: string;
127
+ /** Machines that contributed snapshots, sorted. */
128
+ machines: string[];
129
+ snapshotCount: number;
130
+ /** SHA-256 of the rendered body (rebuild-idempotency). */
131
+ contentHash: string;
132
+ formatVersion: number;
133
+ }
134
+ /** A parsed day digest (frontmatter + rendered body). */
135
+ interface ActivityDayDigest {
136
+ meta: ActivityDayMeta;
137
+ body: string;
138
+ }
139
+ /** Result of a capture-daemon auth/health probe. */
140
+ interface ActivitySourceCheck {
141
+ ok: boolean;
142
+ detail?: string;
143
+ }
144
+ /** One page of snapshots pulled from a capture daemon. */
145
+ interface ActivitySnapshotPage {
146
+ snapshots: ActivitySnapshot[];
147
+ nextCursor: string | null;
148
+ }
149
+ /**
150
+ * Client contract for a screen-capture daemon (one per capture machine).
151
+ * Implemented by a later slice (the HTTP source client); defined here so the
152
+ * store and pipeline can be built and tested against a fixture double first.
153
+ */
154
+ interface ActivitySourceClient {
155
+ /** Stable capture-machine label. */
156
+ machineLabel: string;
157
+ /** Probe connectivity/auth without mutating anything. */
158
+ verify(signal?: AbortSignal): Promise<ActivitySourceCheck>;
159
+ /** Fetch one page of snapshots for a single local day. */
160
+ fetchSnapshots(opts: {
161
+ date: string;
162
+ timezone: string;
163
+ cursor?: string | null;
164
+ signal?: AbortSignal;
165
+ }): Promise<ActivitySnapshotPage>;
166
+ }
167
+ /** One trusted capture daemon that feeds this memory directory. */
168
+ interface ActivitySourceConfig {
169
+ machineLabel: string;
170
+ baseUrl: string;
171
+ token?: string;
172
+ }
173
+ /** Opt-in activity synchronization settings. */
174
+ interface ActivityConfig {
175
+ enabled: boolean;
176
+ timezone: string;
177
+ syncDays: number;
178
+ /** Periodic auto-sync cadence in minutes (default 15). */
179
+ autoSyncIntervalMinutes: number;
180
+ sources: ActivitySourceConfig[];
181
+ }
182
+
87
183
  /**
88
184
  * Wearable transcript subsystem — shared types (issue: wearable connectors).
89
185
  *
@@ -1606,6 +1702,7 @@ interface PluginConfig extends BoundedJsonlStateConfig {
1606
1702
  * Disabled by default; see docs/wearables.md.
1607
1703
  */
1608
1704
  wearables: WearablesConfig;
1705
+ activity: ActivityConfig;
1609
1706
  /**
1610
1707
  * At-rest encryption configuration (issue #690 PR 3/4).
1611
1708
  *
@@ -3930,4 +4027,4 @@ interface HourlySummary {
3930
4027
  generatedAt: string;
3931
4028
  }
3932
4029
 
3933
- export { type BehaviorSignalEvent as $, type ActiveRecallChatType as A, type BriefingSections as B, type CalendarSource as C, type DreamsPhase as D, type EntityFile as E, type FaithfulnessFrontmatter as F, type GatewayConfig as G, type HourlySummary as H, type IdentityInjectionMode as I, type ExtractionResult as J, type ConsolidationResult as K, type LiveConnectorsConfig as L, type MemoryFile as M, type DaySummaryResult as N, type ExtractionFailureClass as O, type PluginConfig as P, type QmdSearchResult as Q, type RecallPlanMode as R, type SessionObserverBandConfig as S, type TranscriptEntry as T, type ProvenanceSource as U, type TrustWeights as V, type ConversationThread as W, type LifecycleState as X, type VerificationState as Y, type PolicyClass as Z, type ImportanceLevel as _, type DreamsRunResult as a, type BulkImportError as a$, type BufferSurpriseEvent as a0, type ImportTurn as a1, type BulkImportOptions as a2, type BulkImportSource as a3, type BulkImportResult as a4, type SecretRef as a5, type AgentAccessAuthToken as a6, type CompressionGuidelineOptimizerEventCounts as a7, type CompressionGuidelineOptimizerActionSummary as a8, type CompressionGuidelineOptimizerRuleUpdate as a9, type EntityActivityEntry as aA, type AccessTrackingEntry as aB, type MemorySummary as aC, type CodingContext as aD, type DreamsStatusResult as aE, type WearableConversation as aF, type WearableSourceSettings as aG, type WearableNativeMemory as aH, type WearableMemoryMode as aI, type WearableSourceConnector as aJ, type WearablesConfig as aK, type WearableSyncSummary as aL, type WearableSourceStatus as aM, type WearableDayTranscript as aN, type WearableCorrectionRule as aO, type RecallSectionConfig as aP, type BootstrapOptions as aQ, type BootstrapResult as aR, type ConsolidationObservation as aS, type CodingModeConfig as aT, type CodingKnowledgeConfig as aU, type WearableCleanupSettings as aV, type WearableFusionConfig as aW, type WearableDayTranscriptMeta as aX, type BriefingConfig as aY, type BriefingOpenCommitment as aZ, type BriefingWindow as a_, type MemoryActionType as aa, type MemoryActionEvent as ab, type CompressionGuidelineOptimizerState as ac, type EntityMention as ad, type EntitySchemaDefinition as ae, type EntitySchemaSectionDefinition as af, type EntityStructuredSection as ag, type ImportanceScore as ah, type MemoryIntent as ai, type MemoryActionEligibilityContext as aj, type MemoryActionPolicyResult as ak, type MemoryLifecycleEventType as al, type MemoryLifecycleStateSummary as am, type ModelProviderConfig as an, type NativeKnowledgeConfig as ao, type ProvenanceConfig as ap, type RetrievalTier as aq, type SignalScanResult as ar, type TopicScore as as, type QmdSearchExplain as at, type EntityTimelineEntry as au, type MemoryLink as av, type BufferState as aw, type MetaState as ax, type FileHygieneConfig as ay, type EntityRelationship as az, type RecallDisclosure as b, type MemoryActionPolicyDecision as b$, type BulkImportSourceAdapter as b0, type CodexCompatConfig as b1, DEFAULT_RECALL_DISCLOSURE as b2, type ExtractedFact as b3, type ImportSourceRole as b4, type ImportTurnValidationIssue as b5, type MemoryActionEligibilitySource as b6, type MemoryObservation as b7, type MemoryScope as b8, RECALL_DISCLOSURE_LEVELS as b9, type ConsolidationAction as bA, type ConsolidationItem as bB, type ContradictionScanConfig as bC, type CronConversationRecallMode as bD, type CronRecallMode as bE, type DreamingConfig as bF, type DreamingNarrativePromptStyle as bG, type DreamsDeepSleepConfig as bH, type DreamsLightSleepConfig as bI, type DreamsPhaseStatus as bJ, type DreamsPhasesConfig as bK, type DreamsRemConfig as bL, type EngramTraceEvent as bM, type ExtractedProcedureStep as bN, type ExtractedQuestion as bO, type ExtractedReasoningTrace as bP, type ExtractedReasoningTraceStep as bQ, type ExtractedRelationship as bR, type ExtractionPassSource as bS, type GitHubLiveConnectorConfig as bT, type GmailLiveConnectorConfig as bU, type GoogleDriveLiveConnectorConfig as bV, type HeartbeatConfig as bW, type HeartbeatDetectionMode as bX, type LlmTraceCallback as bY, type LlmTraceEvent as bZ, type MemoryActionOutcome as b_, type WearableAuthCheck as ba, type WearableFetchOptions as bb, type WearableFetchPage as bc, type WearableNativeMemoryPage as bd, type WearableTranscriptSegment as be, isImportRole as bf, isRecallDisclosure as bg, parseIsoTimestamp as bh, validateImportTurn as bi, type AgentAccessHttpConfig as bj, type AgentDefaultsConfig as bk, type AgentPersona as bl, type BehaviorLoopAdjustment as bm, type BehaviorSignalDirection as bn, type BehaviorSignalType as bo, type BriefingCalendarSourceError as bp, type BufferEntryState as bq, type CaptureMode as br, type ChatConfig as bs, type CodexCliReasoningEffort as bt, type CodexCompactionFlushMode as bu, type CodexConnectorConfig as bv, type CodingGraphLspConfig as bw, type CompressionGuidelineActivationState as bx, type CompressionGuidelineOptimizerSourceWindow as by, type ConfidenceTier as bz, type ActiveRecallQueryMode as c, type MemoryActionStatus as c0, type MemoryLinkType as c1, type MemoryOsPresetName as c2, type ModelApi as c3, type ModelDefinitionConfig as c4, type ModelProviderAuthMode as c5, type NamespacePolicy as c6, type NativeKnowledgeFolderRuleConfig as c7, type NativeKnowledgeObsidianVaultConfig as c8, type NativeKnowledgeOpenClawWorkspaceConfig as c9, type NotionLiveConnectorConfig as ca, type PrincipalFromSessionKeyMode as cb, type PrincipalRule as cc, type ProceduralConfig as cd, type QuestionEntry as ce, type ReasoningEffort as cf, type RecallPipelineConfig as cg, type RecallTraceEvent as ch, type RelevanceFeedback as ci, SPECULATIVE_TTL_DAYS as cj, type ScopeProfileAutoPromoteConfig as ck, type ScopeProfileTeamProjectConfig as cl, type ScopeTeamConfig as cm, type ScoredEntity as cn, type SemanticChunkingConfigShape as co, type SignalLevel as cp, type SlotBehaviorConfig as cq, type SlotMismatchMode as cr, type TriggerMode as cs, confidenceTier as ct, type ActiveRecallPromptStyle as d, type ActiveRecallThinking as e, type ActiveRecallModelFallbackPolicy as f, type RecallTierExplain as g, type BriefingFollowup as h, type BriefingFocus as i, type CalendarEvent as j, type BriefingActiveThread as k, type BriefingResult as l, type BriefingRecentEntity as m, type BufferTurn as n, type MemoryFrontmatter as o, type Checkpoint as p, type AgentPersonaModelConfig as q, type SourceConnectorProvenance as r, type ScopeProfileConfig as s, type ScopeProfileLayerId as t, type ScopeProfilePromotionTarget as u, type BehaviorLoopPolicyState as v, type MemoryCategory as w, type MemoryStatus as x, type MemoryProjectionCurrentState as y, type MemoryLifecycleEvent as z };
4030
+ export { type BehaviorSignalEvent as $, type ActiveRecallChatType as A, type BriefingSections as B, type CalendarSource as C, type DreamsPhase as D, type EntityFile as E, type FaithfulnessFrontmatter as F, type GatewayConfig as G, type HourlySummary as H, type IdentityInjectionMode as I, type ExtractionResult as J, type ConsolidationResult as K, type LiveConnectorsConfig as L, type MemoryFile as M, type DaySummaryResult as N, type ExtractionFailureClass as O, type PluginConfig as P, type QmdSearchResult as Q, type RecallPlanMode as R, type SessionObserverBandConfig as S, type TranscriptEntry as T, type ProvenanceSource as U, type TrustWeights as V, type ConversationThread as W, type LifecycleState as X, type VerificationState as Y, type PolicyClass as Z, type ImportanceLevel as _, type DreamsRunResult as a, type ActivitySourceClient as a$, type BufferSurpriseEvent as a0, type ImportTurn as a1, type BulkImportOptions as a2, type BulkImportSource as a3, type BulkImportResult as a4, type SecretRef as a5, type AgentAccessAuthToken as a6, type CompressionGuidelineOptimizerEventCounts as a7, type CompressionGuidelineOptimizerActionSummary as a8, type CompressionGuidelineOptimizerRuleUpdate as a9, type EntityActivityEntry as aA, type AccessTrackingEntry as aB, type MemorySummary as aC, type CodingContext as aD, type DreamsStatusResult as aE, type WearableConversation as aF, type WearableSourceSettings as aG, type WearableNativeMemory as aH, type WearableMemoryMode as aI, type WearableSourceConnector as aJ, type WearablesConfig as aK, type WearableSyncSummary as aL, type WearableSourceStatus as aM, type WearableDayTranscript as aN, type WearableCorrectionRule as aO, type RecallSectionConfig as aP, type BootstrapOptions as aQ, type BootstrapResult as aR, type ConsolidationObservation as aS, type CodingModeConfig as aT, type CodingKnowledgeConfig as aU, type WearableCleanupSettings as aV, type WearableFusionConfig as aW, type WearableDayTranscriptMeta as aX, type ActivitySnapshot as aY, type ActivityDayMeta as aZ, type ActivityDayDigest as a_, type MemoryActionType as aa, type MemoryActionEvent as ab, type CompressionGuidelineOptimizerState as ac, type EntityMention as ad, type EntitySchemaDefinition as ae, type EntitySchemaSectionDefinition as af, type EntityStructuredSection as ag, type ImportanceScore as ah, type MemoryIntent as ai, type MemoryActionEligibilityContext as aj, type MemoryActionPolicyResult as ak, type MemoryLifecycleEventType as al, type MemoryLifecycleStateSummary as am, type ModelProviderConfig as an, type NativeKnowledgeConfig as ao, type ProvenanceConfig as ap, type RetrievalTier as aq, type SignalScanResult as ar, type TopicScore as as, type QmdSearchExplain as at, type EntityTimelineEntry as au, type MemoryLink as av, type BufferState as aw, type MetaState as ax, type FileHygieneConfig as ay, type EntityRelationship as az, type RecallDisclosure as b, type GitHubLiveConnectorConfig as b$, type ActivitySourceCheck as b0, type ActivitySnapshotPage as b1, type ActivityConfig as b2, type ActivitySourceConfig as b3, type BriefingConfig as b4, type BriefingOpenCommitment as b5, type BriefingWindow as b6, type BulkImportError as b7, type BulkImportSourceAdapter as b8, type CodexCompatConfig as b9, type ChatConfig as bA, type CodexCliReasoningEffort as bB, type CodexCompactionFlushMode as bC, type CodexConnectorConfig as bD, type CodingGraphLspConfig as bE, type CompressionGuidelineActivationState as bF, type CompressionGuidelineOptimizerSourceWindow as bG, type ConfidenceTier as bH, type ConsolidationAction as bI, type ConsolidationItem as bJ, type ContradictionScanConfig as bK, type CronConversationRecallMode as bL, type CronRecallMode as bM, type DreamingConfig as bN, type DreamingNarrativePromptStyle as bO, type DreamsDeepSleepConfig as bP, type DreamsLightSleepConfig as bQ, type DreamsPhaseStatus as bR, type DreamsPhasesConfig as bS, type DreamsRemConfig as bT, type EngramTraceEvent as bU, type ExtractedProcedureStep as bV, type ExtractedQuestion as bW, type ExtractedReasoningTrace as bX, type ExtractedReasoningTraceStep as bY, type ExtractedRelationship as bZ, type ExtractionPassSource as b_, DEFAULT_RECALL_DISCLOSURE as ba, type ExtractedFact as bb, type ImportSourceRole as bc, type ImportTurnValidationIssue as bd, type MemoryActionEligibilitySource as be, type MemoryObservation as bf, type MemoryScope as bg, RECALL_DISCLOSURE_LEVELS as bh, type WearableAuthCheck as bi, type WearableFetchOptions as bj, type WearableFetchPage as bk, type WearableNativeMemoryPage as bl, type WearableTranscriptSegment as bm, isImportRole as bn, isRecallDisclosure as bo, parseIsoTimestamp as bp, validateImportTurn as bq, type AgentAccessHttpConfig as br, type AgentDefaultsConfig as bs, type AgentPersona as bt, type BehaviorLoopAdjustment as bu, type BehaviorSignalDirection as bv, type BehaviorSignalType as bw, type BriefingCalendarSourceError as bx, type BufferEntryState as by, type CaptureMode as bz, type ActiveRecallQueryMode as c, type GmailLiveConnectorConfig as c0, type GoogleDriveLiveConnectorConfig as c1, type HeartbeatConfig as c2, type HeartbeatDetectionMode as c3, type LlmTraceCallback as c4, type LlmTraceEvent as c5, type MemoryActionOutcome as c6, type MemoryActionPolicyDecision as c7, type MemoryActionStatus as c8, type MemoryLinkType as c9, type TriggerMode as cA, confidenceTier as cB, type MemoryOsPresetName as ca, type ModelApi as cb, type ModelDefinitionConfig as cc, type ModelProviderAuthMode as cd, type NamespacePolicy as ce, type NativeKnowledgeFolderRuleConfig as cf, type NativeKnowledgeObsidianVaultConfig as cg, type NativeKnowledgeOpenClawWorkspaceConfig as ch, type NotionLiveConnectorConfig as ci, type PrincipalFromSessionKeyMode as cj, type PrincipalRule as ck, type ProceduralConfig as cl, type QuestionEntry as cm, type ReasoningEffort as cn, type RecallPipelineConfig as co, type RecallTraceEvent as cp, type RelevanceFeedback as cq, SPECULATIVE_TTL_DAYS as cr, type ScopeProfileAutoPromoteConfig as cs, type ScopeProfileTeamProjectConfig as ct, type ScopeTeamConfig as cu, type ScoredEntity as cv, type SemanticChunkingConfigShape as cw, type SignalLevel as cx, type SlotBehaviorConfig as cy, type SlotMismatchMode as cz, type ActiveRecallPromptStyle as d, type ActiveRecallThinking as e, type ActiveRecallModelFallbackPolicy as f, type RecallTierExplain as g, type BriefingFollowup as h, type BriefingFocus as i, type CalendarEvent as j, type BriefingActiveThread as k, type BriefingResult as l, type BriefingRecentEntity as m, type BufferTurn as n, type MemoryFrontmatter as o, type Checkpoint as p, type AgentPersonaModelConfig as q, type SourceConnectorProvenance as r, type ScopeProfileConfig as s, type ScopeProfileLayerId as t, type ScopeProfilePromotionTarget as u, type BehaviorLoopPolicyState as v, type MemoryCategory as w, type MemoryStatus as x, type MemoryProjectionCurrentState as y, type MemoryLifecycleEvent as z };
package/dist/types.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- export { aB as AccessTrackingEntry, A as ActiveRecallChatType, f as ActiveRecallModelFallbackPolicy, d as ActiveRecallPromptStyle, c as ActiveRecallQueryMode, e as ActiveRecallThinking, a6 as AgentAccessAuthToken, bj as AgentAccessHttpConfig, bk as AgentDefaultsConfig, bl as AgentPersona, q as AgentPersonaModelConfig, bm as BehaviorLoopAdjustment, v as BehaviorLoopPolicyState, bn as BehaviorSignalDirection, $ as BehaviorSignalEvent, bo as BehaviorSignalType, aQ as BootstrapOptions, aR as BootstrapResult, k as BriefingActiveThread, bp as BriefingCalendarSourceError, aY as BriefingConfig, i as BriefingFocus, h as BriefingFollowup, aZ as BriefingOpenCommitment, m as BriefingRecentEntity, l as BriefingResult, B as BriefingSections, a_ as BriefingWindow, bq as BufferEntryState, aw as BufferState, a0 as BufferSurpriseEvent, n as BufferTurn, j as CalendarEvent, C as CalendarSource, br as CaptureMode, bs as ChatConfig, p as Checkpoint, bt as CodexCliReasoningEffort, bu as CodexCompactionFlushMode, b1 as CodexCompatConfig, bv as CodexConnectorConfig, aD as CodingContext, bw as CodingGraphLspConfig, aU as CodingKnowledgeConfig, aT as CodingModeConfig, bx as CompressionGuidelineActivationState, a8 as CompressionGuidelineOptimizerActionSummary, a7 as CompressionGuidelineOptimizerEventCounts, a9 as CompressionGuidelineOptimizerRuleUpdate, by as CompressionGuidelineOptimizerSourceWindow, ac as CompressionGuidelineOptimizerState, bz as ConfidenceTier, bA as ConsolidationAction, bB as ConsolidationItem, aS as ConsolidationObservation, K as ConsolidationResult, bC as ContradictionScanConfig, W as ConversationThread, bD as CronConversationRecallMode, bE as CronRecallMode, b2 as DEFAULT_RECALL_DISCLOSURE, N as DaySummaryResult, bF as DreamingConfig, bG as DreamingNarrativePromptStyle, bH as DreamsDeepSleepConfig, bI as DreamsLightSleepConfig, D as DreamsPhase, bJ as DreamsPhaseStatus, bK as DreamsPhasesConfig, bL as DreamsRemConfig, a as DreamsRunResult, aE as DreamsStatusResult, bM as EngramTraceEvent, aA as EntityActivityEntry, E as EntityFile, ad as EntityMention, az as EntityRelationship, ae as EntitySchemaDefinition, af as EntitySchemaSectionDefinition, ag as EntityStructuredSection, au as EntityTimelineEntry, b3 as ExtractedFact, bN as ExtractedProcedureStep, bO as ExtractedQuestion, bP as ExtractedReasoningTrace, bQ as ExtractedReasoningTraceStep, bR as ExtractedRelationship, O as ExtractionFailureClass, bS as ExtractionPassSource, J as ExtractionResult, F as FaithfulnessFrontmatter, ay as FileHygieneConfig, G as GatewayConfig, bT as GitHubLiveConnectorConfig, bU as GmailLiveConnectorConfig, bV as GoogleDriveLiveConnectorConfig, bW as HeartbeatConfig, bX as HeartbeatDetectionMode, H as HourlySummary, I as IdentityInjectionMode, _ as ImportanceLevel, ah as ImportanceScore, X as LifecycleState, L as LiveConnectorsConfig, bY as LlmTraceCallback, bZ as LlmTraceEvent, aj as MemoryActionEligibilityContext, b6 as MemoryActionEligibilitySource, ab as MemoryActionEvent, b_ as MemoryActionOutcome, b$ as MemoryActionPolicyDecision, ak as MemoryActionPolicyResult, c0 as MemoryActionStatus, aa as MemoryActionType, w as MemoryCategory, M as MemoryFile, o as MemoryFrontmatter, ai as MemoryIntent, z as MemoryLifecycleEvent, al as MemoryLifecycleEventType, am as MemoryLifecycleStateSummary, av as MemoryLink, c1 as MemoryLinkType, b7 as MemoryObservation, c2 as MemoryOsPresetName, y as MemoryProjectionCurrentState, b8 as MemoryScope, x as MemoryStatus, aC as MemorySummary, ax as MetaState, c3 as ModelApi, c4 as ModelDefinitionConfig, c5 as ModelProviderAuthMode, an as ModelProviderConfig, c6 as NamespacePolicy, ao as NativeKnowledgeConfig, c7 as NativeKnowledgeFolderRuleConfig, c8 as NativeKnowledgeObsidianVaultConfig, c9 as NativeKnowledgeOpenClawWorkspaceConfig, ca as NotionLiveConnectorConfig, P as PluginConfig, Z as PolicyClass, cb as PrincipalFromSessionKeyMode, cc as PrincipalRule, cd as ProceduralConfig, ap as ProvenanceConfig, U as ProvenanceSource, at as QmdSearchExplain, Q as QmdSearchResult, ce as QuestionEntry, b9 as RECALL_DISCLOSURE_LEVELS, cf as ReasoningEffort, b as RecallDisclosure, cg as RecallPipelineConfig, R as RecallPlanMode, aP as RecallSectionConfig, g as RecallTierExplain, ch as RecallTraceEvent, ci as RelevanceFeedback, aq as RetrievalTier, cj as SPECULATIVE_TTL_DAYS, ck as ScopeProfileAutoPromoteConfig, s as ScopeProfileConfig, t as ScopeProfileLayerId, u as ScopeProfilePromotionTarget, cl as ScopeProfileTeamProjectConfig, cm as ScopeTeamConfig, cn as ScoredEntity, a5 as SecretRef, co as SemanticChunkingConfigShape, S as SessionObserverBandConfig, cp as SignalLevel, ar as SignalScanResult, cq as SlotBehaviorConfig, cr as SlotMismatchMode, r as SourceConnectorProvenance, as as TopicScore, T as TranscriptEntry, cs as TriggerMode, V as TrustWeights, Y as VerificationState, ct as confidenceTier, bg as isRecallDisclosure } from './types-2q_MRFcM.js';
1
+ export { aB as AccessTrackingEntry, A as ActiveRecallChatType, f as ActiveRecallModelFallbackPolicy, d as ActiveRecallPromptStyle, c as ActiveRecallQueryMode, e as ActiveRecallThinking, a6 as AgentAccessAuthToken, br as AgentAccessHttpConfig, bs as AgentDefaultsConfig, bt as AgentPersona, q as AgentPersonaModelConfig, bu as BehaviorLoopAdjustment, v as BehaviorLoopPolicyState, bv as BehaviorSignalDirection, $ as BehaviorSignalEvent, bw as BehaviorSignalType, aQ as BootstrapOptions, aR as BootstrapResult, k as BriefingActiveThread, bx as BriefingCalendarSourceError, b4 as BriefingConfig, i as BriefingFocus, h as BriefingFollowup, b5 as BriefingOpenCommitment, m as BriefingRecentEntity, l as BriefingResult, B as BriefingSections, b6 as BriefingWindow, by as BufferEntryState, aw as BufferState, a0 as BufferSurpriseEvent, n as BufferTurn, j as CalendarEvent, C as CalendarSource, bz as CaptureMode, bA as ChatConfig, p as Checkpoint, bB as CodexCliReasoningEffort, bC as CodexCompactionFlushMode, b9 as CodexCompatConfig, bD as CodexConnectorConfig, aD as CodingContext, bE as CodingGraphLspConfig, aU as CodingKnowledgeConfig, aT as CodingModeConfig, bF as CompressionGuidelineActivationState, a8 as CompressionGuidelineOptimizerActionSummary, a7 as CompressionGuidelineOptimizerEventCounts, a9 as CompressionGuidelineOptimizerRuleUpdate, bG as CompressionGuidelineOptimizerSourceWindow, ac as CompressionGuidelineOptimizerState, bH as ConfidenceTier, bI as ConsolidationAction, bJ as ConsolidationItem, aS as ConsolidationObservation, K as ConsolidationResult, bK as ContradictionScanConfig, W as ConversationThread, bL as CronConversationRecallMode, bM as CronRecallMode, ba as DEFAULT_RECALL_DISCLOSURE, N as DaySummaryResult, bN as DreamingConfig, bO as DreamingNarrativePromptStyle, bP as DreamsDeepSleepConfig, bQ as DreamsLightSleepConfig, D as DreamsPhase, bR as DreamsPhaseStatus, bS as DreamsPhasesConfig, bT as DreamsRemConfig, a as DreamsRunResult, aE as DreamsStatusResult, bU as EngramTraceEvent, aA as EntityActivityEntry, E as EntityFile, ad as EntityMention, az as EntityRelationship, ae as EntitySchemaDefinition, af as EntitySchemaSectionDefinition, ag as EntityStructuredSection, au as EntityTimelineEntry, bb as ExtractedFact, bV as ExtractedProcedureStep, bW as ExtractedQuestion, bX as ExtractedReasoningTrace, bY as ExtractedReasoningTraceStep, bZ as ExtractedRelationship, O as ExtractionFailureClass, b_ as ExtractionPassSource, J as ExtractionResult, F as FaithfulnessFrontmatter, ay as FileHygieneConfig, G as GatewayConfig, b$ as GitHubLiveConnectorConfig, c0 as GmailLiveConnectorConfig, c1 as GoogleDriveLiveConnectorConfig, c2 as HeartbeatConfig, c3 as HeartbeatDetectionMode, H as HourlySummary, I as IdentityInjectionMode, _ as ImportanceLevel, ah as ImportanceScore, X as LifecycleState, L as LiveConnectorsConfig, c4 as LlmTraceCallback, c5 as LlmTraceEvent, aj as MemoryActionEligibilityContext, be as MemoryActionEligibilitySource, ab as MemoryActionEvent, c6 as MemoryActionOutcome, c7 as MemoryActionPolicyDecision, ak as MemoryActionPolicyResult, c8 as MemoryActionStatus, aa as MemoryActionType, w as MemoryCategory, M as MemoryFile, o as MemoryFrontmatter, ai as MemoryIntent, z as MemoryLifecycleEvent, al as MemoryLifecycleEventType, am as MemoryLifecycleStateSummary, av as MemoryLink, c9 as MemoryLinkType, bf as MemoryObservation, ca as MemoryOsPresetName, y as MemoryProjectionCurrentState, bg as MemoryScope, x as MemoryStatus, aC as MemorySummary, ax as MetaState, cb as ModelApi, cc as ModelDefinitionConfig, cd as ModelProviderAuthMode, an as ModelProviderConfig, ce as NamespacePolicy, ao as NativeKnowledgeConfig, cf as NativeKnowledgeFolderRuleConfig, cg as NativeKnowledgeObsidianVaultConfig, ch as NativeKnowledgeOpenClawWorkspaceConfig, ci as NotionLiveConnectorConfig, P as PluginConfig, Z as PolicyClass, cj as PrincipalFromSessionKeyMode, ck as PrincipalRule, cl as ProceduralConfig, ap as ProvenanceConfig, U as ProvenanceSource, at as QmdSearchExplain, Q as QmdSearchResult, cm as QuestionEntry, bh as RECALL_DISCLOSURE_LEVELS, cn as ReasoningEffort, b as RecallDisclosure, co as RecallPipelineConfig, R as RecallPlanMode, aP as RecallSectionConfig, g as RecallTierExplain, cp as RecallTraceEvent, cq as RelevanceFeedback, aq as RetrievalTier, cr as SPECULATIVE_TTL_DAYS, cs as ScopeProfileAutoPromoteConfig, s as ScopeProfileConfig, t as ScopeProfileLayerId, u as ScopeProfilePromotionTarget, ct as ScopeProfileTeamProjectConfig, cu as ScopeTeamConfig, cv as ScoredEntity, a5 as SecretRef, cw as SemanticChunkingConfigShape, S as SessionObserverBandConfig, cx as SignalLevel, ar as SignalScanResult, cy as SlotBehaviorConfig, cz as SlotMismatchMode, r as SourceConnectorProvenance, as as TopicScore, T as TranscriptEntry, cA as TriggerMode, V as TrustWeights, Y as VerificationState, cB as confidenceTier, bo as isRecallDisclosure } from './types-OUCJALBK.js';
2
2
  import './message-parts/index.js';
3
3
  import './bounded-jsonl-state.js';
4
4
  export { ContinuityImprovementLoop, ContinuityIncidentCloseInput, ContinuityIncidentOpenInput, ContinuityIncidentRecord, ContinuityIncidentState, ContinuityLoopCadence, ContinuityLoopReviewInput, ContinuityLoopStatus, ContinuityLoopUpsertInput } from './types-continuity.js';
package/dist/types.js CHANGED
@@ -4,7 +4,7 @@ import {
4
4
  SPECULATIVE_TTL_DAYS,
5
5
  confidenceTier,
6
6
  isRecallDisclosure
7
- } from "./chunk-FJ5IQ3SI.js";
7
+ } from "./chunk-N7DK67GZ.js";
8
8
  import "./chunk-PZ5AY32C.js";
9
9
  export {
10
10
  DEFAULT_RECALL_DISCLOSURE,
@@ -1,5 +1,5 @@
1
1
  import { TierRoutingPolicy } from './tier-routing.js';
2
- import './types-2q_MRFcM.js';
2
+ import './types-OUCJALBK.js';
3
3
  import './message-parts/index.js';
4
4
  import './bounded-jsonl-state.js';
5
5
  import './types-continuity.js';
@@ -1,9 +1,9 @@
1
1
  import {
2
2
  compareVerifiedEpisodeResults,
3
3
  searchVerifiedEpisodes
4
- } from "./chunk-6EJL2O3G.js";
4
+ } from "./chunk-AFH7PIFU.js";
5
5
  import "./chunk-B7RWBZXW.js";
6
- import "./chunk-O7ACJAHR.js";
6
+ import "./chunk-7YJLCNPF.js";
7
7
  import "./chunk-B3ABVQ36.js";
8
8
  import "./chunk-2QMKMVHH.js";
9
9
  import "./chunk-DEBHXHJR.js";
@@ -11,7 +11,7 @@ import "./chunk-DNHVPZOD.js";
11
11
  import "./chunk-6CIAGZ6X.js";
12
12
  import "./chunk-J6A3CX5N.js";
13
13
  import "./chunk-V57NLO5P.js";
14
- import "./chunk-FJ5IQ3SI.js";
14
+ import "./chunk-N7DK67GZ.js";
15
15
  import "./chunk-XKGPIWGI.js";
16
16
  import "./chunk-EGGE52UU.js";
17
17
  import "./chunk-GCASGYIO.js";
@@ -1,4 +1,4 @@
1
- import { w as MemoryCategory } from './types-2q_MRFcM.js';
1
+ import { w as MemoryCategory } from './types-OUCJALBK.js';
2
2
  import './message-parts/index.js';
3
3
  import './bounded-jsonl-state.js';
4
4
  import './types-continuity.js';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@remnic/core",
3
- "version": "9.15.3",
3
+ "version": "9.16.0",
4
4
  "description": "Framework-agnostic Remnic memory engine — orchestrator, storage, extraction, search, trust zones",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",
@@ -3045,7 +3045,7 @@
3045
3045
  "core"
3046
3046
  ],
3047
3047
  "peerDependencies": {
3048
- "@remnic/coding-graph": "^9.15.3"
3048
+ "@remnic/coding-graph": "^9.16.0"
3049
3049
  },
3050
3050
  "peerDependenciesMeta": {
3051
3051
  "@remnic/coding-graph": {
@@ -0,0 +1,113 @@
1
+ import assert from "node:assert/strict";
2
+ import test from "node:test";
3
+
4
+ import { parseActivityConfig } from "./config.js";
5
+
6
+ test("parseActivityConfig defaults to an inert configuration", () => {
7
+ assert.deepEqual(parseActivityConfig(undefined), {
8
+ enabled: false,
9
+ timezone: "UTC",
10
+ syncDays: 1,
11
+ autoSyncIntervalMinutes: 15,
12
+ sources: [],
13
+ });
14
+ });
15
+
16
+ test("parseActivityConfig treats a string false gate as disabled", () => {
17
+ assert.equal(parseActivityConfig({ enabled: "false" }).enabled, false);
18
+ });
19
+
20
+ test("parseActivityConfig preserves explicit source settings", () => {
21
+ assert.deepEqual(
22
+ parseActivityConfig({
23
+ enabled: true,
24
+ timezone: "America/Chicago",
25
+ syncDays: 3,
26
+ sources: [{ machineLabel: "fixture-machine", baseUrl: "http://127.0.0.1:4319", token: "fixture-token" }],
27
+ }),
28
+ {
29
+ enabled: true,
30
+ timezone: "America/Chicago",
31
+ syncDays: 3,
32
+ autoSyncIntervalMinutes: 15,
33
+ sources: [{ machineLabel: "fixture-machine", baseUrl: "http://127.0.0.1:4319", token: "fixture-token" }],
34
+ },
35
+ );
36
+ });
37
+
38
+ test("parseActivityConfig rejects enabled configurations without valid source definitions", () => {
39
+ assert.throws(() => parseActivityConfig({ enabled: true, sources: [] }), /at least one source/);
40
+ assert.throws(
41
+ () => parseActivityConfig({ enabled: true, sources: [{ machineLabel: "fixture", baseUrl: "ftp://example.test" }] }),
42
+ /HTTP or HTTPS/,
43
+ );
44
+ assert.throws(() => parseActivityConfig({ syncDays: 0 }), /syncDays/);
45
+ });
46
+
47
+ test("parseActivityConfig enforces both ends of the syncDays range", () => {
48
+ assert.equal(parseActivityConfig({ syncDays: 90 }).syncDays, 90);
49
+ assert.equal(parseActivityConfig({ syncDays: 1 }).syncDays, 1);
50
+ assert.throws(() => parseActivityConfig({ syncDays: 91 }), /syncDays must be an integer from 1 to 90/);
51
+ assert.throws(() => parseActivityConfig({ syncDays: 0 }), /syncDays must be an integer from 1 to 90/);
52
+ });
53
+
54
+ test("parseActivityConfig rejects an invalid IANA timezone at parse time", () => {
55
+ assert.throws(() => parseActivityConfig({ timezone: "Not/AZone" }), /Invalid IANA timezone/);
56
+ });
57
+
58
+ test("parseActivityConfig rejects a whitespace-only machineLabel before any sync", () => {
59
+ assert.throws(
60
+ () => parseActivityConfig({ enabled: true, sources: [{ machineLabel: " ", baseUrl: "http://127.0.0.1:4319" }] }),
61
+ /machineLabel must not be blank/,
62
+ );
63
+ });
64
+
65
+ test("parseActivityConfig rejects duplicate machine labels that would share a cursor", () => {
66
+ assert.throws(
67
+ () =>
68
+ parseActivityConfig({
69
+ enabled: true,
70
+ sources: [
71
+ { machineLabel: "dup", baseUrl: "http://127.0.0.1:4319" },
72
+ { machineLabel: "dup", baseUrl: "http://127.0.0.1:4320" },
73
+ ],
74
+ }),
75
+ /machineLabel must be unique/,
76
+ );
77
+ });
78
+
79
+ test("parseActivityConfig reports a malformed baseUrl with a prefixed validation error", () => {
80
+ assert.throws(
81
+ () => parseActivityConfig({ enabled: true, sources: [{ machineLabel: "fixture", baseUrl: "not a url" }] }),
82
+ /activity source baseUrl must be a valid URL/,
83
+ );
84
+ });
85
+
86
+ test("parseActivityConfig rejects a non-loopback baseUrl that could exfiltrate the token", () => {
87
+ assert.throws(
88
+ () => parseActivityConfig({ enabled: true, sources: [{ machineLabel: "fixture", baseUrl: "https://example.test" }] }),
89
+ /must target a loopback host/,
90
+ );
91
+ });
92
+
93
+ test("parseActivityConfig accepts localhost and 127.x loopback hosts", () => {
94
+ assert.equal(
95
+ parseActivityConfig({ enabled: true, sources: [{ machineLabel: "a", baseUrl: "http://localhost:4319" }] }).sources
96
+ .length,
97
+ 1,
98
+ );
99
+ assert.equal(
100
+ parseActivityConfig({ enabled: true, sources: [{ machineLabel: "b", baseUrl: "http://127.0.0.5:4319" }] }).sources
101
+ .length,
102
+ 1,
103
+ );
104
+ });
105
+
106
+ test("parseActivityConfig parses and bounds autoSyncIntervalMinutes", () => {
107
+ assert.equal(parseActivityConfig(undefined).autoSyncIntervalMinutes, 15);
108
+ assert.equal(parseActivityConfig({ autoSyncIntervalMinutes: "30" }).autoSyncIntervalMinutes, 30);
109
+ assert.equal(parseActivityConfig({ autoSyncIntervalMinutes: 1 }).autoSyncIntervalMinutes, 1);
110
+ assert.equal(parseActivityConfig({ autoSyncIntervalMinutes: 1440 }).autoSyncIntervalMinutes, 1440);
111
+ assert.throws(() => parseActivityConfig({ autoSyncIntervalMinutes: 0 }), /autoSyncIntervalMinutes must be an integer from 1 to 1440/);
112
+ assert.throws(() => parseActivityConfig({ autoSyncIntervalMinutes: 1441 }), /autoSyncIntervalMinutes must be an integer from 1 to 1440/);
113
+ });
@@ -0,0 +1,111 @@
1
+ import { coerceBooleanLike, coerceNumber } from "../connectors/coerce.js";
2
+ import { assertValidTimezone } from "./digest.js";
3
+ import type { ActivityConfig, ActivitySourceConfig } from "./types.js";
4
+
5
+ function asRecord(value: unknown, name: string): Record<string, unknown> {
6
+ if (typeof value !== "object" || value === null || Array.isArray(value)) {
7
+ throw new TypeError(`${name} must be an object`);
8
+ }
9
+ return value as Record<string, unknown>;
10
+ }
11
+
12
+ function optionalString(value: unknown, name: string): string | undefined {
13
+ if (value === undefined) return undefined;
14
+ if (typeof value !== "string" || value.length === 0) throw new TypeError(`${name} must be a non-empty string`);
15
+ return value;
16
+ }
17
+
18
+ const LOOPBACK_HOSTS: Record<string, true> = { localhost: true, "127.0.0.1": true, "::1": true };
19
+
20
+ /**
21
+ * Parse, protocol-check, and confine an activity source base URL to a local
22
+ * loopback host. Shared with ActivityHttpSourceClient so config-load and client
23
+ * construction reject the exact same shapes with the same prefixed message (a
24
+ * bare `new URL()` throws an opaque TypeError on malformed input). The bearer
25
+ * token travels in an Authorization header, so a non-loopback baseUrl would
26
+ * exfiltrate it; the subsystem contract is local capture daemons only.
27
+ */
28
+ export function validateActivityBaseUrl(baseUrl: string): URL {
29
+ let parsed: URL;
30
+ try {
31
+ parsed = new URL(baseUrl);
32
+ } catch {
33
+ throw new RangeError(`activity source baseUrl must be a valid URL: ${baseUrl}`);
34
+ }
35
+ if (parsed.protocol !== "http:" && parsed.protocol !== "https:") {
36
+ throw new RangeError("activity source baseUrl must use HTTP or HTTPS");
37
+ }
38
+ // URL keeps IPv6 hosts bracketed (e.g. "[::1]"); normalize before the lookup.
39
+ const host = parsed.hostname.replace(/^\[|\]$/g, "");
40
+ if (LOOPBACK_HOSTS[host] !== true && !/^127\.\d{1,3}\.\d{1,3}\.\d{1,3}$/.test(host)) {
41
+ throw new RangeError(`activity source baseUrl must target a loopback host (got ${parsed.hostname})`);
42
+ }
43
+ return parsed;
44
+ }
45
+
46
+ function parseSource(value: unknown): ActivitySourceConfig {
47
+ const raw = asRecord(value, "activity source");
48
+ const machineLabel = optionalString(raw.machineLabel, "activity source machineLabel");
49
+ const baseUrl = optionalString(raw.baseUrl, "activity source baseUrl");
50
+ if (machineLabel === undefined || baseUrl === undefined) {
51
+ throw new TypeError("activity source requires machineLabel and baseUrl");
52
+ }
53
+ // Reject whitespace-only labels here so config-load fails loudly rather than
54
+ // parsing clean and then failing on the first sync (the client and pipeline
55
+ // both reject a blank label via trim()).
56
+ if (machineLabel.trim().length === 0) {
57
+ throw new RangeError("activity source machineLabel must not be blank");
58
+ }
59
+ validateActivityBaseUrl(baseUrl);
60
+ const token = optionalString(raw.token, "activity source token");
61
+ return { machineLabel, baseUrl, ...(token === undefined ? {} : { token }) };
62
+ }
63
+
64
+ export function parseActivityConfig(raw: unknown): ActivityConfig {
65
+ if (raw === undefined || raw === null) {
66
+ return { enabled: false, timezone: "UTC", syncDays: 1, autoSyncIntervalMinutes: 15, sources: [] };
67
+ }
68
+ const config = asRecord(raw, "activity");
69
+ const enabledValue = coerceBooleanLike(config.enabled, "activity.enabled");
70
+ if (config.enabled !== undefined && enabledValue === undefined) {
71
+ throw new TypeError("activity.enabled must be a boolean");
72
+ }
73
+ const timezone = optionalString(config.timezone, "activity.timezone") ?? "UTC";
74
+ // Validate the IANA zone at parse so a typo fails before any daemon is
75
+ // contacted; otherwise activityDayWindow() throws mid-sync after snapshot
76
+ // pages may already be persisted, and every retry replays the same window.
77
+ assertValidTimezone(timezone);
78
+ const syncDaysValue = coerceNumber(config.syncDays, "activity.syncDays");
79
+ if (config.syncDays !== undefined && syncDaysValue === undefined) {
80
+ throw new TypeError("activity.syncDays must be a finite number");
81
+ }
82
+ const syncDays = syncDaysValue ?? 1;
83
+ if (!Number.isInteger(syncDays) || syncDays < 1 || syncDays > 90) {
84
+ throw new RangeError("activity.syncDays must be an integer from 1 to 90");
85
+ }
86
+ const intervalValue = coerceNumber(config.autoSyncIntervalMinutes, "activity.autoSyncIntervalMinutes");
87
+ if (config.autoSyncIntervalMinutes !== undefined && intervalValue === undefined) {
88
+ throw new TypeError("activity.autoSyncIntervalMinutes must be a finite number");
89
+ }
90
+ const autoSyncIntervalMinutes = intervalValue ?? 15;
91
+ if (!Number.isInteger(autoSyncIntervalMinutes) || autoSyncIntervalMinutes < 1 || autoSyncIntervalMinutes > 1440) {
92
+ throw new RangeError("activity.autoSyncIntervalMinutes must be an integer from 1 to 1440");
93
+ }
94
+ if (config.sources !== undefined && !Array.isArray(config.sources)) {
95
+ throw new TypeError("activity.sources must be an array");
96
+ }
97
+ const sources = (config.sources ?? []).map(parseSource);
98
+ // Cursors and row dedup are keyed on machineLabel alone; two sources sharing
99
+ // a label would share a cursor and dedup namespace, silently skipping or
100
+ // conflating snapshots. Reject the collision at parse.
101
+ const labels = new Set<string>();
102
+ for (const source of sources) {
103
+ if (labels.has(source.machineLabel)) {
104
+ throw new RangeError(`activity source machineLabel must be unique: ${source.machineLabel}`);
105
+ }
106
+ labels.add(source.machineLabel);
107
+ }
108
+ const enabled = enabledValue ?? false;
109
+ if (enabled && sources.length === 0) throw new RangeError("activity.enabled requires at least one source");
110
+ return { enabled, timezone, syncDays, autoSyncIntervalMinutes, sources };
111
+ }
@@ -55,11 +55,11 @@ function timezoneOffsetIso(instant: Date, timezone: string): string {
55
55
  return match?.[1] ?? "+00:00";
56
56
  }
57
57
 
58
- function assertValidTimezone(timezone: string): void {
58
+ export function assertValidTimezone(timezone: string): void {
59
59
  try {
60
60
  new Intl.DateTimeFormat("en-US", { timeZone: timezone });
61
61
  } catch {
62
- throw new RangeError(`Invalid IANA timezone "${timezone}" for the activity digest.`);
62
+ throw new RangeError(`Invalid IANA timezone "${timezone}".`);
63
63
  }
64
64
  }
65
65
 
@@ -7,3 +7,9 @@
7
7
  export * from "./types.js";
8
8
  export * from "./store.js";
9
9
  export * from "./digest.js";
10
+ export * from "./pipeline.js";
11
+ export * from "./source-client.js";
12
+ export * from "./runner.js";
13
+ export * from "./scheduler.js";
14
+ export * from "./config.js";
15
+ export * from "./reindex.js";