@snoai/memory 0.0.0-stage → 1.0.1
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/LICENSE +176 -0
- package/README.md +33 -2
- package/config/b-profile-section-registry.json +118 -0
- package/config/llm/compiled/2026-05-19T230932Z/manifest.json +25 -0
- package/config/llm/compiled/2026-05-19T230932Z/registry-root.json +67 -0
- package/config/llm/compiled/2026-05-19T230932Z/resolved/mem_claw/openai_gpt_5_nano.json +5 -0
- package/config/llm/compiled/2026-05-19T230932Z/resolved/mem_claw/openrouter_auto.json +5 -0
- package/config/llm/compiled/2026-05-19T230932Z/resolved/mem_claw/sno_ai_extract.json +5 -0
- package/config/llm/compiled/2026-05-19T230932Z/source/mem_claw/openai_gpt_5_nano.mda +24 -0
- package/config/llm/compiled/2026-05-19T230932Z/source/mem_claw/openrouter_auto.mda +24 -0
- package/config/llm/compiled/2026-05-19T230932Z/source/mem_claw/sno_ai_extract.mda +24 -0
- package/config/llm/compiled/2026-07-21T001311Z/manifest.json +43 -0
- package/config/llm/compiled/2026-07-21T001311Z/registry-root.json +97 -0
- package/config/llm/compiled/2026-07-21T001311Z/resolved/mem_claw/openai_gpt_5_nano.json +5 -0
- package/config/llm/compiled/2026-07-21T001311Z/resolved/mem_claw/openrouter_auto.json +5 -0
- package/config/llm/compiled/2026-07-21T001311Z/resolved/mem_claw/sno_ai_extract.json +5 -0
- package/config/llm/compiled/2026-07-21T001311Z/resolved/mem_claw/sno_conflict_verdict.json +10 -0
- package/config/llm/compiled/2026-07-21T001311Z/resolved/mem_claw/sno_extract_chat.json +10 -0
- package/config/llm/compiled/2026-07-21T001311Z/resolved/mem_claw/sno_extract_profile.json +10 -0
- package/config/llm/compiled/2026-07-21T001311Z/source/mem_claw/openai_gpt_5_nano.mda +24 -0
- package/config/llm/compiled/2026-07-21T001311Z/source/mem_claw/openrouter_auto.mda +24 -0
- package/config/llm/compiled/2026-07-21T001311Z/source/mem_claw/sno_ai_extract.mda +24 -0
- package/config/llm/compiled/2026-07-21T001311Z/source/mem_claw/sno_conflict_verdict.mda +27 -0
- package/config/llm/compiled/2026-07-21T001311Z/source/mem_claw/sno_extract_chat.mda +27 -0
- package/config/llm/compiled/2026-07-21T001311Z/source/mem_claw/sno_extract_profile.mda +27 -0
- package/config/llm/compiled/2026-08-29T060335Z/manifest.json +43 -0
- package/config/llm/compiled/2026-08-29T060335Z/registry-root.json +97 -0
- package/config/llm/compiled/2026-08-29T060335Z/resolved/mem_claw/openai_gpt_5_nano.json +5 -0
- package/config/llm/compiled/2026-08-29T060335Z/resolved/mem_claw/openrouter_auto.json +5 -0
- package/config/llm/compiled/2026-08-29T060335Z/resolved/mem_claw/sno_ai_extract.json +5 -0
- package/config/llm/compiled/2026-08-29T060335Z/resolved/mem_claw/sno_conflict_verdict.json +10 -0
- package/config/llm/compiled/2026-08-29T060335Z/resolved/mem_claw/sno_extract_chat.json +10 -0
- package/config/llm/compiled/2026-08-29T060335Z/resolved/mem_claw/sno_extract_profile.json +10 -0
- package/config/llm/compiled/2026-08-29T060335Z/source/mem_claw/openai_gpt_5_nano.mda +24 -0
- package/config/llm/compiled/2026-08-29T060335Z/source/mem_claw/openrouter_auto.mda +24 -0
- package/config/llm/compiled/2026-08-29T060335Z/source/mem_claw/sno_ai_extract.mda +24 -0
- package/config/llm/compiled/2026-08-29T060335Z/source/mem_claw/sno_conflict_verdict.mda +27 -0
- package/config/llm/compiled/2026-08-29T060335Z/source/mem_claw/sno_extract_chat.mda +27 -0
- package/config/llm/compiled/2026-08-29T060335Z/source/mem_claw/sno_extract_profile.mda +27 -0
- package/config/llm/compiled/2026-09-04T004828Z/manifest.json +43 -0
- package/config/llm/compiled/2026-09-04T004828Z/registry-root.json +97 -0
- package/config/llm/compiled/2026-09-04T004828Z/resolved/mem_claw/openai_gpt_5_nano.json +5 -0
- package/config/llm/compiled/2026-09-04T004828Z/resolved/mem_claw/openrouter_auto.json +5 -0
- package/config/llm/compiled/2026-09-04T004828Z/resolved/mem_claw/sno_ai_extract.json +5 -0
- package/config/llm/compiled/2026-09-04T004828Z/resolved/mem_claw/sno_conflict_verdict.json +10 -0
- package/config/llm/compiled/2026-09-04T004828Z/resolved/mem_claw/sno_extract_chat.json +10 -0
- package/config/llm/compiled/2026-09-04T004828Z/resolved/mem_claw/sno_extract_profile.json +10 -0
- package/config/llm/compiled/2026-09-04T004828Z/source/mem_claw/openai_gpt_5_nano.mda +24 -0
- package/config/llm/compiled/2026-09-04T004828Z/source/mem_claw/openrouter_auto.mda +24 -0
- package/config/llm/compiled/2026-09-04T004828Z/source/mem_claw/sno_ai_extract.mda +24 -0
- package/config/llm/compiled/2026-09-04T004828Z/source/mem_claw/sno_conflict_verdict.mda +27 -0
- package/config/llm/compiled/2026-09-04T004828Z/source/mem_claw/sno_extract_chat.mda +27 -0
- package/config/llm/compiled/2026-09-04T004828Z/source/mem_claw/sno_extract_profile.mda +27 -0
- package/config/llm/current.json +4 -0
- package/config/llm/source/mem_claw/openai_gpt_5_nano.mda +24 -0
- package/config/llm/source/mem_claw/openrouter_auto.mda +24 -0
- package/config/llm/source/mem_claw/sno_ai_extract.mda +24 -0
- package/config/llm/source/mem_claw/sno_conflict_verdict.mda +27 -0
- package/config/llm/source/mem_claw/sno_extract_chat.mda +27 -0
- package/config/llm/source/mem_claw/sno_extract_profile.mda +27 -0
- package/config/llm.trust.json +37 -0
- package/dist/_types-CUKHSRkS.d.ts +103 -0
- package/dist/access-tracker-BbEvEocb.d.ts +110 -0
- package/dist/adapter-B7Jox9-6.d.ts +69 -0
- package/dist/adapter-XaRHZWZ2.js +333 -0
- package/dist/agent-llm-port-5oXgBpzJ.d.ts +53 -0
- package/dist/all-resources-BQK2ugjB.js +6379 -0
- package/dist/all-resources-Dij6l5h0.d.ts +18 -0
- package/dist/ambient-learning-text-normalizer-CxjATmMp.js +170 -0
- package/dist/ambient-learning-text-normalizer-_fH3LeuK.d.ts +10 -0
- package/dist/atomic-extraction-reply-BJ9XV_9s.js +863 -0
- package/dist/atomic-extraction-skill-CcXmuCqL.js +56 -0
- package/dist/atomic-memory-extraction-C5rmogoY.js +3605 -0
- package/dist/atomic-memory-extraction-d9EG-4ti.d.ts +327 -0
- package/dist/b-profile-section-dictionary-provider-BHkoNqgk.js +1812 -0
- package/dist/b-profile-section-dictionary-provider-BxbksLj3.d.ts +62 -0
- package/dist/best-effort-BPZSzKk0.d.ts +9 -0
- package/dist/calendar-instruction-CzqZbAPG.js +194 -0
- package/dist/capture-policy-detector-CxbHPkMX.d.ts +53 -0
- package/dist/capture-policy-detector-DaMfy9CZ.js +357 -0
- package/dist/classifier-DnbbtwTS.d.ts +272 -0
- package/dist/client.d.ts +34 -0
- package/dist/client.js +306 -0
- package/dist/coding-skin.d.ts +51 -0
- package/dist/coding-skin.js +55 -0
- package/dist/config-CL90qYva.js +2576 -0
- package/dist/connection-3IVXpuPE.d.ts +391 -0
- package/dist/connection-C9YD5sgm.js +297 -0
- package/dist/daily-log-generator-CH_KuWHs.js +469 -0
- package/dist/daily-log-generator-CsQPHl4A.d.ts +73 -0
- package/dist/daily-spend-estimator-DiwzBlo1.d.ts +8 -0
- package/dist/data-bootstrap-Bl3lthzE.d.ts +30 -0
- package/dist/data-bootstrap-P8sie9WA.js +172 -0
- package/dist/data-paths-C7sNdqvP.d.ts +22 -0
- package/dist/derived-suppression-cache-CI0durYx.d.ts +36 -0
- package/dist/diagnostic-encoder.d.ts +6 -0
- package/dist/diagnostic-encoder.js +29 -0
- package/dist/embedding-provider-client-Q_hJonK9.js +294 -0
- package/dist/embedding-provider-client-vynZMuit.d.ts +94 -0
- package/dist/entry-metadata-parser-BIVSMCIk.js +20 -0
- package/dist/error-D-wb-rZw.js +23 -0
- package/dist/error-signals-D8_3vYu4.d.ts +28 -0
- package/dist/error-signals-lMH2uAdV.js +134 -0
- package/dist/errors-CeVRxf9V.d.ts +49 -0
- package/dist/extraction-text-sanitizer-B_AhIecT.d.ts +32 -0
- package/dist/i18n-text-DbD6Qify.d.ts +13 -0
- package/dist/index-0aqS8pVF.d.ts +351 -0
- package/dist/index-BO4RU_mc.d.ts +650 -0
- package/dist/index-DL8AVj0Z.d.ts +571 -0
- package/dist/index.d.ts +65 -0
- package/dist/index.js +1201 -0
- package/dist/intent-analyzer-B5XVrWwe.d.ts +28 -0
- package/dist/internal/config/index.d.ts +2 -0
- package/dist/internal/config/index.js +581 -0
- package/dist/internal/config/plugin-config-schema.d.ts +2 -0
- package/dist/internal/config/plugin-config-schema.js +2 -0
- package/dist/internal/config/product-mode.d.ts +2 -0
- package/dist/internal/config/product-mode.js +36 -0
- package/dist/internal/config/settings.d.ts +2 -0
- package/dist/internal/config/settings.js +265 -0
- package/dist/internal/config/skill-categories.d.ts +4 -0
- package/dist/internal/config/skill-categories.js +68 -0
- package/dist/internal/config/skin-defaults.d.ts +6 -0
- package/dist/internal/config/skin-defaults.js +6 -0
- package/dist/internal/contract/discovery.d.ts +10 -0
- package/dist/internal/contract/discovery.js +53 -0
- package/dist/internal/contract/profile.d.ts +2 -0
- package/dist/internal/contract/profile.js +44 -0
- package/dist/internal/contract/routes.d.ts +2 -0
- package/dist/internal/contract/routes.js +62 -0
- package/dist/internal/engine/bindings/memory-cli-shared.d.ts +47 -0
- package/dist/internal/engine/bindings/memory-cli-shared.js +84 -0
- package/dist/internal/engine/bindings/memory-forget-tool.d.ts +5 -0
- package/dist/internal/engine/bindings/memory-forget-tool.js +66 -0
- package/dist/internal/engine/bindings/memory-list-tool.d.ts +5 -0
- package/dist/internal/engine/bindings/memory-list-tool.js +57 -0
- package/dist/internal/engine/bindings/memory-recall-tool.d.ts +10 -0
- package/dist/internal/engine/bindings/memory-recall-tool.js +283 -0
- package/dist/internal/engine/bindings/memory-reflection-resolve-tool.d.ts +5 -0
- package/dist/internal/engine/bindings/memory-reflection-resolve-tool.js +150 -0
- package/dist/internal/engine/bindings/memory-stats-tool.d.ts +5 -0
- package/dist/internal/engine/bindings/memory-stats-tool.js +43 -0
- package/dist/internal/engine/bindings/memory-store-tool.d.ts +5 -0
- package/dist/internal/engine/bindings/memory-store-tool.js +165 -0
- package/dist/internal/engine/bindings/memory-tool-access.d.ts +16 -0
- package/dist/internal/engine/bindings/memory-tool-access.js +46 -0
- package/dist/internal/engine/bindings/memory-tool-formatting.d.ts +62 -0
- package/dist/internal/engine/bindings/memory-tool-formatting.js +106 -0
- package/dist/internal/engine/bindings/memory-tool-results.d.ts +8 -0
- package/dist/internal/engine/bindings/memory-tool-results.js +41 -0
- package/dist/internal/engine/bindings/memory-tool-schemas.d.ts +109 -0
- package/dist/internal/engine/bindings/memory-tool-schemas.js +75 -0
- package/dist/internal/engine/bindings/memory-update-tool.d.ts +5 -0
- package/dist/internal/engine/bindings/memory-update-tool.js +127 -0
- package/dist/internal/engine/bindings/sno-station-mem-ambient-learning-hook.d.ts +14 -0
- package/dist/internal/engine/bindings/sno-station-mem-ambient-learning-hook.js +248 -0
- package/dist/internal/engine/bindings/sno-station-mem-auto-recall-hook.d.ts +12 -0
- package/dist/internal/engine/bindings/sno-station-mem-auto-recall-hook.js +324 -0
- package/dist/internal/engine/bindings/sno-station-mem-hook-types.d.ts +56 -0
- package/dist/internal/engine/bindings/sno-station-mem-hook-types.js +1 -0
- package/dist/internal/engine/bindings/sno-station-mem-insight-distill-factory.d.ts +14 -0
- package/dist/internal/engine/bindings/sno-station-mem-insight-distill-factory.js +119 -0
- package/dist/internal/engine/bindings/sno-station-mem-message-transcript.d.ts +52 -0
- package/dist/internal/engine/bindings/sno-station-mem-message-transcript.js +145 -0
- package/dist/internal/engine/bindings/sno-station-mem-reset-hook.d.ts +10 -0
- package/dist/internal/engine/bindings/sno-station-mem-reset-hook.js +9 -0
- package/dist/internal/engine/bindings/sno-station-mem-runtime-mode.d.ts +36 -0
- package/dist/internal/engine/bindings/sno-station-mem-runtime-mode.js +104 -0
- package/dist/internal/engine/bindings/sno-station-mem-session-state.d.ts +10 -0
- package/dist/internal/engine/bindings/sno-station-mem-session-state.js +27 -0
- package/dist/internal/engine/eval/trace.d.ts +2 -0
- package/dist/internal/engine/eval/trace.js +151 -0
- package/dist/internal/engine/extraction/ambient-learning-text-normalizer.d.ts +2 -0
- package/dist/internal/engine/extraction/ambient-learning-text-normalizer.js +2 -0
- package/dist/internal/engine/extraction/atomic-memory-extraction.d.ts +2 -0
- package/dist/internal/engine/extraction/atomic-memory-extraction.js +2 -0
- package/dist/internal/engine/extraction/b-profile-section-dictionary-provider.d.ts +2 -0
- package/dist/internal/engine/extraction/b-profile-section-dictionary-provider.js +2 -0
- package/dist/internal/engine/extraction/b-profile-section-rekey.d.ts +49 -0
- package/dist/internal/engine/extraction/b-profile-section-rekey.js +730 -0
- package/dist/internal/engine/extraction/capture-policy-detector.d.ts +2 -0
- package/dist/internal/engine/extraction/capture-policy-detector.js +2 -0
- package/dist/internal/engine/extraction/embedding-provider-client.d.ts +2 -0
- package/dist/internal/engine/extraction/embedding-provider-client.js +2 -0
- package/dist/internal/engine/extraction/extraction-text-sanitizer.d.ts +2 -0
- package/dist/internal/engine/extraction/extraction-text-sanitizer.js +114 -0
- package/dist/internal/engine/extraction/memory-metadata-codec.d.ts +3 -0
- package/dist/internal/engine/extraction/memory-metadata-codec.js +2 -0
- package/dist/internal/engine/extraction/memory-temporality-classifier.d.ts +2 -0
- package/dist/internal/engine/extraction/memory-temporality-classifier.js +2 -0
- package/dist/internal/engine/i18n/all-resources.d.ts +2 -0
- package/dist/internal/engine/i18n/all-resources.js +2 -0
- package/dist/internal/engine/i18n/locales.d.ts +2 -0
- package/dist/internal/engine/i18n/locales.js +19 -0
- package/dist/internal/engine/i18n/res/_types.d.ts +2 -0
- package/dist/internal/engine/i18n/res/_types.js +11 -0
- package/dist/internal/engine/observability/adapter.d.ts +2 -0
- package/dist/internal/engine/observability/adapter.js +2 -0
- package/dist/internal/engine/observability/best-effort.d.ts +2 -0
- package/dist/internal/engine/observability/best-effort.js +41 -0
- package/dist/internal/engine/observability/early-diagnostics.js +2 -0
- package/dist/internal/engine/observability/memory-snapshot.d.ts +2 -0
- package/dist/internal/engine/observability/memory-snapshot.js +44 -0
- package/dist/internal/engine/observability/observable-embedder.d.ts +2 -0
- package/dist/internal/engine/observability/observable-embedder.js +43 -0
- package/dist/internal/engine/observability/observable-llm-client.d.ts +2 -0
- package/dist/internal/engine/observability/observable-llm-client.js +98 -0
- package/dist/internal/engine/observability/observable-memory-store.d.ts +2 -0
- package/dist/internal/engine/observability/observable-memory-store.js +701 -0
- package/dist/internal/engine/observability/observable-retriever.d.ts +2 -0
- package/dist/internal/engine/observability/observable-retriever.js +95 -0
- package/dist/internal/engine/observability/runtime-diagnostics.d.ts +13 -0
- package/dist/internal/engine/observability/runtime-diagnostics.js +96 -0
- package/dist/internal/engine/observability/session-registry.d.ts +2 -0
- package/dist/internal/engine/observability/session-registry.js +58 -0
- package/dist/internal/engine/observability/version-metadata.d.ts +7 -0
- package/dist/internal/engine/observability/version-metadata.js +59 -0
- package/dist/internal/engine/operations/daily-spend-estimator.d.ts +2 -0
- package/dist/internal/engine/operations/daily-spend-estimator.js +97 -0
- package/dist/internal/engine/operations/learning-file-maintenance.d.ts +2 -0
- package/dist/internal/engine/operations/learning-file-maintenance.js +255 -0
- package/dist/internal/engine/operations/memory-tier-promoter.d.ts +2 -0
- package/dist/internal/engine/operations/memory-tier-promoter.js +95 -0
- package/dist/internal/engine/operations/runtime-audit-log.d.ts +3 -0
- package/dist/internal/engine/operations/runtime-audit-log.js +3 -0
- package/dist/internal/engine/provider/canonical-memory-corpus.d.ts +38 -0
- package/dist/internal/engine/provider/canonical-memory-corpus.js +253 -0
- package/dist/internal/engine/provider/provider-registration.d.ts +39 -0
- package/dist/internal/engine/provider/provider-registration.js +2 -0
- package/dist/internal/engine/provider/provider-row-renderer.d.ts +7 -0
- package/dist/internal/engine/provider/provider-row-renderer.js +53 -0
- package/dist/internal/engine/provider/provider-types.d.ts +2 -0
- package/dist/internal/engine/provider/provider-types.js +1 -0
- package/dist/internal/engine/reflection/daily-log-generator.d.ts +2 -0
- package/dist/internal/engine/reflection/daily-log-generator.js +2 -0
- package/dist/internal/engine/reflection/reflection-command-hooks.d.ts +2 -0
- package/dist/internal/engine/reflection/reflection-command-hooks.js +2 -0
- package/dist/internal/engine/reflection/reflection-deps.d.ts +2 -0
- package/dist/internal/engine/reflection/reflection-deps.js +1 -0
- package/dist/internal/engine/reflection/reflection-embedded-generator.d.ts +2 -0
- package/dist/internal/engine/reflection/reflection-embedded-generator.js +2 -0
- package/dist/internal/engine/reflection/reflection-injection-hooks.d.ts +2 -0
- package/dist/internal/engine/reflection/reflection-injection-hooks.js +219 -0
- package/dist/internal/engine/reflection/reflection-lifecycle-hooks.d.ts +2 -0
- package/dist/internal/engine/reflection/reflection-lifecycle-hooks.js +63 -0
- package/dist/internal/engine/reflection/strategy-hook-runner.d.ts +4 -0
- package/dist/internal/engine/reflection/strategy-hook-runner.js +3 -0
- package/dist/internal/engine/rem/classifier.d.ts +2 -0
- package/dist/internal/engine/rem/classifier.js +180 -0
- package/dist/internal/engine/rem/index.d.ts +4 -0
- package/dist/internal/engine/rem/index.js +2551 -0
- package/dist/internal/engine/rem/types.d.ts +2 -0
- package/dist/internal/engine/rem/types.js +40 -0
- package/dist/internal/engine/retrieval/access-tracker.d.ts +2 -0
- package/dist/internal/engine/retrieval/access-tracker.js +314 -0
- package/dist/internal/engine/retrieval/intent-analyzer.d.ts +2 -0
- package/dist/internal/engine/retrieval/intent-analyzer.js +27 -0
- package/dist/internal/engine/retrieval/retrieval-gate.d.ts +2 -0
- package/dist/internal/engine/retrieval/retrieval-gate.js +47 -0
- package/dist/internal/engine/retrieval/retriever.d.ts +2 -0
- package/dist/internal/engine/retrieval/retriever.js +2 -0
- package/dist/internal/engine/security/memory-scope-policy.d.ts +2 -0
- package/dist/internal/engine/security/memory-scope-policy.js +2 -0
- package/dist/internal/engine/security/redact.d.ts +2 -0
- package/dist/internal/engine/security/redact.js +34 -0
- package/dist/internal/engine/security/scopes.d.ts +3 -0
- package/dist/internal/engine/security/scopes.js +3 -0
- package/dist/internal/engine/shared/errors.d.ts +2 -0
- package/dist/internal/engine/shared/errors.js +66 -0
- package/dist/internal/engine/shared/i18n-text.d.ts +2 -0
- package/dist/internal/engine/shared/i18n-text.js +58 -0
- package/dist/internal/engine/shared/iso-date-time.d.ts +16 -0
- package/dist/internal/engine/shared/iso-date-time.js +40 -0
- package/dist/internal/engine/shared/lru.d.ts +2 -0
- package/dist/internal/engine/shared/lru.js +30 -0
- package/dist/internal/engine/shared/memory-kind-policy.d.ts +2 -0
- package/dist/internal/engine/shared/memory-kind-policy.js +64 -0
- package/dist/internal/engine/shared/paths.d.ts +3 -0
- package/dist/internal/engine/shared/paths.js +2 -0
- package/dist/internal/engine/shared/types.d.ts +3 -0
- package/dist/internal/engine/shared/types.js +25 -0
- package/dist/internal/engine/shared/utils.d.ts +2 -0
- package/dist/internal/engine/shared/utils.js +175 -0
- package/dist/internal/engine/telemetry/memory-telemetry-api.d.ts +134 -0
- package/dist/internal/engine/telemetry/memory-telemetry-api.js +730 -0
- package/dist/internal/engine/telemetry/memory-telemetry-observability.d.ts +24 -0
- package/dist/internal/engine/telemetry/memory-telemetry-observability.js +133 -0
- package/dist/internal/engine/telemetry/memory-telemetry-outbox.d.ts +2 -0
- package/dist/internal/engine/telemetry/memory-telemetry-outbox.js +443 -0
- package/dist/internal/engine/telemetry/memory-telemetry-types.d.ts +2 -0
- package/dist/internal/engine/telemetry/memory-telemetry-types.js +21 -0
- package/dist/internal/engine/telemetry/observe-ledger.d.ts +30 -0
- package/dist/internal/engine/telemetry/observe-ledger.js +111 -0
- package/dist/internal/model/agent-llm-port.d.ts +2 -0
- package/dist/internal/model/agent-llm-port.js +1 -0
- package/dist/internal/model/llm-client.d.ts +3 -0
- package/dist/internal/model/llm-client.js +3 -0
- package/dist/internal/model/llm-failure.d.ts +26 -0
- package/dist/internal/model/llm-failure.js +63 -0
- package/dist/internal/model/llm-mode-routing.d.ts +22 -0
- package/dist/internal/model/llm-mode-routing.js +37 -0
- package/dist/internal/store/atomic-memory-cutover-sql.d.ts +13 -0
- package/dist/internal/store/atomic-memory-cutover-sql.js +237 -0
- package/dist/internal/store/connection.d.ts +2 -0
- package/dist/internal/store/connection.js +2 -0
- package/dist/internal/store/data-bootstrap.d.ts +2 -0
- package/dist/internal/store/data-bootstrap.js +2 -0
- package/dist/internal/store/data-paths.d.ts +2 -0
- package/dist/internal/store/data-paths.js +65 -0
- package/dist/internal/store/maintenance.d.ts +75 -0
- package/dist/internal/store/maintenance.js +1401 -0
- package/dist/internal/store/memory-kinds-cutover-migrator.d.ts +28 -0
- package/dist/internal/store/memory-kinds-cutover-migrator.js +415 -0
- package/dist/internal/store/migrations.d.ts +27 -0
- package/dist/internal/store/migrations.js +201 -0
- package/dist/internal/store/sqlite-runtime.d.ts +2 -0
- package/dist/internal/store/sqlite-runtime.js +109 -0
- package/dist/internal/store/store.d.ts +3 -0
- package/dist/internal/store/store.js +2 -0
- package/dist/learning-file-maintenance-9b-Ut6Kv.d.ts +30 -0
- package/dist/llm-client-BSYUAcUb.js +1374 -0
- package/dist/llm-client-DOTSGzhe.d.ts +51 -0
- package/dist/locales-JxGmkG6t.d.ts +7 -0
- package/dist/log-site-catalog.generated-BMKWj-Nx.js +2321 -0
- package/dist/log-site-catalog.json +1 -0
- package/dist/lru-DyoaTyIs.d.ts +14 -0
- package/dist/memdump.d.ts +52 -0
- package/dist/memdump.js +163 -0
- package/dist/memory-entry-projector-DHo8jH10.js +1015 -0
- package/dist/memory-kind-policy-BiuRjSJc.d.ts +23 -0
- package/dist/memory-metadata-codec-DL1sbJiN.js +577 -0
- package/dist/memory-metadata-codec-DUvsYe_X.d.ts +68 -0
- package/dist/memory-runtime-DqUS4cWi.js +19459 -0
- package/dist/memory-scope-policy-1gg5QlWZ.d.ts +67 -0
- package/dist/memory-scope-policy-DICSCURA.js +283 -0
- package/dist/memory-snapshot-CqY1BUUA.d.ts +16 -0
- package/dist/memory-source-order-YMRoeDLd.js +134 -0
- package/dist/memory-store-base-CQ_bHlYA.d.ts +1094 -0
- package/dist/memory-store-shared-DqpWJXZZ.js +158 -0
- package/dist/memory-store-write-validation-B_hDG2zf.js +243 -0
- package/dist/memory-telemetry-incidents-BWA9kcZx.js +8 -0
- package/dist/memory-telemetry-metadata-CA7W8tK6.js +77 -0
- package/dist/memory-telemetry-outbox-ddTdImt7.d.ts +74 -0
- package/dist/memory-telemetry-receipts-MAJecvXQ.d.ts +34 -0
- package/dist/memory-telemetry-receipts-YsxbwOAf.js +91 -0
- package/dist/memory-telemetry-types-CufVmrCs.d.ts +14 -0
- package/dist/memory-temporality-classifier-BUjXG5o7.js +184 -0
- package/dist/memory-temporality-classifier-Brht5jyK.d.ts +43 -0
- package/dist/memory-tier-promoter-CqGxCkue.d.ts +43 -0
- package/dist/memory-tool-dependencies-CatGzI9R.d.ts +14 -0
- package/dist/memory-tool-dependencies-DjUoelnm.js +19 -0
- package/dist/model-call-table-CspopkBg.js +563 -0
- package/dist/model-reply-text-CKopStP2.js +334 -0
- package/dist/observable-embedder-CNNe9gkg.d.ts +17 -0
- package/dist/observable-llm-client-CRuKlefQ.d.ts +21 -0
- package/dist/observable-memory-store-CnGDpOY5.d.ts +73 -0
- package/dist/observable-retriever-Cooc62Qw.d.ts +23 -0
- package/dist/operation-cancellation-CTKWwNHk.js +81 -0
- package/dist/paths-qVF-5uBq.d.ts +1 -0
- package/dist/plugin-config-schema-C0UUbOmG.d.ts +413 -0
- package/dist/plugin-config-schema-YJLyIIcJ.js +361 -0
- package/dist/profile-TWPJ_myr.d.ts +13 -0
- package/dist/profile-section-writer-BhGKPBjw.js +2149 -0
- package/dist/provider-registration-CF1tg8Xy.js +721 -0
- package/dist/provider-runtime-types-DFhtdA6d.d.ts +134 -0
- package/dist/provider-types-CZGm6v88.d.ts +23 -0
- package/dist/redact-BTIZcHQL.d.ts +5 -0
- package/dist/reflection-command-hooks-ClUl-iv6.js +644 -0
- package/dist/reflection-command-hooks-G1-dI2Av.d.ts +32 -0
- package/dist/reflection-deps-Ccm2Jf5W.d.ts +19 -0
- package/dist/reflection-embedded-generator-BRvqV5N-.js +130 -0
- package/dist/reflection-embedded-generator-kfQfKEYV.d.ts +14 -0
- package/dist/reflection-injection-hooks-CS_uhjoD.d.ts +43 -0
- package/dist/reflection-lifecycle-hooks-CRSpUdLi.d.ts +27 -0
- package/dist/relation-dictionary-Cev1kyLe.js +4248 -0
- package/dist/release-download.d.ts +8 -0
- package/dist/release-download.js +32 -0
- package/dist/relevant-memories-context-m8nuFZcM.js +23 -0
- package/dist/rem-batch-executor-Dg2HgROM.js +2 -0
- package/dist/rem-batch-executor-DuC4nYyf.js +31640 -0
- package/dist/rem-consumer-retrieval-CR0dtcHR.js +246 -0
- package/dist/rem-trigger-Hn6od8IV.js +730 -0
- package/dist/resolver-Dy-hnjCR.js +103 -0
- package/dist/results-C3ZLroMb.js +140 -0
- package/dist/retrieval-gate-Bx2Zg7jD.d.ts +31 -0
- package/dist/retriever-Dxss5fRv.d.ts +469 -0
- package/dist/retriever-ZoLvPRHq.js +1757 -0
- package/dist/rolldown-runtime-D7D4PA-g.js +13 -0
- package/dist/routes-DLHT__Ay.js +60 -0
- package/dist/runtime-audit-log-BCeujlEp.js +430 -0
- package/dist/runtime-audit-log-zpQiR9HT.d.ts +149 -0
- package/dist/scopes-CSOn6zdd.js +71 -0
- package/dist/scopes-CtrY-YQ3.d.ts +23 -0
- package/dist/server-CSvxchqg.js +1412 -0
- package/dist/session-registry-DBoE7AvZ.d.ts +14 -0
- package/dist/sidecar/main.d.ts +1 -0
- package/dist/sidecar/main.js +56 -0
- package/dist/signed-registry-constants-Bv0fgZ8Q.d.ts +12 -0
- package/dist/signed-registry-constants-yq3DlG3B.js +82 -0
- package/dist/sno-station-mem-runtime-dependencies-CoWqUMbK.js +30 -0
- package/dist/sno-station-mem-runtime-dependencies-DHESIuPn.d.ts +31 -0
- package/dist/sqlite-runtime-L_ywirTm.d.ts +58 -0
- package/dist/store-C8sUTssE.d.ts +27 -0
- package/dist/store-nPql26YM.js +5830 -0
- package/dist/strategy-hook-runner-Bxy851Xx.d.ts +16 -0
- package/dist/strategy-hook-runner-Djify5Rw.js +110 -0
- package/dist/token-counter-BD1f48Km.js +73 -0
- package/dist/trace-C1JxMfs-.d.ts +86 -0
- package/dist/types-CWdhXLxr.d.ts +477 -0
- package/dist/types-pVomjzqR.d.ts +132 -0
- package/dist/unplaced-candidate-migration-CbQHzcEM.js +940 -0
- package/dist/utils-Ctb9aevJ.d.ts +34 -0
- package/drizzle/0000_initial.sql +10 -0
- package/drizzle/0001_virtual_tables.sql +34 -0
- package/drizzle/0002_add_indexes.sql +11 -0
- package/drizzle/0003_content_hash_lookup_index.sql +2 -0
- package/drizzle/0004_chunk_swap.sql +60 -0
- package/drizzle/0005_drop_legacy_vec_fts.sql +10 -0
- package/drizzle/0006_fts_simple.sql +45 -0
- package/drizzle/0007_restore_simple_fts.sql +40 -0
- package/drizzle/0008_widen_memory_hash_unique_index.sql +4 -0
- package/drizzle/0009_memory_telemetry.sql +109 -0
- package/drizzle/0010_provider_mappings.sql +27 -0
- package/drizzle/0011_db_optimization.sql +82 -0
- package/drizzle/0012_b_profile_lanes.sql +9 -0
- package/drizzle/0013_extraction_timestamps.sql +6 -0
- package/drizzle/0014_extraction_timestamp_source.sql +3 -0
- package/drizzle/0015_task_lifecycle_state.sql +101 -0
- package/drizzle/0016_task_lifecycle_legacy_migration.sql +144 -0
- package/drizzle/0017_unplaced_candidates.sql +15 -0
- package/drizzle/0018_rem_batch_chassis.sql +71 -0
- package/drizzle/0019_profile_recovery_entries.sql +17 -0
- package/drizzle/0020_rem_scan_retry_progress.down.sql +14 -0
- package/drizzle/0020_rem_scan_retry_progress.sql +24 -0
- package/drizzle/0021_rem_two_facet_storage.down.sql +14 -0
- package/drizzle/0021_rem_two_facet_storage.sql +42 -0
- package/drizzle/0022_rem_facet_chunk_versions.down.sql +4 -0
- package/drizzle/0022_rem_facet_chunk_versions.sql +4 -0
- package/drizzle/0023_rem_defect_ledger.sql +40 -0
- package/drizzle/0024_rem_unbuilt_foundations.down.sql +13 -0
- package/drizzle/0024_rem_unbuilt_foundations.sql +65 -0
- package/drizzle/0025_rem_journal_operation_constraint.sql +28 -0
- package/drizzle/0026_rem_journal_detail.sql +1 -0
- package/drizzle/0027_legacy_nodix_namespace.sql +3 -0
- package/drizzle/0028_memory_timezone.sql +23 -0
- package/drizzle/0029_rem_write_hash_symmetry.sql +17 -0
- package/drizzle/0030_atomic_memory_additive.sql +105 -0
- package/drizzle/0031_atomic_extraction_ledger.sql +23 -0
- package/drizzle/0032_atomic_memory_entities.sql +12 -0
- package/drizzle/0033_todo_own_store.sql +99 -0
- package/drizzle/meta/0000_snapshot.json +87 -0
- package/drizzle/meta/_journal.json +244 -0
- package/generated/rem-operations.json +1 -0
- package/package.json +126 -4
- package/scripts/download-simple-tokenizer.mjs +254 -0
- package/settings.default.json +243 -0
- package/skills/extract-atomic-memory/SKILL.md +298 -0
- package/skills/extract-atomic-memory/references/account-for-turns.md +9 -0
- package/skills/extract-atomic-memory/references/calendar-meaning.md +64 -0
- package/skills/extract-atomic-memory/references/capture.md +120 -0
- package/skills/extract-atomic-memory/references/enrichment.md +92 -0
- package/skills/extract-atomic-memory/references/missing-durable-half.md +6 -0
- package/skills/extract-atomic-memory/references/progress-classification.md +21 -0
- package/skills/extract-atomic-memory/references/resolve-subject.md +19 -0
- package/skills/extract-atomic-memory/references/surrounding-context.md +10 -0
- package/skills/extract-atomic-memory/references/user-subject-guard.md +29 -0
- package/skills/judge-group-closure/SKILL.md +25 -0
- package/skills/judge-rem-memory-updates/SKILL.md +56 -0
- package/skills/judge-rem-memory-updates/agents/openai.yaml +4 -0
- package/skills/judge-retired-position/SKILL.md +25 -0
- package/skills/judge-task-lifecycle/SKILL.md +45 -0
- package/skills/key-state-attribute/SKILL.md +16 -0
- package/skills/resolve-entity-identity/SKILL.md +24 -0
- package/skills/resolve-relative-time/SKILL.md +22 -0
- package/sqlite-extensions/LICENSE-simple-tokenizer +28 -0
- package/sqlite-extensions/LICENSE-sqlite-vec +21 -0
- package/sqlite-extensions/linux-arm64/vec0.so +0 -0
- package/sqlite-extensions/linux-x64/vec0.so +0 -0
|
@@ -0,0 +1,391 @@
|
|
|
1
|
+
import { o as SqliteRuntimeHandle, r as SqliteDatabaseLike } from "./sqlite-runtime-L_ywirTm.js";
|
|
2
|
+
import { drizzle } from "drizzle-orm/better-sqlite3";
|
|
3
|
+
import { SQLiteColumn, SQLiteTableWithColumns } from "drizzle-orm/sqlite-core";
|
|
4
|
+
declare namespace schema_d_exports {
|
|
5
|
+
export { memoryEvents, memoryTelemetryIncidents, memoryTelemetrySyncState, memoryUsageOutbox, nodixAtomicExtractionLedger, nodixMemories, nodixMemoryEntities, nodixMemoryExtractionTimestamps, nodixMemoryRelations, nodixMemorySuppressions, nodixProfileRecoveryEntries, nodixProviderAgentMappings, nodixProviderProjectAgents, nodixProviderProjectMappings, nodixTodoMigrationReceipts, nodixTodos, nodixUnplacedMemoryCandidates };
|
|
6
|
+
}
|
|
7
|
+
type TextColumn<Name extends string, Table extends string, NotNull extends boolean, HasDefault extends boolean, PrimaryKey extends boolean> = SQLiteColumn<{
|
|
8
|
+
name: Name;
|
|
9
|
+
tableName: Table;
|
|
10
|
+
dataType: "string";
|
|
11
|
+
columnType: "SQLiteText";
|
|
12
|
+
data: string;
|
|
13
|
+
driverParam: string;
|
|
14
|
+
notNull: NotNull;
|
|
15
|
+
hasDefault: HasDefault;
|
|
16
|
+
isPrimaryKey: PrimaryKey;
|
|
17
|
+
isAutoincrement: false;
|
|
18
|
+
hasRuntimeDefault: false;
|
|
19
|
+
enumValues: [string, ...string[]];
|
|
20
|
+
baseColumn: never;
|
|
21
|
+
identity: undefined;
|
|
22
|
+
generated: undefined;
|
|
23
|
+
}, object, {
|
|
24
|
+
length: number | undefined;
|
|
25
|
+
}>;
|
|
26
|
+
type IntegerColumn<Name extends string, Table extends string, NotNull extends boolean, HasDefault extends boolean, PrimaryKey extends boolean> = SQLiteColumn<{
|
|
27
|
+
name: Name;
|
|
28
|
+
tableName: Table;
|
|
29
|
+
dataType: "number";
|
|
30
|
+
columnType: "SQLiteInteger";
|
|
31
|
+
data: number;
|
|
32
|
+
driverParam: number;
|
|
33
|
+
notNull: NotNull;
|
|
34
|
+
hasDefault: HasDefault;
|
|
35
|
+
isPrimaryKey: PrimaryKey;
|
|
36
|
+
isAutoincrement: false;
|
|
37
|
+
hasRuntimeDefault: false;
|
|
38
|
+
enumValues: undefined;
|
|
39
|
+
baseColumn: never;
|
|
40
|
+
identity: undefined;
|
|
41
|
+
generated: undefined;
|
|
42
|
+
}>;
|
|
43
|
+
type RealColumn<Name extends string, Table extends string, NotNull extends boolean, HasDefault extends boolean, PrimaryKey extends boolean> = SQLiteColumn<{
|
|
44
|
+
name: Name;
|
|
45
|
+
tableName: Table;
|
|
46
|
+
dataType: "number";
|
|
47
|
+
columnType: "SQLiteReal";
|
|
48
|
+
data: number;
|
|
49
|
+
driverParam: number;
|
|
50
|
+
notNull: NotNull;
|
|
51
|
+
hasDefault: HasDefault;
|
|
52
|
+
isPrimaryKey: PrimaryKey;
|
|
53
|
+
isAutoincrement: false;
|
|
54
|
+
hasRuntimeDefault: false;
|
|
55
|
+
enumValues: undefined;
|
|
56
|
+
baseColumn: never;
|
|
57
|
+
identity: undefined;
|
|
58
|
+
generated: undefined;
|
|
59
|
+
}>;
|
|
60
|
+
declare const nodixMemories: SQLiteTableWithColumns<{
|
|
61
|
+
name: "nodix_memories";
|
|
62
|
+
schema: undefined;
|
|
63
|
+
columns: {
|
|
64
|
+
id: TextColumn<"id", "nodix_memories", true, false, true>;
|
|
65
|
+
text: TextColumn<"text", "nodix_memories", true, false, false>;
|
|
66
|
+
category: TextColumn<"category", "nodix_memories", true, false, false>;
|
|
67
|
+
projectId: TextColumn<"project_id", "nodix_memories", true, false, false>;
|
|
68
|
+
importance: RealColumn<"importance", "nodix_memories", true, true, false>;
|
|
69
|
+
timestamp: IntegerColumn<"timestamp", "nodix_memories", true, false, false>;
|
|
70
|
+
timezone: TextColumn<"timezone", "nodix_memories", true, false, false>;
|
|
71
|
+
metadata: TextColumn<"metadata", "nodix_memories", false, true, false>;
|
|
72
|
+
contentHash: TextColumn<"content_hash", "nodix_memories", true, false, false>;
|
|
73
|
+
factId: TextColumn<"fact_id", "nodix_memories", false, false, false>;
|
|
74
|
+
derivedFrom: TextColumn<"derived_from", "nodix_memories", false, false, false>;
|
|
75
|
+
consolidationEpochId: TextColumn<"consolidation_epoch_id", "nodix_memories", false, false, false>;
|
|
76
|
+
confidenceSource: TextColumn<"confidence_source", "nodix_memories", false, false, false>;
|
|
77
|
+
lane: TextColumn<"lane", "nodix_memories", true, true, false>;
|
|
78
|
+
rawCandidateJson: TextColumn<"raw_candidate_json", "nodix_memories", false, false, false>;
|
|
79
|
+
dispositionReason: TextColumn<"disposition_reason", "nodix_memories", false, false, false>;
|
|
80
|
+
dispositionedAtMs: IntegerColumn<"dispositioned_at_ms", "nodix_memories", false, false, false>;
|
|
81
|
+
subject: TextColumn<"subject", "nodix_memories", false, false, false>;
|
|
82
|
+
attribute: TextColumn<"attribute", "nodix_memories", false, false, false>;
|
|
83
|
+
validFrom: IntegerColumn<"valid_from", "nodix_memories", false, false, false>;
|
|
84
|
+
validUntil: IntegerColumn<"valid_until", "nodix_memories", false, false, false>;
|
|
85
|
+
maturity: TextColumn<"maturity", "nodix_memories", false, false, false>;
|
|
86
|
+
source: TextColumn<"source", "nodix_memories", false, false, false>;
|
|
87
|
+
extractorVersion: TextColumn<"extractor_version", "nodix_memories", false, false, false>;
|
|
88
|
+
};
|
|
89
|
+
dialect: "sqlite";
|
|
90
|
+
}>;
|
|
91
|
+
declare const nodixMemoryExtractionTimestamps: SQLiteTableWithColumns<{
|
|
92
|
+
name: "nodix_memory_extraction_timestamps";
|
|
93
|
+
schema: undefined;
|
|
94
|
+
columns: {
|
|
95
|
+
projectId: TextColumn<"project_id", "nodix_memory_extraction_timestamps", true, false, false>;
|
|
96
|
+
replayKey: TextColumn<"replay_key", "nodix_memory_extraction_timestamps", true, false, false>;
|
|
97
|
+
resolvedAtMs: IntegerColumn<"resolved_at_ms", "nodix_memory_extraction_timestamps", true, false, false>;
|
|
98
|
+
timeSource: TextColumn<"time_source", "nodix_memory_extraction_timestamps", false, false, false>;
|
|
99
|
+
};
|
|
100
|
+
dialect: "sqlite";
|
|
101
|
+
}>;
|
|
102
|
+
declare const nodixMemoryRelations: SQLiteTableWithColumns<{
|
|
103
|
+
name: "nodix_memory_relations";
|
|
104
|
+
schema: undefined;
|
|
105
|
+
columns: {
|
|
106
|
+
sourceCardId: TextColumn<"source_card_id", "nodix_memory_relations", true, false, false>;
|
|
107
|
+
subject: TextColumn<"subject", "nodix_memory_relations", true, false, false>;
|
|
108
|
+
predicate: TextColumn<"predicate", "nodix_memory_relations", true, false, false>;
|
|
109
|
+
object: TextColumn<"object", "nodix_memory_relations", true, false, false>;
|
|
110
|
+
createdAt: IntegerColumn<"created_at", "nodix_memory_relations", true, false, false>;
|
|
111
|
+
};
|
|
112
|
+
dialect: "sqlite";
|
|
113
|
+
}>;
|
|
114
|
+
declare const nodixMemorySuppressions: SQLiteTableWithColumns<{
|
|
115
|
+
name: "nodix_memory_suppressions";
|
|
116
|
+
schema: undefined;
|
|
117
|
+
columns: {
|
|
118
|
+
projectId: TextColumn<"project_id", "nodix_memory_suppressions", true, false, false>;
|
|
119
|
+
subject: TextColumn<"subject", "nodix_memory_suppressions", false, false, false>;
|
|
120
|
+
attribute: TextColumn<"attribute", "nodix_memory_suppressions", false, false, false>;
|
|
121
|
+
contentHash: TextColumn<"content_hash", "nodix_memory_suppressions", false, false, false>;
|
|
122
|
+
createdAt: IntegerColumn<"created_at", "nodix_memory_suppressions", true, false, false>;
|
|
123
|
+
};
|
|
124
|
+
dialect: "sqlite";
|
|
125
|
+
}>;
|
|
126
|
+
declare const nodixTodos: SQLiteTableWithColumns<{
|
|
127
|
+
name: "nodix_todos";
|
|
128
|
+
schema: undefined;
|
|
129
|
+
columns: {
|
|
130
|
+
projectId: TextColumn<"project_id", "nodix_todos", true, false, false>;
|
|
131
|
+
activeTaskId: TextColumn<"active_task_id", "nodix_todos", true, false, false>;
|
|
132
|
+
description: TextColumn<"description", "nodix_todos", true, false, false>;
|
|
133
|
+
status: TextColumn<"status", "nodix_todos", true, false, false>;
|
|
134
|
+
openedAt: IntegerColumn<"opened_at", "nodix_todos", true, false, false>;
|
|
135
|
+
transitionedAt: IntegerColumn<"transitioned_at", "nodix_todos", true, false, false>;
|
|
136
|
+
closedAt: IntegerColumn<"closed_at", "nodix_todos", false, false, false>;
|
|
137
|
+
closeReason: TextColumn<"close_reason", "nodix_todos", false, false, false>;
|
|
138
|
+
sourceSession: TextColumn<"source_session", "nodix_todos", true, false, false>;
|
|
139
|
+
extractionPath: TextColumn<"extraction_path", "nodix_todos", true, false, false>;
|
|
140
|
+
};
|
|
141
|
+
dialect: "sqlite";
|
|
142
|
+
}>;
|
|
143
|
+
declare const nodixTodoMigrationReceipts: SQLiteTableWithColumns<{
|
|
144
|
+
name: "nodix_todo_migration_receipts";
|
|
145
|
+
schema: undefined;
|
|
146
|
+
columns: {
|
|
147
|
+
migrationId: TextColumn<"migration_id", "nodix_todo_migration_receipts", true, false, true>;
|
|
148
|
+
beforeCount: IntegerColumn<"before_count", "nodix_todo_migration_receipts", true, false, false>;
|
|
149
|
+
afterCount: IntegerColumn<"after_count", "nodix_todo_migration_receipts", true, false, false>;
|
|
150
|
+
migratedAt: IntegerColumn<"migrated_at", "nodix_todo_migration_receipts", true, false, false>;
|
|
151
|
+
};
|
|
152
|
+
dialect: "sqlite";
|
|
153
|
+
}>;
|
|
154
|
+
declare const nodixMemoryEntities: SQLiteTableWithColumns<{
|
|
155
|
+
name: "nodix_memory_entities";
|
|
156
|
+
schema: undefined;
|
|
157
|
+
columns: {
|
|
158
|
+
projectId: TextColumn<"project_id", "nodix_memory_entities", true, false, false>;
|
|
159
|
+
entityId: TextColumn<"entity_id", "nodix_memory_entities", true, false, false>;
|
|
160
|
+
displayName: TextColumn<"display_name", "nodix_memory_entities", true, false, false>;
|
|
161
|
+
normalizedName: TextColumn<"normalized_name", "nodix_memory_entities", true, false, false>;
|
|
162
|
+
createdAt: IntegerColumn<"created_at", "nodix_memory_entities", true, false, false>;
|
|
163
|
+
};
|
|
164
|
+
dialect: "sqlite";
|
|
165
|
+
}>;
|
|
166
|
+
declare const nodixAtomicExtractionLedger: SQLiteTableWithColumns<{
|
|
167
|
+
name: "nodix_atomic_extraction_ledger";
|
|
168
|
+
schema: undefined;
|
|
169
|
+
columns: {
|
|
170
|
+
conversationId: TextColumn<"conversation_id", "nodix_atomic_extraction_ledger", true, false, false>;
|
|
171
|
+
chunkHash: TextColumn<"chunk_hash", "nodix_atomic_extraction_ledger", true, false, false>;
|
|
172
|
+
pipelineVersion: TextColumn<"pipeline_version", "nodix_atomic_extraction_ledger", true, false, false>;
|
|
173
|
+
state: TextColumn<"state", "nodix_atomic_extraction_ledger", true, false, false>;
|
|
174
|
+
rawChunk: TextColumn<"raw_chunk", "nodix_atomic_extraction_ledger", true, false, false>;
|
|
175
|
+
routingSnapshotId: TextColumn<"routing_snapshot_id", "nodix_atomic_extraction_ledger", true, false, false>;
|
|
176
|
+
runParametersJson: TextColumn<"run_parameters_json", "nodix_atomic_extraction_ledger", true, false, false>;
|
|
177
|
+
reprocessReason: TextColumn<"reprocess_reason", "nodix_atomic_extraction_ledger", false, false, false>;
|
|
178
|
+
reprocessAttemptCount: IntegerColumn<"reprocess_attempt_count", "nodix_atomic_extraction_ledger", true, true, false>;
|
|
179
|
+
failedReply: TextColumn<"failed_reply", "nodix_atomic_extraction_ledger", false, false, false>;
|
|
180
|
+
createdAt: IntegerColumn<"created_at", "nodix_atomic_extraction_ledger", true, false, false>;
|
|
181
|
+
updatedAt: IntegerColumn<"updated_at", "nodix_atomic_extraction_ledger", true, false, false>;
|
|
182
|
+
};
|
|
183
|
+
dialect: "sqlite";
|
|
184
|
+
}>;
|
|
185
|
+
declare const nodixProviderProjectMappings: SQLiteTableWithColumns<{
|
|
186
|
+
name: "nodix_provider_project_mappings";
|
|
187
|
+
schema: undefined;
|
|
188
|
+
columns: {
|
|
189
|
+
userId: TextColumn<"user_id", "nodix_provider_project_mappings", true, false, false>;
|
|
190
|
+
externalSystem: TextColumn<"external_system", "nodix_provider_project_mappings", true, false, false>;
|
|
191
|
+
externalProjectKey: TextColumn<"external_project_key", "nodix_provider_project_mappings", true, false, false>;
|
|
192
|
+
projectId: TextColumn<"project_id", "nodix_provider_project_mappings", true, false, false>;
|
|
193
|
+
createdAtMs: IntegerColumn<"created_at_ms", "nodix_provider_project_mappings", true, false, false>;
|
|
194
|
+
};
|
|
195
|
+
dialect: "sqlite";
|
|
196
|
+
}>;
|
|
197
|
+
declare const nodixProviderAgentMappings: SQLiteTableWithColumns<{
|
|
198
|
+
name: "nodix_provider_agent_mappings";
|
|
199
|
+
schema: undefined;
|
|
200
|
+
columns: {
|
|
201
|
+
userId: TextColumn<"user_id", "nodix_provider_agent_mappings", true, false, false>;
|
|
202
|
+
externalSystem: TextColumn<"external_system", "nodix_provider_agent_mappings", true, false, false>;
|
|
203
|
+
externalAgentKey: TextColumn<"external_agent_key", "nodix_provider_agent_mappings", true, false, false>;
|
|
204
|
+
agentId: TextColumn<"agent_id", "nodix_provider_agent_mappings", true, false, false>;
|
|
205
|
+
createdAtMs: IntegerColumn<"created_at_ms", "nodix_provider_agent_mappings", true, false, false>;
|
|
206
|
+
};
|
|
207
|
+
dialect: "sqlite";
|
|
208
|
+
}>;
|
|
209
|
+
declare const nodixProviderProjectAgents: SQLiteTableWithColumns<{
|
|
210
|
+
name: "nodix_provider_project_agents";
|
|
211
|
+
schema: undefined;
|
|
212
|
+
columns: {
|
|
213
|
+
userId: TextColumn<"user_id", "nodix_provider_project_agents", true, false, false>;
|
|
214
|
+
projectId: TextColumn<"project_id", "nodix_provider_project_agents", true, false, false>;
|
|
215
|
+
agentId: TextColumn<"agent_id", "nodix_provider_project_agents", true, false, false>;
|
|
216
|
+
createdAtMs: IntegerColumn<"created_at_ms", "nodix_provider_project_agents", true, false, false>;
|
|
217
|
+
};
|
|
218
|
+
dialect: "sqlite";
|
|
219
|
+
}>;
|
|
220
|
+
declare const memoryEvents: SQLiteTableWithColumns<{
|
|
221
|
+
name: "nodix_memory_events";
|
|
222
|
+
schema: undefined;
|
|
223
|
+
columns: {
|
|
224
|
+
id: IntegerColumn<"id", "nodix_memory_events", true, true, true>;
|
|
225
|
+
eventType: TextColumn<"event_type", "nodix_memory_events", true, false, false>;
|
|
226
|
+
factId: TextColumn<"fact_id", "nodix_memory_events", false, false, false>;
|
|
227
|
+
memoryKind: TextColumn<"memory_kind", "nodix_memory_events", false, false, false>;
|
|
228
|
+
timestampMs: IntegerColumn<"timestamp_ms", "nodix_memory_events", true, false, false>;
|
|
229
|
+
sessionUuid: TextColumn<"session_uuid", "nodix_memory_events", false, false, false>;
|
|
230
|
+
turnId: TextColumn<"turn_id", "nodix_memory_events", false, false, false>;
|
|
231
|
+
agentId: TextColumn<"agent_id", "nodix_memory_events", true, false, false>;
|
|
232
|
+
projectId: TextColumn<"project_id", "nodix_memory_events", false, false, false>;
|
|
233
|
+
tenantId: TextColumn<"tenant_id", "nodix_memory_events", false, false, false>;
|
|
234
|
+
sourceEventId: IntegerColumn<"source_event_id", "nodix_memory_events", false, false, false>;
|
|
235
|
+
derivedFrom: TextColumn<"derived_from", "nodix_memory_events", false, false, false>;
|
|
236
|
+
consolidationEpochId: TextColumn<"consolidation_epoch_id", "nodix_memory_events", false, false, false>;
|
|
237
|
+
contentHash: TextColumn<"content_hash", "nodix_memory_events", false, false, false>;
|
|
238
|
+
receiptHmac: TextColumn<"receipt_hmac", "nodix_memory_events", false, false, false>;
|
|
239
|
+
keyVersion: IntegerColumn<"key_version", "nodix_memory_events", false, false, false>;
|
|
240
|
+
retrievalRank: IntegerColumn<"retrieval_rank", "nodix_memory_events", false, false, false>;
|
|
241
|
+
retrievalScore: RealColumn<"retrieval_score", "nodix_memory_events", false, false, false>;
|
|
242
|
+
queryTenantId: TextColumn<"query_tenant_id", "nodix_memory_events", false, false, false>;
|
|
243
|
+
resultTenantId: TextColumn<"result_tenant_id", "nodix_memory_events", false, false, false>;
|
|
244
|
+
metadataJson: TextColumn<"metadata_json", "nodix_memory_events", false, false, false>;
|
|
245
|
+
};
|
|
246
|
+
dialect: "sqlite";
|
|
247
|
+
}>;
|
|
248
|
+
declare const memoryUsageOutbox: SQLiteTableWithColumns<{
|
|
249
|
+
name: "nodix_memory_usage_outbox";
|
|
250
|
+
schema: undefined;
|
|
251
|
+
columns: {
|
|
252
|
+
id: IntegerColumn<"id", "nodix_memory_usage_outbox", true, true, true>;
|
|
253
|
+
eventType: TextColumn<"event_type", "nodix_memory_usage_outbox", true, false, false>;
|
|
254
|
+
payloadJson: TextColumn<"payload_json", "nodix_memory_usage_outbox", true, false, false>;
|
|
255
|
+
acceptedAtMs: IntegerColumn<"accepted_at_ms", "nodix_memory_usage_outbox", true, false, false>;
|
|
256
|
+
status: TextColumn<"status", "nodix_memory_usage_outbox", true, false, false>;
|
|
257
|
+
attemptCount: IntegerColumn<"attempt_count", "nodix_memory_usage_outbox", true, true, false>;
|
|
258
|
+
lastError: TextColumn<"last_error", "nodix_memory_usage_outbox", false, false, false>;
|
|
259
|
+
nextAttemptMs: IntegerColumn<"next_attempt_ms", "nodix_memory_usage_outbox", false, false, false>;
|
|
260
|
+
};
|
|
261
|
+
dialect: "sqlite";
|
|
262
|
+
}>;
|
|
263
|
+
declare const memoryTelemetryIncidents: SQLiteTableWithColumns<{
|
|
264
|
+
name: "nodix_memory_telemetry_incidents";
|
|
265
|
+
schema: undefined;
|
|
266
|
+
columns: {
|
|
267
|
+
id: IntegerColumn<"id", "nodix_memory_telemetry_incidents", true, true, true>;
|
|
268
|
+
incidentType: TextColumn<"incident_type", "nodix_memory_telemetry_incidents", true, false, false>;
|
|
269
|
+
severity: TextColumn<"severity", "nodix_memory_telemetry_incidents", true, false, false>;
|
|
270
|
+
message: TextColumn<"message", "nodix_memory_telemetry_incidents", true, false, false>;
|
|
271
|
+
payloadJson: TextColumn<"payload_json", "nodix_memory_telemetry_incidents", false, false, false>;
|
|
272
|
+
createdAtMs: IntegerColumn<"created_at_ms", "nodix_memory_telemetry_incidents", true, false, false>;
|
|
273
|
+
};
|
|
274
|
+
dialect: "sqlite";
|
|
275
|
+
}>;
|
|
276
|
+
declare const memoryTelemetrySyncState: SQLiteTableWithColumns<{
|
|
277
|
+
name: "nodix_memory_telemetry_sync_state";
|
|
278
|
+
schema: undefined;
|
|
279
|
+
columns: {
|
|
280
|
+
sink: TextColumn<"sink", "nodix_memory_telemetry_sync_state", true, false, true>;
|
|
281
|
+
lastEventId: IntegerColumn<"last_event_id", "nodix_memory_telemetry_sync_state", true, true, false>;
|
|
282
|
+
updatedAtMs: IntegerColumn<"updated_at_ms", "nodix_memory_telemetry_sync_state", true, false, false>;
|
|
283
|
+
};
|
|
284
|
+
dialect: "sqlite";
|
|
285
|
+
}>;
|
|
286
|
+
/**
|
|
287
|
+
* Write attempts the extraction path could not place. A rejected candidate is
|
|
288
|
+
* preserved here with the raw model output that produced it, so a failed write
|
|
289
|
+
* costs retrievability and never the content. Rows here are NOT memories: no
|
|
290
|
+
* retrieval path reads this table.
|
|
291
|
+
*/
|
|
292
|
+
declare const nodixUnplacedMemoryCandidates: SQLiteTableWithColumns<{
|
|
293
|
+
name: "nodix_unplaced_memory_candidates";
|
|
294
|
+
schema: undefined;
|
|
295
|
+
columns: {
|
|
296
|
+
id: TextColumn<"id", "nodix_unplaced_memory_candidates", true, false, true>;
|
|
297
|
+
projectId: TextColumn<"project_id", "nodix_unplaced_memory_candidates", true, false, false>;
|
|
298
|
+
category: TextColumn<"category", "nodix_unplaced_memory_candidates", true, false, false>;
|
|
299
|
+
text: TextColumn<"text", "nodix_unplaced_memory_candidates", true, false, false>;
|
|
300
|
+
rawCandidateJson: TextColumn<"raw_candidate_json", "nodix_unplaced_memory_candidates", true, false, false>;
|
|
301
|
+
dispositionReason: TextColumn<"disposition_reason", "nodix_unplaced_memory_candidates", true, false, false>;
|
|
302
|
+
dispositionedAtMs: IntegerColumn<"dispositioned_at_ms", "nodix_unplaced_memory_candidates", true, false, false>;
|
|
303
|
+
sessionKey: TextColumn<"session_key", "nodix_unplaced_memory_candidates", false, false, false>;
|
|
304
|
+
dedupeHash: TextColumn<"dedupe_hash", "nodix_unplaced_memory_candidates", true, false, false>;
|
|
305
|
+
};
|
|
306
|
+
dialect: "sqlite";
|
|
307
|
+
}>;
|
|
308
|
+
declare const nodixProfileRecoveryEntries: SQLiteTableWithColumns<{
|
|
309
|
+
name: "nodix_profile_recovery_entries";
|
|
310
|
+
schema: undefined;
|
|
311
|
+
columns: {
|
|
312
|
+
entryId: TextColumn<"entry_id", "nodix_profile_recovery_entries", true, false, true>;
|
|
313
|
+
mutationAttemptId: TextColumn<"mutation_attempt_id", "nodix_profile_recovery_entries", true, false, false>;
|
|
314
|
+
removedRowId: TextColumn<"removed_row_id", "nodix_profile_recovery_entries", true, false, false>;
|
|
315
|
+
projectId: TextColumn<"project_id", "nodix_profile_recovery_entries", true, false, false>;
|
|
316
|
+
profileFactId: TextColumn<"profile_fact_id", "nodix_profile_recovery_entries", true, false, false>;
|
|
317
|
+
sectionName: TextColumn<"section_name", "nodix_profile_recovery_entries", true, false, false>;
|
|
318
|
+
removedValue: TextColumn<"removed_value", "nodix_profile_recovery_entries", true, false, false>;
|
|
319
|
+
removedAtMs: IntegerColumn<"removed_at_ms", "nodix_profile_recovery_entries", true, false, false>;
|
|
320
|
+
};
|
|
321
|
+
dialect: "sqlite";
|
|
322
|
+
}>;
|
|
323
|
+
//#endregion
|
|
324
|
+
//#region src/store/path-validation.d.ts
|
|
325
|
+
/**
|
|
326
|
+
* Validate and prepare the storage directory for the SQLite database file.
|
|
327
|
+
* Resolves symlinks, creates missing directories, and checks write permissions.
|
|
328
|
+
* Returns the resolved parent directory path on success, or throws a descriptive error.
|
|
329
|
+
*/
|
|
330
|
+
declare function validateStoragePath(dbPath: string): string;
|
|
331
|
+
//#endregion
|
|
332
|
+
//#region src/store/connection.d.ts
|
|
333
|
+
type RuntimeDrizzleDB = ReturnType<typeof drizzle<typeof schema_d_exports>>;
|
|
334
|
+
type DrizzleDB = RuntimeDrizzleDB & {
|
|
335
|
+
$client: SqliteDatabaseLike;
|
|
336
|
+
vectorDimension: number;
|
|
337
|
+
vectorSearchAvailable: boolean;
|
|
338
|
+
retrySetup(): void;
|
|
339
|
+
/**
|
|
340
|
+
* The chokepoint wrapper over the same connection. Store code MUST use this
|
|
341
|
+
* (prepared-statement cache lives here); `$client` is the raw
|
|
342
|
+
* driver handle drizzle was constructed over and bypasses both.
|
|
343
|
+
*/
|
|
344
|
+
chokepoint: SqliteDatabaseLike;
|
|
345
|
+
};
|
|
346
|
+
/**
|
|
347
|
+
* Opens the Node SQLite runtime and applies SQLite connection setup fallback behavior for missing data.
|
|
348
|
+
*/
|
|
349
|
+
/**
|
|
350
|
+
* Reads the locked embedding dimension from the existing `nodix_memory_chunk_vectors`
|
|
351
|
+
* DDL. Returns `undefined` if the DB file does not exist or the table has not
|
|
352
|
+
* been created yet; throws on a corrupt-state DDL.
|
|
353
|
+
*
|
|
354
|
+
* This lets out-of-band tooling (CLI preset switching, diagnostics) detect
|
|
355
|
+
* dim mismatches *before* the gateway boots, without paying the cost of
|
|
356
|
+
* spinning up a real `MemoryStore`. Keeping the regex here means CLI,
|
|
357
|
+
* diagnostics, and store startup agree on one canonical parser.
|
|
358
|
+
*/
|
|
359
|
+
declare function readChunkVecTableDimension(dbPath: string): number | undefined;
|
|
360
|
+
declare function parseVecTableDimension(sql: string): number;
|
|
361
|
+
/** Phase D: project_id PARTITION KEY on nodix_memory_chunk_vectors. */
|
|
362
|
+
declare function vecTableDdlHasPartitionKey(sql: string): boolean;
|
|
363
|
+
interface VecTableState {
|
|
364
|
+
dimension: number;
|
|
365
|
+
rowCount: number;
|
|
366
|
+
hasPartitionKey: boolean;
|
|
367
|
+
}
|
|
368
|
+
declare function readChunkVecTableState(db: SqliteDatabaseLike): VecTableState | undefined;
|
|
369
|
+
declare function loadStorageExtensions(sqlite: SqliteRuntimeHandle): void;
|
|
370
|
+
/**
|
|
371
|
+
* Startup invariant: the persisted DDL
|
|
372
|
+
* for `nodix_memory_chunks_fts` must declare `tokenize='simple ...'`. Catches DBs
|
|
373
|
+
* created against an older plugin build (still on `unicode61`) so a stale
|
|
374
|
+
* DB plus a fresh plugin doesn't silently degrade CJK recall to char-level.
|
|
375
|
+
*
|
|
376
|
+
* Mirrors the regex pattern used by `parseVecTableDimension` for
|
|
377
|
+
* `nodix_memory_chunk_vectors` — single SELECT against `sqlite_master`, regex match.
|
|
378
|
+
*/
|
|
379
|
+
/**
|
|
380
|
+
* Round A invariant: detect legacy DBs that pre-date migration 0004
|
|
381
|
+
* (chunk-table swap). If the parent vec/FTS objects still exist, the DB
|
|
382
|
+
* was opened against a build that never ran the new migration — fail loud
|
|
383
|
+
* so the dev wipes the file.
|
|
384
|
+
*/
|
|
385
|
+
declare function assertNoLegacyBoundarySchema(db: SqliteDatabaseLike): void;
|
|
386
|
+
/** Implements init db as the local SQLite connection setup operation. */
|
|
387
|
+
declare function initDb(dbPath: string, vectorDim: number): DrizzleDB;
|
|
388
|
+
/** Implements close db as the local SQLite connection setup operation. */
|
|
389
|
+
declare function closeDb(db: DrizzleDB): void;
|
|
390
|
+
//#endregion
|
|
391
|
+
export { initDb as a, readChunkVecTableDimension as c, validateStoragePath as d, closeDb as i, readChunkVecTableState as l, VecTableState as n, loadStorageExtensions as o, assertNoLegacyBoundarySchema as r, parseVecTableDimension as s, DrizzleDB as t, vecTableDdlHasPartitionKey as u };
|