@remnic/core 9.3.665 → 9.3.666
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/access-audit.js +2 -2
- package/dist/access-cli.js +41 -40
- package/dist/access-cli.js.map +1 -1
- package/dist/access-http.d.ts +3 -2
- package/dist/access-http.js +25 -25
- package/dist/access-mcp.d.ts +3 -2
- package/dist/access-mcp.js +22 -22
- package/dist/access-schema.d.ts +36 -36
- package/dist/access-schema.js +3 -3
- package/dist/{access-service-D0SLB4MH.d.ts → access-service-DsS-TatL.d.ts} +1 -1
- package/dist/access-service.d.ts +3 -2
- package/dist/access-service.js +21 -21
- package/dist/adapters/index.js +4 -4
- package/dist/adapters/registry.js +2 -2
- package/dist/bootstrap.d.ts +2 -1
- package/dist/briefing.js +4 -3
- package/dist/capabilities.d.ts +73 -0
- package/dist/capabilities.js +8 -0
- package/dist/capabilities.js.map +1 -0
- package/dist/causal-behavior.js +2 -2
- package/dist/causal-chain.js +2 -2
- package/dist/causal-consolidation.js +7 -6
- package/dist/causal-consolidation.js.map +1 -1
- package/dist/causal-retrieval.js +2 -2
- package/dist/causal-trajectory.js +1 -1
- package/dist/{chunk-ROHLEUTH.js → chunk-23EBQ27U.js} +5 -5
- package/dist/{chunk-YW52BQSU.js → chunk-2TCHDANJ.js} +2 -2
- package/dist/{chunk-IROWLAWG.js → chunk-46WUVFOD.js} +4 -4
- package/dist/{chunk-7C4MPEPE.js → chunk-4T7P2HLJ.js} +3 -3
- package/dist/{chunk-7XH7VJN4.js → chunk-6T4LTI2F.js} +4 -4
- package/dist/{chunk-TVVEYCNW.js → chunk-7K5Q6COX.js} +4 -4
- package/dist/{chunk-BZG2CWOQ.js → chunk-A5TEHAR4.js} +3 -3
- package/dist/{chunk-C7AF236A.js → chunk-AARDBQTA.js} +2 -2
- package/dist/{chunk-IHG6CC7T.js → chunk-BQJUPECT.js} +2 -2
- package/dist/{chunk-7OGJQP7T.js → chunk-CRO4LCQ6.js} +5 -5
- package/dist/{chunk-YNDLCWXS.js → chunk-EZ25VE3G.js} +4 -4
- package/dist/{chunk-WH4SKYPX.js → chunk-GZ6QAYSH.js} +94 -74
- package/dist/chunk-GZ6QAYSH.js.map +1 -0
- package/dist/{chunk-UXA5L2DZ.js → chunk-HQCGRSRU.js} +2 -2
- package/dist/{chunk-RKNJBZ55.js → chunk-JBPKEARU.js} +4 -4
- package/dist/{chunk-XW3W4PV4.js → chunk-JTPXSXHC.js} +2 -2
- package/dist/{chunk-OHJFJ4HI.js → chunk-KOXGLQS7.js} +2 -2
- package/dist/{chunk-2OPARZ4B.js → chunk-MPXYHC35.js} +26 -26
- package/dist/{chunk-6JBKHTQD.js → chunk-MR4PJ277.js} +2 -2
- package/dist/{chunk-EXXBA5OM.js → chunk-OI4BXFSB.js} +4 -4
- package/dist/{chunk-SQZ42MKH.js → chunk-OQH5XUH3.js} +6 -3
- package/dist/chunk-OQH5XUH3.js.map +1 -0
- package/dist/{chunk-2HEZXPYU.js → chunk-Q2LQZYQ7.js} +3 -3
- package/dist/{chunk-XRSIGVTS.js → chunk-QHWJG5C5.js} +8 -8
- package/dist/{chunk-T2AN3BSP.js → chunk-QZ7ODIVL.js} +2 -2
- package/dist/chunk-RI5XBIZ6.js +23 -0
- package/dist/chunk-RI5XBIZ6.js.map +1 -0
- package/dist/{chunk-D7IXTY5E.js → chunk-TJ7HH5LB.js} +2 -2
- package/dist/{chunk-V25ZAOSB.js → chunk-UOBLE67F.js} +4 -4
- package/dist/{chunk-JIX3ZL2J.js → chunk-UVUTV7CM.js} +15 -15
- package/dist/{chunk-VH6EIKVS.js → chunk-WKMCC4NQ.js} +35 -16
- package/dist/chunk-WKMCC4NQ.js.map +1 -0
- package/dist/{chunk-SSOMTUCA.js → chunk-WXGTC424.js} +1 -1
- package/dist/{chunk-KHGE6PMF.js → chunk-WXXLSZHA.js} +2 -2
- package/dist/{chunk-DSLUOQDY.js → chunk-XMWF6AU3.js} +2 -2
- package/dist/{chunk-DQY7NJ5L.js → chunk-XS2CWEHZ.js} +2 -2
- package/dist/{cli-BQRqR9N-.d.ts → cli-BypxcNqq.d.ts} +2 -2
- package/dist/cli.d.ts +4 -3
- package/dist/cli.js +42 -42
- package/dist/compounding/engine.js +4 -3
- package/dist/connectors/codex-materialize-runner.js +4 -3
- package/dist/connectors/index.js +4 -3
- package/dist/consolidation-provenance-check.js +2 -2
- package/dist/conversation-index/backend.js +2 -2
- package/dist/dashboard-runtime.js +2 -2
- package/dist/direct-answer-wiring.d.ts +13 -3
- package/dist/direct-answer-wiring.js +1 -1
- package/dist/entity-retrieval.js +4 -3
- package/dist/explicit-capture.d.ts +2 -1
- package/dist/index.d.ts +5 -4
- package/dist/index.js +66 -65
- package/dist/index.js.map +1 -1
- package/dist/lcm/engine.js +2 -2
- package/dist/lcm/index.js +4 -4
- package/dist/maintenance/memory-governance.js +4 -4
- package/dist/maintenance/rebuild-memory-lifecycle-ledger.js +4 -3
- package/dist/maintenance/rebuild-memory-projection.js +5 -5
- package/dist/mcp-memory-inspector-app.d.ts +3 -2
- package/dist/namespaces/migrate.js +11 -11
- package/dist/namespaces/search.js +7 -7
- package/dist/namespaces/storage.js +4 -3
- package/dist/operator-toolkit.js +15 -15
- package/dist/{orchestrator-Cg1UkvmO.d.ts → orchestrator-DZqPVoMI.d.ts} +8 -0
- package/dist/orchestrator.d.ts +2 -1
- package/dist/orchestrator.js +32 -31
- package/dist/recall-planner-llm.d.ts +2 -1
- package/dist/recall-planner-llm.js +3 -2
- package/dist/recall-planner-llm.js.map +1 -1
- package/dist/schemas.d.ts +42 -42
- package/dist/search/factory.js +6 -6
- package/dist/search/index.js +10 -10
- package/dist/search/lancedb-backend.js +1 -1
- package/dist/search/meilisearch-backend.js +1 -1
- package/dist/search/orama-backend.js +1 -1
- package/dist/semantic-consolidation.js +5 -4
- package/dist/semantic-rule-promotion.js +4 -3
- package/dist/semantic-rule-verifier.js +4 -3
- package/dist/shared-context/manager.d.ts +2 -2
- package/dist/storage.js +3 -2
- package/dist/transfer/backup.js +2 -2
- package/dist/transfer/capsule-export.js +2 -2
- package/dist/transfer/capsule-import.js +1 -1
- package/dist/verified-recall.js +4 -3
- package/package.json +1 -1
- package/src/capabilities.test.ts +97 -0
- package/src/capabilities.ts +86 -0
- package/src/direct-answer-wiring.test.ts +53 -2
- package/src/direct-answer-wiring.ts +18 -5
- package/src/orchestrator.ts +69 -19
- package/src/recall-planner-llm.test.ts +12 -11
- package/src/recall-planner-llm.ts +7 -1
- package/src/storage-fallback-category-dirs.test.ts +150 -1
- package/src/storage.ts +51 -14
- package/dist/chunk-SQZ42MKH.js.map +0 -1
- package/dist/chunk-VH6EIKVS.js.map +0 -1
- package/dist/chunk-WH4SKYPX.js.map +0 -1
- /package/dist/{chunk-ROHLEUTH.js.map → chunk-23EBQ27U.js.map} +0 -0
- /package/dist/{chunk-YW52BQSU.js.map → chunk-2TCHDANJ.js.map} +0 -0
- /package/dist/{chunk-IROWLAWG.js.map → chunk-46WUVFOD.js.map} +0 -0
- /package/dist/{chunk-7C4MPEPE.js.map → chunk-4T7P2HLJ.js.map} +0 -0
- /package/dist/{chunk-7XH7VJN4.js.map → chunk-6T4LTI2F.js.map} +0 -0
- /package/dist/{chunk-TVVEYCNW.js.map → chunk-7K5Q6COX.js.map} +0 -0
- /package/dist/{chunk-BZG2CWOQ.js.map → chunk-A5TEHAR4.js.map} +0 -0
- /package/dist/{chunk-C7AF236A.js.map → chunk-AARDBQTA.js.map} +0 -0
- /package/dist/{chunk-IHG6CC7T.js.map → chunk-BQJUPECT.js.map} +0 -0
- /package/dist/{chunk-7OGJQP7T.js.map → chunk-CRO4LCQ6.js.map} +0 -0
- /package/dist/{chunk-YNDLCWXS.js.map → chunk-EZ25VE3G.js.map} +0 -0
- /package/dist/{chunk-UXA5L2DZ.js.map → chunk-HQCGRSRU.js.map} +0 -0
- /package/dist/{chunk-RKNJBZ55.js.map → chunk-JBPKEARU.js.map} +0 -0
- /package/dist/{chunk-XW3W4PV4.js.map → chunk-JTPXSXHC.js.map} +0 -0
- /package/dist/{chunk-OHJFJ4HI.js.map → chunk-KOXGLQS7.js.map} +0 -0
- /package/dist/{chunk-2OPARZ4B.js.map → chunk-MPXYHC35.js.map} +0 -0
- /package/dist/{chunk-6JBKHTQD.js.map → chunk-MR4PJ277.js.map} +0 -0
- /package/dist/{chunk-EXXBA5OM.js.map → chunk-OI4BXFSB.js.map} +0 -0
- /package/dist/{chunk-2HEZXPYU.js.map → chunk-Q2LQZYQ7.js.map} +0 -0
- /package/dist/{chunk-XRSIGVTS.js.map → chunk-QHWJG5C5.js.map} +0 -0
- /package/dist/{chunk-T2AN3BSP.js.map → chunk-QZ7ODIVL.js.map} +0 -0
- /package/dist/{chunk-D7IXTY5E.js.map → chunk-TJ7HH5LB.js.map} +0 -0
- /package/dist/{chunk-V25ZAOSB.js.map → chunk-UOBLE67F.js.map} +0 -0
- /package/dist/{chunk-JIX3ZL2J.js.map → chunk-UVUTV7CM.js.map} +0 -0
- /package/dist/{chunk-SSOMTUCA.js.map → chunk-WXGTC424.js.map} +0 -0
- /package/dist/{chunk-KHGE6PMF.js.map → chunk-WXXLSZHA.js.map} +0 -0
- /package/dist/{chunk-DSLUOQDY.js.map → chunk-XMWF6AU3.js.map} +0 -0
- /package/dist/{chunk-DQY7NJ5L.js.map → chunk-XS2CWEHZ.js.map} +0 -0
|
@@ -19,7 +19,7 @@ import {
|
|
|
19
19
|
} from "./chunk-666A3MOW.js";
|
|
20
20
|
import {
|
|
21
21
|
LcmEngine
|
|
22
|
-
} from "./chunk-
|
|
22
|
+
} from "./chunk-UOBLE67F.js";
|
|
23
23
|
import {
|
|
24
24
|
chunkTranscriptEntries
|
|
25
25
|
} from "./chunk-TECVW3JP.js";
|
|
@@ -29,7 +29,7 @@ import {
|
|
|
29
29
|
import {
|
|
30
30
|
CompoundingEngine,
|
|
31
31
|
defaultTierMigrationCycleBudget
|
|
32
|
-
} from "./chunk-
|
|
32
|
+
} from "./chunk-KOXGLQS7.js";
|
|
33
33
|
import {
|
|
34
34
|
SharedContextManager
|
|
35
35
|
} from "./chunk-DRD2Q7HQ.js";
|
|
@@ -38,6 +38,14 @@ import {
|
|
|
38
38
|
applyUtilityRankingRuntimeDelta,
|
|
39
39
|
loadUtilityRuntimeValues
|
|
40
40
|
} from "./chunk-LXOM6IQU.js";
|
|
41
|
+
import {
|
|
42
|
+
applyTemporalSupersession,
|
|
43
|
+
normalizeSupersessionKey,
|
|
44
|
+
shouldFilterSupersededFromRecall
|
|
45
|
+
} from "./chunk-YTWNKQ2G.js";
|
|
46
|
+
import {
|
|
47
|
+
isValidAsOf
|
|
48
|
+
} from "./chunk-MDYG7VI7.js";
|
|
41
49
|
import {
|
|
42
50
|
TierMigrationExecutor
|
|
43
51
|
} from "./chunk-VOUOLGIP.js";
|
|
@@ -57,17 +65,13 @@ import {
|
|
|
57
65
|
buildTargetedFactRecallSection,
|
|
58
66
|
shouldRecallTargetedFactEvidence
|
|
59
67
|
} from "./chunk-R5DB26G6.js";
|
|
60
|
-
import {
|
|
61
|
-
applyTemporalSupersession,
|
|
62
|
-
normalizeSupersessionKey,
|
|
63
|
-
shouldFilterSupersededFromRecall
|
|
64
|
-
} from "./chunk-YTWNKQ2G.js";
|
|
65
|
-
import {
|
|
66
|
-
isValidAsOf
|
|
67
|
-
} from "./chunk-MDYG7VI7.js";
|
|
68
68
|
import {
|
|
69
69
|
SessionObserverState
|
|
70
70
|
} from "./chunk-MHQC2WU2.js";
|
|
71
|
+
import {
|
|
72
|
+
RerankCache,
|
|
73
|
+
rerankLocalOrNoop
|
|
74
|
+
} from "./chunk-E3VODCC3.js";
|
|
71
75
|
import {
|
|
72
76
|
buildResponseGuidanceRecallSection,
|
|
73
77
|
shouldRecallResponseGuidance
|
|
@@ -99,10 +103,6 @@ import {
|
|
|
99
103
|
import {
|
|
100
104
|
RelevanceStore
|
|
101
105
|
} from "./chunk-452WDNFO.js";
|
|
102
|
-
import {
|
|
103
|
-
RerankCache,
|
|
104
|
-
rerankLocalOrNoop
|
|
105
|
-
} from "./chunk-E3VODCC3.js";
|
|
106
106
|
import {
|
|
107
107
|
reorderRecallResultsWithMmr
|
|
108
108
|
} from "./chunk-YDBIWGNI.js";
|
|
@@ -120,6 +120,9 @@ import {
|
|
|
120
120
|
import {
|
|
121
121
|
NegativeExampleStore
|
|
122
122
|
} from "./chunk-XKXKSQU7.js";
|
|
123
|
+
import {
|
|
124
|
+
evaluateMemoryActionPolicy
|
|
125
|
+
} from "./chunk-H63EDPFJ.js";
|
|
123
126
|
import {
|
|
124
127
|
applyMemoryWorthFilter,
|
|
125
128
|
buildMemoryWorthCounterMap
|
|
@@ -128,8 +131,8 @@ import {
|
|
|
128
131
|
runLiveConnectorsOnce
|
|
129
132
|
} from "./chunk-VU3SVYMA.js";
|
|
130
133
|
import {
|
|
131
|
-
|
|
132
|
-
} from "./chunk-
|
|
134
|
+
classifyMemoryKind
|
|
135
|
+
} from "./chunk-YAZNBMNF.js";
|
|
133
136
|
import {
|
|
134
137
|
hasBroadGraphIntent,
|
|
135
138
|
inferIntentFromText,
|
|
@@ -137,9 +140,6 @@ import {
|
|
|
137
140
|
isTaskInitiationIntent,
|
|
138
141
|
planRecallMode
|
|
139
142
|
} from "./chunk-PD6O7AXF.js";
|
|
140
|
-
import {
|
|
141
|
-
classifyMemoryKind
|
|
142
|
-
} from "./chunk-YAZNBMNF.js";
|
|
143
143
|
import {
|
|
144
144
|
recordJudgeTrainingPair
|
|
145
145
|
} from "./chunk-7YX23JBA.js";
|
|
@@ -166,11 +166,14 @@ import {
|
|
|
166
166
|
buildFocusedListRecallSection,
|
|
167
167
|
shouldRecallFocusedListEvidence
|
|
168
168
|
} from "./chunk-LZTFCAKE.js";
|
|
169
|
+
import {
|
|
170
|
+
EmbeddingFallback
|
|
171
|
+
} from "./chunk-XCAZF7KQ.js";
|
|
169
172
|
import {
|
|
170
173
|
buildEntityRecallSection,
|
|
171
174
|
entityRecentTranscriptLookbackHours,
|
|
172
175
|
readRecentEntityTranscriptEntries
|
|
173
|
-
} from "./chunk-
|
|
176
|
+
} from "./chunk-QZ7ODIVL.js";
|
|
174
177
|
import {
|
|
175
178
|
buildEventOrderRecallSection,
|
|
176
179
|
shouldRecallEventOrderEvidence
|
|
@@ -183,10 +186,7 @@ import {
|
|
|
183
186
|
} from "./chunk-WLEB7WCG.js";
|
|
184
187
|
import {
|
|
185
188
|
tryDirectAnswer
|
|
186
|
-
} from "./chunk-
|
|
187
|
-
import {
|
|
188
|
-
EmbeddingFallback
|
|
189
|
-
} from "./chunk-XCAZF7KQ.js";
|
|
189
|
+
} from "./chunk-OQH5XUH3.js";
|
|
190
190
|
import {
|
|
191
191
|
CODEX_THREAD_KEY_PREFIX
|
|
192
192
|
} from "./chunk-3PG3H5TD.js";
|
|
@@ -205,24 +205,24 @@ import {
|
|
|
205
205
|
materializeAfterSemanticConsolidation,
|
|
206
206
|
parseConsolidationResponse,
|
|
207
207
|
parseOperatorAwareConsolidationResponse
|
|
208
|
-
} from "./chunk-
|
|
209
|
-
import {
|
|
210
|
-
normalizeReplaySessionKey
|
|
211
|
-
} from "./chunk-2PRQG7PV.js";
|
|
208
|
+
} from "./chunk-JTPXSXHC.js";
|
|
212
209
|
import {
|
|
213
210
|
RoutingRulesStore
|
|
214
211
|
} from "./chunk-X6IRLNOO.js";
|
|
212
|
+
import {
|
|
213
|
+
normalizeReplaySessionKey
|
|
214
|
+
} from "./chunk-2PRQG7PV.js";
|
|
215
215
|
import {
|
|
216
216
|
compareVerifiedEpisodeResults,
|
|
217
217
|
searchVerifiedEpisodes
|
|
218
|
-
} from "./chunk-
|
|
218
|
+
} from "./chunk-2TCHDANJ.js";
|
|
219
219
|
import {
|
|
220
220
|
ThreadingManager
|
|
221
221
|
} from "./chunk-W4RVMTHR.js";
|
|
222
222
|
import {
|
|
223
223
|
compareVerifiedSemanticRuleResults,
|
|
224
224
|
searchVerifiedSemanticRules
|
|
225
|
-
} from "./chunk-
|
|
225
|
+
} from "./chunk-XMWF6AU3.js";
|
|
226
226
|
import {
|
|
227
227
|
searchWorkProductLedgerEntries
|
|
228
228
|
} from "./chunk-ZRWB5D4H.js";
|
|
@@ -236,7 +236,7 @@ import {
|
|
|
236
236
|
NamespaceStorageRouter,
|
|
237
237
|
resolveDefaultNamespaceRoot,
|
|
238
238
|
resolveNamespaceStorageRoot
|
|
239
|
-
} from "./chunk-
|
|
239
|
+
} from "./chunk-TJ7HH5LB.js";
|
|
240
240
|
import {
|
|
241
241
|
isAboveImportanceThreshold,
|
|
242
242
|
scoreImportance
|
|
@@ -244,6 +244,10 @@ import {
|
|
|
244
244
|
import {
|
|
245
245
|
searchHarmonicRetrieval
|
|
246
246
|
} from "./chunk-AV5ZEH4M.js";
|
|
247
|
+
import {
|
|
248
|
+
EXTRACTION_JUDGE_VERDICT_CATEGORY,
|
|
249
|
+
recordJudgeVerdict
|
|
250
|
+
} from "./chunk-AJU4PJGY.js";
|
|
247
251
|
import {
|
|
248
252
|
collectNativeKnowledgeChunks,
|
|
249
253
|
formatNativeKnowledgeSection,
|
|
@@ -252,10 +256,6 @@ import {
|
|
|
252
256
|
import {
|
|
253
257
|
recordEvalShadowRecall
|
|
254
258
|
} from "./chunk-3PY7VHV7.js";
|
|
255
|
-
import {
|
|
256
|
-
EXTRACTION_JUDGE_VERDICT_CATEGORY,
|
|
257
|
-
recordJudgeVerdict
|
|
258
|
-
} from "./chunk-AJU4PJGY.js";
|
|
259
259
|
import {
|
|
260
260
|
applyCommitmentLedgerLifecycle
|
|
261
261
|
} from "./chunk-LMDRGRJ2.js";
|
|
@@ -273,6 +273,9 @@ import {
|
|
|
273
273
|
fallbackLlmRuntimeContextFromConfig,
|
|
274
274
|
gatewayTaskChainOptions
|
|
275
275
|
} from "./chunk-LCC5EZTT.js";
|
|
276
|
+
import {
|
|
277
|
+
resolveCapabilities
|
|
278
|
+
} from "./chunk-RI5XBIZ6.js";
|
|
276
279
|
import {
|
|
277
280
|
compileCorrectionRule,
|
|
278
281
|
correctionsFilePath,
|
|
@@ -319,11 +322,11 @@ import {
|
|
|
319
322
|
} from "./chunk-2MXEVL75.js";
|
|
320
323
|
import {
|
|
321
324
|
NamespaceSearchRouter
|
|
322
|
-
} from "./chunk-
|
|
325
|
+
} from "./chunk-XS2CWEHZ.js";
|
|
323
326
|
import {
|
|
324
327
|
createConversationIndexRuntime,
|
|
325
328
|
createSearchBackend
|
|
326
|
-
} from "./chunk-
|
|
329
|
+
} from "./chunk-23EBQ27U.js";
|
|
327
330
|
import {
|
|
328
331
|
NoopSearchBackend
|
|
329
332
|
} from "./chunk-CYEPCZN5.js";
|
|
@@ -332,9 +335,6 @@ import {
|
|
|
332
335
|
namespaceIdentityToken,
|
|
333
336
|
normalizeNamespaceIdentity
|
|
334
337
|
} from "./chunk-ZFXCQPNO.js";
|
|
335
|
-
import {
|
|
336
|
-
assertPathInsideRoot
|
|
337
|
-
} from "./chunk-5GPPACXK.js";
|
|
338
338
|
import {
|
|
339
339
|
writeConversationChunks
|
|
340
340
|
} from "./chunk-OIF36KGD.js";
|
|
@@ -359,7 +359,7 @@ import {
|
|
|
359
359
|
} from "./chunk-Y56J7CXW.js";
|
|
360
360
|
import {
|
|
361
361
|
buildChainFollowupGenerator
|
|
362
|
-
} from "./chunk-
|
|
362
|
+
} from "./chunk-WXXLSZHA.js";
|
|
363
363
|
import {
|
|
364
364
|
ContentHashIndex,
|
|
365
365
|
StorageManager,
|
|
@@ -368,7 +368,7 @@ import {
|
|
|
368
368
|
normalizeAttributePairs,
|
|
369
369
|
parseEntityFile,
|
|
370
370
|
stripAttributesSuffix
|
|
371
|
-
} from "./chunk-
|
|
371
|
+
} from "./chunk-WKMCC4NQ.js";
|
|
372
372
|
import {
|
|
373
373
|
isValidTranscriptDate,
|
|
374
374
|
loadSpeakerRegistry,
|
|
@@ -376,6 +376,9 @@ import {
|
|
|
376
376
|
saveSpeakerRegistry,
|
|
377
377
|
speakerRegistryKey
|
|
378
378
|
} from "./chunk-M7XQSUBB.js";
|
|
379
|
+
import {
|
|
380
|
+
assertPathInsideRoot
|
|
381
|
+
} from "./chunk-5GPPACXK.js";
|
|
379
382
|
import {
|
|
380
383
|
attachCitation,
|
|
381
384
|
hasCitationForTemplate,
|
|
@@ -405,7 +408,7 @@ import {
|
|
|
405
408
|
} from "./chunk-FVQJYWH7.js";
|
|
406
409
|
import {
|
|
407
410
|
searchCausalTrajectories
|
|
408
|
-
} from "./chunk-
|
|
411
|
+
} from "./chunk-WXGTC424.js";
|
|
409
412
|
import {
|
|
410
413
|
canReadNamespace,
|
|
411
414
|
defaultNamespaceForPrincipal,
|
|
@@ -3968,7 +3971,8 @@ function resolveRecallModeDecision(options) {
|
|
|
3968
3971
|
}
|
|
3969
3972
|
async function resolveRecallModeDecisionAsync(options) {
|
|
3970
3973
|
const heuristicDecision = resolveRecallModeDecision(options);
|
|
3971
|
-
|
|
3974
|
+
const plannerLlmEnabled = options.caps?.recallPlannerLlm ?? options.config.recallPlannerLlmEnabled;
|
|
3975
|
+
if (!options.plannerEnabled || !plannerLlmEnabled) {
|
|
3972
3976
|
return heuristicDecision;
|
|
3973
3977
|
}
|
|
3974
3978
|
const { planRecallModeLLM } = await import("./recall-planner-llm.js");
|
|
@@ -3977,7 +3981,8 @@ async function resolveRecallModeDecisionAsync(options) {
|
|
|
3977
3981
|
options.hints,
|
|
3978
3982
|
options.config,
|
|
3979
3983
|
options.llm,
|
|
3980
|
-
options.signal
|
|
3984
|
+
options.signal,
|
|
3985
|
+
options.caps
|
|
3981
3986
|
);
|
|
3982
3987
|
if (options.config.recallPlannerShadowMode) {
|
|
3983
3988
|
return {
|
|
@@ -7081,6 +7086,7 @@ ${r.snippet.trim()}
|
|
|
7081
7086
|
}
|
|
7082
7087
|
}
|
|
7083
7088
|
async recall(prompt, sessionKey, options = {}) {
|
|
7089
|
+
const caps = resolveCapabilities(this.config);
|
|
7084
7090
|
const abortController = new AbortController();
|
|
7085
7091
|
const onAbort = () => {
|
|
7086
7092
|
abortController.abort();
|
|
@@ -7134,7 +7140,7 @@ ${r.snippet.trim()}
|
|
|
7134
7140
|
const recallPromise = this.recallInternal(prompt, sessionKey, {
|
|
7135
7141
|
...options,
|
|
7136
7142
|
abortSignal: abortController.signal
|
|
7137
|
-
});
|
|
7143
|
+
}, caps);
|
|
7138
7144
|
const RECALL_TIMEOUT_MS = this.config.recallOuterTimeoutMs ?? 75e3;
|
|
7139
7145
|
if (RECALL_TIMEOUT_MS <= 0) {
|
|
7140
7146
|
return await recallPromise;
|
|
@@ -7152,13 +7158,14 @@ ${r.snippet.trim()}
|
|
|
7152
7158
|
} finally {
|
|
7153
7159
|
if (timeoutHandle) clearTimeout(timeoutHandle);
|
|
7154
7160
|
}
|
|
7155
|
-
if (
|
|
7161
|
+
if (caps.recallDirectAnswer && sessionKey) {
|
|
7156
7162
|
try {
|
|
7157
7163
|
this.enqueueDirectAnswerObservation(
|
|
7158
7164
|
prompt,
|
|
7159
7165
|
sessionKey,
|
|
7160
7166
|
options.namespace?.trim() || void 0,
|
|
7161
|
-
options.principalOverride
|
|
7167
|
+
options.principalOverride,
|
|
7168
|
+
caps
|
|
7162
7169
|
);
|
|
7163
7170
|
} catch (err) {
|
|
7164
7171
|
log.debug(`direct-answer observation setup failed: ${err}`);
|
|
@@ -7213,7 +7220,7 @@ ${r.snippet.trim()}
|
|
|
7213
7220
|
if (timeoutHandle) clearTimeout(timeoutHandle);
|
|
7214
7221
|
}
|
|
7215
7222
|
}
|
|
7216
|
-
enqueueDirectAnswerObservation(prompt, sessionKey, namespaceOverride, principalOverride) {
|
|
7223
|
+
enqueueDirectAnswerObservation(prompt, sessionKey, namespaceOverride, principalOverride, caps) {
|
|
7217
7224
|
const expectedSnapshot = this.lastRecall.get(sessionKey);
|
|
7218
7225
|
if (expectedSnapshot === null) return;
|
|
7219
7226
|
if (expectedSnapshot.plannerMode === "no_recall") return;
|
|
@@ -7271,6 +7278,7 @@ ${r.snippet.trim()}
|
|
|
7271
7278
|
sessionKey,
|
|
7272
7279
|
observationNamespaces,
|
|
7273
7280
|
expectedIdentity,
|
|
7281
|
+
caps,
|
|
7274
7282
|
void 0
|
|
7275
7283
|
);
|
|
7276
7284
|
} catch (err) {
|
|
@@ -7278,7 +7286,7 @@ ${r.snippet.trim()}
|
|
|
7278
7286
|
}
|
|
7279
7287
|
});
|
|
7280
7288
|
}
|
|
7281
|
-
async annotateDirectAnswerTier(prompt, sessionKey, namespaces, expectedIdentity, _parentAbortSignal) {
|
|
7289
|
+
async annotateDirectAnswerTier(prompt, sessionKey, namespaces, expectedIdentity, caps, _parentAbortSignal) {
|
|
7282
7290
|
const tierStart = Date.now();
|
|
7283
7291
|
try {
|
|
7284
7292
|
if (namespaces.length === 0) return;
|
|
@@ -7339,6 +7347,7 @@ ${r.snippet.trim()}
|
|
|
7339
7347
|
query: prompt,
|
|
7340
7348
|
namespace: ns,
|
|
7341
7349
|
config: this.config,
|
|
7350
|
+
enabled: caps.recallDirectAnswer,
|
|
7342
7351
|
sources
|
|
7343
7352
|
});
|
|
7344
7353
|
if (r.eligible && r.winner) {
|
|
@@ -8203,7 +8212,7 @@ ${r.snippet.trim()}
|
|
|
8203
8212
|
finalChars: usedChars
|
|
8204
8213
|
};
|
|
8205
8214
|
}
|
|
8206
|
-
async recallInternal(prompt, sessionKey, options = {}) {
|
|
8215
|
+
async recallInternal(prompt, sessionKey, options = {}, caps = resolveCapabilities(this.config)) {
|
|
8207
8216
|
const recallStart = Date.now();
|
|
8208
8217
|
const backendDegradations = [];
|
|
8209
8218
|
let asOfMs;
|
|
@@ -8299,16 +8308,17 @@ ${r.snippet.trim()}
|
|
|
8299
8308
|
let identityInjectionTruncated = false;
|
|
8300
8309
|
timings.queryPolicy = `${queryPolicy.promptShape}/${queryPolicy.retrievalBudgetMode}${queryPolicy.skipConversationRecall ? "/skip-conv" : ""}`;
|
|
8301
8310
|
const recallModeDecisionOptions = {
|
|
8302
|
-
plannerEnabled:
|
|
8303
|
-
graphRecallEnabled:
|
|
8311
|
+
plannerEnabled: caps.recallPlanner,
|
|
8312
|
+
graphRecallEnabled: caps.graphRecall,
|
|
8304
8313
|
multiGraphMemoryEnabled: this.config.multiGraphMemoryEnabled,
|
|
8305
|
-
graphExpandedIntentEnabled:
|
|
8314
|
+
graphExpandedIntentEnabled: caps.graphExpandedIntent,
|
|
8306
8315
|
prompt
|
|
8307
8316
|
};
|
|
8308
8317
|
const requestedMode = options.mode;
|
|
8309
8318
|
const recallDecision = requestedMode !== void 0 ? resolveRecallModeDecision(recallModeDecisionOptions) : await resolveRecallModeDecisionAsync({
|
|
8310
8319
|
...recallModeDecisionOptions,
|
|
8311
8320
|
config: this.config,
|
|
8321
|
+
caps,
|
|
8312
8322
|
signal: options.abortSignal
|
|
8313
8323
|
});
|
|
8314
8324
|
if (this.config.recallPlannerTelemetryEnabled && recallDecision.plannerSource && recallDecision.plannerSource !== "heuristic") {
|
|
@@ -8468,7 +8478,7 @@ ${r.snippet.trim()}
|
|
|
8468
8478
|
promptLength: prompt.length,
|
|
8469
8479
|
retrievalQueryHash,
|
|
8470
8480
|
retrievalQueryLength: retrievalQuery.length,
|
|
8471
|
-
plannerEnabled:
|
|
8481
|
+
plannerEnabled: caps.recallPlanner,
|
|
8472
8482
|
plannedMode: requestedMode ?? recallDecision.plannedMode,
|
|
8473
8483
|
effectiveMode: recallMode,
|
|
8474
8484
|
recallResultLimit,
|
|
@@ -8479,7 +8489,7 @@ ${r.snippet.trim()}
|
|
|
8479
8489
|
reason: graphDecisionReason,
|
|
8480
8490
|
shadowMode: graphDecisionShadowMode,
|
|
8481
8491
|
qmdAvailable,
|
|
8482
|
-
graphRecallEnabled:
|
|
8492
|
+
graphRecallEnabled: caps.graphRecall,
|
|
8483
8493
|
multiGraphMemoryEnabled: this.config.multiGraphMemoryEnabled
|
|
8484
8494
|
}
|
|
8485
8495
|
});
|
|
@@ -10974,7 +10984,7 @@ ${tmtNode.summary}`
|
|
|
10974
10984
|
memoryResults = memoryResults.filter(
|
|
10975
10985
|
(r) => !isArtifactMemoryPath(r.path)
|
|
10976
10986
|
);
|
|
10977
|
-
const isFullModeGraphAssist = this.config.multiGraphMemoryEnabled &&
|
|
10987
|
+
const isFullModeGraphAssist = this.config.multiGraphMemoryEnabled && caps.graphAssistInFullMode && recallMode === "full" && memoryResults.length >= Math.max(1, this.config.graphAssistMinSeedResults ?? 3);
|
|
10978
10988
|
const shouldRunGraphExpansion = recallMode === "graph_mode" || isFullModeGraphAssist;
|
|
10979
10989
|
const graphShadowEvalEnabled = isFullModeGraphAssist && this.config.graphAssistShadowEvalEnabled === true;
|
|
10980
10990
|
if (shouldRunGraphExpansion) {
|
|
@@ -11117,7 +11127,7 @@ ${tmtNode.summary}`
|
|
|
11117
11127
|
timeoutMs: this.config.rerankTimeoutMs,
|
|
11118
11128
|
maxCandidates: this.config.rerankMaxCandidates,
|
|
11119
11129
|
cache: this.rerankCache,
|
|
11120
|
-
cacheEnabled:
|
|
11130
|
+
cacheEnabled: caps.rerankCache,
|
|
11121
11131
|
cacheTtlMs: this.config.rerankCacheTtlMs
|
|
11122
11132
|
});
|
|
11123
11133
|
if (ranked && ranked.length > 0) {
|
|
@@ -11139,7 +11149,7 @@ ${tmtNode.summary}`
|
|
|
11139
11149
|
"rerankProvider=cloud is reserved/experimental in v2.2.0; skipping rerank"
|
|
11140
11150
|
);
|
|
11141
11151
|
}
|
|
11142
|
-
if (
|
|
11152
|
+
if (caps.recallMemoryWorthFilter && memoryResults.length > 0) {
|
|
11143
11153
|
try {
|
|
11144
11154
|
memoryResults = await this.applyMemoryWorthRerank(memoryResults, recallNamespaces);
|
|
11145
11155
|
} catch (err) {
|
|
@@ -11152,7 +11162,7 @@ ${tmtNode.summary}`
|
|
|
11152
11162
|
memoryResults.length
|
|
11153
11163
|
);
|
|
11154
11164
|
let confidenceGateRejected = false;
|
|
11155
|
-
if (
|
|
11165
|
+
if (caps.recallConfidenceGate && effectiveGateScore > 0) {
|
|
11156
11166
|
if (effectiveGateScore < this.config.recallConfidenceGateThreshold) {
|
|
11157
11167
|
log.debug(
|
|
11158
11168
|
`recall: confidence gate rejected ${memoryResults.length} results (effective score ${effectiveGateScore.toFixed(3)} below ${this.config.recallConfidenceGateThreshold})`
|
|
@@ -11165,7 +11175,8 @@ ${tmtNode.summary}`
|
|
|
11165
11175
|
"memories",
|
|
11166
11176
|
memoryResults,
|
|
11167
11177
|
recallResultLimit,
|
|
11168
|
-
retrievalQuery
|
|
11178
|
+
retrievalQuery,
|
|
11179
|
+
caps
|
|
11169
11180
|
);
|
|
11170
11181
|
if (this.config.memoryReconstructionEnabled && memoryResults.length > 0) {
|
|
11171
11182
|
try {
|
|
@@ -11265,7 +11276,8 @@ ${tmtNode.summary}`
|
|
|
11265
11276
|
"memories",
|
|
11266
11277
|
boostedScoped,
|
|
11267
11278
|
recallResultLimit,
|
|
11268
|
-
retrievalQuery
|
|
11279
|
+
retrievalQuery,
|
|
11280
|
+
caps
|
|
11269
11281
|
);
|
|
11270
11282
|
},
|
|
11271
11283
|
[]
|
|
@@ -11301,6 +11313,7 @@ ${tmtNode.summary}`
|
|
|
11301
11313
|
recallNamespaces,
|
|
11302
11314
|
recallResultLimit,
|
|
11303
11315
|
recallMode,
|
|
11316
|
+
caps,
|
|
11304
11317
|
queryAwarePrefilter,
|
|
11305
11318
|
abortSignal: options.abortSignal,
|
|
11306
11319
|
onDegradation: (degradation) => {
|
|
@@ -11409,7 +11422,8 @@ ${tmtNode.summary}`
|
|
|
11409
11422
|
"memories",
|
|
11410
11423
|
boostedScoped,
|
|
11411
11424
|
recallResultLimit,
|
|
11412
|
-
retrievalQuery
|
|
11425
|
+
retrievalQuery,
|
|
11426
|
+
caps
|
|
11413
11427
|
);
|
|
11414
11428
|
},
|
|
11415
11429
|
[]
|
|
@@ -11472,6 +11486,7 @@ ${tmtNode.summary}`
|
|
|
11472
11486
|
recallNamespaces,
|
|
11473
11487
|
recallResultLimit,
|
|
11474
11488
|
recallMode,
|
|
11489
|
+
caps,
|
|
11475
11490
|
queryAwarePrefilter,
|
|
11476
11491
|
abortSignal: options.abortSignal,
|
|
11477
11492
|
onDegradation: (degradation) => {
|
|
@@ -11535,7 +11550,8 @@ ${tmtNode.summary}`
|
|
|
11535
11550
|
"memories",
|
|
11536
11551
|
boostedRecent,
|
|
11537
11552
|
recallResultLimit,
|
|
11538
|
-
retrievalQuery
|
|
11553
|
+
retrievalQuery,
|
|
11554
|
+
caps
|
|
11539
11555
|
);
|
|
11540
11556
|
},
|
|
11541
11557
|
[]
|
|
@@ -11571,6 +11587,7 @@ ${tmtNode.summary}`
|
|
|
11571
11587
|
recallNamespaces,
|
|
11572
11588
|
recallResultLimit,
|
|
11573
11589
|
recallMode,
|
|
11590
|
+
caps,
|
|
11574
11591
|
queryAwarePrefilter,
|
|
11575
11592
|
abortSignal: options.abortSignal,
|
|
11576
11593
|
onDegradation: (degradation) => {
|
|
@@ -11615,6 +11632,7 @@ ${tmtNode.summary}`
|
|
|
11615
11632
|
recallNamespaces,
|
|
11616
11633
|
recallResultLimit,
|
|
11617
11634
|
recallMode,
|
|
11635
|
+
caps,
|
|
11618
11636
|
queryAwarePrefilter,
|
|
11619
11637
|
abortSignal: options.abortSignal,
|
|
11620
11638
|
onDegradation: (degradation) => {
|
|
@@ -16122,15 +16140,15 @@ ${lines.join("\n\n")}`;
|
|
|
16122
16140
|
}
|
|
16123
16141
|
return reordered;
|
|
16124
16142
|
}
|
|
16125
|
-
diversifyAndLimitRecallResults(sectionId, results, limit, retrievalQuery) {
|
|
16143
|
+
diversifyAndLimitRecallResults(sectionId, results, limit, retrievalQuery, caps = resolveCapabilities(this.config)) {
|
|
16126
16144
|
const safeLimit = typeof limit === "number" && Number.isFinite(limit) ? Math.max(0, Math.floor(limit)) : 0;
|
|
16127
16145
|
if (!Array.isArray(results) || results.length === 0) return [];
|
|
16128
16146
|
if (safeLimit === 0) return [];
|
|
16129
|
-
const boosted =
|
|
16147
|
+
const boosted = caps.recallReasoningTraceBoost && typeof retrievalQuery === "string" ? applyReasoningTraceBoost(results, {
|
|
16130
16148
|
enabled: true,
|
|
16131
16149
|
query: retrievalQuery
|
|
16132
16150
|
}) : results;
|
|
16133
|
-
const diversified = this.applyMmrToQmdResults(sectionId, boosted);
|
|
16151
|
+
const diversified = this.applyMmrToQmdResults(sectionId, boosted, caps);
|
|
16134
16152
|
return diversified.slice(0, safeLimit);
|
|
16135
16153
|
}
|
|
16136
16154
|
/**
|
|
@@ -16141,8 +16159,8 @@ ${lines.join("\n\n")}`;
|
|
|
16141
16159
|
* input unchanged when disabled, when there are fewer than 2 candidates, or
|
|
16142
16160
|
* when no budget information is available.
|
|
16143
16161
|
*/
|
|
16144
|
-
applyMmrToQmdResults(sectionId, results) {
|
|
16145
|
-
if (
|
|
16162
|
+
applyMmrToQmdResults(sectionId, results, caps = resolveCapabilities(this.config)) {
|
|
16163
|
+
if (!caps.recallMmr) return results;
|
|
16146
16164
|
if (!Array.isArray(results) || results.length < 2) return results;
|
|
16147
16165
|
const configuredTopN = this.config.recallMmrTopN;
|
|
16148
16166
|
const topN = typeof configuredTopN === "number" && Number.isFinite(configuredTopN) ? Math.max(0, Math.floor(configuredTopN)) : 40;
|
|
@@ -16328,6 +16346,7 @@ ${lines.join("\n\n")}`;
|
|
|
16328
16346
|
return [...mergedByPath.values()].filter((result) => !isArtifactMemoryPath(result.path)).sort((a, b) => b.score - a.score).slice(0, cappedLimit);
|
|
16329
16347
|
}
|
|
16330
16348
|
async applyColdFallbackPipeline(options) {
|
|
16349
|
+
const caps = options.caps ?? resolveCapabilities(this.config);
|
|
16331
16350
|
if (options.queryAwarePrefilter?.candidatePaths?.size === 0) {
|
|
16332
16351
|
if (options.xrayPoolSizeSink) options.xrayPoolSizeSink.size = 0;
|
|
16333
16352
|
return [];
|
|
@@ -16501,7 +16520,7 @@ ${lines.join("\n\n")}`;
|
|
|
16501
16520
|
}
|
|
16502
16521
|
results = results.filter((r) => !isArtifactMemoryPath(r.path));
|
|
16503
16522
|
if (results.length === 0) return [];
|
|
16504
|
-
const isFullModeGraphAssist = this.config.qmdTierParityGraphEnabled && this.config.multiGraphMemoryEnabled &&
|
|
16523
|
+
const isFullModeGraphAssist = this.config.qmdTierParityGraphEnabled && this.config.multiGraphMemoryEnabled && caps.graphAssistInFullMode && options.recallMode === "full" && results.length >= Math.max(1, this.config.graphAssistMinSeedResults ?? 3);
|
|
16505
16524
|
const shouldRunGraphExpansion = this.config.qmdTierParityGraphEnabled && (options.recallMode === "graph_mode" || isFullModeGraphAssist);
|
|
16506
16525
|
if (shouldRunGraphExpansion) {
|
|
16507
16526
|
const { merged } = await this.expandResultsViaGraph({
|
|
@@ -16578,7 +16597,7 @@ ${lines.join("\n\n")}`;
|
|
|
16578
16597
|
timeoutMs: this.config.rerankTimeoutMs,
|
|
16579
16598
|
maxCandidates: this.config.rerankMaxCandidates,
|
|
16580
16599
|
cache: this.rerankCache,
|
|
16581
|
-
cacheEnabled:
|
|
16600
|
+
cacheEnabled: caps.rerankCache,
|
|
16582
16601
|
cacheTtlMs: this.config.rerankCacheTtlMs
|
|
16583
16602
|
});
|
|
16584
16603
|
if (ranked && ranked.length > 0) {
|
|
@@ -16600,7 +16619,7 @@ ${lines.join("\n\n")}`;
|
|
|
16600
16619
|
"rerankProvider=cloud is reserved/experimental in v2.2.0; skipping rerank"
|
|
16601
16620
|
);
|
|
16602
16621
|
}
|
|
16603
|
-
if (
|
|
16622
|
+
if (caps.recallMemoryWorthFilter && results.length > 0) {
|
|
16604
16623
|
try {
|
|
16605
16624
|
results = await this.applyMemoryWorthRerank(results, options.recallNamespaces);
|
|
16606
16625
|
} catch (err) {
|
|
@@ -16619,7 +16638,8 @@ ${lines.join("\n\n")}`;
|
|
|
16619
16638
|
"memories",
|
|
16620
16639
|
results,
|
|
16621
16640
|
options.recallResultLimit,
|
|
16622
|
-
options.prompt
|
|
16641
|
+
options.prompt,
|
|
16642
|
+
caps
|
|
16623
16643
|
);
|
|
16624
16644
|
}
|
|
16625
16645
|
// ---------------------------------------------------------------------------
|
|
@@ -17357,4 +17377,4 @@ export {
|
|
|
17357
17377
|
resolvePersistedMemoryRelativePath,
|
|
17358
17378
|
Orchestrator
|
|
17359
17379
|
};
|
|
17360
|
-
//# sourceMappingURL=chunk-
|
|
17380
|
+
//# sourceMappingURL=chunk-GZ6QAYSH.js.map
|