@remnic/core 1.0.1 → 1.0.3

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 (347) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +48 -0
  3. package/dist/access-cli.d.ts +13 -3
  4. package/dist/access-cli.js +90 -75
  5. package/dist/access-cli.js.map +1 -1
  6. package/dist/access-http.d.ts +10 -3
  7. package/dist/access-http.js +25 -18
  8. package/dist/access-mcp.d.ts +30 -3
  9. package/dist/access-mcp.js +16 -1
  10. package/dist/access-schema.d.ts +46 -46
  11. package/dist/access-schema.js +1 -1
  12. package/dist/access-service.d.ts +65 -4
  13. package/dist/access-service.js +21 -15
  14. package/dist/active-memory-bridge.d.ts +66 -0
  15. package/dist/active-memory-bridge.js +11 -0
  16. package/dist/active-recall.d.ts +96 -0
  17. package/dist/active-recall.js +308 -0
  18. package/dist/active-recall.js.map +1 -0
  19. package/dist/behavior-learner.js +1 -1
  20. package/dist/bootstrap.d.ts +6 -3
  21. package/dist/bootstrap.js +2 -2
  22. package/dist/boxes.js +2 -2
  23. package/dist/briefing.d.ts +169 -0
  24. package/dist/briefing.js +52 -0
  25. package/dist/briefing.js.map +1 -0
  26. package/dist/buffer.d.ts +19 -5
  27. package/dist/buffer.js +2 -2
  28. package/dist/calibration.js +6 -6
  29. package/dist/causal-behavior.js +5 -5
  30. package/dist/causal-chain.js +3 -3
  31. package/dist/causal-consolidation.d.ts +22 -2
  32. package/dist/causal-consolidation.js +36 -9
  33. package/dist/causal-consolidation.js.map +1 -1
  34. package/dist/causal-retrieval.js +6 -6
  35. package/dist/causal-trajectory-graph.js +1 -1
  36. package/dist/causal-trajectory.d.ts +14 -1
  37. package/dist/causal-trajectory.js +5 -1
  38. package/dist/{chunk-KWBU5S5U.js → chunk-2ODBA7MQ.js} +9 -3
  39. package/dist/chunk-2ODBA7MQ.js.map +1 -0
  40. package/dist/{chunk-6UJQNRIO.js → chunk-2VFW5K5U.js} +93 -36
  41. package/dist/chunk-2VFW5K5U.js.map +1 -0
  42. package/dist/chunk-3PG3H5TD.js +7 -0
  43. package/dist/chunk-3PG3H5TD.js.map +1 -0
  44. package/dist/{chunk-NTTLPF7F.js → chunk-3QFQGRHO.js} +5 -5
  45. package/dist/chunk-4DJQYKMN.js +187 -0
  46. package/dist/chunk-4DJQYKMN.js.map +1 -0
  47. package/dist/chunk-4KAN3GZ3.js +225 -0
  48. package/dist/chunk-4KAN3GZ3.js.map +1 -0
  49. package/dist/{chunk-ORZMT74A.js → chunk-4NRAJUDS.js} +11 -1
  50. package/dist/chunk-4NRAJUDS.js.map +1 -0
  51. package/dist/{chunk-B7LOFDVE.js → chunk-4WMCPJWX.js} +8 -3
  52. package/dist/chunk-4WMCPJWX.js.map +1 -0
  53. package/dist/{chunk-G3AG3KZN.js → chunk-5IZL4DCV.js} +2 -2
  54. package/dist/{chunk-BRK4ODMI.js → chunk-5NPGSAVB.js} +2 -2
  55. package/dist/chunk-6MKAMLQL.js +16 -0
  56. package/dist/chunk-6MKAMLQL.js.map +1 -0
  57. package/dist/{chunk-ESSMF2FR.js → chunk-6PFRXT4K.js} +15 -6
  58. package/dist/chunk-6PFRXT4K.js.map +1 -0
  59. package/dist/chunk-6ZH4TU6I.js +245 -0
  60. package/dist/chunk-6ZH4TU6I.js.map +1 -0
  61. package/dist/{chunk-V4YC4LUK.js → chunk-74JR4N5J.js} +175 -63
  62. package/dist/chunk-74JR4N5J.js.map +1 -0
  63. package/dist/{chunk-L5RPWGFK.js → chunk-7DHTMOND.js} +2 -2
  64. package/dist/{chunk-TVVVQQAK.js → chunk-7PA4OZEU.js} +53 -11
  65. package/dist/chunk-7PA4OZEU.js.map +1 -0
  66. package/dist/{chunk-Q6FETXJA.js → chunk-7SEAZFFB.js} +2 -2
  67. package/dist/chunk-ALXMCZEU.js +332 -0
  68. package/dist/chunk-ALXMCZEU.js.map +1 -0
  69. package/dist/{chunk-QANCTXQF.js → chunk-AYPYCLR7.js} +3 -3
  70. package/dist/{chunk-WWIQTB2Y.js → chunk-BKQJBXXX.js} +9 -2
  71. package/dist/chunk-BKQJBXXX.js.map +1 -0
  72. package/dist/{chunk-LP47L3ZX.js → chunk-BTY5RRRF.js} +7 -7
  73. package/dist/{chunk-SCHEKPYH.js → chunk-C2EFFULQ.js} +1 -1
  74. package/dist/{chunk-GJR6D6KC.js → chunk-D654IBA6.js} +2 -2
  75. package/dist/{chunk-UV2FO7J4.js → chunk-E6K4NIEU.js} +2 -2
  76. package/dist/{chunk-T4WRIV2C.js → chunk-EABGC2TL.js} +2 -2
  77. package/dist/chunk-ECKDIK5F.js +813 -0
  78. package/dist/chunk-ECKDIK5F.js.map +1 -0
  79. package/dist/chunk-EJI5XIBB.js +232 -0
  80. package/dist/chunk-EJI5XIBB.js.map +1 -0
  81. package/dist/{chunk-ONRU4L2N.js → chunk-FEMOX5AD.js} +2 -2
  82. package/dist/{chunk-IFFFR3MR.js → chunk-FSFEQI74.js} +3 -3
  83. package/dist/chunk-G4SK7DSQ.js +121 -0
  84. package/dist/chunk-G4SK7DSQ.js.map +1 -0
  85. package/dist/{chunk-UIYZ5T3I.js → chunk-GJQPH5G3.js} +8 -8
  86. package/dist/{chunk-2PO5ZRKV.js → chunk-GZCUW5IC.js} +16 -3
  87. package/dist/chunk-GZCUW5IC.js.map +1 -0
  88. package/dist/{chunk-IZME7KW2.js → chunk-HITJFT7E.js} +24 -10
  89. package/dist/{chunk-IZME7KW2.js.map → chunk-HITJFT7E.js.map} +1 -1
  90. package/dist/chunk-IQT3XTKW.js +121 -0
  91. package/dist/chunk-IQT3XTKW.js.map +1 -0
  92. package/dist/{chunk-BDFZXRSO.js → chunk-J4IYOZZ5.js} +15 -2
  93. package/dist/chunk-J4IYOZZ5.js.map +1 -0
  94. package/dist/{chunk-ZKYI7UVO.js → chunk-JR4ZC3G4.js} +2 -2
  95. package/dist/{chunk-UCYSTFZR.js → chunk-JRNQ3RNA.js} +2 -2
  96. package/dist/{chunk-UYSKNO6E.js → chunk-JROGC36Y.js} +15 -4
  97. package/dist/chunk-JROGC36Y.js.map +1 -0
  98. package/dist/{chunk-GPGBSNKM.js → chunk-K4FLSOR5.js} +2 -2
  99. package/dist/{chunk-M5ZBBBJI.js → chunk-KEG4GNGI.js} +2 -2
  100. package/dist/chunk-KVE7R4CG.js +320 -0
  101. package/dist/chunk-KVE7R4CG.js.map +1 -0
  102. package/dist/{chunk-L7WO3MZ4.js → chunk-KWP7T3DP.js} +2 -2
  103. package/dist/chunk-LAYN4LDC.js +267 -0
  104. package/dist/chunk-LAYN4LDC.js.map +1 -0
  105. package/dist/{chunk-PGK3VUHN.js → chunk-MTLYEMJB.js} +3 -2
  106. package/dist/chunk-MTLYEMJB.js.map +1 -0
  107. package/dist/{chunk-J47FNDR7.js → chunk-MYQWXITD.js} +7 -7
  108. package/dist/{chunk-YNI4S5WT.js → chunk-N53K2EXC.js} +2 -2
  109. package/dist/{chunk-763GUIOU.js → chunk-NBNN5GOB.js} +2 -2
  110. package/dist/{chunk-CXWFUJR2.js → chunk-NSB3WSYS.js} +125 -6
  111. package/dist/chunk-NSB3WSYS.js.map +1 -0
  112. package/dist/{chunk-KL4CP4SB.js → chunk-O5ETUNBT.js} +17 -5
  113. package/dist/chunk-O5ETUNBT.js.map +1 -0
  114. package/dist/{chunk-OOSWAUYB.js → chunk-ODWDQNRE.js} +2 -2
  115. package/dist/{chunk-ISY75RLM.js → chunk-OJFGVJS6.js} +288 -7
  116. package/dist/chunk-OJFGVJS6.js.map +1 -0
  117. package/dist/{chunk-HLBYLYRD.js → chunk-PAORGQRI.js} +70 -13
  118. package/dist/chunk-PAORGQRI.js.map +1 -0
  119. package/dist/{chunk-ZJLY4QSU.js → chunk-PMB3WGDL.js} +69 -6
  120. package/dist/chunk-PMB3WGDL.js.map +1 -0
  121. package/dist/{chunk-J3BT33K7.js → chunk-POBPGDWI.js} +5 -5
  122. package/dist/{chunk-QWUUMMIK.js → chunk-POMSFKTB.js} +1351 -76
  123. package/dist/chunk-POMSFKTB.js.map +1 -0
  124. package/dist/{chunk-OTAVQCSF.js → chunk-PYXS46O7.js} +2 -2
  125. package/dist/chunk-QDW3E4RD.js +108 -0
  126. package/dist/chunk-QDW3E4RD.js.map +1 -0
  127. package/dist/{chunk-YNCQ7E4M.js → chunk-QDYXG4CS.js} +4 -3
  128. package/dist/chunk-QDYXG4CS.js.map +1 -0
  129. package/dist/{chunk-XUHI52HK.js → chunk-QKAH5B6E.js} +4 -4
  130. package/dist/{chunk-HLXVTBF3.js → chunk-QNJMBKFK.js} +3 -2
  131. package/dist/chunk-QNJMBKFK.js.map +1 -0
  132. package/dist/chunk-RCICHSHL.js +789 -0
  133. package/dist/chunk-RCICHSHL.js.map +1 -0
  134. package/dist/{chunk-HG2NKWR2.js → chunk-S4LX5EBI.js} +2 -2
  135. package/dist/{chunk-4A24LIM2.js → chunk-S75M5ZRK.js} +2 -2
  136. package/dist/{chunk-QCCCQT3O.js → chunk-TBBDFYXW.js} +2 -2
  137. package/dist/chunk-TBBDFYXW.js.map +1 -0
  138. package/dist/{chunk-U4PV25RD.js → chunk-U2IQTSBY.js} +1 -1
  139. package/dist/chunk-U2IQTSBY.js.map +1 -0
  140. package/dist/chunk-U66YHYC7.js +31 -0
  141. package/dist/chunk-U66YHYC7.js.map +1 -0
  142. package/dist/{chunk-MWGVGUIS.js → chunk-UEYA6UC7.js} +36 -4
  143. package/dist/chunk-UEYA6UC7.js.map +1 -0
  144. package/dist/{chunk-MDDAA2AO.js → chunk-UPMD5XND.js} +2 -2
  145. package/dist/{chunk-M5KEYE5E.js → chunk-URB2WSKZ.js} +2 -2
  146. package/dist/chunk-UVJFDP7P.js +202 -0
  147. package/dist/chunk-UVJFDP7P.js.map +1 -0
  148. package/dist/{chunk-QY2BHY5O.js → chunk-V7XCAHIB.js} +265 -25
  149. package/dist/chunk-V7XCAHIB.js.map +1 -0
  150. package/dist/chunk-W6SL7OFG.js +180 -0
  151. package/dist/chunk-W6SL7OFG.js.map +1 -0
  152. package/dist/{chunk-QDOSNLB4.js → chunk-X4WESCKA.js} +17 -15
  153. package/dist/chunk-X4WESCKA.js.map +1 -0
  154. package/dist/{chunk-OTFNI3OO.js → chunk-XMGSSBFX.js} +1738 -383
  155. package/dist/chunk-XMGSSBFX.js.map +1 -0
  156. package/dist/chunk-YDBIWGNI.js +298 -0
  157. package/dist/chunk-YDBIWGNI.js.map +1 -0
  158. package/dist/chunk-YFYL2SIJ.js +7857 -0
  159. package/dist/chunk-YFYL2SIJ.js.map +1 -0
  160. package/dist/chunking.js +1 -1
  161. package/dist/citations.d.ts +67 -0
  162. package/dist/citations.js +13 -0
  163. package/dist/citations.js.map +1 -0
  164. package/dist/cli-DwIBnp2g.d.ts +1240 -0
  165. package/dist/cli.d.ts +31 -1147
  166. package/dist/cli.js +149 -7092
  167. package/dist/cli.js.map +1 -1
  168. package/dist/codex-materialize-CQlLTzke.d.ts +139 -0
  169. package/dist/codex-thread-key.d.ts +3 -0
  170. package/dist/codex-thread-key.js +7 -0
  171. package/dist/codex-thread-key.js.map +1 -0
  172. package/dist/config.js +3 -2
  173. package/dist/connectors/codex/instructions.md +160 -0
  174. package/dist/connectors/codex/resources/namespace-cheatsheet.md +48 -0
  175. package/dist/day-summary.d.ts +7 -2
  176. package/dist/day-summary.js +5 -2
  177. package/dist/embedding-fallback.d.ts +96 -2
  178. package/dist/embedding-fallback.js +6 -4
  179. package/dist/{engine-2A6J4XEX.js → engine-X7X3AAG3.js} +10 -7
  180. package/dist/engine-X7X3AAG3.js.map +1 -0
  181. package/dist/entity-retrieval.d.ts +3 -2
  182. package/dist/entity-retrieval.js +10 -7
  183. package/dist/entity-schema.d.ts +11 -0
  184. package/dist/entity-schema.js +19 -0
  185. package/dist/entity-schema.js.map +1 -0
  186. package/dist/explicit-capture.d.ts +6 -3
  187. package/dist/explicit-capture.js +2 -2
  188. package/dist/extraction-judge.d.ts +66 -0
  189. package/dist/extraction-judge.js +18 -0
  190. package/dist/extraction-judge.js.map +1 -0
  191. package/dist/extraction.d.ts +1 -0
  192. package/dist/extraction.js +12 -10
  193. package/dist/fallback-llm.js +4 -4
  194. package/dist/graph.js +1 -1
  195. package/dist/importance.d.ts +11 -1
  196. package/dist/importance.js +3 -1
  197. package/dist/index.d.ts +1140 -8
  198. package/dist/index.js +3350 -333
  199. package/dist/index.js.map +1 -1
  200. package/dist/intent.d.ts +2 -1
  201. package/dist/intent.js +3 -1
  202. package/dist/lifecycle.js +1 -1
  203. package/dist/local-llm.js +2 -2
  204. package/dist/logger.d.ts +1 -1
  205. package/dist/logger.js +1 -1
  206. package/dist/memory-cache.d.ts +2 -2
  207. package/dist/memory-cache.js +1 -1
  208. package/dist/{memory-projection-store-NxMkbocT.d.ts → memory-projection-store-DeSXPh1j.d.ts} +1 -1
  209. package/dist/memory-projection-store.d.ts +1 -1
  210. package/dist/model-registry.js +2 -2
  211. package/dist/models-json.js +2 -2
  212. package/dist/native-knowledge.js +2 -2
  213. package/dist/negative.js +2 -2
  214. package/dist/operator-toolkit.js +20 -16
  215. package/dist/{orchestrator-CIvLFHx3.d.ts → orchestrator-B9kwlCep.d.ts} +254 -9
  216. package/dist/orchestrator.d.ts +6 -3
  217. package/dist/orchestrator.js +70 -58
  218. package/dist/page-versioning.d.ts +77 -0
  219. package/dist/page-versioning.js +15 -0
  220. package/dist/page-versioning.js.map +1 -0
  221. package/dist/plugin-id.d.ts +37 -0
  222. package/dist/plugin-id.js +11 -0
  223. package/dist/plugin-id.js.map +1 -0
  224. package/dist/policy-runtime.js +2 -2
  225. package/dist/profiling.js +2 -2
  226. package/dist/qmd.d.ts +5 -2
  227. package/dist/qmd.js +3 -3
  228. package/dist/recall-audit.d.ts +20 -0
  229. package/dist/recall-audit.js +50 -0
  230. package/dist/recall-audit.js.map +1 -0
  231. package/dist/recall-mmr.d.ts +152 -0
  232. package/dist/recall-mmr.js +17 -0
  233. package/dist/recall-mmr.js.map +1 -0
  234. package/dist/recall-qos.js +2 -2
  235. package/dist/recall-state.js +2 -2
  236. package/dist/relevance.js +2 -2
  237. package/dist/resolve-provider-secret.js +2 -2
  238. package/dist/resume-bundles.js +5 -4
  239. package/dist/retrieval-agents.js +2 -2
  240. package/dist/retrieval.js +2 -2
  241. package/dist/schemas.d.ts +422 -64
  242. package/dist/schemas.js +3 -1
  243. package/dist/sdk-compat.d.ts +2 -0
  244. package/dist/sdk-compat.js +6 -3
  245. package/dist/sdk-compat.js.map +1 -1
  246. package/dist/semantic-chunking.d.ts +87 -0
  247. package/dist/semantic-chunking.js +20 -0
  248. package/dist/semantic-chunking.js.map +1 -0
  249. package/dist/semantic-consolidation-DrvSYRdB.d.ts +119 -0
  250. package/dist/semantic-consolidation.d.ts +4 -42
  251. package/dist/semantic-consolidation.js +23 -2
  252. package/dist/semantic-rule-promotion.js +9 -6
  253. package/dist/semantic-rule-verifier.js +10 -7
  254. package/dist/session-observer-state.js +2 -2
  255. package/dist/session-toggles.d.ts +22 -0
  256. package/dist/session-toggles.js +116 -0
  257. package/dist/session-toggles.js.map +1 -0
  258. package/dist/skills-registry.d.ts +47 -0
  259. package/dist/skills-registry.js +48 -0
  260. package/dist/skills-registry.js.map +1 -0
  261. package/dist/source-attribution.d.ts +169 -0
  262. package/dist/source-attribution.js +27 -0
  263. package/dist/source-attribution.js.map +1 -0
  264. package/dist/storage.d.ts +171 -10
  265. package/dist/storage.js +16 -5
  266. package/dist/summarizer.js +7 -7
  267. package/dist/temporal-supersession.d.ts +127 -0
  268. package/dist/temporal-supersession.js +20 -0
  269. package/dist/temporal-supersession.js.map +1 -0
  270. package/dist/threading.js +2 -2
  271. package/dist/tier-migration.d.ts +2 -1
  272. package/dist/tier-routing.js +2 -2
  273. package/dist/tokens.d.ts +21 -1
  274. package/dist/tokens.js +5 -1
  275. package/dist/transcript.js +2 -2
  276. package/dist/types.d.ts +497 -3
  277. package/dist/types.js +1 -1
  278. package/dist/utility-learner.js +2 -2
  279. package/dist/utility-runtime.js +3 -3
  280. package/dist/verified-recall.js +11 -8
  281. package/dist/whitespace.d.ts +4 -0
  282. package/dist/whitespace.js +9 -0
  283. package/dist/whitespace.js.map +1 -0
  284. package/package.json +14 -8
  285. package/dist/chunk-2CJCWDMR.js +0 -87
  286. package/dist/chunk-2CJCWDMR.js.map +0 -1
  287. package/dist/chunk-2PO5ZRKV.js.map +0 -1
  288. package/dist/chunk-6UJQNRIO.js.map +0 -1
  289. package/dist/chunk-B7LOFDVE.js.map +0 -1
  290. package/dist/chunk-BDFZXRSO.js.map +0 -1
  291. package/dist/chunk-CXWFUJR2.js.map +0 -1
  292. package/dist/chunk-DORBM6OB.js +0 -81
  293. package/dist/chunk-DORBM6OB.js.map +0 -1
  294. package/dist/chunk-ESSMF2FR.js.map +0 -1
  295. package/dist/chunk-HLBYLYRD.js.map +0 -1
  296. package/dist/chunk-HLXVTBF3.js.map +0 -1
  297. package/dist/chunk-ISY75RLM.js.map +0 -1
  298. package/dist/chunk-KL4CP4SB.js.map +0 -1
  299. package/dist/chunk-KWBU5S5U.js.map +0 -1
  300. package/dist/chunk-MWGVGUIS.js.map +0 -1
  301. package/dist/chunk-ORZMT74A.js.map +0 -1
  302. package/dist/chunk-OTFNI3OO.js.map +0 -1
  303. package/dist/chunk-PGK3VUHN.js.map +0 -1
  304. package/dist/chunk-QCCCQT3O.js.map +0 -1
  305. package/dist/chunk-QDOSNLB4.js.map +0 -1
  306. package/dist/chunk-QPKFPHOO.js +0 -178
  307. package/dist/chunk-QPKFPHOO.js.map +0 -1
  308. package/dist/chunk-QWUUMMIK.js.map +0 -1
  309. package/dist/chunk-QY2BHY5O.js.map +0 -1
  310. package/dist/chunk-TVVVQQAK.js.map +0 -1
  311. package/dist/chunk-U4PV25RD.js.map +0 -1
  312. package/dist/chunk-UYSKNO6E.js.map +0 -1
  313. package/dist/chunk-V4YC4LUK.js.map +0 -1
  314. package/dist/chunk-WWIQTB2Y.js.map +0 -1
  315. package/dist/chunk-YNCQ7E4M.js.map +0 -1
  316. package/dist/chunk-ZJLY4QSU.js.map +0 -1
  317. /package/dist/{engine-2A6J4XEX.js.map → active-memory-bridge.js.map} +0 -0
  318. /package/dist/{chunk-NTTLPF7F.js.map → chunk-3QFQGRHO.js.map} +0 -0
  319. /package/dist/{chunk-G3AG3KZN.js.map → chunk-5IZL4DCV.js.map} +0 -0
  320. /package/dist/{chunk-BRK4ODMI.js.map → chunk-5NPGSAVB.js.map} +0 -0
  321. /package/dist/{chunk-L5RPWGFK.js.map → chunk-7DHTMOND.js.map} +0 -0
  322. /package/dist/{chunk-Q6FETXJA.js.map → chunk-7SEAZFFB.js.map} +0 -0
  323. /package/dist/{chunk-QANCTXQF.js.map → chunk-AYPYCLR7.js.map} +0 -0
  324. /package/dist/{chunk-LP47L3ZX.js.map → chunk-BTY5RRRF.js.map} +0 -0
  325. /package/dist/{chunk-SCHEKPYH.js.map → chunk-C2EFFULQ.js.map} +0 -0
  326. /package/dist/{chunk-GJR6D6KC.js.map → chunk-D654IBA6.js.map} +0 -0
  327. /package/dist/{chunk-UV2FO7J4.js.map → chunk-E6K4NIEU.js.map} +0 -0
  328. /package/dist/{chunk-T4WRIV2C.js.map → chunk-EABGC2TL.js.map} +0 -0
  329. /package/dist/{chunk-ONRU4L2N.js.map → chunk-FEMOX5AD.js.map} +0 -0
  330. /package/dist/{chunk-IFFFR3MR.js.map → chunk-FSFEQI74.js.map} +0 -0
  331. /package/dist/{chunk-UIYZ5T3I.js.map → chunk-GJQPH5G3.js.map} +0 -0
  332. /package/dist/{chunk-ZKYI7UVO.js.map → chunk-JR4ZC3G4.js.map} +0 -0
  333. /package/dist/{chunk-UCYSTFZR.js.map → chunk-JRNQ3RNA.js.map} +0 -0
  334. /package/dist/{chunk-GPGBSNKM.js.map → chunk-K4FLSOR5.js.map} +0 -0
  335. /package/dist/{chunk-M5ZBBBJI.js.map → chunk-KEG4GNGI.js.map} +0 -0
  336. /package/dist/{chunk-L7WO3MZ4.js.map → chunk-KWP7T3DP.js.map} +0 -0
  337. /package/dist/{chunk-J47FNDR7.js.map → chunk-MYQWXITD.js.map} +0 -0
  338. /package/dist/{chunk-YNI4S5WT.js.map → chunk-N53K2EXC.js.map} +0 -0
  339. /package/dist/{chunk-763GUIOU.js.map → chunk-NBNN5GOB.js.map} +0 -0
  340. /package/dist/{chunk-OOSWAUYB.js.map → chunk-ODWDQNRE.js.map} +0 -0
  341. /package/dist/{chunk-J3BT33K7.js.map → chunk-POBPGDWI.js.map} +0 -0
  342. /package/dist/{chunk-OTAVQCSF.js.map → chunk-PYXS46O7.js.map} +0 -0
  343. /package/dist/{chunk-XUHI52HK.js.map → chunk-QKAH5B6E.js.map} +0 -0
  344. /package/dist/{chunk-HG2NKWR2.js.map → chunk-S4LX5EBI.js.map} +0 -0
  345. /package/dist/{chunk-4A24LIM2.js.map → chunk-S75M5ZRK.js.map} +0 -0
  346. /package/dist/{chunk-MDDAA2AO.js.map → chunk-UPMD5XND.js.map} +0 -0
  347. /package/dist/{chunk-M5KEYE5E.js.map → chunk-URB2WSKZ.js.map} +0 -0
package/dist/types.d.ts CHANGED
@@ -1,7 +1,7 @@
1
1
  type ReasoningEffort = "none" | "low" | "medium" | "high";
2
2
  type TriggerMode = "smart" | "every_n" | "time_based";
3
3
  type SignalLevel = "none" | "low" | "medium" | "high";
4
- type MemoryCategory = "fact" | "preference" | "correction" | "entity" | "decision" | "relationship" | "principle" | "commitment" | "moment" | "skill" | "rule";
4
+ type MemoryCategory = "fact" | "preference" | "correction" | "entity" | "decision" | "relationship" | "principle" | "commitment" | "moment" | "skill" | "rule" | "procedure";
5
5
  type ConsolidationAction = "ADD" | "MERGE" | "UPDATE" | "INVALIDATE" | "SKIP";
6
6
  type ConfidenceTier = "explicit" | "implied" | "inferred" | "speculative";
7
7
  type PrincipalFromSessionKeyMode = "map" | "prefix" | "regex";
@@ -12,6 +12,42 @@ type IdentityInjectionMode = "recovery_only" | "minimal" | "full";
12
12
  type CaptureMode = "implicit" | "explicit" | "hybrid";
13
13
  type MemoryOsPresetName = "conservative" | "balanced" | "research-max" | "local-llm-heavy";
14
14
  type ExtractionPassSource = "base" | "proactive";
15
+ type SlotMismatchMode = "error" | "warn" | "silent";
16
+ type CodexCompactionFlushMode = "signal" | "heuristic" | "auto";
17
+ type DreamingNarrativePromptStyle = "reflective" | "diary" | "analytical";
18
+ type HeartbeatDetectionMode = "runtime-signal" | "heuristic" | "auto";
19
+ type ActiveRecallQueryMode = "message" | "recent" | "full";
20
+ type ActiveRecallPromptStyle = "balanced" | "strict" | "contextual" | "recall-heavy" | "precision-heavy" | "preference-only";
21
+ type ActiveRecallThinking = "off" | "minimal" | "low" | "medium" | "high" | "xhigh" | "adaptive";
22
+ type ActiveRecallChatType = "direct" | "group" | "channel";
23
+ type ActiveRecallModelFallbackPolicy = "default-remote" | "resolved-only";
24
+ /**
25
+ * Retrieval tier ladder (issue #518). Identifies which tier served a recall
26
+ * result. Ordered top-to-bottom by cost, but routing is not strictly
27
+ * sequential — callers may jump straight to a lower tier when eligibility
28
+ * does not hold.
29
+ */
30
+ type RetrievalTier = "exact-cache" | "fuzzy-cache" | "direct-answer" | "hybrid" | "rerank-graph" | "agentic";
31
+ /**
32
+ * Per-recall annotation describing which retrieval tier served a result,
33
+ * why that tier was chosen, and what was filtered along the way. Added as
34
+ * part of issue #518 (direct-answer tier + `query --explain`).
35
+ *
36
+ * Not to be confused with the existing `recallExplain` operation
37
+ * (graph-path explanation) — that is a user-invoked RPC; this is a
38
+ * per-result annotation that can be attached to any recall response.
39
+ */
40
+ interface RecallTierExplain {
41
+ tier: RetrievalTier;
42
+ tierReason: string;
43
+ filteredBy: string[];
44
+ candidatesConsidered: number;
45
+ latencyMs: number;
46
+ sourceAnchors?: Array<{
47
+ path: string;
48
+ lineRange?: [number, number];
49
+ }>;
50
+ }
15
51
  interface RecallSectionConfig {
16
52
  id: string;
17
53
  enabled?: boolean;
@@ -103,9 +139,67 @@ interface AgentAccessHttpConfig {
103
139
  principal?: string;
104
140
  maxBodyBytes: number;
105
141
  }
142
+ interface DreamingConfig {
143
+ enabled: boolean;
144
+ journalPath: string;
145
+ maxEntries: number;
146
+ injectRecentCount: number;
147
+ minIntervalMinutes: number;
148
+ narrativeModel: string | null;
149
+ narrativePromptStyle: DreamingNarrativePromptStyle;
150
+ watchFile: boolean;
151
+ }
152
+ /** Procedural memory (issue #519): mining + recall gates. All sub-features default off. */
153
+ interface ProceduralConfig {
154
+ enabled: boolean;
155
+ /** Minimum recurrence count before emitting a candidate procedure (0 disables mining threshold). */
156
+ minOccurrences: number;
157
+ /** Minimum success rate from trajectory outcomes in [0, 1]. */
158
+ successFloor: number;
159
+ /** When auto-promotion is enabled, promote pending_review → active after this many occurrences. */
160
+ autoPromoteOccurrences: number;
161
+ autoPromoteEnabled: boolean;
162
+ lookbackDays: number;
163
+ /** When true, installer may register the nightly procedural mining cron (default off). */
164
+ proceduralMiningCronAutoRegister: boolean;
165
+ /** Max procedure memories to inject on task-initiation recall (1–10). */
166
+ recallMaxProcedures: number;
167
+ }
168
+ interface HeartbeatConfig {
169
+ enabled: boolean;
170
+ journalPath: string;
171
+ maxPreviousRuns: number;
172
+ watchFile: boolean;
173
+ detectionMode: HeartbeatDetectionMode;
174
+ gateExtractionDuringHeartbeat: boolean;
175
+ }
176
+ interface SlotBehaviorConfig {
177
+ requireExclusiveMemorySlot: boolean;
178
+ onSlotMismatch: SlotMismatchMode;
179
+ }
180
+ interface CodexCompatConfig {
181
+ enabled: boolean;
182
+ threadIdBufferKeying: boolean;
183
+ compactionFlushMode: CodexCompactionFlushMode;
184
+ fingerprintDedup: boolean;
185
+ }
106
186
  declare function confidenceTier(score: number): ConfidenceTier;
107
187
  /** Default TTL in days for speculative memories (auto-expire if unconfirmed) */
108
188
  declare const SPECULATIVE_TTL_DAYS = 30;
189
+ /**
190
+ * Shape for semantic chunking config overrides stored in PluginConfig.
191
+ * Mirrors SemanticChunkingConfig from semantic-chunking.ts without creating
192
+ * a circular import (types.ts is imported by everything).
193
+ */
194
+ interface SemanticChunkingConfigShape {
195
+ targetTokens: number;
196
+ minTokens: number;
197
+ maxTokens: number;
198
+ smoothingWindowSize: number;
199
+ boundaryThresholdStdDevs: number;
200
+ embeddingBatchSize: number;
201
+ fallbackToRecursive: boolean;
202
+ }
109
203
  interface PluginConfig {
110
204
  openaiApiKey: string | undefined;
111
205
  openaiBaseUrl: string | undefined;
@@ -181,10 +275,52 @@ interface PluginConfig {
181
275
  chunkingTargetTokens: number;
182
276
  chunkingMinTokens: number;
183
277
  chunkingOverlapSentences: number;
278
+ /** Enable semantic chunking with embedding-based topic boundary detection. Default: false. */
279
+ semanticChunkingEnabled: boolean;
280
+ /** Optional overrides for the semantic chunking algorithm. */
281
+ semanticChunkingConfig: Partial<SemanticChunkingConfigShape>;
184
282
  contradictionDetectionEnabled: boolean;
185
283
  contradictionSimilarityThreshold: number;
186
284
  contradictionMinConfidence: number;
187
285
  contradictionAutoResolve: boolean;
286
+ /**
287
+ * When enabled, writes that carry `structuredAttributes` mark any older
288
+ * fact with the same `entityRef + attribute_name` supersession key and a
289
+ * conflicting value as `status: "superseded"`.
290
+ */
291
+ temporalSupersessionEnabled: boolean;
292
+ /**
293
+ * When enabled, superseded memories are still returned by recall (useful
294
+ * for audit/history queries). Default: false — superseded memories are
295
+ * filtered out.
296
+ */
297
+ temporalSupersessionIncludeInRecall: boolean;
298
+ /**
299
+ * When true, recall checks whether a single validated memory in a
300
+ * high-trust taxonomy bucket can answer the query before invoking QMD.
301
+ * Default false — enable explicitly after bench validation.
302
+ */
303
+ recallDirectAnswerEnabled: boolean;
304
+ /**
305
+ * Minimum token-overlap ratio (query tokens ∩ memory tokens / query tokens)
306
+ * required for direct-answer eligibility. Set to 0 to disable the gate.
307
+ */
308
+ recallDirectAnswerTokenOverlapFloor: number;
309
+ /**
310
+ * Minimum calibrated importance score required for direct-answer
311
+ * eligibility. Set to 0 to disable the gate.
312
+ */
313
+ recallDirectAnswerImportanceFloor: number;
314
+ /**
315
+ * Ambiguity margin: if the second-best candidate scores within this
316
+ * ratio of the top candidate, direct-answer defers to the hybrid tier.
317
+ */
318
+ recallDirectAnswerAmbiguityMargin: number;
319
+ /**
320
+ * Taxonomy category IDs eligible for direct-answer routing. Memories
321
+ * whose resolved taxonomy category is not in this list never qualify.
322
+ */
323
+ recallDirectAnswerEligibleTaxonomyBuckets: string[];
188
324
  memoryLinkingEnabled: boolean;
189
325
  threadingEnabled: boolean;
190
326
  threadingGapMinutes: number;
@@ -205,6 +341,53 @@ interface PluginConfig {
205
341
  checkpointEnabled: boolean;
206
342
  checkpointTurns: number;
207
343
  compactionResetEnabled: boolean;
344
+ beforeResetTimeoutMs: number;
345
+ flushOnResetEnabled: boolean;
346
+ commandsListEnabled: boolean;
347
+ openclawToolsEnabled: boolean;
348
+ openclawToolSnippetMaxChars: number;
349
+ sessionTogglesEnabled: boolean;
350
+ verboseRecallVisibility: boolean;
351
+ recallTranscriptsEnabled: boolean;
352
+ recallTranscriptRetentionDays: number;
353
+ respectBundledActiveMemoryToggle: boolean;
354
+ activeRecallEnabled: boolean;
355
+ activeRecallAgents: string[] | null;
356
+ activeRecallAllowedChatTypes: ActiveRecallChatType[];
357
+ activeRecallQueryMode: ActiveRecallQueryMode;
358
+ activeRecallPromptStyle: ActiveRecallPromptStyle;
359
+ activeRecallPromptOverride: string | null;
360
+ activeRecallPromptAppend: string | null;
361
+ activeRecallMaxSummaryChars: number;
362
+ activeRecallRecentUserTurns: number;
363
+ activeRecallRecentAssistantTurns: number;
364
+ activeRecallRecentUserChars: number;
365
+ activeRecallRecentAssistantChars: number;
366
+ activeRecallThinking: ActiveRecallThinking;
367
+ activeRecallTimeoutMs: number;
368
+ activeRecallCacheTtlMs: number;
369
+ activeRecallModel: string | null;
370
+ activeRecallModelFallbackPolicy: ActiveRecallModelFallbackPolicy;
371
+ activeRecallPersistTranscripts: boolean;
372
+ activeRecallTranscriptDir: string;
373
+ activeRecallEntityGraphDepth: number;
374
+ activeRecallIncludeCausalTrajectories: boolean;
375
+ activeRecallIncludeDaySummary: boolean;
376
+ activeRecallAttachRecallExplain: boolean;
377
+ activeRecallAllowChainedActiveMemory: boolean;
378
+ dreaming: DreamingConfig;
379
+ procedural: ProceduralConfig;
380
+ heartbeat: HeartbeatConfig;
381
+ slotBehavior: SlotBehaviorConfig;
382
+ codexCompat: CodexCompatConfig;
383
+ /** Enable the LLM-as-judge fact-worthiness gate on extracted facts. Default false (opt-in). */
384
+ extractionJudgeEnabled: boolean;
385
+ /** Model override for the judge LLM. Empty string means use the local model. */
386
+ extractionJudgeModel: string;
387
+ /** Maximum number of candidate facts per judge LLM batch call. */
388
+ extractionJudgeBatchSize: number;
389
+ /** Shadow mode: log judge verdicts but do not filter facts. Default false. */
390
+ extractionJudgeShadow: boolean;
208
391
  hourlySummariesEnabled: boolean;
209
392
  daySummaryEnabled: boolean;
210
393
  /** If true, Engram may attempt to auto-register an hourly summary cron job (default off). */
@@ -336,6 +519,29 @@ interface PluginConfig {
336
519
  extractionMaxEntitiesPerRun: number;
337
520
  extractionMaxQuestionsPerRun: number;
338
521
  extractionMaxProfileUpdatesPerRun: number;
522
+ /**
523
+ * Minimum importance level required to persist an extracted fact. Facts
524
+ * whose locally-scored level falls below this threshold are dropped before
525
+ * write and counted toward the `importance_gated` metric. Defaults to
526
+ * "low" so trivial content (greetings, single-word replies, filler) is
527
+ * silently dropped while everything else still passes.
528
+ */
529
+ extractionMinImportanceLevel: ImportanceLevel;
530
+ /**
531
+ * Inline source attribution (issue #369).
532
+ * When enabled, extracted facts carry a compact provenance tag (agent,
533
+ * session, timestamp) inlined into the fact text — not just in YAML
534
+ * frontmatter — so the citation survives prompt injection, copy/paste,
535
+ * and LLM quoting. Off by default to preserve backwards compatibility
536
+ * with existing downstream consumers that expect raw fact text.
537
+ */
538
+ inlineSourceAttributionEnabled: boolean;
539
+ /**
540
+ * Template used when injecting inline citations. Supported placeholders:
541
+ * `{agent}`, `{session}`, `{sessionId}`, `{ts}`, `{date}`. Defaults to
542
+ * `[Source: agent={agent}, session={sessionId}, ts={ts}]`.
543
+ */
544
+ inlineSourceAttributionFormat: string;
339
545
  consolidationRequireNonZeroExtraction: boolean;
340
546
  consolidationMinIntervalMs: number;
341
547
  qmdMaintenanceEnabled: boolean;
@@ -440,11 +646,18 @@ interface PluginConfig {
440
646
  entityRetrievalMaxSupportingFacts: number;
441
647
  entityRetrievalMaxRelatedEntities: number;
442
648
  entityRetrievalRecentTurns: number;
649
+ entitySchemas?: Record<string, EntitySchemaDefinition>;
443
650
  recallBudgetChars: number;
444
651
  recallOuterTimeoutMs: number;
445
652
  recallCoreDeadlineMs: number;
446
653
  recallEnrichmentDeadlineMs: number;
447
654
  recallPipeline: RecallSectionConfig[];
655
+ /** Apply Maximal Marginal Relevance to the final recall selection per-section. */
656
+ recallMmrEnabled: boolean;
657
+ /** MMR λ parameter. 1.0 = pure relevance, 0.0 = pure diversity. Default 0.7. */
658
+ recallMmrLambda: number;
659
+ /** MMR is applied over the top N candidates per section. Default 40. */
660
+ recallMmrTopN: number;
448
661
  qmdRecallCacheTtlMs: number;
449
662
  qmdRecallCacheStaleTtlMs: number;
450
663
  qmdRecallCacheMaxEntries: number;
@@ -453,8 +666,22 @@ interface PluginConfig {
453
666
  entityActivityLogMaxEntries: number;
454
667
  entityAliasesEnabled: boolean;
455
668
  entitySummaryEnabled: boolean;
669
+ entitySynthesisMaxTokens: number;
456
670
  /** Enable content-hash deduplication to prevent storing semantically identical facts. */
457
671
  factDeduplicationEnabled: boolean;
672
+ /**
673
+ * Issue #373 — Write-time semantic similarity guard. When enabled (default),
674
+ * the orchestrator embeds each candidate fact and queries the existing
675
+ * embedding index for its top-K nearest neighbors. If the best cosine
676
+ * similarity is at or above `semanticDedupThreshold`, the fact is dropped
677
+ * as a near-duplicate. Fails open (keeps the fact) if the embedding backend
678
+ * is unavailable.
679
+ */
680
+ semanticDedupEnabled: boolean;
681
+ /** Cosine similarity threshold in [0, 1] above which a candidate fact is skipped. */
682
+ semanticDedupThreshold: number;
683
+ /** Number of nearest-neighbor candidates to consider during semantic dedup. */
684
+ semanticDedupCandidates: number;
458
685
  /** Enable automatic archival of old, low-importance, rarely-accessed facts. */
459
686
  factArchivalEnabled: boolean;
460
687
  /** Minimum age in days before a fact is eligible for archival. */
@@ -627,6 +854,187 @@ interface PluginConfig {
627
854
  };
628
855
  /** Max results fetched per agent before merge. */
629
856
  parallelMaxResultsPerAgent: number;
857
+ /** Briefing configuration knobs — see BriefingConfig for field docs. */
858
+ briefing: BriefingConfig;
859
+ codex: CodexConnectorConfig;
860
+ /** Enable the MECE taxonomy knowledge directory. Default false. */
861
+ taxonomyEnabled: boolean;
862
+ /** Auto-regenerate RESOLVER.md when taxonomy changes. Default true. */
863
+ taxonomyAutoGenResolver: boolean;
864
+ /** Materialize Remnic memories into Codex's expected ~/.codex/memories/ layout. Default true. */
865
+ codexMaterializeMemories: boolean;
866
+ /** Namespace to materialize; "auto" derives from the connector context. Default "auto". */
867
+ codexMaterializeNamespace: string;
868
+ /** Max whitespace-tokenized size of memory_summary.md. Default 4500. */
869
+ codexMaterializeMaxSummaryTokens: number;
870
+ /** Max age in days for rollout_summaries/*.md before pruning. Default 30. */
871
+ codexMaterializeRolloutRetentionDays: number;
872
+ /** Run materialization after semantic/causal consolidation completes. Default true. */
873
+ codexMaterializeOnConsolidation: boolean;
874
+ /** Run materialization at Codex session-end hook. Default true. */
875
+ codexMaterializeOnSessionEnd: boolean;
876
+ /** Enable Codex marketplace integration. Default true. */
877
+ codexMarketplaceEnabled: boolean;
878
+ /** Enable page-level versioning with sidecar snapshots. Default false. */
879
+ versioningEnabled: boolean;
880
+ /** Maximum number of version snapshots to keep per page. Default 50. Set to 0 to disable pruning. */
881
+ versioningMaxPerPage: number;
882
+ /** Name of the sidecar directory inside memoryDir. Default ".versions". */
883
+ versioningSidecarDir: string;
884
+ /** Enable binary file lifecycle management (mirror, redirect, clean). Default: false. */
885
+ binaryLifecycleEnabled: boolean;
886
+ /** Grace period in days before a mirrored binary is eligible for local cleanup. Default: 7. */
887
+ binaryLifecycleGracePeriodDays: number;
888
+ /** Storage backend type: "filesystem" copies to a local dir, "none" is no-op. Default: "none". */
889
+ binaryLifecycleBackendType: "filesystem" | "s3" | "none";
890
+ /** Base path for the filesystem backend. Required when backendType is "filesystem". */
891
+ binaryLifecycleBackendPath: string;
892
+ /** Enable oai-mem-citation blocks in recall responses. Default false. */
893
+ citationsEnabled: boolean;
894
+ /** Auto-enable citations when the Codex adapter is detected. Default true. */
895
+ citationsAutoDetect: boolean;
896
+ /** Enable the external enrichment pipeline. Default false. */
897
+ enrichmentEnabled: boolean;
898
+ /** Automatically enrich new entities on creation. Default false. */
899
+ enrichmentAutoOnCreate: boolean;
900
+ /** Max candidates accepted per entity per enrichment run. Default 20. */
901
+ enrichmentMaxCandidatesPerEntity: number;
902
+ /** Whether third-party memory extensions are discovered and injected into consolidation. Default true. */
903
+ memoryExtensionsEnabled: boolean;
904
+ /**
905
+ * Root directory for memory extensions. Empty string means derive from
906
+ * memoryDir: go up to the Remnic home dir and append memory_extensions.
907
+ */
908
+ memoryExtensionsRoot: string;
909
+ }
910
+ /** Runtime configuration for the daily context briefing feature. */
911
+ interface BriefingConfig {
912
+ /** Whether `remnic briefing` CLI and MCP tool are enabled. */
913
+ enabled: boolean;
914
+ /** Default lookback window token (e.g. "yesterday", "3d", "1w", "24h"). */
915
+ defaultWindow: string;
916
+ /** Default output format for the CLI. */
917
+ defaultFormat: "markdown" | "json";
918
+ /** Maximum number of LLM-generated suggested follow-ups. */
919
+ maxFollowups: number;
920
+ /** Optional path to an ICS or JSON calendar file. null disables the section. */
921
+ calendarSource: string | null;
922
+ /** If true, CLI writes a dated briefing file by default. */
923
+ saveByDefault: boolean;
924
+ /** Override directory for saved briefings. null → $REMNIC_HOME/briefings/. */
925
+ saveDir: string | null;
926
+ /** Whether to call the Responses API for follow-up suggestions. */
927
+ llmFollowups: boolean;
928
+ }
929
+ /** Parsed representation of a briefing lookback window. */
930
+ type BriefingWindow = "yesterday" | "today" | string;
931
+ /** Filter the briefing to a single entity / project / topic. */
932
+ interface BriefingFocus {
933
+ type: "person" | "project" | "topic";
934
+ value: string;
935
+ }
936
+ /** Calendar event surfaced by a CalendarSource implementation. */
937
+ interface CalendarEvent {
938
+ /** Stable identifier for dedupe / linking. */
939
+ id: string;
940
+ /** Event title (short). */
941
+ title: string;
942
+ /** ISO 8601 start timestamp. */
943
+ start: string;
944
+ /** Optional ISO 8601 end timestamp. */
945
+ end?: string;
946
+ /** Optional freeform location. */
947
+ location?: string;
948
+ /** Optional short notes. */
949
+ notes?: string;
950
+ }
951
+ /** Abstraction over any calendar backend. Concrete implementations: `FileCalendarSource`. */
952
+ interface CalendarSource {
953
+ /** Return events that fall on the given UTC date (YYYY-MM-DD). */
954
+ eventsForDate(dateIso: string): Promise<CalendarEvent[]>;
955
+ }
956
+ /** A single "active thread" surfaced in a briefing. */
957
+ interface BriefingActiveThread {
958
+ id: string;
959
+ title: string;
960
+ updatedAt: string;
961
+ reason: string;
962
+ }
963
+ /** A single "recent entity" entry. */
964
+ interface BriefingRecentEntity {
965
+ name: string;
966
+ type: string;
967
+ updatedAt: string;
968
+ score: number;
969
+ summary?: string;
970
+ }
971
+ /** A single unresolved commitment or open question. */
972
+ interface BriefingOpenCommitment {
973
+ id: string;
974
+ kind: "question" | "commitment" | "pending_memory";
975
+ text: string;
976
+ source?: string;
977
+ createdAt?: string;
978
+ }
979
+ /** An LLM-generated short follow-up suggestion. */
980
+ interface BriefingFollowup {
981
+ text: string;
982
+ rationale?: string;
983
+ }
984
+ /** Structured sections of a briefing result. */
985
+ interface BriefingSections {
986
+ activeThreads: BriefingActiveThread[];
987
+ recentEntities: BriefingRecentEntity[];
988
+ openCommitments: BriefingOpenCommitment[];
989
+ suggestedFollowups: BriefingFollowup[];
990
+ /** Only populated when a calendar source is configured and returns events. */
991
+ todayCalendar?: CalendarEvent[];
992
+ }
993
+ /** A calendar source failure recorded when a CalendarSource throws during briefing generation. */
994
+ interface BriefingCalendarSourceError {
995
+ /** Human-readable description of the source (e.g. file path or source name). */
996
+ source: string;
997
+ /** Stringified error message from the failed source. */
998
+ error: string;
999
+ }
1000
+ /** Result returned by `buildBriefing`. */
1001
+ interface BriefingResult {
1002
+ markdown: string;
1003
+ json: Record<string, unknown>;
1004
+ sections: BriefingSections;
1005
+ /** Reason why suggested follow-ups were omitted (e.g. missing API key, LLM error). */
1006
+ followupsUnavailableReason?: string;
1007
+ /** Effective lookback window (ISO date range) used for this briefing. */
1008
+ window: {
1009
+ from: string;
1010
+ to: string;
1011
+ };
1012
+ /**
1013
+ * Calendar sources that failed during this briefing run.
1014
+ * Only present (non-empty) when at least one source threw.
1015
+ * Allows callers to distinguish "no events today" from "source unavailable".
1016
+ */
1017
+ calendarSourceErrors?: BriefingCalendarSourceError[];
1018
+ }
1019
+ /**
1020
+ * Settings for the Codex CLI connector. These are consumed by
1021
+ * `remnic connectors install codex-cli` to decide where the phase-2 memory
1022
+ * extension is dropped and whether to install it at all.
1023
+ */
1024
+ interface CodexConnectorConfig {
1025
+ /**
1026
+ * Whether to install the Remnic memory extension into
1027
+ * `<codex_home>/memories_extensions/remnic/` when the `codex-cli`
1028
+ * connector is installed. Default `true`. Set to `false` for users who
1029
+ * self-manage the Codex memory extensions folder.
1030
+ */
1031
+ installExtension: boolean;
1032
+ /**
1033
+ * Optional override for the Codex home directory. When `null`, the
1034
+ * connector reads `$CODEX_HOME` and falls back to `~/.codex`. Setting
1035
+ * this is useful for integration tests and non-default installs.
1036
+ */
1037
+ codexHome: string | null;
630
1038
  }
631
1039
  interface BootstrapOptions {
632
1040
  dryRun?: boolean;
@@ -662,11 +1070,21 @@ interface BufferTurn {
662
1070
  content: string;
663
1071
  timestamp: string;
664
1072
  sessionKey?: string;
1073
+ logicalSessionKey?: string;
1074
+ providerThreadId?: string | null;
1075
+ turnFingerprint?: string;
1076
+ persistProcessedFingerprint?: boolean;
1077
+ }
1078
+ interface BufferEntryState {
1079
+ turns: BufferTurn[];
1080
+ lastExtractionAt: string | null;
1081
+ extractionCount: number;
665
1082
  }
666
1083
  interface BufferState {
667
1084
  turns: BufferTurn[];
668
1085
  lastExtractionAt: string | null;
669
1086
  extractionCount: number;
1087
+ entries?: Record<string, BufferEntryState>;
670
1088
  }
671
1089
  interface BehaviorLoopAdjustment {
672
1090
  parameter: string;
@@ -774,9 +1192,20 @@ interface MemoryFrontmatter {
774
1192
  sourceMemoryId?: string;
775
1193
  sourceTurnId?: string;
776
1194
  /** episode = time-specific event; note = stable belief/preference/decision */
777
- memoryKind?: "episode" | "note";
1195
+ memoryKind?: "episode" | "note" | "box" | "dream" | "procedural";
778
1196
  /** Structured key-value attributes extracted from the content (e.g., product attributes, dates, quantities). */
779
1197
  structuredAttributes?: Record<string, string>;
1198
+ /**
1199
+ * SHA-256 (via ContentHashIndex.computeHash) of the raw content that was
1200
+ * used as the dedup key at write time. Persists through archive and
1201
+ * consolidation so the hash can be removed from the index even if the stored
1202
+ * content has been transformed (e.g. an inline citation was appended).
1203
+ *
1204
+ * When present, archive/consolidation paths use this directly instead of
1205
+ * calling stripCitation(memory.content), which only handles the default
1206
+ * [Source: ...] format and silently fails for custom citation templates.
1207
+ */
1208
+ contentHash?: string;
780
1209
  }
781
1210
  /** Memory link relationship types */
782
1211
  type MemoryLinkType = "follows" | "references" | "contradicts" | "supports" | "related";
@@ -822,6 +1251,17 @@ interface MemoryFile {
822
1251
  frontmatter: MemoryFrontmatter;
823
1252
  content: string;
824
1253
  }
1254
+ /** Ordered step for extracted procedure memories (issue #519). */
1255
+ interface ExtractedProcedureStep {
1256
+ order: number;
1257
+ intent: string;
1258
+ toolCall?: {
1259
+ kind: string;
1260
+ signature: string;
1261
+ };
1262
+ expectedOutcome?: string;
1263
+ optional?: boolean;
1264
+ }
825
1265
  interface ExtractedFact {
826
1266
  category: MemoryCategory;
827
1267
  content: string;
@@ -832,11 +1272,15 @@ interface ExtractedFact {
832
1272
  promptedByQuestion?: string;
833
1273
  /** Structured key-value attributes extracted from the content (e.g., product attributes, dates, quantities). */
834
1274
  structuredAttributes?: Record<string, string>;
1275
+ /** When category is `procedure`, ordered steps with intents (persisted under procedures/). */
1276
+ procedureSteps?: ExtractedProcedureStep[];
835
1277
  }
836
1278
  interface MemoryIntent {
837
1279
  goal: string;
838
1280
  actionType: string;
839
1281
  entityTypes: string[];
1282
+ /** True when the prompt reads like starting a concrete task (ship/deploy/tests/PR, etc.). */
1283
+ taskInitiation?: boolean;
840
1284
  }
841
1285
  interface ExtractedQuestion {
842
1286
  question: string;
@@ -864,6 +1308,7 @@ interface EntityMention {
864
1308
  name: string;
865
1309
  type: "person" | "project" | "tool" | "company" | "place" | "other";
866
1310
  facts: string[];
1311
+ structuredSections?: EntityStructuredSection[];
867
1312
  source?: ExtractionPassSource;
868
1313
  promptedByQuestion?: string;
869
1314
  }
@@ -875,15 +1320,51 @@ interface EntityActivityEntry {
875
1320
  date: string;
876
1321
  note: string;
877
1322
  }
1323
+ interface EntityTimelineEntry {
1324
+ timestamp: string;
1325
+ text: string;
1326
+ source?: string;
1327
+ sessionKey?: string;
1328
+ principal?: string;
1329
+ }
1330
+ interface EntityStructuredSection {
1331
+ key: string;
1332
+ title: string;
1333
+ facts: string[];
1334
+ }
1335
+ interface EntitySchemaSectionDefinition {
1336
+ key: string;
1337
+ title: string;
1338
+ description: string;
1339
+ aliases?: string[];
1340
+ }
1341
+ interface EntitySchemaDefinition {
1342
+ sections: EntitySchemaSectionDefinition[];
1343
+ }
878
1344
  interface EntityFile {
879
1345
  name: string;
880
1346
  type: string;
1347
+ created?: string;
881
1348
  updated: string;
1349
+ extraFrontmatterLines?: string[];
1350
+ preSectionLines?: string[];
882
1351
  facts: string[];
883
1352
  summary?: string;
1353
+ synthesis?: string;
1354
+ synthesisUpdatedAt?: string;
1355
+ synthesisTimelineCount?: number;
1356
+ synthesisStructuredFactCount?: number;
1357
+ synthesisStructuredFactDigest?: string;
1358
+ synthesisVersion?: number;
1359
+ timeline: EntityTimelineEntry[];
1360
+ structuredSections?: EntityStructuredSection[];
884
1361
  relationships: EntityRelationship[];
885
1362
  activity: EntityActivityEntry[];
886
1363
  aliases: string[];
1364
+ extraSections?: Array<{
1365
+ title: string;
1366
+ lines: string[];
1367
+ }>;
887
1368
  }
888
1369
  interface ScoredEntity {
889
1370
  name: string;
@@ -912,6 +1393,15 @@ interface ConsolidationResult {
912
1393
  profileUpdates: string[];
913
1394
  entityUpdates: EntityMention[];
914
1395
  }
1396
+ interface ConsolidationObservation {
1397
+ runAt: string;
1398
+ recentMemories: MemoryFile[];
1399
+ existingMemories: MemoryFile[];
1400
+ profile: string;
1401
+ result: ConsolidationResult;
1402
+ merged: number;
1403
+ invalidated: number;
1404
+ }
915
1405
  interface QmdSearchResult {
916
1406
  docid: string;
917
1407
  path: string;
@@ -933,6 +1423,10 @@ interface MetaState {
933
1423
  lastConsolidationAt: string | null;
934
1424
  totalMemories: number;
935
1425
  totalEntities: number;
1426
+ processedExtractionFingerprints?: Array<{
1427
+ fingerprint: string;
1428
+ observedAt: string;
1429
+ }>;
936
1430
  }
937
1431
  type MemoryActionType = "store_episode" | "store_note" | "update_note" | "create_artifact" | "summarize_node" | "discard" | "link_graph";
938
1432
  type MemoryActionOutcome = "applied" | "skipped" | "failed";
@@ -1240,4 +1734,4 @@ interface HourlySummary {
1240
1734
  generatedAt: string;
1241
1735
  }
1242
1736
 
1243
- export { type AccessTrackingEntry, type AgentAccessHttpConfig, type AgentDefaultsConfig, type AgentPersona, type AgentPersonaModelConfig, type BehaviorLoopAdjustment, type BehaviorLoopPolicyState, type BehaviorSignalDirection, type BehaviorSignalEvent, type BehaviorSignalType, type BootstrapOptions, type BootstrapResult, type BufferState, type BufferTurn, type CaptureMode, type Checkpoint, type CompressionGuidelineActivationState, type CompressionGuidelineOptimizerActionSummary, type CompressionGuidelineOptimizerEventCounts, type CompressionGuidelineOptimizerRuleUpdate, type CompressionGuidelineOptimizerSourceWindow, type CompressionGuidelineOptimizerState, type ConfidenceTier, type ConsolidationAction, type ConsolidationItem, type ConsolidationResult, type ContinuityImprovementLoop, type ContinuityIncidentCloseInput, type ContinuityIncidentOpenInput, type ContinuityIncidentRecord, type ContinuityIncidentState, type ContinuityLoopCadence, type ContinuityLoopReviewInput, type ContinuityLoopStatus, type ContinuityLoopUpsertInput, type ConversationThread, type CronConversationRecallMode, type CronRecallMode, type DaySummaryResult, type EngramTraceEvent, type EntityActivityEntry, type EntityFile, type EntityMention, type EntityRelationship, type ExtractedFact, type ExtractedQuestion, type ExtractedRelationship, type ExtractionPassSource, type ExtractionResult, type FileHygieneConfig, type GatewayConfig, type HourlySummary, type IdentityInjectionMode, type ImportanceLevel, type ImportanceScore, type LifecycleState, type LlmTraceCallback, type LlmTraceEvent, type MemoryActionEligibilityContext, type MemoryActionEligibilitySource, type MemoryActionEvent, type MemoryActionOutcome, type MemoryActionPolicyDecision, type MemoryActionPolicyResult, type MemoryActionStatus, type MemoryActionType, type MemoryCategory, type MemoryFile, type MemoryFrontmatter, type MemoryIntent, type MemoryLifecycleEvent, type MemoryLifecycleEventType, type MemoryLifecycleStateSummary, type MemoryLink, type MemoryLinkType, type MemoryOsPresetName, type MemoryProjectionCurrentState, type MemoryStatus, type MemorySummary, type MetaState, type ModelApi, type ModelDefinitionConfig, type ModelProviderAuthMode, type ModelProviderConfig, type NamespacePolicy, type NativeKnowledgeConfig, type NativeKnowledgeFolderRuleConfig, type NativeKnowledgeObsidianVaultConfig, type NativeKnowledgeOpenClawWorkspaceConfig, type PluginConfig, type PolicyClass, type PrincipalFromSessionKeyMode, type PrincipalRule, type QmdSearchExplain, type QmdSearchResult, type QuestionEntry, type ReasoningEffort, type RecallPipelineConfig, type RecallPlanMode, type RecallSectionConfig, type RecallTraceEvent, type RelevanceFeedback, SPECULATIVE_TTL_DAYS, type ScoredEntity, type SessionObserverBandConfig, type SignalLevel, type SignalScanResult, type TopicScore, type TranscriptEntry, type TriggerMode, type VerificationState, confidenceTier };
1737
+ export { type AccessTrackingEntry, type ActiveRecallChatType, type ActiveRecallModelFallbackPolicy, type ActiveRecallPromptStyle, type ActiveRecallQueryMode, type ActiveRecallThinking, type AgentAccessHttpConfig, type AgentDefaultsConfig, type AgentPersona, type AgentPersonaModelConfig, type BehaviorLoopAdjustment, type BehaviorLoopPolicyState, type BehaviorSignalDirection, type BehaviorSignalEvent, type BehaviorSignalType, type BootstrapOptions, type BootstrapResult, type BriefingActiveThread, type BriefingCalendarSourceError, type BriefingConfig, type BriefingFocus, type BriefingFollowup, type BriefingOpenCommitment, type BriefingRecentEntity, type BriefingResult, type BriefingSections, type BriefingWindow, type BufferEntryState, type BufferState, type BufferTurn, type CalendarEvent, type CalendarSource, type CaptureMode, type Checkpoint, type CodexCompactionFlushMode, type CodexCompatConfig, type CodexConnectorConfig, type CompressionGuidelineActivationState, type CompressionGuidelineOptimizerActionSummary, type CompressionGuidelineOptimizerEventCounts, type CompressionGuidelineOptimizerRuleUpdate, type CompressionGuidelineOptimizerSourceWindow, type CompressionGuidelineOptimizerState, type ConfidenceTier, type ConsolidationAction, type ConsolidationItem, type ConsolidationObservation, type ConsolidationResult, type ContinuityImprovementLoop, type ContinuityIncidentCloseInput, type ContinuityIncidentOpenInput, type ContinuityIncidentRecord, type ContinuityIncidentState, type ContinuityLoopCadence, type ContinuityLoopReviewInput, type ContinuityLoopStatus, type ContinuityLoopUpsertInput, type ConversationThread, type CronConversationRecallMode, type CronRecallMode, type DaySummaryResult, type DreamingConfig, type DreamingNarrativePromptStyle, type EngramTraceEvent, type EntityActivityEntry, type EntityFile, type EntityMention, type EntityRelationship, type EntitySchemaDefinition, type EntitySchemaSectionDefinition, type EntityStructuredSection, type EntityTimelineEntry, type ExtractedFact, type ExtractedProcedureStep, type ExtractedQuestion, type ExtractedRelationship, type ExtractionPassSource, type ExtractionResult, type FileHygieneConfig, type GatewayConfig, type HeartbeatConfig, type HeartbeatDetectionMode, type HourlySummary, type IdentityInjectionMode, type ImportanceLevel, type ImportanceScore, type LifecycleState, type LlmTraceCallback, type LlmTraceEvent, type MemoryActionEligibilityContext, type MemoryActionEligibilitySource, type MemoryActionEvent, type MemoryActionOutcome, type MemoryActionPolicyDecision, type MemoryActionPolicyResult, type MemoryActionStatus, type MemoryActionType, type MemoryCategory, type MemoryFile, type MemoryFrontmatter, type MemoryIntent, type MemoryLifecycleEvent, type MemoryLifecycleEventType, type MemoryLifecycleStateSummary, type MemoryLink, type MemoryLinkType, type MemoryOsPresetName, type MemoryProjectionCurrentState, type MemoryStatus, type MemorySummary, type MetaState, type ModelApi, type ModelDefinitionConfig, type ModelProviderAuthMode, type ModelProviderConfig, type NamespacePolicy, type NativeKnowledgeConfig, type NativeKnowledgeFolderRuleConfig, type NativeKnowledgeObsidianVaultConfig, type NativeKnowledgeOpenClawWorkspaceConfig, type PluginConfig, type PolicyClass, type PrincipalFromSessionKeyMode, type PrincipalRule, type ProceduralConfig, type QmdSearchExplain, type QmdSearchResult, type QuestionEntry, type ReasoningEffort, type RecallPipelineConfig, type RecallPlanMode, type RecallSectionConfig, type RecallTierExplain, type RecallTraceEvent, type RelevanceFeedback, type RetrievalTier, SPECULATIVE_TTL_DAYS, type ScoredEntity, type SemanticChunkingConfigShape, type SessionObserverBandConfig, type SignalLevel, type SignalScanResult, type SlotBehaviorConfig, type SlotMismatchMode, type TopicScore, type TranscriptEntry, type TriggerMode, type VerificationState, confidenceTier };
package/dist/types.js CHANGED
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  SPECULATIVE_TTL_DAYS,
3
3
  confidenceTier
4
- } from "./chunk-U4PV25RD.js";
4
+ } from "./chunk-U2IQTSBY.js";
5
5
  export {
6
6
  SPECULATIVE_TTL_DAYS,
7
7
  confidenceTier
@@ -3,11 +3,11 @@ import {
3
3
  learnUtilityPromotionWeights,
4
4
  readUtilityLearningSnapshot,
5
5
  resolveUtilityLearningStatePath
6
- } from "./chunk-OTAVQCSF.js";
6
+ } from "./chunk-PYXS46O7.js";
7
7
  import "./chunk-3QKK7QOS.js";
8
+ import "./chunk-TBBDFYXW.js";
8
9
  import "./chunk-DGXUHMOV.js";
9
10
  import "./chunk-LPSF4OQH.js";
10
- import "./chunk-QCCCQT3O.js";
11
11
  export {
12
12
  getUtilityLearningStatus,
13
13
  learnUtilityPromotionWeights,