@cortexkit/opencode-magic-context 0.49.95 → 0.49.97
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/{announcement-4ynkaf0d.js → announcement-8nj2jd87.js} +5 -5
- package/dist/auto-search-worker.js +5 -5
- package/dist/chunk-embedding-write-worker.js +16 -16
- package/dist/{compaction-marker-candidates-1ndjqh9k.js → compaction-marker-candidates-a4b0anvv.js} +3 -3
- package/dist/compaction-marker-candidates-worker.js +1 -1
- package/dist/{compartment-chunk-embedding-4nn3hsw2.js → compartment-chunk-embedding-re2cw7y3.js} +8 -8
- package/dist/config/removed-agent-config.d.ts +1 -1
- package/dist/config/removed-agent-config.d.ts.map +1 -1
- package/dist/config/schema/magic-context.d.ts +0 -75
- package/dist/config/schema/magic-context.d.ts.map +1 -1
- package/dist/{conflict-warning-hook-exf96bpt.js → conflict-warning-hook-wcq55y61.js} +8 -8
- package/dist/{context-h9x9m2p3.js → context-br04s0b6.js} +86 -104
- package/dist/{derive-budgets-hzzq71rm.js → derive-budgets-g1sy72e8.js} +5 -5
- package/dist/embedding-backfill-pdymqbnh.js +29 -0
- package/dist/embedding-worker-process.js +2 -2
- package/dist/embedding-worker.js +8 -8
- package/dist/features/magic-context/dreamer/token-budget.d.ts +2 -2
- package/dist/features/magic-context/dreamer/token-budget.d.ts.map +1 -1
- package/dist/features/magic-context/search-rerank.d.ts +2 -2
- package/dist/features/magic-context/search-rerank.d.ts.map +1 -1
- package/dist/features/magic-context/search.d.ts.map +1 -1
- package/dist/features/magic-context/storage-native-replay.d.ts +7 -0
- package/dist/features/magic-context/storage-native-replay.d.ts.map +1 -1
- package/dist/{history-owner-xqfsvf9k.js → history-owner-74826t4n.js} +3 -3
- package/dist/hooks/magic-context/apply-operations.d.ts.map +1 -1
- package/dist/hooks/magic-context/hook.d.ts.map +1 -1
- package/dist/hooks/magic-context/inject-compartments.d.ts +6 -1
- package/dist/hooks/magic-context/inject-compartments.d.ts.map +1 -1
- package/dist/hooks/magic-context/tag-messages.d.ts +11 -1
- package/dist/hooks/magic-context/tag-messages.d.ts.map +1 -1
- package/dist/hooks/magic-context/transform-compartment-phase.d.ts +2 -1
- package/dist/hooks/magic-context/transform-compartment-phase.d.ts.map +1 -1
- package/dist/hooks/magic-context/transform-postprocess-phase.d.ts +1 -0
- package/dist/hooks/magic-context/transform-postprocess-phase.d.ts.map +1 -1
- package/dist/hooks/magic-context/transform.d.ts +2 -0
- package/dist/hooks/magic-context/transform.d.ts.map +1 -1
- package/dist/{index-3ywyr4zx.js → index-0bjj9yf3.js} +2 -2
- package/dist/{index-7skgrbsg.js → index-0sqhg9nf.js} +41 -21
- package/dist/{index-nxxzeq4y.js → index-0ve29s6f.js} +1 -1
- package/dist/{index-ywrz4wy2.js → index-3fhb0j32.js} +1 -1
- package/dist/{index-gqf8r04r.js → index-3n4j5rqc.js} +1 -1
- package/dist/{index-xsqw8kbd.js → index-45qgkg8j.js} +2 -2
- package/dist/{index-5df2fw5b.js → index-6mryx739.js} +1 -1
- package/dist/{index-tedck05r.js → index-7m2tnk8q.js} +10 -10
- package/dist/{index-r4y0dczp.js → index-7sdns2ww.js} +2 -2
- package/dist/{index-mjy2k9jr.js → index-880a24vd.js} +1 -1
- package/dist/{index-esacb9d0.js → index-89bkkgcn.js} +4 -4
- package/dist/{index-s32f8y67.js → index-89xg64wb.js} +2 -2
- package/dist/{index-pc49a7zt.js → index-8v1brm5n.js} +13 -11
- package/dist/{index-qmm8xpbc.js → index-910gahfb.js} +6 -6
- package/dist/{index-47hst5me.js → index-9jvxq5rt.js} +4 -4
- package/dist/{index-832w615x.js → index-azkfw78y.js} +1 -1
- package/dist/{index-wh9fxds5.js → index-c205x7xd.js} +1 -1
- package/dist/{index-mg9s2rc3.js → index-cpbr0xvk.js} +2 -2
- package/dist/{index-cr483vx6.js → index-dj64gzg5.js} +2 -2
- package/dist/{index-jba6ny4m.js → index-dnpcv1rg.js} +4 -4
- package/dist/{index-z4p0ry94.js → index-dt7cyqfe.js} +2 -1
- package/dist/{index-tm799pq7.js → index-e6ay1gez.js} +1 -1
- package/dist/{index-j7n64sg4.js → index-fgw241hh.js} +2 -2
- package/dist/{index-yzzxb5e1.js → index-h7kta6cn.js} +3 -3
- package/dist/{index-q7q6qp1f.js → index-hedgz8an.js} +1 -1
- package/dist/{index-5pgyqgmx.js → index-hj78hvhm.js} +2 -2
- package/dist/{index-7r11k4xr.js → index-hp46xe93.js} +7 -7
- package/dist/{index-ejgp0z9p.js → index-j4dcjb8t.js} +4 -4
- package/dist/{index-e6ncz7a6.js → index-jzrvdqb8.js} +1 -1
- package/dist/{index-sp5pvs95.js → index-k34hc455.js} +2 -2
- package/dist/{index-9ffntwyr.js → index-kj4bprep.js} +4 -4
- package/dist/{index-xe34pwb6.js → index-mgy7g740.js} +1 -1
- package/dist/{index-2v9qpmb3.js → index-mmf6e740.js} +7 -7
- package/dist/{index-3tmbvn0z.js → index-pkxkeezb.js} +27 -19
- package/dist/{index-jm62g83a.js → index-qdjxrbnr.js} +71 -44
- package/dist/{index-xjaf9g90.js → index-r1d45dsr.js} +4 -4
- package/dist/{index-y915t3ey.js → index-r3f85n7y.js} +5 -1
- package/dist/{index-wqwjawer.js → index-tbdy1hk0.js} +6 -6
- package/dist/{index-m0pwswv9.js → index-tqtpgnhr.js} +1 -1
- package/dist/{index-zk6gtf43.js → index-w7n7qkpf.js} +5 -5
- package/dist/{index-ewta5h87.js → index-w9hxgntq.js} +5 -5
- package/dist/{index-2gewejcz.js → index-x49x59ar.js} +145 -32
- package/dist/{index-7dzaamqg.js → index-xcej5kpt.js} +4 -4
- package/dist/{index-s7460efs.js → index-zfx7mtqa.js} +1 -1
- package/dist/{index-c81tggen.js → index-zkjx8gq3.js} +11 -11
- package/dist/{index-et39x9k3.js → index-zmgp0tr6.js} +3 -3
- package/dist/index.js +58 -55
- package/dist/{logger-d7c8akh9.js → logger-nmb2508f.js} +2 -2
- package/dist/{message-fts-rowid-map-0xx8ge09.js → message-fts-rowid-map-vcatdan0.js} +5 -5
- package/dist/{message-index-bounded-d3x8rhpz.js → message-index-bounded-abhwe610.js} +12 -12
- package/dist/{message-time-backfill-pz5981mf.js → message-time-backfill-zc5rsvhv.js} +3 -3
- package/dist/migration-worker.js +13 -13
- package/dist/plugin/hooks/create-session-hooks.d.ts.map +1 -1
- package/dist/{project-embedding-registry-az68q792.js → project-embedding-registry-e566q4bg.js} +15 -15
- package/dist/raw-ordinal-warmup-worker.js +8 -8
- package/dist/{read-session-chunk-70r1snq3.js → read-session-chunk-sde0wym3.js} +10 -10
- package/dist/{read-session-raw-3sc9231y.js → read-session-raw-trhdgc9z.js} +3 -3
- package/dist/{recomp-orchestrator-cn4r2gz6.js → recomp-orchestrator-dapm3e4v.js} +33 -33
- package/dist/render-6vmqzcem.js +43 -0
- package/dist/{safe-notification-target-d21swr3n.js → safe-notification-target-54ns7dv9.js} +3 -3
- package/dist/{search-b0cb342r.js → search-11aw8wpq.js} +27 -27
- package/dist/{search-archive-s9t3exc1.js → search-archive-4bbn3ztv.js} +13 -13
- package/dist/{send-session-notification-0779tyd9.js → send-session-notification-gxrj4w1r.js} +6 -6
- package/dist/shared/host-sqlite-runtime.d.ts +3 -0
- package/dist/shared/host-sqlite-runtime.d.ts.map +1 -0
- package/dist/shared/redaction.d.ts.map +1 -1
- package/dist/shared/transcript.d.ts +14 -0
- package/dist/shared/transcript.d.ts.map +1 -1
- package/dist/{storage-tags-xvbje7jm.js → storage-tags-jq0c0zsn.js} +7 -7
- package/dist/{store-91kawq9a.js → store-29ksp6vy.js} +3 -3
- package/dist/{transform-postprocess-phase-r1xhsjrh.js → transform-postprocess-phase-1xrjg6be.js} +34 -34
- package/dist/v2/auto-search-worker.js +5 -5
- package/dist/v2/chunk-embedding-write-worker.js +16 -16
- package/dist/v2/{compaction-marker-candidates-bp1bn579.js → compaction-marker-candidates-6nypmsr3.js} +3 -3
- package/dist/v2/compaction-marker-candidates-worker.js +1 -1
- package/dist/v2/{compartment-chunk-embedding-a7ddvz7v.js → compartment-chunk-embedding-jthtfhcd.js} +8 -8
- package/dist/v2/{context-2hssw26q.js → context-43r0mzkp.js} +127 -111
- package/dist/v2/{derive-budgets-hr4qqrnv.js → derive-budgets-wj0q7s7d.js} +6 -6
- package/dist/v2/embedding-backfill-16b16m38.js +29 -0
- package/dist/v2/embedding-worker-process.js +2 -2
- package/dist/v2/embedding-worker.js +8 -8
- package/dist/v2/fold/native-replay.d.ts +2 -1
- package/dist/v2/fold/native-replay.d.ts.map +1 -1
- package/dist/v2/hidden-child-native.d.ts.map +1 -1
- package/dist/v2/hidden-child-record.d.ts +8 -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/hidden-run-holder.d.ts +8 -2
- package/dist/v2/hidden-run-holder.d.ts.map +1 -1
- package/dist/v2/{history-owner-260djmv5.js → history-owner-8pd5ax3n.js} +3 -3
- package/dist/v2/hooks/context.d.ts.map +1 -1
- package/dist/v2/hooks/hidden-child.d.ts +3 -0
- package/dist/v2/hooks/hidden-child.d.ts.map +1 -1
- package/dist/v2/{logger-zyf43np1.js → logger-58jfese9.js} +2 -2
- package/dist/v2/{message-fts-rowid-map-n8mcvcpz.js → message-fts-rowid-map-ax4vk78j.js} +5 -5
- package/dist/v2/{message-index-bounded-tbwrff24.js → message-index-bounded-qh794qxx.js} +12 -12
- package/dist/v2/{message-time-backfill-ynb3vg6r.js → message-time-backfill-yj773saf.js} +3 -3
- package/dist/v2/migration-worker.js +13 -13
- package/dist/v2/{project-embedding-registry-2zeycxek.js → project-embedding-registry-z05xvckg.js} +15 -15
- package/dist/v2/raw-ordinal-warmup-worker.js +8 -8
- package/dist/v2/{read-session-chunk-cvgsfsgr.js → read-session-chunk-8tn2dbn1.js} +10 -10
- package/dist/v2/{read-session-raw-wg5zc29f.js → read-session-raw-ywebck9q.js} +3 -3
- package/dist/v2/recomp-orchestrator-vzygyqwn.js +69 -0
- package/dist/v2/render-9b5dxp9e.js +43 -0
- package/dist/v2/{safe-notification-target-y55z2zat.js → safe-notification-target-zrwbh6k7.js} +3 -3
- package/dist/v2/{search-x1cac8t6.js → search-35cz80x0.js} +26 -26
- package/dist/v2/{search-archive-k2yh0jj3.js → search-archive-8zqsf9e6.js} +13 -13
- package/dist/v2/{send-session-notification-v69y04f5.js → send-session-notification-8x146x5y.js} +6 -6
- package/dist/v2/{server-gj259dqy.js → server-11ra1pmx.js} +5 -5
- package/dist/v2/{server-6nh36020.js → server-1fnsfm3a.js} +132 -33
- package/dist/v2/{server-gs2251jr.js → server-2cq3e1c1.js} +4 -4
- package/dist/v2/{server-39bcszk4.js → server-2qvnr3t7.js} +1 -1
- package/dist/v2/{server-jkj1dq6j.js → server-2sare4qg.js} +4 -4
- package/dist/v2/{server-jdfe07mp.js → server-2wz6y46g.js} +1 -1
- package/dist/v2/{server-at0v0z4t.js → server-379fd3n7.js} +1 -1
- package/dist/v2/{server-ds8vpfkr.js → server-40vdz8sf.js} +2 -2
- package/dist/v2/{server-qntmqaca.js → server-4yrvbnnm.js} +2 -2
- package/dist/v2/{server-x69fqsvz.js → server-5t4nzfpt.js} +1 -1
- package/dist/v2/{server-npdey91q.js → server-63ree5ns.js} +1 -1
- package/dist/v2/{server-gqkdfdvw.js → server-6qax5pds.js} +2 -2
- package/dist/v2/{server-qb3s0mnc.js → server-73bqw5c0.js} +1 -1
- package/dist/v2/{server-qy58c11s.js → server-7h4gwphm.js} +4 -4
- package/dist/v2/{server-476anw1w.js → server-7tj8yzrv.js} +1 -1
- package/dist/v2/{server-e6xneh68.js → server-arfzfxe8.js} +5 -1
- package/dist/v2/{server-6ash6z8z.js → server-av3p9c8k.js} +1 -1
- package/dist/v2/{server-5hwf5c7r.js → server-bx5k66qc.js} +1 -1
- package/dist/v2/{server-s81b3nct.js → server-db91dxwc.js} +7 -7
- package/dist/v2/{server-z4p0ry94.js → server-dt7cyqfe.js} +2 -1
- package/dist/v2/{server-zc8s06gx.js → server-ganavh75.js} +2 -2
- package/dist/v2/{server-cvm1qrqc.js → server-gh2w75fn.js} +3 -3
- package/dist/v2/{server-y0pd600x.js → server-j1gxs1gj.js} +1 -1
- package/dist/v2/{server-xepfjgv5.js → server-k3ntgf6n.js} +2 -2
- package/dist/v2/{server-j8376q08.js → server-kzrrdjp5.js} +1 -1
- package/dist/v2/{server-1rrmxhd1.js → server-n33hyq9t.js} +2 -2
- package/dist/v2/{server-0tv6kytx.js → server-n34vzyfm.js} +1 -1
- package/dist/v2/{server-prrx17q3.js → server-nnh81jqy.js} +6 -6
- package/dist/v2/{server-cd93xyyx.js → server-qjjky07w.js} +13 -11
- package/dist/v2/{server-vbr1rdkg.js → server-r3h4fy4k.js} +4 -4
- package/dist/v2/{server-96nm9vk4.js → server-rr5c0xcg.js} +2 -2
- package/dist/v2/{server-j4jjtdc5.js → server-rt8t6s2a.js} +2 -2
- package/dist/v2/{server-srtq37nh.js → server-svccj9rd.js} +4 -4
- package/dist/v2/{server-5sbsnpkn.js → server-tq523gj6.js} +1 -1
- package/dist/v2/{server-00adcfjd.js → server-vj0xbbrc.js} +17 -3
- package/dist/v2/{server-88pjnecb.js → server-vsx9tsks.js} +11 -11
- package/dist/v2/{server-s8mk882p.js → server-xekyjy4w.js} +6 -6
- package/dist/v2/{server-bfct1yvb.js → server-z2nv8jdv.js} +41 -21
- package/dist/v2/{server-6aj72z52.js → server-z5cv5wm5.js} +10 -10
- package/dist/v2/{server-5016ccyn.js → server-zemnpv92.js} +4 -4
- package/dist/v2/server.js +9 -9
- package/dist/v2/{storage-tags-y20j3jdp.js → storage-tags-pcenytad.js} +7 -7
- package/dist/v2/{store-b95snz31.js → store-gx19qc3a.js} +3 -3
- package/dist/v2/{v2-archive-reader-q92kwkr5.js → v2-archive-reader-hvdyz30c.js} +1 -1
- package/dist/v2/{wrapup-orchestrator-ydqkxkhj.js → wrapup-orchestrator-0d4ceff3.js} +34 -34
- package/dist/{v2-archive-reader-x62hsr4c.js → v2-archive-reader-qs24chs6.js} +1 -1
- package/dist/wrapup-orchestrator-v1mhjw55.js +56 -0
- package/package.json +1 -1
- package/src/config/index.test.ts +23 -5
- package/src/config/live-run-config.test.ts +7 -7
- package/src/config/removed-agent-config.ts +14 -1
- package/src/config/schema/magic-context.ts +5 -1
- package/src/shared/host-sqlite-runtime.test.ts +21 -0
- package/src/shared/host-sqlite-runtime.ts +32 -0
- package/src/shared/redaction.test.ts +11 -8
- package/src/shared/redaction.ts +5 -1
- package/src/shared/tag-transcript.ts +61 -10
- package/src/shared/transcript.ts +16 -0
- package/dist/embedding-backfill-wdrqkw09.js +0 -29
- package/dist/render-g45k3gts.js +0 -43
- package/dist/v2/embedding-backfill-gveter8p.js +0 -29
- package/dist/v2/recomp-orchestrator-k4cj62f2.js +0 -69
- package/dist/v2/render-ys7a3zks.js +0 -43
- package/dist/wrapup-orchestrator-kt81d6et.js +0 -56
|
@@ -6,10 +6,10 @@ import {
|
|
|
6
6
|
getMagicContextHistorianSessionDir,
|
|
7
7
|
log2,
|
|
8
8
|
sessionLog2
|
|
9
|
-
} from "./server-
|
|
9
|
+
} from "./server-kzrrdjp5.js";
|
|
10
10
|
import {
|
|
11
11
|
sanitizeDiagnosticText
|
|
12
|
-
} from "./server-
|
|
12
|
+
} from "./server-dt7cyqfe.js";
|
|
13
13
|
import {
|
|
14
14
|
parseTree,
|
|
15
15
|
parseJsoncRecovering,
|
|
@@ -19,20 +19,20 @@ import {
|
|
|
19
19
|
cortexKitProjectConfigBasePath,
|
|
20
20
|
resolveLegacyConfigSourcesForHarness,
|
|
21
21
|
loadPluginConfigDetailed
|
|
22
|
-
} from "./server-
|
|
22
|
+
} from "./server-vj0xbbrc.js";
|
|
23
23
|
import {
|
|
24
24
|
catalogOutputReserve,
|
|
25
25
|
getSdkContextLimit,
|
|
26
26
|
modelSupportsVision,
|
|
27
27
|
getSdkOutputLimit
|
|
28
|
-
} from "./server-
|
|
28
|
+
} from "./server-rr5c0xcg.js";
|
|
29
29
|
import {
|
|
30
30
|
withContentLanguageDirective,
|
|
31
31
|
buildPrimaryLanguageDirective,
|
|
32
32
|
resolvePromptSurface,
|
|
33
33
|
DEFAULT_HISTORIAN_TIMEOUT_MS,
|
|
34
34
|
LIVE_RELOAD_CONFIG_PATHS
|
|
35
|
-
} from "./server-
|
|
35
|
+
} from "./server-arfzfxe8.js";
|
|
36
36
|
import {
|
|
37
37
|
inRootAsyncContext2,
|
|
38
38
|
Database2,
|
|
@@ -47,7 +47,7 @@ import {
|
|
|
47
47
|
RawOrdinalsNotReady2,
|
|
48
48
|
dropRawSessionOrdinalCheckpoints2,
|
|
49
49
|
runSessionWarmupWorker
|
|
50
|
-
} from "./server-
|
|
50
|
+
} from "./server-av3p9c8k.js";
|
|
51
51
|
import {
|
|
52
52
|
CACHED_TRIM_PARTIAL_SQL,
|
|
53
53
|
ensureSessionMetaRow,
|
|
@@ -97,7 +97,7 @@ import {
|
|
|
97
97
|
foldShrunkPartTags2,
|
|
98
98
|
getTagNumberByMessageId2,
|
|
99
99
|
getActiveTagsBySession2
|
|
100
|
-
} from "./server-
|
|
100
|
+
} from "./server-11ra1pmx.js";
|
|
101
101
|
import {
|
|
102
102
|
COMPARTMENT_LEASE_RENEWAL_MS,
|
|
103
103
|
getCompartmentLeaseBlocker,
|
|
@@ -147,7 +147,7 @@ import {
|
|
|
147
147
|
getProjectState,
|
|
148
148
|
recordSubagentInvocation,
|
|
149
149
|
getLatestHistorianInvocationId
|
|
150
|
-
} from "./server-
|
|
150
|
+
} from "./server-qjjky07w.js";
|
|
151
151
|
import {
|
|
152
152
|
providerMass,
|
|
153
153
|
calibrationForModelKey,
|
|
@@ -156,11 +156,12 @@ import {
|
|
|
156
156
|
import {
|
|
157
157
|
hasMeaningfulUserText2,
|
|
158
158
|
estimateTokens,
|
|
159
|
+
createTokenCountMemo,
|
|
159
160
|
estimateFixedPromptTokens
|
|
160
|
-
} from "./server-
|
|
161
|
+
} from "./server-73bqw5c0.js";
|
|
161
162
|
import {
|
|
162
163
|
BoundedSessionMap
|
|
163
|
-
} from "./server-
|
|
164
|
+
} from "./server-4yrvbnnm.js";
|
|
164
165
|
import {
|
|
165
166
|
resolveOpenCodeDbPath,
|
|
166
167
|
assertOpenCodeStoreGeneration,
|
|
@@ -171,7 +172,7 @@ import {
|
|
|
171
172
|
openCodeDbExists,
|
|
172
173
|
withReadOnlySessionDb,
|
|
173
174
|
getMessageTimesFromOpenCodeDb
|
|
174
|
-
} from "./server-
|
|
175
|
+
} from "./server-bx5k66qc.js";
|
|
175
176
|
import {
|
|
176
177
|
removeUnsupportedCommitHashes,
|
|
177
178
|
completedToolArcCrossesBoundary,
|
|
@@ -207,14 +208,14 @@ import {
|
|
|
207
208
|
getRawSessionTagKeysThrough2,
|
|
208
209
|
getLegacyProtectedTailStartOrdinal2,
|
|
209
210
|
readSessionChunk2
|
|
210
|
-
} from "./server-
|
|
211
|
+
} from "./server-db91dxwc.js";
|
|
211
212
|
import {
|
|
212
213
|
clearCompressionDepth,
|
|
213
214
|
clearCompressionDepthRange,
|
|
214
215
|
toMessageIndexSource,
|
|
215
216
|
clearIndexedMessagesInTransaction,
|
|
216
217
|
indexSourcesAfterOrdinal
|
|
217
|
-
} from "./server-
|
|
218
|
+
} from "./server-svccj9rd.js";
|
|
218
219
|
import {
|
|
219
220
|
invalidateAutoEmbedSession
|
|
220
221
|
} from "./server-2amn2s73.js";
|
|
@@ -227,7 +228,7 @@ import {
|
|
|
227
228
|
replaceCompartmentChunkEmbeddings2,
|
|
228
229
|
deleteChunkEmbedBackoffForSession2,
|
|
229
230
|
chunkWindowSourceKey2
|
|
230
|
-
} from "./server-
|
|
231
|
+
} from "./server-zemnpv92.js";
|
|
231
232
|
import {
|
|
232
233
|
isMarkerCandidateBasisCurrent2,
|
|
233
234
|
invalidateMarkerCandidateBasis2,
|
|
@@ -238,18 +239,18 @@ import {
|
|
|
238
239
|
certifiedMarkerReferenceFloor2,
|
|
239
240
|
readMarkerReferenceRows2,
|
|
240
241
|
readKnownMarkerReferenceRows2
|
|
241
|
-
} from "./server-
|
|
242
|
+
} from "./server-379fd3n7.js";
|
|
242
243
|
import {
|
|
243
244
|
shouldSkipHomeProjectMemory,
|
|
244
245
|
resolveProjectIdentity
|
|
245
|
-
} from "./server-
|
|
246
|
+
} from "./server-n33hyq9t.js";
|
|
246
247
|
import {
|
|
247
248
|
contentSha2562,
|
|
248
249
|
enqueueShadowEmbeddingItems2,
|
|
249
250
|
getProjectChunkEmbeddingModelId2,
|
|
250
251
|
getProjectEmbeddingMaxInputTokens2,
|
|
251
252
|
embedItemsWindowBounded2
|
|
252
|
-
} from "./server-
|
|
253
|
+
} from "./server-z5cv5wm5.js";
|
|
253
254
|
import {
|
|
254
255
|
V2_MEMORY_CATEGORIES,
|
|
255
256
|
CATEGORY_PRIORITY,
|
|
@@ -260,7 +261,7 @@ import {
|
|
|
260
261
|
userFacingFailureCode,
|
|
261
262
|
promoteSessionFactsDurable,
|
|
262
263
|
embedPromotedFacts
|
|
263
|
-
} from "./server-
|
|
264
|
+
} from "./server-nnh81jqy.js";
|
|
264
265
|
import {
|
|
265
266
|
computeCueContentHash,
|
|
266
267
|
getMuralCueState,
|
|
@@ -274,7 +275,7 @@ import {
|
|
|
274
275
|
LATEST_SUPPORTED_VERSION,
|
|
275
276
|
getPersistedSchemaVersion,
|
|
276
277
|
openDatabase
|
|
277
|
-
} from "./server-
|
|
278
|
+
} from "./server-vsx9tsks.js";
|
|
278
279
|
import {
|
|
279
280
|
parseCompartmentOutput,
|
|
280
281
|
resolveWorkspaceShareCategories,
|
|
@@ -283,15 +284,15 @@ import {
|
|
|
283
284
|
resolveStoredPathWorkspaceIdentity,
|
|
284
285
|
sourceNameForMemory,
|
|
285
286
|
computeWorkspaceEpochFingerprint
|
|
286
|
-
} from "./server-
|
|
287
|
+
} from "./server-2sare4qg.js";
|
|
287
288
|
import {
|
|
288
289
|
FAIL_CLOSED_DOCTOR_COMMAND
|
|
289
|
-
} from "./server-
|
|
290
|
+
} from "./server-2qvnr3t7.js";
|
|
290
291
|
import {
|
|
291
292
|
getSessionNotes,
|
|
292
293
|
getReadySmartNotes,
|
|
293
294
|
insertPrimerCandidates
|
|
294
|
-
} from "./server-
|
|
295
|
+
} from "./server-5t4nzfpt.js";
|
|
295
296
|
import {
|
|
296
297
|
pushNotification2
|
|
297
298
|
} from "./server-y14pawe1.js";
|
|
@@ -299,10 +300,10 @@ import {
|
|
|
299
300
|
deriveTriggerBudget2,
|
|
300
301
|
resolveHistorianProducerLimits2,
|
|
301
302
|
producerSourceLocalBudget2
|
|
302
|
-
} from "./server-
|
|
303
|
+
} from "./server-rt8t6s2a.js";
|
|
303
304
|
import {
|
|
304
305
|
sendStatusNotification2
|
|
305
|
-
} from "./server-
|
|
306
|
+
} from "./server-2cq3e1c1.js";
|
|
306
307
|
import {
|
|
307
308
|
retreatPastHostUnservedRows,
|
|
308
309
|
snapTerminalCompartmentToServedRow,
|
|
@@ -322,7 +323,7 @@ import {
|
|
|
322
323
|
import {
|
|
323
324
|
logSlowWriteTransaction,
|
|
324
325
|
WriteTransactionSteps
|
|
325
|
-
} from "./server-
|
|
326
|
+
} from "./server-tq523gj6.js";
|
|
326
327
|
import {
|
|
327
328
|
sameProjectDirectory
|
|
328
329
|
} from "./server-knvkbfvh.js";
|
|
@@ -2748,8 +2749,92 @@ function withoutHistorianTailCache(body) {
|
|
|
2748
2749
|
// src/v2/hidden-run-holder.ts
|
|
2749
2750
|
import { createHash as createHash5, randomUUID } from "node:crypto";
|
|
2750
2751
|
import { stat } from "node:fs/promises";
|
|
2752
|
+
|
|
2753
|
+
// src/v2/hidden-child-record.ts
|
|
2754
|
+
function keptUnderRetention(keepSubagents, child) {
|
|
2755
|
+
return keepSubagents && (child.ever_settled === true || child.role === "historian");
|
|
2756
|
+
}
|
|
2757
|
+
function roleTitle(role) {
|
|
2758
|
+
return role === "historian" ? "Magic Context historian" : "Magic Context dreamer";
|
|
2759
|
+
}
|
|
2760
|
+
function roleAgent(role) {
|
|
2761
|
+
if (role === "historian")
|
|
2762
|
+
return HIDDEN_HISTORIAN_AGENT;
|
|
2763
|
+
return role === "dreamer-curate" ? HIDDEN_CURATE_AGENT : HIDDEN_DREAMER_AGENT;
|
|
2764
|
+
}
|
|
2765
|
+
function childCreateInput(identity, role, model) {
|
|
2766
|
+
const agent = hiddenToolLoop(identity) ? hiddenAgentFor(identity) : roleAgent(role);
|
|
2767
|
+
return {
|
|
2768
|
+
title: roleTitle(role),
|
|
2769
|
+
agent,
|
|
2770
|
+
model: {
|
|
2771
|
+
providerID: model.providerID,
|
|
2772
|
+
id: model.modelID,
|
|
2773
|
+
...model.variant ? { variant: model.variant } : {}
|
|
2774
|
+
},
|
|
2775
|
+
location: { directory: identity.directory },
|
|
2776
|
+
metadata: { magic_context: "hidden-run", role },
|
|
2777
|
+
permissions: hiddenChildPermissions(agent, model.providerID)
|
|
2778
|
+
};
|
|
2779
|
+
}
|
|
2780
|
+
function assistantOutcome(row) {
|
|
2781
|
+
const outcome = row?.data.outcome;
|
|
2782
|
+
return outcome === "succeeded" || outcome === "failed" || outcome === "interrupted" ? outcome : undefined;
|
|
2783
|
+
}
|
|
2784
|
+
function withReader(openReader, read) {
|
|
2785
|
+
const reader = openReader();
|
|
2786
|
+
try {
|
|
2787
|
+
return read(reader);
|
|
2788
|
+
} finally {
|
|
2789
|
+
reader.close?.();
|
|
2790
|
+
}
|
|
2791
|
+
}
|
|
2792
|
+
function errorText(value) {
|
|
2793
|
+
if (value instanceof Error)
|
|
2794
|
+
return value.message;
|
|
2795
|
+
if (typeof value === "string")
|
|
2796
|
+
return value;
|
|
2797
|
+
try {
|
|
2798
|
+
return JSON.stringify(value);
|
|
2799
|
+
} catch {
|
|
2800
|
+
return String(value);
|
|
2801
|
+
}
|
|
2802
|
+
}
|
|
2803
|
+
|
|
2804
|
+
// src/v2/hidden-run-holder.ts
|
|
2751
2805
|
var HOLDER_PREFIX = "ses_mc_bg_";
|
|
2752
2806
|
var HOLDER_CANDIDATES = 3;
|
|
2807
|
+
var HOLDER_ARCHIVE_TIMEOUT_MS = 250;
|
|
2808
|
+
var archivingHolders = new Set;
|
|
2809
|
+
var loggedArchiveFailure = false;
|
|
2810
|
+
function supportsHolderArchive(version) {
|
|
2811
|
+
const release = version?.match(/^2\.(\d+)\.(\d+)$/);
|
|
2812
|
+
return !release || Number(release[1]) > 4 || Number(release[1]) === 4 && Number(release[2]) >= 3;
|
|
2813
|
+
}
|
|
2814
|
+
function archiveBackgroundHolder(id, archive) {
|
|
2815
|
+
if (archivingHolders.has(id))
|
|
2816
|
+
return;
|
|
2817
|
+
archivingHolders.add(id);
|
|
2818
|
+
(async () => {
|
|
2819
|
+
let timer;
|
|
2820
|
+
try {
|
|
2821
|
+
await Promise.race([
|
|
2822
|
+
Promise.resolve().then(() => archive.update({ sessionID: id, archived: true })),
|
|
2823
|
+
new Promise((_, reject) => {
|
|
2824
|
+
timer = setTimeout(() => reject(new Error(`session.update timed out after ${HOLDER_ARCHIVE_TIMEOUT_MS}ms`)), HOLDER_ARCHIVE_TIMEOUT_MS);
|
|
2825
|
+
})
|
|
2826
|
+
]);
|
|
2827
|
+
} catch (error) {
|
|
2828
|
+
if (!loggedArchiveFailure) {
|
|
2829
|
+
loggedArchiveFailure = true;
|
|
2830
|
+
archive.log(`[magic-context] could not archive background holder ${id}: ${errorText(error)}`);
|
|
2831
|
+
}
|
|
2832
|
+
} finally {
|
|
2833
|
+
clearTimeout(timer);
|
|
2834
|
+
archivingHolders.delete(id);
|
|
2835
|
+
}
|
|
2836
|
+
})();
|
|
2837
|
+
}
|
|
2753
2838
|
function isHiddenRunHolder(id) {
|
|
2754
2839
|
return id.startsWith(HOLDER_PREFIX);
|
|
2755
2840
|
}
|
|
@@ -2759,7 +2844,7 @@ function supportsQuietHiddenChildren(version) {
|
|
|
2759
2844
|
function matchesHiddenRunLocation(wanted, returned) {
|
|
2760
2845
|
return sameProjectDirectory(wanted, returned ?? "");
|
|
2761
2846
|
}
|
|
2762
|
-
async function hiddenRunPlacement(createHolder, directory, budget) {
|
|
2847
|
+
async function hiddenRunPlacement(createHolder, directory, budget, archive) {
|
|
2763
2848
|
const work = budget?.work ?? ((start) => start());
|
|
2764
2849
|
budget?.setStage("checking the holder directory");
|
|
2765
2850
|
if (!(await work(() => stat(directory))).isDirectory())
|
|
@@ -2778,6 +2863,8 @@ async function hiddenRunPlacement(createHolder, directory, budget) {
|
|
|
2778
2863
|
if (holder.id !== id || holder.parentID)
|
|
2779
2864
|
throw new Error(`OpenCode did not return the expected background holder ${id}`);
|
|
2780
2865
|
if (holder.metadata?.magic_context === "background-holder" && matchesHiddenRunLocation(directory, holder.location?.directory)) {
|
|
2866
|
+
if (archive && holder.time?.archived == null)
|
|
2867
|
+
archiveBackgroundHolder(id, archive);
|
|
2781
2868
|
return { id: `ses_aut_${randomUUID()}`, parentID: id };
|
|
2782
2869
|
}
|
|
2783
2870
|
displaced.push(id);
|
|
@@ -3225,6 +3312,12 @@ class HiddenChildHook {
|
|
|
3225
3312
|
onBudgetUpdate({ ...selected.budget.snapshot(), sessionId: draft.sessionID });
|
|
3226
3313
|
}
|
|
3227
3314
|
}
|
|
3315
|
+
if (selected.budget) {
|
|
3316
|
+
const count = selected.countRequestText ??= createTokenCountMemo(256, 2 * 1024 * 1024);
|
|
3317
|
+
const messageTokens = draft.messages.reduce((total, message) => total + count(JSON.stringify(message.content ?? message.parts) ?? ""), 0);
|
|
3318
|
+
const toolTokens = Object.values(draft.tools).reduce((total, tool) => total + count(tool.description) + count(JSON.stringify(tool.input) ?? ""), 0);
|
|
3319
|
+
(selected.requestTokenEstimates ??= []).push(count(systemText) + messageTokens + toolTokens);
|
|
3320
|
+
}
|
|
3228
3321
|
selected.observedMessages = draft.messages;
|
|
3229
3322
|
selected.shaped = true;
|
|
3230
3323
|
return true;
|
|
@@ -8239,11 +8332,12 @@ function clearDegradedRebuild(sessionId) {
|
|
|
8239
8332
|
degradedRebuildCountBySession.delete(sessionId);
|
|
8240
8333
|
reAnchorLoggedBySession.delete(sessionId);
|
|
8241
8334
|
}
|
|
8242
|
-
function logReanchorOnce(sessionId, message) {
|
|
8335
|
+
function logReanchorOnce(sessionId, message, quiet) {
|
|
8243
8336
|
if (reAnchorLoggedBySession.get(sessionId))
|
|
8244
8337
|
return;
|
|
8245
8338
|
reAnchorLoggedBySession.set(sessionId, true);
|
|
8246
|
-
|
|
8339
|
+
if (!quiet)
|
|
8340
|
+
sessionLog2(sessionId, message);
|
|
8247
8341
|
}
|
|
8248
8342
|
function findVisibleReanchorIndex(compartments, visibleMessageIds) {
|
|
8249
8343
|
for (let index = compartments.length - 1;index >= 0; index -= 1) {
|
|
@@ -8370,7 +8464,9 @@ function cutCoveredPrefix(messages, count, coveredInstructions) {
|
|
|
8370
8464
|
coveredInstructions.push(message);
|
|
8371
8465
|
}
|
|
8372
8466
|
}
|
|
8373
|
-
function prepareCompartmentInjection(db, sessionId, messages, isCacheBusting, coveredInstructions, projectPath, injectionBudgetTokens, temporalAwareness, frozenBaseline) {
|
|
8467
|
+
function prepareCompartmentInjection(db, sessionId, messages, isCacheBusting, coveredInstructions, projectPath, injectionBudgetTokens, temporalAwareness, frozenBaseline, restoredBoundaryDiagnostic) {
|
|
8468
|
+
if (restoredBoundaryDiagnostic)
|
|
8469
|
+
restoredBoundaryDiagnostic.expectedAbsence = false;
|
|
8374
8470
|
const cached = injectionCache.get(sessionId);
|
|
8375
8471
|
if (cached && cached.db !== db) {
|
|
8376
8472
|
clearInjectionCache(sessionId);
|
|
@@ -8516,6 +8612,9 @@ function prepareCompartmentInjection(db, sessionId, messages, isCacheBusting, co
|
|
|
8516
8612
|
resultEndMessageId = trimEndMessageId;
|
|
8517
8613
|
resultEndMessagePartial = trimEndMessagePartial;
|
|
8518
8614
|
} else {
|
|
8615
|
+
const quiet = restoredBoundaryDiagnostic?.restoredAfterId === trimEndMessageId;
|
|
8616
|
+
if (restoredBoundaryDiagnostic)
|
|
8617
|
+
restoredBoundaryDiagnostic.expectedAbsence = quiet;
|
|
8519
8618
|
const degradedCount = noteDegradedRebuild(sessionId);
|
|
8520
8619
|
if (isCacheBusting) {
|
|
8521
8620
|
reconcileForkOrphanedCompactionMarkers(db, sessionId, isCacheBusting);
|
|
@@ -8538,14 +8637,14 @@ function prepareCompartmentInjection(db, sessionId, messages, isCacheBusting, co
|
|
|
8538
8637
|
resultEndMessage = reAnchorCompartment.endMessage;
|
|
8539
8638
|
resultEndMessageId = reAnchorCompartment.endMessageId;
|
|
8540
8639
|
reAnchored = true;
|
|
8541
|
-
logReanchorOnce(sessionId, `compartment injection re-anchored: natural boundary ${trimEndMessageId} not visible for ${degradedCount} passes; splicing at visible compartment boundary ${resultEndMessageId} (ordinal ${resultEndMessage})
|
|
8640
|
+
logReanchorOnce(sessionId, `compartment injection re-anchored: natural boundary ${trimEndMessageId} not visible for ${degradedCount} passes; splicing at visible compartment boundary ${resultEndMessageId} (ordinal ${resultEndMessage})`, quiet);
|
|
8542
8641
|
}
|
|
8543
8642
|
}
|
|
8544
8643
|
if (!reAnchored) {
|
|
8545
8644
|
needsFreshMaterialization = true;
|
|
8546
|
-
logReanchorOnce(sessionId, `compartment injection degraded: boundary ${trimEndMessageId} not visible for ${degradedCount} passes and no compartment boundary is visible; requesting fresh materialization to re-cut the baseline
|
|
8645
|
+
logReanchorOnce(sessionId, `compartment injection degraded: boundary ${trimEndMessageId} not visible for ${degradedCount} passes and no compartment boundary is visible; requesting fresh materialization to re-cut the baseline`, quiet);
|
|
8547
8646
|
}
|
|
8548
|
-
} else {
|
|
8647
|
+
} else if (!quiet) {
|
|
8549
8648
|
sessionLog2(sessionId, `compartment injection entering degraded mode: boundary ${trimEndMessageId} not in visible messages (consecutive degraded passes: ${degradedCount})`);
|
|
8550
8649
|
}
|
|
8551
8650
|
}
|
|
@@ -17062,4 +17161,4 @@ ${failure}`;
|
|
|
17062
17161
|
}
|
|
17063
17162
|
}
|
|
17064
17163
|
|
|
17065
|
-
export { historianRunConfig, dreamerRunConfig, pluginConfigReader, currentPluginConfigReader, withLiveDreamerOutputCap, v2ToolDefinitionsHash, v2RequestToolsFingerprint, classifyRequestToolsChange, readCoordinateGeneration, rebaseSessionCoordinatesAsync, HiddenCompletionRefusal, getOpenCodeDbPath, compareOpenCodeMessagesByCanonicalOrder, startCompactionMarkerCandidatePreparation, removeMcOwnedCompactionMarkers, getCompartmentEvents, USER_MEMORY_CANDIDATE_TTL_MS, insertUserMemoryCandidates, getUserMemoryCandidates, deleteUserMemoryCandidates, pruneExpiredUserMemoryCandidates, insertUserMemory, getActiveUserMemories, updateUserMemoryContent, dismissUserMemory, DreamerProviderOutputFailureError, providerOutputFailureFromInvalidManifest, DREAMER_AGENT, DREAMER_RETROSPECTIVE_AGENT, DREAMER_PRIMER_INVESTIGATOR_AGENT, DREAMER_MEMORY_MAPPER_AGENT, DREAMER_CLASSIFIER_AGENT, DREAMER_DOCS_AGENT, DREAMER_REVIEWER_AGENT,
|
|
17164
|
+
export { historianRunConfig, dreamerRunConfig, pluginConfigReader, currentPluginConfigReader, withLiveDreamerOutputCap, v2ToolDefinitionsHash, v2RequestToolsFingerprint, classifyRequestToolsChange, readCoordinateGeneration, rebaseSessionCoordinatesAsync, HiddenCompletionRefusal, getOpenCodeDbPath, compareOpenCodeMessagesByCanonicalOrder, startCompactionMarkerCandidatePreparation, removeMcOwnedCompactionMarkers, getCompartmentEvents, USER_MEMORY_CANDIDATE_TTL_MS, insertUserMemoryCandidates, getUserMemoryCandidates, deleteUserMemoryCandidates, pruneExpiredUserMemoryCandidates, insertUserMemory, getActiveUserMemories, updateUserMemoryContent, dismissUserMemory, DreamerProviderOutputFailureError, providerOutputFailureFromInvalidManifest, DREAMER_AGENT, DREAMER_RETROSPECTIVE_AGENT, DREAMER_PRIMER_INVESTIGATOR_AGENT, DREAMER_MEMORY_MAPPER_AGENT, DREAMER_CLASSIFIER_AGENT, DREAMER_DOCS_AGENT, DREAMER_REVIEWER_AGENT, keptUnderRetention, roleTitle, childCreateInput, assistantOutcome, withReader, errorText, supportsHolderArchive, supportsQuietHiddenChildren, matchesHiddenRunLocation, hiddenRunPlacement, HIDDEN_CURATE_AGENT, hiddenToolLoop, HIDDEN_RUN_DISPOSED_REASON, noteChildOfDisposedInstance, noteTimedOutHiddenChild, registerHiddenChildAgents, hiddenToolCallRefusal, HiddenAgentStepLimit, HiddenChildHook, extractLatestAssistantText, hasLengthCappedOutput, isLatestAssistantLengthCapped, parseProviderModel, modelBodyField, toModelEntry, hiddenModelCooldowns, ModelProducedNoOutputError, promptTransportBudget, notePromptSetupTimeout, noteModelActivityMonitored, noteModelOutputReceived, isPromptTimeoutError, getPromptFailureDetail, raceWithSignal, promptSyncWithValidatedOutputRetry, normalizeSDKResponse, annotateSubagentInvocationError, failedInvocationStatus, emptyTokenTotals, sumTokensFromChildMessages, recordChildInvocation, createPromptAsyncTransport, CTX_NOTE_LIGHT_DESCRIPTION, ACTIVE_TOOL_IDS, systemPromptFingerprint, createPromptSurfaceRuntime, createPromptSurfaceGuidanceEpochCache, MARKER_SUMMARY_TEXT, markerUpdateDefinitelyDidNotCut, applyDeferredCompactionMarker, teardownChildSession, runTokenLog, formatRunTokenLog, createChildSessionWithFence, validateStoredCompartments, buildMagicContextSection, getMuralIdentity, getMural, modelKeyAcceptsImages, resolveMuralWire, 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, clampProducerAtomChars, producerInputTokenLimit, historianProducerReserve, producerPromptFailureReason, resolveHiddenCompletionExecutor, createV1HiddenCompletionExecutor, omitIncompleteFileTokenTotals, describeBoundaryDiagnostics, RECOVERY_NO_HEAD_LIMIT, resolveOpenCodeProtectedTailBoundary, resolveWrapupProtectedTailBoundary, getRawHistoryEligibility, hasRunnableCompartmentWindow, recordHighPressureNoEligibleHead, reportProviderRecoveryDrainSkip, isHistorianDrainBudgetSpent, readHistorianFailureStreak, describeHistorianJoinRefusal, shouldWaitForNewHistorianHistory, EMPTY_READ_REPLY, noteTouchedAt, renderGlance, renderNotesById, formatWriteReply, observeNoteNudgeServe, onNoteTrigger, peekNoteNudgeText, markNoteNudgeDelivered, clearNoteNudgeTriggerAndCooldown, clearNoteNudgeTriggerOnly, noteTransformPassForExactOrdinalReads, nonNarrativeStoredGapRanges, runCompartmentAgent, getActiveCompartmentRun, markActiveCompartmentRunPublished, registerActiveCompartmentRun, startCompartmentAgent, isRecompFailure2, isRecompSkip2, extractRecompReason2, setRecompStarting2, setRecompNote2, setRecompTerminal2, buildRecompDeps2, runManagedRecomp2 };
|
|
@@ -4,13 +4,13 @@ import {
|
|
|
4
4
|
import {
|
|
5
5
|
importPluginModule,
|
|
6
6
|
sessionLog2
|
|
7
|
-
} from "./server-
|
|
7
|
+
} from "./server-kzrrdjp5.js";
|
|
8
8
|
import {
|
|
9
9
|
isDefaultSessionTitle2
|
|
10
|
-
} from "./server-
|
|
10
|
+
} from "./server-63ree5ns.js";
|
|
11
11
|
import {
|
|
12
12
|
shouldHoldIgnoredNotification
|
|
13
|
-
} from "./server-
|
|
13
|
+
} from "./server-bx5k66qc.js";
|
|
14
14
|
import {
|
|
15
15
|
getErrorMessage
|
|
16
16
|
} from "./server-y8v6yerm.js";
|
|
@@ -142,7 +142,7 @@ async function sendIgnoredMessageNow(client, sessionId, text, params, forcePersi
|
|
|
142
142
|
holdIgnoredNotification({ client, sessionId, text, params, forcePersist }, "during target checks");
|
|
143
143
|
return "queued";
|
|
144
144
|
}
|
|
145
|
-
const { waitForSafeNotificationTarget } = await importPluginModule(() => import("./safe-notification-target-
|
|
145
|
+
const { waitForSafeNotificationTarget } = await importPluginModule(() => import("./safe-notification-target-zrwbh6k7.js"));
|
|
146
146
|
if (await waitForSafeNotificationTarget(client, sessionId) === "skip") {
|
|
147
147
|
sessionLog2(sessionId, "notification skipped (session not titled yet)");
|
|
148
148
|
return "skipped";
|
|
@@ -3,12 +3,12 @@ import {
|
|
|
3
3
|
} from "./server-fr0wbhdn.js";
|
|
4
4
|
import {
|
|
5
5
|
log2
|
|
6
|
-
} from "./server-
|
|
6
|
+
} from "./server-kzrrdjp5.js";
|
|
7
7
|
import {
|
|
8
8
|
ensureColumn,
|
|
9
9
|
healAllNullColumns,
|
|
10
10
|
installV95PerfSchema
|
|
11
|
-
} from "./server-
|
|
11
|
+
} from "./server-4yrvbnnm.js";
|
|
12
12
|
import {
|
|
13
13
|
resolveOpenCodeDbPath,
|
|
14
14
|
openCodeDbPathExists,
|
|
@@ -20,10 +20,10 @@ import {
|
|
|
20
20
|
import {
|
|
21
21
|
normalizeStoredProjectPath,
|
|
22
22
|
storedPathBelongsToIdentity
|
|
23
|
-
} from "./server-
|
|
23
|
+
} from "./server-n33hyq9t.js";
|
|
24
24
|
import {
|
|
25
25
|
logSlowWriteTransaction
|
|
26
|
-
} from "./server-
|
|
26
|
+
} from "./server-tq523gj6.js";
|
|
27
27
|
|
|
28
28
|
// src/features/magic-context/migrations.ts
|
|
29
29
|
import { isMainThread } from "node:worker_threads";
|
|
@@ -5,10 +5,10 @@ import {
|
|
|
5
5
|
} from "./server-gzy5w8ya.js";
|
|
6
6
|
import {
|
|
7
7
|
runSessionWarmupWorker
|
|
8
|
-
} from "./server-
|
|
8
|
+
} from "./server-av3p9c8k.js";
|
|
9
9
|
import {
|
|
10
10
|
logSlowWriteTransaction
|
|
11
|
-
} from "./server-
|
|
11
|
+
} from "./server-tq523gj6.js";
|
|
12
12
|
|
|
13
13
|
// src/features/magic-context/message-fts-rowid-map.ts
|
|
14
14
|
import { createHash } from "node:crypto";
|
|
@@ -3,10 +3,10 @@ import {
|
|
|
3
3
|
} from "./server-pavzsdc6.js";
|
|
4
4
|
import {
|
|
5
5
|
isUserHomeDirectory
|
|
6
|
-
} from "./server-
|
|
6
|
+
} from "./server-n33hyq9t.js";
|
|
7
7
|
import {
|
|
8
8
|
logSlowWriteTransaction
|
|
9
|
-
} from "./server-
|
|
9
|
+
} from "./server-tq523gj6.js";
|
|
10
10
|
|
|
11
11
|
// src/features/magic-context/git-commits/sweep-coordinator.ts
|
|
12
12
|
var GIT_SWEEP_COOLDOWN_MS = 10 * 60 * 1000;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
DEFAULT_LOCAL_EMBEDDING_MODEL
|
|
3
|
-
} from "./server-
|
|
3
|
+
} from "./server-arfzfxe8.js";
|
|
4
4
|
import {
|
|
5
5
|
getHarness2
|
|
6
6
|
} from "./server-pavzsdc6.js";
|
|
@@ -9,17 +9,17 @@ import {
|
|
|
9
9
|
importPluginModule,
|
|
10
10
|
log2,
|
|
11
11
|
flushLogger2
|
|
12
|
-
} from "./server-
|
|
12
|
+
} from "./server-kzrrdjp5.js";
|
|
13
13
|
import {
|
|
14
14
|
shouldEnforcePrivateStoragePermissions,
|
|
15
15
|
ensureStorageDirectorySync,
|
|
16
16
|
writeStorageFileAsync,
|
|
17
17
|
writeStorageFileHandleAsync,
|
|
18
18
|
createStorageFileHandleAsync
|
|
19
|
-
} from "./server-
|
|
19
|
+
} from "./server-n34vzyfm.js";
|
|
20
20
|
import {
|
|
21
21
|
getSynapseLaneIdentity
|
|
22
|
-
} from "./server-
|
|
22
|
+
} from "./server-k3ntgf6n.js";
|
|
23
23
|
import {
|
|
24
24
|
inRootAsyncContext2
|
|
25
25
|
} from "./server-gzy5w8ya.js";
|
|
@@ -6843,7 +6843,11 @@ var AgentMetadataSchema = AgentOverrideConfigSchema.pick({
|
|
|
6843
6843
|
permission: true,
|
|
6844
6844
|
maxTokens: true
|
|
6845
6845
|
});
|
|
6846
|
-
var DreamerConfigSchema = AgentMetadataSchema.
|
|
6846
|
+
var DreamerConfigSchema = AgentMetadataSchema.omit({
|
|
6847
|
+
prompt: true,
|
|
6848
|
+
tools: true,
|
|
6849
|
+
permission: true
|
|
6850
|
+
}).extend({
|
|
6847
6851
|
disable: boolean().optional().describe("Disable the dreamer: no scheduled or manual dream task runs. Also turns off smart notes (ctx_note drops surface_condition even with smart_notes.enabled true) and the historian's collection of user observations for review-user-memories. dreamer.inject_docs still applies."),
|
|
6848
6852
|
runner: _enum(["broca", "host"]).optional().describe(`Which side runs the dreamer completions the Rust module routes (classify-memories) in Rust transform mode: "host" runs them on this process's carrier, "broca" routes them to the Broca module. When unset, historian.runner applies, and when that is unset too the harness decides the same way it does for the historian. User-level config only.`),
|
|
6849
6853
|
opencode: DreamerOpenCodeHarnessBlockSchema.optional(),
|
|
@@ -6,7 +6,7 @@ import {
|
|
|
6
6
|
estimateMessageTokens,
|
|
7
7
|
getCandidateToolOwners2,
|
|
8
8
|
pickNearestPriorOwner2
|
|
9
|
-
} from "./server-
|
|
9
|
+
} from "./server-11ra1pmx.js";
|
|
10
10
|
import {
|
|
11
11
|
OMO_INTERNAL_INITIATOR_MARKER,
|
|
12
12
|
isSystemDirective,
|
|
@@ -21,16 +21,16 @@ import {
|
|
|
21
21
|
formatBlock,
|
|
22
22
|
compactTextForSummary,
|
|
23
23
|
mergeCommitHashes
|
|
24
|
-
} from "./server-
|
|
24
|
+
} from "./server-73bqw5c0.js";
|
|
25
25
|
import {
|
|
26
26
|
sessionLog2
|
|
27
|
-
} from "./server-
|
|
27
|
+
} from "./server-kzrrdjp5.js";
|
|
28
28
|
import {
|
|
29
29
|
stableStringify
|
|
30
|
-
} from "./server-
|
|
30
|
+
} from "./server-4yrvbnnm.js";
|
|
31
31
|
import {
|
|
32
32
|
renderToolTemplate
|
|
33
|
-
} from "./server-
|
|
33
|
+
} from "./server-arfzfxe8.js";
|
|
34
34
|
import {
|
|
35
35
|
readRawSessionMessagesFromDb2,
|
|
36
36
|
readRawSessionMessagePageFromDb2,
|
|
@@ -47,13 +47,13 @@ import {
|
|
|
47
47
|
readRawSeedTailFromDb2,
|
|
48
48
|
readRawSessionBoundaryEndpointsFromDb2,
|
|
49
49
|
prewarmRawSessionOrdinalsForDb
|
|
50
|
-
} from "./server-
|
|
50
|
+
} from "./server-av3p9c8k.js";
|
|
51
51
|
import {
|
|
52
52
|
openCodeDbExists,
|
|
53
53
|
withReadOnlySessionDb,
|
|
54
54
|
getRawSessionMessageCountFromDb,
|
|
55
55
|
getMessageTimesFromOpenCodeDb
|
|
56
|
-
} from "./server-
|
|
56
|
+
} from "./server-bx5k66qc.js";
|
|
57
57
|
import {
|
|
58
58
|
markHostUnservedRow,
|
|
59
59
|
isHostUnservedRow
|
|
@@ -96,7 +96,8 @@ function sanitizePathString(value) {
|
|
|
96
96
|
sanitized = sanitized.replace(/\/home\/[^/]+\//g, "/home/<USER>/");
|
|
97
97
|
sanitized = sanitized.replace(/C:\\Users\\[^\\]+\\/g, "C:\\Users\\<USER>\\");
|
|
98
98
|
if (username) {
|
|
99
|
-
|
|
99
|
+
const word = "[\\p{L}\\p{M}\\p{N}_]";
|
|
100
|
+
sanitized = sanitized.replace(new RegExp(`(?<!${word})${escapeRegex(username)}(?!${word})`, "gu"), "<USER>");
|
|
100
101
|
}
|
|
101
102
|
return sanitized;
|
|
102
103
|
}
|