@snoai/memory 1.0.0 → 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/README.md +30 -4
- package/dist/{access-tracker-CSc21GtV.d.ts → access-tracker-BbEvEocb.d.ts} +3 -3
- package/dist/{adapter-DMEmCTKo.d.ts → adapter-B7Jox9-6.d.ts} +1 -1
- package/dist/{atomic-memory-extraction-sdNf1-B1.js → atomic-memory-extraction-C5rmogoY.js} +7 -7
- package/dist/{atomic-memory-extraction-BpOUWPJM.d.ts → atomic-memory-extraction-d9EG-4ti.d.ts} +3 -3
- package/dist/{capture-policy-detector-CHz5GOPA.d.ts → capture-policy-detector-CxbHPkMX.d.ts} +1 -1
- package/dist/{classifier-C96uH9OF.d.ts → classifier-DnbbtwTS.d.ts} +2 -2
- package/dist/client.d.ts +1 -1
- package/dist/client.js +3 -2
- package/dist/{config-tSrvLXgV.js → config-CL90qYva.js} +1 -2
- package/dist/{connection-DAbzki8K.d.ts → connection-3IVXpuPE.d.ts} +1 -1
- package/dist/{connection-DliCOBB2.js → connection-C9YD5sgm.js} +2 -2
- package/dist/{data-bootstrap-CcJUwkqf.d.ts → data-bootstrap-Bl3lthzE.d.ts} +2 -2
- package/dist/{data-bootstrap-CYniFp8b.js → data-bootstrap-P8sie9WA.js} +4 -4
- package/dist/{derived-suppression-cache-C7bGARc0.d.ts → derived-suppression-cache-CI0durYx.d.ts} +1 -1
- package/dist/diagnostic-encoder.js +1 -1
- package/dist/{index-DQ7VL6d3.d.ts → index-0aqS8pVF.d.ts} +3 -2
- package/dist/{index-BsMap4It.d.ts → index-BO4RU_mc.d.ts} +1 -1
- package/dist/index.d.ts +9 -9
- package/dist/index.js +7 -7
- package/dist/internal/contract/routes.d.ts +2 -2
- package/dist/internal/contract/routes.js +2 -1
- package/dist/internal/engine/bindings/memory-cli-shared.d.ts +4 -4
- package/dist/internal/engine/bindings/memory-forget-tool.js +1 -1
- package/dist/internal/engine/bindings/memory-list-tool.js +1 -1
- package/dist/internal/engine/bindings/memory-recall-tool.js +2 -2
- package/dist/internal/engine/bindings/memory-reflection-resolve-tool.js +1 -1
- package/dist/internal/engine/bindings/memory-stats-tool.js +1 -1
- package/dist/internal/engine/bindings/memory-store-tool.js +3 -3
- package/dist/internal/engine/bindings/memory-tool-access.d.ts +1 -1
- package/dist/internal/engine/bindings/memory-tool-access.js +1 -1
- package/dist/internal/engine/bindings/memory-tool-results.d.ts +1 -1
- package/dist/internal/engine/bindings/memory-tool-results.js +1 -1
- package/dist/internal/engine/bindings/memory-tool-schemas.d.ts +4 -4
- package/dist/internal/engine/bindings/memory-tool-schemas.js +1 -1
- package/dist/internal/engine/bindings/memory-update-tool.js +2 -2
- package/dist/internal/engine/bindings/sno-station-mem-ambient-learning-hook.d.ts +3 -3
- package/dist/internal/engine/bindings/sno-station-mem-ambient-learning-hook.js +2 -2
- package/dist/internal/engine/bindings/sno-station-mem-auto-recall-hook.d.ts +3 -3
- package/dist/internal/engine/bindings/sno-station-mem-auto-recall-hook.js +2 -2
- package/dist/internal/engine/bindings/sno-station-mem-insight-distill-factory.d.ts +4 -4
- package/dist/internal/engine/bindings/sno-station-mem-insight-distill-factory.js +2 -2
- package/dist/internal/engine/bindings/sno-station-mem-message-transcript.js +2 -2
- package/dist/internal/engine/bindings/sno-station-mem-reset-hook.d.ts +2 -2
- package/dist/internal/engine/bindings/sno-station-mem-runtime-mode.d.ts +2 -3
- package/dist/internal/engine/bindings/sno-station-mem-runtime-mode.js +1 -2
- package/dist/internal/engine/eval/trace.d.ts +1 -1
- package/dist/internal/engine/eval/trace.js +2 -2
- package/dist/internal/engine/extraction/atomic-memory-extraction.d.ts +1 -1
- package/dist/internal/engine/extraction/atomic-memory-extraction.js +1 -1
- package/dist/internal/engine/extraction/b-profile-section-rekey.d.ts +3 -3
- package/dist/internal/engine/extraction/capture-policy-detector.d.ts +1 -1
- package/dist/internal/engine/extraction/memory-metadata-codec.d.ts +2 -2
- package/dist/internal/engine/extraction/memory-temporality-classifier.d.ts +1 -1
- package/dist/internal/engine/extraction/memory-temporality-classifier.js +1 -1
- package/dist/internal/engine/observability/adapter.d.ts +1 -1
- package/dist/internal/engine/observability/memory-snapshot.d.ts +1 -1
- package/dist/internal/engine/observability/observable-embedder.d.ts +1 -1
- package/dist/internal/engine/observability/observable-llm-client.d.ts +1 -1
- package/dist/internal/engine/observability/observable-memory-store.d.ts +1 -1
- package/dist/internal/engine/observability/observable-memory-store.js +1 -1
- package/dist/internal/engine/observability/observable-retriever.d.ts +1 -1
- package/dist/internal/engine/observability/observable-retriever.js +1 -1
- package/dist/internal/engine/observability/runtime-diagnostics.js +1 -1
- package/dist/internal/engine/operations/memory-tier-promoter.d.ts +1 -1
- package/dist/internal/engine/provider/provider-registration.d.ts +3 -3
- package/dist/internal/engine/provider/provider-row-renderer.d.ts +1 -1
- package/dist/internal/engine/reflection/reflection-command-hooks.d.ts +1 -1
- package/dist/internal/engine/reflection/reflection-command-hooks.js +1 -1
- package/dist/internal/engine/reflection/reflection-deps.d.ts +1 -1
- package/dist/internal/engine/reflection/reflection-embedded-generator.d.ts +1 -1
- package/dist/internal/engine/reflection/reflection-embedded-generator.js +1 -1
- package/dist/internal/engine/reflection/reflection-injection-hooks.d.ts +1 -1
- package/dist/internal/engine/reflection/reflection-injection-hooks.js +1 -1
- package/dist/internal/engine/reflection/reflection-lifecycle-hooks.d.ts +1 -1
- package/dist/internal/engine/reflection/reflection-lifecycle-hooks.js +1 -1
- package/dist/internal/engine/reflection/strategy-hook-runner.d.ts +3 -3
- package/dist/internal/engine/reflection/strategy-hook-runner.js +2 -2
- package/dist/internal/engine/rem/classifier.d.ts +1 -1
- package/dist/internal/engine/rem/index.d.ts +2 -2
- package/dist/internal/engine/retrieval/access-tracker.d.ts +1 -1
- package/dist/internal/engine/retrieval/retriever.d.ts +1 -1
- package/dist/internal/engine/retrieval/retriever.js +1 -1
- package/dist/internal/engine/shared/memory-kind-policy.d.ts +1 -1
- package/dist/internal/engine/shared/types.d.ts +1 -1
- package/dist/internal/engine/telemetry/observe-ledger.d.ts +1 -1
- package/dist/internal/model/llm-client.js +1 -1
- package/dist/internal/store/atomic-memory-cutover-sql.js +1 -1
- package/dist/internal/store/connection.d.ts +1 -1
- package/dist/internal/store/connection.js +1 -1
- package/dist/internal/store/data-bootstrap.d.ts +1 -1
- package/dist/internal/store/data-bootstrap.js +1 -1
- package/dist/internal/store/maintenance.d.ts +1 -1
- package/dist/internal/store/maintenance.js +6 -6
- package/dist/internal/store/store.d.ts +2 -2
- package/dist/internal/store/store.js +1 -1
- package/dist/{llm-client-B7Xoxqou.js → llm-client-BSYUAcUb.js} +1 -5
- package/dist/{log-site-catalog.generated-B9WYdnAM.js → log-site-catalog.generated-BMKWj-Nx.js} +160 -160
- package/dist/log-site-catalog.json +1 -1
- package/dist/{memory-kind-policy-LKt0u3gy.d.ts → memory-kind-policy-BiuRjSJc.d.ts} +1 -1
- package/dist/{memory-metadata-codec-C3oQd47V.d.ts → memory-metadata-codec-DUvsYe_X.d.ts} +1 -1
- package/dist/{memory-runtime-BZtREuwW.js → memory-runtime-DqUS4cWi.js} +168 -168
- package/dist/{memory-snapshot-3e44ND2i.d.ts → memory-snapshot-CqY1BUUA.d.ts} +1 -1
- package/dist/{memory-source-order-BtrIxaIt.js → memory-source-order-YMRoeDLd.js} +1 -1
- package/dist/{memory-store-base-XRA4S9Xl.d.ts → memory-store-base-CQ_bHlYA.d.ts} +5 -6
- package/dist/{memory-store-shared-DeIDkhLj.js → memory-store-shared-DqpWJXZZ.js} +2 -2
- package/dist/{memory-temporality-classifier-CKiTAHXe.js → memory-temporality-classifier-BUjXG5o7.js} +1 -1
- package/dist/{memory-temporality-classifier-CEdRTN5J.d.ts → memory-temporality-classifier-Brht5jyK.d.ts} +1 -1
- package/dist/{memory-tier-promoter-DbTpahkP.d.ts → memory-tier-promoter-CqGxCkue.d.ts} +1 -1
- package/dist/memory-tool-dependencies-CatGzI9R.d.ts +14 -0
- package/dist/{memory-tool-dependencies-CLODycUw.js → memory-tool-dependencies-DjUoelnm.js} +1 -1
- package/dist/{observable-embedder-DQnNgf9O.d.ts → observable-embedder-CNNe9gkg.d.ts} +1 -1
- package/dist/{observable-llm-client-uwqPADpN.d.ts → observable-llm-client-CRuKlefQ.d.ts} +1 -1
- package/dist/{observable-memory-store-BaZKbhgq.d.ts → observable-memory-store-CnGDpOY5.d.ts} +4 -4
- package/dist/{observable-retriever-Dt_NUxAA.d.ts → observable-retriever-Cooc62Qw.d.ts} +5 -5
- package/dist/{profile-section-writer-hIphqpUY.js → profile-section-writer-BhGKPBjw.js} +4 -4
- package/dist/{reflection-command-hooks-BeQiJI9-.js → reflection-command-hooks-ClUl-iv6.js} +4 -4
- package/dist/{reflection-command-hooks-C1Vxgb-O.d.ts → reflection-command-hooks-G1-dI2Av.d.ts} +3 -3
- package/dist/{reflection-deps-RpLPFrSc.d.ts → reflection-deps-Ccm2Jf5W.d.ts} +2 -2
- package/dist/{reflection-embedded-generator-CDUhgV96.js → reflection-embedded-generator-BRvqV5N-.js} +1 -1
- package/dist/{reflection-embedded-generator-CxOex5xK.d.ts → reflection-embedded-generator-kfQfKEYV.d.ts} +2 -2
- package/dist/{reflection-injection-hooks-DfUgqu8f.d.ts → reflection-injection-hooks-CS_uhjoD.d.ts} +3 -3
- package/dist/{reflection-lifecycle-hooks-Ct5HBdSG.d.ts → reflection-lifecycle-hooks-CRSpUdLi.d.ts} +2 -2
- package/dist/{rem-batch-executor-bc0IFlp2.js → rem-batch-executor-Dg2HgROM.js} +1 -1
- package/dist/{rem-batch-executor-Cbm5gfSe.js → rem-batch-executor-DuC4nYyf.js} +11 -15
- package/dist/{rem-consumer-retrieval-CRpvG8KS.js → rem-consumer-retrieval-CR0dtcHR.js} +1 -1
- package/dist/{rem-trigger-BTxkcjgT.js → rem-trigger-Hn6od8IV.js} +3 -2
- package/dist/{retriever-Ruk3zp7_.d.ts → retriever-Dxss5fRv.d.ts} +14 -14
- package/dist/{retriever-CygHBazG.js → retriever-ZoLvPRHq.js} +3 -3
- package/dist/{routes-Ce7SQKec.js → routes-DLHT__Ay.js} +2 -1
- package/dist/{server-BPAY4NTG.js → server-CSvxchqg.js} +12 -10
- package/dist/sidecar/main.js +3 -3
- package/dist/{sno-station-mem-runtime-dependencies-DjLOhB45.js → sno-station-mem-runtime-dependencies-CoWqUMbK.js} +8 -8
- package/dist/sno-station-mem-runtime-dependencies-DHESIuPn.d.ts +31 -0
- package/dist/{store-2pM0-dZg.d.ts → store-C8sUTssE.d.ts} +1 -1
- package/dist/{store-DzpZBMEm.js → store-nPql26YM.js} +4 -4
- package/dist/{strategy-hook-runner-gBtU47tX.d.ts → strategy-hook-runner-Bxy851Xx.d.ts} +6 -6
- package/dist/{strategy-hook-runner-zmdIYOmQ.js → strategy-hook-runner-Djify5Rw.js} +1 -1
- package/dist/{trace-1t1n_wUm.d.ts → trace-C1JxMfs-.d.ts} +2 -2
- package/dist/{types-DxKqU60b.d.ts → types-CWdhXLxr.d.ts} +7 -7
- package/package.json +7 -7
- package/dist/memory-tool-dependencies-N69chrQc.d.ts +0 -14
- package/dist/sno-station-mem-runtime-dependencies-Bu-MiqPX.d.ts +0 -31
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { t as PluginConfig } from "./plugin-config-schema-C0UUbOmG.js";
|
|
2
|
-
import "./types-
|
|
2
|
+
import "./types-CWdhXLxr.js";
|
|
3
3
|
import { r as SqliteDatabaseLike } from "./sqlite-runtime-L_ywirTm.js";
|
|
4
4
|
//#region src/engine/observability/memory-snapshot.d.ts
|
|
5
5
|
type SnapshotReason = "startup" | "session_end";
|
|
@@ -61,7 +61,7 @@ function isSafeInteger(value) {
|
|
|
61
61
|
/**
|
|
62
62
|
* The order key a row carries, or the one a row written before this change is treated as having.
|
|
63
63
|
*
|
|
64
|
-
* A row from before
|
|
64
|
+
* A row from before source order was persisted has no `source_order` until the maintenance pass backfills it, and an
|
|
65
65
|
* ordinary wave must keep running over such a store rather than throwing. Those rows are older
|
|
66
66
|
* than everything written since — that is what "written before" means — so they read as the
|
|
67
67
|
* lowest possible key: anything may close them, and they may close nothing.
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import { _ as MemoryLane, b as MemoryTier, g as MemoryEntry, h as MemoryCategory, r as AggregationQuery, v as MemoryMetadata, y as MemorySearchResult } from "./types-
|
|
1
|
+
import { _ as MemoryLane, b as MemoryTier, g as MemoryEntry, h as MemoryCategory, r as AggregationQuery, v as MemoryMetadata, y as MemorySearchResult } from "./types-CWdhXLxr.js";
|
|
2
2
|
import "./index-DL8AVj0Z.js";
|
|
3
3
|
import { t as Embedder } from "./embedding-provider-client-vynZMuit.js";
|
|
4
|
-
import { K as RemFacetPolicy } from "./index-
|
|
4
|
+
import { K as RemFacetPolicy } from "./index-BO4RU_mc.js";
|
|
5
5
|
import { T as WriteTextVersionInput, h as RemMutationResult } from "./types-pVomjzqR.js";
|
|
6
6
|
import { a as StorageError } from "./errors-CeVRxf9V.js";
|
|
7
|
-
import { r as WriterAuthority } from "./memory-kind-policy-
|
|
8
|
-
import { t as DrizzleDB } from "./connection-
|
|
7
|
+
import { r as WriterAuthority } from "./memory-kind-policy-BiuRjSJc.js";
|
|
8
|
+
import { t as DrizzleDB } from "./connection-3IVXpuPE.js";
|
|
9
9
|
import { r as SqliteDatabaseLike } from "./sqlite-runtime-L_ywirTm.js";
|
|
10
10
|
import { n as MemoryTelemetryKeySet, t as MemoryTelemetryReceiptService } from "./memory-telemetry-receipts-MAJecvXQ.js";
|
|
11
11
|
import { a as MemoryTelemetryMetadata, i as MemoryTelemetryEventType, r as MemoryTelemetryDeleteReason } from "./memory-telemetry-types-CufVmrCs.js";
|
|
@@ -263,8 +263,7 @@ interface SearchOptions {
|
|
|
263
263
|
/**
|
|
264
264
|
* When set, search excludes memories whose metadata.invalidated_at is <= this
|
|
265
265
|
* timestamp. Fires on EVERY recall path — manual + auto + slash commands —
|
|
266
|
-
* because a superseded fact is obsolete regardless of recall mode
|
|
267
|
-
* memora-fama OD-3, FAA binary).
|
|
266
|
+
* because a superseded fact is obsolete regardless of recall mode.
|
|
268
267
|
*/
|
|
269
268
|
excludeInvalidatedBefore?: number;
|
|
270
269
|
/** Explicit historical recall retains an invalidated row only when it names a successor. */
|
|
@@ -2,7 +2,7 @@ import "./internal/config/index.js";
|
|
|
2
2
|
import { Ct as PERSISTED_CONTENT_HASH_V3, St as PERSISTED_CONTENT_HASH_V1 } from "./signed-registry-constants-yq3DlG3B.js";
|
|
3
3
|
import { StorageError } from "./internal/engine/shared/errors.js";
|
|
4
4
|
import "./internal/engine/shared/utils.js";
|
|
5
|
-
import "./connection-
|
|
5
|
+
import "./connection-C9YD5sgm.js";
|
|
6
6
|
import { CHUNKING_VERSION, aggregateChunksToMemories, buildChunkId, buildDensePayload, chunk as chunk$1, expandSnippetWindow, extractMetadataHeader, headExtract, shouldDropSummary } from "@snoai/chunking";
|
|
7
7
|
import { createLogger } from "@snoai/utils/logger";
|
|
8
8
|
import { randomUUID as randomUUID$1 } from "node:crypto";
|
|
@@ -54,7 +54,7 @@ function readAmbientCaptureHashMetadata(metadata) {
|
|
|
54
54
|
*/
|
|
55
55
|
const log = createLogger("sno-station-mem:store");
|
|
56
56
|
/**
|
|
57
|
-
*
|
|
57
|
+
* Reflection v3: discriminator added to content-hash input when the
|
|
58
58
|
* row carries a `metadata.mappedKind`. Two rows with same projectId + same store
|
|
59
59
|
* category + same text but distinct mappedKinds (e.g. user-model vs
|
|
60
60
|
* agent-model both → category=preference) must coexist as distinct rows. The
|
package/dist/{memory-temporality-classifier-CKiTAHXe.js → memory-temporality-classifier-BUjXG5o7.js}
RENAMED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { isSupportedLocale } from "./internal/engine/i18n/locales.js";
|
|
2
2
|
import { parseIsoDateTimeMs } from "./internal/engine/shared/iso-date-time.js";
|
|
3
3
|
import { n as modelCallDestination } from "./model-call-table-CspopkBg.js";
|
|
4
|
-
import { a as isTerminalLlmFailure } from "./llm-client-
|
|
4
|
+
import { a as isTerminalLlmFailure } from "./llm-client-BSYUAcUb.js";
|
|
5
5
|
import { n as readModelReplyJson } from "./model-reply-text-CKopStP2.js";
|
|
6
6
|
import { n as RESOURCES_BY_LOCALE } from "./all-resources-BQK2ugjB.js";
|
|
7
7
|
import { a as sessionZoneCarriedBy, n as calendarInstructionSchema, r as calendarSessionTimestamp, t as calculateCalendarTime } from "./calendar-instruction-CzqZbAPG.js";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { h as MemoryCategory, w as InsightMetadata } from "./types-
|
|
1
|
+
import { h as MemoryCategory, w as InsightMetadata } from "./types-CWdhXLxr.js";
|
|
2
2
|
//#region src/engine/extraction/memory-temporality-classifier.d.ts
|
|
3
3
|
type TemporalType = "static" | "dynamic";
|
|
4
4
|
type TemporalResolutionStatus = "resolved" | "unresolved" | "static";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { b as MemoryTier, l as DecayScore } from "./types-
|
|
1
|
+
import { b as MemoryTier, l as DecayScore } from "./types-CWdhXLxr.js";
|
|
2
2
|
//#region src/engine/operations/memory-tier-promoter.d.ts
|
|
3
3
|
interface TierConfig {
|
|
4
4
|
/** Minimum access count for Core promotion (default: 10) */
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import "./types-CWdhXLxr.js";
|
|
2
|
+
import "./index-DL8AVj0Z.js";
|
|
3
|
+
import "./embedding-provider-client-vynZMuit.js";
|
|
4
|
+
import "./retriever-Dxss5fRv.js";
|
|
5
|
+
import "./memory-metadata-codec-DUvsYe_X.js";
|
|
6
|
+
import "./store-C8sUTssE.js";
|
|
7
|
+
import "./capture-policy-detector-CxbHPkMX.js";
|
|
8
|
+
import "./memory-temporality-classifier-Brht5jyK.js";
|
|
9
|
+
import "./runtime-audit-log-zpQiR9HT.js";
|
|
10
|
+
import { z as z$1 } from "zod";
|
|
11
|
+
import "@snoai/chunking";
|
|
12
|
+
import "@sinclair/typebox";
|
|
13
|
+
import "async-mutex";
|
|
14
|
+
export { z$1 as t };
|
|
@@ -7,7 +7,7 @@ import "./internal/engine/shared/utils.js";
|
|
|
7
7
|
import "./all-resources-BQK2ugjB.js";
|
|
8
8
|
import "./capture-policy-detector-DaMfy9CZ.js";
|
|
9
9
|
import "./internal/engine/extraction/extraction-text-sanitizer.js";
|
|
10
|
-
import "./memory-temporality-classifier-
|
|
10
|
+
import "./memory-temporality-classifier-BUjXG5o7.js";
|
|
11
11
|
import "./runtime-audit-log-BCeujlEp.js";
|
|
12
12
|
import "./internal/engine/operations/daily-spend-estimator.js";
|
|
13
13
|
import "./internal/engine/operations/learning-file-maintenance.js";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { n as PluginObservability } from "./adapter-
|
|
1
|
+
import { n as PluginObservability } from "./adapter-B7Jox9-6.js";
|
|
2
2
|
import { r as EmbeddingConfig, t as Embedder } from "./embedding-provider-client-vynZMuit.js";
|
|
3
3
|
//#region src/engine/observability/observable-embedder.d.ts
|
|
4
4
|
type SessionUuidProvider = () => string | undefined;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { i as LlmClientConfig, r as LlmClient, s as MemoryLlmRequest } from "./plugin-config-schema-C0UUbOmG.js";
|
|
2
|
-
import { n as PluginObservability } from "./adapter-
|
|
2
|
+
import { n as PluginObservability } from "./adapter-B7Jox9-6.js";
|
|
3
3
|
import "./llm-client-DOTSGzhe.js";
|
|
4
4
|
//#region src/engine/observability/observable-llm-client.d.ts
|
|
5
5
|
type SessionUuidProvider = () => string | undefined;
|
package/dist/{observable-memory-store-BaZKbhgq.d.ts → observable-memory-store-CnGDpOY5.d.ts}
RENAMED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { b as MemoryTier, g as MemoryEntry, v as MemoryMetadata, y as MemorySearchResult } from "./types-
|
|
2
|
-
import { n as PluginObservability } from "./adapter-
|
|
1
|
+
import { b as MemoryTier, g as MemoryEntry, v as MemoryMetadata, y as MemorySearchResult } from "./types-CWdhXLxr.js";
|
|
2
|
+
import { n as PluginObservability } from "./adapter-B7Jox9-6.js";
|
|
3
3
|
import { r as EmbeddingConfig } from "./embedding-provider-client-vynZMuit.js";
|
|
4
|
-
import { C as MemoryStore, F as TaskLifecycleBatchWriteResult, M as SupersedeClose, N as SupersedePreserveExisting, P as TaskLifecycleBatchWriteInput, at as ListOptions, dt as RecordUnplacedCandidateResult, f as AtomicExtractionWriteResult, ft as SearchOptions, gt as StoreResult, ht as StoreInput, j as SupersedeActiveFactGuard, mt as StoreConfig, ot as MemoryRow, rt as ChunkSearchResult, u as AtomicExtractionWriteInput, ut as RecordUnplacedCandidateInput, w as MemoryStoreInternals, yt as UpdateChanges } from "./memory-store-base-
|
|
5
|
-
import "./store-
|
|
4
|
+
import { C as MemoryStore, F as TaskLifecycleBatchWriteResult, M as SupersedeClose, N as SupersedePreserveExisting, P as TaskLifecycleBatchWriteInput, at as ListOptions, dt as RecordUnplacedCandidateResult, f as AtomicExtractionWriteResult, ft as SearchOptions, gt as StoreResult, ht as StoreInput, j as SupersedeActiveFactGuard, mt as StoreConfig, ot as MemoryRow, rt as ChunkSearchResult, u as AtomicExtractionWriteInput, ut as RecordUnplacedCandidateInput, w as MemoryStoreInternals, yt as UpdateChanges } from "./memory-store-base-CQ_bHlYA.js";
|
|
5
|
+
import "./store-C8sUTssE.js";
|
|
6
6
|
//#region src/engine/observability/observable-memory-store.d.ts
|
|
7
7
|
type SessionUuidProvider = () => string | undefined;
|
|
8
8
|
declare class ObservableMemoryStore extends MemoryStore {
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { x as RetrievalResult } from "./types-
|
|
2
|
-
import { n as PluginObservability } from "./adapter-
|
|
1
|
+
import { x as RetrievalResult } from "./types-CWdhXLxr.js";
|
|
2
|
+
import { n as PluginObservability } from "./adapter-B7Jox9-6.js";
|
|
3
3
|
import { r as EmbeddingConfig, t as Embedder } from "./embedding-provider-client-vynZMuit.js";
|
|
4
|
-
import { d as RetrievalConfig, f as RetrievalContext, t as MemoryRetriever } from "./retriever-
|
|
5
|
-
import { C as MemoryStore } from "./memory-store-base-
|
|
6
|
-
import "./store-
|
|
4
|
+
import { d as RetrievalConfig, f as RetrievalContext, t as MemoryRetriever } from "./retriever-Dxss5fRv.js";
|
|
5
|
+
import { C as MemoryStore } from "./memory-store-base-CQ_bHlYA.js";
|
|
6
|
+
import "./store-C8sUTssE.js";
|
|
7
7
|
//#region src/engine/observability/observable-retriever.d.ts
|
|
8
8
|
type SessionUuidProvider = () => string | undefined;
|
|
9
9
|
type RetrievalTraceResult = Awaited<ReturnType<MemoryRetriever["retrieveWithTrace"]>>;
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { MAX_LIST_LIMIT } from "./internal/config/index.js";
|
|
2
2
|
import { SnoStationMemError, StorageError } from "./internal/engine/shared/errors.js";
|
|
3
3
|
import { a as buildInsightMetadata, c as stringifyInsightMetadata, h as deriveFactKey, s as parseInsightMetadata } from "./memory-metadata-codec-DL1sbJiN.js";
|
|
4
|
-
import { n as LlmClientTerminalError } from "./llm-client-
|
|
4
|
+
import { n as LlmClientTerminalError } from "./llm-client-BSYUAcUb.js";
|
|
5
5
|
import { resolveLlmRoute } from "./internal/model/llm-mode-routing.js";
|
|
6
6
|
import { boundSectionContent, buildIndexedText } from "./internal/engine/extraction/extraction-text-sanitizer.js";
|
|
7
7
|
import { d as runWithMutationAttempt, i as currentMutationAttemptId } from "./runtime-audit-log-BCeujlEp.js";
|
|
8
8
|
import { adapterAViewFromRecord, orderAdapterAPair, parseAdapterAChatVerdict, prospectiveProfileView, renderAdapterAChatPrompt, renderAdapterAPrompt } from "./internal/engine/rem/index.js";
|
|
9
|
-
import { C as TaskLifecycleStaleResolutionError, a as resolveTaskLifecycle, c as buildTaskLifecycleCommandClaim, i as findUniqueActiveTaskByDescription, l as resolveTaskLifecycleEffectiveTime, n as acceptsTaskLifecycleJudgment, o as taskLifecycleCandidateSetVersion, r as buildTaskLifecycleCandidateSet, s as admitTaskLifecycleAssertion, x as StaleSupersedeTargetError } from "./store-
|
|
9
|
+
import { C as TaskLifecycleStaleResolutionError, a as resolveTaskLifecycle, c as buildTaskLifecycleCommandClaim, i as findUniqueActiveTaskByDescription, l as resolveTaskLifecycleEffectiveTime, n as acceptsTaskLifecycleJudgment, o as taskLifecycleCandidateSetVersion, r as buildTaskLifecycleCandidateSet, s as admitTaskLifecycleAssertion, x as StaleSupersedeTargetError } from "./store-nPql26YM.js";
|
|
10
10
|
import { o as canonicalizeProfileSectionName, r as recordTokenCounter } from "./memory-store-write-validation-B_hDG2zf.js";
|
|
11
11
|
import { canExtractorWrite } from "./internal/engine/shared/memory-kind-policy.js";
|
|
12
12
|
import { resolveHookAgentId } from "./internal/engine/bindings/sno-station-mem-runtime-mode.js";
|
|
@@ -716,7 +716,7 @@ const LIFECYCLE_RETIREMENT_MAX_DEFERRALS = 3;
|
|
|
716
716
|
* the route can ever answer, and three timeouts is an ordinary afternoon on a busy GPU — counting
|
|
717
717
|
* them would throw away a retirement and leave the stale row it named live for good. A malformed
|
|
718
718
|
* or empty answer from a route that resolved ON is the failure that repeats, so it is the one
|
|
719
|
-
* that counts.
|
|
719
|
+
* that counts.
|
|
720
720
|
*/
|
|
721
721
|
function deferLifecycleRetirement(retiredClauses, incomingAssertion, liveSiblingSectionNames, attempts = 0, failure = "malformed-answer") {
|
|
722
722
|
const nextAttempts = failure === "transport" ? attempts : attempts + 1;
|
|
@@ -1188,7 +1188,7 @@ function renderRetirementRecheckPrompt(input) {
|
|
|
1188
1188
|
}
|
|
1189
1189
|
/**
|
|
1190
1190
|
* The second key on every clause the profile judgement retired from `preferences.general`.
|
|
1191
|
-
* Measured 2026-09-01 on the
|
|
1191
|
+
* Measured 2026-09-01 on the Memora store: 753 clauses were retired across 1,149
|
|
1192
1192
|
* rewrites, 317 of them shared no content word with the incoming assertion, and 238 of those in
|
|
1193
1193
|
* the general section had no live sibling carrying them; replayed one by one, 39 of 40 such
|
|
1194
1194
|
* retirements were judged wrong, while 14 of 20 genuine replacements were still retired. A
|
|
@@ -3,14 +3,14 @@ import { a as buildInsightMetadata, c as stringifyInsightMetadata } from "./memo
|
|
|
3
3
|
import { redactSecrets } from "./internal/engine/security/redact.js";
|
|
4
4
|
import { t as checkMemoryOperation } from "./operation-cancellation-CTKWwNHk.js";
|
|
5
5
|
import { setLruEntry } from "./internal/engine/shared/lru.js";
|
|
6
|
-
import { i as createLlmClient } from "./llm-client-
|
|
6
|
+
import { i as createLlmClient } from "./llm-client-BSYUAcUb.js";
|
|
7
7
|
import { pickLlmRoutingConfig } from "./internal/model/llm-mode-routing.js";
|
|
8
8
|
import { appendSelfImprovementEntry } from "./internal/engine/operations/learning-file-maintenance.js";
|
|
9
9
|
import { getSnoStationMemDataDir } from "./internal/store/data-paths.js";
|
|
10
10
|
import { resolveHookAgentId } from "./internal/engine/bindings/sno-station-mem-runtime-mode.js";
|
|
11
|
-
import { n as createRetireByNameRunBudget, r as runProfileSectionUpdate } from "./profile-section-writer-
|
|
11
|
+
import { n as createRetireByNameRunBudget, r as runProfileSectionUpdate } from "./profile-section-writer-BhGKPBjw.js";
|
|
12
12
|
import { a as generateReflectionText, c as shouldSkipReflectionMessage, l as writeReflectionToFilesystem, s as readSessionConversationWithResetFallback, u as extractTextContent } from "./daily-log-generator-CH_KuWHs.js";
|
|
13
|
-
import { a as resolveWorkspaceDirFromEvent, f as setReflectionDerivedCacheEntry, l as isSessionBoundaryReflectionAction, n as createReflectionGenerator, o as DEFAULT_REFLECTION_BOUNDARY_DERIVED_SUPPRESSION_MS, t as DEFAULT_MEMORY_LLM_CONFIG, u as setReflectionDerivedSuppression } from "./reflection-embedded-generator-
|
|
13
|
+
import { a as resolveWorkspaceDirFromEvent, f as setReflectionDerivedCacheEntry, l as isSessionBoundaryReflectionAction, n as createReflectionGenerator, o as DEFAULT_REFLECTION_BOUNDARY_DERIVED_SUPPRESSION_MS, t as DEFAULT_MEMORY_LLM_CONFIG, u as setReflectionDerivedSuppression } from "./reflection-embedded-generator-BRvqV5N-.js";
|
|
14
14
|
import { i as buildReflectionMappedMetadata, n as createReflectionEventId, o as extractInjectableReflectionMappedMemoryItems, r as buildReflectionAntiPatternSignature, s as extractReflectionLearningGovernanceCandidates, t as storeReflectionEntries } from "./memory-entry-projector-DHo8jH10.js";
|
|
15
15
|
import { createLogger, currentLogContext, privateLogReference, withLogContext } from "@snoai/utils/logger";
|
|
16
16
|
import { basename, join } from "node:path";
|
|
@@ -224,7 +224,7 @@ function governanceEntryType(area) {
|
|
|
224
224
|
*/
|
|
225
225
|
const diagnosticLog$1 = createLogger("sno-station-mem:session-serial-guard");
|
|
226
226
|
/**
|
|
227
|
-
* Serial guard for reflection
|
|
227
|
+
* Serial guard for reflection.
|
|
228
228
|
*
|
|
229
229
|
* Two distinct protections:
|
|
230
230
|
* (1) In-flight lock - boolean, no time bound, blocks parallel re-entry.
|
package/dist/{reflection-command-hooks-C1Vxgb-O.d.ts → reflection-command-hooks-G1-dI2Av.d.ts}
RENAMED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { t as PluginConfig } from "./plugin-config-schema-C0UUbOmG.js";
|
|
2
|
-
import "./types-
|
|
2
|
+
import "./types-CWdhXLxr.js";
|
|
3
3
|
import { n as createErrorSignalTracker } from "./error-signals-D8_3vYu4.js";
|
|
4
|
-
import { n as ReflectionDerivedCache, t as ReflectionDerivedSuppressionCache } from "./derived-suppression-cache-
|
|
5
|
-
import { t as ReflectionDeps } from "./reflection-deps-
|
|
4
|
+
import { n as ReflectionDerivedCache, t as ReflectionDerivedSuppressionCache } from "./derived-suppression-cache-CI0durYx.js";
|
|
5
|
+
import { t as ReflectionDeps } from "./reflection-deps-Ccm2Jf5W.js";
|
|
6
6
|
//#region src/engine/reflection/reflection-command-hooks.d.ts
|
|
7
7
|
declare function createRunMemoryReflection(params: ReflectionCommandParams): (event: {
|
|
8
8
|
sessionKey: string;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { n as AgentLlmPort } from "./agent-llm-port-5oXgBpzJ.js";
|
|
2
2
|
import { n as createEmbedder } from "./embedding-provider-client-vynZMuit.js";
|
|
3
|
-
import { C as MemoryStore } from "./memory-store-base-
|
|
4
|
-
import "./store-
|
|
3
|
+
import { C as MemoryStore } from "./memory-store-base-CQ_bHlYA.js";
|
|
4
|
+
import "./store-C8sUTssE.js";
|
|
5
5
|
import { r as MemoryTelemetryUsageOutbox } from "./memory-telemetry-outbox-ddTdImt7.js";
|
|
6
6
|
import { n as createScopePolicy } from "./memory-scope-policy-1gg5QlWZ.js";
|
|
7
7
|
//#region src/engine/reflection/reflection-deps.d.ts
|
package/dist/{reflection-embedded-generator-CDUhgV96.js → reflection-embedded-generator-BRvqV5N-.js}
RENAMED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { X as FIXED_MEMORY_SNO_AI_EXTRACT } from "./signed-registry-constants-yq3DlG3B.js";
|
|
2
|
-
import { i as createLlmClient } from "./llm-client-
|
|
2
|
+
import { i as createLlmClient } from "./llm-client-BSYUAcUb.js";
|
|
3
3
|
//#region src/engine/reflection/derived-line-cache.ts
|
|
4
4
|
/**
|
|
5
5
|
* Returns reflection derived cache entry from reflection cache keys state without side effects.
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { p as LlmRoutingConfig, t as PluginConfig } from "./plugin-config-schema-C0UUbOmG.js";
|
|
2
|
-
import "./types-
|
|
2
|
+
import "./types-CWdhXLxr.js";
|
|
3
3
|
import { n as AgentLlmPort } from "./agent-llm-port-5oXgBpzJ.js";
|
|
4
4
|
import { n as ReflectionGenerator } from "./daily-log-generator-CsQPHl4A.js";
|
|
5
5
|
import { n as createErrorSignalTracker } from "./error-signals-D8_3vYu4.js";
|
|
6
|
-
import { n as ReflectionDerivedCache, t as ReflectionDerivedSuppressionCache } from "./derived-suppression-cache-
|
|
6
|
+
import { n as ReflectionDerivedCache, t as ReflectionDerivedSuppressionCache } from "./derived-suppression-cache-CI0durYx.js";
|
|
7
7
|
//#region src/engine/reflection/reflection-embedded-generator.d.ts
|
|
8
8
|
declare const DEFAULT_MEMORY_LLM_CONFIG: NonNullable<PluginConfig["extraction"]["llm"]>;
|
|
9
9
|
declare function isInternalReflectionSessionKey(sessionKey: unknown): boolean;
|
package/dist/{reflection-injection-hooks-DfUgqu8f.d.ts → reflection-injection-hooks-CS_uhjoD.d.ts}
RENAMED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { t as PluginConfig } from "./plugin-config-schema-C0UUbOmG.js";
|
|
2
|
-
import "./types-
|
|
3
|
-
import "./store-
|
|
2
|
+
import "./types-CWdhXLxr.js";
|
|
3
|
+
import "./store-C8sUTssE.js";
|
|
4
4
|
import { r as MemoryTelemetryUsageOutbox } from "./memory-telemetry-outbox-ddTdImt7.js";
|
|
5
5
|
import { n as createScopePolicy } from "./memory-scope-policy-1gg5QlWZ.js";
|
|
6
6
|
import { n as createErrorSignalTracker } from "./error-signals-D8_3vYu4.js";
|
|
7
|
-
import { n as ReflectionDerivedCache, r as LoadedReflectionSlices, t as ReflectionDerivedSuppressionCache } from "./derived-suppression-cache-
|
|
7
|
+
import { n as ReflectionDerivedCache, r as LoadedReflectionSlices, t as ReflectionDerivedSuppressionCache } from "./derived-suppression-cache-CI0durYx.js";
|
|
8
8
|
//#region src/engine/reflection/reflection-slice-loader.d.ts
|
|
9
9
|
interface ReflectionSliceLoader {
|
|
10
10
|
loadAgentReflectionSlices: (agentId: string, projectIdFilter: string[]) => Promise<LoadedReflectionSlices>;
|
package/dist/{reflection-lifecycle-hooks-Ct5HBdSG.d.ts → reflection-lifecycle-hooks-CRSpUdLi.d.ts}
RENAMED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { t as PluginConfig } from "./plugin-config-schema-C0UUbOmG.js";
|
|
2
|
-
import "./types-
|
|
2
|
+
import "./types-CWdhXLxr.js";
|
|
3
3
|
import { n as createErrorSignalTracker } from "./error-signals-D8_3vYu4.js";
|
|
4
|
-
import { n as ReflectionDerivedCache, t as ReflectionDerivedSuppressionCache } from "./derived-suppression-cache-
|
|
4
|
+
import { n as ReflectionDerivedCache, t as ReflectionDerivedSuppressionCache } from "./derived-suppression-cache-CI0durYx.js";
|
|
5
5
|
//#region src/engine/reflection/reflection-lifecycle-hooks.d.ts
|
|
6
6
|
type ReflectionLifecycleParams = {
|
|
7
7
|
reflectionCfg: PluginConfig["memoryReflection"];
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { o as runRemProductionOrderedWave } from "./rem-batch-executor-
|
|
1
|
+
import { o as runRemProductionOrderedWave } from "./rem-batch-executor-DuC4nYyf.js";
|
|
2
2
|
export { runRemProductionOrderedWave };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { $ as
|
|
1
|
+
import { $ as FIXED_IDX_MEMORY_ACTIVE_TASK_EVIDENCE_INSTANCE, $n as MAX_CHUNK_FETCH_LIMIT, $t as FIXED_VEC_MEMORY, At as FIXED_MEMORY_PROVIDER_AGENT_MAPPINGS, B as FIXED_EXTERNAL_VALUE_51, C as getSnoStationMemStateDir, Cn as CHUNK_TARGET_TOKENS, Cr as LOCAL_EMBEDDING_CACHE_DIR_DEFAULT, Ct as FIXED_MEMORY_CHUNKS_MEM_IDX, D as settingsToPluginConfig, Dn as DEFAULT_RECALL_LIFECYCLE, Dr as ensureModelDownloaded, Dt as FIXED_MEMORY_MEMORIES_FACT_ID_UPDATE_GUARD, En as DEFAULT_IMPORTANCE, Er as LocalEmbedProvider, Et as FIXED_MEMORY_MEMORIES_FACT_ID_INSERT_GUARD, Fn as EMBEDDER_DIM, Ft as FIXED_MEMORY_SNO_EXTRACT_CHAT, G as FIXED_EXTERNAL_VALUE_56, Gt as FIXED_PROTOCOL_VALUE_69, H as FIXED_EXTERNAL_VALUE_53, Hn as HEAD_EXTRACT_OVERLAP_DROP_RATIO, In as EMBEDDER_MODEL_DEFAULT, J as FIXED_EXTERNAL_VALUE_62, Jn as LIGHTWEIGHT_FUSION_WEIGHT, K as FIXED_EXTERNAL_VALUE_57, Kn as INTRA_MEMORY_COSINE_THRESHOLD, Kt as FIXED_PROTOCOL_VALUE_73, Ln as EMBEDDER_PROVIDER_DEFAULT, Lt as FIXED_MEMORY_TASK_LIFECYCLE_COMMANDS, Mn as DEFAULT_RERANK_TIMEOUT_MS, Mt as FIXED_MEMORY_PROVIDER_PROJECT_MAPPINGS, O as MODEL_CALLS, Ot as FIXED_MEMORY_MIGRATION_MARKERS, Pn as DEFAULT_VECTOR_WEIGHT, Q as FIXED_IDX_MEMORY_ACTIVE_TASK_CURRENT_REVISION, Rn as EVAL_QA_TRACES_FILENAME, Rt as FIXED_MEMORY_UNPLACED_CANDIDATES, Sn as CHUNK_OVERLAP_TOKENS, Sr as CachedEmbeddingProvider, St as FIXED_MEMORY_CHUNKS_MEM_FACET_IDX, T as readSettings, Tn as DEFAULT_BM25_WEIGHT, Tt as FIXED_MEMORY_MEMORIES, U as FIXED_EXTERNAL_VALUE_54, Un as HEAD_EXTRACT_TOKEN_BUDGET, V as FIXED_EXTERNAL_VALUE_52, Vn as HEAD_EXTRACT_MIN_CONTENT_TOKENS, W as FIXED_EXTERNAL_VALUE_55, Wn as IMPORTANCE_WEIGHT_BASE, X as FIXED_EXTERNAL_VALUE_9, Y as FIXED_EXTERNAL_VALUE_8, Yn as LIGHTWEIGHT_RERANK_PENALTY, Z as FIXED_IDX_MEMORY, _n as BONUS_TOTAL_INVARIANT, _t as FIXED_MEMORY_CHUNKS_AD, a as REM_MODEL_OUTPUT_TOKEN_CAP, ar as MULTI_HIT_BONUS_CAP, at as FIXED_IDX_MEMORY_MEMORIES_PROJECT, bn as CHUNK_MAX_TOKENS, br as experimentMmrDisabled, bt as FIXED_MEMORY_CHUNKS_FTS, cr as RECENCY_WEIGHT, ct as FIXED_IDX_MEMORY_MEMORIES_PROJECT_TIMESTAMP, dr as RERANK_BLEND_CROSS, dt as FIXED_MEMORY_ACTIVE_TASK_INSTANCES, en as FIXED_VEC_MEMORY_CHUNKS, er as MAX_LIST_LIMIT, et as FIXED_IDX_MEMORY_ACTIVE_TASK_INSTANCES_PROJECTION, fr as RERANK_BLEND_VECTOR, ft as FIXED_MEMORY_ACTIVE_TASK_MIGRATION_EVIDENCE, g as readRemOperationalConfig, gt as FIXED_MEMORY_CHUNKS, hr as TIME_DECAY_FLOOR, ht as FIXED_MEMORY_ACTIVE_TASK_TRANSITIONS, in as PERSISTED_PROVIDER_SYSTEM, ir as MMR_LAMBDA, it as FIXED_IDX_MEMORY_MEMORIES_LANE_PROJECT, jn as DEFAULT_RERANK_MODEL, jt as FIXED_MEMORY_PROVIDER_PROJECT_AGENTS, k as modelCallDestination, kt as FIXED_MEMORY_PROFILE_RECOVERY_ENTRIES, ln as ADJACENCY_BONUS_CAP, lt as FIXED_MEMORY, mt as FIXED_MEMORY_ACTIVE_TASK_REVISIONS, nn as PERSISTED_CONTENT_HASH_V1, nt as FIXED_IDX_MEMORY_MEMORIES_CONTENT_HASH, on as llmRoutingConfigSchema, or as MULTI_HIT_BONUS_PER_HIT, ot as FIXED_IDX_MEMORY_MEMORIES_PROJECT_CONTENT_HASH, pr as RETRIEVAL_STORAGE_CHUNK_PROFILE, pt as FIXED_MEMORY_ACTIVE_TASK_MIGRATION_MANIFESTS, q as FIXED_EXTERNAL_VALUE_58, qn as LIGHTWEIGHT_COSINE_WEIGHT, rn as PERSISTED_CONTENT_HASH_V3, rt as FIXED_IDX_MEMORY_MEMORIES_FACT_ID, sn as SUPPORTED_LOCALES, st as FIXED_IDX_MEMORY_MEMORIES_PROJECT_FACT_KEY_ACTIVE, tn as PERSISTED_CANDIDATE_HASH_V1, tt as FIXED_IDX_MEMORY_MEMORIES_CATEGORY, un as ADJACENCY_BONUS_PER_PAIR, ut as FIXED_MEMORY_ACTIVE_TASK_EVIDENCE, vn as CACHE_TTL_MS, vt as FIXED_MEMORY_CHUNKS_AI, wn as CHUNK_TOKENIZER_MODE, wr as LOCAL_EMBEDDING_MODEL, wt as FIXED_MEMORY_EXTRACTION_TIMESTAMPS, xn as CHUNK_MIN_TOKENS, xt as FIXED_MEMORY_CHUNKS_MEMORY_ID_IDX, yn as CHUNKING_VERSION$1, yr as experimentCandidatePoolOverride, yt as FIXED_MEMORY_CHUNKS_AU, z as FIXED_EXTERNAL_VALUE_49 } from "./config-CL90qYva.js";
|
|
2
2
|
import { createLogger, createLogger as createLogger$1, currentLogContext, privateLogReference, withLogContext } from "@snoai/utils/logger";
|
|
3
3
|
import path, { dirname, join, resolve } from "node:path";
|
|
4
4
|
import { appendFileSync, createReadStream, existsSync, mkdirSync, readFileSync, realpathSync, writeFileSync } from "node:fs";
|
|
@@ -5890,11 +5890,7 @@ const SNO_STATION_MEM_RELEASE_ANCHOR_URL = FIXED_EXTERNAL_VALUE_8;
|
|
|
5890
5890
|
const SNO_STATION_MEM_RELEASE_KEY_ID = FIXED_EXTERNAL_VALUE_9;
|
|
5891
5891
|
const SNO_STATION_MEM_RELEASE_ANCHOR_ATTEMPTS = 2;
|
|
5892
5892
|
const SNO_STATION_MEM_RELEASE_ANCHOR_RETRY_DELAY_MS = 50;
|
|
5893
|
-
const ALLOWED_HTTP_ENDPOINT_HOSTS = /* @__PURE__ */ new Set([
|
|
5894
|
-
"localhost",
|
|
5895
|
-
"127.0.0.1",
|
|
5896
|
-
"100.100.200.71"
|
|
5897
|
-
]);
|
|
5893
|
+
const ALLOWED_HTTP_ENDPOINT_HOSTS = /* @__PURE__ */ new Set(["localhost", "127.0.0.1"]);
|
|
5898
5894
|
function parsePresetId(preset) {
|
|
5899
5895
|
const [module, presetName] = preset.split("/");
|
|
5900
5896
|
if (!module || !presetName) throw new Error(`sno-station-mem llm-client: invalid LLMIx preset id "${preset}"`);
|
|
@@ -14851,7 +14847,7 @@ function isSafeInteger(value) {
|
|
|
14851
14847
|
/**
|
|
14852
14848
|
* The order key a row carries, or the one a row written before this change is treated as having.
|
|
14853
14849
|
*
|
|
14854
|
-
* A row from before
|
|
14850
|
+
* A row from before source order was persisted has no `source_order` until the maintenance pass backfills it, and an
|
|
14855
14851
|
* ordinary wave must keep running over such a store rather than throwing. Those rows are older
|
|
14856
14852
|
* than everything written since — that is what "written before" means — so they read as the
|
|
14857
14853
|
* lowest possible key: anything may close them, and they may close nothing.
|
|
@@ -17943,7 +17939,7 @@ function ensureChunkVecTable(db, vectorDim) {
|
|
|
17943
17939
|
return verified.dimension;
|
|
17944
17940
|
}
|
|
17945
17941
|
/**
|
|
17946
|
-
*
|
|
17942
|
+
* Loads the wangfenjin/simple SQLite
|
|
17947
17943
|
* tokenizer extension and registers its jieba dictionary path. Called once
|
|
17948
17944
|
* per connection, BEFORE migrations run, so 0006 can create the
|
|
17949
17945
|
* `nodix_memory_chunks_fts` virtual table with `tokenize='simple 0'`.
|
|
@@ -18066,7 +18062,7 @@ function ensureColumn(database, tableName, columnName, declaration) {
|
|
|
18066
18062
|
*/
|
|
18067
18063
|
const log$11 = createLogger("sno-station-mem:store");
|
|
18068
18064
|
/**
|
|
18069
|
-
*
|
|
18065
|
+
* Reflection v3: discriminator added to content-hash input when the
|
|
18070
18066
|
* row carries a `metadata.mappedKind`. Two rows with same projectId + same store
|
|
18071
18067
|
* category + same text but distinct mappedKinds (e.g. user-model vs
|
|
18072
18068
|
* agent-model both → category=preference) must coexist as distinct rows. The
|
|
@@ -26341,7 +26337,7 @@ function createEmbedder(config, stateDir) {
|
|
|
26341
26337
|
* @boundary Filesystem (JSONL/JSON write) and config constants surface.
|
|
26342
26338
|
* @see ../retrieval/retriever.ts, ../../config/index.ts.
|
|
26343
26339
|
*
|
|
26344
|
-
* Minimum-viable trace emission
|
|
26340
|
+
* Minimum-viable trace emission. Off by default; enabled by the
|
|
26345
26341
|
* eval harness via `EVAL_TRACE_ENABLED=true` (env or build constant) and a
|
|
26346
26342
|
* run-dir provided via `EVAL_TRACE_DIR` (env). Phase 0 instrumentation
|
|
26347
26343
|
* (MRR/Recall, gold-rank, miss classification) remains explicitly waived.
|
|
@@ -26904,7 +26900,7 @@ var TraceCollector = class {
|
|
|
26904
26900
|
* @boundary Types and defaults only; no ranking execution.
|
|
26905
26901
|
*/
|
|
26906
26902
|
/**
|
|
26907
|
-
* The serving-path validity default
|
|
26903
|
+
* The serving-path validity default. This is the one named code
|
|
26908
26904
|
* point that supplies it: reading the default here is what makes the
|
|
26909
26905
|
* invalidated-row filter a property of the serving path rather than a parameter
|
|
26910
26906
|
* every caller has to remember, and the omission is no longer silent.
|
|
@@ -26914,7 +26910,7 @@ var TraceCollector = class {
|
|
|
26914
26910
|
*
|
|
26915
26911
|
* Scope is the retriever, never the store layer: six write-side consumers (dedup,
|
|
26916
26912
|
* reflection loops, observability, the REM batch executor) call the store search
|
|
26917
|
-
* APIs directly and legitimately read invalidated rows.
|
|
26913
|
+
* APIs directly and legitimately read invalidated rows. Do not move this
|
|
26918
26914
|
* down a layer.
|
|
26919
26915
|
*/
|
|
26920
26916
|
function withServingValidityDefault(context) {
|
|
@@ -27946,7 +27942,7 @@ function getTierFloor(tier) {
|
|
|
27946
27942
|
}
|
|
27947
27943
|
}
|
|
27948
27944
|
/**
|
|
27949
|
-
* Multiplier formula
|
|
27945
|
+
* Multiplier formula + retention-
|
|
27950
27946
|
* scoring spec §62. Bounded to `[SEARCH_BOOST_MIN, 1.0]`; never amplifies,
|
|
27951
27947
|
* only suppresses, so existing scores are an upper bound after the stage.
|
|
27952
27948
|
*
|
|
@@ -30499,7 +30495,7 @@ function invalidWriterOperation(writer, row, successor) {
|
|
|
30499
30495
|
/**
|
|
30500
30496
|
* The order key a row carries, or the order it can still be given from what it has.
|
|
30501
30497
|
*
|
|
30502
|
-
*
|
|
30498
|
+
* Extraction persists `metadata.source_order` on every row extraction writes, and the maintenance pass
|
|
30503
30499
|
* backfills the rows written before it. Until that pass has run on a store, its rows have no key,
|
|
30504
30500
|
* and the wave still has to order them: a row's own content time is what it has, and that is what
|
|
30505
30501
|
* the executor compared before this change. Falling back to it keeps an unmigrated store working
|
|
@@ -31334,7 +31330,7 @@ async function buildRemReplaceCandidateQueue(input) {
|
|
|
31334
31330
|
* A profile or state row about a subject is paired with that subject's live profile and state rows
|
|
31335
31331
|
* by similarity alone, no floor: extraction files one fact under different categories, sections
|
|
31336
31332
|
* and attributes run to run, and a real correction pair scored 0.571 to 0.688, below any floor
|
|
31337
|
-
* that keeps unrelated rows out
|
|
31333
|
+
* that keeps unrelated rows out. Such a row still runs the threshold search, so a
|
|
31338
31334
|
* pair with a row outside that set keeps address and threshold pairing.
|
|
31339
31335
|
*/
|
|
31340
31336
|
function pairsBySubject(candidate) {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { DEFAULT_RECALL_TOKEN_BUDGET, MIN_RECALL_TOKEN_BUDGET } from "./internal/config/index.js";
|
|
2
|
-
import { o as readMemorySourceOrderOrOldest, r as compareMemorySourceOrder } from "./memory-source-order-
|
|
2
|
+
import { o as readMemorySourceOrderOrOldest, r as compareMemorySourceOrder } from "./memory-source-order-YMRoeDLd.js";
|
|
3
3
|
//#region src/engine/retrieval/recall-token-packer.ts
|
|
4
4
|
/** @file recall-token-packer.ts
|
|
5
5
|
* @purpose Packs recall rows into a character-estimated token budget without changing rank order.
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import { $ as appendAuditEntryStrict, r as enumerateRemCandidateScopes, tt as getAuditPath } from "./rem-batch-executor-
|
|
2
|
-
import {
|
|
1
|
+
import { $ as appendAuditEntryStrict, r as enumerateRemCandidateScopes, tt as getAuditPath } from "./rem-batch-executor-DuC4nYyf.js";
|
|
2
|
+
import { s as REM_SIDECAR_TOKEN_HEADER } from "./routes-DLHT__Ay.js";
|
|
3
|
+
import { d as getRemDiscoveryPath, o as REM_RUN_PATH, r as REM_CORRELATION_ID_HEADER, s as REM_SIDECAR_HOST } from "./config-CL90qYva.js";
|
|
3
4
|
import { createLogger } from "@snoai/utils/logger";
|
|
4
5
|
import path from "node:path";
|
|
5
6
|
import { z } from "zod";
|
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import { h as MemoryCategory, l as DecayScore, r as AggregationQuery, u as DecayableMemory, x as RetrievalResult, y as MemorySearchResult } from "./types-
|
|
1
|
+
import { h as MemoryCategory, l as DecayScore, r as AggregationQuery, u as DecayableMemory, x as RetrievalResult, y as MemorySearchResult } from "./types-CWdhXLxr.js";
|
|
2
2
|
import { sn as RecallLifecycleConfig } from "./index-DL8AVj0Z.js";
|
|
3
3
|
import { t as Embedder } from "./embedding-provider-client-vynZMuit.js";
|
|
4
|
-
import "./trace-
|
|
5
|
-
import "./memory-metadata-codec-
|
|
6
|
-
import { K as RemFacetPolicy } from "./index-
|
|
7
|
-
import { C as MemoryStore } from "./memory-store-base-
|
|
8
|
-
import "./store-
|
|
9
|
-
import { n as AccessTracker } from "./access-tracker-
|
|
10
|
-
import { r as TierPromoter } from "./memory-tier-promoter-
|
|
4
|
+
import "./trace-C1JxMfs-.js";
|
|
5
|
+
import "./memory-metadata-codec-DUvsYe_X.js";
|
|
6
|
+
import { K as RemFacetPolicy } from "./index-BO4RU_mc.js";
|
|
7
|
+
import { C as MemoryStore } from "./memory-store-base-CQ_bHlYA.js";
|
|
8
|
+
import "./store-C8sUTssE.js";
|
|
9
|
+
import { n as AccessTracker } from "./access-tracker-BbEvEocb.js";
|
|
10
|
+
import { r as TierPromoter } from "./memory-tier-promoter-CqGxCkue.js";
|
|
11
11
|
import "@snoai/utils/logger";
|
|
12
12
|
//#region src/engine/retrieval/retrieval-trace.d.ts
|
|
13
13
|
/** @file retrieval-trace.ts
|
|
@@ -266,7 +266,7 @@ interface RetrievalConfig {
|
|
|
266
266
|
/** Hard cap: effective half-life <= baseHalfLife * maxHalfLifeMultiplier (default: 3) */
|
|
267
267
|
maxHalfLifeMultiplier?: number;
|
|
268
268
|
/**
|
|
269
|
-
* Phase 0 retention-loop knobs
|
|
269
|
+
* Phase 0 retention-loop knobs.
|
|
270
270
|
* Optional so legacy `RetrievalConfig` literals keep parsing; resolved
|
|
271
271
|
* default in `DEFAULT_RETRIEVAL_CONFIG` is `DEFAULT_RECALL_LIFECYCLE`
|
|
272
272
|
* (all booleans `false`), making the new wire sites pass-through.
|
|
@@ -284,7 +284,7 @@ interface RetrievalContext {
|
|
|
284
284
|
/**
|
|
285
285
|
* Refused fallback rows carry the user's own words and are served by default; product
|
|
286
286
|
* entrypoints pass true, and only an explicit false hides them (owner ruling 2026-09-01,
|
|
287
|
-
* reversing
|
|
287
|
+
* reversing an earlier default). Omitted low-level/internal reads preserve all rows.
|
|
288
288
|
*/
|
|
289
289
|
includeRefused?: boolean;
|
|
290
290
|
signal?: AbortSignal;
|
|
@@ -299,12 +299,12 @@ interface RetrievalContext {
|
|
|
299
299
|
/** Selects current chunks only unless a non-user consumer explicitly requests history. */
|
|
300
300
|
facetPolicy?: RemFacetPolicy;
|
|
301
301
|
/**
|
|
302
|
-
* Tombstone exclusion
|
|
302
|
+
* Tombstone exclusion. When set, the store search
|
|
303
303
|
* drops candidates whose `metadata.invalidated_at <= excludeInvalidatedBefore`.
|
|
304
304
|
* A superseded fact is obsolete regardless of recall mode (OD-3, FAA binary),
|
|
305
305
|
* so omitting it on a serving path does not mean "serve everything": both
|
|
306
306
|
* retriever entrypoints run the context through `withServingValidityDefault`
|
|
307
|
-
* first
|
|
307
|
+
* first. Pass `0` for a deliberate history read.
|
|
308
308
|
*/
|
|
309
309
|
excludeInvalidatedBefore?: number;
|
|
310
310
|
includeRetired?: boolean;
|
|
@@ -316,7 +316,7 @@ interface RetrievalContext {
|
|
|
316
316
|
excludeSuperseded?: boolean;
|
|
317
317
|
}
|
|
318
318
|
/**
|
|
319
|
-
* The serving-path validity default
|
|
319
|
+
* The serving-path validity default. This is the one named code
|
|
320
320
|
* point that supplies it: reading the default here is what makes the
|
|
321
321
|
* invalidated-row filter a property of the serving path rather than a parameter
|
|
322
322
|
* every caller has to remember, and the omission is no longer silent.
|
|
@@ -326,7 +326,7 @@ interface RetrievalContext {
|
|
|
326
326
|
*
|
|
327
327
|
* Scope is the retriever, never the store layer: six write-side consumers (dedup,
|
|
328
328
|
* reflection loops, observability, the REM batch executor) call the store search
|
|
329
|
-
* APIs directly and legitimately read invalidated rows.
|
|
329
|
+
* APIs directly and legitimately read invalidated rows. Do not move this
|
|
330
330
|
* down a layer.
|
|
331
331
|
*/
|
|
332
332
|
declare function withServingValidityDefault(context: RetrievalContext): RetrievalContext;
|
|
@@ -185,7 +185,7 @@ var TraceCollector = class {
|
|
|
185
185
|
* @boundary Types and defaults only; no ranking execution.
|
|
186
186
|
*/
|
|
187
187
|
/**
|
|
188
|
-
* The serving-path validity default
|
|
188
|
+
* The serving-path validity default. This is the one named code
|
|
189
189
|
* point that supplies it: reading the default here is what makes the
|
|
190
190
|
* invalidated-row filter a property of the serving path rather than a parameter
|
|
191
191
|
* every caller has to remember, and the omission is no longer silent.
|
|
@@ -195,7 +195,7 @@ var TraceCollector = class {
|
|
|
195
195
|
*
|
|
196
196
|
* Scope is the retriever, never the store layer: six write-side consumers (dedup,
|
|
197
197
|
* reflection loops, observability, the REM batch executor) call the store search
|
|
198
|
-
* APIs directly and legitimately read invalidated rows.
|
|
198
|
+
* APIs directly and legitimately read invalidated rows. Do not move this
|
|
199
199
|
* down a layer.
|
|
200
200
|
*/
|
|
201
201
|
function withServingValidityDefault(context) {
|
|
@@ -1256,7 +1256,7 @@ function getTierFloor(tier) {
|
|
|
1256
1256
|
}
|
|
1257
1257
|
}
|
|
1258
1258
|
/**
|
|
1259
|
-
* Multiplier formula
|
|
1259
|
+
* Multiplier formula + retention-
|
|
1260
1260
|
* scoring spec §62. Bounded to `[SEARCH_BOOST_MIN, 1.0]`; never amplifies,
|
|
1261
1261
|
* only suppresses, so existing scores are an upper bound after the stage.
|
|
1262
1262
|
*
|
|
@@ -39,6 +39,7 @@ const MEMORY_ROUTES = {
|
|
|
39
39
|
};
|
|
40
40
|
const MEMORY_BODY_LIMIT_BYTES = 8388608;
|
|
41
41
|
const MEMORY_SKIN_HEADER = "x-sno-station-mem-skin";
|
|
42
|
+
const REM_SIDECAR_TOKEN_HEADER = "x-sidecar-token";
|
|
42
43
|
function memoryMethod(pathname) {
|
|
43
44
|
return Object.keys(MEMORY_ROUTES).find((method) => MEMORY_ROUTES[method].path === pathname);
|
|
44
45
|
}
|
|
@@ -56,4 +57,4 @@ const MEMORY_ERROR_STATUS = {
|
|
|
56
57
|
const MEMORY_RECONNECT_INTERVAL_MS = 1e3;
|
|
57
58
|
const MEMORY_DEFAULT_SKIN_ID = "default";
|
|
58
59
|
//#endregion
|
|
59
|
-
export { MEMORY_ROUTES as a, MEMORY_RECONNECT_INTERVAL_MS as i, MEMORY_DEFAULT_SKIN_ID as n, MEMORY_SKIN_HEADER as o, MEMORY_ERROR_STATUS as r,
|
|
60
|
+
export { MEMORY_ROUTES as a, memoryMethod as c, MEMORY_RECONNECT_INTERVAL_MS as i, MEMORY_DEFAULT_SKIN_ID as n, MEMORY_SKIN_HEADER as o, MEMORY_ERROR_STATUS as r, REM_SIDECAR_TOKEN_HEADER as s, MEMORY_BODY_LIMIT_BYTES as t };
|