@cortexkit/pi-magic-context 0.49.48 → 0.49.49
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 +5 -5
- package/dist/chunk-embedding-write-worker.js +12 -12
- package/dist/{compaction-marker-candidates-17a21jfn.js → compaction-marker-candidates-9yhrstyb.js} +2 -2
- package/dist/compaction-marker-candidates-worker.js +1 -1
- package/dist/{compartment-chunk-embedding-nyjs3dfh.js → compartment-chunk-embedding-wg7emg3z.js} +7 -7
- package/dist/{embedding-backfill-er9jc4xf.js → embedding-backfill-xsd7fc5c.js} +12 -12
- package/dist/embedding-worker-process.js +1 -1
- package/dist/embedding-worker.js +4 -4
- package/dist/historian-calibration-extension.js +1 -1
- package/dist/{index-w26zvs1q.js → index-46wk0td0.js} +1 -1
- package/dist/{index-bbbp8zs1.js → index-6d0bby9d.js} +2 -2
- package/dist/{index-000fthre.js → index-7y60kyea.js} +1 -1
- package/dist/{index-gwm5x42c.js → index-8bpxfq4c.js} +3 -3
- package/dist/{index-vnygvrad.js → index-9036v8ay.js} +6 -6
- package/dist/{index-pja6ggeq.js → index-9n1hyjck.js} +10 -10
- package/dist/{index-806brt0p.js → index-bjeb4ya4.js} +10 -10
- package/dist/{index-rcenqffj.js → index-cmyk3bmf.js} +8 -8
- package/dist/{index-0wtm7g7f.js → index-j0eagxkz.js} +1 -1
- package/dist/{index-yacs388s.js → index-jxm4bvm4.js} +1 -1
- package/dist/{index-4sa1rx3h.js → index-ndg15t3x.js} +4 -4
- package/dist/{index-j1kkx3f3.js → index-pkg07s54.js} +2 -2
- package/dist/{index-bhj8kymt.js → index-qcsjj9m0.js} +3 -3
- package/dist/{index-gwvahsdz.js → index-qm139qq2.js} +2 -2
- package/dist/{index-3g9fnq6y.js → index-szn2tac8.js} +1 -1
- package/dist/{index-h1rtbjrp.js → index-vdrqxca5.js} +19 -19
- package/dist/{index-zybqfwfv.js → index-wz66mger.js} +4 -4
- package/dist/{index-2kmwjq42.js → index-xssjy4z9.js} +1 -1
- package/dist/{index-6pk49fc3.js → index-xx1911hb.js} +1 -1
- package/dist/{index-bbffazv6.js → index-y2g8rdmm.js} +8 -8
- package/dist/{index-zwbgxt01.js → index-yc4vfwvm.js} +4 -4
- package/dist/{index-cq71g4dk.js → index-yjgkjkjs.js} +1 -1
- package/dist/{index-gymgz20n.js → index-yxeg8zaa.js} +23 -20
- package/dist/{index-d107f484.js → index-zc6fdyx7.js} +4 -4
- package/dist/{index-6748dkmx.js → index-zggajt0j.js} +2 -2
- package/dist/{index-tsg6swzr.js → index-zrbvwxtb.js} +2 -2
- package/dist/{index-mp0gh04g.js → index-zxm7ckvc.js} +2 -2
- package/dist/index.js +49 -37
- package/dist/{logger-2j70hhz4.js → logger-hhgpkbx1.js} +1 -1
- package/dist/{message-fts-rowid-map-ff4qg3e4.js → message-fts-rowid-map-tec2x7qe.js} +4 -4
- package/dist/{message-index-bounded-f0bk44ch.js → message-index-bounded-6zghm1jn.js} +9 -9
- package/dist/{message-time-backfill-x45573rs.js → message-time-backfill-krre2qnb.js} +2 -2
- package/dist/migration-worker.js +9 -9
- package/dist/{project-embedding-registry-ysaezfqw.js → project-embedding-registry-j4ywdpq0.js} +11 -11
- package/dist/raw-ordinal-warmup-worker.js +8 -8
- package/dist/{read-session-chunk-6nt4dzkk.js → read-session-chunk-hs4jtxsm.js} +7 -7
- package/dist/{read-session-raw-nttnwy8p.js → read-session-raw-75dcxtdy.js} +2 -2
- package/dist/{render-yn7fgmg7.js → render-n3y6kvwq.js} +16 -16
- package/dist/{safe-notification-target-jk69jxwp.js → safe-notification-target-8s1xg0q9.js} +2 -2
- package/dist/{search-archive-pcf0za02.js → search-archive-1g44f9jt.js} +9 -9
- package/dist/{search-yvcam5gm.js → search-gzkbjgx0.js} +19 -19
- package/dist/{storage-tags-s0zqj0m0.js → storage-tags-ahhwtfdq.js} +4 -4
- package/dist/subagent-entry.js +25 -25
- package/dist/tag-snapshot-worker-pi.js +11 -11
- package/dist/{v2-archive-reader-accb2tjp.js → v2-archive-reader-sez4pjd8.js} +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -15,7 +15,7 @@ import {
|
|
|
15
15
|
log2,
|
|
16
16
|
sessionLog2,
|
|
17
17
|
flushLogger2
|
|
18
|
-
} from "./index-
|
|
18
|
+
} from "./index-yxeg8zaa.js";
|
|
19
19
|
import {
|
|
20
20
|
sanitizeDiagnosticText,
|
|
21
21
|
hasShareabilitySensitiveText
|
|
@@ -153,7 +153,7 @@ import {
|
|
|
153
153
|
registerTodoStateLifecycle,
|
|
154
154
|
syncCtxMemoryToolEnabled,
|
|
155
155
|
registerMagicContextTools
|
|
156
|
-
} from "./index-
|
|
156
|
+
} from "./index-vdrqxca5.js";
|
|
157
157
|
import"./index-4knyh1kt.js";
|
|
158
158
|
import {
|
|
159
159
|
canonicalModelIdentity,
|
|
@@ -191,7 +191,7 @@ import {
|
|
|
191
191
|
resolveProjectIdentityForSession,
|
|
192
192
|
beginBootQuietPeriod,
|
|
193
193
|
scheduleAfterBootQuiet
|
|
194
|
-
} from "./index-
|
|
194
|
+
} from "./index-xx1911hb.js";
|
|
195
195
|
import {
|
|
196
196
|
detectThinkingBindingMismatch,
|
|
197
197
|
detectLatestTurnThinkingMismatch,
|
|
@@ -356,7 +356,7 @@ import {
|
|
|
356
356
|
getRawSessionTagKeysThrough2,
|
|
357
357
|
getLegacyProtectedTailStartOrdinal2,
|
|
358
358
|
readSessionChunk2
|
|
359
|
-
} from "./index-
|
|
359
|
+
} from "./index-9036v8ay.js";
|
|
360
360
|
import {
|
|
361
361
|
UNKNOWN_FIT_RATIO,
|
|
362
362
|
hasMeasuredDecisionCalibration,
|
|
@@ -445,7 +445,7 @@ import {
|
|
|
445
445
|
getToolTagNumberByOwner2,
|
|
446
446
|
getNullOwnerToolTag2,
|
|
447
447
|
adoptNullOwnerToolTag2
|
|
448
|
-
} from "./index-
|
|
448
|
+
} from "./index-qcsjj9m0.js";
|
|
449
449
|
import {
|
|
450
450
|
textMentionsRecentCommit,
|
|
451
451
|
hasMeaningfulUserText2,
|
|
@@ -457,7 +457,7 @@ import {
|
|
|
457
457
|
estimateTokens,
|
|
458
458
|
estimateFixedPromptTokens,
|
|
459
459
|
normalizeText
|
|
460
|
-
} from "./index-
|
|
460
|
+
} from "./index-7y60kyea.js";
|
|
461
461
|
import {
|
|
462
462
|
inRootAsyncContext2,
|
|
463
463
|
Database2,
|
|
@@ -477,7 +477,7 @@ import {
|
|
|
477
477
|
observeTemporalDecisions,
|
|
478
478
|
freezeTemporalDecisions,
|
|
479
479
|
tagIdentityRevisionKey
|
|
480
|
-
} from "./index-
|
|
480
|
+
} from "./index-jxm4bvm4.js";
|
|
481
481
|
import {
|
|
482
482
|
piHarnessKindFromExecutable,
|
|
483
483
|
getErrorMessage,
|
|
@@ -495,7 +495,7 @@ import {
|
|
|
495
495
|
openCurrentDatabase,
|
|
496
496
|
openDatabaseAsync,
|
|
497
497
|
closeDatabase
|
|
498
|
-
} from "./index-
|
|
498
|
+
} from "./index-y2g8rdmm.js";
|
|
499
499
|
import {
|
|
500
500
|
LkgRecoveryFenceError,
|
|
501
501
|
clearLkgFenceProcessState,
|
|
@@ -612,7 +612,7 @@ import {
|
|
|
612
612
|
getSourceContents,
|
|
613
613
|
recordSubagentInvocation,
|
|
614
614
|
getLatestHistorianInvocationId
|
|
615
|
-
} from "./index-
|
|
615
|
+
} from "./index-9n1hyjck.js";
|
|
616
616
|
import {
|
|
617
617
|
resolveOpenCodeDbPath,
|
|
618
618
|
assertOpenCodeStoreGeneration,
|
|
@@ -630,12 +630,12 @@ import {
|
|
|
630
630
|
} from "./index-x2n261wp.js";
|
|
631
631
|
import {
|
|
632
632
|
RAW_SUMMARY_TEXT_MAX_CHARS2
|
|
633
|
-
} from "./index-
|
|
633
|
+
} from "./index-szn2tac8.js";
|
|
634
634
|
import"./index-nvh6d3bz.js";
|
|
635
635
|
import {
|
|
636
636
|
formatSynapseLaneDescriptor
|
|
637
|
-
} from "./index-
|
|
638
|
-
import"./index-
|
|
637
|
+
} from "./index-qm139qq2.js";
|
|
638
|
+
import"./index-6d0bby9d.js";
|
|
639
639
|
import {
|
|
640
640
|
buildCanonicalChunkTextFromFts2,
|
|
641
641
|
buildCompartmentSummaryFallbackText2,
|
|
@@ -645,7 +645,7 @@ import {
|
|
|
645
645
|
replaceCompartmentChunkEmbeddings2,
|
|
646
646
|
deleteChunkEmbedBackoffForSession2,
|
|
647
647
|
chunkWindowSourceKey2
|
|
648
|
-
} from "./index-
|
|
648
|
+
} from "./index-ndg15t3x.js";
|
|
649
649
|
import {
|
|
650
650
|
recordSessionProjectIdentity,
|
|
651
651
|
GIT_SWEEP_LEASE_RENEWAL_MS,
|
|
@@ -654,7 +654,7 @@ import {
|
|
|
654
654
|
markGitSweepSuccessAndRelease,
|
|
655
655
|
parkGitSweepNonIndexable,
|
|
656
656
|
releaseGitSweepLease
|
|
657
|
-
} from "./index-
|
|
657
|
+
} from "./index-zxm7ckvc.js";
|
|
658
658
|
import {
|
|
659
659
|
embedPauseBySession,
|
|
660
660
|
embedRunStateBySession,
|
|
@@ -670,7 +670,7 @@ import {
|
|
|
670
670
|
clearCompressionDepthRange,
|
|
671
671
|
cleanSearchText,
|
|
672
672
|
matchedSearchSnippet
|
|
673
|
-
} from "./index-
|
|
673
|
+
} from "./index-wz66mger.js";
|
|
674
674
|
import {
|
|
675
675
|
rememberV1HiddenRun
|
|
676
676
|
} from "./index-6x556c2q.js";
|
|
@@ -688,7 +688,7 @@ import {
|
|
|
688
688
|
expandWorkspaceIdentitySetWithAliases,
|
|
689
689
|
sourceNameForMemory,
|
|
690
690
|
computeWorkspaceEpochFingerprint
|
|
691
|
-
} from "./index-
|
|
691
|
+
} from "./index-zc6fdyx7.js";
|
|
692
692
|
import {
|
|
693
693
|
configureContextDatabasePragmas2
|
|
694
694
|
} from "./index-fapenpch.js";
|
|
@@ -713,7 +713,7 @@ import {
|
|
|
713
713
|
createPrimer,
|
|
714
714
|
updatePrimerSupport,
|
|
715
715
|
updatePrimerAnswer
|
|
716
|
-
} from "./index-
|
|
716
|
+
} from "./index-46wk0td0.js";
|
|
717
717
|
import {
|
|
718
718
|
setEmbeddingSessionBusy2,
|
|
719
719
|
isEmbeddingHostBusy2
|
|
@@ -747,7 +747,7 @@ import {
|
|
|
747
747
|
} from "./index-q1yc6bs0.js";
|
|
748
748
|
import {
|
|
749
749
|
getCachedLocalEmbeddingPooling
|
|
750
|
-
} from "./index-
|
|
750
|
+
} from "./index-zrbvwxtb.js";
|
|
751
751
|
import {
|
|
752
752
|
describeShadowBackfillWriteRefusal2,
|
|
753
753
|
contentSha2562,
|
|
@@ -765,10 +765,10 @@ import {
|
|
|
765
765
|
embedSessionCompartmentChunks2,
|
|
766
766
|
getEmbeddingCoverageStatus2,
|
|
767
767
|
getAutoEmbeddingSessionCoverage2
|
|
768
|
-
} from "./index-
|
|
768
|
+
} from "./index-cmyk3bmf.js";
|
|
769
769
|
import {
|
|
770
770
|
cosineSimilarity
|
|
771
|
-
} from "./index-
|
|
771
|
+
} from "./index-yc4vfwvm.js";
|
|
772
772
|
import {
|
|
773
773
|
USER_FACING_FAILURES,
|
|
774
774
|
renderUserFacingFailure,
|
|
@@ -802,8 +802,8 @@ import {
|
|
|
802
802
|
scheduleClearAndReindex,
|
|
803
803
|
clearSessionTracking,
|
|
804
804
|
createAutoSearchDiagnostics
|
|
805
|
-
} from "./index-
|
|
806
|
-
import"./index-
|
|
805
|
+
} from "./index-bjeb4ya4.js";
|
|
806
|
+
import"./index-xssjy4z9.js";
|
|
807
807
|
import {
|
|
808
808
|
DREAMER_PRIMER_INVESTIGATOR_ALLOWED_TOOLS,
|
|
809
809
|
buildHiddenAgentRegistrations,
|
|
@@ -830,11 +830,11 @@ import {
|
|
|
830
830
|
drainPiTagSnapshotSession,
|
|
831
831
|
assertPiTagSnapshotReady,
|
|
832
832
|
ensurePiTagSnapshotReady
|
|
833
|
-
} from "./index-
|
|
834
|
-
import"./index-
|
|
833
|
+
} from "./index-pkg07s54.js";
|
|
834
|
+
import"./index-yjgkjkjs.js";
|
|
835
835
|
import"./index-1cvyaw9a.js";
|
|
836
|
-
import"./index-
|
|
837
|
-
import"./index-
|
|
836
|
+
import"./index-8bpxfq4c.js";
|
|
837
|
+
import"./index-zggajt0j.js";
|
|
838
838
|
import {
|
|
839
839
|
__toESM
|
|
840
840
|
} from "./index-22jkk6wg.js";
|
|
@@ -857,7 +857,7 @@ import {
|
|
|
857
857
|
import {
|
|
858
858
|
logSlowWriteTransaction,
|
|
859
859
|
WriteTransactionSteps
|
|
860
|
-
} from "./index-
|
|
860
|
+
} from "./index-j0eagxkz.js";
|
|
861
861
|
import {
|
|
862
862
|
setStoragePrivatePermissionEnforcement,
|
|
863
863
|
ensureStorageDirectorySync,
|
|
@@ -3589,7 +3589,7 @@ function startHostStallProfilerSwitch() {
|
|
|
3589
3589
|
// package.json
|
|
3590
3590
|
var package_default = {
|
|
3591
3591
|
name: "@cortexkit/pi-magic-context",
|
|
3592
|
-
version: "0.49.
|
|
3592
|
+
version: "0.49.49",
|
|
3593
3593
|
type: "module",
|
|
3594
3594
|
description: "Pi and OMP coding agent extension for Magic Context — cross-session memory and context management",
|
|
3595
3595
|
main: "dist/index.js",
|
|
@@ -12641,6 +12641,7 @@ function writeDocsProposal(projectDir, output, budget, expected, head) {
|
|
|
12641
12641
|
const result = validateDocsProposal(projectDir, output, budget, expected);
|
|
12642
12642
|
const dir = proposalDir(projectDir);
|
|
12643
12643
|
mkdirSync2(join8(dir, "superseded"), { recursive: true });
|
|
12644
|
+
ensureCortexKitArtifactGitignore(projectDir);
|
|
12644
12645
|
const stamp = `${new Date().toISOString().replace(/[:.]/g, "-")}-${Math.random().toString(36).slice(2, 8)}`;
|
|
12645
12646
|
const path = join8(dir, `${stamp}.md`);
|
|
12646
12647
|
const body = `# Docs update proposal
|
|
@@ -25776,10 +25777,6 @@ var NON_EMERGENCY_MAX_CAP = 250000;
|
|
|
25776
25777
|
var FORCE80_MAX_CAP = 500000;
|
|
25777
25778
|
var FORCE95_MAX_CAP = 750000;
|
|
25778
25779
|
var NORMAL_HYSTERESIS_TOKENS = 256;
|
|
25779
|
-
var MIN_FORCE_ELIGIBLE_TOKENS_CAP = 1000;
|
|
25780
|
-
function deriveMinForceEligibleTokens(scaledN) {
|
|
25781
|
-
return Math.min(MIN_FORCE_ELIGIBLE_TOKENS_CAP, Math.max(1, Math.floor(scaledN / 8)));
|
|
25782
|
-
}
|
|
25783
25780
|
function clampPercentage(value) {
|
|
25784
25781
|
if (!Number.isFinite(value))
|
|
25785
25782
|
return 0;
|
|
@@ -26024,6 +26021,7 @@ function resolveProtectedTailBoundary(ctx) {
|
|
|
26024
26021
|
priorBoundaryOrdinal: ctx.priorBoundaryOrdinal,
|
|
26025
26022
|
migrationFloorActive: ctx.migrationFloorActive,
|
|
26026
26023
|
emergencyTailScale: ctx.emergencyTailScale,
|
|
26024
|
+
recovery: ctx.recovery,
|
|
26027
26025
|
providerShapeVersion: ctx.providerShapeVersion,
|
|
26028
26026
|
cacheNamespace: ctx.cacheNamespace,
|
|
26029
26027
|
createdAt,
|
|
@@ -26068,6 +26066,7 @@ function resolveProtectedTailBoundary(ctx) {
|
|
|
26068
26066
|
priorBoundaryOrdinal: ctx.priorBoundaryOrdinal,
|
|
26069
26067
|
migrationFloorActive: false,
|
|
26070
26068
|
emergencyTailScale: ctx.emergencyTailScale,
|
|
26069
|
+
recovery: ctx.recovery,
|
|
26071
26070
|
providerShapeVersion: ctx.providerShapeVersion,
|
|
26072
26071
|
cacheNamespace: ctx.cacheNamespace,
|
|
26073
26072
|
createdAt,
|
|
@@ -26183,6 +26182,7 @@ function resolveProtectedTailBoundary(ctx) {
|
|
|
26183
26182
|
priorBoundaryOrdinal: ctx.priorBoundaryOrdinal,
|
|
26184
26183
|
migrationFloorActive: ctx.migrationFloorActive,
|
|
26185
26184
|
emergencyTailScale: ctx.emergencyTailScale,
|
|
26185
|
+
recovery: ctx.recovery,
|
|
26186
26186
|
liftLivePromptFloor: ctx.liftLivePromptFloor === true ? true : undefined,
|
|
26187
26187
|
providerShapeVersion: ctx.providerShapeVersion,
|
|
26188
26188
|
cacheNamespace: ctx.cacheNamespace,
|
|
@@ -26261,6 +26261,7 @@ function resolveBoundaryContext(args) {
|
|
|
26261
26261
|
protectedTailPolicyVersion: meta.protectedTailPolicyVersion,
|
|
26262
26262
|
migrationFloorActive,
|
|
26263
26263
|
emergencyTailScale: args.emergencyTailScale,
|
|
26264
|
+
recovery: args.recovery,
|
|
26264
26265
|
liftLivePromptFloor: args.liftLivePromptFloor,
|
|
26265
26266
|
providerShapeVersion: args.providerShapeVersion ?? "opencode-v1",
|
|
26266
26267
|
cacheNamespace: args.cacheNamespace ?? `opencode:${args.sessionId}`,
|
|
@@ -26441,9 +26442,11 @@ function hasRunnableCompartmentWindow(snapshot) {
|
|
|
26441
26442
|
return false;
|
|
26442
26443
|
if (snapshot.eligibleEndOrdinal <= snapshot.offset)
|
|
26443
26444
|
return false;
|
|
26445
|
+
if (snapshot.recovery || snapshot.usagePercentage >= 95 || snapshot.mode === "manual-wrapup" || snapshot.mode === "manual-full-recomp")
|
|
26446
|
+
return true;
|
|
26444
26447
|
const forceMaterializationPercentage = escalationBands(snapshot.executeThresholdPercentage).forceMaterializationPercentage;
|
|
26445
26448
|
if (snapshot.usagePercentage >= forceMaterializationPercentage || snapshot.emergencyTailScale) {
|
|
26446
|
-
return snapshot.
|
|
26449
|
+
return snapshot.summaryRemovedEligibleTokens >= snapshot.contextLimit * 0.02;
|
|
26447
26450
|
}
|
|
26448
26451
|
return snapshot.eligibleEndOrdinal > snapshot.offset;
|
|
26449
26452
|
}
|
|
@@ -26856,9 +26859,13 @@ function checkCompartmentTrigger(db, sessionId, sessionMeta, usage, _previousPer
|
|
|
26856
26859
|
}
|
|
26857
26860
|
return { shouldFire: false };
|
|
26858
26861
|
}
|
|
26862
|
+
const recovery = getOverflowState(db, sessionId).needsEmergencyRecovery;
|
|
26863
|
+
if (tailInfo.boundarySnapshot && recovery) {
|
|
26864
|
+
tailInfo.boundarySnapshot = { ...tailInfo.boundarySnapshot, recovery: true };
|
|
26865
|
+
}
|
|
26859
26866
|
if (tailInfo.boundarySnapshot && shouldWaitForNewHistorianHistory(tailInfo.boundarySnapshot, {
|
|
26860
26867
|
usagePercentage: usage.percentage,
|
|
26861
|
-
emergency:
|
|
26868
|
+
emergency: recovery
|
|
26862
26869
|
})) {
|
|
26863
26870
|
sessionLog2(sessionId, "compartment trigger: waiting for new history after no forward progress");
|
|
26864
26871
|
return { shouldFire: false };
|
|
@@ -26900,13 +26907,14 @@ function checkCompartmentTrigger(db, sessionId, sessionMeta, usage, _previousPer
|
|
|
26900
26907
|
executeThresholdPercentage,
|
|
26901
26908
|
usage,
|
|
26902
26909
|
usageSource: "live",
|
|
26903
|
-
emergencyTailScale: scale
|
|
26910
|
+
emergencyTailScale: scale,
|
|
26911
|
+
recovery
|
|
26904
26912
|
});
|
|
26905
26913
|
});
|
|
26906
26914
|
if (hasRunnableCompartmentWindow(scaledBoundary)) {
|
|
26907
26915
|
return { shouldFire: true, reason: "force_band", boundarySnapshot: scaledBoundary };
|
|
26908
26916
|
}
|
|
26909
|
-
sessionLog2(sessionId, "compartment trigger: force_band skipped —
|
|
26917
|
+
sessionLog2(sessionId, "compartment trigger: force_band skipped — no protected head meets summary admission after emergency tail scale");
|
|
26910
26918
|
return { shouldFire: false };
|
|
26911
26919
|
}
|
|
26912
26920
|
const clusterEnabled = commitClusterTrigger?.enabled ?? true;
|
|
@@ -30449,7 +30457,10 @@ async function runPiHistorian(deps) {
|
|
|
30449
30457
|
}) : { ok: true };
|
|
30450
30458
|
if (!validation.ok && validation.reason === "stale_snapshot" && refreshBoundarySnapshot) {
|
|
30451
30459
|
try {
|
|
30452
|
-
const refreshed =
|
|
30460
|
+
const refreshed = {
|
|
30461
|
+
...refreshBoundarySnapshot(boundarySnapshot),
|
|
30462
|
+
recovery: boundarySnapshot.recovery || forceDrainQuota
|
|
30463
|
+
};
|
|
30453
30464
|
if (hasRunnableCompartmentWindow(refreshed)) {
|
|
30454
30465
|
sessionLog2(sessionId, `historian: refreshed stale protected-tail snapshot at run time (was: ${validation.detail ?? "stale"}) — eligible head ${refreshed.offset}-${refreshed.eligibleEndOrdinal - 1}`);
|
|
30455
30466
|
boundarySnapshot = refreshed;
|
|
@@ -48234,6 +48245,7 @@ function maybeFireHistorian(args) {
|
|
|
48234
48245
|
providerShapeVersion: "pi-folded-v1",
|
|
48235
48246
|
cacheNamespace: `pi:${sessionId}`,
|
|
48236
48247
|
emergencyTailScale,
|
|
48248
|
+
recovery: historianStateSnapshot.needsEmergencyRecovery,
|
|
48237
48249
|
liftLivePromptFloor
|
|
48238
48250
|
}));
|
|
48239
48251
|
const resolveRunnablePiBoundarySnapshot = (stale) => {
|
|
@@ -5,13 +5,13 @@ import {
|
|
|
5
5
|
startMessageFtsRowidMapBackfill2,
|
|
6
6
|
messageFtsOrdinalRangeIsMapped2,
|
|
7
7
|
deleteUnmappedMessageFtsRows2
|
|
8
|
-
} from "./index-
|
|
9
|
-
import"./index-
|
|
8
|
+
} from "./index-6d0bby9d.js";
|
|
9
|
+
import"./index-szn2tac8.js";
|
|
10
10
|
import"./index-wfqysrwq.js";
|
|
11
11
|
import"./index-8sqebjzk.js";
|
|
12
|
-
import"./index-
|
|
12
|
+
import"./index-j0eagxkz.js";
|
|
13
13
|
import"./index-2qtx0q6h.js";
|
|
14
|
-
import"./index-
|
|
14
|
+
import"./index-yxeg8zaa.js";
|
|
15
15
|
import"./index-0h2mkab2.js";
|
|
16
16
|
import"./index-dnp1jjar.js";
|
|
17
17
|
import"./index-x2n261wp.js";
|
|
@@ -3,19 +3,19 @@ import {
|
|
|
3
3
|
withIndexChunk2,
|
|
4
4
|
yieldIndexChunk2
|
|
5
5
|
} from "./index-2qtx0q6h.js";
|
|
6
|
-
import"./index-
|
|
7
|
-
import"./index-
|
|
6
|
+
import"./index-qcsjj9m0.js";
|
|
7
|
+
import"./index-7y60kyea.js";
|
|
8
8
|
import"./index-0h2mkab2.js";
|
|
9
|
-
import"./index-
|
|
9
|
+
import"./index-yxeg8zaa.js";
|
|
10
10
|
import"./index-dnp1jjar.js";
|
|
11
|
-
import"./index-
|
|
11
|
+
import"./index-jxm4bvm4.js";
|
|
12
12
|
import"./index-gzk7d940.js";
|
|
13
13
|
import"./index-8sqebjzk.js";
|
|
14
14
|
import"./index-wfqysrwq.js";
|
|
15
15
|
import"./index-x2n261wp.js";
|
|
16
|
-
import"./index-
|
|
16
|
+
import"./index-szn2tac8.js";
|
|
17
17
|
import"./index-n0zjvs3h.js";
|
|
18
|
-
import"./index-
|
|
18
|
+
import"./index-9036v8ay.js";
|
|
19
19
|
import"./index-6x556c2q.js";
|
|
20
20
|
import"./index-c6wbq66z.js";
|
|
21
21
|
import {
|
|
@@ -25,9 +25,9 @@ import {
|
|
|
25
25
|
markMessageIndexDirty,
|
|
26
26
|
getIndexableContent,
|
|
27
27
|
indexSingleMessage
|
|
28
|
-
} from "./index-
|
|
29
|
-
import"./index-
|
|
30
|
-
import"./index-
|
|
28
|
+
} from "./index-wz66mger.js";
|
|
29
|
+
import"./index-6d0bby9d.js";
|
|
30
|
+
import"./index-j0eagxkz.js";
|
|
31
31
|
|
|
32
32
|
// ../plugin/src/features/magic-context/message-index-bounded.ts
|
|
33
33
|
import { createHash } from "node:crypto";
|
|
@@ -3,11 +3,11 @@ import {
|
|
|
3
3
|
withoutSqliteTransformPass2
|
|
4
4
|
} from "./index-2qtx0q6h.js";
|
|
5
5
|
import"./index-0h2mkab2.js";
|
|
6
|
-
import"./index-
|
|
6
|
+
import"./index-yxeg8zaa.js";
|
|
7
7
|
import"./index-dnp1jjar.js";
|
|
8
8
|
import {
|
|
9
9
|
logSlowWriteTransaction
|
|
10
|
-
} from "./index-
|
|
10
|
+
} from "./index-j0eagxkz.js";
|
|
11
11
|
|
|
12
12
|
// ../plugin/src/features/magic-context/message-time-backfill.ts
|
|
13
13
|
var MESSAGE_TIME_BACKFILL_BATCH_SIZE = 500;
|
package/dist/migration-worker.js
CHANGED
|
@@ -2,7 +2,7 @@ import"./index-0h2mkab2.js";
|
|
|
2
2
|
import {
|
|
3
3
|
setLogLineForwarder2,
|
|
4
4
|
log2
|
|
5
|
-
} from "./index-
|
|
5
|
+
} from "./index-yxeg8zaa.js";
|
|
6
6
|
import"./index-dnp1jjar.js";
|
|
7
7
|
import {
|
|
8
8
|
Database2
|
|
@@ -10,27 +10,27 @@ import {
|
|
|
10
10
|
import"./index-135e8hvg.js";
|
|
11
11
|
import {
|
|
12
12
|
runMigrationsWithRetry
|
|
13
|
-
} from "./index-
|
|
14
|
-
import"./index-
|
|
13
|
+
} from "./index-zc6fdyx7.js";
|
|
14
|
+
import"./index-jxm4bvm4.js";
|
|
15
15
|
import"./index-n0zjvs3h.js";
|
|
16
|
-
import"./index-
|
|
16
|
+
import"./index-xx1911hb.js";
|
|
17
17
|
import {
|
|
18
18
|
setSqlitePragmaConfig,
|
|
19
19
|
initializeDatabase
|
|
20
|
-
} from "./index-
|
|
20
|
+
} from "./index-y2g8rdmm.js";
|
|
21
21
|
import"./index-fapenpch.js";
|
|
22
22
|
import"./index-3bb24eb6.js";
|
|
23
23
|
import"./index-8sqebjzk.js";
|
|
24
24
|
import"./index-wfqysrwq.js";
|
|
25
25
|
import"./index-x2n261wp.js";
|
|
26
|
-
import"./index-
|
|
27
|
-
import"./index-
|
|
28
|
-
import"./index-
|
|
26
|
+
import"./index-szn2tac8.js";
|
|
27
|
+
import"./index-6d0bby9d.js";
|
|
28
|
+
import"./index-7y60kyea.js";
|
|
29
29
|
import"./index-c6wbq66z.js";
|
|
30
30
|
import {
|
|
31
31
|
closeQuietly
|
|
32
32
|
} from "./index-nrzkqte4.js";
|
|
33
|
-
import"./index-
|
|
33
|
+
import"./index-j0eagxkz.js";
|
|
34
34
|
import {
|
|
35
35
|
serveWorkerJobs
|
|
36
36
|
} from "./index-nypgv96r.js";
|
package/dist/{project-embedding-registry-ysaezfqw.js → project-embedding-registry-j4ywdpq0.js}
RENAMED
|
@@ -33,24 +33,24 @@ import {
|
|
|
33
33
|
sweepAllRegisteredProjects2,
|
|
34
34
|
_setTestProviderFactoryForProject2,
|
|
35
35
|
_resetProjectEmbeddingRegistryForTests2
|
|
36
|
-
} from "./index-
|
|
36
|
+
} from "./index-cmyk3bmf.js";
|
|
37
37
|
import"./index-9p40dgkm.js";
|
|
38
38
|
import"./index-hgd00nas.js";
|
|
39
39
|
import"./index-yhzhdp3m.js";
|
|
40
|
-
import"./index-
|
|
41
|
-
import"./index-
|
|
42
|
-
import"./index-
|
|
43
|
-
import"./index-
|
|
40
|
+
import"./index-zxm7ckvc.js";
|
|
41
|
+
import"./index-ndg15t3x.js";
|
|
42
|
+
import"./index-zrbvwxtb.js";
|
|
43
|
+
import"./index-qm139qq2.js";
|
|
44
44
|
import"./index-gzk7d940.js";
|
|
45
|
-
import"./index-
|
|
46
|
-
import"./index-
|
|
47
|
-
import"./index-
|
|
45
|
+
import"./index-xx1911hb.js";
|
|
46
|
+
import"./index-6d0bby9d.js";
|
|
47
|
+
import"./index-szn2tac8.js";
|
|
48
48
|
import"./index-wfqysrwq.js";
|
|
49
49
|
import"./index-8sqebjzk.js";
|
|
50
|
-
import"./index-
|
|
51
|
-
import"./index-
|
|
50
|
+
import"./index-j0eagxkz.js";
|
|
51
|
+
import"./index-7y60kyea.js";
|
|
52
52
|
import"./index-2qtx0q6h.js";
|
|
53
|
-
import"./index-
|
|
53
|
+
import"./index-yxeg8zaa.js";
|
|
54
54
|
import"./index-0h2mkab2.js";
|
|
55
55
|
import"./index-dnp1jjar.js";
|
|
56
56
|
import"./index-x2n261wp.js";
|
|
@@ -19,7 +19,7 @@ serveWorkerJobs(async (input, port) => {
|
|
|
19
19
|
await main();
|
|
20
20
|
async function main() {
|
|
21
21
|
if (input.v2ArchiveReader) {
|
|
22
|
-
const { serveV2ArchiveReads } = await import("./v2-archive-reader-
|
|
22
|
+
const { serveV2ArchiveReads } = await import("./v2-archive-reader-sez4pjd8.js");
|
|
23
23
|
await serveV2ArchiveReads(port, openConnections);
|
|
24
24
|
return;
|
|
25
25
|
}
|
|
@@ -30,9 +30,9 @@ serveWorkerJobs(async (input, port) => {
|
|
|
30
30
|
{ log }
|
|
31
31
|
] = await Promise.all([
|
|
32
32
|
import("./sqlite-v89bj0yy.js"),
|
|
33
|
-
import("./read-session-raw-
|
|
33
|
+
import("./read-session-raw-75dcxtdy.js"),
|
|
34
34
|
import("./harness-9872e0ym.js"),
|
|
35
|
-
import("./logger-
|
|
35
|
+
import("./logger-hhgpkbx1.js")
|
|
36
36
|
]);
|
|
37
37
|
setHarness(input.harness ?? "opencode");
|
|
38
38
|
registerSqliteDiagnosticSink(log, getHarness);
|
|
@@ -46,13 +46,13 @@ serveWorkerJobs(async (input, port) => {
|
|
|
46
46
|
openConnections.add(db);
|
|
47
47
|
db.exec("PRAGMA busy_timeout = 250");
|
|
48
48
|
if (input.ftsRowidBackfill) {
|
|
49
|
-
const { runMessageFtsRowidMapBackfill } = await import("./message-fts-rowid-map-
|
|
49
|
+
const { runMessageFtsRowidMapBackfill } = await import("./message-fts-rowid-map-tec2x7qe.js");
|
|
50
50
|
db.exec("PRAGMA busy_timeout = 0");
|
|
51
51
|
await runMessageFtsRowidMapBackfill(db);
|
|
52
52
|
reply = { kind: "fts-rowid-backfill" };
|
|
53
53
|
} else if (input.searchArchive) {
|
|
54
|
-
const { renderSearchArchive } = await import("./search-archive-
|
|
55
|
-
const { readRawSessionMessageIdOrdinalsForRangeFromDb } = await import("./read-session-raw-
|
|
54
|
+
const { renderSearchArchive } = await import("./search-archive-1g44f9jt.js");
|
|
55
|
+
const { readRawSessionMessageIdOrdinalsForRangeFromDb } = await import("./read-session-raw-75dcxtdy.js");
|
|
56
56
|
const archive = input.searchArchive;
|
|
57
57
|
let raw;
|
|
58
58
|
try {
|
|
@@ -81,7 +81,7 @@ serveWorkerJobs(async (input, port) => {
|
|
|
81
81
|
const { setHarness } = await import("./harness-9872e0ym.js");
|
|
82
82
|
setHarness(input.harness ?? "opencode");
|
|
83
83
|
const [{ indexMessageInShortChunks }, { configureContextDatabasePragmas }] = await Promise.all([
|
|
84
|
-
import("./message-index-bounded-
|
|
84
|
+
import("./message-index-bounded-6zghm1jn.js"),
|
|
85
85
|
import("./sqlite-context-pragmas-gcgch6qz.js")
|
|
86
86
|
]);
|
|
87
87
|
configureContextDatabasePragmas(db);
|
|
@@ -95,7 +95,7 @@ serveWorkerJobs(async (input, port) => {
|
|
|
95
95
|
measurements: result.measurements
|
|
96
96
|
};
|
|
97
97
|
} else if (input.tagRatio !== undefined) {
|
|
98
|
-
const { scanTagOwnerSummary, scanTagOwnerDelta } = await import("./storage-tags-
|
|
98
|
+
const { scanTagOwnerSummary, scanTagOwnerDelta } = await import("./storage-tags-ahhwtfdq.js");
|
|
99
99
|
const delta = input.tagState ? scanTagOwnerDelta(db, input.sessionId, input.tagState) : null;
|
|
100
100
|
if (delta)
|
|
101
101
|
reply = { kind: "tag-delta", delta };
|
|
@@ -38,23 +38,23 @@ import {
|
|
|
38
38
|
readSessionChunk2,
|
|
39
39
|
getRawSessionMessageIdsThrough2,
|
|
40
40
|
readRawSessionSeedTail2
|
|
41
|
-
} from "./index-
|
|
42
|
-
import"./index-
|
|
41
|
+
} from "./index-9036v8ay.js";
|
|
42
|
+
import"./index-qcsjj9m0.js";
|
|
43
43
|
import"./index-6x556c2q.js";
|
|
44
44
|
import"./index-gzk7d940.js";
|
|
45
45
|
import"./index-c6wbq66z.js";
|
|
46
|
-
import"./index-
|
|
47
|
-
import"./index-
|
|
46
|
+
import"./index-jxm4bvm4.js";
|
|
47
|
+
import"./index-szn2tac8.js";
|
|
48
48
|
import"./index-wfqysrwq.js";
|
|
49
49
|
import"./index-8sqebjzk.js";
|
|
50
50
|
import"./index-n0zjvs3h.js";
|
|
51
|
-
import"./index-
|
|
51
|
+
import"./index-j0eagxkz.js";
|
|
52
52
|
import {
|
|
53
53
|
hasMeaningfulUserText2,
|
|
54
54
|
extractTexts2
|
|
55
|
-
} from "./index-
|
|
55
|
+
} from "./index-7y60kyea.js";
|
|
56
56
|
import"./index-2qtx0q6h.js";
|
|
57
|
-
import"./index-
|
|
57
|
+
import"./index-yxeg8zaa.js";
|
|
58
58
|
import"./index-0h2mkab2.js";
|
|
59
59
|
import"./index-dnp1jjar.js";
|
|
60
60
|
import"./index-x2n261wp.js";
|
|
@@ -28,11 +28,11 @@ import {
|
|
|
28
28
|
hasRawSessionMessageByIdFromDb2,
|
|
29
29
|
readRawSeedTailFromDb2,
|
|
30
30
|
readRawSessionBoundaryEndpointsFromDb2
|
|
31
|
-
} from "./index-
|
|
31
|
+
} from "./index-szn2tac8.js";
|
|
32
32
|
import"./index-wfqysrwq.js";
|
|
33
33
|
import"./index-8sqebjzk.js";
|
|
34
34
|
import"./index-2qtx0q6h.js";
|
|
35
|
-
import"./index-
|
|
35
|
+
import"./index-yxeg8zaa.js";
|
|
36
36
|
import"./index-0h2mkab2.js";
|
|
37
37
|
import"./index-dnp1jjar.js";
|
|
38
38
|
import"./index-x2n261wp.js";
|
|
@@ -3,34 +3,34 @@ import {
|
|
|
3
3
|
renderVerboseRange2,
|
|
4
4
|
renderVerboseRangeForTool2,
|
|
5
5
|
renderItemByTag2
|
|
6
|
-
} from "./index-
|
|
7
|
-
import"./index-
|
|
8
|
-
import"./index-
|
|
6
|
+
} from "./index-9n1hyjck.js";
|
|
7
|
+
import"./index-46wk0td0.js";
|
|
8
|
+
import"./index-wz66mger.js";
|
|
9
9
|
import"./index-hgd00nas.js";
|
|
10
10
|
import"./index-nvh6d3bz.js";
|
|
11
|
-
import"./index-
|
|
12
|
-
import"./index-
|
|
13
|
-
import"./index-
|
|
11
|
+
import"./index-ndg15t3x.js";
|
|
12
|
+
import"./index-9036v8ay.js";
|
|
13
|
+
import"./index-qcsjj9m0.js";
|
|
14
14
|
import"./index-6x556c2q.js";
|
|
15
|
-
import"./index-
|
|
15
|
+
import"./index-qm139qq2.js";
|
|
16
16
|
import"./index-gzk7d940.js";
|
|
17
|
-
import"./index-
|
|
17
|
+
import"./index-y2g8rdmm.js";
|
|
18
18
|
import"./index-fapenpch.js";
|
|
19
|
-
import"./index-
|
|
19
|
+
import"./index-zc6fdyx7.js";
|
|
20
20
|
import"./index-135e8hvg.js";
|
|
21
|
-
import"./index-
|
|
22
|
-
import"./index-
|
|
21
|
+
import"./index-xx1911hb.js";
|
|
22
|
+
import"./index-6d0bby9d.js";
|
|
23
23
|
import"./index-3bb24eb6.js";
|
|
24
24
|
import"./index-c6wbq66z.js";
|
|
25
|
-
import"./index-
|
|
26
|
-
import"./index-
|
|
25
|
+
import"./index-jxm4bvm4.js";
|
|
26
|
+
import"./index-szn2tac8.js";
|
|
27
27
|
import"./index-wfqysrwq.js";
|
|
28
28
|
import"./index-8sqebjzk.js";
|
|
29
29
|
import"./index-n0zjvs3h.js";
|
|
30
|
-
import"./index-
|
|
31
|
-
import"./index-
|
|
30
|
+
import"./index-j0eagxkz.js";
|
|
31
|
+
import"./index-7y60kyea.js";
|
|
32
32
|
import"./index-2qtx0q6h.js";
|
|
33
|
-
import"./index-
|
|
33
|
+
import"./index-yxeg8zaa.js";
|
|
34
34
|
import"./index-0h2mkab2.js";
|
|
35
35
|
import"./index-dnp1jjar.js";
|
|
36
36
|
import"./index-x2n261wp.js";
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import {
|
|
2
2
|
isDefaultSessionTitle2,
|
|
3
3
|
waitForSafeNotificationTarget2
|
|
4
|
-
} from "./index-
|
|
5
|
-
import"./index-
|
|
4
|
+
} from "./index-yjgkjkjs.js";
|
|
5
|
+
import"./index-yxeg8zaa.js";
|
|
6
6
|
import"./index-0h2mkab2.js";
|
|
7
7
|
import"./index-dnp1jjar.js";
|
|
8
8
|
export {
|