@cortexkit/opencode-magic-context 0.49.34 → 0.49.36
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/dist/auto-search-worker.js +163 -155
- package/dist/chunk-embedding-write-worker.js +70 -66
- package/dist/{compaction-marker-candidates-31h86ph0.js → compaction-marker-candidates-5p1qkve9.js} +5 -2
- package/dist/compaction-marker-candidates-worker.js +24 -23
- package/dist/{compartment-chunk-embedding-5q5gj67r.js → compartment-chunk-embedding-ypktm0tk.js} +10 -8
- package/dist/{conflict-warning-hook-xgskea1v.js → conflict-warning-hook-b75jn458.js} +11 -9
- package/dist/{context-p3xrarzt.js → context-969z683s.js} +1839 -746
- package/dist/{derive-budgets-pqybnx09.js → derive-budgets-htj16n4x.js} +3 -2
- package/dist/embedding-backfill-rma0v2ct.js +28 -0
- package/dist/embedding-worker-process.js +2 -1
- package/dist/embedding-worker.js +6 -5
- package/dist/expand-attachments-h33jbgyz.js +21 -0
- package/dist/features/magic-context/auto-search-diagnostics.d.ts +21 -0
- package/dist/features/magic-context/auto-search-diagnostics.d.ts.map +1 -0
- package/dist/features/magic-context/compaction-marker-candidates.d.ts.map +1 -1
- package/dist/features/magic-context/compaction-marker.d.ts +5 -3
- package/dist/features/magic-context/compaction-marker.d.ts.map +1 -1
- package/dist/features/magic-context/compartment-chunk-embedding.d.ts +1 -1
- package/dist/features/magic-context/compartment-chunk-embedding.d.ts.map +1 -1
- package/dist/features/magic-context/dreamer/task-gates.d.ts.map +1 -1
- package/dist/features/magic-context/dreamer/verify-gate.d.ts +2 -0
- package/dist/features/magic-context/dreamer/verify-gate.d.ts.map +1 -1
- package/dist/features/magic-context/dreamer/verify-state.d.ts +9 -0
- package/dist/features/magic-context/dreamer/verify-state.d.ts.map +1 -0
- package/dist/features/magic-context/dreamer/verify.d.ts +2 -1
- package/dist/features/magic-context/dreamer/verify.d.ts.map +1 -1
- package/dist/features/magic-context/migration-worker-client.d.ts +3 -0
- package/dist/features/magic-context/migration-worker-client.d.ts.map +1 -1
- package/dist/features/magic-context/migration-worker.d.ts +15 -0
- package/dist/features/magic-context/migration-worker.d.ts.map +1 -1
- package/dist/features/magic-context/overflow-detection.d.ts +2 -2
- package/dist/features/magic-context/overflow-detection.d.ts.map +1 -1
- package/dist/features/magic-context/search-rerank.d.ts.map +1 -1
- package/dist/features/magic-context/search.d.ts +4 -0
- package/dist/features/magic-context/search.d.ts.map +1 -1
- package/dist/features/magic-context/storage-meta-persisted.d.ts +1 -0
- package/dist/features/magic-context/storage-meta-persisted.d.ts.map +1 -1
- package/dist/features/magic-context/storage-tags.d.ts +4 -0
- package/dist/features/magic-context/storage-tags.d.ts.map +1 -1
- package/dist/features/magic-context/store-generation-rebase-labels.d.ts +6 -0
- package/dist/features/magic-context/store-generation-rebase-labels.d.ts.map +1 -0
- package/dist/features/magic-context/store-generation-rebase.d.ts.map +1 -1
- package/dist/features/magic-context/work-metrics-carry-storage.d.ts +10 -0
- package/dist/features/magic-context/work-metrics-carry-storage.d.ts.map +1 -0
- package/dist/{history-owner-36wp3mkb.js → history-owner-0z620wgz.js} +3 -2
- package/dist/hooks/magic-context/apply-operations.d.ts +20 -3
- package/dist/hooks/magic-context/apply-operations.d.ts.map +1 -1
- package/dist/hooks/magic-context/auto-search-observation.d.ts +13 -0
- package/dist/hooks/magic-context/auto-search-observation.d.ts.map +1 -0
- package/dist/hooks/magic-context/auto-search-runner.d.ts.map +1 -1
- package/dist/hooks/magic-context/auto-search-worker-client.d.ts +10 -2
- package/dist/hooks/magic-context/auto-search-worker-client.d.ts.map +1 -1
- package/dist/hooks/magic-context/compaction-marker-publication.d.ts.map +1 -1
- package/dist/hooks/magic-context/compartment-commit-hashes.d.ts +4 -0
- package/dist/hooks/magic-context/compartment-commit-hashes.d.ts.map +1 -0
- package/dist/hooks/magic-context/compartment-runner-historian.d.ts.map +1 -1
- package/dist/hooks/magic-context/compartment-runner-validation.d.ts +1 -0
- package/dist/hooks/magic-context/compartment-runner-validation.d.ts.map +1 -1
- package/dist/hooks/magic-context/event-resolvers.d.ts.map +1 -1
- package/dist/hooks/magic-context/final-wire-completeness.d.ts +15 -0
- package/dist/hooks/magic-context/final-wire-completeness.d.ts.map +1 -0
- package/dist/hooks/magic-context/final-wire-token-estimate.d.ts.map +1 -1
- package/dist/hooks/magic-context/issue-423-fixture.d.ts +1 -1
- package/dist/hooks/magic-context/issue-423-fixture.d.ts.map +1 -1
- package/dist/hooks/magic-context/issue-424-fixture.d.ts +1 -1
- package/dist/hooks/magic-context/issue-424-fixture.d.ts.map +1 -1
- package/dist/hooks/magic-context/project-structural-sentinels.d.ts +25 -0
- package/dist/hooks/magic-context/project-structural-sentinels.d.ts.map +1 -0
- package/dist/hooks/magic-context/protected-tail-boundary.d.ts +8 -1
- package/dist/hooks/magic-context/protected-tail-boundary.d.ts.map +1 -1
- package/dist/hooks/magic-context/raw-ordinal-warmup.d.ts +1 -0
- package/dist/hooks/magic-context/raw-ordinal-warmup.d.ts.map +1 -1
- package/dist/hooks/magic-context/read-session-chunk.d.ts +11 -0
- package/dist/hooks/magic-context/read-session-chunk.d.ts.map +1 -1
- package/dist/hooks/magic-context/read-session-formatting.d.ts +2 -0
- package/dist/hooks/magic-context/read-session-formatting.d.ts.map +1 -1
- package/dist/hooks/magic-context/read-session-true-raw-tokens.d.ts +2 -0
- package/dist/hooks/magic-context/read-session-true-raw-tokens.d.ts.map +1 -1
- package/dist/hooks/magic-context/release-recovery-prefix.d.ts +9 -0
- package/dist/hooks/magic-context/release-recovery-prefix.d.ts.map +1 -0
- package/dist/hooks/magic-context/strip-structural-noise.d.ts +6 -3
- package/dist/hooks/magic-context/strip-structural-noise.d.ts.map +1 -1
- package/dist/hooks/magic-context/transform-context-state.d.ts +3 -0
- package/dist/hooks/magic-context/transform-context-state.d.ts.map +1 -1
- package/dist/hooks/magic-context/transform-postprocess-phase.d.ts +3 -0
- package/dist/hooks/magic-context/transform-postprocess-phase.d.ts.map +1 -1
- package/dist/hooks/magic-context/transform.d.ts.map +1 -1
- package/dist/{index-cpjk5jd2.js → index-1d042x6w.js} +16 -14
- package/dist/{index-2743x98y.js → index-21fgrfrf.js} +35 -142
- package/dist/index-2amn2s73.js +123 -0
- package/dist/{index-c7phnbvk.js → index-2p37txes.js} +1 -1
- package/dist/index-2qbtqg1w.js +529 -0
- package/dist/{index-9gpw8hrm.js → index-2rs7912w.js} +4 -4
- package/dist/{index-m1x9ghk5.js → index-4ks89h5a.js} +37 -7
- package/dist/{index-b88dwwrh.js → index-4xyjr62e.js} +1 -1
- package/dist/index-4y35msh5.js +531 -0
- package/dist/index-66a50f3e.js +777 -0
- package/dist/index-72czy45z.js +4557 -0
- package/dist/index-7v05d9b7.js +58 -0
- package/dist/{index-qgh1qwjj.js → index-850vthn3.js} +9 -3
- package/dist/{index-np3rgfw4.js → index-8jjjmhab.js} +15 -4
- package/dist/index-96ztjvkn.js +204 -0
- package/dist/{index-fm36bjv4.js → index-9fgmkfaf.js} +22 -277
- package/dist/{index-atekmqef.js → index-9tdvbdv1.js} +508 -5547
- package/dist/{index-xrnsygfq.js → index-9wnbnx8f.js} +1 -1
- package/dist/{index-waktfbjy.js → index-ae1ar4v1.js} +4 -4
- package/dist/{index-v15ne3a3.js → index-b1ydbp95.js} +2 -2
- package/dist/{index-nxrsns5x.js → index-c5dzns43.js} +75 -75
- package/dist/{index-v7287tzq.js → index-dcjkw41m.js} +19 -8
- package/dist/{index-hbx7m8he.js → index-dfdg2cgg.js} +338 -86
- package/dist/{index-spwjbkc7.js → index-dnqqqc5f.js} +1 -1
- package/dist/{index-04z754rd.js → index-dz48h1wx.js} +33 -5
- package/dist/{index-rrv26qjz.js → index-fw42ms3m.js} +1 -1
- package/dist/{index-t5pck3ss.js → index-fxbk7gk3.js} +1 -1
- package/dist/{index-wfybj1dw.js → index-g4t7850m.js} +2 -2
- package/dist/{index-97spytxq.js → index-gnmhbyyc.js} +583 -474
- package/dist/{index-4pnsgvfk.js → index-hacf2tyx.js} +1 -1
- package/dist/index-j105mf16.js +270 -0
- package/dist/{index-gkee6p4g.js → index-jggt5gf2.js} +3 -3
- package/dist/{index-s1n8dd2n.js → index-jkanybgq.js} +2 -2
- package/dist/{index-h7tgn49j.js → index-jrfre9ah.js} +5 -222
- package/dist/{index-kfyb3k6n.js → index-jz5bk7xd.js} +2 -2
- package/dist/{index-7kkphb6c.js → index-nj360hcs.js} +4 -4
- package/dist/{index-07vskjn8.js → index-pp8vdn01.js} +15 -13
- package/dist/index-prw8apnc.js +194 -0
- package/dist/{index-rverk2vz.js → index-r2epb000.js} +34 -4
- package/dist/{index-7g9dr8gy.js → index-tn9drm1a.js} +125 -143
- package/dist/{index-kq5w68dp.js → index-txs8tce6.js} +1 -1
- package/dist/{index-rfxzazzy.js → index-ty4vhe4n.js} +5 -5
- package/dist/{index-y1qwzvxn.js → index-vd2ywmfe.js} +2 -2
- package/dist/{index-0677w9sd.js → index-wcwhhtdh.js} +58 -23
- package/dist/index-wh9fxds5.js +265 -0
- package/dist/{index-51rdvtkz.js → index-xd2p95m7.js} +3 -3
- package/dist/{index-as2amvn3.js → index-xnm0wq1r.js} +6 -531
- package/dist/{index-ftr84kkv.js → index-ys7j6679.js} +7 -5
- package/dist/index-z4p0ry94.js +222 -0
- package/dist/index-z9zygwse.js +89 -0
- package/dist/index.js +86 -74
- package/dist/{logger-94kew5wm.js → logger-qwnbcfj9.js} +2 -1
- package/dist/{message-fts-rowid-map-va36knh4.js → message-fts-rowid-map-t6qsyg9s.js} +7 -5
- package/dist/{message-index-bounded-qh91fdr3.js → message-index-bounded-wfk6aqxk.js} +15 -13
- package/dist/{message-time-backfill-4qva0b4f.js → message-time-backfill-39bm498k.js} +3 -2
- package/dist/migration-worker.js +55 -48
- package/dist/plugin/rpc-handlers.d.ts.map +1 -1
- package/dist/{project-embedding-registry-6yex0r9f.js → project-embedding-registry-3yyegjma.js} +16 -13
- package/dist/raw-ordinal-warmup-worker.js +114 -113
- package/dist/{read-session-chunk-kaghtr75.js → read-session-chunk-26yrrhyz.js} +18 -12
- package/dist/{read-session-raw-b2sd67v4.js → read-session-raw-j7c9w57v.js} +5 -3
- package/dist/recomp-orchestrator-wk509qkp.js +69 -0
- package/dist/render-h1qarr8a.js +44 -0
- package/dist/{safe-notification-target-mkr9yzvr.js → safe-notification-target-wztd7bgk.js} +3 -2
- package/dist/search-5h9fydyq.js +54 -0
- package/dist/search-archive-q79hyqxs.js +29 -0
- package/dist/{send-session-notification-vz86nt79.js → send-session-notification-14p3yje4.js} +9 -7
- package/dist/shared/model-suggestion-retry.d.ts +7 -0
- package/dist/shared/model-suggestion-retry.d.ts.map +1 -1
- package/dist/shared/prompt-async-transport.d.ts.map +1 -1
- package/dist/shared/reusable-worker-entry.d.ts +4 -0
- package/dist/shared/reusable-worker-entry.d.ts.map +1 -0
- package/dist/shared/reusable-worker.d.ts +6 -0
- package/dist/shared/reusable-worker.d.ts.map +1 -0
- package/dist/shared/reusable-worker.fixture.d.ts +2 -0
- package/dist/shared/reusable-worker.fixture.d.ts.map +1 -0
- package/dist/shared/worker-shutdown.d.ts +1 -1
- package/dist/shared/worker-shutdown.d.ts.map +1 -1
- package/dist/{storage-tags-6hvkk01c.js → storage-tags-vj0yj7ed.js} +5 -4
- package/dist/store-reader-yh19h38c.js +14 -0
- package/dist/store-s3eykdjt.js +21 -0
- package/dist/tools/ctx-expand/render.d.ts +5 -3
- package/dist/tools/ctx-expand/render.d.ts.map +1 -1
- package/dist/tools/ctx-expand/search-archive.d.ts.map +1 -1
- package/dist/tools/ctx-expand/tools.d.ts +2 -0
- package/dist/tools/ctx-expand/tools.d.ts.map +1 -1
- package/dist/tools/ctx-expand/v2-archive-reader.d.ts +33 -0
- package/dist/tools/ctx-expand/v2-archive-reader.d.ts.map +1 -0
- package/dist/{transform-postprocess-phase-ph38mhrs.js → transform-postprocess-phase-4gj0mtcg.js} +39 -32
- package/dist/v2/auto-search-worker.js +163 -155
- package/dist/v2/chunk-embedding-write-worker.js +71 -67
- package/dist/v2/compaction-marker-candidates-worker.js +24 -23
- package/dist/v2/{compaction-marker-candidates-m4vmye3w.js → compaction-marker-candidates-yeb2ky46.js} +6 -3
- package/dist/v2/{compartment-chunk-embedding-rc31e6md.js → compartment-chunk-embedding-qfk791bd.js} +11 -9
- package/dist/v2/{context-s60hcatx.js → context-bxr039be.js} +2678 -1246
- package/dist/v2/{derive-budgets-knf763tt.js → derive-budgets-sa0v7bz0.js} +4 -3
- package/dist/v2/embedding-backfill-00tw59rx.js +27 -0
- package/dist/v2/embedding-worker-process.js +2 -1
- package/dist/v2/embedding-worker.js +6 -5
- package/dist/v2/expand-attachments-h33jbgyz.js +21 -0
- package/dist/v2/fold/code-mode-catalog.d.ts +3 -0
- package/dist/v2/fold/code-mode-catalog.d.ts.map +1 -0
- package/dist/v2/fold/idle.d.ts +16 -0
- package/dist/v2/fold/idle.d.ts.map +1 -0
- package/dist/v2/fold/manual-baseline.d.ts +8 -0
- package/dist/v2/fold/manual-baseline.d.ts.map +1 -0
- package/dist/v2/fold/native-replay-v3.d.ts +75 -0
- package/dist/v2/fold/native-replay-v3.d.ts.map +1 -0
- package/dist/v2/fold/native-replay.d.ts +81 -8
- package/dist/v2/fold/native-replay.d.ts.map +1 -1
- package/dist/v2/fold/policy.d.ts +2 -1
- package/dist/v2/fold/policy.d.ts.map +1 -1
- package/dist/v2/fold/restore.d.ts.map +1 -1
- package/dist/v2/fold/summary.d.ts +4 -0
- package/dist/v2/fold/summary.d.ts.map +1 -0
- package/dist/v2/hidden-completion.d.ts.map +1 -1
- package/dist/v2/{history-owner-ad0crnrn.js → history-owner-fpka43cn.js} +3 -2
- package/dist/v2/hooks/channel2.d.ts +6 -0
- package/dist/v2/hooks/channel2.d.ts.map +1 -1
- package/dist/v2/hooks/context.d.ts.map +1 -1
- package/dist/v2/hooks/expand-attachments.d.ts +8 -0
- package/dist/v2/hooks/expand-attachments.d.ts.map +1 -0
- package/dist/v2/hooks/overflow-recovery.d.ts +45 -0
- package/dist/v2/hooks/overflow-recovery.d.ts.map +1 -0
- package/dist/v2/hooks/restore-rows.d.ts +12 -2
- package/dist/v2/hooks/restore-rows.d.ts.map +1 -1
- package/dist/v2/hooks/store.d.ts +7 -2
- package/dist/v2/hooks/store.d.ts.map +1 -1
- package/dist/v2/hooks/synthetic-admission.d.ts +7 -0
- package/dist/v2/hooks/synthetic-admission.d.ts.map +1 -0
- package/dist/v2/hooks/usage-persist.d.ts.map +1 -1
- package/dist/v2/{logger-p34mjtja.js → logger-4cj6d03m.js} +2 -1
- package/dist/v2/{message-fts-rowid-map-78awh03v.js → message-fts-rowid-map-z86avy0n.js} +8 -6
- package/dist/v2/{message-index-bounded-4htdr1j6.js → message-index-bounded-w14496s9.js} +16 -14
- package/dist/v2/{message-time-backfill-zvthw6xb.js → message-time-backfill-0c4h7sg6.js} +3 -2
- package/dist/v2/migration-worker.js +56 -49
- package/dist/v2/ordinal-range.fixture.d.ts +7 -0
- package/dist/v2/ordinal-range.fixture.d.ts.map +1 -0
- package/dist/v2/{project-embedding-registry-1x5qe2fy.js → project-embedding-registry-jqq2qeqb.js} +17 -14
- package/dist/v2/raw-ordinal-warmup-worker.js +114 -113
- package/dist/v2/{read-session-chunk-1fa9qzwb.js → read-session-chunk-tqnh1ret.js} +18 -12
- package/dist/v2/{read-session-raw-5x088amc.js → read-session-raw-qpp6x9kg.js} +6 -4
- package/dist/v2/recomp-orchestrator-9cjk6aej.js +68 -0
- package/dist/v2/render-5dz1knf2.js +43 -0
- package/dist/v2/{safe-notification-target-khnzg57c.js → safe-notification-target-gphhast7.js} +3 -2
- package/dist/v2/search-8yfet25y.js +52 -0
- package/dist/v2/search-archive-z6z9jqwf.js +28 -0
- package/dist/v2/{send-session-notification-x5nzy34v.js → send-session-notification-kxp47tsw.js} +9 -7
- package/dist/v2/{server-cpjk5jd2.js → server-1d042x6w.js} +16 -14
- package/dist/v2/server-2amn2s73.js +123 -0
- package/dist/v2/{server-6g98c227.js → server-3schkz95.js} +4 -4
- package/dist/v2/server-468mya5v.js +209 -0
- package/dist/v2/{server-z2wft9zv.js → server-5by3vdzs.js} +562 -5560
- package/dist/v2/{server-qjvk4a9t.js → server-69m30b21.js} +1 -1
- package/dist/v2/server-6emy0v9a.js +531 -0
- package/dist/v2/{server-vr4szghm.js → server-6vzh6wej.js} +3 -3
- package/dist/v2/{server-ajxhrgjv.js → server-7094pk3w.js} +80 -19
- package/dist/v2/{server-ab8017gw.js → server-7acq7815.js} +34 -141
- package/dist/v2/server-7v05d9b7.js +58 -0
- package/dist/v2/{server-24g8r2d0.js → server-7zacmty5.js} +75 -75
- package/dist/v2/{server-3mz2qh5a.js → server-969cdpmg.js} +1 -1
- package/dist/v2/server-96ztjvkn.js +204 -0
- package/dist/v2/{server-grakwy1v.js → server-a9w5f0yw.js} +37 -7
- package/dist/v2/{server-835q39kd.js → server-avdveykk.js} +3 -3
- package/dist/v2/{server-qc915kw2.js → server-bez34e60.js} +4 -4
- package/dist/v2/{server-h1byrhwx.js → server-cp1a03vc.js} +19 -8
- package/dist/v2/{server-bsgd4dk1.js → server-dcws5831.js} +2 -2
- package/dist/v2/{server-m1pfg2d4.js → server-dfq5vb8j.js} +4 -4
- package/dist/v2/server-e51xmr4d.js +194 -0
- package/dist/v2/server-ef1mskas.js +777 -0
- package/dist/v2/{server-1bw1wcbp.js → server-f0j864ma.js} +1 -1
- package/dist/v2/{server-jw5qe9y8.js → server-g3gqq4ac.js} +18 -217
- package/dist/v2/{server-2aasmpsp.js → server-gkse1wyz.js} +5 -5
- package/dist/v2/{server-6495nmn9.js → server-jb6tjyeb.js} +5 -222
- package/dist/v2/{server-qvy4qavp.js → server-jd7vzwn4.js} +125 -143
- package/dist/v2/{server-a7x00tw8.js → server-mfn1yf9d.js} +1 -1
- package/dist/v2/{server-awr8qa4c.js → server-nmyganc8.js} +2 -2
- package/dist/v2/{server-tkdabx8q.js → server-nq3cb7be.js} +5 -530
- package/dist/v2/server-qjyp27vf.js +270 -0
- package/dist/v2/{server-gyy4k6mf.js → server-qmmkhz2z.js} +1 -1
- package/dist/v2/{server-29qp8nz4.js → server-qxzbmtqt.js} +1 -1
- package/dist/v2/{server-806rzhs6.js → server-r4430x9m.js} +10 -4
- package/dist/v2/{server-53eh1r8r.js → server-sd8hvzte.js} +2 -2
- package/dist/v2/{server-k3t06fxr.js → server-sefxj8k1.js} +1 -1
- package/dist/v2/server-t8y64xj7.js +4513 -0
- package/dist/v2/{server-6vd2n183.js → server-tnzbk64q.js} +35 -5
- package/dist/v2/{server-v77xa5wj.js → server-tpt7bwq8.js} +1 -1
- package/dist/v2/{server-51779zs2.js → server-v0p37hm2.js} +4 -1
- package/dist/v2/{server-nxas8v1d.js → server-xfjjbrkt.js} +15 -4
- package/dist/v2/{server-cqjvxyrp.js → server-xy7w7hrd.js} +2 -2
- package/dist/v2/server-ypf1ap0v.js +529 -0
- package/dist/v2/server-z4p0ry94.js +222 -0
- package/dist/v2/server-z9zygwse.js +89 -0
- package/dist/v2/{server-ab1g0wn9.js → server-zzgtgqmd.js} +2 -2
- package/dist/v2/server.js +7 -6
- package/dist/v2/{storage-tags-18nbaanf.js → storage-tags-cw07ky67.js} +5 -4
- package/dist/v2/store-reader-cgx47zkp.js +14 -0
- package/dist/v2/store-reader.d.ts +9 -2
- package/dist/v2/store-reader.d.ts.map +1 -1
- package/dist/v2/store-z3qe67cg.js +21 -0
- package/dist/v2/v2-archive-reader-z7wr42ry.js +11 -0
- package/dist/v2/{wrapup-orchestrator-wxf7n5k6.js → wrapup-orchestrator-j1v62bkj.js} +50 -42
- package/dist/v2-archive-reader-028z6kck.js +11 -0
- package/dist/wrapup-orchestrator-xg9avt2p.js +56 -0
- package/package.json +1 -1
- package/src/shared/model-suggestion-retry.ts +1 -1
- package/src/shared/prompt-async-transport.test.ts +64 -3
- package/src/shared/prompt-async-transport.ts +61 -16
- package/src/shared/reusable-worker-entry.ts +58 -0
- package/src/shared/reusable-worker-reset.test.ts +108 -0
- package/src/shared/reusable-worker.fixture.ts +35 -0
- package/src/shared/reusable-worker.test.ts +253 -0
- package/src/shared/reusable-worker.ts +240 -0
- package/src/shared/sqlite-transaction-mode-guard.test.ts +2 -0
- package/src/shared/worker-shutdown.ts +21 -17
- package/dist/embedding-backfill-0jgtqxen.js +0 -25
- package/dist/recomp-orchestrator-0y983w7h.js +0 -62
- package/dist/search-archive-1kw2rp19.js +0 -26
- package/dist/search-p684j8ww.js +0 -50
- package/dist/v2/embedding-backfill-f43hd8y6.js +0 -24
- package/dist/v2/recomp-orchestrator-7q9nvxte.js +0 -61
- package/dist/v2/search-archive-xfp51s0g.js +0 -25
- package/dist/v2/search-wf8rqxhm.js +0 -48
- package/dist/wrapup-orchestrator-ys2nrkkb.js +0 -49
|
@@ -3,7 +3,7 @@ import {
|
|
|
3
3
|
} from "./index-pavzsdc6.js";
|
|
4
4
|
import {
|
|
5
5
|
sessionLog2
|
|
6
|
-
} from "./index-
|
|
6
|
+
} from "./index-jrfre9ah.js";
|
|
7
7
|
import {
|
|
8
8
|
UNKNOWN_FIT_RATIO,
|
|
9
9
|
resolveDecisionCalibration,
|
|
@@ -24,7 +24,7 @@ import {
|
|
|
24
24
|
TAG_SELECT_COLUMNS2,
|
|
25
25
|
getCandidateToolOwners2,
|
|
26
26
|
pickNearestPriorOwner2
|
|
27
|
-
} from "./index-
|
|
27
|
+
} from "./index-8jjjmhab.js";
|
|
28
28
|
import {
|
|
29
29
|
OMO_INTERNAL_INITIATOR_MARKER,
|
|
30
30
|
isSystemDirective,
|
|
@@ -42,18 +42,18 @@ import {
|
|
|
42
42
|
formatBlock,
|
|
43
43
|
compactTextForSummary,
|
|
44
44
|
mergeCommitHashes
|
|
45
|
-
} from "./index-
|
|
45
|
+
} from "./index-4xyjr62e.js";
|
|
46
46
|
import {
|
|
47
47
|
prepareCachedStatement2
|
|
48
48
|
} from "./index-gzy5w8ya.js";
|
|
49
49
|
import {
|
|
50
50
|
stableStringify
|
|
51
|
-
} from "./index-
|
|
51
|
+
} from "./index-9wnbnx8f.js";
|
|
52
52
|
import {
|
|
53
53
|
renderToolTemplate,
|
|
54
54
|
resolveModelConfigValue,
|
|
55
55
|
deriveDefaultProtectedTokens
|
|
56
|
-
} from "./index-
|
|
56
|
+
} from "./index-c5dzns43.js";
|
|
57
57
|
import {
|
|
58
58
|
readRawSessionMessagesFromDb2,
|
|
59
59
|
readRawSessionMessagePageFromDb2,
|
|
@@ -70,25 +70,29 @@ import {
|
|
|
70
70
|
readRawSeedTailFromDb2,
|
|
71
71
|
readRawSessionBoundaryEndpointsFromDb2,
|
|
72
72
|
prewarmRawSessionOrdinalsForDb
|
|
73
|
-
} from "./index-
|
|
73
|
+
} from "./index-r2epb000.js";
|
|
74
74
|
import {
|
|
75
75
|
openCodeDbExists,
|
|
76
76
|
withReadOnlySessionDb,
|
|
77
77
|
getRawSessionMessageCountFromDb,
|
|
78
78
|
getMessageTimesFromOpenCodeDb
|
|
79
|
-
} from "./index-
|
|
79
|
+
} from "./index-vd2ywmfe.js";
|
|
80
80
|
import {
|
|
81
81
|
getToolDefinitionMeasurementSignature,
|
|
82
82
|
getMeasuredToolDefinitionTokens,
|
|
83
83
|
getSessionToolDefinitionTokens
|
|
84
|
-
} from "./index-
|
|
84
|
+
} from "./index-jkanybgq.js";
|
|
85
|
+
import {
|
|
86
|
+
markHostUnservedRow,
|
|
87
|
+
isHostUnservedRow
|
|
88
|
+
} from "./index-z9zygwse.js";
|
|
85
89
|
import {
|
|
86
90
|
canonicalModelIdentity,
|
|
87
91
|
piModelRefToCanonical
|
|
88
92
|
} from "./index-avwt563y.js";
|
|
89
93
|
import {
|
|
90
94
|
logSlowWriteTransaction
|
|
91
|
-
} from "./index-
|
|
95
|
+
} from "./index-fxbk7gk3.js";
|
|
92
96
|
|
|
93
97
|
// src/shared/hidden-zen-read.ts
|
|
94
98
|
function isToolFreeHiddenAgent(agent) {
|
|
@@ -556,92 +560,22 @@ function askAnswerLines(text) {
|
|
|
556
560
|
return extractAskAnswerNotices(text).map(formatAskAnswerNotice);
|
|
557
561
|
}
|
|
558
562
|
|
|
559
|
-
// src/hooks/magic-context/
|
|
560
|
-
|
|
561
|
-
|
|
562
|
-
|
|
563
|
-
value: true,
|
|
564
|
-
enumerable: false,
|
|
565
|
-
configurable: true
|
|
566
|
-
});
|
|
567
|
-
return target;
|
|
568
|
-
}
|
|
569
|
-
function isHostUnservedRow(value) {
|
|
570
|
-
return typeof value === "object" && value !== null && value[HOST_UNSERVED_ROW] === true;
|
|
571
|
-
}
|
|
572
|
-
function retreatPastHostUnservedRows(messages, exclusiveEnd, floor) {
|
|
573
|
-
if (!messages.some(isHostUnservedRow))
|
|
574
|
-
return exclusiveEnd;
|
|
575
|
-
const byOrdinal = new Map(messages.map((message) => [message.ordinal, message]));
|
|
576
|
-
let end = exclusiveEnd;
|
|
577
|
-
while (end - 1 >= floor && isHostUnservedRow(byOrdinal.get(end - 1)))
|
|
578
|
-
end -= 1;
|
|
579
|
-
return end;
|
|
580
|
-
}
|
|
581
|
-
function snapTerminalCompartmentToServedRow(compartments, lines) {
|
|
582
|
-
if (!lines.some(isHostUnservedRow))
|
|
583
|
-
return { compartments: [...compartments], snapped: false };
|
|
584
|
-
const byOrdinal = new Map(lines.map((line) => [line.ordinal, line]));
|
|
585
|
-
const result = [...compartments];
|
|
586
|
-
let snapped = false;
|
|
587
|
-
while (result.length > 0) {
|
|
588
|
-
const last = result[result.length - 1];
|
|
589
|
-
if (!isHostUnservedRow(byOrdinal.get(last.endMessage)))
|
|
590
|
-
break;
|
|
591
|
-
snapped = true;
|
|
592
|
-
let served;
|
|
593
|
-
for (let ordinal = last.endMessage - 1;ordinal >= last.startMessage; ordinal -= 1) {
|
|
594
|
-
const line = byOrdinal.get(ordinal);
|
|
595
|
-
if (line && !isHostUnservedRow(line)) {
|
|
596
|
-
served = line;
|
|
597
|
-
break;
|
|
598
|
-
}
|
|
599
|
-
}
|
|
600
|
-
if (!served) {
|
|
601
|
-
result.pop();
|
|
602
|
-
continue;
|
|
603
|
-
}
|
|
604
|
-
result[result.length - 1] = {
|
|
605
|
-
...last,
|
|
606
|
-
endMessage: served.ordinal,
|
|
607
|
-
endMessageId: served.messageId
|
|
608
|
-
};
|
|
609
|
-
break;
|
|
610
|
-
}
|
|
611
|
-
return { compartments: result, snapped };
|
|
612
|
-
}
|
|
613
|
-
function isHostRenderedSystemMessage(message) {
|
|
614
|
-
const id = message.info.id;
|
|
615
|
-
return (typeof id !== "string" || id.length === 0) && message.info.role === "system";
|
|
616
|
-
}
|
|
617
|
-
var COVERED_INSTRUCTION_ROW = "coveredInstructionRow";
|
|
618
|
-
function markCoveredInstructionRow(target) {
|
|
619
|
-
Object.defineProperty(target, COVERED_INSTRUCTION_ROW, {
|
|
620
|
-
value: true,
|
|
621
|
-
enumerable: false,
|
|
622
|
-
configurable: true
|
|
623
|
-
});
|
|
624
|
-
return target;
|
|
625
|
-
}
|
|
626
|
-
function isCoveredInstructionRow(value) {
|
|
627
|
-
return typeof value === "object" && value !== null && value[COVERED_INSTRUCTION_ROW] === true;
|
|
628
|
-
}
|
|
629
|
-
function takeCoveredInstructionRows(messages) {
|
|
630
|
-
const taken = messages.filter((message) => isCoveredInstructionRow(message.info));
|
|
631
|
-
if (taken.length > 0) {
|
|
632
|
-
const kept = messages.filter((message) => !isCoveredInstructionRow(message.info));
|
|
633
|
-
messages.splice(0, messages.length, ...kept);
|
|
563
|
+
// src/hooks/magic-context/compartment-commit-hashes.ts
|
|
564
|
+
function rawCommitHashes(value) {
|
|
565
|
+
if (typeof value === "string") {
|
|
566
|
+
return Array.from(value.matchAll(/\b[0-9a-f]{7,40}\b/gi), (match) => match[0].toLowerCase());
|
|
634
567
|
}
|
|
635
|
-
|
|
636
|
-
|
|
637
|
-
|
|
638
|
-
|
|
639
|
-
|
|
640
|
-
|
|
641
|
-
|
|
642
|
-
|
|
568
|
+
if (value === null || typeof value !== "object")
|
|
569
|
+
return [];
|
|
570
|
+
return Object.values(value).flatMap(rawCommitHashes);
|
|
571
|
+
}
|
|
572
|
+
function removeUnsupportedCommitHashes(text, supported) {
|
|
573
|
+
return text.replace(/`?\b([0-9a-f]{7,40})\b`?/gi, (token, hash) => {
|
|
574
|
+
const normalized = hash.toLowerCase();
|
|
575
|
+
if (!/[a-f]/.test(normalized))
|
|
576
|
+
return token;
|
|
577
|
+
return Array.from(supported).some((source) => source.startsWith(normalized)) ? token : "";
|
|
643
578
|
});
|
|
644
|
-
return copy;
|
|
645
579
|
}
|
|
646
580
|
|
|
647
581
|
// src/hooks/magic-context/read-session-true-raw-tokens.ts
|
|
@@ -717,7 +651,7 @@ function looksImageLike(part) {
|
|
|
717
651
|
const type = typeof part.type === "string" ? part.type.toLowerCase() : "";
|
|
718
652
|
const mime = typeof part.mime === "string" ? part.mime.toLowerCase() : "";
|
|
719
653
|
const mediaType = typeof part.mediaType === "string" ? part.mediaType.toLowerCase() : "";
|
|
720
|
-
return type.includes("image") || mime.startsWith("image/") || mediaType.startsWith("image/") || part.image_url !== undefined || part.imageUrl !== undefined || part.image !== undefined;
|
|
654
|
+
return type.includes("image") || mime.startsWith("image/") || mediaType.startsWith("image/") || part.image_url !== undefined || part.imageUrl !== undefined || part.image !== undefined || type.includes("file") && (typeof part.url === "string" && part.url.startsWith("data:image/") || typeof part.data === "string" && /^(?:data:image\/|\/9j\/|iVBORw0KGgo|R0lGOD)/.test(part.data));
|
|
721
655
|
}
|
|
722
656
|
function defaultImageTokenHeuristic(part) {
|
|
723
657
|
if (isRecord(part)) {
|
|
@@ -1081,7 +1015,7 @@ function buildTrueRawTokenIndex(sessionId, messages, options) {
|
|
|
1081
1015
|
} else {
|
|
1082
1016
|
const raw = tokenForMessage(message, options);
|
|
1083
1017
|
const seed = options.calibration;
|
|
1084
|
-
total = seed ? (raw.toolInput + raw.toolOutput) * seed.toolsRatio + (raw.text + raw.reasoning + raw.other) * seed.proseRatio + raw.image : raw.total;
|
|
1018
|
+
total = options.measure === "summary-removed" ? raw.text * (seed?.proseRatio ?? 1) + raw.toolInput * (seed?.toolsRatio ?? 1) : seed ? (raw.toolInput + raw.toolOutput) * seed.toolsRatio + (raw.text + raw.reasoning + raw.other) * seed.proseRatio + raw.image : raw.total;
|
|
1085
1019
|
}
|
|
1086
1020
|
tokensByOrdinal.set(message.ordinal, total);
|
|
1087
1021
|
idsByOrdinal.set(message.ordinal, message.id);
|
|
@@ -1362,6 +1296,78 @@ function applyEditMarkerToInput(input) {
|
|
|
1362
1296
|
}
|
|
1363
1297
|
}
|
|
1364
1298
|
|
|
1299
|
+
// src/hooks/magic-context/final-wire-completeness.ts
|
|
1300
|
+
function incompleteWirePartFields(part) {
|
|
1301
|
+
if (!part || typeof part !== "object")
|
|
1302
|
+
return ["part"];
|
|
1303
|
+
const p = part;
|
|
1304
|
+
if (p.ignored === true)
|
|
1305
|
+
return [];
|
|
1306
|
+
const missing = (present, field) => present ? [] : [field];
|
|
1307
|
+
switch (p.type) {
|
|
1308
|
+
case "text":
|
|
1309
|
+
case "reasoning":
|
|
1310
|
+
return missing(typeof p.text === "string", "text");
|
|
1311
|
+
case "thinking":
|
|
1312
|
+
return missing(typeof p.thinking === "string", "thinking");
|
|
1313
|
+
case "redacted_thinking":
|
|
1314
|
+
return missing(typeof p.data === "string", "data");
|
|
1315
|
+
case "tool": {
|
|
1316
|
+
const state = p.state !== null && typeof p.state === "object" ? p.state : undefined;
|
|
1317
|
+
const input = state?.input !== undefined || p.input !== undefined || p.args !== undefined;
|
|
1318
|
+
const result = state?.output !== undefined || state?.content !== undefined || state?.error !== undefined || p.output !== undefined || p.result !== undefined || p.content !== undefined;
|
|
1319
|
+
return [...missing(input, "input"), ...missing(result, "result")];
|
|
1320
|
+
}
|
|
1321
|
+
case "tool-call":
|
|
1322
|
+
case "tool_use":
|
|
1323
|
+
return missing(p.input !== undefined || p.args !== undefined, "input");
|
|
1324
|
+
case "tool-invocation":
|
|
1325
|
+
return [
|
|
1326
|
+
...missing(p.args !== undefined || p.input !== undefined, "input"),
|
|
1327
|
+
...missing(p.result !== undefined || p.output !== undefined || p.state !== null && typeof p.state === "object", "result")
|
|
1328
|
+
];
|
|
1329
|
+
case "tool-result":
|
|
1330
|
+
case "tool_result":
|
|
1331
|
+
return missing(p.result !== undefined || p.content !== undefined || p.output !== undefined, "result");
|
|
1332
|
+
case "step-start":
|
|
1333
|
+
case "step-finish":
|
|
1334
|
+
return [];
|
|
1335
|
+
case "file":
|
|
1336
|
+
return missing(typeof p.url === "string" && p.url.startsWith("data:image/"), "url (data:image/)");
|
|
1337
|
+
default:
|
|
1338
|
+
return ["supported type"];
|
|
1339
|
+
}
|
|
1340
|
+
}
|
|
1341
|
+
function label(value) {
|
|
1342
|
+
return typeof value === "string" ? value.replace(/[^a-zA-Z0-9_.-]/g, "_").slice(0, 128) : null;
|
|
1343
|
+
}
|
|
1344
|
+
function incompleteWireParts(messages) {
|
|
1345
|
+
return messages.flatMap((message) => message.parts.flatMap((part, partIndex) => {
|
|
1346
|
+
const missingFields = incompleteWirePartFields(part);
|
|
1347
|
+
if (!missingFields.length)
|
|
1348
|
+
return [];
|
|
1349
|
+
const p = part && typeof part === "object" ? part : undefined;
|
|
1350
|
+
return [
|
|
1351
|
+
{
|
|
1352
|
+
messageId: label(message.info.id),
|
|
1353
|
+
partId: label(p?.id),
|
|
1354
|
+
partIndex,
|
|
1355
|
+
type: label(p?.type) ?? "unknown",
|
|
1356
|
+
missingFields
|
|
1357
|
+
}
|
|
1358
|
+
];
|
|
1359
|
+
}));
|
|
1360
|
+
}
|
|
1361
|
+
function createFinalWireIncompleteLogger(sessionID) {
|
|
1362
|
+
let logged = false;
|
|
1363
|
+
return (estimate, messages) => {
|
|
1364
|
+
if (logged || estimate?.trusted)
|
|
1365
|
+
return;
|
|
1366
|
+
logged = true;
|
|
1367
|
+
sessionLog2(sessionID, `transform: final-wire untrusted incompleteParts=${JSON.stringify(incompleteWireParts(messages))}`);
|
|
1368
|
+
};
|
|
1369
|
+
}
|
|
1370
|
+
|
|
1365
1371
|
// src/features/magic-context/merged-reasoning-decisions.ts
|
|
1366
1372
|
var MERGED_REASONING_PARTS_PREFIX = "__merged_reasoning_parts_v1__:";
|
|
1367
1373
|
var decodedDecisions = new Map;
|
|
@@ -4138,12 +4144,6 @@ function getSessionsWithPendingMarker(db) {
|
|
|
4138
4144
|
AND pending_compaction_marker_state != ''`).all();
|
|
4139
4145
|
return rows.map((r) => r.session_id);
|
|
4140
4146
|
}
|
|
4141
|
-
function setSessionWorkMetrics(db, sessionId, newWorkTokens, totalInputTokens) {
|
|
4142
|
-
ensureSessionMetaRow(db, sessionId);
|
|
4143
|
-
db.prepare(`UPDATE session_meta
|
|
4144
|
-
SET new_work_tokens = ?, total_input_tokens = ?
|
|
4145
|
-
WHERE session_id = ?`).run(Math.max(0, Math.floor(newWorkTokens)), Math.max(0, Math.floor(totalInputTokens)), sessionId);
|
|
4146
|
-
}
|
|
4147
4147
|
var preSnapshotSessions = new Map;
|
|
4148
4148
|
var warnedProtectedTokenTierOverrides = new WeakSet;
|
|
4149
4149
|
function isPreSnapshotMemo(value) {
|
|
@@ -4355,6 +4355,8 @@ var OVERFLOW_PATTERNS = [
|
|
|
4355
4355
|
/request entity too large/i,
|
|
4356
4356
|
/context length is only \d+ tokens/i,
|
|
4357
4357
|
/input length.*exceeds.*context length/i,
|
|
4358
|
+
/\bContextWindowExceededError\b/i,
|
|
4359
|
+
/\bthe input \(\d+ tokens?\) is longer than the model's context length \(\d+ tokens?\)/i,
|
|
4358
4360
|
/prompt too long; exceeded (?:max )?context length/i,
|
|
4359
4361
|
/too large for model with \d+ maximum context length/i,
|
|
4360
4362
|
/model_context_window_exceeded/i,
|
|
@@ -4377,6 +4379,10 @@ var LIMIT_EXTRACTION_PATTERNS = [
|
|
|
4377
4379
|
},
|
|
4378
4380
|
{ pattern: /context size[^0-9]{0,40}(\d{4,})\s*tokens?/i, provenance: "combined" },
|
|
4379
4381
|
{ pattern: /exceeds? the context length of (\d+)/i, provenance: "combined" },
|
|
4382
|
+
{
|
|
4383
|
+
pattern: /\bthe input \(\d+ tokens?\) is longer than the model's context length \((\d+) tokens?\)/i,
|
|
4384
|
+
provenance: "combined"
|
|
4385
|
+
},
|
|
4380
4386
|
{
|
|
4381
4387
|
pattern: />\s*(\d+)\s*(?:tokens?\s*)?(?:maximum|max|limit)\b/i,
|
|
4382
4388
|
provenance: "prompt_only"
|
|
@@ -4515,7 +4521,9 @@ function parseReportedInputTokens(message) {
|
|
|
4515
4521
|
/input token count\s*\(?\s*(\d+)/i,
|
|
4516
4522
|
/input length\s*(\d+)/i,
|
|
4517
4523
|
/prompt was\s*(\d+)/i,
|
|
4518
|
-
/messages resulted in\s*(\d+)\s*tokens?/i
|
|
4524
|
+
/messages resulted in\s*(\d+)\s*tokens?/i,
|
|
4525
|
+
/\bthe input \((\d+) tokens?\) is longer than the model's context length \(\d+ tokens?\)/i,
|
|
4526
|
+
/\(\s*(\d+)\s+in the messages,\s*\d+\s+in the completion\s*\)/i
|
|
4519
4527
|
];
|
|
4520
4528
|
for (const pattern of patterns) {
|
|
4521
4529
|
const raw = message.match(pattern)?.[1];
|
|
@@ -6109,45 +6117,7 @@ function estimateAppendedWireTokens(input) {
|
|
|
6109
6117
|
};
|
|
6110
6118
|
}
|
|
6111
6119
|
function hasCountableParts(message) {
|
|
6112
|
-
return message.parts.every((part) =>
|
|
6113
|
-
if (!part || typeof part !== "object")
|
|
6114
|
-
return false;
|
|
6115
|
-
const p = part;
|
|
6116
|
-
if (p.ignored === true)
|
|
6117
|
-
return true;
|
|
6118
|
-
switch (p.type) {
|
|
6119
|
-
case "text":
|
|
6120
|
-
case "reasoning":
|
|
6121
|
-
return typeof p.text === "string";
|
|
6122
|
-
case "thinking":
|
|
6123
|
-
return typeof p.thinking === "string";
|
|
6124
|
-
case "redacted_thinking":
|
|
6125
|
-
return typeof p.data === "string";
|
|
6126
|
-
case "tool": {
|
|
6127
|
-
const state = p.state !== null && typeof p.state === "object" ? p.state : undefined;
|
|
6128
|
-
const hasInput = state?.input !== undefined || p.input !== undefined || p.args !== undefined;
|
|
6129
|
-
const hasResult = state?.output !== undefined || state?.content !== undefined || state?.error !== undefined || p.output !== undefined || p.result !== undefined || p.content !== undefined;
|
|
6130
|
-
return hasInput && hasResult;
|
|
6131
|
-
}
|
|
6132
|
-
case "tool-call":
|
|
6133
|
-
return p.input !== undefined || p.args !== undefined;
|
|
6134
|
-
case "tool-invocation":
|
|
6135
|
-
return (p.args !== undefined || p.input !== undefined) && (p.result !== undefined || p.output !== undefined || p.state !== null && typeof p.state === "object");
|
|
6136
|
-
case "tool-result":
|
|
6137
|
-
return p.result !== undefined || p.content !== undefined || p.output !== undefined;
|
|
6138
|
-
case "tool_use":
|
|
6139
|
-
return p.input !== undefined || p.args !== undefined;
|
|
6140
|
-
case "tool_result":
|
|
6141
|
-
return p.content !== undefined || p.result !== undefined || p.output !== undefined;
|
|
6142
|
-
case "step-start":
|
|
6143
|
-
case "step-finish":
|
|
6144
|
-
return true;
|
|
6145
|
-
case "file":
|
|
6146
|
-
return typeof p.url === "string" && p.url.startsWith("data:image/");
|
|
6147
|
-
default:
|
|
6148
|
-
return false;
|
|
6149
|
-
}
|
|
6150
|
-
});
|
|
6120
|
+
return message.parts.every((part) => incompleteWirePartFields(part).length === 0);
|
|
6151
6121
|
}
|
|
6152
6122
|
|
|
6153
6123
|
// src/hooks/magic-context/tool-input-size.ts
|
|
@@ -6656,6 +6626,13 @@ function resolveHostServedBoundaryId2(sessionId, messageId) {
|
|
|
6656
6626
|
function hasRawMessageProvider2(sessionId) {
|
|
6657
6627
|
return sessionProviders.has(sessionId);
|
|
6658
6628
|
}
|
|
6629
|
+
function rawMessageWorkerSource2(sessionId) {
|
|
6630
|
+
return sessionProviders.get(sessionId)?.provider.workerSource;
|
|
6631
|
+
}
|
|
6632
|
+
function rawMessageOffThreadRangeReader2(sessionId) {
|
|
6633
|
+
const provider = sessionProviders.get(sessionId)?.provider;
|
|
6634
|
+
return provider?.readMessageIdOrdinalsForRangeOffThread?.bind(provider);
|
|
6635
|
+
}
|
|
6659
6636
|
function setRawMessageProvider2(sessionId, provider) {
|
|
6660
6637
|
const current = sessionProviders.get(sessionId);
|
|
6661
6638
|
const registration = current?.provider === provider ? current : { provider, scopes: 0 };
|
|
@@ -7442,7 +7419,12 @@ function readSessionChunk2(sessionId, tokenBudget, offset = 1, eligibleEndOrdina
|
|
|
7442
7419
|
}
|
|
7443
7420
|
if (msg.ordinal < startOrdinal)
|
|
7444
7421
|
continue;
|
|
7445
|
-
const
|
|
7422
|
+
const commitHashes = rawCommitHashes(msg.parts);
|
|
7423
|
+
const meta = {
|
|
7424
|
+
ordinal: msg.ordinal,
|
|
7425
|
+
messageId: msg.id
|
|
7426
|
+
};
|
|
7427
|
+
Object.defineProperty(meta, "commitHashes", { value: commitHashes });
|
|
7446
7428
|
if (isHostUnservedRow(msg))
|
|
7447
7429
|
markHostUnservedRow(meta);
|
|
7448
7430
|
if (msg.role === "system") {
|
|
@@ -7620,4 +7602,4 @@ function readRawSessionSeedTail2(sessionId, boundaryId, onQuery) {
|
|
|
7620
7602
|
});
|
|
7621
7603
|
}
|
|
7622
7604
|
|
|
7623
|
-
export { isToolFreeHiddenAgent, TOOL_USE_DISABLED, ZEN_READ_AGENT_SUFFIX, needsBlockedRead, withBlockedReadInstruction, rememberV1HiddenRun, shapeV1HiddenMessage, expandToolPart, askAnswerLines,
|
|
7605
|
+
export { isToolFreeHiddenAgent, TOOL_USE_DISABLED, ZEN_READ_AGENT_SUFFIX, needsBlockedRead, withBlockedReadInstruction, rememberV1HiddenRun, shapeV1HiddenMessage, expandToolPart, askAnswerLines, removeUnsupportedCommitHashes, completedToolArcCrossesBoundary, estimateTrueRawMessageTokens, buildToolArcs, fenceBoundaryForCompletedToolArcs, fenceBoundaryForToolArcs, buildTrueRawTokenIndex, computeRawRangeFingerprint, invalidateTrueRawTokenCache, stripSystemInjection, isTextPart, isToolPartWithOutput, isFilePart, toolPartHasUserAnswer, DreamTokenBudgetExceeded, TOKEN_BUDGET_FINALIZE_MESSAGE, registerBudgetFinalizeChild, releaseBudgetFinalizeChild, createDreamTokenBudget, recordToolParameters, createDroppedInputGuard, assertExecutableToolInput, createDroppedInputToolExecuteBeforeHook, isEditTool, createFinalWireIncompleteLogger, MERGED_REASONING_PARTS_PREFIX, decodeMergedReasoningParts, MAX_EXECUTE_THRESHOLD, escalationBands, HYGIENE_PROVIDER_UNITS_VERSION, sessionDecisionCalibration, transitionSessionHygieneUnits, readEpochFloorSnapshot, getProtectionWindowForSession, SESSION_META_SELECT_COLUMNS, META_COLUMNS, BOOLEAN_META_KEYS, NULL_BIND_META_KEYS, isSessionMetaRow, getDefaultSessionMeta, ensureSessionMetaRow, toSessionMeta, persistCachedM0, clearCachedM0M1, clearCachedM0, withReplayEnvelopeSnapshot, invalidateReplayEnvelopeSnapshot, isRustMarkerAdmissionFenced, setRustMarkerAdmissionFence, ReplayDocumentError, readReplayEnvelope, readReplayDocument, updateReplayDocument, writeReplayDocument, isEmergencyRecoveryArmed, isProviderOverflowReconfirmed, isProviderOverflowFailClosedProven, getEmergencyRecoveryArmedAt, describeProtectedTailDrainBudgetSkip, loadPersistedUsage, loadProtectedTailMeta, markProtectedTailPolicyV3Seeded, recordProtectedTailPublicationFloor, recordProtectedTailNoEligibleHead, resetProtectedTailNoEligibleHead, getWrapupInProgressState, isWrapupInProgress, acquireWrapupInProgress, updateWrapupInProgress, releaseWrapupInProgress, resolveCompactionModeRecord, getCompactionModeRecord, setCompactionModeRecord, getProtectedTailDrainBudgetSkip, reserveProtectedTailDrainTokens, clearEmergencyDrainLatch, recordHistorianDrainFailure, clearHistorianDrainFailure, rollbackProtectedTailDrainReservation, getPersistedReasoningWatermark, setPersistedReasoningWatermark, clearPersistedReasoningWatermark, getEmergencyInputSample, setEmergencyDropSample, clearEmergencyDropSample, getLastNudgeUndropped, setLastNudgeUndropped, getChannel1NudgeState, setChannel1NudgeState, markChannel1PostReduceGracePending, captureChannel1PostReduceGraceBaseline, getChannel2NudgeState, getChannel2NudgeClaim, setChannel2NudgeState, casChannel2NudgeState, claimChannel2NudgeState, casChannel2NudgeClaim, getPersistedNoteNudge, setPersistedNoteNudgeTrigger, setPersistedNoteNudgeTriggerMessageId, getNoteNudgeAnchors, getAutoSearchHintDecisions, deliverNoteNudgeAtomic, appendAutoSearchHintDecision, pruneNoteNudgeAnchors, removeNoteNudgeAnchorByMessageId, queueAutoSearchHintDecisionRetirement, flushAutoSearchHintDecisionRetirement, removeAutoSearchHintDecisionByMessageId, getPersistedTodoPermissionDenied, setPersistedTodoPermissionDenied, getPersistedTodoSyntheticAnchor, setPersistedTodoSyntheticAnchor, clearPersistedTodoSyntheticAnchor, getNoteLastReadAt, setNoteLastReadAt, getHistorianFailureState, incrementHistorianFailure, clearHistorianFailureState, getOverflowState, loadTransformPassStateSnapshot, recordOverflowDetected, recordDetectedContextLimit, clearEmergencyRecovery, clearDetectedContextLimit, getPersistedCompactionMarkerState, getCompactionMarkerPublicationState, compareAndSetCompactionMarkerPublicationState, setPersistedCompactionMarkerState, getDeferredClearedCompactionMarkerState, retireDeferredClearedCompactionMarkerState, parseStrippedPlaceholderState, serializeStrippedPlaceholderState, getStrippedPlaceholderIds, applyStrippedPlaceholderDelta, removeStrippedPlaceholderId, THINKING_BINDING_RECOVERY_FROZEN_PREFIX, THINKING_BINDING_STRIP_ORDER_END_MARKER, thinkingBindingRecoveryFrozenId, COMPACTION_OFF_THINKING_FROZEN_PREFIX, compactionOffThinkingFrozenId, compactionOffFrozenThinkingIds, getThinkingBindingRecoveryTarget, armThinkingBindingRecovery, clearThinkingBindingRecoveryIf, getMergedReasoningStrippedIds, addMergedReasoningStrippedIds, getTrailingBlankDecisions, addTrailingBlankDecisions, demoteTrailingBlankKeepDecisions, getStaleReduceStrippedIds, addStaleReduceStrippedIds, getProcessedImageStrippedIds, parseProcessedImageMarkers, serializeProcessedImageMarkers, getProcessedImageMarkers, addProcessedImageStrippedIds, getPendingCompactionMarkerState, getCompactionMarkerHealth, loadPostprocessReplaySnapshot, setPendingCompactionMarkerState, replacePendingCompactionMarkerStateIf, clearPendingCompactionMarkerStateIf, getPendingPiCompactionMarkerState, clearPendingPiCompactionMarkerStateIf, logPiCompactionMarkerClear, getSessionsWithPendingMarker, getObservedEpochFloor, resolveEpochFloorForPass, getReasoningRemovalState, addRemovedReasoningIds, markDropLeavesReasoning, detectThinkingBindingMismatch, detectLatestTurnThinkingMismatch, isPrefixBoundThinkingModel, detectOverflow, modelAcceptsEmptyContent, isAnthropicFamilyRoute, neutralizeDroppedReasoningPart, restoreNeutralizedReasoningPart, isNeutralizedReasoningPart, variantChangeBustsProviderCache, makeSentinel, makeWholeMessageSentinel, isSentinel, replaySentinelByMessageIds, isInActiveAnthropicTurn, activeAnthropicTurnStart, hasAnthropicReasoning, markServedShapeRepair, prepareServedShapeRepair, stripSystemInjectedMessages, stripDroppedPlaceholderMessages, replayClearedReasoning, replayStrippedInlineThinking, clearOldReasoning, stripClearedReasoning, captureInlineThinkingRepairs, stripInlineThinking, findReasoningBearingAssistantIds, findLatestAssistantReasoningMutationExemptMessage, snapshotTrailingBlankSourceDecisions, findTrailingBlankDecisionCandidates, applyFrozenTrailingBlankDecisions, stripReasoningFromAssistantIds, findMergedReasoningStripDecisions, stripReasoningFromMergedAssistants, getEmptyImageParts, stripProcessedImages, projectOpencodeReasoningBudgetCutoff, DEFAULT_KEEP_REASONING_TOKENS, resolveKeepReasoningTokens, reasoningStepCost, reasoningBudgetCutoff, reasoningTextAndOpaque, opencodeReasoningBudgetCutoff, describeFinalWireTail, estimatePartImageTokens, estimateMessageTokens, wireContentBytes, createFinalWireUsageTracker, estimateFinalWireInputTokens, estimateAppendedWireTokens, SKELETON_REAL_INPUT_MAX_BYTES, partHasCompletedResult, extractToolCallObservation, ToolMutationBatch, createToolDropTarget, resolveHostServedBoundaryId2, hasRawMessageProvider2, rawMessageWorkerSource2, rawMessageOffThreadRangeReader2, setRawMessageProvider2, setBoundedRawMessageProvider2, withRawMessageProvider2, cleanUserText2, withRawSessionMessageCache2, readRawSessionMessages2, readRawSessionMessagePage2, getRawSessionMessageOrdinalCount2, RAW_MESSAGE_VISIT_PAGE_SIZE2, visitRawSessionMessages2, visitRawSessionMessagesAsync2, readRawSessionMessageRange2, prepareRawSessionOrdinals2, primeTailRawMessageCache2, getCachedAbsoluteMessageCount2, primeInMemoryTailRawMessageCache2, readRawSessionMessageOrdinalPage2, getRawSessionStoredMessageCount2, readRawSessionMessageIdOrdinalsForRange2, readRawSessionMessageIdOrdinals2, readRawSessionMessagePartsById2, readRawSessionBoundaryEndpoints2, hasRawSessionMessageById2, readRawSessionMessageOrdinalById2, resolveHistorianChunkStart2, compareRawSessionMessageOrder2, readRawSessionMessageById2, getRawSessionMessageCount2, RAW_SESSION_TAG_KEY_PAGE_SIZE2, getRawSessionTagKeysThrough2, getLegacyProtectedTailStartOrdinal2, getProtectedTailStartOrdinal2, readSessionChunk2, getRawSessionMessageIdsThrough2, readRawSessionSeedTail2 };
|
|
@@ -1,21 +1,21 @@
|
|
|
1
1
|
import {
|
|
2
2
|
DEFAULT_LOCAL_EMBEDDING_MODEL
|
|
3
|
-
} from "./index-
|
|
3
|
+
} from "./index-c5dzns43.js";
|
|
4
4
|
import {
|
|
5
5
|
log2
|
|
6
|
-
} from "./index-
|
|
6
|
+
} from "./index-jrfre9ah.js";
|
|
7
7
|
import {
|
|
8
8
|
isSynapseEmbeddingTruncated,
|
|
9
9
|
SynapseEmbeddingProvider
|
|
10
|
-
} from "./index-
|
|
10
|
+
} from "./index-g4t7850m.js";
|
|
11
11
|
import {
|
|
12
12
|
LocalEmbeddingProvider
|
|
13
|
-
} from "./index-
|
|
13
|
+
} from "./index-xd2p95m7.js";
|
|
14
14
|
import {
|
|
15
15
|
OpenAICompatibleEmbeddingProvider,
|
|
16
16
|
getProjectEmbeddingSnapshot2,
|
|
17
17
|
embedBatchForProject2
|
|
18
|
-
} from "./index-
|
|
18
|
+
} from "./index-21fgrfrf.js";
|
|
19
19
|
import {
|
|
20
20
|
isEmbeddingHostBusy2
|
|
21
21
|
} from "./index-qt1qqasc.js";
|
|
@@ -4,7 +4,7 @@ import {
|
|
|
4
4
|
} from "./index-pavzsdc6.js";
|
|
5
5
|
import {
|
|
6
6
|
log2
|
|
7
|
-
} from "./index-
|
|
7
|
+
} from "./index-jrfre9ah.js";
|
|
8
8
|
import {
|
|
9
9
|
resolveOpenCodeDbPath,
|
|
10
10
|
assertOpenCodeStoreGeneration,
|
|
@@ -19,7 +19,7 @@ import {
|
|
|
19
19
|
import {
|
|
20
20
|
forgetRawSessionOrdinalWatermark2,
|
|
21
21
|
forgetRawSessionSummaryRows2
|
|
22
|
-
} from "./index-
|
|
22
|
+
} from "./index-r2epb000.js";
|
|
23
23
|
import {
|
|
24
24
|
closeQuietly
|
|
25
25
|
} from "./index-8ajstryz.js";
|