@cortexkit/opencode-magic-context 0.49.86 → 0.49.87
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/auto-search-worker.js +13 -7
- package/dist/chunk-embedding-write-worker.js +4 -4
- package/dist/{compartment-chunk-embedding-ymc9mtwv.js → compartment-chunk-embedding-fey2bsyf.js} +3 -1
- package/dist/{conflict-warning-hook-a0wrnzch.js → conflict-warning-hook-kbq6ppjf.js} +2 -2
- package/dist/{context-xesm7rj3.js → context-gnk68pyy.js} +126 -46
- package/dist/{embedding-backfill-v6sw58m8.js → embedding-backfill-9khxv6a9.js} +4 -4
- package/dist/{embedding-cache-mgyr73ef.js → embedding-cache-zn4r1c31.js} +5 -1
- package/dist/features/magic-context/compartment-chunk-embedding.d.ts +1 -0
- package/dist/features/magic-context/compartment-chunk-embedding.d.ts.map +1 -1
- package/dist/features/magic-context/dreamer/task-executor.d.ts.map +1 -1
- package/dist/features/magic-context/dreamer/token-budget.d.ts +8 -3
- package/dist/features/magic-context/dreamer/token-budget.d.ts.map +1 -1
- package/dist/features/magic-context/memory/embedding-cache.d.ts +7 -0
- package/dist/features/magic-context/memory/embedding-cache.d.ts.map +1 -1
- package/dist/features/magic-context/search.d.ts +6 -0
- package/dist/features/magic-context/search.d.ts.map +1 -1
- package/dist/features/magic-context/tool-definition-tokens.d.ts +2 -0
- package/dist/features/magic-context/tool-definition-tokens.d.ts.map +1 -1
- package/dist/hooks/magic-context/auto-search-worker-client.d.ts.map +1 -1
- package/dist/hooks/magic-context/auto-search-worker-probe.fixture.d.ts +2 -0
- package/dist/hooks/magic-context/auto-search-worker-probe.fixture.d.ts.map +1 -0
- package/dist/hooks/magic-context/dropped-input-guard.d.ts.map +1 -1
- package/dist/hooks/magic-context/emergency-fail-closed.d.ts +2 -0
- package/dist/hooks/magic-context/emergency-fail-closed.d.ts.map +1 -1
- package/dist/hooks/magic-context/send-session-notification.d.ts +11 -1
- package/dist/hooks/magic-context/send-session-notification.d.ts.map +1 -1
- package/dist/hooks/magic-context/transform.d.ts +1 -0
- package/dist/hooks/magic-context/transform.d.ts.map +1 -1
- package/dist/{index-7j2zv9nm.js → index-2qsca7h7.js} +47 -11
- package/dist/{index-25nktq8n.js → index-3jgzd7nz.js} +7 -7
- package/dist/{index-snbpdpa3.js → index-3pdknr07.js} +4 -4
- package/dist/{index-k0tb2z28.js → index-3x4qvp29.js} +2 -2
- package/dist/{index-d0rtbv0f.js → index-5nmqgvz2.js} +21 -14
- package/dist/{index-xrnhxkz7.js → index-60wnwcwz.js} +1 -1
- package/dist/{index-g6hfh4h4.js → index-6zewd2n5.js} +14 -8
- package/dist/{index-nny4gm06.js → index-74sh122g.js} +2 -2
- package/dist/{index-70cv85b0.js → index-78t37mcq.js} +2 -2
- package/dist/{index-stx8zd81.js → index-83qd3n7s.js} +2 -2
- package/dist/{index-jjvbk92s.js → index-9emdjcb5.js} +1 -1
- package/dist/{index-gxdc95cp.js → index-awyqqnd8.js} +585 -82
- package/dist/{index-022w6314.js → index-b364vr04.js} +109 -505
- package/dist/{index-4w5rx7de.js → index-bxrfq3mv.js} +1 -1
- package/dist/{index-1bqkqde0.js → index-c1s40xmj.js} +3 -3
- package/dist/{index-05bm2ndp.js → index-chpzb6xy.js} +1 -1
- package/dist/{index-ttk3trse.js → index-csztadkj.js} +46 -17
- package/dist/{index-798s7c8s.js → index-hdyfvdag.js} +1 -1
- package/dist/{index-4ntnt8ee.js → index-jka4y6mv.js} +1 -1
- package/dist/{index-w6v4dw5f.js → index-kmrv1fw3.js} +4 -4
- package/dist/{index-jrj95cce.js → index-m6dnydf8.js} +9 -2
- package/dist/{index-e32b3x4n.js → index-pmcvg3k1.js} +4 -4
- package/dist/{index-4dhv7mqz.js → index-qjwpqvnf.js} +48 -1
- package/dist/{index-xccywqdj.js → index-rvf1726x.js} +3 -3
- package/dist/{index-1pf5qrx4.js → index-vyfrgwhk.js} +3 -3
- package/dist/{index-s8ks5nz4.js → index-watde7a1.js} +2 -2
- package/dist/{v2/server-fzgyvsb1.js → index-y14pawe1.js} +3 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +61 -52
- package/dist/{message-index-bounded-6fr624zf.js → message-index-bounded-r1qys471.js} +4 -4
- package/dist/migration-worker.js +3 -3
- package/dist/plugin/messages-transform.d.ts +3 -4
- package/dist/plugin/messages-transform.d.ts.map +1 -1
- package/dist/plugin/refusal-notice.d.ts +3 -0
- package/dist/plugin/refusal-notice.d.ts.map +1 -0
- package/dist/{project-embedding-registry-q80scexh.js → project-embedding-registry-8t0gwf59.js} +3 -3
- package/dist/raw-ordinal-warmup-worker.js +4 -4
- package/dist/{read-session-chunk-6wedfths.js → read-session-chunk-xv9f0wgb.js} +3 -3
- package/dist/{recomp-orchestrator-7ecg8ryx.js → recomp-orchestrator-2ztmtxt2.js} +18 -18
- package/dist/{render-yqp7q79f.js → render-d6q6h9hy.js} +10 -10
- package/dist/{rpc-notifications-t9q0ynq7.js → rpc-notifications-ta2zsxpq.js} +1 -1
- package/dist/{search-archive-r4h96j2z.js → search-archive-g96jn6p0.js} +5 -5
- package/dist/{search-bw22d7zc.js → search-d5aajhs3.js} +14 -14
- package/dist/{send-session-notification-7x518gew.js → send-session-notification-gzxz88vq.js} +1 -1
- package/dist/shared/assistant-message-extractor.d.ts +2 -0
- package/dist/shared/assistant-message-extractor.d.ts.map +1 -1
- package/dist/shared/prompt-async-transport.d.ts.map +1 -1
- package/dist/shared/rpc-notifications.d.ts +1 -1
- package/dist/shared/rpc-notifications.d.ts.map +1 -1
- package/dist/{storage-memory-e6a7mb0k.js → storage-memory-hhrvfw0x.js} +2 -2
- package/dist/{storage-tags-y2mrb8e6.js → storage-tags-f1ftvjpw.js} +2 -2
- package/dist/{transform-postprocess-phase-t99yj9vt.js → transform-postprocess-phase-b2yjw8by.js} +19 -19
- package/dist/v2/auto-search-worker.js +13 -7
- package/dist/v2/chunk-embedding-write-worker.js +4 -4
- package/dist/v2/{compartment-chunk-embedding-x6qw6mjk.js → compartment-chunk-embedding-knt2468v.js} +3 -1
- package/dist/v2/{context-k8sx1nyy.js → context-s86114yy.js} +219 -62
- package/dist/v2/{embedding-backfill-k8kqnwfq.js → embedding-backfill-tazkbpyg.js} +4 -4
- package/dist/v2/{embedding-cache-mgyr73ef.js → embedding-cache-zn4r1c31.js} +5 -1
- package/dist/v2/fold/native-replay.d.ts +3 -1
- package/dist/v2/fold/native-replay.d.ts.map +1 -1
- package/dist/v2/hidden-child-record.d.ts +1 -0
- package/dist/v2/hidden-child-record.d.ts.map +1 -1
- package/dist/v2/hidden-completion.d.ts.map +1 -1
- package/dist/v2/hooks/context.d.ts.map +1 -1
- package/dist/v2/{message-index-bounded-jqy7283g.js → message-index-bounded-b07r9cjv.js} +4 -4
- package/dist/v2/migration-worker.js +3 -3
- package/dist/v2/{project-embedding-registry-2jp1antr.js → project-embedding-registry-ah3gsg48.js} +3 -3
- package/dist/v2/raw-ordinal-warmup-worker.js +4 -4
- package/dist/v2/{read-session-chunk-n3nhfvd7.js → read-session-chunk-38wdy8nd.js} +3 -3
- package/dist/v2/{recomp-orchestrator-ssde9ft1.js → recomp-orchestrator-kc62xgb9.js} +17 -17
- package/dist/v2/{render-fezgh7pa.js → render-j05per51.js} +10 -10
- package/dist/v2/{rpc-notifications-t9q0ynq7.js → rpc-notifications-ta2zsxpq.js} +1 -1
- package/dist/v2/{search-archive-zz1kza50.js → search-archive-b4ptw02k.js} +5 -5
- package/dist/v2/{search-m251amra.js → search-kg31ad2s.js} +13 -13
- package/dist/v2/{send-session-notification-p52rhjzy.js → send-session-notification-zazaxxpf.js} +1 -1
- package/dist/v2/{server-ps6rz88g.js → server-2p0qayr1.js} +1 -1
- package/dist/v2/{server-fsw8kbng.js → server-2r9btf0g.js} +46 -17
- package/dist/v2/{server-wdq85mxj.js → server-6250cxzs.js} +14 -8
- package/dist/v2/{server-brgandk4.js → server-6vnbz81n.js} +2 -2
- package/dist/v2/{server-jjvbk92s.js → server-9emdjcb5.js} +1 -1
- package/dist/v2/{server-ap81bk3c.js → server-9n2qgk29.js} +1 -1
- package/dist/v2/{server-mbkwcwgw.js → server-axdmkvd5.js} +2 -2
- package/dist/v2/{server-2k8tkbhz.js → server-c7awk5s2.js} +10 -4
- package/dist/v2/{server-4wwwm2ya.js → server-ct0gs8fc.js} +4 -4
- package/dist/v2/{server-97w51d8n.js → server-ff5wcfy4.js} +3 -3
- package/dist/v2/{server-ssg29wjg.js → server-gqrw0br5.js} +20 -13
- package/dist/v2/{server-y31y6gws.js → server-gwhj0362.js} +3 -3
- package/dist/v2/{server-w7mpvkpj.js → server-pbp58w5x.js} +1 -1
- package/dist/v2/{server-s15knz0w.js → server-pmws7we9.js} +1 -1
- package/dist/v2/{server-4dhv7mqz.js → server-qjwpqvnf.js} +48 -1
- package/dist/v2/{server-a2f1bhyj.js → server-stjy5dxv.js} +9 -2
- package/dist/v2/{server-hn8b7sfe.js → server-xn7zqs4j.js} +2 -2
- package/dist/{index-fzgyvsb1.js → v2/server-y14pawe1.js} +3 -0
- package/dist/v2/{server-8pdfmc27.js → server-y17r5ryz.js} +4 -4
- package/dist/v2/{server-n5zr7190.js → server-yh2z4gg2.js} +3 -3
- package/dist/v2/{server-sxfbjdye.js → server-yx0nyj1q.js} +2 -2
- package/dist/v2/server.js +3 -3
- package/dist/v2/{storage-memory-e6a7mb0k.js → storage-memory-hhrvfw0x.js} +2 -2
- package/dist/v2/{storage-tags-xq81zgt2.js → storage-tags-pmw33chf.js} +2 -2
- package/dist/v2/{v2-archive-reader-e2w39c3p.js → v2-archive-reader-2ayz16s4.js} +1 -1
- package/dist/v2/{wrapup-orchestrator-eg5b1p89.js → wrapup-orchestrator-e20sjbdz.js} +17 -17
- package/dist/{v2-archive-reader-8dsngf2j.js → v2-archive-reader-x39mzvwn.js} +1 -1
- package/dist/{wrapup-orchestrator-nmk6yf7f.js → wrapup-orchestrator-h3s905vs.js} +19 -19
- package/package.json +1 -1
- package/src/shared/assistant-message-extractor.test.ts +22 -0
- package/src/shared/assistant-message-extractor.ts +13 -0
- package/src/shared/model-suggestion-retry.test.ts +43 -12
- package/src/shared/prompt-async-transport.test.ts +275 -8
- package/src/shared/prompt-async-transport.ts +41 -2
- package/src/shared/reusable-worker.fixture.ts +15 -3
- package/src/shared/reusable-worker.test.ts +20 -10
- package/src/shared/rpc-notifications.ts +4 -1
- package/src/shared/sqlite-foreground-wait.test.ts +2 -2
- package/src/shared/startup-maintenance-policy.test.ts +4 -2
|
@@ -21,10 +21,10 @@ import {
|
|
|
21
21
|
import {
|
|
22
22
|
OpenAICompatibleEmbeddingProvider,
|
|
23
23
|
embedTextForProject2
|
|
24
|
-
} from "./index-
|
|
24
|
+
} from "./index-watde7a1.js";
|
|
25
25
|
import {
|
|
26
26
|
saveEmbeddingIfHashMatches
|
|
27
|
-
} from "./index-
|
|
27
|
+
} from "./index-qjwpqvnf.js";
|
|
28
28
|
import {
|
|
29
29
|
getMemorySelectColumns2,
|
|
30
30
|
isMemoryRow2,
|
|
@@ -34,7 +34,7 @@ import {
|
|
|
34
34
|
buildWorkspaceMemorySqlFilter2,
|
|
35
35
|
getMemoryById2,
|
|
36
36
|
updateMemorySeenCount2
|
|
37
|
-
} from "./index-
|
|
37
|
+
} from "./index-9emdjcb5.js";
|
|
38
38
|
import {
|
|
39
39
|
computeNormalizedHash
|
|
40
40
|
} from "./index-2bvekkfy.js";
|
|
@@ -35,7 +35,7 @@ import {
|
|
|
35
35
|
getRawSessionTagKeysThrough2,
|
|
36
36
|
getLegacyProtectedTailStartOrdinal2,
|
|
37
37
|
readSessionChunk2
|
|
38
|
-
} from "./index-
|
|
38
|
+
} from "./index-2qsca7h7.js";
|
|
39
39
|
import {
|
|
40
40
|
getHarness2,
|
|
41
41
|
harnessOwnsOpenCodeStore2
|
|
@@ -117,7 +117,7 @@ import {
|
|
|
117
117
|
LATEST_SUPPORTED_VERSION,
|
|
118
118
|
getPersistedSchemaVersion,
|
|
119
119
|
openDatabase
|
|
120
|
-
} from "./index-
|
|
120
|
+
} from "./index-rvf1726x.js";
|
|
121
121
|
import {
|
|
122
122
|
areRustHistorianSyntheticParts2,
|
|
123
123
|
isStrictGapHealingMessage2,
|
|
@@ -134,10 +134,10 @@ import {
|
|
|
134
134
|
resolveStoredPathWorkspaceIdentity,
|
|
135
135
|
sourceNameForMemory,
|
|
136
136
|
computeWorkspaceEpochFingerprint
|
|
137
|
-
} from "./index-
|
|
137
|
+
} from "./index-bxrfq3mv.js";
|
|
138
138
|
import {
|
|
139
139
|
BoundedSessionMap
|
|
140
|
-
} from "./index-
|
|
140
|
+
} from "./index-m6dnydf8.js";
|
|
141
141
|
import {
|
|
142
142
|
V2_MEMORY_CATEGORIES,
|
|
143
143
|
CATEGORY_PRIORITY,
|
|
@@ -161,7 +161,7 @@ import {
|
|
|
161
161
|
replaceCompartmentChunkEmbeddings2,
|
|
162
162
|
deleteChunkEmbedBackoffForSession2,
|
|
163
163
|
chunkWindowSourceKey2
|
|
164
|
-
} from "./index-
|
|
164
|
+
} from "./index-3pdknr07.js";
|
|
165
165
|
import {
|
|
166
166
|
COMPARTMENT_LEASE_RENEWAL_MS,
|
|
167
167
|
getCompartmentLeaseBlocker,
|
|
@@ -206,14 +206,14 @@ import {
|
|
|
206
206
|
getProjectState,
|
|
207
207
|
recordSubagentInvocation,
|
|
208
208
|
getLatestHistorianInvocationId
|
|
209
|
-
} from "./index-
|
|
209
|
+
} from "./index-kmrv1fw3.js";
|
|
210
210
|
import {
|
|
211
211
|
clearCompressionDepth,
|
|
212
212
|
clearCompressionDepthRange,
|
|
213
213
|
toMessageIndexSource,
|
|
214
214
|
clearIndexedMessagesInTransaction,
|
|
215
215
|
indexSourcesAfterOrdinal
|
|
216
|
-
} from "./index-
|
|
216
|
+
} from "./index-chpzb6xy.js";
|
|
217
217
|
import {
|
|
218
218
|
stripWellFormedLeadingTagPrefix,
|
|
219
219
|
peelLeadingMcTagNotation,
|
|
@@ -263,7 +263,7 @@ import {
|
|
|
263
263
|
foldShrunkPartTags2,
|
|
264
264
|
getTagNumberByMessageId2,
|
|
265
265
|
getActiveTagsBySession2
|
|
266
|
-
} from "./index-
|
|
266
|
+
} from "./index-60wnwcwz.js";
|
|
267
267
|
import {
|
|
268
268
|
openCodeDbExists,
|
|
269
269
|
withReadOnlySessionDb,
|
|
@@ -273,10 +273,10 @@ import {
|
|
|
273
273
|
getSessionNotes,
|
|
274
274
|
getReadySmartNotes,
|
|
275
275
|
insertPrimerCandidates
|
|
276
|
-
} from "./index-
|
|
276
|
+
} from "./index-jka4y6mv.js";
|
|
277
277
|
import {
|
|
278
278
|
pushNotification2
|
|
279
|
-
} from "./index-
|
|
279
|
+
} from "./index-y14pawe1.js";
|
|
280
280
|
import {
|
|
281
281
|
computeCueContentHash,
|
|
282
282
|
getMuralCueState,
|
|
@@ -284,20 +284,20 @@ import {
|
|
|
284
284
|
getMemoriesByProject2,
|
|
285
285
|
getMemoriesByProjects2,
|
|
286
286
|
getMaxMemoryIdForProjects2
|
|
287
|
-
} from "./index-
|
|
287
|
+
} from "./index-9emdjcb5.js";
|
|
288
288
|
import {
|
|
289
289
|
contentSha2562,
|
|
290
290
|
enqueueShadowEmbeddingItems2,
|
|
291
291
|
getProjectChunkEmbeddingModelId2,
|
|
292
292
|
getProjectEmbeddingMaxInputTokens2,
|
|
293
293
|
embedItemsWindowBounded2
|
|
294
|
-
} from "./index-
|
|
294
|
+
} from "./index-watde7a1.js";
|
|
295
295
|
import {
|
|
296
296
|
renderUserFacingFailure,
|
|
297
297
|
userFacingFailureCode,
|
|
298
298
|
promoteSessionFactsDurable,
|
|
299
299
|
embedPromotedFacts
|
|
300
|
-
} from "./index-
|
|
300
|
+
} from "./index-c1s40xmj.js";
|
|
301
301
|
import {
|
|
302
302
|
isMarkerCandidateBasisCurrent2,
|
|
303
303
|
invalidateMarkerCandidateBasis2,
|
|
@@ -311,7 +311,7 @@ import {
|
|
|
311
311
|
} from "./index-832w615x.js";
|
|
312
312
|
import {
|
|
313
313
|
sendStatusNotification2
|
|
314
|
-
} from "./index-
|
|
314
|
+
} from "./index-6zewd2n5.js";
|
|
315
315
|
import {
|
|
316
316
|
isCompactionEnabled,
|
|
317
317
|
migrateLegacyAgentEnabledInMemory
|
|
@@ -5243,6 +5243,10 @@ function hasLengthCappedOutput(value) {
|
|
|
5243
5243
|
}
|
|
5244
5244
|
return Object.values(value).some((item) => hasLengthCappedOutput(item));
|
|
5245
5245
|
}
|
|
5246
|
+
function isLatestAssistantLengthCapped(messages) {
|
|
5247
|
+
const latest = getLatestAssistantMessage(messages);
|
|
5248
|
+
return hasLengthCappedOutput(latest?.info?.finish ? { finish: latest.info.finish } : null) || Array.isArray(latest?.parts) && latest.parts.some((part) => isRecord(part) && part.type === "step-finish" && hasLengthCappedOutput(part));
|
|
5249
|
+
}
|
|
5246
5250
|
function describeAssistantSettlement(output) {
|
|
5247
5251
|
if (isRecord(output) && isRecord(output.tokenLog)) {
|
|
5248
5252
|
return `finish=${String(output.tokenLog.finish_reason ?? "unknown")}, reasoning=${typeof output.reasoning === "string" && output.reasoning.length > 0}`;
|
|
@@ -6259,6 +6263,24 @@ function messageId(message) {
|
|
|
6259
6263
|
const id = infoOf(message).id;
|
|
6260
6264
|
return typeof id === "string" ? id : null;
|
|
6261
6265
|
}
|
|
6266
|
+
function inFlightAtAbort(messages, initialBaseline) {
|
|
6267
|
+
const reply = messages.slice().reverse().find((message) => {
|
|
6268
|
+
const id = messageId(message);
|
|
6269
|
+
return id !== null && !initialBaseline.has(id) && infoOf(message).role === "assistant";
|
|
6270
|
+
});
|
|
6271
|
+
const parts = reply?.parts;
|
|
6272
|
+
const ids = new Set;
|
|
6273
|
+
if (Array.isArray(parts)) {
|
|
6274
|
+
for (const part of parts) {
|
|
6275
|
+
if (part?.type !== "tool" || typeof part.callID !== "string")
|
|
6276
|
+
continue;
|
|
6277
|
+
const state = part.state;
|
|
6278
|
+
if (state?.status === "pending" || state?.status === "running" || state?.status === "error" && state.error === "Tool execution aborted" && state.metadata?.interrupted === true)
|
|
6279
|
+
ids.add(part.callID);
|
|
6280
|
+
}
|
|
6281
|
+
}
|
|
6282
|
+
return ids;
|
|
6283
|
+
}
|
|
6262
6284
|
function recordedAssistantError(message) {
|
|
6263
6285
|
const info = infoOf(message);
|
|
6264
6286
|
if (info.error != null)
|
|
@@ -6483,7 +6505,7 @@ async function promptAsyncAndWaitForIdle(client, request, options = {}) {
|
|
|
6483
6505
|
finalizing = true;
|
|
6484
6506
|
sessionLog2(sessionId, "dreamer token budget: finalize fired", budget.snapshot());
|
|
6485
6507
|
budgetAbortedSessions.add(sessionId);
|
|
6486
|
-
registerBudgetFinalizeChild(sessionId, budget);
|
|
6508
|
+
const countRefusals = registerBudgetFinalizeChild(sessionId, budget);
|
|
6487
6509
|
if (!session.abort)
|
|
6488
6510
|
throw new DreamTokenBudgetExceeded(sessionId, budget.snapshot().spent);
|
|
6489
6511
|
await session.abort({ path: { id: sessionId } });
|
|
@@ -6497,7 +6519,14 @@ async function promptAsyncAndWaitForIdle(client, request, options = {}) {
|
|
|
6497
6519
|
if (await readStatus(session, sessionId, dir, signal) !== "idle") {
|
|
6498
6520
|
throw new DreamTokenBudgetExceeded(sessionId, budget.snapshot().spent);
|
|
6499
6521
|
}
|
|
6500
|
-
|
|
6522
|
+
const cancelled = await readMessages(session, sessionId, dir, signal);
|
|
6523
|
+
completionBaseline = new Set((cancelled.length ? cancelled : messages).map(messageId).filter((value) => value !== null));
|
|
6524
|
+
const exemptCallIds = inFlightAtAbort(cancelled, initialBaseline);
|
|
6525
|
+
countRefusals(exemptCallIds);
|
|
6526
|
+
sessionLog2(sessionId, "dreamer token budget: counting tool refusals", {
|
|
6527
|
+
snapshot: cancelled.length ? "read" : "unreadable",
|
|
6528
|
+
exemptCallIds: [...exemptCallIds]
|
|
6529
|
+
});
|
|
6501
6530
|
const finalizeResponse = await session.promptAsync?.({
|
|
6502
6531
|
...request,
|
|
6503
6532
|
body: {
|
|
@@ -19506,4 +19535,4 @@ async function executeContextRecomp(deps, options = {}) {
|
|
|
19506
19535
|
return (await executeContextRecompWithResult(deps, options)).message;
|
|
19507
19536
|
}
|
|
19508
19537
|
|
|
19509
|
-
export { denyTaskRoutingToCallerAgents, buildHiddenAgentRegistrations, buildZenReadAgentRegistrations, buildHiddenAgentConfig, getMagicContextBuiltinCommands, formatConfigParseStatusLine, claimConfigParseFailuresOnce, isCommitRetentionPaused, cortexKitUserConfigBasePath, cortexKitProjectConfigBasePath, resolveLegacyConfigSources, migrateMagicContextConfigLocations, getProtectedTokensTierOverrides, loadPluginConfigDetailed, historianRunConfig, dreamerRunConfig, pluginConfigReader, currentPluginConfigReader, withLiveDreamerOutputCap, createDreamerOutputCapSampler, COMPARTMENT_AGENT_SYSTEM_PROMPT, HISTORIAN_EDITOR_SYSTEM_PROMPT, COMPARTMENT_STRUCTURAL_SYSTEM_PROMPT, clampProducerAtomChars, producerInputTokenLimit, historianProducerReserve, producerPromptFailureReason, DREAMER_AGENT, DREAMER_RETROSPECTIVE_AGENT, DREAMER_PRIMER_INVESTIGATOR_AGENT, DREAMER_MEMORY_MAPPER_AGENT, DREAMER_CLASSIFIER_AGENT, DREAMER_DOCS_AGENT, DREAMER_REVIEWER_AGENT, createChildSessionWithFence, HiddenCompletionRefusal, DreamerProviderOutputFailureError, providerOutputFailureFromInvalidManifest, supportsQuietHiddenChildren, matchesHiddenRunLocation, hiddenRunPlacement, HIDDEN_HISTORIAN_AGENT, HIDDEN_DREAMER_AGENT, HIDDEN_CURATE_AGENT, hiddenAgentFor, hiddenToolLoop, HIDDEN_RUN_DISPOSED_REASON, noteChildOfDisposedInstance, hiddenChildPermissions, registerHiddenChildAgents, hiddenToolCallRefusal, HiddenAgentStepLimit, HiddenChildHook, extractLatestAssistantText, hasLengthCappedOutput, parseProviderModel, modelBodyField, toModelEntry, hiddenModelCooldowns, ModelProducedNoOutputError, noteModelActivityMonitored, noteModelOutputReceived, isPromptTimeoutError, getPromptFailureDetail, raceWithSignal, promptSyncWithValidatedOutputRetry, normalizeSDKResponse, annotateSubagentInvocationError, failedInvocationStatus, emptyTokenTotals, sumTokensFromChildMessages, recordChildInvocation, recordPromptSessionError, createPromptAsyncTransport, CTX_NOTE_LIGHT_DESCRIPTION, ACTIVE_TOOL_IDS, systemPromptFingerprint, createPromptSurfaceRuntime, createPromptSurfaceGuidanceEpochCache, setKeepSubagents, teardownChildSession, getCompartmentEvents, runTokenLog, formatRunTokenLog, validateStoredCompartments, buildMagicContextSection, getMuralIdentity, getMural, modelKeyAcceptsImages, resolveMuralWire, v2ToolDefinitionsHash, v2RequestToolsFingerprint, classifyRequestToolsChange, USER_MEMORY_CANDIDATE_TTL_MS, insertUserMemoryCandidates, getUserMemoryCandidates, deleteUserMemoryCandidates, pruneExpiredUserMemoryCandidates, insertUserMemory, getActiveUserMemories, updateUserMemoryContent, dismissUserMemory, getOpenCodeDbPath, compareOpenCodeMessagesByCanonicalOrder, startCompactionMarkerCandidatePreparation, removeMcOwnedCompactionMarkers, MARKER_SUMMARY_TEXT, markerUpdateDefinitelyDidNotCut, applyDeferredCompactionMarker, removeCompactionMarkerForSession, checkCompactionMarkerConsistency, extractM0Block, formatDate, TEMPORAL_MARKER_REPLAY_PATTERN, collectTemporalCandidates, injectTemporalMarkers, clearInjectionCache, getVisibleMemoryIds, selectHiddenMessagesAtCompactionSeam, prepareCompartmentInjection, renderCompartmentInjection, MaterializeContentionError, mustMaterialize, trimMemoriesToBudgetV2, renderMemoryBlockV2, stripMemoryMuralBlock, servedHeadTexts, materializeM0, hydrateCachedM0Mural, resetPrefixTrimFallbackState, findHostCompactionWindow, capturePrefixTrimSourceOrder, prepareCachedM0M1Replay, headMessagesForSizing, rawTailAfterNewestCompartment, hasCompleteCachedM0M1, injectM0M1, resolveHiddenCompletionExecutor, createV1HiddenCompletionExecutor, readCoordinateGeneration, readCoordinateRebaseNotice, formatCoordinateRebaseNotice, rebaseSessionCoordinatesAsync, readHistorianFailureStreak, describeHistorianJoinRefusal, shouldWaitForNewHistorianHistory, EMPTY_READ_REPLY, noteTouchedAt, renderGlance, renderNotesById, formatWriteReply, observeNoteNudgeServe, onNoteTrigger, peekNoteNudgeText, markNoteNudgeDelivered, clearNoteNudgeTriggerAndCooldown, resetNoteNudgeCooldownOnly, clearNoteNudgeTriggerOnly, omitIncompleteFileTokenTotals, describeBoundaryDiagnostics, RECOVERY_NO_HEAD_LIMIT, deriveProtectedTailTokenTarget, selectPerRunCap, resolveOpenCodeProtectedTailBoundary, resolveWrapupProtectedTailBoundary, getRawHistoryEligibility, hasRunnableCompartmentWindow, recordHighPressureNoEligibleHead, noteTransformPassForExactOrdinalReads, nonNarrativeStoredGapRanges, runCompartmentAgent, snapRangeToCompartments, getActiveCompartmentRun, markActiveCompartmentRunPublished, registerActiveCompartmentRun, startCompartmentAgent, executeContextRecomp };
|
|
19538
|
+
export { denyTaskRoutingToCallerAgents, buildHiddenAgentRegistrations, buildZenReadAgentRegistrations, buildHiddenAgentConfig, getMagicContextBuiltinCommands, formatConfigParseStatusLine, claimConfigParseFailuresOnce, isCommitRetentionPaused, cortexKitUserConfigBasePath, cortexKitProjectConfigBasePath, resolveLegacyConfigSources, migrateMagicContextConfigLocations, getProtectedTokensTierOverrides, loadPluginConfigDetailed, historianRunConfig, dreamerRunConfig, pluginConfigReader, currentPluginConfigReader, withLiveDreamerOutputCap, createDreamerOutputCapSampler, COMPARTMENT_AGENT_SYSTEM_PROMPT, HISTORIAN_EDITOR_SYSTEM_PROMPT, COMPARTMENT_STRUCTURAL_SYSTEM_PROMPT, clampProducerAtomChars, producerInputTokenLimit, historianProducerReserve, producerPromptFailureReason, DREAMER_AGENT, DREAMER_RETROSPECTIVE_AGENT, DREAMER_PRIMER_INVESTIGATOR_AGENT, DREAMER_MEMORY_MAPPER_AGENT, DREAMER_CLASSIFIER_AGENT, DREAMER_DOCS_AGENT, DREAMER_REVIEWER_AGENT, createChildSessionWithFence, HiddenCompletionRefusal, DreamerProviderOutputFailureError, providerOutputFailureFromInvalidManifest, supportsQuietHiddenChildren, matchesHiddenRunLocation, hiddenRunPlacement, HIDDEN_HISTORIAN_AGENT, HIDDEN_DREAMER_AGENT, HIDDEN_CURATE_AGENT, hiddenAgentFor, hiddenToolLoop, HIDDEN_RUN_DISPOSED_REASON, noteChildOfDisposedInstance, hiddenChildPermissions, registerHiddenChildAgents, hiddenToolCallRefusal, HiddenAgentStepLimit, HiddenChildHook, extractLatestAssistantText, hasLengthCappedOutput, isLatestAssistantLengthCapped, parseProviderModel, modelBodyField, toModelEntry, hiddenModelCooldowns, ModelProducedNoOutputError, noteModelActivityMonitored, noteModelOutputReceived, isPromptTimeoutError, getPromptFailureDetail, raceWithSignal, promptSyncWithValidatedOutputRetry, normalizeSDKResponse, annotateSubagentInvocationError, failedInvocationStatus, emptyTokenTotals, sumTokensFromChildMessages, recordChildInvocation, recordPromptSessionError, createPromptAsyncTransport, CTX_NOTE_LIGHT_DESCRIPTION, ACTIVE_TOOL_IDS, systemPromptFingerprint, createPromptSurfaceRuntime, createPromptSurfaceGuidanceEpochCache, setKeepSubagents, teardownChildSession, getCompartmentEvents, runTokenLog, formatRunTokenLog, validateStoredCompartments, buildMagicContextSection, getMuralIdentity, getMural, modelKeyAcceptsImages, resolveMuralWire, v2ToolDefinitionsHash, v2RequestToolsFingerprint, classifyRequestToolsChange, USER_MEMORY_CANDIDATE_TTL_MS, insertUserMemoryCandidates, getUserMemoryCandidates, deleteUserMemoryCandidates, pruneExpiredUserMemoryCandidates, insertUserMemory, getActiveUserMemories, updateUserMemoryContent, dismissUserMemory, getOpenCodeDbPath, compareOpenCodeMessagesByCanonicalOrder, startCompactionMarkerCandidatePreparation, removeMcOwnedCompactionMarkers, MARKER_SUMMARY_TEXT, markerUpdateDefinitelyDidNotCut, applyDeferredCompactionMarker, removeCompactionMarkerForSession, checkCompactionMarkerConsistency, extractM0Block, formatDate, TEMPORAL_MARKER_REPLAY_PATTERN, collectTemporalCandidates, injectTemporalMarkers, clearInjectionCache, getVisibleMemoryIds, selectHiddenMessagesAtCompactionSeam, prepareCompartmentInjection, renderCompartmentInjection, MaterializeContentionError, mustMaterialize, trimMemoriesToBudgetV2, renderMemoryBlockV2, stripMemoryMuralBlock, servedHeadTexts, materializeM0, hydrateCachedM0Mural, resetPrefixTrimFallbackState, findHostCompactionWindow, capturePrefixTrimSourceOrder, prepareCachedM0M1Replay, headMessagesForSizing, rawTailAfterNewestCompartment, hasCompleteCachedM0M1, injectM0M1, resolveHiddenCompletionExecutor, createV1HiddenCompletionExecutor, readCoordinateGeneration, readCoordinateRebaseNotice, formatCoordinateRebaseNotice, rebaseSessionCoordinatesAsync, readHistorianFailureStreak, describeHistorianJoinRefusal, shouldWaitForNewHistorianHistory, EMPTY_READ_REPLY, noteTouchedAt, renderGlance, renderNotesById, formatWriteReply, observeNoteNudgeServe, onNoteTrigger, peekNoteNudgeText, markNoteNudgeDelivered, clearNoteNudgeTriggerAndCooldown, resetNoteNudgeCooldownOnly, clearNoteNudgeTriggerOnly, omitIncompleteFileTokenTotals, describeBoundaryDiagnostics, RECOVERY_NO_HEAD_LIMIT, deriveProtectedTailTokenTarget, selectPerRunCap, resolveOpenCodeProtectedTailBoundary, resolveWrapupProtectedTailBoundary, getRawHistoryEligibility, hasRunnableCompartmentWindow, recordHighPressureNoEligibleHead, noteTransformPassForExactOrdinalReads, nonNarrativeStoredGapRanges, runCompartmentAgent, snapRangeToCompartments, getActiveCompartmentRun, markActiveCompartmentRunPublished, registerActiveCompartmentRun, startCompartmentAgent, executeContextRecomp };
|
|
@@ -7,7 +7,7 @@ import {
|
|
|
7
7
|
deleteTagIdentityRevisions,
|
|
8
8
|
getTableColumnNames,
|
|
9
9
|
getMeasuredToolDefinitionTokens
|
|
10
|
-
} from "./index-
|
|
10
|
+
} from "./index-m6dnydf8.js";
|
|
11
11
|
import {
|
|
12
12
|
invalidateAutoEmbedSession,
|
|
13
13
|
drainBackgroundBatches
|
|
@@ -31,7 +31,7 @@ import {
|
|
|
31
31
|
} from "./index-s32f8y67.js";
|
|
32
32
|
import {
|
|
33
33
|
deleteChunkEmbedBackoffForSession2
|
|
34
|
-
} from "./index-
|
|
34
|
+
} from "./index-3pdknr07.js";
|
|
35
35
|
import {
|
|
36
36
|
isPidAlive,
|
|
37
37
|
readProcessStartTime
|
|
@@ -68,14 +68,14 @@ import {
|
|
|
68
68
|
getPendingPiCompactionMarkerState,
|
|
69
69
|
logPiCompactionMarkerClear,
|
|
70
70
|
isPrefixBoundThinkingModel
|
|
71
|
-
} from "./index-
|
|
71
|
+
} from "./index-60wnwcwz.js";
|
|
72
72
|
import {
|
|
73
73
|
withReadOnlySessionDb
|
|
74
74
|
} from "./index-x40zr813.js";
|
|
75
75
|
import {
|
|
76
76
|
layoutLkgPrefix,
|
|
77
77
|
assembleLkgPrefix
|
|
78
|
-
} from "./index-
|
|
78
|
+
} from "./index-bxrfq3mv.js";
|
|
79
79
|
import {
|
|
80
80
|
ensurePrivateStorageDirectorySync,
|
|
81
81
|
writeStorageFileSync,
|
|
@@ -912,7 +912,10 @@ function recordToolDefinitionSet(providerID, modelID, agentName, tools, sessionI
|
|
|
912
912
|
for (const [toolID, slot] of next)
|
|
913
913
|
writeSlot(route, toolID, slot);
|
|
914
914
|
if (sessionId)
|
|
915
|
-
sessionFlights.set(sessionId, {
|
|
915
|
+
sessionFlights.set(sessionId, {
|
|
916
|
+
key,
|
|
917
|
+
exact: { ...summarize([...next.entries()], true), providerID, modelID }
|
|
918
|
+
});
|
|
916
919
|
}
|
|
917
920
|
function getCurrentToolSetHash(providerID, modelID, agentName, sessionId) {
|
|
918
921
|
return resolve(providerID, modelID, agentName, sessionId)?.hash ?? "";
|
|
@@ -923,6 +926,10 @@ function getToolDefinitionMeasurementSignature(providerID, modelID, agentName, s
|
|
|
923
926
|
function getMeasuredToolDefinitionTokens(providerID, modelID, agentName, sessionId) {
|
|
924
927
|
return resolve(providerID, modelID, agentName, sessionId)?.total;
|
|
925
928
|
}
|
|
929
|
+
function getExactSessionToolDefinitionTokens(providerID, modelID, sessionId) {
|
|
930
|
+
const exact = sessionFlights.peek(sessionId)?.exact;
|
|
931
|
+
return exact && exact.providerID === providerID && exact.modelID === modelID ? exact.total : undefined;
|
|
932
|
+
}
|
|
926
933
|
function getSessionToolDefinitionTokens(sessionId) {
|
|
927
934
|
if (!sessionId)
|
|
928
935
|
return;
|
|
@@ -935,4 +942,4 @@ function getSessionToolDefinitionTokens(sessionId) {
|
|
|
935
942
|
return route ? summarize(currentTools(route), route.live).total : undefined;
|
|
936
943
|
}
|
|
937
944
|
|
|
938
|
-
export { BoundedSessionMap, tagTombstoneOwnerRange, tagTombstoneOwnerKey, tagRevisionKey, tagIdentityRevisionKey, installTagIdentityRevisionTrigger, deleteTagIdentityRevisions, getTableColumnNames, ensureColumn, healAllNullColumns, getTemporalDecisions, observeTemporalDecisions, freezeTemporalDecisions, deleteTemporalDecision, installV95PerfSchema, tagOrderConstraintIndex, stableStringify, stableStringifyHash, setDatabase, loadToolDefinitionMeasurements, recordToolDefinition, recordToolDefinitionSet, getCurrentToolSetHash, getToolDefinitionMeasurementSignature, getMeasuredToolDefinitionTokens, getSessionToolDefinitionTokens };
|
|
945
|
+
export { BoundedSessionMap, tagTombstoneOwnerRange, tagTombstoneOwnerKey, tagRevisionKey, tagIdentityRevisionKey, installTagIdentityRevisionTrigger, deleteTagIdentityRevisions, getTableColumnNames, ensureColumn, healAllNullColumns, getTemporalDecisions, observeTemporalDecisions, freezeTemporalDecisions, deleteTemporalDecision, installV95PerfSchema, tagOrderConstraintIndex, stableStringify, stableStringifyHash, setDatabase, loadToolDefinitionMeasurements, recordToolDefinition, recordToolDefinitionSet, getCurrentToolSetHash, getToolDefinitionMeasurementSignature, getMeasuredToolDefinitionTokens, getExactSessionToolDefinitionTokens, getSessionToolDefinitionTokens };
|
|
@@ -3,18 +3,18 @@ import {
|
|
|
3
3
|
} from "./index-ywrz4wy2.js";
|
|
4
4
|
import {
|
|
5
5
|
clearEmergencyRecovery
|
|
6
|
-
} from "./index-
|
|
6
|
+
} from "./index-60wnwcwz.js";
|
|
7
7
|
import {
|
|
8
8
|
requestPendingMaterialization,
|
|
9
9
|
dropSlot
|
|
10
|
-
} from "./index-
|
|
10
|
+
} from "./index-kmrv1fw3.js";
|
|
11
11
|
import {
|
|
12
12
|
executeContextRecomp
|
|
13
|
-
} from "./index-
|
|
13
|
+
} from "./index-csztadkj.js";
|
|
14
14
|
import {
|
|
15
15
|
renderUserFacingFailure,
|
|
16
16
|
userFacingFailureCode
|
|
17
|
-
} from "./index-
|
|
17
|
+
} from "./index-c1s40xmj.js";
|
|
18
18
|
|
|
19
19
|
// src/hooks/magic-context/recomp-orchestrator.ts
|
|
20
20
|
function resolveLiveModelKey(liveSessionState, sessionId) {
|
|
@@ -72,6 +72,41 @@ function getMemoryEmbedCoverage(db, projectPath, modelId) {
|
|
|
72
72
|
var DEFAULT_EMBEDDING_CACHE_TTL_MS = 60000;
|
|
73
73
|
var projectEmbeddingCache = new Map;
|
|
74
74
|
var embeddingCacheTtlMs = DEFAULT_EMBEDDING_CACHE_TTL_MS;
|
|
75
|
+
var keptWorkerCaches = new WeakMap;
|
|
76
|
+
function keepWorkerMemoryEmbeddings2(db) {
|
|
77
|
+
keptWorkerCaches.set(db, {
|
|
78
|
+
entries: new Map,
|
|
79
|
+
lastBackgroundReloadAt: -Infinity
|
|
80
|
+
});
|
|
81
|
+
}
|
|
82
|
+
function readDataVersion(db, cache) {
|
|
83
|
+
cache.version ??= db.prepare("PRAGMA data_version");
|
|
84
|
+
return Number(cache.version.get().data_version);
|
|
85
|
+
}
|
|
86
|
+
function loadKeptWorkerEntry(db, cache, projectPath, modelId, version, loadedAt) {
|
|
87
|
+
const embeddings = loadAllEmbeddings(db, projectPath, modelId);
|
|
88
|
+
cache.entries.set(projectPath, {
|
|
89
|
+
projectPath,
|
|
90
|
+
modelId,
|
|
91
|
+
version,
|
|
92
|
+
loadedAt,
|
|
93
|
+
embeddings
|
|
94
|
+
});
|
|
95
|
+
return embeddings;
|
|
96
|
+
}
|
|
97
|
+
function maintainKeptWorkerMemoryEmbeddings2(db) {
|
|
98
|
+
const cache = keptWorkerCaches.get(db);
|
|
99
|
+
const now = Date.now();
|
|
100
|
+
if (!cache?.entries.size || now - cache.lastBackgroundReloadAt < DEFAULT_EMBEDDING_CACHE_TTL_MS)
|
|
101
|
+
return;
|
|
102
|
+
const version = readDataVersion(db, cache);
|
|
103
|
+
for (const entry of cache.entries.values()) {
|
|
104
|
+
if (entry.version === version || now - entry.loadedAt < DEFAULT_EMBEDDING_CACHE_TTL_MS)
|
|
105
|
+
continue;
|
|
106
|
+
cache.lastBackgroundReloadAt = now;
|
|
107
|
+
loadKeptWorkerEntry(db, cache, entry.projectPath, entry.modelId, version, now);
|
|
108
|
+
}
|
|
109
|
+
}
|
|
75
110
|
function cacheKey(projectPath, modelId) {
|
|
76
111
|
return `${projectPath}\x00${modelId}`;
|
|
77
112
|
}
|
|
@@ -87,6 +122,18 @@ function getValidCacheEntry(projectPath, modelId) {
|
|
|
87
122
|
return entry;
|
|
88
123
|
}
|
|
89
124
|
function getProjectEmbeddings2(db, projectPath, modelId) {
|
|
125
|
+
const kept = keptWorkerCaches.get(db);
|
|
126
|
+
if (kept) {
|
|
127
|
+
const now = Date.now();
|
|
128
|
+
const cached = kept.entries.get(projectPath);
|
|
129
|
+
const entry = cached?.modelId === modelId ? cached : undefined;
|
|
130
|
+
if (entry && now - entry.loadedAt < DEFAULT_EMBEDDING_CACHE_TTL_MS)
|
|
131
|
+
return entry.embeddings;
|
|
132
|
+
const version = readDataVersion(db, kept);
|
|
133
|
+
if (entry?.version === version)
|
|
134
|
+
return entry.embeddings;
|
|
135
|
+
return loadKeptWorkerEntry(db, kept, projectPath, modelId, version, now);
|
|
136
|
+
}
|
|
90
137
|
const cached = getValidCacheEntry(projectPath, modelId);
|
|
91
138
|
if (cached) {
|
|
92
139
|
return cached.embeddings;
|
|
@@ -128,4 +175,4 @@ function setEmbeddingCacheTtlForTests2(ttlMs) {
|
|
|
128
175
|
embeddingCacheTtlMs = Math.max(0, Math.floor(ttlMs));
|
|
129
176
|
}
|
|
130
177
|
|
|
131
|
-
export { saveEmbeddingIfHashMatches, getMemoryEmbedCoverage, getProjectEmbeddings2, peekProjectEmbeddings2, invalidateProject2, invalidateMemory2, resetEmbeddingCacheForTests2, setEmbeddingCacheTtlForTests2 };
|
|
178
|
+
export { saveEmbeddingIfHashMatches, getMemoryEmbedCoverage, keepWorkerMemoryEmbeddings2, maintainKeptWorkerMemoryEmbeddings2, getProjectEmbeddings2, peekProjectEmbeddings2, invalidateProject2, invalidateMemory2, resetEmbeddingCacheForTests2, setEmbeddingCacheTtlForTests2 };
|
|
@@ -65,14 +65,14 @@ import {
|
|
|
65
65
|
hasPendingMigrations,
|
|
66
66
|
getMainThreadMigrationBodyCount,
|
|
67
67
|
runMigrations
|
|
68
|
-
} from "./index-
|
|
68
|
+
} from "./index-bxrfq3mv.js";
|
|
69
69
|
import {
|
|
70
70
|
installTagIdentityRevisionTrigger,
|
|
71
71
|
ensureColumn,
|
|
72
72
|
installV95PerfSchema,
|
|
73
73
|
setDatabase,
|
|
74
74
|
loadToolDefinitionMeasurements
|
|
75
|
-
} from "./index-
|
|
75
|
+
} from "./index-m6dnydf8.js";
|
|
76
76
|
import {
|
|
77
77
|
resolveOpenCodeDbPath,
|
|
78
78
|
hasV1MessageTables
|
|
@@ -1021,7 +1021,7 @@ function finishDatabaseOpen(db, dbPath, explicitDbPath, latestSupportedVersion)
|
|
|
1021
1021
|
state.running = startMessageFtsRowidMapBackfill2(db, signal).then(async () => {
|
|
1022
1022
|
if (signal.aborted || !readsOpenCodeStore)
|
|
1023
1023
|
return;
|
|
1024
|
-
const { readRawSessionMessagePage, readRawSessionMessages } = await importPluginModule(() => import("./read-session-chunk-
|
|
1024
|
+
const { readRawSessionMessagePage, readRawSessionMessages } = await importPluginModule(() => import("./read-session-chunk-xv9f0wgb.js"));
|
|
1025
1025
|
const { startMessageTimeBackfill } = await importPluginModule(() => import("./message-time-backfill-pz5981mf.js"));
|
|
1026
1026
|
if (signal.aborted)
|
|
1027
1027
|
return;
|
|
@@ -139,9 +139,9 @@ async function serveV2ArchiveReads2(port, openConnections) {
|
|
|
139
139
|
import("./sqlite-zdgm52sv.js"),
|
|
140
140
|
import("./store-reader-nf8z86n9.js"),
|
|
141
141
|
import("./store-n4yz3n66.js"),
|
|
142
|
-
import("./read-session-chunk-
|
|
143
|
-
import("./render-
|
|
144
|
-
import("./search-archive-
|
|
142
|
+
import("./read-session-chunk-xv9f0wgb.js"),
|
|
143
|
+
import("./render-d6q6h9hy.js"),
|
|
144
|
+
import("./search-archive-g96jn6p0.js"),
|
|
145
145
|
import("./expand-attachments-h33jbgyz.js")
|
|
146
146
|
]);
|
|
147
147
|
const pool = new V2StoreReaderPool;
|
|
@@ -43,7 +43,7 @@ import {
|
|
|
43
43
|
countSessionCompartmentEmbedCoverage2,
|
|
44
44
|
countSessionCompartmentEmbedCoveragePolite2,
|
|
45
45
|
countUnembeddedSessionCompartmentsPolite2
|
|
46
|
-
} from "./index-
|
|
46
|
+
} from "./index-3pdknr07.js";
|
|
47
47
|
import {
|
|
48
48
|
DEFAULT_LOCAL_EMBEDDING_MODEL
|
|
49
49
|
} from "./index-6nqz8hsz.js";
|
|
@@ -83,7 +83,7 @@ import {
|
|
|
83
83
|
saveEmbeddingIfHashMatches,
|
|
84
84
|
getMemoryEmbedCoverage,
|
|
85
85
|
invalidateProject2
|
|
86
|
-
} from "./index-
|
|
86
|
+
} from "./index-qjwpqvnf.js";
|
|
87
87
|
import {
|
|
88
88
|
isKnownAutocommit
|
|
89
89
|
} from "./index-8ajstryz.js";
|
|
@@ -17,13 +17,16 @@ function notificationMatchesSink(notification, sink) {
|
|
|
17
17
|
}
|
|
18
18
|
function pushLiveNotification2(type, payload, sessionId) {
|
|
19
19
|
const notification = { id: nextNotificationId++, type, payload, sessionId };
|
|
20
|
+
let delivered = false;
|
|
20
21
|
for (const sink of sinks) {
|
|
21
22
|
if (sink.sessionId !== sessionId)
|
|
22
23
|
continue;
|
|
23
24
|
try {
|
|
24
25
|
sink.send(notification);
|
|
26
|
+
delivered = true;
|
|
25
27
|
} catch {}
|
|
26
28
|
}
|
|
29
|
+
return delivered;
|
|
27
30
|
}
|
|
28
31
|
function pushNotification2(type, payload, sessionId, options) {
|
|
29
32
|
const notification = { id: nextNotificationId++, type, payload, sessionId };
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAiB,YAAY,EAAE,MAAM,qBAAqB,CAAC;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAiB,YAAY,EAAE,MAAM,qBAAqB,CAAC;AAuHvE,OAAO,EAAE,KAAK,EAAE,MAAM,aAAa,CAAC;AAojCpC,QAAA,MAAM,MAAM,EAAE,YAAY,GAAG;IAAE,KAAK,EAAE,OAAO,KAAK,CAAA;CAIjD,CAAC;AAEF,eAAe,MAAM,CAAC"}
|