@remnic/core 9.3.725 → 9.3.727
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-boundary.d.ts +5 -5
- package/dist/access-boundary.js +28 -27
- package/dist/access-cli.js +65 -63
- package/dist/access-cli.js.map +1 -1
- package/dist/access-http.d.ts +20 -5
- package/dist/access-http.js +34 -33
- package/dist/access-mcp.d.ts +5 -5
- package/dist/access-mcp.js +31 -30
- package/dist/access-operations-batch.js +29 -28
- package/dist/access-operations.d.ts +5 -5
- package/dist/access-operations.js +30 -29
- package/dist/{access-service-B2PlPtxh.d.ts → access-service-Bgpjxo4f.d.ts} +36 -4
- package/dist/access-service.d.ts +5 -5
- package/dist/access-service.js +27 -26
- package/dist/access-surface-catalog.d.ts +5 -5
- package/dist/action-confidence.d.ts +1 -1
- package/dist/active-memory-bridge.d.ts +1 -1
- package/dist/active-recall.d.ts +1 -1
- package/dist/active-recall.js +3 -3
- package/dist/adapters/index.js +4 -4
- package/dist/adapters/registry.js +2 -2
- package/dist/behavior-learner.d.ts +1 -1
- package/dist/behavior-signals.d.ts +1 -1
- package/dist/bootstrap.d.ts +4 -4
- package/dist/briefing.d.ts +1 -1
- package/dist/briefing.js +9 -8
- package/dist/buffer-surprise-report.d.ts +1 -1
- package/dist/buffer.d.ts +1 -1
- package/dist/calibration.d.ts +1 -1
- package/dist/capabilities.d.ts +1 -1
- package/dist/{catalog-CzUb-GyD.d.ts → catalog-bMczlO2G.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 +10 -9
- package/dist/causal-consolidation.js.map +1 -1
- package/dist/causal-trajectory-graph.d.ts +1 -1
- package/dist/{chunk-KGZF2VO3.js → chunk-27QQC7ZX.js} +80 -19
- package/dist/{chunk-KGZF2VO3.js.map → chunk-27QQC7ZX.js.map} +1 -1
- package/dist/{chunk-HCVWF657.js → chunk-2KAYTPPT.js} +12 -12
- package/dist/{chunk-4SF232E6.js → chunk-36SEDFAU.js} +19 -7
- package/dist/chunk-36SEDFAU.js.map +1 -0
- package/dist/{chunk-ZK2L72VN.js → chunk-37436GML.js} +2 -2
- package/dist/{chunk-SC2YAWRF.js → chunk-3TSTGI6F.js} +2 -2
- package/dist/{chunk-FACTVMXQ.js → chunk-4H4F3BFL.js} +2 -2
- package/dist/{chunk-WAFDHKES.js → chunk-4NOI577P.js} +2 -2
- package/dist/{chunk-YQMPUYHE.js → chunk-4NR2PDZ5.js} +2 -2
- package/dist/{chunk-TAPSNIMA.js → chunk-5CEJH5ZN.js} +4 -4
- package/dist/{chunk-FN6QP7JQ.js → chunk-6PY5YJAV.js} +100 -14
- package/dist/{chunk-FN6QP7JQ.js.map → chunk-6PY5YJAV.js.map} +1 -1
- package/dist/{chunk-PKMQK2WY.js → chunk-773DPI6T.js} +4 -4
- package/dist/{chunk-4R3CGCI5.js → chunk-7RLCCNHU.js} +15 -12
- package/dist/chunk-7RLCCNHU.js.map +1 -0
- package/dist/{chunk-XGTBNVIU.js → chunk-AAD2ZS6P.js} +11 -1
- package/dist/chunk-AAD2ZS6P.js.map +1 -0
- package/dist/{chunk-Z3FGC3QE.js → chunk-AQLOP5F4.js} +139 -30
- package/dist/chunk-AQLOP5F4.js.map +1 -0
- package/dist/{chunk-FXCIOLRB.js → chunk-ASKXIAHD.js} +2 -2
- package/dist/{chunk-5OPYYPJN.js → chunk-CBWI22JN.js} +2 -2
- package/dist/{chunk-ZOHMPFOB.js → chunk-CKFLLAIS.js} +3 -3
- package/dist/{chunk-GZQXOQQ2.js → chunk-CSRXQ6NB.js} +5 -5
- package/dist/{chunk-QR67FU5G.js → chunk-CTOQEZSN.js} +2 -2
- package/dist/{chunk-ZUDM75KG.js → chunk-DCWIQFNA.js} +4 -4
- package/dist/{chunk-6CWGS2LY.js → chunk-DKJCRGWM.js} +3 -3
- package/dist/{chunk-JJJCVCCQ.js → chunk-DMQWV6SQ.js} +2 -2
- package/dist/{chunk-F3XZN24Z.js → chunk-DRUDC2UX.js} +2 -2
- package/dist/{chunk-4WZ3J7M6.js → chunk-EY6MDMHK.js} +2 -2
- package/dist/{chunk-YNDLCWXS.js → chunk-EZ25VE3G.js} +4 -4
- package/dist/{chunk-C4X4QGIO.js → chunk-G6NKALRN.js} +5 -2
- package/dist/chunk-G6NKALRN.js.map +1 -0
- package/dist/{chunk-6SQQOJ4U.js → chunk-GKRLPHPU.js} +2 -2
- package/dist/{chunk-D7EBTQ24.js → chunk-HOHVIVDR.js} +2 -2
- package/dist/{chunk-RKNJBZ55.js → chunk-JBPKEARU.js} +4 -4
- package/dist/{chunk-UBHVAGO7.js → chunk-JYLFZWUX.js} +2 -2
- package/dist/{chunk-LD53WPMU.js → chunk-LQ6JI4VH.js} +4 -4
- package/dist/chunk-LTHVM4XN.js +109 -0
- package/dist/chunk-LTHVM4XN.js.map +1 -0
- package/dist/{chunk-WM7DNKBD.js → chunk-M4V2JVSZ.js} +2 -2
- package/dist/{chunk-I2HL5M6T.js → chunk-MJIHJ7OG.js} +52 -52
- package/dist/{chunk-J334N6QV.js → chunk-MLKWJOAJ.js} +2 -2
- package/dist/{chunk-C6BWLYW5.js → chunk-N3VNUM4Z.js} +171 -79
- package/dist/chunk-N3VNUM4Z.js.map +1 -0
- package/dist/{chunk-DF3I6JGP.js → chunk-NSA5ZRUL.js} +15 -15
- package/dist/{chunk-VI5SGGXB.js → chunk-OEEW4KJA.js} +4 -4
- package/dist/{chunk-7AG54AF3.js → chunk-PUR2CKX2.js} +1 -1
- package/dist/chunk-PUR2CKX2.js.map +1 -0
- package/dist/{chunk-NT36GU6X.js → chunk-R7IYU5DZ.js} +2 -2
- package/dist/{chunk-TT5U3UDO.js → chunk-SNKPUJHR.js} +4 -4
- package/dist/{chunk-T55EGZSJ.js → chunk-UVPL565C.js} +2 -2
- package/dist/chunk-W5H6ZRPT.js +14 -0
- package/dist/chunk-W5H6ZRPT.js.map +1 -0
- package/dist/{chunk-YQGHW5ML.js → chunk-WRFKZEO6.js} +4 -4
- package/dist/{chunk-KLFYKC3K.js → chunk-XPHVAOBT.js} +195 -74
- package/dist/chunk-XPHVAOBT.js.map +1 -0
- package/dist/{chunk-H7HUQIY7.js → chunk-Y4YD5TYW.js} +3 -3
- package/dist/{chunk-MDBZTH7N.js → chunk-YKBHOBJK.js} +44 -10
- package/dist/chunk-YKBHOBJK.js.map +1 -0
- package/dist/{chunk-YUYPWJD3.js → chunk-YOLZS7NY.js} +2 -2
- package/dist/{chunk-6OIDDKAA.js → chunk-YTU7WKYN.js} +35 -9
- package/dist/chunk-YTU7WKYN.js.map +1 -0
- package/dist/{cli-IOlDHSBT.d.ts → cli-BLME420h.d.ts} +3 -3
- package/dist/cli.d.ts +6 -6
- package/dist/cli.js +60 -59
- package/dist/compat/codex-cli-fallback.d.ts +1 -0
- package/dist/compat/codex-cli-fallback.js +22 -0
- package/dist/compat/codex-cli-fallback.js.map +1 -0
- package/dist/compat/codex-thread-key.d.ts +1 -0
- package/dist/compat/codex-thread-key.js +18 -0
- package/dist/compat/codex-thread-key.js.map +1 -0
- package/dist/compounding/engine.d.ts +1 -1
- package/dist/compounding/engine.js +9 -8
- 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 +3 -3
- package/dist/connectors/codex-materialize-runner.d.ts +1 -1
- package/dist/connectors/codex-materialize-runner.js +9 -8
- package/dist/connectors/codex-materialize.d.ts +1 -1
- package/dist/connectors/index.d.ts +1 -1
- package/dist/connectors/index.js +9 -8
- package/dist/consolidation-provenance-check.d.ts +1 -1
- package/dist/consolidation-undo.d.ts +1 -1
- package/dist/content-hash.d.ts +14 -0
- package/dist/content-hash.js +10 -0
- package/dist/content-hash.js.map +1 -0
- package/dist/contradiction/index.d.ts +1 -1
- package/dist/conversation-index/backend.d.ts +1 -1
- package/dist/conversation-index/backend.js +2 -2
- 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/dashboard-runtime.js +2 -2
- package/dist/day-summary.d.ts +1 -1
- package/dist/delinearize.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-retrieval.d.ts +1 -1
- package/dist/entity-retrieval.js +9 -8
- package/dist/entity-schema.d.ts +1 -1
- package/dist/explicit-capture.d.ts +4 -4
- package/dist/extraction-faithfulness.d.ts +1 -1
- package/dist/extraction-faithfulness.js +2 -2
- package/dist/extraction-judge-telemetry.d.ts +1 -1
- package/dist/extraction-judge-training.d.ts +1 -1
- package/dist/extraction-judge.d.ts +1 -1
- package/dist/extraction-redaction-rules.d.ts +33 -0
- package/dist/extraction-redaction-rules.js +14 -0
- package/dist/extraction-redaction-rules.js.map +1 -0
- package/dist/extraction.d.ts +1 -1
- package/dist/extraction.js +3 -3
- package/dist/faithfulness-config.d.ts +1 -0
- package/dist/faithfulness-config.js +1 -1
- package/dist/fallback-llm.d.ts +1 -1
- package/dist/{forget-OEE5OELK.js → forget-WYLR4ZFV.js} +2 -2
- 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-snapshot.d.ts +1 -1
- package/dist/graph.d.ts +1 -1
- package/dist/identity-continuity.d.ts +1 -1
- package/dist/importance.d.ts +1 -1
- package/dist/index.d.ts +9 -9
- package/dist/index.js +107 -105
- package/dist/index.js.map +1 -1
- package/dist/intent.d.ts +1 -1
- package/dist/lcm/engine.d.ts +1 -1
- package/dist/lcm/engine.js +2 -2
- package/dist/lcm/index.d.ts +1 -1
- package/dist/lcm/index.js +4 -4
- 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.d.ts +1 -1
- package/dist/local-model-endpoint.d.ts +9 -4
- package/dist/local-model-endpoint.js +1 -1
- package/dist/maintenance/memory-governance.d.ts +1 -1
- package/dist/maintenance/memory-governance.js +9 -8
- package/dist/maintenance/rebuild-memory-lifecycle-ledger.js +9 -8
- package/dist/maintenance/rebuild-memory-projection.js +10 -9
- package/dist/mcp-memory-inspector-app.d.ts +5 -5
- package/dist/memory-action-policy.d.ts +1 -1
- package/dist/memory-cache.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-worth-outcomes.d.ts +1 -1
- package/dist/models-json.d.ts +1 -1
- package/dist/namespaces/migrate.d.ts +2 -2
- package/dist/namespaces/migrate.js +19 -18
- package/dist/namespaces/principal.d.ts +1 -1
- package/dist/namespaces/search.d.ts +1 -1
- package/dist/namespaces/search.js +9 -9
- package/dist/namespaces/storage.d.ts +2 -2
- package/dist/namespaces/storage.js +9 -8
- package/dist/native-knowledge.d.ts +1 -1
- package/dist/operator-toolkit.d.ts +1 -1
- package/dist/operator-toolkit.js +28 -27
- package/dist/orchestration/maintenance.d.ts +2 -2
- package/dist/orchestration/maintenance.js +11 -10
- package/dist/{orchestrator-C_OMSIMZ.d.ts → orchestrator-DqPAz8ot.d.ts} +3 -3
- package/dist/orchestrator.d.ts +4 -4
- package/dist/orchestrator.js +51 -49
- package/dist/patterns-cli.d.ts +1 -1
- package/dist/policy-runtime.d.ts +1 -1
- package/dist/provenance.d.ts +1 -1
- package/dist/provenance.js +1 -1
- package/dist/qmd-recall-cache.d.ts +1 -1
- package/dist/qmd.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-planner-llm.d.ts +1 -1
- package/dist/recall-state.d.ts +1 -1
- package/dist/recall-tag-filter.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/resolve-auth-token.d.ts +1 -1
- package/dist/resume-bundles.js +4 -4
- package/dist/retrieval-agents.d.ts +1 -1
- 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/schemas.d.ts +22 -22
- package/dist/search/embed-helper.d.ts +1 -1
- package/dist/search/factory.d.ts +1 -1
- package/dist/search/factory.js +8 -8
- package/dist/search/index.d.ts +1 -1
- package/dist/search/index.js +14 -14
- package/dist/search/lancedb-backend.d.ts +1 -1
- package/dist/search/lancedb-backend.js +2 -2
- package/dist/search/meilisearch-backend.d.ts +1 -1
- package/dist/search/meilisearch-backend.js +2 -2
- package/dist/search/noop-backend.d.ts +1 -1
- package/dist/search/orama-backend.d.ts +1 -1
- package/dist/search/orama-backend.js +2 -2
- package/dist/search/port.d.ts +1 -1
- package/dist/search/remote-backend.d.ts +1 -1
- package/dist/{semantic-consolidation-B8LiYtvx.d.ts → semantic-consolidation-Cl15ksZy.d.ts} +1 -1
- package/dist/semantic-consolidation.d.ts +2 -2
- package/dist/semantic-consolidation.js +10 -9
- package/dist/semantic-rule-promotion.js +9 -8
- package/dist/semantic-rule-verifier.d.ts +1 -1
- package/dist/semantic-rule-verifier.js +9 -8
- 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 +1 -1
- package/dist/signal.d.ts +1 -1
- package/dist/storage.d.ts +3 -3
- package/dist/storage.js +9 -8
- package/dist/summarizer.d.ts +1 -1
- package/dist/summary-snapshot.d.ts +1 -1
- package/dist/temporal-supersession.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 +1 -1
- package/dist/tier-routing.d.ts +1 -1
- package/dist/topics.d.ts +1 -1
- package/dist/transcript.d.ts +1 -1
- package/dist/transfer/types.d.ts +12 -12
- package/dist/trust-score-stage.d.ts +1 -1
- package/dist/trust-score.d.ts +1 -1
- package/dist/{types-DmTaqob2.d.ts → types-ChQb9D6s.d.ts} +8 -0
- 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 +9 -8
- package/package.json +26 -2
- package/src/access-http.ts +68 -1
- package/src/admin/admin-surfaces.test.ts +289 -0
- package/src/admin/admin-surfaces.ts +138 -7
- package/src/bitemporal-dedup-backfill.test.ts +294 -0
- package/src/chat/chat-engine.test.ts +66 -1
- package/src/chat/chat-http.test.ts +119 -1
- package/src/chat/chat-http.ts +252 -97
- package/src/chat/chat-session.ts +143 -7
- package/src/compat/codex-cli-fallback.ts +23 -0
- package/src/compat/codex-subpath-aliases.test.ts +93 -0
- package/src/compat/codex-thread-key.ts +23 -0
- package/src/config.test.ts +50 -0
- package/src/config.ts +21 -4
- package/src/content-hash.ts +24 -0
- package/src/correction/correction-access-wiring.ts +104 -19
- package/src/correction/correction-contract.ts +68 -10
- package/src/correction/correction-executor.test.ts +112 -2
- package/src/correction/correction-executor.ts +65 -5
- package/src/correction/correction-planner.test.ts +47 -0
- package/src/correction/correction-planner.ts +40 -1
- package/src/correction/correction-storage-integration.test.ts +183 -0
- package/src/extraction-faithfulness.test.ts +240 -0
- package/src/extraction-faithfulness.ts +58 -6
- package/src/extraction-redaction-rules.test.ts +213 -0
- package/src/extraction-redaction-rules.ts +208 -0
- package/src/faithfulness-config.ts +16 -1
- package/src/local-model-endpoint.ts +24 -3
- package/src/orchestrator.ts +252 -9
- package/src/provenance-extraction.test.ts +266 -0
- package/src/provenance.ts +66 -16
- package/src/storage.ts +6 -10
- package/src/types.ts +8 -0
- package/dist/chunk-4R3CGCI5.js.map +0 -1
- package/dist/chunk-4SF232E6.js.map +0 -1
- package/dist/chunk-6OIDDKAA.js.map +0 -1
- package/dist/chunk-7AG54AF3.js.map +0 -1
- package/dist/chunk-C4X4QGIO.js.map +0 -1
- package/dist/chunk-C6BWLYW5.js.map +0 -1
- package/dist/chunk-KLFYKC3K.js.map +0 -1
- package/dist/chunk-MDBZTH7N.js.map +0 -1
- package/dist/chunk-XGTBNVIU.js.map +0 -1
- package/dist/chunk-Z3FGC3QE.js.map +0 -1
- /package/dist/{chunk-HCVWF657.js.map → chunk-2KAYTPPT.js.map} +0 -0
- /package/dist/{chunk-ZK2L72VN.js.map → chunk-37436GML.js.map} +0 -0
- /package/dist/{chunk-SC2YAWRF.js.map → chunk-3TSTGI6F.js.map} +0 -0
- /package/dist/{chunk-FACTVMXQ.js.map → chunk-4H4F3BFL.js.map} +0 -0
- /package/dist/{chunk-WAFDHKES.js.map → chunk-4NOI577P.js.map} +0 -0
- /package/dist/{chunk-YQMPUYHE.js.map → chunk-4NR2PDZ5.js.map} +0 -0
- /package/dist/{chunk-TAPSNIMA.js.map → chunk-5CEJH5ZN.js.map} +0 -0
- /package/dist/{chunk-PKMQK2WY.js.map → chunk-773DPI6T.js.map} +0 -0
- /package/dist/{chunk-FXCIOLRB.js.map → chunk-ASKXIAHD.js.map} +0 -0
- /package/dist/{chunk-5OPYYPJN.js.map → chunk-CBWI22JN.js.map} +0 -0
- /package/dist/{chunk-ZOHMPFOB.js.map → chunk-CKFLLAIS.js.map} +0 -0
- /package/dist/{chunk-GZQXOQQ2.js.map → chunk-CSRXQ6NB.js.map} +0 -0
- /package/dist/{chunk-QR67FU5G.js.map → chunk-CTOQEZSN.js.map} +0 -0
- /package/dist/{chunk-ZUDM75KG.js.map → chunk-DCWIQFNA.js.map} +0 -0
- /package/dist/{chunk-6CWGS2LY.js.map → chunk-DKJCRGWM.js.map} +0 -0
- /package/dist/{chunk-JJJCVCCQ.js.map → chunk-DMQWV6SQ.js.map} +0 -0
- /package/dist/{chunk-F3XZN24Z.js.map → chunk-DRUDC2UX.js.map} +0 -0
- /package/dist/{chunk-4WZ3J7M6.js.map → chunk-EY6MDMHK.js.map} +0 -0
- /package/dist/{chunk-YNDLCWXS.js.map → chunk-EZ25VE3G.js.map} +0 -0
- /package/dist/{chunk-6SQQOJ4U.js.map → chunk-GKRLPHPU.js.map} +0 -0
- /package/dist/{chunk-D7EBTQ24.js.map → chunk-HOHVIVDR.js.map} +0 -0
- /package/dist/{chunk-RKNJBZ55.js.map → chunk-JBPKEARU.js.map} +0 -0
- /package/dist/{chunk-UBHVAGO7.js.map → chunk-JYLFZWUX.js.map} +0 -0
- /package/dist/{chunk-LD53WPMU.js.map → chunk-LQ6JI4VH.js.map} +0 -0
- /package/dist/{chunk-WM7DNKBD.js.map → chunk-M4V2JVSZ.js.map} +0 -0
- /package/dist/{chunk-I2HL5M6T.js.map → chunk-MJIHJ7OG.js.map} +0 -0
- /package/dist/{chunk-J334N6QV.js.map → chunk-MLKWJOAJ.js.map} +0 -0
- /package/dist/{chunk-DF3I6JGP.js.map → chunk-NSA5ZRUL.js.map} +0 -0
- /package/dist/{chunk-VI5SGGXB.js.map → chunk-OEEW4KJA.js.map} +0 -0
- /package/dist/{chunk-NT36GU6X.js.map → chunk-R7IYU5DZ.js.map} +0 -0
- /package/dist/{chunk-TT5U3UDO.js.map → chunk-SNKPUJHR.js.map} +0 -0
- /package/dist/{chunk-T55EGZSJ.js.map → chunk-UVPL565C.js.map} +0 -0
- /package/dist/{chunk-YQGHW5ML.js.map → chunk-WRFKZEO6.js.map} +0 -0
- /package/dist/{chunk-H7HUQIY7.js.map → chunk-Y4YD5TYW.js.map} +0 -0
- /package/dist/{chunk-YUYPWJD3.js.map → chunk-YOLZS7NY.js.map} +0 -0
- /package/dist/{forget-OEE5OELK.js.map → forget-WYLR4ZFV.js.map} +0 -0
|
@@ -7,13 +7,13 @@ import {
|
|
|
7
7
|
} from "./chunk-4T3BMHKD.js";
|
|
8
8
|
import {
|
|
9
9
|
MaintenanceScheduler
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-MLKWJOAJ.js";
|
|
11
11
|
import {
|
|
12
12
|
migrateFromEngram
|
|
13
13
|
} from "./chunk-7HYPN2GC.js";
|
|
14
14
|
import {
|
|
15
15
|
LcmEngine
|
|
16
|
-
} from "./chunk-
|
|
16
|
+
} from "./chunk-773DPI6T.js";
|
|
17
17
|
import {
|
|
18
18
|
chunkTranscriptEntries
|
|
19
19
|
} from "./chunk-TECVW3JP.js";
|
|
@@ -23,15 +23,26 @@ import {
|
|
|
23
23
|
import {
|
|
24
24
|
CompoundingEngine,
|
|
25
25
|
defaultTierMigrationCycleBudget
|
|
26
|
-
} from "./chunk-
|
|
26
|
+
} from "./chunk-4NR2PDZ5.js";
|
|
27
27
|
import {
|
|
28
28
|
SharedContextManager
|
|
29
29
|
} from "./chunk-UFS7OXGL.js";
|
|
30
|
+
import {
|
|
31
|
+
applyTrustScoreStage,
|
|
32
|
+
buildTrustSignalsForRerank,
|
|
33
|
+
projectTrustForXray
|
|
34
|
+
} from "./chunk-BCDKBDSY.js";
|
|
35
|
+
import {
|
|
36
|
+
renderEpistemicHedge
|
|
37
|
+
} from "./chunk-YN2UN7N3.js";
|
|
30
38
|
import {
|
|
31
39
|
applyUtilityPromotionRuntimePolicy,
|
|
32
40
|
applyUtilityRankingRuntimeDelta,
|
|
33
41
|
loadUtilityRuntimeValues
|
|
34
42
|
} from "./chunk-LXOM6IQU.js";
|
|
43
|
+
import {
|
|
44
|
+
CODEX_THREAD_KEY_PREFIX
|
|
45
|
+
} from "./chunk-4EX5WZ4M.js";
|
|
35
46
|
import {
|
|
36
47
|
TierMigrationExecutor
|
|
37
48
|
} from "./chunk-VOUOLGIP.js";
|
|
@@ -45,26 +56,19 @@ import {
|
|
|
45
56
|
extractTopics
|
|
46
57
|
} from "./chunk-UHGBNIOS.js";
|
|
47
58
|
import {
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
projectTrustForXray
|
|
51
|
-
} from "./chunk-BCDKBDSY.js";
|
|
52
|
-
import {
|
|
53
|
-
renderEpistemicHedge
|
|
54
|
-
} from "./chunk-YN2UN7N3.js";
|
|
59
|
+
HourlySummarizer
|
|
60
|
+
} from "./chunk-DKT3X5C3.js";
|
|
55
61
|
import {
|
|
56
62
|
buildTargetedFactRecallSection,
|
|
57
63
|
shouldRecallTargetedFactEvidence
|
|
58
64
|
} from "./chunk-4SBW47WK.js";
|
|
59
|
-
import {
|
|
60
|
-
CODEX_THREAD_KEY_PREFIX
|
|
61
|
-
} from "./chunk-4EX5WZ4M.js";
|
|
62
|
-
import {
|
|
63
|
-
HourlySummarizer
|
|
64
|
-
} from "./chunk-DKT3X5C3.js";
|
|
65
65
|
import {
|
|
66
66
|
SessionObserverState
|
|
67
67
|
} from "./chunk-DKTSR7EK.js";
|
|
68
|
+
import {
|
|
69
|
+
buildResponseGuidanceRecallSection,
|
|
70
|
+
shouldRecallResponseGuidance
|
|
71
|
+
} from "./chunk-L6W77GWW.js";
|
|
68
72
|
import {
|
|
69
73
|
mergeWithAgentResults,
|
|
70
74
|
runDirectAgent,
|
|
@@ -96,10 +100,6 @@ import {
|
|
|
96
100
|
RerankCache,
|
|
97
101
|
rerankLocalOrNoop
|
|
98
102
|
} from "./chunk-E3VODCC3.js";
|
|
99
|
-
import {
|
|
100
|
-
buildResponseGuidanceRecallSection,
|
|
101
|
-
shouldRecallResponseGuidance
|
|
102
|
-
} from "./chunk-L6W77GWW.js";
|
|
103
103
|
import {
|
|
104
104
|
createRecallSectionMetricRecorder
|
|
105
105
|
} from "./chunk-VQ34TERH.js";
|
|
@@ -109,25 +109,28 @@ import {
|
|
|
109
109
|
TierMigrationStatusStore,
|
|
110
110
|
clampGraphRecallExpandedEntries
|
|
111
111
|
} from "./chunk-UC4YOAC2.js";
|
|
112
|
+
import {
|
|
113
|
+
applyReasoningTraceBoost
|
|
114
|
+
} from "./chunk-ZZTOURJI.js";
|
|
112
115
|
import {
|
|
113
116
|
reorderRecallResultsWithMmr
|
|
114
117
|
} from "./chunk-YDBIWGNI.js";
|
|
115
118
|
import {
|
|
116
|
-
|
|
117
|
-
|
|
119
|
+
applyMemoryWorthFilter,
|
|
120
|
+
buildMemoryWorthCounterMap
|
|
121
|
+
} from "./chunk-3GPTTA4J.js";
|
|
118
122
|
import {
|
|
119
123
|
NegativeExampleStore
|
|
120
124
|
} from "./chunk-EXM3CQTZ.js";
|
|
121
125
|
import {
|
|
122
126
|
evaluateMemoryActionPolicy
|
|
123
127
|
} from "./chunk-H63EDPFJ.js";
|
|
124
|
-
import {
|
|
125
|
-
applyMemoryWorthFilter,
|
|
126
|
-
buildMemoryWorthCounterMap
|
|
127
|
-
} from "./chunk-3GPTTA4J.js";
|
|
128
128
|
import {
|
|
129
129
|
runLiveConnectorsOnce
|
|
130
130
|
} from "./chunk-VU3SVYMA.js";
|
|
131
|
+
import {
|
|
132
|
+
classifyMemoryKind
|
|
133
|
+
} from "./chunk-YAZNBMNF.js";
|
|
131
134
|
import {
|
|
132
135
|
hasBroadGraphIntent,
|
|
133
136
|
inferIntentFromText,
|
|
@@ -136,8 +139,8 @@ import {
|
|
|
136
139
|
planRecallMode
|
|
137
140
|
} from "./chunk-PD6O7AXF.js";
|
|
138
141
|
import {
|
|
139
|
-
|
|
140
|
-
} from "./chunk-
|
|
142
|
+
recordJudgeTrainingPair
|
|
143
|
+
} from "./chunk-XHYGJVXL.js";
|
|
141
144
|
import {
|
|
142
145
|
createDeferCountMap,
|
|
143
146
|
createVerdictCache,
|
|
@@ -145,9 +148,13 @@ import {
|
|
|
145
148
|
judgeFactDurability,
|
|
146
149
|
validateProcedureExtraction
|
|
147
150
|
} from "./chunk-3NN73CM7.js";
|
|
151
|
+
import {
|
|
152
|
+
contentMatchesRedactionRules,
|
|
153
|
+
loadRedactionRules
|
|
154
|
+
} from "./chunk-LTHVM4XN.js";
|
|
148
155
|
import {
|
|
149
156
|
ExtractionEngine
|
|
150
|
-
} from "./chunk-
|
|
157
|
+
} from "./chunk-CSRXQ6NB.js";
|
|
151
158
|
import {
|
|
152
159
|
parseMemoryActionEligibilityContext
|
|
153
160
|
} from "./chunk-5GSUBCZM.js";
|
|
@@ -173,8 +180,8 @@ import {
|
|
|
173
180
|
buildExplicitCueRecallSection
|
|
174
181
|
} from "./chunk-4463LUIE.js";
|
|
175
182
|
import {
|
|
176
|
-
|
|
177
|
-
} from "./chunk-
|
|
183
|
+
formatDaySummaryMemories
|
|
184
|
+
} from "./chunk-EO5QWINU.js";
|
|
178
185
|
import {
|
|
179
186
|
tryDirectAnswer
|
|
180
187
|
} from "./chunk-Q6IP2ARR.js";
|
|
@@ -185,10 +192,7 @@ import {
|
|
|
185
192
|
buildEntityRecallSection,
|
|
186
193
|
entityRecentTranscriptLookbackHours,
|
|
187
194
|
readRecentEntityTranscriptEntries
|
|
188
|
-
} from "./chunk-
|
|
189
|
-
import {
|
|
190
|
-
formatDaySummaryMemories
|
|
191
|
-
} from "./chunk-EO5QWINU.js";
|
|
195
|
+
} from "./chunk-YOLZS7NY.js";
|
|
192
196
|
import {
|
|
193
197
|
normalizeReplaySessionKey
|
|
194
198
|
} from "./chunk-2PRQG7PV.js";
|
|
@@ -198,14 +202,14 @@ import {
|
|
|
198
202
|
import {
|
|
199
203
|
compareVerifiedEpisodeResults,
|
|
200
204
|
searchVerifiedEpisodes
|
|
201
|
-
} from "./chunk-
|
|
205
|
+
} from "./chunk-ASKXIAHD.js";
|
|
202
206
|
import {
|
|
203
207
|
ThreadingManager
|
|
204
208
|
} from "./chunk-QRDOSYOR.js";
|
|
205
209
|
import {
|
|
206
210
|
compareVerifiedSemanticRuleResults,
|
|
207
211
|
searchVerifiedSemanticRules
|
|
208
|
-
} from "./chunk-
|
|
212
|
+
} from "./chunk-UVPL565C.js";
|
|
209
213
|
import {
|
|
210
214
|
searchWorkProductLedgerEntries
|
|
211
215
|
} from "./chunk-ZRWB5D4H.js";
|
|
@@ -218,21 +222,24 @@ import {
|
|
|
218
222
|
import {
|
|
219
223
|
runNamespaceMaintenanceFanout,
|
|
220
224
|
summarizeNamespaceMaintenanceHealth
|
|
221
|
-
} from "./chunk-
|
|
225
|
+
} from "./chunk-CBWI22JN.js";
|
|
222
226
|
import {
|
|
223
227
|
NamespaceCatalog,
|
|
224
228
|
planNamespaceMaintenance
|
|
225
|
-
} from "./chunk-
|
|
229
|
+
} from "./chunk-M4V2JVSZ.js";
|
|
226
230
|
import {
|
|
227
231
|
NamespaceStorageRouter
|
|
228
|
-
} from "./chunk-
|
|
232
|
+
} from "./chunk-3TSTGI6F.js";
|
|
233
|
+
import {
|
|
234
|
+
searchHarmonicRetrieval
|
|
235
|
+
} from "./chunk-AV5ZEH4M.js";
|
|
229
236
|
import {
|
|
230
237
|
isAboveImportanceThreshold,
|
|
231
238
|
scoreImportance
|
|
232
239
|
} from "./chunk-JXS5PDQ7.js";
|
|
233
240
|
import {
|
|
234
|
-
|
|
235
|
-
} from "./chunk-
|
|
241
|
+
recordEvalShadowRecall
|
|
242
|
+
} from "./chunk-3PY7VHV7.js";
|
|
236
243
|
import {
|
|
237
244
|
EXTRACTION_JUDGE_VERDICT_CATEGORY,
|
|
238
245
|
recordJudgeVerdict
|
|
@@ -242,9 +249,6 @@ import {
|
|
|
242
249
|
formatNativeKnowledgeSection,
|
|
243
250
|
searchNativeKnowledge
|
|
244
251
|
} from "./chunk-ZCWIH4LH.js";
|
|
245
|
-
import {
|
|
246
|
-
recordEvalShadowRecall
|
|
247
|
-
} from "./chunk-3PY7VHV7.js";
|
|
248
252
|
import {
|
|
249
253
|
applyCommitmentLedgerLifecycle
|
|
250
254
|
} from "./chunk-LMDRGRJ2.js";
|
|
@@ -263,7 +267,7 @@ import {
|
|
|
263
267
|
materializeAfterSemanticConsolidation,
|
|
264
268
|
parseConsolidationResponse,
|
|
265
269
|
parseOperatorAwareConsolidationResponse
|
|
266
|
-
} from "./chunk-
|
|
270
|
+
} from "./chunk-DMQWV6SQ.js";
|
|
267
271
|
import {
|
|
268
272
|
buildRecallQueryPolicy
|
|
269
273
|
} from "./chunk-LBJBNWS2.js";
|
|
@@ -304,7 +308,7 @@ import {
|
|
|
304
308
|
clusterByKey,
|
|
305
309
|
createCorrectionService,
|
|
306
310
|
detectPassiveCorrections
|
|
307
|
-
} from "./chunk-
|
|
311
|
+
} from "./chunk-AQLOP5F4.js";
|
|
308
312
|
import {
|
|
309
313
|
listTrustZoneRecords,
|
|
310
314
|
searchTrustZoneRecords
|
|
@@ -314,17 +318,11 @@ import {
|
|
|
314
318
|
} from "./chunk-FF4KLI5W.js";
|
|
315
319
|
import {
|
|
316
320
|
buildXraySnapshot
|
|
317
|
-
} from "./chunk-
|
|
318
|
-
import {
|
|
319
|
-
NamespaceSearchRouter
|
|
320
|
-
} from "./chunk-QR67FU5G.js";
|
|
321
|
-
import {
|
|
322
|
-
createConversationIndexRuntime,
|
|
323
|
-
createSearchBackend
|
|
324
|
-
} from "./chunk-HCVWF657.js";
|
|
321
|
+
} from "./chunk-DRUDC2UX.js";
|
|
325
322
|
import {
|
|
326
|
-
|
|
327
|
-
|
|
323
|
+
objectiveStateStoreOverrideForNamespace,
|
|
324
|
+
searchObjectiveStateSnapshots
|
|
325
|
+
} from "./chunk-6HMYUWXR.js";
|
|
328
326
|
import {
|
|
329
327
|
combineNamespaces,
|
|
330
328
|
getConfiguredNamespaces,
|
|
@@ -333,6 +331,16 @@ import {
|
|
|
333
331
|
resolveScopePlan,
|
|
334
332
|
resolveScopeProfilePlan
|
|
335
333
|
} from "./chunk-J6BH2OBA.js";
|
|
334
|
+
import {
|
|
335
|
+
NamespaceSearchRouter
|
|
336
|
+
} from "./chunk-CTOQEZSN.js";
|
|
337
|
+
import {
|
|
338
|
+
createConversationIndexRuntime,
|
|
339
|
+
createSearchBackend
|
|
340
|
+
} from "./chunk-2KAYTPPT.js";
|
|
341
|
+
import {
|
|
342
|
+
NoopSearchBackend
|
|
343
|
+
} from "./chunk-CYEPCZN5.js";
|
|
336
344
|
import {
|
|
337
345
|
namespaceIdentityFromToken,
|
|
338
346
|
namespaceIdentityToken,
|
|
@@ -344,10 +352,6 @@ import {
|
|
|
344
352
|
import {
|
|
345
353
|
parseQmdExplain
|
|
346
354
|
} from "./chunk-K43PI6DQ.js";
|
|
347
|
-
import {
|
|
348
|
-
objectiveStateStoreOverrideForNamespace,
|
|
349
|
-
searchObjectiveStateSnapshots
|
|
350
|
-
} from "./chunk-6HMYUWXR.js";
|
|
351
355
|
import {
|
|
352
356
|
ProfilingCollector
|
|
353
357
|
} from "./chunk-PNLCEFE4.js";
|
|
@@ -373,7 +377,7 @@ import {
|
|
|
373
377
|
} from "./chunk-TBBDFYXW.js";
|
|
374
378
|
import {
|
|
375
379
|
buildChainFollowupGenerator
|
|
376
|
-
} from "./chunk-
|
|
380
|
+
} from "./chunk-EY6MDMHK.js";
|
|
377
381
|
import {
|
|
378
382
|
ContentHashIndex,
|
|
379
383
|
StorageManager,
|
|
@@ -381,7 +385,7 @@ import {
|
|
|
381
385
|
fingerprintEntityStructuredFacts,
|
|
382
386
|
normalizeAttributePairs,
|
|
383
387
|
parseEntityFile
|
|
384
|
-
} from "./chunk-
|
|
388
|
+
} from "./chunk-7RLCCNHU.js";
|
|
385
389
|
import {
|
|
386
390
|
buildRetiredFactTombstoneInputs
|
|
387
391
|
} from "./chunk-L2B3EE7B.js";
|
|
@@ -395,6 +399,9 @@ import {
|
|
|
395
399
|
import {
|
|
396
400
|
assertPathInsideRoot
|
|
397
401
|
} from "./chunk-5GPPACXK.js";
|
|
402
|
+
import {
|
|
403
|
+
stripAttributesSuffix
|
|
404
|
+
} from "./chunk-SVOZFLIQ.js";
|
|
398
405
|
import {
|
|
399
406
|
applyTemporalSupersession,
|
|
400
407
|
normalizeSupersessionKey,
|
|
@@ -410,12 +417,9 @@ import {
|
|
|
410
417
|
hasCitationForTemplate,
|
|
411
418
|
stripCitationForTemplate
|
|
412
419
|
} from "./chunk-J6A3CX5N.js";
|
|
413
|
-
import {
|
|
414
|
-
stripAttributesSuffix
|
|
415
|
-
} from "./chunk-SVOZFLIQ.js";
|
|
416
420
|
import {
|
|
417
421
|
confidenceTier
|
|
418
|
-
} from "./chunk-
|
|
422
|
+
} from "./chunk-PUR2CKX2.js";
|
|
419
423
|
import {
|
|
420
424
|
buildQmdRecallCacheKey,
|
|
421
425
|
getCachedQmdRecall,
|
|
@@ -433,7 +437,7 @@ import {
|
|
|
433
437
|
applyFaithfulnessVerdict,
|
|
434
438
|
createFaithfulnessCounters,
|
|
435
439
|
runFaithfulnessGateBatch
|
|
436
|
-
} from "./chunk-
|
|
440
|
+
} from "./chunk-YTU7WKYN.js";
|
|
437
441
|
import {
|
|
438
442
|
FallbackLlmClient,
|
|
439
443
|
fallbackLlmRuntimeContextFromConfig,
|
|
@@ -3579,7 +3583,8 @@ var Orchestrator = class _Orchestrator {
|
|
|
3579
3583
|
* copy already carries.
|
|
3580
3584
|
*/
|
|
3581
3585
|
async backfillTemporalBoundsOnDedupHit(targetStorage, dedupContent, bounds, entityRef) {
|
|
3582
|
-
|
|
3586
|
+
const hasExtractedStart = bounds.validFrom !== void 0 && bounds.eventTimeSource === "extracted";
|
|
3587
|
+
if (!bounds.invalidAt && !hasExtractedStart) return;
|
|
3583
3588
|
try {
|
|
3584
3589
|
const incomingHash = ContentHashIndex.computeHash(dedupContent);
|
|
3585
3590
|
const normalizedIncoming = ContentHashIndex.normalizeContent(dedupContent);
|
|
@@ -3610,6 +3615,12 @@ var Orchestrator = class _Orchestrator {
|
|
|
3610
3615
|
if (bounds.eventTimeSource && (!fm.eventTimeSource || fm.eventTimeSource.length === 0)) {
|
|
3611
3616
|
patch.eventTimeSource = bounds.eventTimeSource;
|
|
3612
3617
|
}
|
|
3618
|
+
if (bounds.validFrom && bounds.eventTimeSource === "extracted" && fm.valid_at !== bounds.validFrom) {
|
|
3619
|
+
patch.valid_at = bounds.validFrom;
|
|
3620
|
+
if (fm.eventTimeSource !== "extracted") {
|
|
3621
|
+
patch.eventTimeSource = "extracted";
|
|
3622
|
+
}
|
|
3623
|
+
}
|
|
3613
3624
|
if (Object.keys(patch).length === 0) return;
|
|
3614
3625
|
const ok = await targetStorage.writeMemoryFrontmatter(existing, patch);
|
|
3615
3626
|
if (ok) {
|
|
@@ -11836,6 +11847,20 @@ ${normalized}`).digest("hex");
|
|
|
11836
11847
|
let dedupedCount = 0;
|
|
11837
11848
|
let importanceGatedCount = 0;
|
|
11838
11849
|
let batchBackendUnavailable = false;
|
|
11850
|
+
let redactionGatedCount = 0;
|
|
11851
|
+
const redactionRulesByDir = /* @__PURE__ */ new Map();
|
|
11852
|
+
const redactionRulesFor = async (...dirs) => {
|
|
11853
|
+
const out = [];
|
|
11854
|
+
for (const d of dirs) {
|
|
11855
|
+
let r = redactionRulesByDir.get(d);
|
|
11856
|
+
if (!r) {
|
|
11857
|
+
r = await loadRedactionRules(d);
|
|
11858
|
+
redactionRulesByDir.set(d, r);
|
|
11859
|
+
}
|
|
11860
|
+
out.push(...r);
|
|
11861
|
+
}
|
|
11862
|
+
return out;
|
|
11863
|
+
};
|
|
11839
11864
|
const behaviorSignalsByStorage = /* @__PURE__ */ new Map();
|
|
11840
11865
|
const trackBehaviorSignals = (targetStorage, events) => {
|
|
11841
11866
|
if (events.length === 0) return;
|
|
@@ -11917,12 +11942,14 @@ ${normalized}`).digest("hex");
|
|
|
11917
11942
|
const targetStorage = await this.storageRouter.storageFor(target.namespace);
|
|
11918
11943
|
if (targetStorage.dir === options.sourceStorage.dir) continue;
|
|
11919
11944
|
if (options.category === "fact" && await targetStorage.hasFactContentHash(dedupContent)) {
|
|
11920
|
-
if (options.invalidAt) {
|
|
11945
|
+
if (options.invalidAt || options.validAt) {
|
|
11921
11946
|
await this.backfillTemporalBoundsOnDedupHit(
|
|
11922
11947
|
targetStorage,
|
|
11923
11948
|
dedupContent,
|
|
11924
11949
|
{
|
|
11925
11950
|
invalidAt: options.invalidAt,
|
|
11951
|
+
// #1707 thread 2 — carry the corrected start bound.
|
|
11952
|
+
validFrom: options.validAt,
|
|
11926
11953
|
...options.observedAt ? { observedAt: options.observedAt } : {},
|
|
11927
11954
|
...options.eventTimeSource ? { eventTimeSource: options.eventTimeSource } : {}
|
|
11928
11955
|
},
|
|
@@ -12011,12 +12038,14 @@ ${normalized}`).digest("hex");
|
|
|
12011
12038
|
const dedupContent = options.category === "fact" && options.structuredAttributes && Object.keys(options.structuredAttributes).length > 0 ? `${sanitizedBase.text}
|
|
12012
12039
|
[Attributes: ${normalizeAttributePairs(options.structuredAttributes)}]` : sanitizedBase.text;
|
|
12013
12040
|
if (options.category === "fact" && await sharedStorage.hasFactContentHash(dedupContent)) {
|
|
12014
|
-
if (options.invalidAt) {
|
|
12041
|
+
if (options.invalidAt || options.validAt) {
|
|
12015
12042
|
await this.backfillTemporalBoundsOnDedupHit(
|
|
12016
12043
|
sharedStorage,
|
|
12017
12044
|
dedupContent,
|
|
12018
12045
|
{
|
|
12019
12046
|
invalidAt: options.invalidAt,
|
|
12047
|
+
// #1707 thread 2 — carry the corrected start bound.
|
|
12048
|
+
validFrom: options.validAt,
|
|
12020
12049
|
...options.observedAt ? { observedAt: options.observedAt } : {},
|
|
12021
12050
|
...options.eventTimeSource ? { eventTimeSource: options.eventTimeSource } : {}
|
|
12022
12051
|
},
|
|
@@ -12139,6 +12168,60 @@ ${normalized}`).digest("hex");
|
|
|
12139
12168
|
);
|
|
12140
12169
|
}
|
|
12141
12170
|
};
|
|
12171
|
+
const backfillTemporalBoundsOnPromotionCopies = async (args) => {
|
|
12172
|
+
const hasExtractedStart = args.bounds.validFrom !== void 0 && args.bounds.eventTimeSource === "extracted";
|
|
12173
|
+
if (!args.bounds.invalidAt && !hasExtractedStart) return;
|
|
12174
|
+
const rawContent = citationEnabled && hasCitationForTemplate(args.content, citationTemplate) ? stripCitationForTemplate(args.content, citationTemplate) : args.content;
|
|
12175
|
+
const sanitizedBase = sanitizeMemoryContent(rawContent);
|
|
12176
|
+
const dedupContent = args.category === "fact" && args.structuredAttributes && Object.keys(args.structuredAttributes).length > 0 ? `${sanitizedBase.text}
|
|
12177
|
+
[Attributes: ${normalizeAttributePairs(args.structuredAttributes)}]` : sanitizedBase.text;
|
|
12178
|
+
if (scopeProfileWritePlan) {
|
|
12179
|
+
const autoTargets = new Set(
|
|
12180
|
+
scopeProfileWritePlan.profile.autoPromote.targets
|
|
12181
|
+
);
|
|
12182
|
+
const profileTargets = scopeProfileWritePlan.promotionTargets.filter(
|
|
12183
|
+
(target) => target.target !== "serverShared" && autoTargets.has(target.target) && target.authorized && target.namespace
|
|
12184
|
+
);
|
|
12185
|
+
for (const target of profileTargets) {
|
|
12186
|
+
if (!target.namespace) continue;
|
|
12187
|
+
try {
|
|
12188
|
+
const targetStorage = await this.storageRouter.storageFor(
|
|
12189
|
+
target.namespace
|
|
12190
|
+
);
|
|
12191
|
+
if (targetStorage.dir === args.sourceStorage.dir) continue;
|
|
12192
|
+
await this.backfillTemporalBoundsOnDedupHit(
|
|
12193
|
+
targetStorage,
|
|
12194
|
+
dedupContent,
|
|
12195
|
+
args.bounds,
|
|
12196
|
+
args.entityRef
|
|
12197
|
+
);
|
|
12198
|
+
} catch (err) {
|
|
12199
|
+
log.warn(
|
|
12200
|
+
`bitemporal-backfill: profile-target backfill failed open for ${target.target}: ${err}`
|
|
12201
|
+
);
|
|
12202
|
+
}
|
|
12203
|
+
}
|
|
12204
|
+
}
|
|
12205
|
+
if (profileAllowsSharedWrites) {
|
|
12206
|
+
try {
|
|
12207
|
+
const sharedStorage = await this.storageRouter.storageFor(
|
|
12208
|
+
this.config.sharedNamespace
|
|
12209
|
+
);
|
|
12210
|
+
if (sharedStorage.dir !== args.sourceStorage.dir) {
|
|
12211
|
+
await this.backfillTemporalBoundsOnDedupHit(
|
|
12212
|
+
sharedStorage,
|
|
12213
|
+
dedupContent,
|
|
12214
|
+
args.bounds,
|
|
12215
|
+
args.entityRef
|
|
12216
|
+
);
|
|
12217
|
+
}
|
|
12218
|
+
} catch (err) {
|
|
12219
|
+
log.warn(
|
|
12220
|
+
`bitemporal-backfill: shared-target backfill failed open: ${err}`
|
|
12221
|
+
);
|
|
12222
|
+
}
|
|
12223
|
+
}
|
|
12224
|
+
};
|
|
12142
12225
|
if (!result || !Array.isArray(result.facts)) {
|
|
12143
12226
|
log.warn(
|
|
12144
12227
|
"persistExtraction: result or result.facts is invalid, skipping",
|
|
@@ -12227,6 +12310,11 @@ ${normalized}`).digest("hex");
|
|
|
12227
12310
|
let judgeGatedCount = 0;
|
|
12228
12311
|
this.lastPersistExtractionDeferredCount = 0;
|
|
12229
12312
|
if (this.config.extractionJudgeEnabled) {
|
|
12313
|
+
let preJudgeRedactionRules = [];
|
|
12314
|
+
try {
|
|
12315
|
+
preJudgeRedactionRules = await redactionRulesFor(storage.dir);
|
|
12316
|
+
} catch {
|
|
12317
|
+
}
|
|
12230
12318
|
try {
|
|
12231
12319
|
const judgeCandidates = [];
|
|
12232
12320
|
const candidateToFactIndex = [];
|
|
@@ -12251,6 +12339,10 @@ ${normalized}`).digest("hex");
|
|
|
12251
12339
|
)) {
|
|
12252
12340
|
continue;
|
|
12253
12341
|
}
|
|
12342
|
+
if (preJudgeRedactionRules.length > 0) {
|
|
12343
|
+
const rc = f.content + (f.structuredAttributes ? " " + JSON.stringify(f.structuredAttributes) : "") + (f.procedureSteps ? " " + f.procedureSteps.map((s) => `${s.intent} ${s.expectedOutcome ?? ""} ${s.toolCall ? `${s.toolCall.kind} ${s.toolCall.signature}` : ""}`.trim()).join(" ") : "");
|
|
12344
|
+
if (contentMatchesRedactionRules(rc, preJudgeRedactionRules)) continue;
|
|
12345
|
+
}
|
|
12254
12346
|
judgeCandidates.push({
|
|
12255
12347
|
text: f.content,
|
|
12256
12348
|
category: judgeCategory,
|
|
@@ -12359,6 +12451,7 @@ ${normalized}`).digest("hex");
|
|
|
12359
12451
|
const biTemporal = this.config.temporalBiTemporal && factAnchor ? resolveFactEventTime(fact.eventTime, factAnchor) : void 0;
|
|
12360
12452
|
let writeCategory = fact.category;
|
|
12361
12453
|
let targetStorage = storage;
|
|
12454
|
+
const sourceStorageDir = storage.dir;
|
|
12362
12455
|
let targetNamespaceName = baseNamespace && baseNamespace.length > 0 ? baseNamespace : this.storageDirNamespace(targetStorage.dir);
|
|
12363
12456
|
let routedRuleId;
|
|
12364
12457
|
let routedNamespaceExplicit = false;
|
|
@@ -12407,6 +12500,17 @@ ${normalized}`).digest("hex");
|
|
|
12407
12500
|
);
|
|
12408
12501
|
}
|
|
12409
12502
|
}
|
|
12503
|
+
try {
|
|
12504
|
+
const redactionRules = await redactionRulesFor(sourceStorageDir, targetStorage.dir);
|
|
12505
|
+
const redactionCandidate = fact.content + (fact.structuredAttributes ? " " + JSON.stringify(fact.structuredAttributes) : "") + (fact.procedureSteps ? " " + fact.procedureSteps.map((s) => `${s.intent} ${s.expectedOutcome ?? ""} ${s.toolCall ? `${s.toolCall.kind} ${s.toolCall.signature}` : ""}`.trim()).join(" ") : "");
|
|
12506
|
+
if (redactionRules.length > 0 && contentMatchesRedactionRules(redactionCandidate, redactionRules)) {
|
|
12507
|
+
redactionGatedCount++;
|
|
12508
|
+
log.debug(`extraction: redaction-rule withheld fact #${redactionGatedCount} in ${targetStorage.dir}`);
|
|
12509
|
+
continue;
|
|
12510
|
+
}
|
|
12511
|
+
} catch (redactionErr) {
|
|
12512
|
+
log.warn(`extraction: redaction-rule gate failed open: ${redactionErr}`);
|
|
12513
|
+
}
|
|
12410
12514
|
const canonicalContentForHash = citationEnabled && hasCitationForTemplate(fact.content, citationTemplate) ? stripCitationForTemplate(fact.content, citationTemplate) : fact.content;
|
|
12411
12515
|
const contentHashDedupKey = writeCategory === "procedure" ? buildProcedurePersistBody(fact.content, fact.procedureSteps) : canonicalContentForHash;
|
|
12412
12516
|
const importance = scoreImportance(
|
|
@@ -12426,7 +12530,7 @@ ${normalized}`).digest("hex");
|
|
|
12426
12530
|
);
|
|
12427
12531
|
}
|
|
12428
12532
|
if (exactDuplicate) {
|
|
12429
|
-
if (biTemporal && biTemporal.validUntil) {
|
|
12533
|
+
if (biTemporal && writeCategory === "fact" && (biTemporal.validUntil || biTemporal.validFrom)) {
|
|
12430
12534
|
const fr = faithfulnessResultsByFactIndex?.get(factLoopIndex);
|
|
12431
12535
|
const faithfulnessWouldPending = faithfulnessMode === "enforce" && fr?.ok === true && (fr.verdict === "unsupported" || fr.verdict === "contradicted");
|
|
12432
12536
|
const requireSpansWouldPending = this.config.provenance?.requireSpans === true && fact.requireSpansPending === true;
|
|
@@ -12438,11 +12542,27 @@ ${normalized}`).digest("hex");
|
|
|
12438
12542
|
contentHashDedupKey,
|
|
12439
12543
|
{
|
|
12440
12544
|
invalidAt: biTemporal.validUntil,
|
|
12545
|
+
// #1707 thread 2 — carry the corrected start bound too.
|
|
12546
|
+
validFrom: biTemporal.validFrom,
|
|
12441
12547
|
observedAt: biTemporal.observedAt,
|
|
12442
12548
|
eventTimeSource: biTemporal.eventTimeSource
|
|
12443
12549
|
},
|
|
12444
12550
|
fact.entityRef
|
|
12445
12551
|
);
|
|
12552
|
+
await backfillTemporalBoundsOnPromotionCopies({
|
|
12553
|
+
sourceStorage: targetStorage,
|
|
12554
|
+
content: fact.content,
|
|
12555
|
+
category: writeCategory,
|
|
12556
|
+
confidence: fact.confidence,
|
|
12557
|
+
entityRef: fact.entityRef,
|
|
12558
|
+
structuredAttributes: fact.structuredAttributes,
|
|
12559
|
+
bounds: {
|
|
12560
|
+
invalidAt: biTemporal.validUntil,
|
|
12561
|
+
validFrom: biTemporal.validFrom,
|
|
12562
|
+
observedAt: biTemporal.observedAt,
|
|
12563
|
+
eventTimeSource: biTemporal.eventTimeSource
|
|
12564
|
+
}
|
|
12565
|
+
});
|
|
12446
12566
|
}
|
|
12447
12567
|
}
|
|
12448
12568
|
log.debug(
|
|
@@ -13100,8 +13220,9 @@ ${normalized}`).digest("hex");
|
|
|
13100
13220
|
const dedupSuffix = dedupedCount > 0 ? ` (${dedupedCount} deduped)` : "";
|
|
13101
13221
|
const gatedSuffix = importanceGatedCount > 0 ? ` (${importanceGatedCount} gated)` : "";
|
|
13102
13222
|
const judgeSuffix = judgeGatedCount > 0 ? ` (${judgeGatedCount} judge-rejected)` : "";
|
|
13223
|
+
const redactionSuffix = redactionGatedCount > 0 ? ` (${redactionGatedCount} redacted)` : "";
|
|
13103
13224
|
log.info(
|
|
13104
|
-
`persisted: ${facts.length - dedupedCount - importanceGatedCount - judgeGatedCount} facts${dedupSuffix}${gatedSuffix}${judgeSuffix}, ${entities.length} entities, ${questions.length} questions, ${profileUpdates.length} profile updates`
|
|
13225
|
+
`persisted: ${facts.length - dedupedCount - importanceGatedCount - judgeGatedCount - redactionGatedCount} facts${dedupSuffix}${gatedSuffix}${judgeSuffix}${redactionSuffix}, ${entities.length} entities, ${questions.length} questions, ${profileUpdates.length} profile updates`
|
|
13105
13226
|
);
|
|
13106
13227
|
void (async () => {
|
|
13107
13228
|
if (persistedIdsByStorage.size === 0) {
|
|
@@ -16192,4 +16313,4 @@ export {
|
|
|
16192
16313
|
resolvePersistedMemoryRelativePath,
|
|
16193
16314
|
Orchestrator
|
|
16194
16315
|
};
|
|
16195
|
-
//# sourceMappingURL=chunk-
|
|
16316
|
+
//# sourceMappingURL=chunk-XPHVAOBT.js.map
|