@remnic/core 10.0.13 → 10.0.15

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 (614) hide show
  1. package/dist/abstraction-nodes.js +3 -2
  2. package/dist/access-admin-ops-surface.js +96 -92
  3. package/dist/access-authorization-probe.js +97 -93
  4. package/dist/access-boundary.js +96 -92
  5. package/dist/access-cli.js +203 -198
  6. package/dist/access-cli.js.map +1 -1
  7. package/dist/access-extraction-force-flush.js +96 -92
  8. package/dist/access-http-briefing.js +97 -93
  9. package/dist/access-http-query.js +98 -94
  10. package/dist/access-http.js +121 -117
  11. package/dist/access-idempotency.js +3 -2
  12. package/dist/access-identity-continuity-surface.js +96 -92
  13. package/dist/access-lcm-surface.js +96 -92
  14. package/dist/access-mcp.js +110 -106
  15. package/dist/access-namespace-preflight.js +96 -92
  16. package/dist/access-observe-write-category.js +18 -17
  17. package/dist/access-observe-write-surface.js +96 -92
  18. package/dist/access-offline-manifest.js +17 -15
  19. package/dist/access-operations-batch.js +101 -97
  20. package/dist/access-operations.js +108 -104
  21. package/dist/access-recall-concurrency.js +96 -92
  22. package/dist/access-recall-diagnostics.js +2 -2
  23. package/dist/access-recall-response.js +96 -92
  24. package/dist/access-recall-surface.js +96 -92
  25. package/dist/access-schema.d.ts +2 -2
  26. package/dist/access-schema.js +13 -12
  27. package/dist/access-service.js +96 -92
  28. package/dist/access-surface-catalog.js +98 -94
  29. package/dist/access-surface-catalog.js.map +1 -1
  30. package/dist/active-recall.js +43 -39
  31. package/dist/active-recall.js.map +1 -1
  32. package/dist/adapters/index.js +4 -4
  33. package/dist/adapters/registry.js +2 -2
  34. package/dist/{auto-sync-DGJOZYGT.js → auto-sync-7WWAKW6F.js} +8 -8
  35. package/dist/briefing.js +32 -28
  36. package/dist/buffer.js +13 -13
  37. package/dist/calibration.d.ts.map +1 -1
  38. package/dist/calibration.js +6 -3
  39. package/dist/calibration.js.map +1 -1
  40. package/dist/{capsule-merge-M4HETD27.js → capsule-merge-LGYURS3C.js} +6 -5
  41. package/dist/{capsule-merge-M4HETD27.js.map → capsule-merge-LGYURS3C.js.map} +1 -1
  42. package/dist/capture-write-lock-backoff.d.ts +50 -0
  43. package/dist/capture-write-lock-backoff.d.ts.map +1 -0
  44. package/dist/capture-write-lock-backoff.js +30 -0
  45. package/dist/capture-write-lock.d.ts +6 -0
  46. package/dist/capture-write-lock.d.ts.map +1 -0
  47. package/dist/capture-write-lock.js +15 -0
  48. package/dist/causal-behavior.js +4 -3
  49. package/dist/causal-behavior.js.map +1 -1
  50. package/dist/causal-chain.js +4 -3
  51. package/dist/causal-consolidation.js +36 -32
  52. package/dist/causal-consolidation.js.map +1 -1
  53. package/dist/causal-retrieval.js +4 -3
  54. package/dist/causal-retrieval.js.map +1 -1
  55. package/dist/causal-trajectory-graph.js +7 -6
  56. package/dist/causal-trajectory-graph.js.map +1 -1
  57. package/dist/causal-trajectory.js +3 -2
  58. package/dist/{chunk-KZO43HPY.js → chunk-22RM2ZUJ.js} +112 -112
  59. package/dist/{chunk-ZUMXY4KA.js → chunk-22W2XWGH.js} +3 -3
  60. package/dist/{chunk-MZBWIJJN.js → chunk-23ZQPP2G.js} +24 -19
  61. package/dist/chunk-23ZQPP2G.js.map +1 -0
  62. package/dist/{chunk-PCWXLAJY.js → chunk-2PTH4PRL.js} +2 -2
  63. package/dist/{chunk-ZIZ2G47N.js → chunk-2PYHLSXK.js} +2 -2
  64. package/dist/{chunk-B6O2YLUR.js → chunk-2Z5DIDQD.js} +6 -1
  65. package/dist/chunk-2Z5DIDQD.js.map +1 -0
  66. package/dist/{chunk-7OAIOE5P.js → chunk-33G67YZF.js} +2 -2
  67. package/dist/{chunk-AV2OQF2O.js → chunk-3F3HA3R2.js} +2 -2
  68. package/dist/{chunk-RP5SJ3XR.js → chunk-3GNIJUUE.js} +2 -2
  69. package/dist/{chunk-QZZPUREO.js → chunk-3GYSZHMT.js} +3 -3
  70. package/dist/{chunk-QWWMS4AE.js → chunk-3MO4LWYU.js} +1 -1
  71. package/dist/chunk-3MO4LWYU.js.map +1 -0
  72. package/dist/{chunk-SWIKABKI.js → chunk-3Q3XD3NO.js} +2 -2
  73. package/dist/{chunk-AL6EHLB5.js → chunk-3X3PNU3T.js} +2 -2
  74. package/dist/{chunk-BTJ6CAIA.js → chunk-4IYIGN53.js} +10 -10
  75. package/dist/{chunk-BZTRPCCH.js → chunk-4PDTVVSW.js} +2 -2
  76. package/dist/{chunk-HM7RHKS4.js → chunk-4RNBLLZR.js} +2 -2
  77. package/dist/{chunk-Y3VDGK2O.js → chunk-4SCZZ3U7.js} +282 -84
  78. package/dist/chunk-4SCZZ3U7.js.map +1 -0
  79. package/dist/{chunk-JUWJYXI4.js → chunk-5ATSXCAG.js} +4 -4
  80. package/dist/{chunk-EHRE7ZG3.js → chunk-5B5WYAHQ.js} +2 -2
  81. package/dist/{chunk-WCGJK4NQ.js → chunk-5FNZ3G6X.js} +10 -10
  82. package/dist/{chunk-Y6DZ33PA.js → chunk-5GX5457J.js} +4 -4
  83. package/dist/{chunk-EMFBC7L3.js → chunk-5KGYTX5O.js} +2 -2
  84. package/dist/{chunk-OFCHT2TN.js → chunk-5LRV557D.js} +2 -2
  85. package/dist/{chunk-DXHVD4DS.js → chunk-5SMR542T.js} +3 -3
  86. package/dist/{chunk-S7LWX2PQ.js → chunk-655FVTCD.js} +2 -2
  87. package/dist/{chunk-DGRMWDQY.js → chunk-66BCOVW2.js} +7 -7
  88. package/dist/chunk-6EDW54SQ.js +298 -0
  89. package/dist/chunk-6EDW54SQ.js.map +1 -0
  90. package/dist/{chunk-5MDM7UE4.js → chunk-6WGMZQGG.js} +2 -2
  91. package/dist/chunk-77R7BQZ2.js +152 -0
  92. package/dist/chunk-77R7BQZ2.js.map +1 -0
  93. package/dist/{chunk-IPLYGWQF.js → chunk-7LCGFUMB.js} +6 -6
  94. package/dist/{chunk-5ZJYHOJT.js → chunk-7VQ6AI7H.js} +8 -8
  95. package/dist/{chunk-KYY4EACB.js → chunk-7Z3DLNSD.js} +2 -2
  96. package/dist/{chunk-LNH76ZJX.js → chunk-AIYXVWUH.js} +27 -2
  97. package/dist/{chunk-LNH76ZJX.js.map → chunk-AIYXVWUH.js.map} +1 -1
  98. package/dist/{chunk-G7NYVKD6.js → chunk-B2NXOVZN.js} +2 -2
  99. package/dist/{chunk-B43NMCGQ.js → chunk-BK2BVLZW.js} +2 -2
  100. package/dist/{chunk-QJ622LTI.js → chunk-BQOGQULP.js} +30 -8
  101. package/dist/chunk-BQOGQULP.js.map +1 -0
  102. package/dist/{chunk-BOOFTFFE.js → chunk-C2RW36YR.js} +2 -2
  103. package/dist/{chunk-XERVJYH2.js → chunk-C6JMGAMO.js} +7 -3
  104. package/dist/chunk-C6JMGAMO.js.map +1 -0
  105. package/dist/{chunk-5JMI26Q7.js → chunk-CBH2Z4UA.js} +2 -2
  106. package/dist/{chunk-P2S6P7X6.js → chunk-CFZ4SXXH.js} +2 -2
  107. package/dist/{chunk-YRH3C2OJ.js → chunk-CIIHIAJ2.js} +13 -5
  108. package/dist/chunk-CIIHIAJ2.js.map +1 -0
  109. package/dist/{chunk-6M56RFFJ.js → chunk-CJRENHVZ.js} +3 -3
  110. package/dist/{chunk-EGDYVYU7.js → chunk-CLWBFR7Q.js} +3 -3
  111. package/dist/{chunk-375ARKRS.js → chunk-D5SSBCYY.js} +70 -59
  112. package/dist/chunk-D5SSBCYY.js.map +1 -0
  113. package/dist/{chunk-KI6UOSNR.js → chunk-DEY7B77Y.js} +2 -2
  114. package/dist/chunk-DEY7B77Y.js.map +1 -0
  115. package/dist/{chunk-6VAHJ2F6.js → chunk-DMDWFQMR.js} +2 -2
  116. package/dist/{chunk-BLVHDY2U.js → chunk-DOWACHYO.js} +5 -2
  117. package/dist/chunk-DOWACHYO.js.map +1 -0
  118. package/dist/{chunk-UZSBCQEC.js → chunk-DPSOFK4D.js} +2 -2
  119. package/dist/{chunk-IZT3BVDW.js → chunk-DQR2LD3V.js} +2 -2
  120. package/dist/{chunk-K4QY55XV.js → chunk-EH4BQ7LT.js} +2 -2
  121. package/dist/chunk-EHHQJTAU.js +131 -0
  122. package/dist/chunk-EHHQJTAU.js.map +1 -0
  123. package/dist/{chunk-EBA5DA77.js → chunk-EOU6V4IN.js} +2 -2
  124. package/dist/{chunk-GD7BWGIB.js → chunk-EU6IRUCY.js} +6 -4
  125. package/dist/{chunk-GD7BWGIB.js.map → chunk-EU6IRUCY.js.map} +1 -1
  126. package/dist/{chunk-7KYJNHGM.js → chunk-EUCYTCFP.js} +2 -2
  127. package/dist/{chunk-YNDLCWXS.js → chunk-EZ25VE3G.js} +4 -4
  128. package/dist/{chunk-CKUUP64O.js → chunk-F2772ATT.js} +2 -2
  129. package/dist/{chunk-46EST7JO.js → chunk-F2XNSIPP.js} +2 -2
  130. package/dist/{chunk-2KRNPFPK.js → chunk-FLI6DEIU.js} +2 -2
  131. package/dist/{chunk-OAIWPB2I.js → chunk-FT4UQYOV.js} +2 -2
  132. package/dist/{chunk-HYNEDMYJ.js → chunk-G2OYFTUD.js} +2 -2
  133. package/dist/{chunk-XTN54NML.js → chunk-G3T6YMBO.js} +4 -4
  134. package/dist/{chunk-CNG2XVZG.js → chunk-G3UUAQOD.js} +2 -2
  135. package/dist/{chunk-2ZQJLBV6.js → chunk-GCVDFX66.js} +4 -4
  136. package/dist/{chunk-ON4ILX3G.js → chunk-GFAM2LTC.js} +2 -2
  137. package/dist/{chunk-2LUSQV4U.js → chunk-GKJJNO7C.js} +2 -2
  138. package/dist/{chunk-T2YX56QI.js → chunk-GQJKVQJR.js} +2 -2
  139. package/dist/{chunk-5AOAQR37.js → chunk-GWVNGDJW.js} +3 -3
  140. package/dist/{chunk-YDH2FSDI.js → chunk-GZXXPCWJ.js} +3 -3
  141. package/dist/{chunk-5JCLELOP.js → chunk-H5IUN433.js} +2 -2
  142. package/dist/{chunk-IWHEJXR2.js → chunk-H6FREOYX.js} +8 -8
  143. package/dist/{chunk-B7CANWCA.js → chunk-HBAOOSHU.js} +2 -2
  144. package/dist/{chunk-Q4E24IRR.js → chunk-HDN7IVIO.js} +14 -11
  145. package/dist/chunk-HDN7IVIO.js.map +1 -0
  146. package/dist/{chunk-T3FMRLWQ.js → chunk-HFSPY26A.js} +2 -2
  147. package/dist/{chunk-B657ZGDH.js → chunk-HQSK2INQ.js} +2 -2
  148. package/dist/{chunk-RT6D3WN7.js → chunk-IJMDBYCO.js} +2 -2
  149. package/dist/{chunk-CS2JEHTB.js → chunk-IUCPLBDS.js} +9 -9
  150. package/dist/{chunk-XRBHXUTQ.js → chunk-IWD33CF4.js} +6 -6
  151. package/dist/{chunk-4IHBN6WU.js → chunk-JKMIGCK6.js} +2 -2
  152. package/dist/{chunk-YYO447A7.js → chunk-JNIVZNIB.js} +41 -253
  153. package/dist/chunk-JNIVZNIB.js.map +1 -0
  154. package/dist/{chunk-ROBHL3GL.js → chunk-JWX2Q6HS.js} +2 -2
  155. package/dist/{chunk-3I3U6FFT.js → chunk-K7BN34IA.js} +2 -2
  156. package/dist/{chunk-4O6WRBGE.js → chunk-KJXP6RUG.js} +5 -1
  157. package/dist/chunk-KJXP6RUG.js.map +1 -0
  158. package/dist/{chunk-4THZGKQ2.js → chunk-KLJVTZ3R.js} +3 -3
  159. package/dist/{chunk-4G4B3Z2B.js → chunk-KW4AJ7T3.js} +2 -2
  160. package/dist/{chunk-HT2C4EXO.js → chunk-L5VCT7LU.js} +8 -4
  161. package/dist/chunk-L5VCT7LU.js.map +1 -0
  162. package/dist/{chunk-ZI7LMSNI.js → chunk-LLHZZOIB.js} +2 -2
  163. package/dist/{chunk-LS2FHUML.js → chunk-LQ5SS4OP.js} +3 -3
  164. package/dist/{chunk-NSFOERZQ.js → chunk-LWFWZTWX.js} +3 -3
  165. package/dist/{chunk-BMWN7B3Y.js → chunk-LXATZLSC.js} +3 -3
  166. package/dist/{chunk-OYKQ6T4V.js → chunk-MATDGSJ7.js} +2 -2
  167. package/dist/{chunk-3NFN4Y4P.js → chunk-MGCKZWAE.js} +5 -5
  168. package/dist/{chunk-O4KYRDRT.js → chunk-MJIOGYKX.js} +2 -2
  169. package/dist/{chunk-6OMUHXHP.js → chunk-ML7ZJAKJ.js} +2 -2
  170. package/dist/{chunk-GKIXBH7Y.js → chunk-MO6N4QYY.js} +4 -4
  171. package/dist/{chunk-A2E4WNW4.js → chunk-MWWAQXZ6.js} +2 -2
  172. package/dist/{chunk-VYPFEVOM.js → chunk-NHUX6GXA.js} +6 -6
  173. package/dist/{chunk-AKREOU5F.js → chunk-NZCKG25S.js} +2 -2
  174. package/dist/{chunk-4NDWE44P.js → chunk-NZFFGO5O.js} +2 -2
  175. package/dist/{chunk-WWSRLS4M.js → chunk-O2YPCFJT.js} +17 -17
  176. package/dist/{chunk-ZSJGYC3C.js → chunk-OQJKY3Z5.js} +2 -2
  177. package/dist/{chunk-U7VPOXVM.js → chunk-OQR42XCN.js} +82 -78
  178. package/dist/chunk-OQR42XCN.js.map +1 -0
  179. package/dist/{chunk-OFEHITAZ.js → chunk-OXNTOHL6.js} +2 -2
  180. package/dist/{chunk-FQD2KPQH.js → chunk-P55FACBG.js} +2 -2
  181. package/dist/chunk-PGRZ3FYC.js +34 -0
  182. package/dist/chunk-PGRZ3FYC.js.map +1 -0
  183. package/dist/{chunk-JYZSRNR7.js → chunk-PIITB2YZ.js} +2 -2
  184. package/dist/{chunk-PBVNVKYN.js → chunk-PIN5OPBA.js} +2 -2
  185. package/dist/chunk-PPUNC7UX.js +73 -0
  186. package/dist/chunk-PPUNC7UX.js.map +1 -0
  187. package/dist/{chunk-EQWEIIKQ.js → chunk-PQM3B54K.js} +6 -1
  188. package/dist/chunk-PQM3B54K.js.map +1 -0
  189. package/dist/{chunk-4TTGRETU.js → chunk-PRU7OF3Y.js} +5 -5
  190. package/dist/{chunk-K2FSASGZ.js → chunk-PVHQSLNN.js} +7 -7
  191. package/dist/{chunk-SVDU4OHO.js → chunk-Q35L7TYB.js} +2 -2
  192. package/dist/{chunk-5VC7J76U.js → chunk-QPH52AZB.js} +2 -2
  193. package/dist/{chunk-6T42L5FI.js → chunk-QS3OLP5I.js} +2 -2
  194. package/dist/{chunk-P34FDDB5.js → chunk-QSEUUQUF.js} +2 -2
  195. package/dist/chunk-QUIRIG2P.js +31 -0
  196. package/dist/chunk-QUIRIG2P.js.map +1 -0
  197. package/dist/{chunk-PAAJWQH5.js → chunk-QUMKDRCF.js} +2 -2
  198. package/dist/{chunk-KZEMFD6E.js → chunk-R2H4ZFBJ.js} +3 -3
  199. package/dist/{chunk-X3VID2TT.js → chunk-RI2KCQHP.js} +7 -3
  200. package/dist/chunk-RI2KCQHP.js.map +1 -0
  201. package/dist/{chunk-JFVCDEIC.js → chunk-RP7PQWZM.js} +7 -7
  202. package/dist/{chunk-KC46VZR5.js → chunk-RTTPBBAN.js} +9 -9
  203. package/dist/{chunk-ZQ3WU6JO.js → chunk-RXFCU3CY.js} +2 -2
  204. package/dist/{chunk-CBP4HWCL.js → chunk-RYYVMZBR.js} +3 -3
  205. package/dist/{chunk-2NCBDGND.js → chunk-SA6GMZJY.js} +3 -3
  206. package/dist/{chunk-VFTK5WKI.js → chunk-STBX5X6B.js} +2 -2
  207. package/dist/{chunk-WVHRNAXL.js → chunk-SWWHIJUJ.js} +2 -2
  208. package/dist/{chunk-WADSXS4K.js → chunk-SX4QDWXK.js} +2 -2
  209. package/dist/{chunk-WETFW255.js → chunk-T7ASDYNK.js} +2 -2
  210. package/dist/{chunk-XZLWYZ7C.js → chunk-THEPGZBM.js} +2 -2
  211. package/dist/{chunk-YEM7K3KD.js → chunk-TMC7HBED.js} +6 -6
  212. package/dist/{chunk-RWRQ67OR.js → chunk-TPNCXSXP.js} +2 -2
  213. package/dist/{chunk-LZKOVXMX.js → chunk-TRMJ6BYC.js} +2 -2
  214. package/dist/{chunk-A6TVQ3QP.js → chunk-UGYUBENJ.js} +3 -3
  215. package/dist/{chunk-AAM66QCP.js → chunk-UZRSI6NX.js} +2 -2
  216. package/dist/{chunk-XHWJRUVP.js → chunk-V3TXIXXY.js} +3 -3
  217. package/dist/{chunk-2CXQZXWM.js → chunk-V4MB5ONM.js} +6 -6
  218. package/dist/{chunk-UOKPJFO3.js → chunk-VNZMZPAC.js} +3 -3
  219. package/dist/{chunk-FZB4TS2W.js → chunk-VPXIKBPX.js} +5 -5
  220. package/dist/{chunk-CYEK6Z3P.js → chunk-VW6VIJOS.js} +2 -2
  221. package/dist/{chunk-QUA7RLK6.js → chunk-W3FVQBGF.js} +2 -2
  222. package/dist/{chunk-6OQ6N5RP.js → chunk-WGTR573G.js} +22 -22
  223. package/dist/{chunk-W3K3HITK.js → chunk-WLT6LTQP.js} +2 -2
  224. package/dist/{chunk-6Z2AZ4AJ.js → chunk-XKRXN63M.js} +2 -2
  225. package/dist/{chunk-3J5JKBYD.js → chunk-XLBFX63V.js} +80 -77
  226. package/dist/chunk-XLBFX63V.js.map +1 -0
  227. package/dist/{chunk-FZVROZKC.js → chunk-XVZA6VXC.js} +4 -4
  228. package/dist/{chunk-DA2INEB5.js → chunk-XYGQSDTH.js} +4 -4
  229. package/dist/chunk-YET735EZ.js +99 -0
  230. package/dist/chunk-YET735EZ.js.map +1 -0
  231. package/dist/{chunk-RBJQYMMT.js → chunk-YRULQW5J.js} +4 -4
  232. package/dist/{chunk-QUNDYIYZ.js → chunk-YYEOR4XN.js} +3 -3
  233. package/dist/{chunk-6WHJ2EAB.js → chunk-Z64TS5V4.js} +2 -2
  234. package/dist/{chunk-NHLLKEKK.js → chunk-ZAJLJ35W.js} +2 -2
  235. package/dist/{chunk-M7V65M6H.js → chunk-ZKHSAMTE.js} +2 -2
  236. package/dist/cli.d.ts.map +1 -1
  237. package/dist/cli.js +154 -150
  238. package/dist/coding/export-okf-codegraph.js +32 -28
  239. package/dist/coding/export-okf-codegraph.js.map +1 -1
  240. package/dist/coding/pre-action-gate.js +4 -3
  241. package/dist/commitment-ledger.js +3 -2
  242. package/dist/compounding/engine.js +34 -30
  243. package/dist/config.js +43 -39
  244. package/dist/connectors/codex-materialize-runner.js +32 -28
  245. package/dist/connectors/index.js +32 -28
  246. package/dist/console/trace.d.ts +5 -14
  247. package/dist/console/trace.d.ts.map +1 -1
  248. package/dist/consolidation-provenance-check.d.ts.map +1 -1
  249. package/dist/consolidation-provenance-check.js +8 -6
  250. package/dist/consolidation-undo.js +5 -4
  251. package/dist/consolidation-undo.js.map +1 -1
  252. package/dist/contradiction/index.js +9 -7
  253. package/dist/converge-config.d.ts +2 -0
  254. package/dist/converge-config.d.ts.map +1 -1
  255. package/dist/converge-config.js +7 -3
  256. package/dist/convergence-refresh.js +34 -30
  257. package/dist/corpus-watermark.js +34 -30
  258. package/dist/correction/correction-planner.d.ts.map +1 -1
  259. package/dist/cue-anchors.js +4 -3
  260. package/dist/dashboard-runtime.js +2 -2
  261. package/dist/deep-recall-http-glue.js +14 -13
  262. package/dist/deep-recall.js +2 -2
  263. package/dist/{dreams-ledger-567VKVOU.js → dreams-ledger-UCHHRQ4R.js} +3 -2
  264. package/dist/embedding-fallback.js +5 -4
  265. package/dist/embedding-generation-lock.js +4 -3
  266. package/dist/entity-retrieval.js +33 -29
  267. package/dist/eval-trajectory-store.js +4 -3
  268. package/dist/eval-trajectory.js +4 -3
  269. package/dist/evals.js +3 -2
  270. package/dist/explicit-capture.js +11 -8
  271. package/dist/external-wiki-access.js +97 -93
  272. package/dist/extraction-quote-grounding.d.ts +67 -0
  273. package/dist/extraction-quote-grounding.d.ts.map +1 -0
  274. package/dist/extraction-quote-grounding.js +27 -0
  275. package/dist/extraction-quote-grounding.js.map +1 -0
  276. package/dist/extraction-source-grounding-helpers.d.ts +8 -0
  277. package/dist/extraction-source-grounding-helpers.d.ts.map +1 -1
  278. package/dist/extraction-source-grounding-helpers.js +11 -1
  279. package/dist/extraction-source-grounding-rules.d.ts +3 -1
  280. package/dist/extraction-source-grounding-rules.d.ts.map +1 -1
  281. package/dist/extraction-source-grounding-rules.js +3 -2
  282. package/dist/extraction-source-grounding.d.ts +1 -1
  283. package/dist/extraction-source-grounding.d.ts.map +1 -1
  284. package/dist/extraction-source-grounding.js +4 -3
  285. package/dist/extraction-span-materialize.js +2 -2
  286. package/dist/extraction.js +44 -39
  287. package/dist/{first-start-migration-HYAMKJ6V.js → first-start-migration-QVD22WWS.js} +9 -8
  288. package/dist/{first-start-migration-HYAMKJ6V.js.map → first-start-migration-QVD22WWS.js.map} +1 -1
  289. package/dist/{forget-OHAJ6PSU.js → forget-GXBWFKRC.js} +5 -4
  290. package/dist/{forget-OHAJ6PSU.js.map → forget-GXBWFKRC.js.map} +1 -1
  291. package/dist/{graph-edge-decay-CZ3SYLM4.js → graph-edge-decay-BYPZVJT4.js} +10 -9
  292. package/dist/graph-edge-decay-BYPZVJT4.js.map +1 -0
  293. package/dist/graph-jsonl.js +8 -7
  294. package/dist/graph-snapshot.js +8 -7
  295. package/dist/graph-write-lock.js +4 -3
  296. package/dist/graph.js +9 -8
  297. package/dist/harmonic-construction.js +5 -4
  298. package/dist/harmonic-retrieval.js +36 -32
  299. package/dist/harmonic-source-lookup.js +3 -2
  300. package/dist/http-retry.js +2 -1
  301. package/dist/http-retry.js.map +1 -1
  302. package/dist/index.d.ts +1 -1
  303. package/dist/index.d.ts.map +1 -1
  304. package/dist/index.js +244 -237
  305. package/dist/json-store.d.ts.map +1 -1
  306. package/dist/json-store.js +2 -1
  307. package/dist/lcm/engine.js +4 -4
  308. package/dist/lcm/index.js +12 -12
  309. package/dist/location/index.js +35 -31
  310. package/dist/maintenance/dreams-ledger.d.ts.map +1 -1
  311. package/dist/maintenance/memory-governance.d.ts.map +1 -1
  312. package/dist/maintenance/memory-governance.js +32 -28
  313. package/dist/maintenance/rebuild-memory-lifecycle-ledger.js +32 -28
  314. package/dist/maintenance/rebuild-memory-projection-runner.js +34 -30
  315. package/dist/maintenance/rebuild-memory-projection.js +33 -29
  316. package/dist/memory-browse-operations.js +97 -93
  317. package/dist/memory-browse.js +7 -7
  318. package/dist/memory-subject.js +5 -4
  319. package/dist/namespaces/migrate.js +33 -29
  320. package/dist/namespaces/search.js +11 -10
  321. package/dist/namespaces/storage.d.ts.map +1 -1
  322. package/dist/namespaces/storage.js +32 -28
  323. package/dist/objective-state-writers.js +4 -3
  324. package/dist/objective-state.js +3 -2
  325. package/dist/offline-sync-changeset-generations.js +7 -6
  326. package/dist/offline-sync-embedding-generation.js +6 -5
  327. package/dist/offline-sync-impression-drain.js +4 -4
  328. package/dist/offline-sync-snapshot-stream.js +10 -9
  329. package/dist/offline-sync.d.ts.map +1 -1
  330. package/dist/offline-sync.js +11 -10
  331. package/dist/operator-doctor-corpus.js +35 -31
  332. package/dist/operator-toolkit.js +58 -54
  333. package/dist/orchestration/maintenance.js +44 -40
  334. package/dist/orchestrator.js +205 -200
  335. package/dist/page-versioning.js +5 -4
  336. package/dist/profiling.d.ts.map +1 -1
  337. package/dist/profiling.js +2 -1
  338. package/dist/qmd-daemon-session.js +2 -2
  339. package/dist/qmd.js +4 -4
  340. package/dist/recall-explain-renderer.js +3 -3
  341. package/dist/recall-navigate-access.js +2 -2
  342. package/dist/recall-navigate-disclosure.js +2 -2
  343. package/dist/recall-navigate.js +2 -2
  344. package/dist/recall-navigation-operations.js +97 -93
  345. package/dist/recall-navigation.js +96 -92
  346. package/dist/recall-state-view-admission.js +7 -7
  347. package/dist/recall-state.js +4 -3
  348. package/dist/recall-why-service.js +7 -7
  349. package/dist/recall-xray-cli.js +4 -4
  350. package/dist/recall-xray-renderer.js +3 -3
  351. package/dist/recall-xray.js +2 -2
  352. package/dist/reconcile/cursor.js +4 -2
  353. package/dist/reconcile/cursor.js.map +1 -1
  354. package/dist/reconcile/manifest.js +9 -6
  355. package/dist/reconcile/plan.js +4 -2
  356. package/dist/{resolution-EKJHREVJ.js → resolution-ZU5BIAJA.js} +10 -8
  357. package/dist/resolution-ZU5BIAJA.js.map +1 -0
  358. package/dist/resume-bundles.js +48 -44
  359. package/dist/retrieval-agents.d.ts +1 -1
  360. package/dist/retrieval-agents.d.ts.map +1 -1
  361. package/dist/retrieval-agents.js +7 -1
  362. package/dist/salvage-envelope.js +7 -6
  363. package/dist/search/document-scanner.d.ts.map +1 -1
  364. package/dist/search/document-scanner.js +2 -1
  365. package/dist/search/factory.js +10 -9
  366. package/dist/search/index.js +16 -15
  367. package/dist/search/lancedb-backend.js +3 -2
  368. package/dist/search/meilisearch-backend.js +3 -2
  369. package/dist/search/orama-backend.js +3 -2
  370. package/dist/semantic-consolidation.js +37 -33
  371. package/dist/semantic-rule-promotion.js +32 -28
  372. package/dist/semantic-rule-verifier.js +32 -28
  373. package/dist/source-agent-qualifier.js +40 -35
  374. package/dist/standup/build.js +32 -28
  375. package/dist/storage/content-hash-index.d.ts +10 -0
  376. package/dist/storage/content-hash-index.d.ts.map +1 -1
  377. package/dist/storage/entity-canonical-id-migration.d.ts.map +1 -1
  378. package/dist/storage/entity-store.d.ts +32 -1
  379. package/dist/storage/entity-store.d.ts.map +1 -1
  380. package/dist/storage/memory-read-store.d.ts.map +1 -1
  381. package/dist/storage/supersession-audit.d.ts.map +1 -1
  382. package/dist/storage/tombstone-blocked-capture-index.d.ts +3 -0
  383. package/dist/storage/tombstone-blocked-capture-index.d.ts.map +1 -1
  384. package/dist/storage/tombstone-blocked-capture-mutation.d.ts +23 -3
  385. package/dist/storage/tombstone-blocked-capture-mutation.d.ts.map +1 -1
  386. package/dist/storage.d.ts +6 -0
  387. package/dist/storage.d.ts.map +1 -1
  388. package/dist/storage.js +33 -29
  389. package/dist/subject-config.js +6 -5
  390. package/dist/summarizer.js +4 -4
  391. package/dist/summary-snapshot.js +4 -3
  392. package/dist/support-passport/index.js +99 -95
  393. package/dist/{tier-stats-RQM76XYY.js → tier-stats-C3IAMS4X.js} +6 -5
  394. package/dist/{tier-stats-RQM76XYY.js.map → tier-stats-C3IAMS4X.js.map} +1 -1
  395. package/dist/{trace-LXXCMZJA.js → trace-QBQVS5BC.js} +5 -21
  396. package/dist/trace-QBQVS5BC.js.map +1 -0
  397. package/dist/transcript.d.ts.map +1 -1
  398. package/dist/transcript.js +2 -1
  399. package/dist/transfer/autodetect.js +1 -1
  400. package/dist/transfer/backup.js +1 -1
  401. package/dist/transfer/capsule-export.js +3 -3
  402. package/dist/transfer/capsule-import.js +7 -6
  403. package/dist/transfer/export-okf.js +32 -28
  404. package/dist/trust-zones.js +3 -2
  405. package/dist/types.d.ts +9 -0
  406. package/dist/types.d.ts.map +1 -1
  407. package/dist/types.js +1 -1
  408. package/dist/utility-learner.js +4 -3
  409. package/dist/utility-runtime.js +5 -4
  410. package/dist/utility-telemetry.js +3 -2
  411. package/dist/utils/macos-replication-junk.d.ts +32 -0
  412. package/dist/utils/macos-replication-junk.d.ts.map +1 -0
  413. package/dist/utils/malformed-entity-record.d.ts +24 -0
  414. package/dist/utils/malformed-entity-record.d.ts.map +1 -0
  415. package/dist/utils/serialize-mutations.js +3 -2
  416. package/dist/utils/sleep.d.ts +6 -0
  417. package/dist/utils/sleep.d.ts.map +1 -1
  418. package/dist/verified-recall.js +32 -28
  419. package/dist/who-knows-cli.js +33 -29
  420. package/dist/who-knows.js +32 -28
  421. package/dist/work-product-ledger.js +3 -2
  422. package/dist/write-envelope.js +6 -5
  423. package/package.json +22 -2
  424. package/src/calibration.ts +3 -2
  425. package/src/capture-write-lock-backoff.test.ts +534 -0
  426. package/src/capture-write-lock-backoff.ts +140 -0
  427. package/src/capture-write-lock.ts +8 -0
  428. package/src/cli.ts +2 -2
  429. package/src/console/trace.ts +5 -36
  430. package/src/consolidation-provenance-check.ts +2 -0
  431. package/src/converge-config.ts +80 -1
  432. package/src/correction/correction-planner.ts +3 -2
  433. package/src/extraction-quote-grounding.test.ts +546 -0
  434. package/src/extraction-quote-grounding.ts +232 -0
  435. package/src/extraction-source-grounding-helpers.ts +35 -0
  436. package/src/extraction-source-grounding-rules.ts +90 -65
  437. package/src/extraction-source-grounding.ts +11 -2
  438. package/src/index.ts +1 -1
  439. package/src/json-store.ts +3 -0
  440. package/src/macos-replication-junk-scanners.test.ts +275 -0
  441. package/src/maintenance/dreams-ledger.ts +2 -0
  442. package/src/maintenance/memory-governance.ts +2 -0
  443. package/src/namespaces/storage.ts +2 -0
  444. package/src/offline-sync-macos-junk.test.ts +169 -0
  445. package/src/offline-sync.ts +7 -0
  446. package/src/profiling.ts +2 -1
  447. package/src/providers/codex-subscription.test.ts +15 -3
  448. package/src/retrieval-agents.ts +29 -12
  449. package/src/search/document-scanner.ts +4 -0
  450. package/src/storage/content-hash-index.ts +10 -0
  451. package/src/storage/entity-canonical-id-migration.ts +56 -13
  452. package/src/storage/entity-store.ts +173 -15
  453. package/src/storage/memory-read-store.ts +30 -5
  454. package/src/storage/supersession-audit.ts +2 -0
  455. package/src/storage/tombstone-blocked-capture-index.ts +8 -1
  456. package/src/storage/tombstone-blocked-capture-mutation.ts +133 -43
  457. package/src/storage.ts +16 -2
  458. package/src/transcript.ts +11 -10
  459. package/src/types.ts +9 -0
  460. package/src/utils/macos-replication-junk.test.ts +46 -0
  461. package/src/utils/macos-replication-junk.ts +65 -0
  462. package/src/utils/malformed-entity-record.ts +101 -0
  463. package/src/utils/sleep.ts +28 -0
  464. package/dist/chunk-375ARKRS.js.map +0 -1
  465. package/dist/chunk-3J5JKBYD.js.map +0 -1
  466. package/dist/chunk-4O6WRBGE.js.map +0 -1
  467. package/dist/chunk-6MINUTGJ.js +0 -64
  468. package/dist/chunk-6MINUTGJ.js.map +0 -1
  469. package/dist/chunk-7LEQREP2.js +0 -9
  470. package/dist/chunk-7LEQREP2.js.map +0 -1
  471. package/dist/chunk-B6O2YLUR.js.map +0 -1
  472. package/dist/chunk-BLVHDY2U.js.map +0 -1
  473. package/dist/chunk-EQWEIIKQ.js.map +0 -1
  474. package/dist/chunk-HT2C4EXO.js.map +0 -1
  475. package/dist/chunk-KI6UOSNR.js.map +0 -1
  476. package/dist/chunk-MZBWIJJN.js.map +0 -1
  477. package/dist/chunk-Q4E24IRR.js.map +0 -1
  478. package/dist/chunk-QJ622LTI.js.map +0 -1
  479. package/dist/chunk-QWWMS4AE.js.map +0 -1
  480. package/dist/chunk-U7VPOXVM.js.map +0 -1
  481. package/dist/chunk-X3VID2TT.js.map +0 -1
  482. package/dist/chunk-XERVJYH2.js.map +0 -1
  483. package/dist/chunk-Y3VDGK2O.js.map +0 -1
  484. package/dist/chunk-YRH3C2OJ.js.map +0 -1
  485. package/dist/chunk-YYO447A7.js.map +0 -1
  486. package/dist/trace-LXXCMZJA.js.map +0 -1
  487. /package/dist/{auto-sync-DGJOZYGT.js.map → auto-sync-7WWAKW6F.js.map} +0 -0
  488. /package/dist/{dreams-ledger-567VKVOU.js.map → capture-write-lock-backoff.js.map} +0 -0
  489. /package/dist/{graph-edge-decay-CZ3SYLM4.js.map → capture-write-lock.js.map} +0 -0
  490. /package/dist/{chunk-KZO43HPY.js.map → chunk-22RM2ZUJ.js.map} +0 -0
  491. /package/dist/{chunk-ZUMXY4KA.js.map → chunk-22W2XWGH.js.map} +0 -0
  492. /package/dist/{chunk-PCWXLAJY.js.map → chunk-2PTH4PRL.js.map} +0 -0
  493. /package/dist/{chunk-ZIZ2G47N.js.map → chunk-2PYHLSXK.js.map} +0 -0
  494. /package/dist/{chunk-7OAIOE5P.js.map → chunk-33G67YZF.js.map} +0 -0
  495. /package/dist/{chunk-AV2OQF2O.js.map → chunk-3F3HA3R2.js.map} +0 -0
  496. /package/dist/{chunk-RP5SJ3XR.js.map → chunk-3GNIJUUE.js.map} +0 -0
  497. /package/dist/{chunk-QZZPUREO.js.map → chunk-3GYSZHMT.js.map} +0 -0
  498. /package/dist/{chunk-SWIKABKI.js.map → chunk-3Q3XD3NO.js.map} +0 -0
  499. /package/dist/{chunk-AL6EHLB5.js.map → chunk-3X3PNU3T.js.map} +0 -0
  500. /package/dist/{chunk-BTJ6CAIA.js.map → chunk-4IYIGN53.js.map} +0 -0
  501. /package/dist/{chunk-BZTRPCCH.js.map → chunk-4PDTVVSW.js.map} +0 -0
  502. /package/dist/{chunk-HM7RHKS4.js.map → chunk-4RNBLLZR.js.map} +0 -0
  503. /package/dist/{chunk-JUWJYXI4.js.map → chunk-5ATSXCAG.js.map} +0 -0
  504. /package/dist/{chunk-EHRE7ZG3.js.map → chunk-5B5WYAHQ.js.map} +0 -0
  505. /package/dist/{chunk-WCGJK4NQ.js.map → chunk-5FNZ3G6X.js.map} +0 -0
  506. /package/dist/{chunk-Y6DZ33PA.js.map → chunk-5GX5457J.js.map} +0 -0
  507. /package/dist/{chunk-EMFBC7L3.js.map → chunk-5KGYTX5O.js.map} +0 -0
  508. /package/dist/{chunk-OFCHT2TN.js.map → chunk-5LRV557D.js.map} +0 -0
  509. /package/dist/{chunk-DXHVD4DS.js.map → chunk-5SMR542T.js.map} +0 -0
  510. /package/dist/{chunk-S7LWX2PQ.js.map → chunk-655FVTCD.js.map} +0 -0
  511. /package/dist/{chunk-DGRMWDQY.js.map → chunk-66BCOVW2.js.map} +0 -0
  512. /package/dist/{chunk-5MDM7UE4.js.map → chunk-6WGMZQGG.js.map} +0 -0
  513. /package/dist/{chunk-IPLYGWQF.js.map → chunk-7LCGFUMB.js.map} +0 -0
  514. /package/dist/{chunk-5ZJYHOJT.js.map → chunk-7VQ6AI7H.js.map} +0 -0
  515. /package/dist/{chunk-KYY4EACB.js.map → chunk-7Z3DLNSD.js.map} +0 -0
  516. /package/dist/{chunk-G7NYVKD6.js.map → chunk-B2NXOVZN.js.map} +0 -0
  517. /package/dist/{chunk-B43NMCGQ.js.map → chunk-BK2BVLZW.js.map} +0 -0
  518. /package/dist/{chunk-BOOFTFFE.js.map → chunk-C2RW36YR.js.map} +0 -0
  519. /package/dist/{chunk-5JMI26Q7.js.map → chunk-CBH2Z4UA.js.map} +0 -0
  520. /package/dist/{chunk-P2S6P7X6.js.map → chunk-CFZ4SXXH.js.map} +0 -0
  521. /package/dist/{chunk-6M56RFFJ.js.map → chunk-CJRENHVZ.js.map} +0 -0
  522. /package/dist/{chunk-EGDYVYU7.js.map → chunk-CLWBFR7Q.js.map} +0 -0
  523. /package/dist/{chunk-6VAHJ2F6.js.map → chunk-DMDWFQMR.js.map} +0 -0
  524. /package/dist/{chunk-UZSBCQEC.js.map → chunk-DPSOFK4D.js.map} +0 -0
  525. /package/dist/{chunk-IZT3BVDW.js.map → chunk-DQR2LD3V.js.map} +0 -0
  526. /package/dist/{chunk-K4QY55XV.js.map → chunk-EH4BQ7LT.js.map} +0 -0
  527. /package/dist/{chunk-EBA5DA77.js.map → chunk-EOU6V4IN.js.map} +0 -0
  528. /package/dist/{chunk-7KYJNHGM.js.map → chunk-EUCYTCFP.js.map} +0 -0
  529. /package/dist/{chunk-YNDLCWXS.js.map → chunk-EZ25VE3G.js.map} +0 -0
  530. /package/dist/{chunk-CKUUP64O.js.map → chunk-F2772ATT.js.map} +0 -0
  531. /package/dist/{chunk-46EST7JO.js.map → chunk-F2XNSIPP.js.map} +0 -0
  532. /package/dist/{chunk-2KRNPFPK.js.map → chunk-FLI6DEIU.js.map} +0 -0
  533. /package/dist/{chunk-OAIWPB2I.js.map → chunk-FT4UQYOV.js.map} +0 -0
  534. /package/dist/{chunk-HYNEDMYJ.js.map → chunk-G2OYFTUD.js.map} +0 -0
  535. /package/dist/{chunk-XTN54NML.js.map → chunk-G3T6YMBO.js.map} +0 -0
  536. /package/dist/{chunk-CNG2XVZG.js.map → chunk-G3UUAQOD.js.map} +0 -0
  537. /package/dist/{chunk-2ZQJLBV6.js.map → chunk-GCVDFX66.js.map} +0 -0
  538. /package/dist/{chunk-ON4ILX3G.js.map → chunk-GFAM2LTC.js.map} +0 -0
  539. /package/dist/{chunk-2LUSQV4U.js.map → chunk-GKJJNO7C.js.map} +0 -0
  540. /package/dist/{chunk-T2YX56QI.js.map → chunk-GQJKVQJR.js.map} +0 -0
  541. /package/dist/{chunk-5AOAQR37.js.map → chunk-GWVNGDJW.js.map} +0 -0
  542. /package/dist/{chunk-YDH2FSDI.js.map → chunk-GZXXPCWJ.js.map} +0 -0
  543. /package/dist/{chunk-5JCLELOP.js.map → chunk-H5IUN433.js.map} +0 -0
  544. /package/dist/{chunk-IWHEJXR2.js.map → chunk-H6FREOYX.js.map} +0 -0
  545. /package/dist/{chunk-B7CANWCA.js.map → chunk-HBAOOSHU.js.map} +0 -0
  546. /package/dist/{chunk-T3FMRLWQ.js.map → chunk-HFSPY26A.js.map} +0 -0
  547. /package/dist/{chunk-B657ZGDH.js.map → chunk-HQSK2INQ.js.map} +0 -0
  548. /package/dist/{chunk-RT6D3WN7.js.map → chunk-IJMDBYCO.js.map} +0 -0
  549. /package/dist/{chunk-CS2JEHTB.js.map → chunk-IUCPLBDS.js.map} +0 -0
  550. /package/dist/{chunk-XRBHXUTQ.js.map → chunk-IWD33CF4.js.map} +0 -0
  551. /package/dist/{chunk-4IHBN6WU.js.map → chunk-JKMIGCK6.js.map} +0 -0
  552. /package/dist/{chunk-ROBHL3GL.js.map → chunk-JWX2Q6HS.js.map} +0 -0
  553. /package/dist/{chunk-3I3U6FFT.js.map → chunk-K7BN34IA.js.map} +0 -0
  554. /package/dist/{chunk-4THZGKQ2.js.map → chunk-KLJVTZ3R.js.map} +0 -0
  555. /package/dist/{chunk-4G4B3Z2B.js.map → chunk-KW4AJ7T3.js.map} +0 -0
  556. /package/dist/{chunk-ZI7LMSNI.js.map → chunk-LLHZZOIB.js.map} +0 -0
  557. /package/dist/{chunk-LS2FHUML.js.map → chunk-LQ5SS4OP.js.map} +0 -0
  558. /package/dist/{chunk-NSFOERZQ.js.map → chunk-LWFWZTWX.js.map} +0 -0
  559. /package/dist/{chunk-BMWN7B3Y.js.map → chunk-LXATZLSC.js.map} +0 -0
  560. /package/dist/{chunk-OYKQ6T4V.js.map → chunk-MATDGSJ7.js.map} +0 -0
  561. /package/dist/{chunk-3NFN4Y4P.js.map → chunk-MGCKZWAE.js.map} +0 -0
  562. /package/dist/{chunk-O4KYRDRT.js.map → chunk-MJIOGYKX.js.map} +0 -0
  563. /package/dist/{chunk-6OMUHXHP.js.map → chunk-ML7ZJAKJ.js.map} +0 -0
  564. /package/dist/{chunk-GKIXBH7Y.js.map → chunk-MO6N4QYY.js.map} +0 -0
  565. /package/dist/{chunk-A2E4WNW4.js.map → chunk-MWWAQXZ6.js.map} +0 -0
  566. /package/dist/{chunk-VYPFEVOM.js.map → chunk-NHUX6GXA.js.map} +0 -0
  567. /package/dist/{chunk-AKREOU5F.js.map → chunk-NZCKG25S.js.map} +0 -0
  568. /package/dist/{chunk-4NDWE44P.js.map → chunk-NZFFGO5O.js.map} +0 -0
  569. /package/dist/{chunk-WWSRLS4M.js.map → chunk-O2YPCFJT.js.map} +0 -0
  570. /package/dist/{chunk-ZSJGYC3C.js.map → chunk-OQJKY3Z5.js.map} +0 -0
  571. /package/dist/{chunk-OFEHITAZ.js.map → chunk-OXNTOHL6.js.map} +0 -0
  572. /package/dist/{chunk-FQD2KPQH.js.map → chunk-P55FACBG.js.map} +0 -0
  573. /package/dist/{chunk-JYZSRNR7.js.map → chunk-PIITB2YZ.js.map} +0 -0
  574. /package/dist/{chunk-PBVNVKYN.js.map → chunk-PIN5OPBA.js.map} +0 -0
  575. /package/dist/{chunk-4TTGRETU.js.map → chunk-PRU7OF3Y.js.map} +0 -0
  576. /package/dist/{chunk-K2FSASGZ.js.map → chunk-PVHQSLNN.js.map} +0 -0
  577. /package/dist/{chunk-SVDU4OHO.js.map → chunk-Q35L7TYB.js.map} +0 -0
  578. /package/dist/{chunk-5VC7J76U.js.map → chunk-QPH52AZB.js.map} +0 -0
  579. /package/dist/{chunk-6T42L5FI.js.map → chunk-QS3OLP5I.js.map} +0 -0
  580. /package/dist/{chunk-P34FDDB5.js.map → chunk-QSEUUQUF.js.map} +0 -0
  581. /package/dist/{chunk-PAAJWQH5.js.map → chunk-QUMKDRCF.js.map} +0 -0
  582. /package/dist/{chunk-KZEMFD6E.js.map → chunk-R2H4ZFBJ.js.map} +0 -0
  583. /package/dist/{chunk-JFVCDEIC.js.map → chunk-RP7PQWZM.js.map} +0 -0
  584. /package/dist/{chunk-KC46VZR5.js.map → chunk-RTTPBBAN.js.map} +0 -0
  585. /package/dist/{chunk-ZQ3WU6JO.js.map → chunk-RXFCU3CY.js.map} +0 -0
  586. /package/dist/{chunk-CBP4HWCL.js.map → chunk-RYYVMZBR.js.map} +0 -0
  587. /package/dist/{chunk-2NCBDGND.js.map → chunk-SA6GMZJY.js.map} +0 -0
  588. /package/dist/{chunk-VFTK5WKI.js.map → chunk-STBX5X6B.js.map} +0 -0
  589. /package/dist/{chunk-WVHRNAXL.js.map → chunk-SWWHIJUJ.js.map} +0 -0
  590. /package/dist/{chunk-WADSXS4K.js.map → chunk-SX4QDWXK.js.map} +0 -0
  591. /package/dist/{chunk-WETFW255.js.map → chunk-T7ASDYNK.js.map} +0 -0
  592. /package/dist/{chunk-XZLWYZ7C.js.map → chunk-THEPGZBM.js.map} +0 -0
  593. /package/dist/{chunk-YEM7K3KD.js.map → chunk-TMC7HBED.js.map} +0 -0
  594. /package/dist/{chunk-RWRQ67OR.js.map → chunk-TPNCXSXP.js.map} +0 -0
  595. /package/dist/{chunk-LZKOVXMX.js.map → chunk-TRMJ6BYC.js.map} +0 -0
  596. /package/dist/{chunk-A6TVQ3QP.js.map → chunk-UGYUBENJ.js.map} +0 -0
  597. /package/dist/{chunk-AAM66QCP.js.map → chunk-UZRSI6NX.js.map} +0 -0
  598. /package/dist/{chunk-XHWJRUVP.js.map → chunk-V3TXIXXY.js.map} +0 -0
  599. /package/dist/{chunk-2CXQZXWM.js.map → chunk-V4MB5ONM.js.map} +0 -0
  600. /package/dist/{chunk-UOKPJFO3.js.map → chunk-VNZMZPAC.js.map} +0 -0
  601. /package/dist/{chunk-FZB4TS2W.js.map → chunk-VPXIKBPX.js.map} +0 -0
  602. /package/dist/{chunk-CYEK6Z3P.js.map → chunk-VW6VIJOS.js.map} +0 -0
  603. /package/dist/{chunk-QUA7RLK6.js.map → chunk-W3FVQBGF.js.map} +0 -0
  604. /package/dist/{chunk-6OQ6N5RP.js.map → chunk-WGTR573G.js.map} +0 -0
  605. /package/dist/{chunk-W3K3HITK.js.map → chunk-WLT6LTQP.js.map} +0 -0
  606. /package/dist/{chunk-6Z2AZ4AJ.js.map → chunk-XKRXN63M.js.map} +0 -0
  607. /package/dist/{chunk-FZVROZKC.js.map → chunk-XVZA6VXC.js.map} +0 -0
  608. /package/dist/{chunk-DA2INEB5.js.map → chunk-XYGQSDTH.js.map} +0 -0
  609. /package/dist/{chunk-RBJQYMMT.js.map → chunk-YRULQW5J.js.map} +0 -0
  610. /package/dist/{chunk-QUNDYIYZ.js.map → chunk-YYEOR4XN.js.map} +0 -0
  611. /package/dist/{chunk-6WHJ2EAB.js.map → chunk-Z64TS5V4.js.map} +0 -0
  612. /package/dist/{chunk-NHLLKEKK.js.map → chunk-ZAJLJ35W.js.map} +0 -0
  613. /package/dist/{chunk-M7V65M6H.js.map → chunk-ZKHSAMTE.js.map} +0 -0
  614. /package/dist/{resolution-EKJHREVJ.js.map → dreams-ledger-UCHHRQ4R.js.map} +0 -0
@@ -7,10 +7,10 @@ import {
7
7
  import {
8
8
  listMemoryGovernanceRuns,
9
9
  readMemoryGovernanceRunArtifact
10
- } from "./chunk-XERVJYH2.js";
10
+ } from "./chunk-C6JMGAMO.js";
11
11
  import {
12
12
  StorageManager
13
- } from "./chunk-Y3VDGK2O.js";
13
+ } from "./chunk-4SCZZ3U7.js";
14
14
  import {
15
15
  normalizeProjectionPreview,
16
16
  normalizeProjectionTags
@@ -21,7 +21,7 @@ import {
21
21
  readProjectedGovernanceRows,
22
22
  readProjectedNativeKnowledgeRows,
23
23
  writeProjectionMetaHighWater
24
- } from "./chunk-FQD2KPQH.js";
24
+ } from "./chunk-P55FACBG.js";
25
25
  import {
26
26
  MEMORY_LIFECYCLE_EVENT_SORT_ORDER,
27
27
  buildLifecycleEventsForMemory,
@@ -1156,4 +1156,4 @@ export {
1156
1156
  verifyMemoryProjection,
1157
1157
  repairMemoryProjection
1158
1158
  };
1159
- //# sourceMappingURL=chunk-JUWJYXI4.js.map
1159
+ //# sourceMappingURL=chunk-5ATSXCAG.js.map
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  sleep
3
- } from "./chunk-7LEQREP2.js";
3
+ } from "./chunk-PGRZ3FYC.js";
4
4
 
5
5
  // src/utils/serialize-mutations.ts
6
6
  import { randomUUID } from "crypto";
@@ -297,4 +297,4 @@ export {
297
297
  serializeMutations,
298
298
  withHeldFileLock
299
299
  };
300
- //# sourceMappingURL=chunk-EHRE7ZG3.js.map
300
+ //# sourceMappingURL=chunk-5B5WYAHQ.js.map
@@ -1,12 +1,3 @@
1
- import {
2
- LcmDag
3
- } from "./chunk-7N4KAIGN.js";
4
- import {
5
- LcmWorkQueue
6
- } from "./chunk-MMCO4SRG.js";
7
- import {
8
- assembleCompressedHistoryWithTrace
9
- } from "./chunk-UXPUUL3G.js";
10
1
  import {
11
2
  ensureLcmStateDir,
12
3
  openLcmDatabase
@@ -17,6 +8,15 @@ import {
17
8
  import {
18
9
  LcmArchive
19
10
  } from "./chunk-WVP2I6C5.js";
11
+ import {
12
+ LcmDag
13
+ } from "./chunk-7N4KAIGN.js";
14
+ import {
15
+ LcmWorkQueue
16
+ } from "./chunk-MMCO4SRG.js";
17
+ import {
18
+ assembleCompressedHistoryWithTrace
19
+ } from "./chunk-UXPUUL3G.js";
20
20
  import {
21
21
  nativeBindingRecoveryHint
22
22
  } from "./chunk-LD72P4YS.js";
@@ -602,4 +602,4 @@ export {
602
602
  extractLcmConfig,
603
603
  LcmEngine
604
604
  };
605
- //# sourceMappingURL=chunk-WCGJK4NQ.js.map
605
+ //# sourceMappingURL=chunk-5FNZ3G6X.js.map
@@ -1,16 +1,16 @@
1
1
  import {
2
2
  writeGraphJsonlAtomic
3
- } from "./chunk-QUNDYIYZ.js";
3
+ } from "./chunk-YYEOR4XN.js";
4
4
  import {
5
5
  graphFilePath,
6
6
  graphsDir,
7
7
  readEdgesStrict
8
- } from "./chunk-BTJ6CAIA.js";
8
+ } from "./chunk-4IYIGN53.js";
9
9
  import {
10
10
  assertGraphLockHeld,
11
11
  withGraphWriteLock,
12
12
  yieldForLockHeartbeat
13
- } from "./chunk-ZQ3WU6JO.js";
13
+ } from "./chunk-RXFCU3CY.js";
14
14
  import {
15
15
  DEFAULT_DECAY_FLOOR,
16
16
  DEFAULT_DECAY_PER_WINDOW,
@@ -215,4 +215,4 @@ export {
215
215
  discoverGraphNamespaceRoots,
216
216
  runGraphEdgeDecayMaintenanceAcrossNamespaces
217
217
  };
218
- //# sourceMappingURL=chunk-Y6DZ33PA.js.map
218
+ //# sourceMappingURL=chunk-5GX5457J.js.map
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  parseFrontmatter
3
- } from "./chunk-Y3VDGK2O.js";
3
+ } from "./chunk-4SCZZ3U7.js";
4
4
  import {
5
5
  activityDigestPath,
6
6
  isValidActivityDate
@@ -199,4 +199,4 @@ export {
199
199
  buildStandup,
200
200
  standupHelp
201
201
  };
202
- //# sourceMappingURL=chunk-EMFBC7L3.js.map
202
+ //# sourceMappingURL=chunk-5KGYTX5O.js.map
@@ -3,7 +3,7 @@ import {
3
3
  } from "./chunk-BT7NVCML.js";
4
4
  import {
5
5
  isMemorySubject
6
- } from "./chunk-VFTK5WKI.js";
6
+ } from "./chunk-STBX5X6B.js";
7
7
  import {
8
8
  assemblePersistedBody
9
9
  } from "./chunk-JDSVLVCG.js";
@@ -443,4 +443,4 @@ export {
443
443
  buildAccessWriteRequestFingerprint,
444
444
  buildObserveRequestFingerprint
445
445
  };
446
- //# sourceMappingURL=chunk-OFCHT2TN.js.map
446
+ //# sourceMappingURL=chunk-5LRV557D.js.map
@@ -2,11 +2,11 @@ import {
2
2
  OFFLINE_SYNC_SNAPSHOT_FORMAT,
3
3
  filterOfflineSyncDeletionRevisions,
4
4
  iterateOfflineSyncSnapshotFileRecords
5
- } from "./chunk-MZBWIJJN.js";
5
+ } from "./chunk-23ZQPP2G.js";
6
6
  import {
7
7
  computeOmittedEmbeddingGenerationPaths,
8
8
  embeddingGenerationMembership
9
- } from "./chunk-3NFN4Y4P.js";
9
+ } from "./chunk-MGCKZWAE.js";
10
10
  import {
11
11
  matchesOfflineSyncDefaultExclude
12
12
  } from "./chunk-63LFM77Z.js";
@@ -61,4 +61,4 @@ async function buildEmbeddingAwareSnapshotStream(options) {
61
61
  export {
62
62
  buildEmbeddingAwareSnapshotStream
63
63
  };
64
- //# sourceMappingURL=chunk-DXHVD4DS.js.map
64
+ //# sourceMappingURL=chunk-5SMR542T.js.map
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  scanMemoryDir
3
- } from "./chunk-4O6WRBGE.js";
3
+ } from "./chunk-KJXP6RUG.js";
4
4
  import {
5
5
  isSearchAborted,
6
6
  throwIfSearchAborted
@@ -508,4 +508,4 @@ function isMissingVectorProviderColumnError(err) {
508
508
  export {
509
509
  LanceDbBackend
510
510
  };
511
- //# sourceMappingURL=chunk-S7LWX2PQ.js.map
511
+ //# sourceMappingURL=chunk-655FVTCD.js.map
@@ -1,6 +1,12 @@
1
1
  import {
2
2
  resolveEnsureCollectionArgs
3
3
  } from "./chunk-G26YNEOC.js";
4
+ import {
5
+ QmdDaemonSession
6
+ } from "./chunk-SWWHIJUJ.js";
7
+ import {
8
+ createInflightJoiner
9
+ } from "./chunk-TPSLVZHS.js";
4
10
  import {
5
11
  QMD_PROBE_RETRY_BACKOFF_MS,
6
12
  QMD_PROBE_TIMEOUT_MS,
@@ -19,12 +25,6 @@ import {
19
25
  embedQmdFiles,
20
26
  fetchQmdStatus
21
27
  } from "./chunk-IUM3VSHI.js";
22
- import {
23
- QmdDaemonSession
24
- } from "./chunk-WVHRNAXL.js";
25
- import {
26
- createInflightJoiner
27
- } from "./chunk-TPSLVZHS.js";
28
28
  import {
29
29
  clearQmdResultCaches,
30
30
  getCachedQmdSearch,
@@ -2028,4 +2028,4 @@ export {
2028
2028
  sharedDaemonSessionCountForTest,
2029
2029
  QmdClient
2030
2030
  };
2031
- //# sourceMappingURL=chunk-DGRMWDQY.js.map
2031
+ //# sourceMappingURL=chunk-66BCOVW2.js.map
@@ -0,0 +1,298 @@
1
+ import {
2
+ CAPTURE_WRITE_LOCK_BUSY_MESSAGE,
3
+ captureWriteLockDelayMs,
4
+ resolveCaptureWriteLockBackoffLimits
5
+ } from "./chunk-YET735EZ.js";
6
+ import {
7
+ withHeldFileLock
8
+ } from "./chunk-5B5WYAHQ.js";
9
+ import {
10
+ sleepAbortable
11
+ } from "./chunk-PGRZ3FYC.js";
12
+ import {
13
+ raceAbort,
14
+ throwIfAborted
15
+ } from "./chunk-BTTPKDIL.js";
16
+ import {
17
+ log
18
+ } from "./chunk-3WCASNQZ.js";
19
+
20
+ // src/storage/tombstone-blocked-capture-mutation.ts
21
+ import { AsyncLocalStorage } from "async_hooks";
22
+ import { createHash } from "crypto";
23
+ import { mkdir } from "fs/promises";
24
+ import path from "path";
25
+ var TOMBSTONE_CAPTURE_WRITE_LOCK_STALE_MS = 6e4;
26
+ var CAPTURE_WRITE_LOCK_PROBE_MS = 1;
27
+ var CAPTURE_WRITE_LOCK_RETRY = /* @__PURE__ */ Symbol("capture-write-lock-retry");
28
+ var CAPTURE_WRITE_LOCK_PERMANENT = /* @__PURE__ */ Symbol("capture-write-lock-permanent-failure");
29
+ function normalizeExplicitCaptureContent(value) {
30
+ return value.toLowerCase().replace(/\s+/g, " ").trim();
31
+ }
32
+ function buildExplicitCaptureDedupKey(content, category, sourceConnector) {
33
+ const encode = (label, value) => `${label} ${value.length} ${value}`;
34
+ return [
35
+ encode("category", category),
36
+ encode("connector", sourceConnector?.trim() ?? ""),
37
+ encode("content", normalizeExplicitCaptureContent(content))
38
+ ].join(" ");
39
+ }
40
+ function buildCapturePathLockIdentity(pathname) {
41
+ return `path ${pathname.length} ${pathname}`;
42
+ }
43
+ function captureIdentityHash(memory) {
44
+ return createHash("sha256").update(
45
+ buildExplicitCaptureDedupKey(memory.content, memory.frontmatter.category, memory.frontmatter.sourceConnector)
46
+ ).digest("hex");
47
+ }
48
+ var TombstoneBlockedCaptureWriteLock = class {
49
+ constructor(options) {
50
+ this.options = options;
51
+ }
52
+ options;
53
+ context = new AsyncLocalStorage();
54
+ captureWriteLockPathForHash(identityHash) {
55
+ const filename = identityHash.length === 0 ? "explicit-capture-write.lock" : `explicit-capture-write-${identityHash}.lock`;
56
+ return path.join(this.options.stateDir, "tombstone-blocked-capture", filename);
57
+ }
58
+ now() {
59
+ return this.options.now?.() ?? Date.now();
60
+ }
61
+ debug(message) {
62
+ if (this.options.logDebug) {
63
+ this.options.logDebug(message);
64
+ return;
65
+ }
66
+ log.debug(message);
67
+ }
68
+ warn(message) {
69
+ if (this.options.logWarn) {
70
+ this.options.logWarn(message);
71
+ return;
72
+ }
73
+ log.warn(message);
74
+ }
75
+ /** Prefer the constructor seam; converge installs the signal on lock options at acquire time. */
76
+ captureAbortSignal() {
77
+ return this.options.signal ?? this.options.lockOptions?.()?.captureWriteLockSignal;
78
+ }
79
+ /**
80
+ * One probe of a single lock file. Returns the retry symbol when the lock
81
+ * is busy and the permanent symbol on a filesystem error. Does not sleep:
82
+ * the caller backs off only after the whole chain has unwound.
83
+ */
84
+ async withSingleCaptureWriteLockOnce(lockPath, task) {
85
+ await mkdir(path.dirname(lockPath), { recursive: true });
86
+ const runWithHeldFileLock = this.options.withHeldFileLock ?? withHeldFileLock;
87
+ return await runWithHeldFileLock(
88
+ lockPath,
89
+ {
90
+ staleMs: TOMBSTONE_CAPTURE_WRITE_LOCK_STALE_MS,
91
+ maxWaitMs: CAPTURE_WRITE_LOCK_PROBE_MS,
92
+ pollMs: CAPTURE_WRITE_LOCK_PROBE_MS
93
+ },
94
+ async (acquired, controller) => {
95
+ if (acquired) return await task();
96
+ return controller.failure === "error" ? CAPTURE_WRITE_LOCK_PERMANENT : CAPTURE_WRITE_LOCK_RETRY;
97
+ }
98
+ );
99
+ }
100
+ async withPhysicalCaptureWriteLocks(task, identityHashes) {
101
+ const signal = this.captureAbortSignal();
102
+ const lockPaths = [...new Set(identityHashes.map((hash) => this.captureWriteLockPathForHash(hash)))];
103
+ const limits = resolveCaptureWriteLockBackoffLimits(this.options.lockOptions?.());
104
+ const deadline = this.now() + limits.deadlineMs;
105
+ const giveUp = () => {
106
+ throwIfAborted(signal);
107
+ this.warn(
108
+ `tombstone-blocked capture write lock remained busy after ${limits.deadlineMs}ms; failing this write so the rest of the cycle can continue`
109
+ );
110
+ throw new Error(CAPTURE_WRITE_LOCK_BUSY_MESSAGE);
111
+ };
112
+ const acquire = async (index) => {
113
+ throwIfAborted(signal);
114
+ const runTask = async () => {
115
+ if (this.now() >= deadline) giveUp();
116
+ return await task();
117
+ };
118
+ if (index === lockPaths.length) return await runTask();
119
+ const lockPath = lockPaths[index];
120
+ if (lockPath === void 0) return await runTask();
121
+ if (this.now() >= deadline) giveUp();
122
+ return await this.withSingleCaptureWriteLockOnce(lockPath, () => acquire(index + 1));
123
+ };
124
+ for (let attempt = 0; ; attempt += 1) {
125
+ throwIfAborted(signal);
126
+ const outcome = await acquire(0);
127
+ if (outcome === CAPTURE_WRITE_LOCK_PERMANENT) {
128
+ throw new Error("tombstone-blocked capture write lock acquisition failed");
129
+ }
130
+ if (outcome !== CAPTURE_WRITE_LOCK_RETRY) return outcome;
131
+ throwIfAborted(signal);
132
+ const now = this.now();
133
+ if (now >= deadline) giveUp();
134
+ const delay = Math.min(
135
+ captureWriteLockDelayMs(attempt, limits, this.options.random ?? Math.random),
136
+ deadline - now
137
+ );
138
+ if (delay <= 0) giveUp();
139
+ this.debug(`tombstone-blocked capture write lock busy; backing off ${delay}ms before retry ${attempt + 1}`);
140
+ await raceAbort((this.options.sleep ?? sleepAbortable)(delay, signal), signal);
141
+ }
142
+ }
143
+ async withCaptureWriteLock(task, identity) {
144
+ const identities = Array.isArray(identity) && identity.length > 0 ? identity : [typeof identity === "string" ? identity : ""];
145
+ return await this.withCaptureWriteLocks(task, identities, []);
146
+ }
147
+ async withCaptureWriteLockHashes(task, identityHashes) {
148
+ return await this.withCaptureWriteLocks(task, [], identityHashes);
149
+ }
150
+ async withCaptureWriteLockAndHashes(task, identity, identityHashes) {
151
+ const identities = Array.isArray(identity) && identity.length > 0 ? identity : [typeof identity === "string" ? identity : ""];
152
+ return await this.withCaptureWriteLocks(task, identities, identityHashes);
153
+ }
154
+ async withCaptureWriteLocks(task, identities, identityHashes) {
155
+ throwIfAborted(this.captureAbortSignal());
156
+ const current = this.context.getStore();
157
+ const hashToken = (key) => `\0${key.length === 0 ? "" : createHash("sha256").update(key).digest("hex")}`;
158
+ const identityHash = (key) => key.length === 0 ? "" : createHash("sha256").update(key).digest("hex");
159
+ const identityKeys = [...new Set(identities)];
160
+ const hashes = [...new Set(identityHashes)];
161
+ const requested = [
162
+ ...identityKeys.filter((key) => !current || !current.has(key) && !current.has(hashToken(key))).map((key) => ({ hash: identityHash(key), pathLock: key.startsWith("path ") })),
163
+ ...hashes.filter((hash) => !current || !current.has(`\0${hash}`)).map((hash) => ({ hash, pathLock: false }))
164
+ ].filter((entry, index, entries) => entries.findIndex((candidate) => candidate.hash === entry.hash) === index).sort(
165
+ (left, right) => Number(left.pathLock) - Number(right.pathLock) || this.captureWriteLockPathForHash(left.hash).localeCompare(this.captureWriteLockPathForHash(right.hash))
166
+ );
167
+ const physicalMissing = requested.map((entry) => entry.hash);
168
+ if (current && requested.length > 0) {
169
+ const held = [...current].filter((token) => token.startsWith("\0")).map((token) => {
170
+ const hash = token.slice(1);
171
+ const pathLock = [...current].some(
172
+ (key) => !key.startsWith("\0") && key.startsWith("path ") && hashToken(key) === token
173
+ );
174
+ return { hash, pathLock };
175
+ });
176
+ const requestedFirst = requested[0];
177
+ const heldLast = held.sort(
178
+ (left, right) => Number(left.pathLock) - Number(right.pathLock) || this.captureWriteLockPathForHash(left.hash).localeCompare(this.captureWriteLockPathForHash(right.hash))
179
+ ).at(-1);
180
+ if (heldLast && requestedFirst && (Number(requestedFirst.pathLock) < Number(heldLast.pathLock) || requestedFirst.pathLock === heldLast.pathLock && this.captureWriteLockPathForHash(requestedFirst.hash) < this.captureWriteLockPathForHash(heldLast.hash))) {
181
+ throw new Error(CAPTURE_WRITE_LOCK_BUSY_MESSAGE);
182
+ }
183
+ }
184
+ const next = new Set(current);
185
+ for (const key of identityKeys) {
186
+ next.add(key);
187
+ next.add(hashToken(key));
188
+ }
189
+ for (const hash of hashes) next.add(`\0${hash}`);
190
+ const run = () => {
191
+ throwIfAborted(this.captureAbortSignal());
192
+ return this.context.run(next, task);
193
+ };
194
+ if (physicalMissing.length === 0) return await run();
195
+ return await this.withPhysicalCaptureWriteLocks(run, physicalMissing);
196
+ }
197
+ };
198
+ async function runTombstoneBlockedMutation(host, mutation) {
199
+ let lockIdentity = mutation.identity;
200
+ for (; ; ) {
201
+ let retryIdentity;
202
+ let mintedRevision;
203
+ const mutate = async () => {
204
+ const current = await host.readCurrent();
205
+ const currentBlocked = host.isBlocked(current);
206
+ const currentQueuedReview = host.isQueuedReview(current);
207
+ if (current !== null && (mutation.coordinate === true || currentBlocked || currentQueuedReview)) {
208
+ const currentIdentity = host.memoryIdentity(current);
209
+ const heldIdentities = Array.isArray(lockIdentity) ? lockIdentity : [lockIdentity];
210
+ if (!heldIdentities.includes(currentIdentity)) {
211
+ retryIdentity = currentIdentity;
212
+ return;
213
+ }
214
+ }
215
+ const rebuildMarker = mutation.blocked || currentBlocked ? await host.prepareWrite() : void 0;
216
+ const discardRebuildMarker = async () => {
217
+ if (!rebuildMarker) return;
218
+ try {
219
+ await host.discardWrite(rebuildMarker);
220
+ } catch (cleanupError) {
221
+ host.markUntrusted();
222
+ host.logWarning(`storage.tombstoneBlocked failed to clear write marker: ${cleanupError}`);
223
+ }
224
+ };
225
+ let transaction;
226
+ try {
227
+ transaction = mutation.shouldMintRevision?.(current) ? await host.beginDurableMemoryRevision?.(mutation.pathname, mutation.fileContent) : void 0;
228
+ await host.writeStorageSecureFile(mutation.pathname, mutation.fileContent);
229
+ } catch (err) {
230
+ if (transaction) {
231
+ try {
232
+ await transaction.abort();
233
+ } catch (abortError) {
234
+ host.logWarning(
235
+ `storage.tombstoneBlocked failed to abort the reserved receipt (pending marker preserved): ${abortError}`
236
+ );
237
+ }
238
+ }
239
+ await discardRebuildMarker();
240
+ throw err;
241
+ }
242
+ if (transaction) {
243
+ try {
244
+ await transaction.writeLanded();
245
+ } catch (evidenceError) {
246
+ host.logWarning(
247
+ `storage.tombstoneBlocked failed to record receipt crash evidence (pending marker preserved): ${evidenceError}`
248
+ );
249
+ }
250
+ try {
251
+ await transaction.commit();
252
+ } catch (err) {
253
+ host.logWarning(
254
+ `storage.tombstoneBlocked receipt publication failed after the memory write (pending marker preserved for recovery): ${err}`
255
+ );
256
+ await discardRebuildMarker();
257
+ throw err;
258
+ }
259
+ }
260
+ mintedRevision = transaction?.pendingRevision;
261
+ if (rebuildMarker) {
262
+ try {
263
+ await host.commitWrite(rebuildMarker);
264
+ } catch (err) {
265
+ host.markUntrusted();
266
+ host.logWarning(`storage.tombstoneBlocked committed write marker failed: ${err}`);
267
+ }
268
+ }
269
+ if (rebuildMarker) await mutation.beforeIndexUpdate?.();
270
+ await mutation.updateIndex(rebuildMarker, currentBlocked && current !== null ? current : void 0);
271
+ };
272
+ await host.withCaptureWriteLock(mutate, lockIdentity);
273
+ if (retryIdentity === void 0) return mintedRevision;
274
+ const identities = Array.isArray(lockIdentity) ? [...lockIdentity, retryIdentity] : [lockIdentity, retryIdentity];
275
+ lockIdentity = [...new Set(identities)];
276
+ }
277
+ }
278
+ function tombstoneBlocked(frontmatter) {
279
+ return frontmatter.status === "pending_review" && Boolean(frontmatter.blockedBy);
280
+ }
281
+ function isQueuedReviewFrontmatter(frontmatter) {
282
+ return frontmatter.status === "pending_review" && (frontmatter.tags ?? []).includes("queued-review");
283
+ }
284
+ function isQueuedReviewMemory(memory) {
285
+ return memory !== null && isQueuedReviewFrontmatter(memory.frontmatter);
286
+ }
287
+
288
+ export {
289
+ normalizeExplicitCaptureContent,
290
+ buildExplicitCaptureDedupKey,
291
+ buildCapturePathLockIdentity,
292
+ captureIdentityHash,
293
+ TombstoneBlockedCaptureWriteLock,
294
+ runTombstoneBlockedMutation,
295
+ tombstoneBlocked,
296
+ isQueuedReviewMemory
297
+ };
298
+ //# sourceMappingURL=chunk-6EDW54SQ.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../src/storage/tombstone-blocked-capture-mutation.ts"],"sourcesContent":["import { AsyncLocalStorage } from \"node:async_hooks\";\nimport { createHash } from \"node:crypto\";\nimport { mkdir } from \"node:fs/promises\";\nimport path from \"node:path\";\nimport { raceAbort, throwIfAborted } from \"../abort-error.js\";\nimport {\n CAPTURE_WRITE_LOCK_BUSY_MESSAGE,\n type CaptureWriteLockLimitSource,\n captureWriteLockDelayMs,\n resolveCaptureWriteLockBackoffLimits,\n} from \"../capture-write-lock-backoff.js\";\nimport { log } from \"../logger.js\";\nimport type { MemoryFile, MemoryFrontmatter } from \"../types.js\";\nimport { withHeldFileLock } from \"../utils/serialize-mutations.js\";\nimport { sleepAbortable } from \"../utils/sleep.js\";\nimport type { CasRevisionTransaction } from \"./cas-revision-store.js\";\n\nexport { isTombstoneBlockedCaptureWriteLockBusy } from \"../capture-write-lock-backoff.js\";\n\nconst TOMBSTONE_CAPTURE_WRITE_LOCK_STALE_MS = 60_000;\n/**\n * One exclusive-create probe. The bounded wait lives in the outer backoff,\n * which runs only after every lock from this attempt has been released.\n * A multi-second poll here would hold an already-acquired sibling lock.\n */\nconst CAPTURE_WRITE_LOCK_PROBE_MS = 1;\nconst CAPTURE_WRITE_LOCK_RETRY = Symbol(\"capture-write-lock-retry\");\nconst CAPTURE_WRITE_LOCK_PERMANENT = Symbol(\"capture-write-lock-permanent-failure\");\n\nexport function normalizeExplicitCaptureContent(value: string): string {\n return value.toLowerCase().replace(/\\s+/g, \" \").trim();\n}\n\nexport function buildExplicitCaptureDedupKey(\n content: string,\n category: string,\n sourceConnector: string | undefined\n): string {\n const encode = (label: string, value: string): string => `${label} ${value.length} ${value}`;\n return [\n encode(\"category\", category),\n encode(\"connector\", sourceConnector?.trim() ?? \"\"),\n encode(\"content\", normalizeExplicitCaptureContent(content)),\n ].join(\" \");\n}\n\nexport function buildCapturePathLockIdentity(pathname: string): string {\n return `path ${pathname.length} ${pathname}`;\n}\n\nexport function captureIdentityHash(memory: MemoryFile): string {\n return createHash(\"sha256\")\n .update(\n buildExplicitCaptureDedupKey(memory.content, memory.frontmatter.category, memory.frontmatter.sourceConnector)\n )\n .digest(\"hex\");\n}\n\nexport type TombstoneBlockedCaptureWriteLockOptions = {\n readonly stateDir: string;\n readonly withHeldFileLock?: typeof withHeldFileLock;\n /** Read when an acquire starts, after the caller has installed converge config. */\n readonly lockOptions?: () => CaptureWriteLockLimitSource | undefined;\n readonly now?: () => number;\n readonly random?: () => number;\n readonly sleep?: (ms: number, signal?: AbortSignal) => Promise<void>;\n readonly logDebug?: (message: string) => void;\n readonly logWarn?: (message: string) => void;\n /** Direct seam. Converge passes the same signal through `lockOptions` instead. */\n readonly signal?: AbortSignal;\n};\n\nexport class TombstoneBlockedCaptureWriteLock {\n private readonly context = new AsyncLocalStorage<ReadonlySet<string>>();\n\n constructor(private readonly options: TombstoneBlockedCaptureWriteLockOptions) {}\n\n private captureWriteLockPathForHash(identityHash: string): string {\n const filename =\n identityHash.length === 0 ? \"explicit-capture-write.lock\" : `explicit-capture-write-${identityHash}.lock`;\n return path.join(this.options.stateDir, \"tombstone-blocked-capture\", filename);\n }\n\n private now(): number {\n return this.options.now?.() ?? Date.now();\n }\n\n private debug(message: string): void {\n if (this.options.logDebug) {\n this.options.logDebug(message);\n return;\n }\n log.debug(message);\n }\n\n private warn(message: string): void {\n if (this.options.logWarn) {\n this.options.logWarn(message);\n return;\n }\n log.warn(message);\n }\n\n /** Prefer the constructor seam; converge installs the signal on lock options at acquire time. */\n private captureAbortSignal(): AbortSignal | undefined {\n return this.options.signal ?? this.options.lockOptions?.()?.captureWriteLockSignal;\n }\n\n /**\n * One probe of a single lock file. Returns the retry symbol when the lock\n * is busy and the permanent symbol on a filesystem error. Does not sleep:\n * the caller backs off only after the whole chain has unwound.\n */\n private async withSingleCaptureWriteLockOnce<T>(\n lockPath: string,\n task: () => Promise<T | typeof CAPTURE_WRITE_LOCK_RETRY>\n ): Promise<T | typeof CAPTURE_WRITE_LOCK_RETRY | typeof CAPTURE_WRITE_LOCK_PERMANENT> {\n await mkdir(path.dirname(lockPath), { recursive: true });\n const runWithHeldFileLock = this.options.withHeldFileLock ?? withHeldFileLock;\n return await runWithHeldFileLock(\n lockPath,\n {\n staleMs: TOMBSTONE_CAPTURE_WRITE_LOCK_STALE_MS,\n maxWaitMs: CAPTURE_WRITE_LOCK_PROBE_MS,\n pollMs: CAPTURE_WRITE_LOCK_PROBE_MS,\n },\n async (acquired, controller) => {\n if (acquired) return await task();\n return controller.failure === \"error\" ? CAPTURE_WRITE_LOCK_PERMANENT : CAPTURE_WRITE_LOCK_RETRY;\n }\n );\n }\n\n private async withPhysicalCaptureWriteLocks<T>(\n task: () => Promise<T>,\n identityHashes: readonly string[]\n ): Promise<T> {\n const signal = this.captureAbortSignal();\n const lockPaths = [...new Set(identityHashes.map((hash) => this.captureWriteLockPathForHash(hash)))];\n const limits = resolveCaptureWriteLockBackoffLimits(this.options.lockOptions?.());\n const deadline = this.now() + limits.deadlineMs;\n const giveUp = (): never => {\n throwIfAborted(signal);\n this.warn(\n `tombstone-blocked capture write lock remained busy after ${limits.deadlineMs}ms; failing this write so the rest of the cycle can continue`\n );\n throw new Error(CAPTURE_WRITE_LOCK_BUSY_MESSAGE);\n };\n const acquire = async (\n index: number\n ): Promise<T | typeof CAPTURE_WRITE_LOCK_RETRY | typeof CAPTURE_WRITE_LOCK_PERMANENT> => {\n throwIfAborted(signal);\n // The deadline gates each probe: a chain that started before the\n // deadline must not keep probing locks (or run the write) after it.\n const runTask = async (): Promise<T> => {\n if (this.now() >= deadline) giveUp();\n return await task();\n };\n if (index === lockPaths.length) return await runTask();\n const lockPath = lockPaths[index];\n if (lockPath === undefined) return await runTask();\n if (this.now() >= deadline) giveUp();\n return await this.withSingleCaptureWriteLockOnce(lockPath, () => acquire(index + 1));\n };\n for (let attempt = 0; ; attempt += 1) {\n throwIfAborted(signal);\n const outcome = await acquire(0);\n if (outcome === CAPTURE_WRITE_LOCK_PERMANENT) {\n throw new Error(\"tombstone-blocked capture write lock acquisition failed\");\n }\n if (outcome !== CAPTURE_WRITE_LOCK_RETRY) return outcome;\n throwIfAborted(signal);\n const now = this.now();\n if (now >= deadline) giveUp();\n const delay = Math.min(\n captureWriteLockDelayMs(attempt, limits, this.options.random ?? Math.random),\n deadline - now\n );\n if (delay <= 0) giveUp();\n this.debug(`tombstone-blocked capture write lock busy; backing off ${delay}ms before retry ${attempt + 1}`);\n // raceAbort covers seam sleeps that ignore the signal; the default\n // sleepAbortable also clears its timer so abort holds no Timeout.\n await raceAbort((this.options.sleep ?? sleepAbortable)(delay, signal), signal);\n }\n }\n\n async withCaptureWriteLock<T>(task: () => Promise<T>, identity?: string | readonly string[]): Promise<T> {\n const identities =\n Array.isArray(identity) && identity.length > 0 ? identity : [typeof identity === \"string\" ? identity : \"\"];\n return await this.withCaptureWriteLocks(task, identities, []);\n }\n\n async withCaptureWriteLockHashes<T>(task: () => Promise<T>, identityHashes: readonly string[]): Promise<T> {\n return await this.withCaptureWriteLocks(task, [], identityHashes);\n }\n\n async withCaptureWriteLockAndHashes<T>(\n task: () => Promise<T>,\n identity: string | readonly string[] | undefined,\n identityHashes: readonly string[]\n ): Promise<T> {\n const identities =\n Array.isArray(identity) && identity.length > 0 ? identity : [typeof identity === \"string\" ? identity : \"\"];\n return await this.withCaptureWriteLocks(task, identities, identityHashes);\n }\n\n private async withCaptureWriteLocks<T>(\n task: () => Promise<T>,\n identities: readonly string[],\n identityHashes: readonly string[]\n ): Promise<T> {\n throwIfAborted(this.captureAbortSignal());\n const current = this.context.getStore();\n const hashToken = (key: string): string =>\n `\\u0000${key.length === 0 ? \"\" : createHash(\"sha256\").update(key).digest(\"hex\")}`;\n const identityHash = (key: string): string =>\n key.length === 0 ? \"\" : createHash(\"sha256\").update(key).digest(\"hex\");\n const identityKeys = [...new Set(identities)];\n const hashes = [...new Set(identityHashes)];\n const requested = [\n ...identityKeys\n .filter((key) => !current || (!current.has(key) && !current.has(hashToken(key))))\n .map((key) => ({ hash: identityHash(key), pathLock: key.startsWith(\"path \") })),\n ...hashes.filter((hash) => !current || !current.has(`\\u0000${hash}`)).map((hash) => ({ hash, pathLock: false })),\n ]\n .filter((entry, index, entries) => entries.findIndex((candidate) => candidate.hash === entry.hash) === index)\n .sort(\n (left, right) =>\n Number(left.pathLock) - Number(right.pathLock) ||\n this.captureWriteLockPathForHash(left.hash).localeCompare(this.captureWriteLockPathForHash(right.hash))\n );\n const physicalMissing = requested.map((entry) => entry.hash);\n if (current && requested.length > 0) {\n const held = [...current]\n .filter((token) => token.startsWith(\"\\u0000\"))\n .map((token) => {\n const hash = token.slice(1);\n const pathLock = [...current].some(\n (key) => !key.startsWith(\"\\u0000\") && key.startsWith(\"path \") && hashToken(key) === token\n );\n return { hash, pathLock };\n });\n const requestedFirst = requested[0];\n const heldLast = held\n .sort(\n (left, right) =>\n Number(left.pathLock) - Number(right.pathLock) ||\n this.captureWriteLockPathForHash(left.hash).localeCompare(this.captureWriteLockPathForHash(right.hash))\n )\n .at(-1);\n if (\n heldLast &&\n requestedFirst &&\n (Number(requestedFirst.pathLock) < Number(heldLast.pathLock) ||\n (requestedFirst.pathLock === heldLast.pathLock &&\n this.captureWriteLockPathForHash(requestedFirst.hash) < this.captureWriteLockPathForHash(heldLast.hash)))\n ) {\n throw new Error(CAPTURE_WRITE_LOCK_BUSY_MESSAGE);\n }\n }\n const next = new Set(current);\n for (const key of identityKeys) {\n next.add(key);\n next.add(hashToken(key));\n }\n for (const hash of hashes) next.add(`\\u0000${hash}`);\n const run = () => {\n throwIfAborted(this.captureAbortSignal());\n return this.context.run(next, task);\n };\n if (physicalMissing.length === 0) return await run();\n return await this.withPhysicalCaptureWriteLocks(run, physicalMissing);\n }\n}\n\nexport type TombstoneBlockedMutationHost = {\n readCurrent: () => Promise<MemoryFile | null>;\n isBlocked: (memory: MemoryFile | null) => boolean;\n isQueuedReview: (memory: MemoryFile | null) => boolean;\n memoryIdentity: (memory: MemoryFile) => string;\n prepareWrite: () => Promise<string>;\n commitWrite: (marker: string) => Promise<void>;\n discardWrite: (marker: string) => Promise<void>;\n markUntrusted: () => void;\n writeStorageSecureFile: (pathname: string, fileContent: string) => Promise<void>;\n withCaptureWriteLock: (task: () => Promise<void>, identity: string | readonly string[]) => Promise<void>;\n logWarning: (message: string) => void;\n beginDurableMemoryRevision?: (\n pathname: string,\n expectedContent?: string | Buffer | null\n ) => Promise<CasRevisionTransaction | undefined>;\n};\n\nexport type TombstoneBlockedMutation = {\n blocked: boolean;\n pathname: string;\n fileContent: string;\n identity: string | readonly string[];\n updateIndex: (rebuildMarker?: string, current?: MemoryFile | null) => Promise<void>;\n beforeIndexUpdate?: () => Promise<void>;\n coordinate?: boolean;\n shouldMintRevision?: (current: MemoryFile | null) => boolean;\n};\n\nexport async function runTombstoneBlockedMutation(\n host: TombstoneBlockedMutationHost,\n mutation: TombstoneBlockedMutation\n): Promise<string | undefined> {\n let lockIdentity: string | readonly string[] = mutation.identity;\n for (;;) {\n let retryIdentity: string | undefined;\n let mintedRevision: string | undefined;\n const mutate = async (): Promise<void> => {\n const current = await host.readCurrent();\n const currentBlocked = host.isBlocked(current);\n const currentQueuedReview = host.isQueuedReview(current);\n if (current !== null && (mutation.coordinate === true || currentBlocked || currentQueuedReview)) {\n const currentIdentity = host.memoryIdentity(current);\n const heldIdentities = Array.isArray(lockIdentity) ? lockIdentity : [lockIdentity];\n if (!heldIdentities.includes(currentIdentity)) {\n retryIdentity = currentIdentity;\n return;\n }\n }\n const rebuildMarker = mutation.blocked || currentBlocked ? await host.prepareWrite() : undefined;\n const discardRebuildMarker = async (): Promise<void> => {\n if (!rebuildMarker) return;\n try {\n await host.discardWrite(rebuildMarker);\n } catch (cleanupError) {\n host.markUntrusted();\n host.logWarning(`storage.tombstoneBlocked failed to clear write marker: ${cleanupError}`);\n }\n };\n let transaction: CasRevisionTransaction | undefined;\n try {\n // #2813 (P1 C): a two-phase receipt transaction under this same\n // path lock. The PENDING reservation is minted BEFORE the durable\n // file publish, so a failed reservation leaves the memory file\n // untouched — never a mutated record without a receipt. The\n // COMMITTED receipt publishes only AFTER the write lands, so a\n // failed write can never leave the reservation posing as\n // ownership.\n transaction = mutation.shouldMintRevision?.(current)\n ? await host.beginDurableMemoryRevision?.(mutation.pathname, mutation.fileContent)\n : undefined;\n await host.writeStorageSecureFile(mutation.pathname, mutation.fileContent);\n } catch (err) {\n // The memory write failed (or never ran): abort the reservation so\n // no pending marker survives a write that did not land. A failed\n // abort keeps the marker — ambiguity, recovered later.\n if (transaction) {\n try {\n await transaction.abort();\n } catch (abortError) {\n host.logWarning(\n `storage.tombstoneBlocked failed to abort the reserved receipt (pending marker preserved): ${abortError}`\n );\n }\n }\n await discardRebuildMarker();\n throw err;\n }\n if (transaction) {\n // #2807: record the post-write fingerprint in the PENDING marker\n // BEFORE publishing, so a crash between the durable write and the\n // COMMITTED receipt is decisively recoverable. The evidence only\n // guards that crash window — a recording failure must not fail the\n // landed write, so commit still runs and publishes truthfully.\n try {\n await transaction.writeLanded();\n } catch (evidenceError) {\n host.logWarning(\n `storage.tombstoneBlocked failed to record receipt crash evidence (pending marker preserved): ${evidenceError}`\n );\n }\n try {\n await transaction.commit();\n } catch (err) {\n // #2813 (P1 C): the memory file LANDED but the COMMITTED receipt\n // never published. The PENDING marker stays: readers must see\n // unavailable/recovery-needed — never ownership, never absence —\n // and promotion/rollback refuse until recovery reconciles. The\n // reservation must NOT be aborted: the write is on disk.\n host.logWarning(\n `storage.tombstoneBlocked receipt publication failed after the memory write (pending marker preserved for recovery): ${err}`\n );\n await discardRebuildMarker();\n throw err;\n }\n }\n mintedRevision = transaction?.pendingRevision;\n if (rebuildMarker) {\n try {\n await host.commitWrite(rebuildMarker);\n } catch (err) {\n host.markUntrusted();\n host.logWarning(`storage.tombstoneBlocked committed write marker failed: ${err}`);\n }\n }\n if (rebuildMarker) await mutation.beforeIndexUpdate?.();\n await mutation.updateIndex(rebuildMarker, currentBlocked && current !== null ? current : undefined);\n };\n\n await host.withCaptureWriteLock(mutate, lockIdentity);\n if (retryIdentity === undefined) return mintedRevision;\n const identities = Array.isArray(lockIdentity) ? [...lockIdentity, retryIdentity] : [lockIdentity, retryIdentity];\n lockIdentity = [...new Set(identities)];\n }\n}\n\nexport function tombstoneBlocked(frontmatter: MemoryFrontmatter): boolean {\n return frontmatter.status === \"pending_review\" && Boolean(frontmatter.blockedBy);\n}\n\nexport function isQueuedReviewFrontmatter(frontmatter: MemoryFrontmatter): boolean {\n return frontmatter.status === \"pending_review\" && (frontmatter.tags ?? []).includes(\"queued-review\");\n}\n\nexport function isQueuedReviewMemory(memory: MemoryFile | null): memory is MemoryFile {\n return memory !== null && isQueuedReviewFrontmatter(memory.frontmatter);\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA,SAAS,yBAAyB;AAClC,SAAS,kBAAkB;AAC3B,SAAS,aAAa;AACtB,OAAO,UAAU;AAgBjB,IAAM,wCAAwC;AAM9C,IAAM,8BAA8B;AACpC,IAAM,2BAA2B,uBAAO,0BAA0B;AAClE,IAAM,+BAA+B,uBAAO,sCAAsC;AAE3E,SAAS,gCAAgC,OAAuB;AACrE,SAAO,MAAM,YAAY,EAAE,QAAQ,QAAQ,GAAG,EAAE,KAAK;AACvD;AAEO,SAAS,6BACd,SACA,UACA,iBACQ;AACR,QAAM,SAAS,CAAC,OAAe,UAA0B,GAAG,KAAK,IAAI,MAAM,MAAM,IAAI,KAAK;AAC1F,SAAO;AAAA,IACL,OAAO,YAAY,QAAQ;AAAA,IAC3B,OAAO,aAAa,iBAAiB,KAAK,KAAK,EAAE;AAAA,IACjD,OAAO,WAAW,gCAAgC,OAAO,CAAC;AAAA,EAC5D,EAAE,KAAK,GAAG;AACZ;AAEO,SAAS,6BAA6B,UAA0B;AACrE,SAAO,QAAQ,SAAS,MAAM,IAAI,QAAQ;AAC5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,MAAS;AAAA,IACpG;AAEA,UAAM,KAAK,qBAAqB,QAAQ,YAAY;AACpD,QAAI,kBAAkB,OAAW,QAAO;AACxC,UAAM,aAAa,MAAM,QAAQ,YAAY,IAAI,CAAC,GAAG,cAAc,aAAa,IAAI,CAAC,cAAc,aAAa;AAChH,mBAAe,CAAC,GAAG,IAAI,IAAI,UAAU,CAAC;AAAA,EACxC;AACF;AAEO,SAAS,iBAAiB,aAAyC;AACxE,SAAO,YAAY,WAAW,oBAAoB,QAAQ,YAAY,SAAS;AACjF;AAEO,SAAS,0BAA0B,aAAyC;AACjF,SAAO,YAAY,WAAW,qBAAqB,YAAY,QAAQ,CAAC,GAAG,SAAS,eAAe;AACrG;AAEO,SAAS,qBAAqB,QAAiD;AACpF,SAAO,WAAW,QAAQ,0BAA0B,OAAO,WAAW;AACxE;","names":[]}
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  getOperation
3
- } from "./chunk-3J5JKBYD.js";
3
+ } from "./chunk-XLBFX63V.js";
4
4
  import {
5
5
  EngramAccessInputError
6
6
  } from "./chunk-3MUKQQ7A.js";
@@ -21,4 +21,4 @@ async function respondBriefingHttp(options) {
21
21
  export {
22
22
  respondBriefingHttp
23
23
  };
24
- //# sourceMappingURL=chunk-5MDM7UE4.js.map
24
+ //# sourceMappingURL=chunk-6WGMZQGG.js.map