@remnic/core 9.69.40 → 9.69.42
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.
- package/dist/access-admin-ops-surface.d.ts +14 -13
- package/dist/access-admin-ops-surface.js +79 -78
- package/dist/access-audit.js +2 -2
- package/dist/access-authorization-probe.d.ts +14 -13
- package/dist/access-authorization-probe.js +80 -79
- package/dist/access-boundary.d.ts +14 -13
- package/dist/access-boundary.js +79 -78
- package/dist/access-cli.js +170 -168
- package/dist/access-cli.js.map +1 -1
- package/dist/access-coding-context-resolution.d.ts +1 -1
- package/dist/access-extraction-force-flush.d.ts +14 -13
- package/dist/access-extraction-force-flush.js +79 -78
- package/dist/access-health-types.d.ts +1 -1
- package/dist/access-http-briefing.d.ts +14 -13
- package/dist/access-http-briefing.js +80 -79
- package/dist/access-http-lcm-compaction.d.ts +14 -13
- package/dist/access-http-lifecycle-flush.d.ts +14 -13
- package/dist/access-http-offline-stream.d.ts +14 -13
- package/dist/access-http-query.d.ts +2 -2
- package/dist/access-http-query.js +81 -80
- package/dist/access-http.d.ts +15 -14
- package/dist/access-http.js +100 -97
- package/dist/access-identity-continuity-surface.d.ts +11 -11
- package/dist/access-identity-continuity-surface.js +79 -78
- package/dist/access-lcm-surface.d.ts +14 -13
- package/dist/access-lcm-surface.js +79 -78
- package/dist/access-mcp-shared-context-tools.d.ts +157 -0
- package/dist/access-mcp-shared-context-tools.js +8 -0
- package/dist/access-mcp.d.ts +14 -13
- package/dist/access-mcp.js +91 -88
- package/dist/access-memory-search-fanout.d.ts +2 -2
- package/dist/{access-namespace-preflight-CKBumJ8W.d.ts → access-namespace-preflight-ShnAJ9uL.d.ts} +1 -1
- package/dist/access-namespace-preflight.d.ts +3 -3
- package/dist/access-namespace-preflight.js +79 -78
- package/dist/access-observe-transcript.d.ts +11 -11
- package/dist/access-observe-write-category.d.ts +17 -1
- package/dist/access-observe-write-category.js +21 -4
- package/dist/access-observe-write-surface.d.ts +14 -13
- package/dist/access-observe-write-surface.js +79 -78
- package/dist/access-offline-manifest.d.ts +11 -11
- package/dist/access-offline-manifest.js +14 -14
- package/dist/access-operations-batch.js +84 -82
- package/dist/access-operations.d.ts +14 -13
- package/dist/access-operations.js +89 -87
- package/dist/access-recall-concurrency.d.ts +14 -13
- package/dist/access-recall-concurrency.js +79 -78
- package/dist/access-recall-response.d.ts +14 -13
- package/dist/access-recall-response.js +79 -78
- package/dist/access-recall-surface.d.ts +14 -13
- package/dist/access-recall-surface.js +79 -78
- package/dist/access-schema.d.ts +117 -114
- package/dist/access-schema.js +3 -3
- package/dist/{access-service-DJ3qogNt.d.ts → access-service-DjG_e2cM.d.ts} +81 -75
- package/dist/access-service-helpers.d.ts +14 -13
- package/dist/access-service.d.ts +14 -13
- package/dist/access-service.js +79 -78
- package/dist/access-surface-catalog.d.ts +14 -13
- package/dist/access-surface-catalog.js +81 -80
- package/dist/access-surface-catalog.js.map +1 -1
- package/dist/access-wearables-meetings-surface.d.ts +4 -4
- package/dist/action-confidence.d.ts +1 -1
- package/dist/active-memory-bridge.d.ts +1 -1
- package/dist/active-memory-bridge.js +3 -3
- package/dist/active-recall.d.ts +1 -1
- package/dist/active-recall.js +10 -10
- package/dist/activity/digest.d.ts +1 -1
- package/dist/ambient-provenance.d.ts +1 -1
- package/dist/artifact-search.d.ts +1 -1
- package/dist/{auto-sync-D6BAPIJV.js → auto-sync-QZD4RD6H.js} +14 -10
- package/dist/{auto-sync-D6BAPIJV.js.map → auto-sync-QZD4RD6H.js.map} +1 -1
- package/dist/background-generation.d.ts +1 -1
- package/dist/behavior-learner.d.ts +1 -1
- package/dist/behavior-signals.d.ts +1 -1
- package/dist/bootstrap.d.ts +11 -11
- package/dist/briefing-window.d.ts +2 -2
- package/dist/briefing.d.ts +2 -2
- package/dist/briefing.js +22 -22
- package/dist/buffer-surprise-report.d.ts +1 -1
- package/dist/buffer-turn-helpers.d.ts +1 -1
- package/dist/buffer.d.ts +2 -2
- package/dist/buffer.js +9 -9
- package/dist/bulk-import/index.d.ts +3 -3
- package/dist/calibration.d.ts +1 -1
- package/dist/calibration.js +2 -2
- package/dist/capabilities.d.ts +1 -1
- package/dist/{capsule-crypto-7FJQINUR.js → capsule-crypto-YO5QJ6L3.js} +2 -2
- package/dist/{capsule-merge-IPG4IOFP.js → capsule-merge-3MNURAQ3.js} +2 -2
- package/dist/{catalog-BHXkBVhg.d.ts → catalog-BhuXaQHx.d.ts} +1 -1
- package/dist/causal-behavior.d.ts +1 -1
- package/dist/causal-consolidation.d.ts +1 -1
- package/dist/causal-consolidation.js +25 -25
- package/dist/causal-trajectory-graph.d.ts +1 -1
- package/dist/{chunk-M6RORUO5.js → chunk-2EYZ32LH.js} +24 -2
- package/dist/{chunk-M6RORUO5.js.map → chunk-2EYZ32LH.js.map} +1 -1
- package/dist/{chunk-JAJIMTFB.js → chunk-2PDMIPMP.js} +9 -9
- package/dist/{chunk-5LYSEZOF.js → chunk-2UINSKQC.js} +12 -11
- package/dist/chunk-2UINSKQC.js.map +1 -0
- package/dist/{chunk-6L2II3KS.js → chunk-3D75XIYO.js} +2 -2
- package/dist/{chunk-XCPNH2MG.js → chunk-3KJTSCSX.js} +5 -5
- package/dist/{chunk-YTZN2UZO.js → chunk-3RLWUW7G.js} +2 -2
- package/dist/{chunk-J272ODKJ.js → chunk-42DJ235G.js} +2 -2
- package/dist/{chunk-NVVZPBKI.js → chunk-46FVFU7S.js} +2 -2
- package/dist/{chunk-JUDT33RX.js → chunk-4AX5OYKC.js} +2 -2
- package/dist/{chunk-GSSDHAYH.js → chunk-4IGOLIWM.js} +2 -2
- package/dist/{chunk-23HFXQ5J.js → chunk-6EGIQEKC.js} +4 -4
- package/dist/{chunk-TVVEYCNW.js → chunk-7K5Q6COX.js} +4 -4
- package/dist/{chunk-GO5LOHCD.js → chunk-7L54ARML.js} +2 -2
- package/dist/{chunk-TEMKBSV6.js → chunk-7PSRCGWT.js} +3 -3
- package/dist/{chunk-ICNJ6J46.js → chunk-AAAFZW3U.js} +2 -2
- package/dist/{chunk-K4JKAXMO.js → chunk-AAX22E4K.js} +3 -3
- package/dist/{chunk-UZ6JYPJ6.js → chunk-ADARR5KF.js} +232 -171
- package/dist/chunk-ADARR5KF.js.map +1 -0
- package/dist/{chunk-KY236SP5.js → chunk-AHHFBJX7.js} +3 -3
- package/dist/{chunk-TZ44E732.js → chunk-AIVRD66I.js} +2 -2
- package/dist/{chunk-OEDW4ER7.js → chunk-AJBWVDRV.js} +2 -1
- package/dist/chunk-AJBWVDRV.js.map +1 -0
- package/dist/{chunk-YRIFXXMI.js → chunk-AOGICQMH.js} +6 -6
- package/dist/{chunk-KOTG3RXE.js → chunk-AUSRUOMQ.js} +2 -2
- package/dist/{chunk-C5R73BON.js → chunk-BIANISES.js} +2 -2
- package/dist/{chunk-IMBQFHRV.js → chunk-BPXJINHW.js} +8 -8
- package/dist/{chunk-2NLLXCJG.js → chunk-BXLOS5AJ.js} +2 -2
- package/dist/{chunk-2J3V5QEO.js → chunk-C3QXITIP.js} +4 -4
- package/dist/{chunk-2SNCQHJZ.js → chunk-CQ4BTPX6.js} +6 -6
- package/dist/{chunk-3QEVOQF5.js → chunk-CTETTVDN.js} +2 -2
- package/dist/{chunk-DFVSJFHK.js → chunk-DBB5JPSL.js} +2 -2
- package/dist/{chunk-W23JARAQ.js → chunk-DLPMOSNH.js} +2 -2
- package/dist/{chunk-BGRTZOJB.js → chunk-DMTSKY4W.js} +8 -8
- package/dist/{chunk-X7Y7WX73.js → chunk-DQEMWVMT.js} +1 -1
- package/dist/{chunk-QS5Q5RBV.js → chunk-E4FRR4MA.js} +8 -8
- package/dist/{chunk-NETQXOPY.js → chunk-EH3HNCAM.js} +12 -7
- package/dist/{chunk-NETQXOPY.js.map → chunk-EH3HNCAM.js.map} +1 -1
- package/dist/{chunk-RJQAP333.js → chunk-ETE3SGAH.js} +2 -2
- package/dist/{chunk-YNDLCWXS.js → chunk-EZ25VE3G.js} +4 -4
- package/dist/{chunk-RLU2Y5GV.js → chunk-F2FJTOV6.js} +4 -4
- package/dist/{chunk-V2ZA4YWE.js → chunk-F5H6YG5P.js} +2 -2
- package/dist/{chunk-K75A5XWU.js → chunk-F6PTJLEM.js} +4 -4
- package/dist/chunk-F6PTJLEM.js.map +1 -0
- package/dist/{chunk-4CMXI55L.js → chunk-FSUFKIFS.js} +2 -2
- package/dist/{chunk-ZAEPD4C2.js → chunk-G3NTZZWT.js} +2 -2
- package/dist/{chunk-ZMWSYUUL.js → chunk-GCBIXUPT.js} +2 -2
- package/dist/{chunk-WZYHPAG5.js → chunk-GIM2AGFL.js} +3 -3
- package/dist/{chunk-VKWFNPBH.js → chunk-GR76OKET.js} +14 -5
- package/dist/{chunk-VKWFNPBH.js.map → chunk-GR76OKET.js.map} +1 -1
- package/dist/{chunk-J7FVMLBR.js → chunk-GWEZNCGA.js} +2 -2
- package/dist/{chunk-LFVZD5EC.js → chunk-GWNSKQDA.js} +3 -3
- package/dist/{chunk-MJC7UKH7.js → chunk-H2N6SLTR.js} +2 -2
- package/dist/{chunk-J4WGTN2N.js → chunk-HK44SV6K.js} +4 -4
- package/dist/{chunk-JDX2OA4R.js → chunk-HNHIHXSD.js} +2 -2
- package/dist/{chunk-IS2IDFJP.js → chunk-HO2P3FAX.js} +22 -22
- package/dist/chunk-HO2P3FAX.js.map +1 -0
- package/dist/{chunk-VQYWKCDR.js → chunk-HPMCKAET.js} +3 -3
- package/dist/{chunk-ROEFLU37.js → chunk-HSJU6JFT.js} +16 -86
- package/dist/chunk-HSJU6JFT.js.map +1 -0
- package/dist/{chunk-MVG3KXON.js → chunk-I65KB36L.js} +25 -25
- package/dist/chunk-IFBSZGW3.js +42 -0
- package/dist/chunk-IFBSZGW3.js.map +1 -0
- package/dist/{chunk-SFHLQPBF.js → chunk-IUTYNDFS.js} +118 -112
- package/dist/chunk-IUTYNDFS.js.map +1 -0
- package/dist/{chunk-AEOOGXMQ.js → chunk-J2MGTGKC.js} +4 -4
- package/dist/chunk-JATHBCAV.js +94 -0
- package/dist/chunk-JATHBCAV.js.map +1 -0
- package/dist/{chunk-PKUJNICO.js → chunk-JC2OBYYD.js} +2 -2
- package/dist/{chunk-5U7K4W6K.js → chunk-JDOBQPJY.js} +3 -3
- package/dist/{chunk-TG3FAM2S.js → chunk-JL4TQYM5.js} +48 -1
- package/dist/{chunk-TG3FAM2S.js.map → chunk-JL4TQYM5.js.map} +1 -1
- package/dist/{chunk-VQWBUPSJ.js → chunk-JMAP6L6Q.js} +2 -2
- package/dist/{chunk-7Z54NXVS.js → chunk-K27INAPR.js} +2 -2
- package/dist/{chunk-YTK5MVNF.js → chunk-KCKXOS4Y.js} +14 -13
- package/dist/chunk-KCKXOS4Y.js.map +1 -0
- package/dist/{chunk-7D6SER6A.js → chunk-KJQ4Y2PY.js} +14 -14
- package/dist/{chunk-DAZANIYU.js → chunk-L732NBPR.js} +87 -88
- package/dist/{chunk-DAZANIYU.js.map → chunk-L732NBPR.js.map} +1 -1
- package/dist/{chunk-QPVNK2VE.js → chunk-LCVYO3ON.js} +2 -2
- package/dist/{chunk-HIP6DKJJ.js → chunk-LQVXSRAJ.js} +2 -2
- package/dist/{chunk-A7GQBJP5.js → chunk-LVFI5LG7.js} +7 -7
- package/dist/{chunk-TO36VPZI.js → chunk-LWF6GOII.js} +2 -2
- package/dist/{chunk-62HFZNCJ.js → chunk-N7B6V7SG.js} +13 -12
- package/dist/{chunk-62HFZNCJ.js.map → chunk-N7B6V7SG.js.map} +1 -1
- package/dist/{chunk-ES5BUPYB.js → chunk-OCWFKD5Q.js} +2 -2
- package/dist/{chunk-IOPIGX7Y.js → chunk-OP722LOG.js} +2 -2
- package/dist/{chunk-62D2PAAM.js → chunk-PAAJWQH5.js} +4 -4
- package/dist/{chunk-V6EGNVUT.js → chunk-PIWFNPQT.js} +4 -4
- package/dist/{chunk-JOP7W24J.js → chunk-PLJ2MQFT.js} +4 -4
- package/dist/{chunk-37CAEC7E.js → chunk-PWPIERBM.js} +4 -4
- package/dist/{chunk-BXIJSPCL.js → chunk-Q62GA5U2.js} +2 -2
- package/dist/{chunk-CC37E3QM.js → chunk-QKCXRS5A.js} +16 -1
- package/dist/chunk-QKCXRS5A.js.map +1 -0
- package/dist/{chunk-I3H5LFOI.js → chunk-QNJQCLI6.js} +4 -4
- package/dist/{chunk-BYQX4IOG.js → chunk-R45VFSEV.js} +2 -2
- package/dist/{chunk-XVDZFTN5.js → chunk-RFIJH2OE.js} +5 -5
- package/dist/{chunk-K4A6UVPB.js → chunk-RJ7Z7YXK.js} +11 -11
- package/dist/{chunk-ZZCR2QYL.js → chunk-RSSLDMFX.js} +2 -2
- package/dist/{chunk-ZZCR2QYL.js.map → chunk-RSSLDMFX.js.map} +1 -1
- package/dist/{chunk-QE6YVNP5.js → chunk-RTXHUVOD.js} +53 -19
- package/dist/chunk-RTXHUVOD.js.map +1 -0
- package/dist/{chunk-HJUP3K6L.js → chunk-RXYO6NA6.js} +2 -2
- package/dist/{chunk-TBXAY2SS.js → chunk-SGHGCFVV.js} +5 -5
- package/dist/{chunk-THTF2W7M.js → chunk-TRTLWUDD.js} +19 -18
- package/dist/chunk-TRTLWUDD.js.map +1 -0
- package/dist/{chunk-2SKMZUOW.js → chunk-U26LB4WA.js} +7 -7
- package/dist/{chunk-6P4REYKL.js → chunk-UDAUULK2.js} +28 -2
- package/dist/{chunk-6P4REYKL.js.map → chunk-UDAUULK2.js.map} +1 -1
- package/dist/{chunk-KTOXQMW3.js → chunk-UHSOPTNB.js} +14 -4
- package/dist/chunk-UHSOPTNB.js.map +1 -0
- package/dist/{chunk-VHKXRYQN.js → chunk-VBK6SRNE.js} +2 -2
- package/dist/{chunk-KQAFEZQX.js → chunk-VDX2J7OX.js} +2 -2
- package/dist/{chunk-Z4GUX2M6.js → chunk-VSN2DMQK.js} +2 -2
- package/dist/{chunk-ZHXSOMYH.js → chunk-VVX5PZFS.js} +2 -2
- package/dist/{chunk-G2XZFGYN.js → chunk-WGZHSQDV.js} +4 -4
- package/dist/{chunk-H3TKENU4.js → chunk-WIKO4SCR.js} +5 -5
- package/dist/{chunk-MDIEES23.js → chunk-WN2OXGGH.js} +1 -1
- package/dist/chunk-WN2OXGGH.js.map +1 -0
- package/dist/{chunk-LKFVVN7R.js → chunk-WNPRRBOE.js} +2 -2
- package/dist/{chunk-SV4Z2S67.js → chunk-WUUGE7QC.js} +54 -21
- package/dist/chunk-WUUGE7QC.js.map +1 -0
- package/dist/{chunk-ZZUVBZL2.js → chunk-X2QPKLPL.js} +2 -2
- package/dist/{chunk-RDLPFM7I.js → chunk-XJLTQTAO.js} +2 -2
- package/dist/{chunk-ZRMMXWYI.js → chunk-YR5QT4SR.js} +32 -9
- package/dist/chunk-YR5QT4SR.js.map +1 -0
- package/dist/{chunk-CARRTDKC.js → chunk-Z22M4JCY.js} +4 -3
- package/dist/chunk-Z22M4JCY.js.map +1 -0
- package/dist/{chunk-XM46Y66S.js → chunk-ZFU6QNRN.js} +7 -7
- package/dist/{chunk-SUEOG2S4.js → chunk-ZGXHTV5Y.js} +2 -2
- package/dist/{chunk-ZX3AYNNV.js → chunk-ZOGKZ2XT.js} +3 -2
- package/dist/chunk-ZOGKZ2XT.js.map +1 -0
- package/dist/{chunk-46Z3VGWF.js → chunk-ZYRAY5FL.js} +3 -3
- package/dist/{chunk-3XPN7AVY.js → chunk-ZYSOT6HD.js} +2 -2
- package/dist/{cli-BWri5-am.d.ts → cli-Cx9s_VRn.d.ts} +5 -5
- package/dist/cli.d.ts +16 -15
- package/dist/cli.js +129 -127
- package/dist/coding/export-okf-codegraph.d.ts +1 -1
- package/dist/coding/export-okf-codegraph.js +22 -22
- package/dist/coding/pre-action-gate.d.ts +1 -1
- package/dist/compounding/engine.d.ts +2 -2
- package/dist/compounding/engine.js +24 -24
- package/dist/compounding/preference-consolidator.d.ts +1 -1
- package/dist/compression-optimizer.d.ts +1 -1
- package/dist/config.d.ts +1 -1
- package/dist/config.js +10 -10
- package/dist/connectors/codex-materialize-runner.d.ts +1 -1
- package/dist/connectors/codex-materialize-runner.js +24 -24
- package/dist/connectors/codex-materialize.d.ts +1 -1
- package/dist/connectors/codex-materialize.js +2 -2
- package/dist/connectors/index.d.ts +1 -1
- package/dist/connectors/index.js +25 -25
- package/dist/consolidation-provenance-check.d.ts +2 -2
- package/dist/consolidation-undo.d.ts +2 -2
- package/dist/contradiction/index.d.ts +4 -4
- package/dist/contradiction/index.js +7 -7
- package/dist/{contradiction-scan-BSGKZHYJ.js → contradiction-scan-GVD4JJ7B.js} +4 -4
- package/dist/converge-config.d.ts +1 -1
- package/dist/convergence-refresh.d.ts +2 -2
- package/dist/convergence-refresh.js +26 -26
- package/dist/conversation-index/backend.d.ts +1 -1
- package/dist/conversation-index/chunker.d.ts +1 -1
- package/dist/conversation-index/faiss-adapter.d.ts +1 -1
- package/dist/conversation-index/indexer.d.ts +1 -1
- package/dist/conversation-index/search.d.ts +1 -1
- package/dist/corpus-watermark.d.ts +1 -1
- package/dist/corpus-watermark.js +25 -25
- package/dist/cross-lingual-recall.d.ts +1 -1
- package/dist/dashboard-runtime.js +2 -2
- package/dist/day-summary.d.ts +1 -1
- package/dist/deep-recall-config.d.ts +12 -1
- package/dist/deep-recall-config.js +5 -3
- package/dist/deep-recall-http-glue.d.ts +17 -14
- package/dist/deep-recall-http-glue.js +7 -4
- package/dist/deep-recall-mcp-tools.d.ts +14 -13
- package/dist/deep-recall-policy-llm.d.ts +12 -2
- package/dist/deep-recall-policy-llm.js +3 -3
- package/dist/deep-recall-seeds.d.ts +4 -1
- package/dist/deep-recall-seeds.js +1 -1
- package/dist/deep-recall.d.ts +12 -1
- package/dist/deep-recall.js +3 -2
- package/dist/delinearize.d.ts +1 -1
- package/dist/dependency-propagation-config.d.ts +1 -1
- package/dist/{dependency-propagation-delivery-ueZlKTQB.d.ts → dependency-propagation-delivery-C2QFQ97b.d.ts} +1 -1
- package/dist/direct-answer-wiring.d.ts +1 -1
- package/dist/direct-answer.d.ts +1 -1
- package/dist/embedding-fallback.d.ts +1 -1
- package/dist/enrichment/index.d.ts +1 -1
- package/dist/entity-origin-fields.d.ts +1 -1
- package/dist/entity-retrieval.d.ts +2 -2
- package/dist/entity-retrieval.js +23 -23
- package/dist/entity-schema.d.ts +1 -1
- package/dist/episodic-context.d.ts +1 -1
- package/dist/eval-trajectory-contracts.d.ts +1 -1
- package/dist/eval-trajectory-store.d.ts +1 -1
- package/dist/eval-trajectory.d.ts +1 -1
- package/dist/explicit-capture.d.ts +11 -11
- package/dist/explicit-capture.js +6 -6
- package/dist/external-wiki-access.d.ts +14 -13
- package/dist/external-wiki-access.js +80 -79
- package/dist/external-wiki-collection-registration.d.ts +1 -1
- package/dist/external-wiki-collection.d.ts +1 -1
- package/dist/external-wiki-mcp-tools.d.ts +14 -13
- package/dist/extraction-error-classification.d.ts +1 -1
- package/dist/extraction-faithfulness.d.ts +2 -2
- package/dist/extraction-faithfulness.js +3 -3
- package/dist/extraction-judge-telemetry.d.ts +2 -2
- package/dist/extraction-judge-training.d.ts +2 -2
- package/dist/extraction-judge.d.ts +2 -2
- package/dist/extraction-judge.js +3 -3
- package/dist/extraction-liveness.d.ts +1 -1
- package/dist/extraction-normalization.d.ts +1 -1
- package/dist/extraction-prompt.d.ts +1 -1
- package/dist/extraction-source-grounding-rules.d.ts +1 -1
- package/dist/extraction-source-grounding.d.ts +1 -1
- package/dist/extraction-span-config.d.ts +1 -1
- package/dist/extraction-span-materialize.d.ts +1 -1
- package/dist/extraction.d.ts +2 -2
- package/dist/extraction.js +38 -38
- package/dist/fallback-llm-codex-subscription.d.ts +15 -5
- package/dist/fallback-llm-codex-subscription.js +3 -1
- package/dist/fallback-llm.d.ts +1 -1
- package/dist/fallback-llm.js +2 -2
- package/dist/{first-start-migration-ZWMV5CX4.js → first-start-migration-L3UFX5CU.js} +4 -4
- package/dist/{generic-recall-paths-CpyVmA88.d.ts → generic-recall-paths-CeKQsQEn.d.ts} +1 -1
- package/dist/graph-append-error.d.ts +1 -1
- package/dist/graph-dashboard-diff.d.ts +1 -1
- package/dist/graph-dashboard-key.d.ts +1 -1
- package/dist/graph-dashboard-parser.d.ts +1 -1
- package/dist/graph-edge-reinforcement.d.ts +1 -1
- package/dist/graph-jsonl.d.ts +1 -1
- package/dist/graph-path-reconstruction.d.ts +1 -1
- package/dist/graph-path-scoring.d.ts +1 -1
- package/dist/graph-snapshot.d.ts +1 -1
- package/dist/graph.d.ts +1 -1
- package/dist/harmonic-retrieval.js +3 -3
- package/dist/importance.d.ts +1 -1
- package/dist/importers/index.d.ts +1 -1
- package/dist/importers/test-utils.d.ts +1 -1
- package/dist/in-flight-reads.d.ts +1 -1
- package/dist/{index-BvUA4S7M.d.ts → index-Bau-Wl0H.d.ts} +3 -3
- package/dist/index.d.ts +703 -702
- package/dist/index.js +331 -327
- package/dist/intent.d.ts +1 -1
- package/dist/lcm/engine.d.ts +1 -1
- package/dist/lcm/engine.js +3 -3
- package/dist/lcm/index.d.ts +1 -1
- package/dist/lcm/index.js +8 -8
- package/dist/lcm/tools.d.ts +1 -1
- package/dist/lifecycle.d.ts +1 -1
- package/dist/live-connectors-runner.d.ts +1 -1
- package/dist/{local-llm-BsJGulur.d.ts → local-llm-Bj-m01Ro.d.ts} +1 -1
- package/dist/local-llm-helpers.d.ts +2 -2
- package/dist/local-llm.d.ts +2 -2
- package/dist/local-llm.js +2 -2
- package/dist/local-model-endpoint.d.ts +1 -1
- package/dist/location/index.d.ts +6 -209
- package/dist/location/index.js +77 -71
- package/dist/maintenance/memory-governance.d.ts +1 -1
- package/dist/maintenance/memory-governance.js +23 -23
- package/dist/maintenance/rebuild-memory-lifecycle-ledger.d.ts +2 -2
- package/dist/maintenance/rebuild-memory-lifecycle-ledger.js +23 -23
- package/dist/maintenance/rebuild-memory-projection.d.ts +2 -2
- package/dist/maintenance/rebuild-memory-projection.js +25 -25
- package/dist/{maintenance-CYubtIRr.d.ts → maintenance-Ye-y-c7f.d.ts} +7 -6
- package/dist/mcp-memory-inspector-app.d.ts +14 -13
- package/dist/memory-action-policy.d.ts +1 -1
- package/dist/memory-cache.d.ts +1 -1
- package/dist/memory-controller.d.ts +1 -1
- package/dist/memory-lifecycle-ledger-utils.d.ts +1 -1
- package/dist/memory-projection-store.d.ts +1 -1
- package/dist/memory-provenance.d.ts +1 -1
- package/dist/memory-snapshot.d.ts +1 -1
- package/dist/memory-subject-cli.d.ts +14 -13
- package/dist/memory-subject.d.ts +14 -13
- package/dist/memory-worth-outcomes.d.ts +2 -2
- package/dist/models-json.d.ts +1 -1
- package/dist/namespaces/migrate.d.ts +3 -3
- package/dist/namespaces/migrate.js +23 -23
- package/dist/namespaces/principal.d.ts +1 -1
- package/dist/namespaces/search.d.ts +1 -1
- package/dist/namespaces/search.js +3 -3
- package/dist/namespaces/storage.d.ts +3 -3
- package/dist/namespaces/storage.js +22 -22
- package/dist/native-knowledge.d.ts +1 -1
- package/dist/offline-sync-impression-drain.d.ts +1 -1
- package/dist/offline-sync-impression-drain.js +5 -5
- package/dist/operator-doctor-corpus.d.ts +1 -1
- package/dist/operator-doctor-corpus.js +26 -26
- package/dist/operator-doctor-replica.d.ts +1 -1
- package/dist/operator-toolkit.d.ts +3 -3
- package/dist/operator-toolkit.js +44 -44
- package/dist/orchestration/compression-guideline-coordinator.d.ts +2 -2
- package/dist/orchestration/maintenance.d.ts +4 -4
- package/dist/orchestration/maintenance.js +39 -39
- package/dist/{orchestrator-BWDRJ_0d.d.ts → orchestrator-fFDDYUUV.d.ts} +20 -10
- package/dist/orchestrator.d.ts +11 -11
- package/dist/orchestrator.js +170 -168
- package/dist/patterns-cli.d.ts +1 -1
- package/dist/{pipeline-7JMn2yMH.d.ts → pipeline-D_j5n_Ih.d.ts} +1 -1
- package/dist/policy-runtime.d.ts +1 -1
- package/dist/proactive-contention.d.ts +2 -2
- package/dist/provenance.d.ts +1 -1
- package/dist/{public-http-CJWs3mo9.d.ts → public-http-CjiSqxUx.d.ts} +1 -1
- package/dist/{qmd-CxCH9G9m.d.ts → qmd-CnxVjKrv.d.ts} +1 -1
- package/dist/qmd-preflight.d.ts +2 -2
- package/dist/qmd-recall-cache.d.ts +1 -1
- package/dist/qmd.d.ts +2 -2
- package/dist/recall-concurrency-config.d.ts +1 -1
- package/dist/recall-disclosure-escalation.d.ts +1 -1
- package/dist/recall-explain-renderer.d.ts +1 -1
- package/dist/recall-explain-renderer.js +3 -3
- package/dist/recall-memory-map.d.ts +1 -1
- package/dist/recall-navigate-access.d.ts +1 -1
- package/dist/recall-navigate-access.js +2 -2
- package/dist/recall-navigate-disclosure.d.ts +1 -1
- package/dist/recall-navigate-disclosure.js +1 -1
- package/dist/recall-navigate.d.ts +1 -1
- package/dist/recall-navigate.js +2 -2
- package/dist/recall-planner-llm.d.ts +1 -1
- package/dist/recall-planner-llm.js +2 -2
- package/dist/recall-state-view-admission.d.ts +2 -2
- package/dist/recall-state-view-admission.js +8 -8
- package/dist/recall-state-view-anchors.d.ts +1 -1
- package/dist/recall-state-view-anchors.js +2 -2
- package/dist/recall-state-view-inject.js +2 -2
- package/dist/recall-state-view-render.js +2 -2
- package/dist/recall-state-view-widen.js +2 -2
- package/dist/recall-state-view-wire.js +3 -3
- package/dist/recall-state-view.d.ts +9 -1
- package/dist/recall-state-view.js +5 -3
- package/dist/recall-state.d.ts +1 -1
- package/dist/recall-tag-filter.d.ts +1 -1
- package/dist/recall-timings.d.ts +1 -1
- package/dist/recall-xray-cli.d.ts +1 -1
- package/dist/recall-xray-cli.js +4 -4
- package/dist/recall-xray-renderer.d.ts +1 -1
- package/dist/recall-xray-renderer.js +3 -3
- package/dist/recall-xray.d.ts +1 -1
- package/dist/recall-xray.js +2 -2
- package/dist/reconcile/cursor.d.ts +1 -1
- package/dist/reconcile/cursor.js +2 -2
- package/dist/reconcile/manifest.d.ts +1 -1
- package/dist/reconcile/manifest.js +4 -4
- package/dist/reconcile/plan.d.ts +1 -1
- package/dist/reconcile/plan.js +2 -2
- package/dist/replay/normalizers/chatgpt.d.ts +1 -1
- package/dist/replay/normalizers/claude.d.ts +1 -1
- package/dist/replay/normalizers/openclaw.d.ts +1 -1
- package/dist/replay/normalizers/shared.d.ts +1 -1
- package/dist/replay/runner.d.ts +1 -1
- package/dist/replay/types.d.ts +1 -1
- package/dist/replica-divergence.d.ts +1 -1
- package/dist/replica-peers-config.d.ts +1 -1
- package/dist/{resolution-4GG3QZRJ.js → resolution-LXFQQ4AE.js} +8 -8
- package/dist/resolution-LXFQQ4AE.js.map +1 -0
- package/dist/resolve-auth-token.d.ts +1 -1
- package/dist/resume-bundles.js +12 -12
- package/dist/retrieval-agents.d.ts +2 -2
- package/dist/retrieval-tiers.d.ts +1 -1
- package/dist/routing/engine.d.ts +1 -1
- package/dist/routing/store.d.ts +1 -1
- package/dist/salvage-envelope.d.ts +1 -1
- package/dist/schemas.d.ts +160 -160
- package/dist/{scope-profiles-BGAUqhBR.d.ts → scope-profiles-BajH5zAT.d.ts} +1 -1
- package/dist/search/embed-helper.d.ts +1 -1
- package/dist/search/factory.d.ts +1 -1
- package/dist/search/factory.js +2 -2
- package/dist/search/index.d.ts +1 -1
- package/dist/search/index.js +4 -4
- package/dist/search/lancedb-backend.d.ts +1 -1
- package/dist/search/meilisearch-backend.d.ts +1 -1
- package/dist/search/noop-backend.d.ts +1 -1
- package/dist/search/orama-backend.d.ts +1 -1
- package/dist/search/port.d.ts +1 -1
- package/dist/search/remote-backend.d.ts +1 -1
- package/dist/{semantic-consolidation-CCeRD9pV.d.ts → semantic-consolidation-Bu6d3O7R.d.ts} +1 -1
- package/dist/semantic-consolidation.d.ts +2 -2
- package/dist/semantic-consolidation.js +25 -25
- package/dist/semantic-rule-promotion.js +22 -22
- package/dist/semantic-rule-verifier.d.ts +1 -1
- package/dist/semantic-rule-verifier.js +22 -22
- package/dist/{service-BwpzRduk.d.ts → service-ChFwWtLS.d.ts} +13 -2
- package/dist/session-observer-bands.d.ts +1 -1
- package/dist/session-observer-state.d.ts +1 -1
- package/dist/shared-context/manager.d.ts +7 -7
- package/dist/shared-context/manager.js +2 -2
- package/dist/shared-context/write-output-controls.d.ts +34 -0
- package/dist/shared-context/write-output-controls.js +10 -0
- package/dist/shared-context/write-output-controls.js.map +1 -0
- package/dist/signal.d.ts +1 -1
- package/dist/source-agent-qualifier.d.ts +1 -1
- package/dist/source-agent-qualifier.js +33 -33
- package/dist/source-attribution.d.ts +23 -1
- package/dist/source-attribution.js +13 -3
- package/dist/standup/build.js +23 -23
- package/dist/{storage-BprAGBG0.d.ts → storage-BDKQdsmB.d.ts} +1 -1
- package/dist/storage.d.ts +2 -2
- package/dist/storage.js +21 -21
- package/dist/subject-config.d.ts +1 -1
- package/dist/subject-config.js +2 -2
- package/dist/summarizer.d.ts +1 -1
- package/dist/summarizer.js +6 -6
- package/dist/summary-snapshot.d.ts +1 -1
- package/dist/support-passport/index.d.ts +17 -16
- package/dist/support-passport/index.js +82 -81
- package/dist/tagging-CwK6um2q.d.ts +240 -0
- package/dist/temporal-supersession.d.ts +2 -2
- package/dist/temporal-timeline-recall.d.ts +1 -1
- package/dist/temporal-validity.d.ts +1 -1
- package/dist/threading.d.ts +1 -1
- package/dist/tier-migration.d.ts +2 -2
- package/dist/tier-routing.d.ts +1 -1
- package/dist/tier-routing.js +3 -3
- package/dist/{tier-stats-LUSUUNU6.js → tier-stats-VK5PCO2L.js} +4 -4
- package/dist/topics.d.ts +1 -1
- package/dist/transcript.d.ts +1 -1
- package/dist/transfer/backup.js +2 -2
- package/dist/transfer/capsule-export.js +2 -2
- package/dist/transfer/capsule-import.js +3 -3
- package/dist/transfer/export-okf.d.ts +1 -1
- package/dist/transfer/export-okf.js +22 -22
- package/dist/transfer/types.d.ts +78 -78
- package/dist/trust-score-stage.d.ts +1 -1
- package/dist/trust-score.d.ts +1 -1
- package/dist/{types-nJV23pa3.d.ts → types-B65IoepH.d.ts} +6 -1
- package/dist/types.d.ts +1 -1
- package/dist/types.js +1 -1
- package/dist/utility-runtime.d.ts +1 -1
- package/dist/verified-recall.js +22 -22
- package/dist/who-knows-cli.d.ts +14 -13
- package/dist/who-knows-cli.js +23 -23
- package/dist/who-knows.d.ts +14 -13
- package/dist/who-knows.js +22 -22
- package/dist/write-envelope.d.ts +1 -1
- package/package.json +12 -2
- package/src/access-http.test.ts +1 -0
- package/src/access-http.ts +1 -1
- package/src/access-mcp-shared-context-tools.ts +103 -0
- package/src/access-mcp.ts +7 -80
- package/src/access-observe-write-category.ts +1 -0
- package/src/access-observe-write-surface.ts +3 -3
- package/src/access-operations-batch.ts +47 -4
- package/src/access-schema.ts +1 -0
- package/src/access-service.ts +18 -12
- package/src/activity/timeline/regenerate.test.ts +48 -0
- package/src/activity/timeline/regenerate.ts +7 -5
- package/src/cli/deep-recall-commands.ts +22 -10
- package/src/config.ts +5 -0
- package/src/dedup/merge.test.ts +283 -0
- package/src/deep-recall-boundary.test.ts +66 -0
- package/src/deep-recall-cli.test.ts +82 -0
- package/src/deep-recall-config.test.ts +56 -0
- package/src/deep-recall-config.ts +32 -0
- package/src/deep-recall-http-glue.ts +10 -10
- package/src/deep-recall-policy-llm.test.ts +242 -0
- package/src/deep-recall-policy-llm.ts +37 -7
- package/src/deep-recall-seeds.test.ts +53 -0
- package/src/deep-recall-seeds.ts +7 -1
- package/src/deep-recall-surface.test.ts +93 -0
- package/src/deep-recall.test.ts +121 -0
- package/src/deep-recall.ts +88 -28
- package/src/fallback-llm-codex-subscription.ts +27 -5
- package/src/fallback-llm.test.ts +120 -0
- package/src/fallback-llm.ts +17 -16
- package/src/location/phase5-wiring.test.ts +408 -0
- package/src/location/tagging.ts +58 -0
- package/src/meetings/config.test.ts +58 -0
- package/src/orchestration/extraction-persist.ts +1 -1
- package/src/orchestration/orchestrator-helpers.ts +2 -0
- package/src/orchestration/recall-entry.ts +15 -1
- package/src/orchestration/recall-internal.ts +1 -0
- package/src/orchestration/recall-section-coordinator.ts +65 -28
- package/src/orchestration/recall-state-view-pipeline.test.ts +8 -2
- package/src/orchestration/semantic-merge-commit-effects.ts +45 -16
- package/src/orchestration/semantic-merge-persist.ts +23 -36
- package/src/orchestration/workspace-ops.ts +14 -0
- package/src/providers/codex-subscription.test.ts +127 -0
- package/src/providers/codex-subscription.ts +1 -1
- package/src/recall-state-view-budget.test.ts +424 -0
- package/src/recall-state-view.ts +30 -16
- package/src/shared-context/envelope-io.ts +25 -0
- package/src/shared-context/envelope-wiring.test.ts +4 -2
- package/src/shared-context/manager.ts +1 -0
- package/src/shared-context/write-output-controls.test.ts +192 -0
- package/src/shared-context/write-output-controls.ts +72 -0
- package/src/source-attribution.test.ts +39 -0
- package/src/source-attribution.ts +72 -0
- package/src/types.ts +5 -0
- package/src/wearables/pipeline.ts +19 -0
- package/src/wearables/service.ts +8 -0
- package/dist/chunk-5LYSEZOF.js.map +0 -1
- package/dist/chunk-CARRTDKC.js.map +0 -1
- package/dist/chunk-CC37E3QM.js.map +0 -1
- package/dist/chunk-IS2IDFJP.js.map +0 -1
- package/dist/chunk-K75A5XWU.js.map +0 -1
- package/dist/chunk-KTOXQMW3.js.map +0 -1
- package/dist/chunk-MDIEES23.js.map +0 -1
- package/dist/chunk-OEDW4ER7.js.map +0 -1
- package/dist/chunk-QE6YVNP5.js.map +0 -1
- package/dist/chunk-ROEFLU37.js.map +0 -1
- package/dist/chunk-SFHLQPBF.js.map +0 -1
- package/dist/chunk-SV4Z2S67.js.map +0 -1
- package/dist/chunk-THTF2W7M.js.map +0 -1
- package/dist/chunk-UZ6JYPJ6.js.map +0 -1
- package/dist/chunk-YTK5MVNF.js.map +0 -1
- package/dist/chunk-ZRMMXWYI.js.map +0 -1
- package/dist/chunk-ZX3AYNNV.js.map +0 -1
- /package/dist/{capsule-crypto-7FJQINUR.js.map → access-mcp-shared-context-tools.js.map} +0 -0
- /package/dist/{contradiction-scan-BSGKZHYJ.js.map → capsule-crypto-YO5QJ6L3.js.map} +0 -0
- /package/dist/{capsule-merge-IPG4IOFP.js.map → capsule-merge-3MNURAQ3.js.map} +0 -0
- /package/dist/{chunk-JAJIMTFB.js.map → chunk-2PDMIPMP.js.map} +0 -0
- /package/dist/{chunk-6L2II3KS.js.map → chunk-3D75XIYO.js.map} +0 -0
- /package/dist/{chunk-XCPNH2MG.js.map → chunk-3KJTSCSX.js.map} +0 -0
- /package/dist/{chunk-YTZN2UZO.js.map → chunk-3RLWUW7G.js.map} +0 -0
- /package/dist/{chunk-J272ODKJ.js.map → chunk-42DJ235G.js.map} +0 -0
- /package/dist/{chunk-NVVZPBKI.js.map → chunk-46FVFU7S.js.map} +0 -0
- /package/dist/{chunk-JUDT33RX.js.map → chunk-4AX5OYKC.js.map} +0 -0
- /package/dist/{chunk-GSSDHAYH.js.map → chunk-4IGOLIWM.js.map} +0 -0
- /package/dist/{chunk-23HFXQ5J.js.map → chunk-6EGIQEKC.js.map} +0 -0
- /package/dist/{chunk-TVVEYCNW.js.map → chunk-7K5Q6COX.js.map} +0 -0
- /package/dist/{chunk-GO5LOHCD.js.map → chunk-7L54ARML.js.map} +0 -0
- /package/dist/{chunk-TEMKBSV6.js.map → chunk-7PSRCGWT.js.map} +0 -0
- /package/dist/{chunk-ICNJ6J46.js.map → chunk-AAAFZW3U.js.map} +0 -0
- /package/dist/{chunk-K4JKAXMO.js.map → chunk-AAX22E4K.js.map} +0 -0
- /package/dist/{chunk-KY236SP5.js.map → chunk-AHHFBJX7.js.map} +0 -0
- /package/dist/{chunk-TZ44E732.js.map → chunk-AIVRD66I.js.map} +0 -0
- /package/dist/{chunk-YRIFXXMI.js.map → chunk-AOGICQMH.js.map} +0 -0
- /package/dist/{chunk-KOTG3RXE.js.map → chunk-AUSRUOMQ.js.map} +0 -0
- /package/dist/{chunk-C5R73BON.js.map → chunk-BIANISES.js.map} +0 -0
- /package/dist/{chunk-IMBQFHRV.js.map → chunk-BPXJINHW.js.map} +0 -0
- /package/dist/{chunk-2NLLXCJG.js.map → chunk-BXLOS5AJ.js.map} +0 -0
- /package/dist/{chunk-2J3V5QEO.js.map → chunk-C3QXITIP.js.map} +0 -0
- /package/dist/{chunk-2SNCQHJZ.js.map → chunk-CQ4BTPX6.js.map} +0 -0
- /package/dist/{chunk-3QEVOQF5.js.map → chunk-CTETTVDN.js.map} +0 -0
- /package/dist/{chunk-DFVSJFHK.js.map → chunk-DBB5JPSL.js.map} +0 -0
- /package/dist/{chunk-W23JARAQ.js.map → chunk-DLPMOSNH.js.map} +0 -0
- /package/dist/{chunk-BGRTZOJB.js.map → chunk-DMTSKY4W.js.map} +0 -0
- /package/dist/{chunk-X7Y7WX73.js.map → chunk-DQEMWVMT.js.map} +0 -0
- /package/dist/{chunk-QS5Q5RBV.js.map → chunk-E4FRR4MA.js.map} +0 -0
- /package/dist/{chunk-RJQAP333.js.map → chunk-ETE3SGAH.js.map} +0 -0
- /package/dist/{chunk-YNDLCWXS.js.map → chunk-EZ25VE3G.js.map} +0 -0
- /package/dist/{chunk-RLU2Y5GV.js.map → chunk-F2FJTOV6.js.map} +0 -0
- /package/dist/{chunk-V2ZA4YWE.js.map → chunk-F5H6YG5P.js.map} +0 -0
- /package/dist/{chunk-4CMXI55L.js.map → chunk-FSUFKIFS.js.map} +0 -0
- /package/dist/{chunk-ZAEPD4C2.js.map → chunk-G3NTZZWT.js.map} +0 -0
- /package/dist/{chunk-ZMWSYUUL.js.map → chunk-GCBIXUPT.js.map} +0 -0
- /package/dist/{chunk-WZYHPAG5.js.map → chunk-GIM2AGFL.js.map} +0 -0
- /package/dist/{chunk-J7FVMLBR.js.map → chunk-GWEZNCGA.js.map} +0 -0
- /package/dist/{chunk-LFVZD5EC.js.map → chunk-GWNSKQDA.js.map} +0 -0
- /package/dist/{chunk-MJC7UKH7.js.map → chunk-H2N6SLTR.js.map} +0 -0
- /package/dist/{chunk-J4WGTN2N.js.map → chunk-HK44SV6K.js.map} +0 -0
- /package/dist/{chunk-JDX2OA4R.js.map → chunk-HNHIHXSD.js.map} +0 -0
- /package/dist/{chunk-VQYWKCDR.js.map → chunk-HPMCKAET.js.map} +0 -0
- /package/dist/{chunk-MVG3KXON.js.map → chunk-I65KB36L.js.map} +0 -0
- /package/dist/{chunk-AEOOGXMQ.js.map → chunk-J2MGTGKC.js.map} +0 -0
- /package/dist/{chunk-PKUJNICO.js.map → chunk-JC2OBYYD.js.map} +0 -0
- /package/dist/{chunk-5U7K4W6K.js.map → chunk-JDOBQPJY.js.map} +0 -0
- /package/dist/{chunk-VQWBUPSJ.js.map → chunk-JMAP6L6Q.js.map} +0 -0
- /package/dist/{chunk-7Z54NXVS.js.map → chunk-K27INAPR.js.map} +0 -0
- /package/dist/{chunk-7D6SER6A.js.map → chunk-KJQ4Y2PY.js.map} +0 -0
- /package/dist/{chunk-QPVNK2VE.js.map → chunk-LCVYO3ON.js.map} +0 -0
- /package/dist/{chunk-HIP6DKJJ.js.map → chunk-LQVXSRAJ.js.map} +0 -0
- /package/dist/{chunk-A7GQBJP5.js.map → chunk-LVFI5LG7.js.map} +0 -0
- /package/dist/{chunk-TO36VPZI.js.map → chunk-LWF6GOII.js.map} +0 -0
- /package/dist/{chunk-ES5BUPYB.js.map → chunk-OCWFKD5Q.js.map} +0 -0
- /package/dist/{chunk-IOPIGX7Y.js.map → chunk-OP722LOG.js.map} +0 -0
- /package/dist/{chunk-62D2PAAM.js.map → chunk-PAAJWQH5.js.map} +0 -0
- /package/dist/{chunk-V6EGNVUT.js.map → chunk-PIWFNPQT.js.map} +0 -0
- /package/dist/{chunk-JOP7W24J.js.map → chunk-PLJ2MQFT.js.map} +0 -0
- /package/dist/{chunk-37CAEC7E.js.map → chunk-PWPIERBM.js.map} +0 -0
- /package/dist/{chunk-BXIJSPCL.js.map → chunk-Q62GA5U2.js.map} +0 -0
- /package/dist/{chunk-I3H5LFOI.js.map → chunk-QNJQCLI6.js.map} +0 -0
- /package/dist/{chunk-BYQX4IOG.js.map → chunk-R45VFSEV.js.map} +0 -0
- /package/dist/{chunk-XVDZFTN5.js.map → chunk-RFIJH2OE.js.map} +0 -0
- /package/dist/{chunk-K4A6UVPB.js.map → chunk-RJ7Z7YXK.js.map} +0 -0
- /package/dist/{chunk-HJUP3K6L.js.map → chunk-RXYO6NA6.js.map} +0 -0
- /package/dist/{chunk-TBXAY2SS.js.map → chunk-SGHGCFVV.js.map} +0 -0
- /package/dist/{chunk-2SKMZUOW.js.map → chunk-U26LB4WA.js.map} +0 -0
- /package/dist/{chunk-VHKXRYQN.js.map → chunk-VBK6SRNE.js.map} +0 -0
- /package/dist/{chunk-KQAFEZQX.js.map → chunk-VDX2J7OX.js.map} +0 -0
- /package/dist/{chunk-Z4GUX2M6.js.map → chunk-VSN2DMQK.js.map} +0 -0
- /package/dist/{chunk-ZHXSOMYH.js.map → chunk-VVX5PZFS.js.map} +0 -0
- /package/dist/{chunk-G2XZFGYN.js.map → chunk-WGZHSQDV.js.map} +0 -0
- /package/dist/{chunk-H3TKENU4.js.map → chunk-WIKO4SCR.js.map} +0 -0
- /package/dist/{chunk-LKFVVN7R.js.map → chunk-WNPRRBOE.js.map} +0 -0
- /package/dist/{chunk-ZZUVBZL2.js.map → chunk-X2QPKLPL.js.map} +0 -0
- /package/dist/{chunk-RDLPFM7I.js.map → chunk-XJLTQTAO.js.map} +0 -0
- /package/dist/{chunk-XM46Y66S.js.map → chunk-ZFU6QNRN.js.map} +0 -0
- /package/dist/{chunk-SUEOG2S4.js.map → chunk-ZGXHTV5Y.js.map} +0 -0
- /package/dist/{chunk-46Z3VGWF.js.map → chunk-ZYRAY5FL.js.map} +0 -0
- /package/dist/{chunk-3XPN7AVY.js.map → chunk-ZYSOT6HD.js.map} +0 -0
- /package/dist/{resolution-4GG3QZRJ.js.map → contradiction-scan-GVD4JJ7B.js.map} +0 -0
- /package/dist/{first-start-migration-ZWMV5CX4.js.map → first-start-migration-L3UFX5CU.js.map} +0 -0
- /package/dist/{tier-stats-LUSUUNU6.js.map → tier-stats-VK5PCO2L.js.map} +0 -0
|
@@ -0,0 +1,192 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Regression: governed write-output envelope controls exposed on BOTH
|
|
3
|
+
* documented surfaces (issue #2920).
|
|
4
|
+
*
|
|
5
|
+
* Covers the canonical client-input parse, the Access MCP operation
|
|
6
|
+
* (`shared_context_write_output` via the real operation registry), and the
|
|
7
|
+
* access-service adapter against the REAL manager write path:
|
|
8
|
+
* - authority: finite allow-list, binding gated by config
|
|
9
|
+
* - expiresAt: strict ISO, strictly future, bounded by the 10-year TTL
|
|
10
|
+
* - supersedes: validated id shape
|
|
11
|
+
* - client `principal`/`namespace` overrides are rejected
|
|
12
|
+
* - no idempotent replay/dedup semantics on this surface (two identical
|
|
13
|
+
* calls write two files — nothing silently swallows a re-send)
|
|
14
|
+
*
|
|
15
|
+
* All fixtures are synthetic — no real user data.
|
|
16
|
+
*/
|
|
17
|
+
|
|
18
|
+
import assert from "node:assert/strict";
|
|
19
|
+
import test from "node:test";
|
|
20
|
+
import os from "node:os";
|
|
21
|
+
import path from "node:path";
|
|
22
|
+
import { mkdtemp, readFile, rm } from "node:fs/promises";
|
|
23
|
+
|
|
24
|
+
import "../access-operations.js";
|
|
25
|
+
import { getOperation } from "../access-boundary.js";
|
|
26
|
+
import { EngramAccessInputError, EngramAccessService, type EngramAccessService as Service } from "../access-service.js";
|
|
27
|
+
import type { Orchestrator } from "../orchestrator.js";
|
|
28
|
+
import { SharedContextManager } from "./manager.js";
|
|
29
|
+
import { MAX_WRITE_EXPIRES_AT_TTL_MS } from "./envelope-io.js";
|
|
30
|
+
import { parseSharedWriteOutputControls } from "./write-output-controls.js";
|
|
31
|
+
import { parseConfig } from "../config.js";
|
|
32
|
+
|
|
33
|
+
const DAY_MS = 24 * 60 * 60 * 1000;
|
|
34
|
+
|
|
35
|
+
async function makeService(overrides: Record<string, unknown> = {}) {
|
|
36
|
+
const dir = await mkdtemp(path.join(os.tmpdir(), "remnic-shared-controls-"));
|
|
37
|
+
const config = parseConfig({ sharedContextEnabled: true, sharedContextDir: dir, memoryDir: dir, ...overrides });
|
|
38
|
+
const manager = new SharedContextManager(config);
|
|
39
|
+
await manager.ensureStructure();
|
|
40
|
+
const service = new EngramAccessService({ config, sharedContext: manager } as unknown as Orchestrator);
|
|
41
|
+
return { service, manager, dir, config };
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
test("parse: controls are strings-or-absent; empty or non-string values reject", () => {
|
|
45
|
+
assert.deepEqual(parseSharedWriteOutputControls({}), {});
|
|
46
|
+
assert.deepEqual(parseSharedWriteOutputControls(undefined), {});
|
|
47
|
+
assert.deepEqual(parseSharedWriteOutputControls(null), {});
|
|
48
|
+
assert.deepEqual(
|
|
49
|
+
parseSharedWriteOutputControls({ authority: "advisory", expiresAt: "2030-01-01T00:00:00Z", supersedes: "out-1" }),
|
|
50
|
+
{ authority: "advisory", expiresAt: "2030-01-01T00:00:00Z", supersedes: "out-1" },
|
|
51
|
+
);
|
|
52
|
+
assert.throws(() => parseSharedWriteOutputControls({ authority: 7 }), /authority must be a string/);
|
|
53
|
+
assert.throws(() => parseSharedWriteOutputControls({ expiresAt: "" }), /expiresAt must be a non-empty string/);
|
|
54
|
+
assert.throws(() => parseSharedWriteOutputControls({ supersedes: " " }), /supersedes must be a non-empty string/);
|
|
55
|
+
});
|
|
56
|
+
|
|
57
|
+
test("parse: client principal/namespace overrides are rejected", () => {
|
|
58
|
+
assert.throws(
|
|
59
|
+
() => parseSharedWriteOutputControls({ principal: "attacker" }),
|
|
60
|
+
/principal is server-resolved and cannot be supplied by the caller/,
|
|
61
|
+
);
|
|
62
|
+
assert.throws(
|
|
63
|
+
() => parseSharedWriteOutputControls({ namespace: "victim-ns" }),
|
|
64
|
+
/namespace is server-resolved and cannot be supplied by the caller/,
|
|
65
|
+
);
|
|
66
|
+
// Absent keys (and stripped nulls) pass through untouched.
|
|
67
|
+
assert.deepEqual(parseSharedWriteOutputControls({ sessionKey: "ctx" }), {});
|
|
68
|
+
});
|
|
69
|
+
|
|
70
|
+
test("operation: forwards the envelope controls with the authenticated principal", async () => {
|
|
71
|
+
let received: Record<string, unknown> | undefined;
|
|
72
|
+
const service = {
|
|
73
|
+
sharedContextWriteOutput: async (request: Record<string, unknown>) => {
|
|
74
|
+
received = request;
|
|
75
|
+
return { written: true, path: "written.md" };
|
|
76
|
+
},
|
|
77
|
+
} as unknown as Service;
|
|
78
|
+
const operation = getOperation("shared_context_write_output");
|
|
79
|
+
assert.ok(operation);
|
|
80
|
+
|
|
81
|
+
await operation.run(
|
|
82
|
+
{ agentId: "agent", title: "t", content: "c", authority: "advisory", expiresAt: "2030-01-01T00:00:00Z", supersedes: "out-1" },
|
|
83
|
+
{ service, authenticatedPrincipal: "real-principal" },
|
|
84
|
+
);
|
|
85
|
+
assert.equal(received?.authority, "advisory");
|
|
86
|
+
assert.equal(received?.expiresAt, "2030-01-01T00:00:00Z");
|
|
87
|
+
assert.equal(received?.supersedes, "out-1");
|
|
88
|
+
assert.equal(received?.principal, "real-principal");
|
|
89
|
+
});
|
|
90
|
+
|
|
91
|
+
test("operation: client principal/namespace and malformed controls are input errors", async () => {
|
|
92
|
+
const service = {
|
|
93
|
+
sharedContextWriteOutput: async () => ({ written: true, path: "x" }),
|
|
94
|
+
} as unknown as Service;
|
|
95
|
+
const operation = getOperation("shared_context_write_output");
|
|
96
|
+
assert.ok(operation);
|
|
97
|
+
|
|
98
|
+
for (const payload of [
|
|
99
|
+
{ agentId: "a", title: "t", content: "c", principal: "spoofed" },
|
|
100
|
+
{ agentId: "a", title: "t", content: "c", namespace: "other" },
|
|
101
|
+
{ agentId: "a", title: "t", content: "c", authority: "" },
|
|
102
|
+
{ agentId: "a", title: "t", content: "c", expiresAt: 42 },
|
|
103
|
+
]) {
|
|
104
|
+
await assert.rejects(
|
|
105
|
+
() => operation.run(payload, { service, authenticatedPrincipal: "real-principal" }),
|
|
106
|
+
(error: unknown) => error instanceof EngramAccessInputError,
|
|
107
|
+
`must reject ${JSON.stringify(payload)}`,
|
|
108
|
+
);
|
|
109
|
+
}
|
|
110
|
+
});
|
|
111
|
+
|
|
112
|
+
test("service: controls stamp the envelope; absent controls stay informational", async (t) => {
|
|
113
|
+
const { service, dir } = await makeService();
|
|
114
|
+
t.after(() => rm(dir, { recursive: true, force: true }));
|
|
115
|
+
|
|
116
|
+
const expiresAt = new Date(Date.now() + 90 * DAY_MS).toISOString();
|
|
117
|
+
const result = (await service.sharedContextWriteOutput({
|
|
118
|
+
agentId: "agent-alpha",
|
|
119
|
+
title: "Plan",
|
|
120
|
+
content: "x",
|
|
121
|
+
authority: "advisory",
|
|
122
|
+
expiresAt,
|
|
123
|
+
supersedes: "out-0001",
|
|
124
|
+
})) as { written: boolean; path: string };
|
|
125
|
+
const raw = await readFile(result.path, "utf-8");
|
|
126
|
+
assert.match(raw, /^authority: "advisory"$/m);
|
|
127
|
+
assert.ok(raw.includes(`expiresAt: ${JSON.stringify(expiresAt)}`));
|
|
128
|
+
assert.match(raw, /^supersedes: "out-0001"$/m);
|
|
129
|
+
|
|
130
|
+
const plain = (await service.sharedContextWriteOutput({ agentId: "agent-alpha", title: "Plain", content: "x" })) as {
|
|
131
|
+
written: boolean;
|
|
132
|
+
path: string;
|
|
133
|
+
};
|
|
134
|
+
const plainRaw = await readFile(plain.path, "utf-8");
|
|
135
|
+
assert.match(plainRaw, /^authority: "informational"$/m);
|
|
136
|
+
});
|
|
137
|
+
|
|
138
|
+
test("service: binding requires the operator opt-in, else is a client input error", async (t) => {
|
|
139
|
+
const gated = await makeService();
|
|
140
|
+
t.after(() => rm(gated.dir, { recursive: true, force: true }));
|
|
141
|
+
await assert.rejects(
|
|
142
|
+
() =>
|
|
143
|
+
gated.service.sharedContextWriteOutput({ agentId: "agent-alpha", title: "Directive", content: "x", authority: "binding" }),
|
|
144
|
+
(error: unknown) => error instanceof EngramAccessInputError && /requires an explicit binding flag/.test(error.message),
|
|
145
|
+
);
|
|
146
|
+
|
|
147
|
+
const open = await makeService({ sharedContextAllowBindingAuthority: true });
|
|
148
|
+
t.after(() => rm(open.dir, { recursive: true, force: true }));
|
|
149
|
+
const result = (await open.service.sharedContextWriteOutput({
|
|
150
|
+
agentId: "agent-alpha",
|
|
151
|
+
title: "Directive",
|
|
152
|
+
content: "x",
|
|
153
|
+
authority: "binding",
|
|
154
|
+
})) as { path: string };
|
|
155
|
+
assert.match(await readFile(result.path, "utf-8"), /^authority: "binding"$/m);
|
|
156
|
+
});
|
|
157
|
+
|
|
158
|
+
test("service: expiresAt must be strictly future and within the 10-year TTL", async (t) => {
|
|
159
|
+
const { service, dir } = await makeService();
|
|
160
|
+
t.after(() => rm(dir, { recursive: true, force: true }));
|
|
161
|
+
|
|
162
|
+
const cases: Array<{ expiresAt: string; message: string }> = [
|
|
163
|
+
{ expiresAt: new Date(Date.now() - DAY_MS).toISOString(), message: "strictly after the write time" },
|
|
164
|
+
{ expiresAt: new Date(Date.now() + MAX_WRITE_EXPIRES_AT_TTL_MS + DAY_MS).toISOString(), message: "maximum TTL" },
|
|
165
|
+
{ expiresAt: "2030-02-31T00:00:00Z", message: "valid ISO-8601 timestamp" },
|
|
166
|
+
];
|
|
167
|
+
for (const { expiresAt, message } of cases) {
|
|
168
|
+
await assert.rejects(
|
|
169
|
+
() => service.sharedContextWriteOutput({ agentId: "agent-alpha", title: "Expiry", content: "x", expiresAt }),
|
|
170
|
+
(error: unknown) => error instanceof EngramAccessInputError && error.message.includes(message),
|
|
171
|
+
`must reject expiresAt=${expiresAt}`,
|
|
172
|
+
);
|
|
173
|
+
}
|
|
174
|
+
});
|
|
175
|
+
|
|
176
|
+
test("service: supersedes must be a non-blank single-line id", async (t) => {
|
|
177
|
+
const { service, dir } = await makeService();
|
|
178
|
+
t.after(() => rm(dir, { recursive: true, force: true }));
|
|
179
|
+
await assert.rejects(
|
|
180
|
+
() => service.sharedContextWriteOutput({ agentId: "agent-alpha", title: "Supersede", content: "x", supersedes: "out-1\nout-2" }),
|
|
181
|
+
(error: unknown) => error instanceof EngramAccessInputError && /supersedes/.test(error.message),
|
|
182
|
+
);
|
|
183
|
+
});
|
|
184
|
+
|
|
185
|
+
test("service: no idempotent replay — an identical re-send writes a second file", async (t) => {
|
|
186
|
+
const { service, dir } = await makeService();
|
|
187
|
+
t.after(() => rm(dir, { recursive: true, force: true }));
|
|
188
|
+
const base = { agentId: "agent-alpha", title: "Same", content: "same bytes" };
|
|
189
|
+
const first = (await service.sharedContextWriteOutput(base)) as { path: string };
|
|
190
|
+
const second = (await service.sharedContextWriteOutput(base)) as { path: string };
|
|
191
|
+
assert.notEqual(first.path, second.path, "this surface has no replay/dedup semantics; a re-send must not be swallowed");
|
|
192
|
+
});
|
|
@@ -0,0 +1,72 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Canonical client-input parse for shared-context write-output envelope
|
|
3
|
+
* controls (issue #2920).
|
|
4
|
+
*
|
|
5
|
+
* One module feeds BOTH documented surfaces — the Access MCP
|
|
6
|
+
* `shared_context_write_output` operation and the OpenClaw
|
|
7
|
+
* `shared_context_write_output` tool — so surface policy can never drift.
|
|
8
|
+
* This layer owns only what is a SURFACE concern: field type/shape and the
|
|
9
|
+
* rejection of client-supplied identity. Semantic validation (authority
|
|
10
|
+
* allow-list, the binding gate, strict ISO instants, the future/TTL expiry
|
|
11
|
+
* policy, id shape) stays in `composeWriteEnvelope`, the single write-side
|
|
12
|
+
* gate every path already routes through — there is no in-process bypass
|
|
13
|
+
* with looser rules than the tool surfaces.
|
|
14
|
+
*/
|
|
15
|
+
|
|
16
|
+
export interface SharedWriteOutputControls {
|
|
17
|
+
authority?: string;
|
|
18
|
+
expiresAt?: string;
|
|
19
|
+
supersedes?: string;
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
const CONTROL_FIELDS = ["authority", "expiresAt", "supersedes"] as const;
|
|
23
|
+
|
|
24
|
+
/** Server-resolved fields a caller must never supply (issue #2920). */
|
|
25
|
+
const SERVER_RESOLVED_FIELDS = ["principal", "namespace"] as const;
|
|
26
|
+
|
|
27
|
+
/**
|
|
28
|
+
* Parse the optional envelope controls off a raw client request.
|
|
29
|
+
*
|
|
30
|
+
* - Absent fields are omitted; a control must be a non-blank string when
|
|
31
|
+
* present (an explicit empty string is a client error, not "unspecified").
|
|
32
|
+
* - A client-supplied `principal` or `namespace` is rejected: identity and
|
|
33
|
+
* scoping are resolved by the surface, never accepted from the caller.
|
|
34
|
+
*
|
|
35
|
+
* Throws `Error` with a `shared-context write output:` prefix; access
|
|
36
|
+
* surfaces map that to their input-error class.
|
|
37
|
+
*/
|
|
38
|
+
export function parseSharedWriteOutputControls(raw: unknown): SharedWriteOutputControls {
|
|
39
|
+
if (raw === null || typeof raw !== "object" || Array.isArray(raw)) return {};
|
|
40
|
+
const record = raw as Record<string, unknown>;
|
|
41
|
+
for (const field of SERVER_RESOLVED_FIELDS) {
|
|
42
|
+
if (Object.hasOwn(record, field) && record[field] !== undefined) {
|
|
43
|
+
throw new Error(
|
|
44
|
+
`shared-context write output: ${field} is server-resolved and cannot be supplied by the caller`,
|
|
45
|
+
);
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
const controls: SharedWriteOutputControls = {};
|
|
49
|
+
for (const field of CONTROL_FIELDS) {
|
|
50
|
+
const value = record[field];
|
|
51
|
+
if (value === undefined) continue;
|
|
52
|
+
if (typeof value !== "string") {
|
|
53
|
+
throw new Error(`shared-context write output: ${field} must be a string`);
|
|
54
|
+
}
|
|
55
|
+
if (value.trim().length === 0) {
|
|
56
|
+
throw new Error(`shared-context write output: ${field} must be a non-empty string`);
|
|
57
|
+
}
|
|
58
|
+
controls[field] = value;
|
|
59
|
+
}
|
|
60
|
+
return controls;
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
const WRITE_INPUT_PREFIXES = [
|
|
64
|
+
"shared-context write origin mismatch",
|
|
65
|
+
"applyDefaultEnvelope:",
|
|
66
|
+
"composeWriteEnvelope:",
|
|
67
|
+
"shared-context write output:",
|
|
68
|
+
] as const;
|
|
69
|
+
|
|
70
|
+
export function isSharedContextWriteInputError(message: string): boolean {
|
|
71
|
+
return WRITE_INPUT_PREFIXES.some((prefix) => message.startsWith(prefix));
|
|
72
|
+
}
|
|
@@ -9,6 +9,9 @@ import { ContentHashIndex, StorageManager } from "./storage.js";
|
|
|
9
9
|
import {
|
|
10
10
|
DEFAULT_CITATION_FORMAT,
|
|
11
11
|
attachCitation,
|
|
12
|
+
citationTemplateIsDetectable,
|
|
13
|
+
citationTemplatesForMerge,
|
|
14
|
+
citationTemplatesToRecognize,
|
|
12
15
|
deriveSessionId,
|
|
13
16
|
formatCitation,
|
|
14
17
|
hasCitation,
|
|
@@ -17,6 +20,7 @@ import {
|
|
|
17
20
|
parseCitation,
|
|
18
21
|
stripCitation,
|
|
19
22
|
stripCitationForTemplate,
|
|
23
|
+
stripRecognizedCitations,
|
|
20
24
|
} from "./source-attribution.js";
|
|
21
25
|
|
|
22
26
|
test("formatCitation emits the default template with provided fields", () => {
|
|
@@ -171,6 +175,7 @@ test("parseConfig disables inline source attribution by default", () => {
|
|
|
171
175
|
cfg.inlineSourceAttributionFormat,
|
|
172
176
|
"[Source: agent={agent}, session={sessionId}, ts={ts}]",
|
|
173
177
|
);
|
|
178
|
+
assert.deepEqual(cfg.inlineSourceAttributionFormatHistory, []);
|
|
174
179
|
});
|
|
175
180
|
|
|
176
181
|
test("parseConfig honors explicit inline source attribution overrides", () => {
|
|
@@ -196,6 +201,22 @@ test("parseConfig falls back to default format when override is empty", () => {
|
|
|
196
201
|
);
|
|
197
202
|
});
|
|
198
203
|
|
|
204
|
+
test("parseConfig keeps inlineSourceAttributionFormatHistory when format is normalized", () => {
|
|
205
|
+
const prior = "[src:{agent}/{sessionId}@{date}]";
|
|
206
|
+
const current = "[via:{agent}]";
|
|
207
|
+
const cfg = parseConfig({
|
|
208
|
+
inlineSourceAttributionFormat: " ",
|
|
209
|
+
inlineSourceAttributionFormatHistory: [prior, "", 12, " ", current],
|
|
210
|
+
});
|
|
211
|
+
assert.equal(cfg.inlineSourceAttributionFormat, DEFAULT_CITATION_FORMAT);
|
|
212
|
+
assert.deepEqual(cfg.inlineSourceAttributionFormatHistory, [prior, current]);
|
|
213
|
+
assert.deepEqual(citationTemplatesForMerge(cfg), [
|
|
214
|
+
DEFAULT_CITATION_FORMAT,
|
|
215
|
+
prior,
|
|
216
|
+
current,
|
|
217
|
+
]);
|
|
218
|
+
});
|
|
219
|
+
|
|
199
220
|
// ── Finding 1 regression: custom citation template dedup detection ────────────
|
|
200
221
|
|
|
201
222
|
test("hasCitationForTemplate detects default [Source:...] marker regardless of template", () => {
|
|
@@ -539,6 +560,24 @@ test("hasCitationForTemplate: '{agent}{sessionId}' all-placeholder template retu
|
|
|
539
560
|
);
|
|
540
561
|
});
|
|
541
562
|
|
|
563
|
+
test("citationTemplateIsDetectable rejects all-placeholder templates", () => {
|
|
564
|
+
assert.equal(citationTemplateIsDetectable("{agent}{sessionId}"), false);
|
|
565
|
+
assert.equal(citationTemplateIsDetectable(DEFAULT_CITATION_FORMAT), true);
|
|
566
|
+
assert.equal(citationTemplateIsDetectable("[src:{agent}/{sessionId}@{date}]"), true);
|
|
567
|
+
});
|
|
568
|
+
|
|
569
|
+
test("citationTemplatesToRecognize drops undetectable shapes and keeps prior history", () => {
|
|
570
|
+
const prior = "[src:{agent}/{sessionId}@{date}]";
|
|
571
|
+
const recognized = citationTemplatesToRecognize("{agent}{sessionId}", [prior]);
|
|
572
|
+
assert.deepEqual(recognized, [DEFAULT_CITATION_FORMAT, prior]);
|
|
573
|
+
const body = "The cadence is weekly. [src:agent-a/s-old@2026-08-19]";
|
|
574
|
+
assert.equal(stripRecognizedCitations(body, recognized), "The cadence is weekly.");
|
|
575
|
+
assert.deepEqual(citationTemplatesForMerge({ inlineSourceAttributionFormat: prior }), [
|
|
576
|
+
DEFAULT_CITATION_FORMAT,
|
|
577
|
+
prior,
|
|
578
|
+
]);
|
|
579
|
+
});
|
|
580
|
+
|
|
542
581
|
test("formatCitation: substituted values containing placeholder syntax are not re-interpreted", () => {
|
|
543
582
|
// Regression for PR #401 (low-severity): the previous implementation chained
|
|
544
583
|
// `.replace(/\{agent\}/g, ...)`, `.replace(/\{ts\}/g, ...)` etc. If the agent
|
|
@@ -482,6 +482,78 @@ export function lastCitationMarkerForTemplate(
|
|
|
482
482
|
return last;
|
|
483
483
|
}
|
|
484
484
|
|
|
485
|
+
/**
|
|
486
|
+
* True when a template can be matched and stripped later. All-placeholder
|
|
487
|
+
* templates such as `{agent}{sessionId}` have no literal anchors.
|
|
488
|
+
*/
|
|
489
|
+
export function citationTemplateIsDetectable(template: string): boolean {
|
|
490
|
+
if (typeof template !== "string" || template.length === 0) return false;
|
|
491
|
+
if (template === DEFAULT_CITATION_FORMAT) return true;
|
|
492
|
+
PLACEHOLDER_REGEX.lastIndex = 0;
|
|
493
|
+
if (!PLACEHOLDER_REGEX.test(template)) {
|
|
494
|
+
PLACEHOLDER_REGEX.lastIndex = 0;
|
|
495
|
+
return true;
|
|
496
|
+
}
|
|
497
|
+
PLACEHOLDER_REGEX.lastIndex = 0;
|
|
498
|
+
return templateMatcher(template) !== null;
|
|
499
|
+
}
|
|
500
|
+
|
|
501
|
+
/**
|
|
502
|
+
* Templates the merge path may lift, preserve, or strip: the default
|
|
503
|
+
* format, the current format when it is detectable, then any prior
|
|
504
|
+
* configured formats the caller still holds. Undetectable shapes are
|
|
505
|
+
* dropped so we never hash or attach a marker we cannot re-match.
|
|
506
|
+
*/
|
|
507
|
+
export function citationTemplatesToRecognize(
|
|
508
|
+
primary: string | undefined,
|
|
509
|
+
extra: readonly string[] = [],
|
|
510
|
+
): string[] {
|
|
511
|
+
const out: string[] = [];
|
|
512
|
+
const add = (template: string | undefined): void => {
|
|
513
|
+
if (typeof template !== "string" || template.length === 0) return;
|
|
514
|
+
if (!citationTemplateIsDetectable(template)) return;
|
|
515
|
+
if (!out.includes(template)) out.push(template);
|
|
516
|
+
};
|
|
517
|
+
add(DEFAULT_CITATION_FORMAT);
|
|
518
|
+
add(primary);
|
|
519
|
+
for (const template of extra) add(template);
|
|
520
|
+
return out;
|
|
521
|
+
}
|
|
522
|
+
|
|
523
|
+
/**
|
|
524
|
+
* Prior formats the caller still holds, if any. Absent or malformed
|
|
525
|
+
* history is ignored — fail safe, do not invent templates.
|
|
526
|
+
*/
|
|
527
|
+
export function citationTemplatesForMerge(config: {
|
|
528
|
+
inlineSourceAttributionFormat?: string;
|
|
529
|
+
inlineSourceAttributionFormatHistory?: unknown;
|
|
530
|
+
}): string[] {
|
|
531
|
+
const raw = config.inlineSourceAttributionFormatHistory;
|
|
532
|
+
const extra = Array.isArray(raw)
|
|
533
|
+
? raw.filter((value): value is string => typeof value === "string" && value.length > 0)
|
|
534
|
+
: [];
|
|
535
|
+
return citationTemplatesToRecognize(config.inlineSourceAttributionFormat, extra);
|
|
536
|
+
}
|
|
537
|
+
|
|
538
|
+
export function lastRecognizedCitationMarker(
|
|
539
|
+
text: string,
|
|
540
|
+
templates: readonly string[],
|
|
541
|
+
): string | null {
|
|
542
|
+
for (const template of templates) {
|
|
543
|
+
const marker = lastCitationMarkerForTemplate(text, template);
|
|
544
|
+
if (marker) return marker;
|
|
545
|
+
}
|
|
546
|
+
return null;
|
|
547
|
+
}
|
|
548
|
+
|
|
549
|
+
export function stripRecognizedCitations(text: string, templates: readonly string[]): string {
|
|
550
|
+
let out = text;
|
|
551
|
+
for (const template of templates) {
|
|
552
|
+
out = stripCitationForTemplate(out, template);
|
|
553
|
+
}
|
|
554
|
+
return out;
|
|
555
|
+
}
|
|
556
|
+
|
|
485
557
|
/**
|
|
486
558
|
* Attach an inline citation to fact text.
|
|
487
559
|
*
|
package/src/types.ts
CHANGED
|
@@ -1608,6 +1608,11 @@ export interface PluginConfig
|
|
|
1608
1608
|
* `[Source: agent={agent}, session={sessionId}, ts={ts}]`.
|
|
1609
1609
|
*/
|
|
1610
1610
|
inlineSourceAttributionFormat: string;
|
|
1611
|
+
/**
|
|
1612
|
+
* Prior citation templates still recognized after a format change.
|
|
1613
|
+
* Empty when the operator has never changed the template.
|
|
1614
|
+
*/
|
|
1615
|
+
inlineSourceAttributionFormatHistory: string[];
|
|
1611
1616
|
consolidationRequireNonZeroExtraction: boolean;
|
|
1612
1617
|
consolidationMinIntervalMs: number;
|
|
1613
1618
|
// QMD maintenance (debounced singleflight)
|
|
@@ -15,6 +15,7 @@
|
|
|
15
15
|
* write for the run has succeeded.
|
|
16
16
|
*/
|
|
17
17
|
|
|
18
|
+
import { fillWearableConversationLocations } from "../location/tagging.js";
|
|
18
19
|
import { cleanConversation } from "./cleanup.js";
|
|
19
20
|
import { describeErrorForOperator, WearablesInputError } from "./errors.js";
|
|
20
21
|
import {
|
|
@@ -50,6 +51,7 @@ import {
|
|
|
50
51
|
saveSyncState,
|
|
51
52
|
updateSourceSyncState,
|
|
52
53
|
} from "./sync-state.js";
|
|
54
|
+
import type { LocationConfig } from "../location/types.js";
|
|
53
55
|
import type {
|
|
54
56
|
WearableConversation,
|
|
55
57
|
WearableSourceConnector,
|
|
@@ -122,6 +124,11 @@ export interface WearableSyncDeps {
|
|
|
122
124
|
listSupportMemories?(): Promise<Array<{ id: string; content: string }>>;
|
|
123
125
|
/** Clock injection for tests. */
|
|
124
126
|
now?: () => Date;
|
|
127
|
+
/**
|
|
128
|
+
* Location config for the missing-only conversation location fill
|
|
129
|
+
* (issue #2925). Absent, or location tagging disabled, changes nothing.
|
|
130
|
+
*/
|
|
131
|
+
locationConfig?: LocationConfig;
|
|
125
132
|
}
|
|
126
133
|
|
|
127
134
|
/** Format a Date as YYYY-MM-DD in the given IANA timezone. */
|
|
@@ -382,6 +389,18 @@ export async function syncWearableSource(
|
|
|
382
389
|
summary.redactions += cleaned.redactions;
|
|
383
390
|
summary.correctionsApplied += cleaned.correctionsApplied;
|
|
384
391
|
|
|
392
|
+
// Missing-only location fill (issue #2925): run before the body is
|
|
393
|
+
// composed so a qualifying dominant-overlap place reaches the day
|
|
394
|
+
// transcript and memory headers exactly like a provider-supplied
|
|
395
|
+
// location would. Source-provided values are never overwritten, and
|
|
396
|
+
// the helper no-ops unless both location gates are on.
|
|
397
|
+
if (deps.locationConfig) {
|
|
398
|
+
await fillWearableConversationLocations(cleaned.conversations, {
|
|
399
|
+
memoryDir: deps.memoryDir,
|
|
400
|
+
config: deps.locationConfig,
|
|
401
|
+
});
|
|
402
|
+
}
|
|
403
|
+
|
|
385
404
|
if (fetched.conversations.length === 0) {
|
|
386
405
|
// No provider data at all. A transient provider hiccup can
|
|
387
406
|
// legitimately produce an empty result, so an existing stored
|
package/src/wearables/service.ts
CHANGED
|
@@ -13,6 +13,7 @@ import {
|
|
|
13
13
|
} from "./corrections.js";
|
|
14
14
|
import { describeErrorForOperator, WearablesInputError } from "./errors.js";
|
|
15
15
|
import { inferMemoryStatus } from "../memory-lifecycle-ledger-utils.js";
|
|
16
|
+
import type { LocationConfig } from "../location/types.js";
|
|
16
17
|
import { isSupportPassportPrivateMemory } from "../support-passport/card-projection.js";
|
|
17
18
|
import {
|
|
18
19
|
bodyIsEscaped,
|
|
@@ -143,6 +144,12 @@ export interface WearablesServiceDeps {
|
|
|
143
144
|
* fails the sync.
|
|
144
145
|
*/
|
|
145
146
|
onDaysSynced?: (days: readonly string[]) => void | Promise<void>;
|
|
147
|
+
/**
|
|
148
|
+
* Location config for the missing-only conversation location fill
|
|
149
|
+
* (issue #2925). Absent changes nothing; the fill itself stays gated
|
|
150
|
+
* on the location tagging flags.
|
|
151
|
+
*/
|
|
152
|
+
locationConfig?: LocationConfig;
|
|
146
153
|
}
|
|
147
154
|
|
|
148
155
|
export interface WearableTranscriptSearchResult {
|
|
@@ -351,6 +358,7 @@ export class WearablesService {
|
|
|
351
358
|
options,
|
|
352
359
|
{
|
|
353
360
|
memoryDir: storage.dir,
|
|
361
|
+
locationConfig: this.deps.locationConfig,
|
|
354
362
|
readDayContentHash: async (source, date) => {
|
|
355
363
|
const raw = await storage.readWearableDayTranscript(source, date);
|
|
356
364
|
if (raw === null) return null;
|