@cortexkit/opencode-magic-context 0.45.0 → 0.46.1
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 +26 -0
- package/dist/{announcement-f75t58v9.js → announcement-y35wzg2r.js} +1 -1
- package/dist/config/index.d.ts.map +1 -1
- package/dist/config/live-run-config.d.ts.map +1 -1
- package/dist/config/migrate-config-location.d.ts.map +1 -1
- package/dist/config/schema/magic-context.d.ts +13 -7
- package/dist/config/schema/magic-context.d.ts.map +1 -1
- package/dist/{conflict-warning-hook-5yrz2r24.js → conflict-warning-hook-7fj2b9jw.js} +6 -5
- package/dist/context-sh2m2vde.js +4525 -0
- package/dist/{derive-budgets-a63zsm5c.js → derive-budgets-7nj7r1rv.js} +2 -2
- package/dist/embedding-worker.js +4 -4
- package/dist/features/magic-context/checkout-claim-fake-subc.test-support.d.ts +45 -0
- package/dist/features/magic-context/checkout-claim-fake-subc.test-support.d.ts.map +1 -0
- package/dist/features/magic-context/checkout-claim.d.ts +155 -0
- package/dist/features/magic-context/checkout-claim.d.ts.map +1 -0
- package/dist/features/magic-context/compaction-marker.d.ts +20 -3
- package/dist/features/magic-context/compaction-marker.d.ts.map +1 -1
- package/dist/features/magic-context/compartment-storage.d.ts +23 -2
- package/dist/features/magic-context/compartment-storage.d.ts.map +1 -1
- package/dist/features/magic-context/dreamer/classify.d.ts.map +1 -1
- package/dist/features/magic-context/dreamer/evaluate-smart-notes.d.ts.map +1 -1
- package/dist/features/magic-context/dreamer/provider-output-failure.d.ts +6 -2
- package/dist/features/magic-context/dreamer/provider-output-failure.d.ts.map +1 -1
- package/dist/features/magic-context/dreamer/provider-output-failure.test-support.d.ts +30 -0
- package/dist/features/magic-context/dreamer/provider-output-failure.test-support.d.ts.map +1 -0
- package/dist/features/magic-context/dreamer/storage-dream-runs.d.ts.map +1 -1
- package/dist/features/magic-context/dreamer/task-executor.d.ts +9 -0
- package/dist/features/magic-context/dreamer/task-executor.d.ts.map +1 -1
- package/dist/features/magic-context/dreamer/task-gates.d.ts.map +1 -1
- package/dist/features/magic-context/dreamer/task-scheduler.d.ts.map +1 -1
- package/dist/features/magic-context/dreamer/verify-diff.d.ts.map +1 -1
- package/dist/features/magic-context/dreamer/verify-gate.d.ts.map +1 -1
- package/dist/features/magic-context/dreamer/verify.d.ts.map +1 -1
- package/dist/features/magic-context/git-commits/search-git-commits.d.ts.map +1 -1
- package/dist/features/magic-context/memory/embedding-local.d.ts.map +1 -1
- package/dist/features/magic-context/memory/project-identity-cache.d.ts.map +1 -1
- package/dist/features/magic-context/memory/storage-memory-verifications.d.ts.map +1 -1
- package/dist/features/magic-context/memory/storage-memory.d.ts +3 -0
- package/dist/features/magic-context/memory/storage-memory.d.ts.map +1 -1
- package/dist/features/magic-context/memory/verification-paths.d.ts +2 -2
- package/dist/features/magic-context/memory/verification-paths.d.ts.map +1 -1
- package/dist/features/magic-context/merged-reasoning-decisions.d.ts.map +1 -1
- package/dist/features/magic-context/message-index-async.d.ts +3 -3
- package/dist/features/magic-context/message-index-async.d.ts.map +1 -1
- package/dist/features/magic-context/message-index.d.ts +2 -0
- package/dist/features/magic-context/message-index.d.ts.map +1 -1
- package/dist/features/magic-context/migration-v95-perf-indexes.d.ts +12 -0
- package/dist/features/magic-context/migration-v95-perf-indexes.d.ts.map +1 -0
- package/dist/features/magic-context/migration-worker-client.d.ts +4 -4
- package/dist/features/magic-context/migration-worker-client.d.ts.map +1 -1
- package/dist/features/magic-context/migrations.d.ts +1 -0
- package/dist/features/magic-context/migrations.d.ts.map +1 -1
- package/dist/features/magic-context/mural/render-trigger.d.ts.map +1 -1
- package/dist/features/magic-context/mural/resolve-mural.d.ts +15 -4
- package/dist/features/magic-context/mural/resolve-mural.d.ts.map +1 -1
- package/dist/features/magic-context/mural/source-revision.d.ts +7 -0
- package/dist/features/magic-context/mural/source-revision.d.ts.map +1 -0
- package/dist/features/magic-context/mural/storage-mural-cues.d.ts.map +1 -1
- package/dist/features/magic-context/reclaim-protection.d.ts +15 -10
- package/dist/features/magic-context/reclaim-protection.d.ts.map +1 -1
- package/dist/features/magic-context/session-cache-ttl.d.ts +4 -2
- package/dist/features/magic-context/session-cache-ttl.d.ts.map +1 -1
- package/dist/features/magic-context/smart-notes/capabilities.d.ts +3 -0
- package/dist/features/magic-context/smart-notes/capabilities.d.ts.map +1 -1
- package/dist/features/magic-context/smart-notes/compiler.d.ts.map +1 -1
- package/dist/features/magic-context/smart-notes/github-token.d.ts +5 -0
- package/dist/features/magic-context/smart-notes/github-token.d.ts.map +1 -0
- package/dist/features/magic-context/smart-notes/runner.d.ts +1 -0
- package/dist/features/magic-context/smart-notes/runner.d.ts.map +1 -1
- package/dist/features/magic-context/smart-notes/sandbox-runner.d.ts +12 -0
- package/dist/features/magic-context/smart-notes/sandbox-runner.d.ts.map +1 -1
- package/dist/features/magic-context/smart-notes/ssrf-guard.d.ts +6 -0
- package/dist/features/magic-context/smart-notes/ssrf-guard.d.ts.map +1 -1
- package/dist/features/magic-context/smart-notes/storage.d.ts.map +1 -1
- package/dist/features/magic-context/smart-notes/types.d.ts +2 -0
- package/dist/features/magic-context/smart-notes/types.d.ts.map +1 -1
- package/dist/features/magic-context/storage-clone.d.ts.map +1 -1
- package/dist/features/magic-context/storage-db.d.ts +6 -9
- package/dist/features/magic-context/storage-db.d.ts.map +1 -1
- package/dist/features/magic-context/storage-meta-shared.d.ts +1 -1
- package/dist/features/magic-context/storage-meta-shared.d.ts.map +1 -1
- package/dist/features/magic-context/storage-ops.d.ts +8 -1
- package/dist/features/magic-context/storage-ops.d.ts.map +1 -1
- package/dist/features/magic-context/storage-replay-document.d.ts +7 -0
- package/dist/features/magic-context/storage-replay-document.d.ts.map +1 -1
- package/dist/features/magic-context/storage-schema-helpers.d.ts +2 -0
- package/dist/features/magic-context/storage-schema-helpers.d.ts.map +1 -1
- package/dist/features/magic-context/storage-session-tables.d.ts.map +1 -1
- package/dist/features/magic-context/storage-source.d.ts.map +1 -1
- package/dist/features/magic-context/storage-tags.d.ts +11 -3
- package/dist/features/magic-context/storage-tags.d.ts.map +1 -1
- package/dist/features/magic-context/storage.d.ts +2 -2
- package/dist/features/magic-context/storage.d.ts.map +1 -1
- package/dist/features/magic-context/temporal-decisions.d.ts +10 -0
- package/dist/features/magic-context/temporal-decisions.d.ts.map +1 -0
- package/dist/features/magic-context/tool-definition-tokens.d.ts +2 -0
- package/dist/features/magic-context/tool-definition-tokens.d.ts.map +1 -1
- package/dist/features/magic-context/transform-decision-log.d.ts.map +1 -1
- package/dist/features/magic-context/types.d.ts +7 -6
- package/dist/features/magic-context/types.d.ts.map +1 -1
- package/dist/features/magic-context/window-report-ledger.d.ts.map +1 -1
- package/dist/hooks/auto-update-checker/index.d.ts.map +1 -1
- package/dist/hooks/magic-context/apply-operations.d.ts +8 -0
- package/dist/hooks/magic-context/apply-operations.d.ts.map +1 -1
- package/dist/hooks/magic-context/cache-busting-signals.d.ts +6 -3
- package/dist/hooks/magic-context/cache-busting-signals.d.ts.map +1 -1
- package/dist/hooks/magic-context/channel2-cycle.d.ts +2 -0
- package/dist/hooks/magic-context/channel2-cycle.d.ts.map +1 -1
- package/dist/hooks/magic-context/compaction-marker-manager.d.ts +7 -0
- package/dist/hooks/magic-context/compaction-marker-manager.d.ts.map +1 -1
- package/dist/hooks/magic-context/compartment-prompt.d.ts +2 -2
- package/dist/hooks/magic-context/compartment-prompt.d.ts.map +1 -1
- package/dist/hooks/magic-context/compartment-render-epoch.d.ts +8 -0
- package/dist/hooks/magic-context/compartment-render-epoch.d.ts.map +1 -1
- package/dist/hooks/magic-context/compartment-runner-drop-queue.d.ts +18 -4
- package/dist/hooks/magic-context/compartment-runner-drop-queue.d.ts.map +1 -1
- package/dist/hooks/magic-context/compartment-runner-incremental.d.ts.map +1 -1
- package/dist/hooks/magic-context/compartment-runner-partial-recomp.d.ts.map +1 -1
- package/dist/hooks/magic-context/compartment-runner-recomp.d.ts.map +1 -1
- package/dist/hooks/magic-context/ctx-reduce-availability.d.ts +12 -0
- package/dist/hooks/magic-context/ctx-reduce-availability.d.ts.map +1 -1
- package/dist/hooks/magic-context/decision-calibration.d.ts +3 -0
- package/dist/hooks/magic-context/decision-calibration.d.ts.map +1 -1
- package/dist/hooks/magic-context/default-protection-pressure.test-support.d.ts +37 -0
- package/dist/hooks/magic-context/default-protection-pressure.test-support.d.ts.map +1 -0
- package/dist/hooks/magic-context/drop-stale-reduce-calls.d.ts +4 -0
- package/dist/hooks/magic-context/drop-stale-reduce-calls.d.ts.map +1 -1
- package/dist/hooks/magic-context/edit-marker.d.ts.map +1 -1
- package/dist/hooks/magic-context/emergency-drop.d.ts +2 -0
- package/dist/hooks/magic-context/emergency-drop.d.ts.map +1 -1
- package/dist/hooks/magic-context/emergency-fail-closed.d.ts +21 -1
- package/dist/hooks/magic-context/emergency-fail-closed.d.ts.map +1 -1
- package/dist/hooks/magic-context/event-handler.d.ts +5 -0
- package/dist/hooks/magic-context/event-handler.d.ts.map +1 -1
- package/dist/hooks/magic-context/final-wire-token-estimate.d.ts +30 -1
- package/dist/hooks/magic-context/final-wire-token-estimate.d.ts.map +1 -1
- package/dist/hooks/magic-context/heuristic-cleanup.d.ts +2 -0
- package/dist/hooks/magic-context/heuristic-cleanup.d.ts.map +1 -1
- package/dist/hooks/magic-context/historian-prompt-fit.d.ts +4 -2
- package/dist/hooks/magic-context/historian-prompt-fit.d.ts.map +1 -1
- package/dist/hooks/magic-context/hook.d.ts +2 -1
- package/dist/hooks/magic-context/hook.d.ts.map +1 -1
- package/dist/hooks/magic-context/inject-compartments.d.ts +9 -10
- package/dist/hooks/magic-context/inject-compartments.d.ts.map +1 -1
- package/dist/hooks/magic-context/lkg-measured-request.d.ts +69 -0
- package/dist/hooks/magic-context/lkg-measured-request.d.ts.map +1 -0
- package/dist/hooks/magic-context/lkg-persist.d.ts +2 -0
- package/dist/hooks/magic-context/lkg-persist.d.ts.map +1 -1
- package/dist/hooks/magic-context/lkg-replay-fit.d.ts +14 -0
- package/dist/hooks/magic-context/lkg-replay-fit.d.ts.map +1 -1
- package/dist/hooks/magic-context/lkg-replay.d.ts +10 -1
- package/dist/hooks/magic-context/lkg-replay.d.ts.map +1 -1
- package/dist/hooks/magic-context/lkg-slot.d.ts +4 -0
- package/dist/hooks/magic-context/lkg-slot.d.ts.map +1 -1
- package/dist/hooks/magic-context/module-state-sync.d.ts +2 -0
- package/dist/hooks/magic-context/module-state-sync.d.ts.map +1 -1
- package/dist/hooks/magic-context/module-transport.d.ts.map +1 -1
- package/dist/hooks/magic-context/module-wire.d.ts.map +1 -1
- package/dist/hooks/magic-context/note-nudger.d.ts +17 -5
- package/dist/hooks/magic-context/note-nudger.d.ts.map +1 -1
- package/dist/hooks/magic-context/read-session-chunk.d.ts +1 -1
- package/dist/hooks/magic-context/read-session-chunk.d.ts.map +1 -1
- package/dist/hooks/magic-context/read-session-db.d.ts +1 -0
- package/dist/hooks/magic-context/read-session-db.d.ts.map +1 -1
- package/dist/hooks/magic-context/read-session-formatting.d.ts +7 -0
- package/dist/hooks/magic-context/read-session-formatting.d.ts.map +1 -1
- package/dist/hooks/magic-context/read-session-raw.d.ts +4 -0
- package/dist/hooks/magic-context/read-session-raw.d.ts.map +1 -1
- package/dist/hooks/magic-context/read-session-true-raw-tokens.d.ts.map +1 -1
- package/dist/hooks/magic-context/recomp-orchestrator.d.ts +2 -0
- package/dist/hooks/magic-context/recomp-orchestrator.d.ts.map +1 -1
- package/dist/hooks/magic-context/reference-retrieval.d.ts +27 -17
- package/dist/hooks/magic-context/reference-retrieval.d.ts.map +1 -1
- package/dist/hooks/magic-context/request-hook-order.d.ts +56 -0
- package/dist/hooks/magic-context/request-hook-order.d.ts.map +1 -0
- package/dist/hooks/magic-context/rust-mode-transform.d.ts +22 -3
- package/dist/hooks/magic-context/rust-mode-transform.d.ts.map +1 -1
- package/dist/hooks/magic-context/strip-content.d.ts +4 -2
- package/dist/hooks/magic-context/strip-content.d.ts.map +1 -1
- package/dist/hooks/magic-context/supersession-reclaim.d.ts +4 -0
- package/dist/hooks/magic-context/supersession-reclaim.d.ts.map +1 -1
- package/dist/hooks/magic-context/system-prompt-hash.d.ts +7 -0
- package/dist/hooks/magic-context/system-prompt-hash.d.ts.map +1 -1
- package/dist/hooks/magic-context/tail-hygiene-walk.d.ts +12 -3
- package/dist/hooks/magic-context/tail-hygiene-walk.d.ts.map +1 -1
- package/dist/hooks/magic-context/temporal-awareness.d.ts +6 -3
- package/dist/hooks/magic-context/temporal-awareness.d.ts.map +1 -1
- package/dist/hooks/magic-context/temporal-served-projection.d.ts +4 -0
- package/dist/hooks/magic-context/temporal-served-projection.d.ts.map +1 -0
- package/dist/hooks/magic-context/tool-drop-target.d.ts.map +1 -1
- package/dist/hooks/magic-context/tool-reclaim.d.ts +2 -0
- package/dist/hooks/magic-context/tool-reclaim.d.ts.map +1 -1
- package/dist/hooks/magic-context/transform-message-helpers.d.ts +5 -0
- package/dist/hooks/magic-context/transform-message-helpers.d.ts.map +1 -1
- package/dist/hooks/magic-context/transform-postprocess-phase.d.ts +41 -17
- package/dist/hooks/magic-context/transform-postprocess-phase.d.ts.map +1 -1
- package/dist/hooks/magic-context/transform.d.ts +12 -0
- package/dist/hooks/magic-context/transform.d.ts.map +1 -1
- package/dist/hooks/magic-context/wrapup-orchestrator.d.ts.map +1 -1
- package/dist/{index-vvtfyw1z.js → index-0d3g3461.js} +5 -13
- package/dist/index-1bc61ans.js +154 -0
- package/dist/{index-n96ag4rk.js → index-1zx87sdm.js} +5 -1
- package/dist/{index-4krbw8z9.js → index-3h0ybwah.js} +608 -102
- package/dist/{index-gd5qx1j9.js → index-5eqk6z3s.js} +62 -1
- package/dist/index-5gq3b2ya.js +494 -0
- package/dist/{index-8fgkmxmy.js → index-5p8jdswx.js} +4 -3
- package/dist/{index-75zjgwga.js → index-7qw742ev.js} +1 -1
- package/dist/{index-f85teqck.js → index-8da2zjhz.js} +3 -256
- package/dist/{index-q7yesyk9.js → index-8x2v7gg9.js} +25 -24
- package/dist/{index-w9jwmntv.js → index-b35pxds2.js} +9 -1
- package/dist/{v2/server-a4m2b1yv.js → index-fg34g6a5.js} +55 -1
- package/dist/index-hpecdzec.js +28506 -0
- package/dist/{index-2ntg5sd4.js → index-k5bdx1bx.js} +9 -5
- package/dist/{index-bmzf7zxv.js → index-majxda46.js} +23 -5
- package/dist/{index-2aq21j41.js → index-pkbcrdqs.js} +418 -127
- package/dist/{index-remp7e2g.js → index-q4yp4b52.js} +16 -1
- package/dist/{index-fr2z4qy8.js → index-r5hmbx3t.js} +132 -169
- package/dist/index-sfnj6h8h.js +259 -0
- package/dist/{index-xgt9k6c6.js → index-sgthv3f7.js} +2 -1
- package/dist/index-sj29b3z2.js +30 -0
- package/dist/{index-16ny736w.js → index-sjthx78w.js} +20526 -19817
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1983 -33118
- package/dist/{message-time-backfill-an311pmk.js → message-time-backfill-68gj6t3e.js} +2 -2
- package/dist/migration-worker.js +12 -7
- package/dist/plugin/dream-timer.d.ts +25 -1
- package/dist/plugin/dream-timer.d.ts.map +1 -1
- package/dist/plugin/hooks/create-session-hooks.d.ts +2 -1
- package/dist/plugin/hooks/create-session-hooks.d.ts.map +1 -1
- package/dist/plugin/messages-transform.d.ts +13 -0
- package/dist/plugin/messages-transform.d.ts.map +1 -1
- package/dist/plugin/rpc-handlers.d.ts +4 -0
- package/dist/plugin/rpc-handlers.d.ts.map +1 -1
- package/dist/plugin/subagent-tool-policy.d.ts +14 -0
- package/dist/plugin/subagent-tool-policy.d.ts.map +1 -0
- package/dist/plugin/tool-registry.d.ts +1 -0
- package/dist/plugin/tool-registry.d.ts.map +1 -1
- package/dist/{read-session-chunk-8rxs0tc9.js → read-session-chunk-egz7r68d.js} +8 -8
- package/dist/{recomp-orchestrator-nzamtw29.js → recomp-orchestrator-y15j0rb9.js} +15 -15
- package/dist/{send-session-notification-nqpv7cne.js → send-session-notification-dyw42dtr.js} +4 -4
- package/dist/shared/announcement.d.ts.map +1 -1
- package/dist/shared/cache-ttl-display.d.ts +6 -4
- package/dist/shared/cache-ttl-display.d.ts.map +1 -1
- package/dist/shared/model-cache-ttl.d.ts +1 -1
- package/dist/shared/model-cache-ttl.d.ts.map +1 -1
- package/dist/shared/model-suggestion-retry.d.ts +2 -0
- package/dist/shared/model-suggestion-retry.d.ts.map +1 -1
- package/dist/shared/models-dev-cache.d.ts.map +1 -1
- package/dist/shared/protected-tools-policy.d.ts +6 -0
- package/dist/shared/protected-tools-policy.d.ts.map +1 -0
- package/dist/shared/quota-diagnostic.d.ts +4 -0
- package/dist/shared/quota-diagnostic.d.ts.map +1 -0
- package/dist/shared/rpc-server.d.ts.map +1 -1
- package/dist/shared/sqlite-context-pragmas.d.ts +12 -0
- package/dist/shared/sqlite-context-pragmas.d.ts.map +1 -0
- package/dist/shared/sqlite-helpers.d.ts +9 -0
- package/dist/shared/sqlite-helpers.d.ts.map +1 -1
- package/dist/shared/sqlite.d.ts +10 -0
- package/dist/shared/sqlite.d.ts.map +1 -1
- package/dist/shared/status-summary.d.ts +1 -0
- package/dist/shared/status-summary.d.ts.map +1 -1
- package/dist/shared/status-view-check.d.ts.map +1 -1
- package/dist/shared/status-view.d.ts +4 -0
- package/dist/shared/status-view.d.ts.map +1 -1
- package/dist/shared/storage-permissions.d.ts +24 -0
- package/dist/shared/storage-permissions.d.ts.map +1 -1
- package/dist/shared/temporal-upgrade-fixture.d.ts +19 -0
- package/dist/shared/temporal-upgrade-fixture.d.ts.map +1 -0
- package/dist/shared/user-facing-codes.d.ts +5 -0
- package/dist/shared/user-facing-codes.d.ts.map +1 -1
- package/dist/shared/write-transaction-timing.d.ts +8 -1
- package/dist/shared/write-transaction-timing.d.ts.map +1 -1
- package/dist/tools/ctx-expand/render.d.ts.map +1 -1
- package/dist/tools/ctx-memory/tools.d.ts.map +1 -1
- package/dist/tools/ctx-reduce/constants.d.ts +2 -0
- package/dist/tools/ctx-reduce/constants.d.ts.map +1 -1
- package/dist/tools/ctx-reduce/tools.d.ts +4 -4
- package/dist/tools/ctx-reduce/tools.d.ts.map +1 -1
- package/dist/{transform-postprocess-phase-414phndq.js → transform-postprocess-phase-bqhz6vdr.js} +15 -15
- package/dist/v2/context-zecmzk5s.js +52209 -0
- package/dist/v2/{derive-budgets-v0krf3t7.js → derive-budgets-kdgp4s3r.js} +4 -3
- package/dist/v2/embedding-worker.js +6 -5
- package/dist/v2/fold/boundary.d.ts +2 -0
- package/dist/v2/fold/boundary.d.ts.map +1 -1
- package/dist/v2/fold/owner.d.ts.map +1 -1
- package/dist/v2/hidden-child-native.d.ts +7 -0
- 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/hooks/channel2.d.ts +2 -0
- package/dist/v2/hooks/channel2.d.ts.map +1 -1
- package/dist/v2/hooks/context.d.ts +2 -2
- package/dist/v2/hooks/context.d.ts.map +1 -1
- package/dist/v2/hooks/dream-timer.d.ts +39 -0
- package/dist/v2/hooks/dream-timer.d.ts.map +1 -0
- package/dist/v2/hooks/dream-trigger.d.ts +15 -1
- package/dist/v2/hooks/dream-trigger.d.ts.map +1 -1
- package/dist/v2/hooks/hidden-child.d.ts +54 -3
- package/dist/v2/hooks/hidden-child.d.ts.map +1 -1
- package/dist/v2/hooks/payload.d.ts.map +1 -1
- package/dist/v2/hooks/store.d.ts.map +1 -1
- package/dist/v2/hooks/tools.d.ts +1 -1
- package/dist/v2/hooks/tools.d.ts.map +1 -1
- package/dist/v2/hooks/types.d.ts +12 -1
- package/dist/v2/hooks/types.d.ts.map +1 -1
- package/dist/v2/hooks/update-check.d.ts.map +1 -1
- package/dist/v2/{message-time-backfill-0n93vrd7.js → message-time-backfill-r6qkem1x.js} +3 -3
- package/dist/v2/migration-worker.js +13 -8
- package/dist/v2/{read-session-chunk-hjza38hr.js → read-session-chunk-8vjp6581.js} +9 -9
- package/dist/v2/recomp-orchestrator-8ejxvrzz.js +39 -0
- package/dist/v2/{safe-notification-target-wtj0bbc2.js → safe-notification-target-eb1n1vfb.js} +2 -2
- package/dist/v2/{send-session-notification-mq9frrtm.js → send-session-notification-qs0j78v6.js} +6 -6
- package/dist/v2/server-14vq4kpm.js +30 -0
- package/dist/v2/server-1bc61ans.js +154 -0
- package/dist/v2/{server-n96ag4rk.js → server-1zx87sdm.js} +5 -1
- package/dist/v2/server-3n4q9xme.js +79 -0
- package/dist/v2/{server-rhdgxp1t.js → server-51dv1pr5.js} +63 -2
- package/dist/v2/{server-5317ykaf.js → server-6r257mf5.js} +1 -1
- package/dist/v2/server-84w6rvvf.js +14 -0
- package/dist/v2/{server-qpg6wf72.js → server-ajzeteqw.js} +9 -1
- package/dist/v2/server-c5gz8wph.js +3892 -0
- package/dist/v2/{server-v5xgft5v.js → server-e29d7p7c.js} +188 -3533
- package/dist/{index-a4m2b1yv.js → v2/server-fg34g6a5.js} +55 -1
- package/dist/v2/{server-e36nf2p1.js → server-frbm99q5.js} +1595 -1599
- package/dist/v2/{server-remp7e2g.js → server-g0fjrkta.js} +16 -1
- package/dist/v2/{server-c4g2y1z8.js → server-jc7y02q0.js} +2816 -5392
- package/dist/v2/{server-z19x7eqz.js → server-mcfawjgc.js} +4 -4
- package/dist/v2/{server-hfjfbg59.js → server-qp5hx1ad.js} +608 -105
- package/dist/v2/server-vs5gpnd4.js +493 -0
- package/dist/v2/{server-w99cyt6a.js → server-wvjvfhck.js} +14 -6
- package/dist/v2/server-xa4xe3rv.js +3351 -0
- package/dist/v2/{server-0jqw05sa.js → server-y8maxeft.js} +6 -84
- package/dist/v2/server.d.ts.map +1 -1
- package/dist/v2/server.js +104 -49288
- package/dist/v2/store-reader.d.ts +39 -1
- package/dist/v2/store-reader.d.ts.map +1 -1
- package/dist/v2/tool-result.d.ts +8 -0
- package/dist/v2/tool-result.d.ts.map +1 -0
- package/dist/v2/tui/index.d.ts.map +1 -1
- package/dist/v2/{wrapup-orchestrator-tbyx78dz.js → wrapup-orchestrator-0snhvwcv.js} +20 -16
- package/dist/wrapup-orchestrator-39amhv9s.js +26 -0
- package/package.json +26 -10
- package/src/config/index.ts +21 -4
- package/src/config/latch-permanence-guard.test.ts +6 -1
- package/src/config/live-run-config.ts +1 -0
- package/src/config/migrate-config-location.test.ts +31 -1
- package/src/config/migrate-config-location.ts +8 -41
- package/src/config/protected-tools.test.ts +70 -0
- package/src/config/raw-loader.test.ts +15 -0
- package/src/config/raw-loader.ts +1 -1
- package/src/config/removed-agent-source-fence.test.ts +10 -1
- package/src/config/schema/magic-context.test.ts +20 -1
- package/src/config/schema/magic-context.ts +26 -7
- package/src/shared/announcement.ts +6 -5
- package/src/shared/cache-ttl-display.test.ts +1 -1
- package/src/shared/cache-ttl-display.ts +17 -16
- package/src/shared/fold-render-lock-fence.test.ts +84 -0
- package/src/shared/fold-render-lock-fixtures.test.ts +276 -0
- package/src/shared/model-cache-ttl.test.ts +2 -2
- package/src/shared/model-cache-ttl.ts +8 -4
- package/src/shared/model-suggestion-retry.test.ts +104 -1
- package/src/shared/model-suggestion-retry.ts +63 -6
- package/src/shared/models-dev-cache.ts +3 -11
- package/src/shared/protected-tools-policy.ts +23 -0
- package/src/shared/quota-diagnostic.ts +9 -0
- package/src/shared/rpc-server.ts +6 -54
- package/src/shared/sqlite-context-pragmas.test.ts +105 -0
- package/src/shared/sqlite-context-pragmas.ts +24 -0
- package/src/shared/sqlite-helpers.ts +17 -0
- package/src/shared/sqlite.ts +75 -0
- package/src/shared/status-detail-text.test.ts +18 -1
- package/src/shared/status-summary.ts +11 -0
- package/src/shared/status-view-check.ts +5 -0
- package/src/shared/status-view.test.ts +11 -2
- package/src/shared/status-view.ts +12 -1
- package/src/shared/storage-permissions.test.ts +204 -0
- package/src/shared/storage-permissions.ts +192 -0
- package/src/shared/temporal-upgrade-fixture.ts +50 -0
- package/src/shared/user-facing-codes.ts +6 -0
- package/src/shared/write-transaction-timing.test.ts +39 -0
- package/src/shared/write-transaction-timing.ts +25 -1
- package/src/tui/dialogs/status-dialog-render.test.ts +1 -1
- package/src/tui/index.tsx +3 -1
- package/src/tui/startup-order.test.ts +16 -0
- package/src/tui-compiled/index.tsx +3 -1
- package/src/v2/tui/index.ts +9 -2
- package/dist/index-anq4nn6f.js +0 -131
- package/dist/index-e44zzy84.js +0 -10
- package/dist/index-x23gah8c.js +0 -16
- package/dist/v2/recomp-orchestrator-1aq7h44c.js +0 -36
- package/dist/v2/server-e44zzy84.js +0 -10
- package/dist/v2/server-fgmxwrgy.js +0 -16
- package/dist/v2/server-r7cmye3k.js +0 -131
- package/dist/wrapup-orchestrator-h28bqsy6.js +0 -26
- package/dist/v2/{server-ckpc8pxy.js → server-1qbnzc80.js} +8 -8
|
@@ -5,9 +5,10 @@ import {
|
|
|
5
5
|
resolveHistorianProducerLimits2,
|
|
6
6
|
resolveHistorianContextLimit2,
|
|
7
7
|
producerSourceLocalBudget2
|
|
8
|
-
} from "./server-
|
|
9
|
-
import"./server-
|
|
10
|
-
import"./server-
|
|
8
|
+
} from "./server-3n4q9xme.js";
|
|
9
|
+
import"./server-y8maxeft.js";
|
|
10
|
+
import"./server-1zx87sdm.js";
|
|
11
|
+
import"./server-1qbnzc80.js";
|
|
11
12
|
export {
|
|
12
13
|
deriveHistorianChunkTokens2 as deriveHistorianChunkTokens,
|
|
13
14
|
deriveTriggerBudget2 as deriveTriggerBudget,
|
|
@@ -1,17 +1,18 @@
|
|
|
1
1
|
import {
|
|
2
2
|
setHarness,
|
|
3
3
|
log
|
|
4
|
-
} from "./server-
|
|
4
|
+
} from "./server-1qbnzc80.js";
|
|
5
|
+
import"./server-e29d7p7c.js";
|
|
6
|
+
import"./server-g0fjrkta.js";
|
|
5
7
|
import {
|
|
6
8
|
resolveLocalEmbeddingWorkerRuntime,
|
|
7
9
|
getLocalEmbeddingNativeMemoryStats,
|
|
8
10
|
LocalEmbeddingProvider
|
|
9
|
-
} from "./server-
|
|
10
|
-
import"./server-
|
|
11
|
-
import"./server-rhdgxp1t.js";
|
|
11
|
+
} from "./server-xa4xe3rv.js";
|
|
12
|
+
import"./server-51dv1pr5.js";
|
|
12
13
|
import {
|
|
13
14
|
setStoragePrivatePermissionEnforcement
|
|
14
|
-
} from "./server-
|
|
15
|
+
} from "./server-1bc61ans.js";
|
|
15
16
|
|
|
16
17
|
// src/features/magic-context/memory/embedding-worker.ts
|
|
17
18
|
import { parentPort, workerData } from "node:worker_threads";
|
|
@@ -57,5 +57,7 @@ findBoundaryUserMessage: (sessionId: string, endMessageId: string) => RawMessage
|
|
|
57
57
|
*/
|
|
58
58
|
export declare function trimToRecordedBoundary(db: ContextDatabase, sessionId: string, messages: Array<{
|
|
59
59
|
id?: string;
|
|
60
|
+
role?: string;
|
|
61
|
+
ordinal?: number;
|
|
60
62
|
}>): number;
|
|
61
63
|
//# sourceMappingURL=boundary.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"boundary.d.ts","sourceRoot":"","sources":["../../../src/v2/fold/boundary.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"boundary.d.ts","sourceRoot":"","sources":["../../../src/v2/fold/boundary.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,sCAAsC,CAAC;AAY5E,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,4CAA4C,CAAC;AAC7E,OAAO,KAAK,EAAE,wBAAwB,EAAE,MAAM,uDAAuD,CAAC;AAItG;;;;;;;;;;;GAWG;AACH,wBAAgB,0BAA0B,CACtC,QAAQ,EAAE,SAAS,UAAU,EAAE,EAC/B,YAAY,EAAE,MAAM,GACrB,UAAU,GAAG,IAAI,CAQnB;AAED;;;;;;;;;;;GAWG;AACH,wBAAgB,oCAAoC;AAChD;;;;GAIG;AACH,uBAAuB,EAAE,CAAC,SAAS,EAAE,MAAM,EAAE,YAAY,EAAE,MAAM,KAAK,UAAU,GAAG,IAAI,GACxF,wBAAwB,CAkE1B;AAED;;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AAG,SAAS,CAAC;IAG1D,MAAM,CAAC,IAAI,EAAE;QACf,SAAS,EAAE,MAAM,CAAC;QAClB,SAAS,EAAE,MAAM,CAAC;QAClB,UAAU,CAAC,EAAE,MAAM,CAAC;QACpB,WAAW,EAAE,MAAM,MAAM,CAAC;KAC7B,GAAG,OAAO,CAAC,YAAY,CAAC;IAoBnB,OAAO,CAAC,IAAI,EAAE;QAChB,SAAS,EAAE,MAAM,CAAC;QAClB,MAAM,EAAE,MAAM,CAAC;QACf,OAAO,EAAE,MAAM,CAAC;QAChB,QAAQ,EAAE,SAAS,CAAC;QACpB,MAAM,EAAE,CAAC,MAAM,EAAE,WAAW,CAAC,YAAY,CAAC,QAAQ,CAAC,CAAC,KAAK,IAAI,CAAC;KACjE,GAAG,OAAO,CAAC,YAAY,CAAC;CA2C5B"}
|
|
@@ -24,6 +24,13 @@ export declare function createNativeHiddenChildren(host: HiddenChildHost, remove
|
|
|
24
24
|
keepSubagents: boolean;
|
|
25
25
|
log: (message: string) => void;
|
|
26
26
|
removalTimeoutMs?: number;
|
|
27
|
+
/**
|
|
28
|
+
* The directory of the plugin instance that owns this lifecycle. OpenCode 2
|
|
29
|
+
* runs a session's hooks in the instance of the session's own location,
|
|
30
|
+
* and a child takes its parent's location, so a child bound to any other
|
|
31
|
+
* directory would be shaped (and guarded) by a different instance.
|
|
32
|
+
*/
|
|
33
|
+
directory?: string;
|
|
27
34
|
}): HiddenChildLifecycle;
|
|
28
35
|
export {};
|
|
29
36
|
//# sourceMappingURL=hidden-child-native.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"hidden-child-native.d.ts","sourceRoot":"","sources":["../../src/v2/hidden-child-native.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"hidden-child-native.d.ts","sourceRoot":"","sources":["../../src/v2/hidden-child-native.ts"],"names":[],"mappings":"AAIA,OAAO,EAGH,KAAK,eAAe,EACpB,KAAK,oBAAoB,EAM5B,MAAM,uBAAuB,CAAC;AAC/B,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,sBAAsB,CAAC;AAE5D;;;;;;GAMG;AAEH,KAAK,aAAa,GAAG,WAAW,CAAC,eAAe,CAAC,eAAe,CAAC,CAAC,CAAC;AAEnE;;;;GAIG;AACH,wBAAgB,mBAAmB,CAAC,OAAO,EAAE,MAAM,GAAG,aAAa,GAAG,SAAS,CAI9E;AAED,mEAAmE;AACnE,wBAAgB,iBAAiB,CAAC,KAAK,EAAE,OAAO,GAAG,OAAO,CAQzD;AAMD,qDAAqD;AACrD,wBAAgB,0BAA0B,IAAI,IAAI,CAEjD;AAED,wBAAgB,0BAA0B,CACtC,IAAI,EAAE,eAAe,EACrB,aAAa,EAAE,aAAa,EAC5B,OAAO,EAAE;IACL,IAAI,EAAE,eAAe,CAAC;IACtB,UAAU,EAAE,MAAM,CAAC;IACnB,aAAa,EAAE,OAAO,CAAC;IACvB,GAAG,EAAE,CAAC,OAAO,EAAE,MAAM,KAAK,IAAI,CAAC;IAC/B,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAC1B;;;;;OAKG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;CACtB,GACF,oBAAoB,CAiItB"}
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import type { HiddenRunIdentity } from "../hooks/magic-context/compartment-runner-types";
|
|
2
|
+
import { type HiddenPermissionRule } from "./hooks/hidden-child";
|
|
2
3
|
import type { StoreRow } from "./store-reader";
|
|
3
4
|
/** Session carrier shared by the native hidden-run executor and lifecycle. */
|
|
4
5
|
export interface HiddenChildModel {
|
|
@@ -41,6 +42,8 @@ export interface HiddenChildHost {
|
|
|
41
42
|
};
|
|
42
43
|
/** A child inherits this parent's location. */
|
|
43
44
|
parentID?: string;
|
|
45
|
+
/** Session rules; the host evaluates them after every rule of the agent. */
|
|
46
|
+
permissions?: HiddenPermissionRule[];
|
|
44
47
|
}): Promise<{
|
|
45
48
|
id: string;
|
|
46
49
|
}>;
|
|
@@ -56,6 +59,11 @@ export interface HiddenChildHost {
|
|
|
56
59
|
error?: unknown;
|
|
57
60
|
/** The parent the host stored for the session, on hosts that keep one. */
|
|
58
61
|
parentID?: string;
|
|
62
|
+
/** The location the host bound the session to; a child takes its parent's. */
|
|
63
|
+
location?: {
|
|
64
|
+
directory?: string;
|
|
65
|
+
workspaceID?: string;
|
|
66
|
+
};
|
|
59
67
|
}>;
|
|
60
68
|
/** Optional event-backed error lookup for hosts that do not retain the reason on session.get. */
|
|
61
69
|
terminalError?(input: {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"hidden-child-record.d.ts","sourceRoot":"","sources":["../../src/v2/hidden-child-record.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,iDAAiD,CAAC;
|
|
1
|
+
{"version":3,"file":"hidden-child-record.d.ts","sourceRoot":"","sources":["../../src/v2/hidden-child-record.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,iDAAiD,CAAC;AACzF,OAAO,EAIH,KAAK,oBAAoB,EAI5B,MAAM,sBAAsB,CAAC;AAC9B,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,gBAAgB,CAAC;AAE/C,8EAA8E;AAE9E,MAAM,WAAW,gBAAgB;IAC7B,UAAU,EAAE,MAAM,CAAC;IACnB,OAAO,EAAE,MAAM,CAAC;IAChB,OAAO,CAAC,EAAE,MAAM,CAAC;CACpB;AAED,MAAM,MAAM,eAAe,GAAG,WAAW,GAAG,SAAS,GAAG,gBAAgB,CAAC;AAEzE,MAAM,WAAW,oBAAoB;IACjC,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,eAAe,CAAC;IACtB,UAAU,EAAE,MAAM,CAAC;IACnB,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,gBAAgB,CAAC;IACxB,UAAU,EAAE,MAAM,CAAC;IACnB,gGAAgG;IAChG,SAAS,CAAC,EAAE,MA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IAAI,EAAE,eAAe,CAAC;IACtB,UAAU,EAAE,MAAM,eAAe,GAAG;QAAE,KAAK,CAAC,EAAE,MAAM,IAAI,CAAA;KAAE,CAAC;IAC3D,WAAW,CAAC,IAAI,OAAO,CAAC,IAAI,CAAC,CAAC;IAC9B,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,kEAAkE;IAClE,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAC1B;;;OAGG;IACH,aAAa,CAAC,EAAE,OAAO,CAAC;IACxB,GAAG,CAAC,EAAE,CAAC,OAAO,EAAE,MAAM,KAAK,IAAI,CAAC;IAChC,4FAA4F;IAC5F,YAAY,CAAC,EAAE,MAAM,OAAO,CAAC,OAAO,CAAC,CAAC;CACzC;AAwFD;;;;;GAKG;AACH,wBAAgB,gBAAgB,CAAC,OAAO,EAAE,kBAAkB,GAAG,OAAO,EAAE,CA6CvE;AAoBD;;;;;GAKG;AACH,qBAAa,mBAAoB,SAAQ,KAAK;IAC1C,QAAQ,CAAC,OAAO,EAAE,OAAO,CAAC;gBAEd,MAAM,EAAE,MAAM,EAAE,OAAO,GAAE;QAAE,OAAO,CAAC,EAAE,OAAO,CAAA;KAAO;CAKlE;AA4GD,uEAAuE;AACvE,eAAO,MAAM,+BAA+B,EAAE,wBAAwB,CAAC,cAAc,CAGpF,CAAC;AAEF;;;;;GAKG;AACH,wBAAgB,wBAAwB,CACpC,OAAO,EAAE,MAAM,wBAAwB,GAAG,SAAS,GACpD,wBAAwB,CAiB1B;AAED,wBAAsB,gCAAgC,CAClD,IAAI,EAAE,eAAe,EACrB,OAAO,EAAE,yBAAyB,GACnC,OAAO,CAAC,wBAAwB,CAAC,CAgbnC"}
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
import type { ContextDatabase } from "../../features/magic-context/storage";
|
|
2
2
|
import { type Channel1State } from "../../hooks/magic-context/ctx-reduce-nudge";
|
|
3
3
|
import type { V2Context } from "./types";
|
|
4
|
+
export declare function syntheticCandidates(context: Pick<V2Context, "storage">, sessionID: string, stored: Set<string>): Set<string>;
|
|
5
|
+
export declare function clearSyntheticCandidates(context: Pick<V2Context, "storage">): void;
|
|
4
6
|
/** Record the admitted identity before sending; recognition never relies on its prefix. */
|
|
5
7
|
export declare function deliverSynthetic(context: Pick<V2Context, "session" | "storage">, sessionID: string, text: string): Promise<string>;
|
|
6
8
|
export declare function isAdmittedSynthetic(context: Pick<V2Context, "storage">, sessionID: string, id: string): Promise<boolean>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"channel2.d.ts","sourceRoot":"","sources":["../../../src/v2/hooks/channel2.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,sCAAsC,CAAC;AAM5E,OAAO,EAEH,KAAK,aAAa,EAGrB,MAAM,4CAA4C,CAAC;AACpD,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,SAAS,CAAC;
|
|
1
|
+
{"version":3,"file":"channel2.d.ts","sourceRoot":"","sources":["../../../src/v2/hooks/channel2.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,sCAAsC,CAAC;AAM5E,OAAO,EAEH,KAAK,aAAa,EAGrB,MAAM,4CAA4C,CAAC;AACpD,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,SAAS,CAAC;AAMzC,wBAAgB,mBAAmB,CAC/B,OAAO,EAAE,IAAI,CAAC,SAAS,EAAE,SAAS,CAAC,EACnC,SAAS,EAAE,MAAM,EACjB,MAAM,EAAE,GAAG,CAAC,MAAM,CAAC,GACpB,GAAG,CAAC,MAAM,CAAC,CAQb;AAED,wBAAgB,wBAAwB,CAAC,OAAO,EAAE,IAAI,CAAC,SAAS,EAAE,SAAS,CAAC,GAAG,IAAI,CAElF;AAED,2FAA2F;AAC3F,wBAAsB,gBAAgB,CAClC,OAAO,EAAE,IAAI,CAAC,SAAS,EAAE,SAAS,GAAG,SAAS,CAAC,EAC/C,SAAS,EAAE,MAAM,EACjB,IAAI,EAAE,MAAM,GACb,OAAO,CAAC,MAAM,CAAC,CAWjB;AAED,wBAAsB,mBAAmB,CACrC,OAAO,EAAE,IAAI,CAAC,SAAS,EAAE,SAAS,CAAC,EACnC,SAAS,EAAE,MAAM,EACjB,EAAE,EAAE,MAAM,GACX,OAAO,CAAC,OAAO,CAAC,CAGlB;AAED,wBAAsB,sBAAsB,CACxC,OAAO,EAAE,SAAS,EAClB,EAAE,EAAE,eAAe,EACnB,SAAS,EAAE,MAAM,EACjB,QAAQ,EAAE,aAAa,GAAG,SAAS,GACpC,OAAO,CAAC,IAAI,CAAC,CAoBf"}
|
|
@@ -5,7 +5,7 @@ import { type TransformDeps } from "../../hooks/magic-context/transform";
|
|
|
5
5
|
import type { PromptSurfaceConfig } from "../../shared/prompt-surface";
|
|
6
6
|
import { type PromptSurfaceRuntime } from "../../shared/prompt-surface-runtime";
|
|
7
7
|
import { type Database } from "../../shared/sqlite";
|
|
8
|
-
import { V2StoreReader } from "../store-reader";
|
|
8
|
+
import { type V2StoreReader } from "../store-reader";
|
|
9
9
|
import type { SessionContext, V2Context } from "./types";
|
|
10
10
|
export declare function isBlockingV2TransformError(error: unknown): boolean;
|
|
11
11
|
/**
|
|
@@ -29,7 +29,7 @@ export declare function checkHistoryBoundary(db: Database, reader: Pick<V2StoreR
|
|
|
29
29
|
* session's lifetime; a failed lookup is retried on the next pass.
|
|
30
30
|
*/
|
|
31
31
|
export declare function cacheV2SessionDirectory(session: Pick<V2Context["session"], "get">, sessionID: string, directories: Map<string, string>): Promise<void>;
|
|
32
|
-
export declare function createHostSeams(context: V2Context, readAllForConversion: TransformDeps["hostRawMessages"] & {}, reconciliationSource: NonNullable<TransformDeps["hostMessageReconciliationSource"]>, liveModels: NonNullable<TransformDeps["liveModelBySession"]>): Required<Pick<TransformDeps, "hostRawMessages" | "hostMessageReconciliationSource" | "hostProtectedTailBoundary" | "hostModelFallback" | "hostRefusalNotice" | "hostRefuse">>;
|
|
32
|
+
export declare function createHostSeams(context: V2Context, readAllForConversion: TransformDeps["hostRawMessages"] & {}, reconciliationSource: NonNullable<TransformDeps["hostMessageReconciliationSource"]>, liveModels: NonNullable<TransformDeps["liveModelBySession"]>): Required<Pick<TransformDeps, "hostRawMessages" | "hostMessageReconciliationSource" | "hostProtectedTailBoundary" | "hostModelFallback" | "getModelKey" | "hostRefusalNotice" | "hostRefuse">>;
|
|
33
33
|
type V2ThresholdConfig = Pick<ReturnType<typeof loadPluginConfigDetailed>["config"], "execute_threshold_percentage" | "execute_threshold_tokens">;
|
|
34
34
|
/**
|
|
35
35
|
* The execute thresholds the shared transform and its scheduler read, built the way the
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"context.d.ts","sourceRoot":"","sources":["../../../src/v2/hooks/context.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,wBAAwB,EAAE,MAAM,cAAc,CAAC;
|
|
1
|
+
{"version":3,"file":"context.d.ts","sourceRoot":"","sources":["../../../src/v2/hooks/context.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,wBAAwB,EAAE,MAAM,cAAc,CAAC;AA6DxD,OAAO,EACH,KAAK,qBAAqB,EAE7B,MAAM,mDAAmD,CAAC;AAsB3D,OAAO,EAAE,6BAA6B,EAAE,MAAM,8CAA8C,CAAC;AAC7F,OAAO,EAAmB,KAAK,aAAa,EAAE,MAAM,qCAAqC,CAAC;AAmB1F,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,6BAA6B,CAAC;AACvE,OAAO,EAGH,KAAK,oBAAoB,EAC5B,MAAM,qCAAqC,CAAC;AAG7C,OAAO,EACH,KAAK,QAAQ,EAKhB,MAAM,qBAAqB,CAAC;AAY7B,OAAO,EAAkB,KAAK,aAAa,EAAqB,MAAM,iBAAiB,CAAC;AA0CxF,OAAO,KAAK,EAAE,cAAc,EAAE,SAAS,EAAE,MAAM,SAAS,CAAC;AAOzD,wBAAgB,0BAA0B,CAAC,KAAK,EAAE,OAAO,GAAG,OAAO,CA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a,CACzB,MAAM,EAAE,OAAO,EACf,UAAU,CAAC,EAAE,cAAc,CAAC,OAAO,CAAC,GACrC,KAAK,CAAC;IACL,EAAE,EAAE,MAAM,CAAC;IACX,UAAU,EAAE,MAAM,CAAC;IACnB,KAAK,EAAE;QAAE,OAAO,EAAE,MAAM,CAAC;QAAC,KAAK,CAAC,EAAE,MAAM,CAAC;QAAC,MAAM,CAAC,EAAE,MAAM,CAAA;KAAE,CAAC;CAC/D,CAAC,CAyCD;AAED,wBAAgB,sBAAsB,CAAC,KAAK,EAAE,cAAc,GAAG,IAAI,CAElE;AAED,4EAA4E;AAC5E,wBAAgB,yBAAyB,CACrC,KAAK,EAAE,cAAc,EACrB,OAAO,EAAE,oBAAoB,EAC7B,MAAM,EAAE,mBAAmB,GAAG,SAAS,GACxC,IAAI,CAUN;AAED;;;;;;;;;;;GAWG;AACH,wBAAgB,uBAAuB,CAAC,KAAK,EAAE,cAAc,GAAG,IAAI,CAgBnE;AAED;;;;;;;;;;;;;;;;;;;;;GAqBG;AACH,wBAAsB,mBAAmB,CACrC,YAAY,EAAE,IAAI,CAAC,UAAU,CAAC,OAAO,6BAA6B,CAAC,EAAE,SAAS,CAAC,EAC/E,KAAK,EAAE,IAAI,CAAC,cAAc,EAAE,WAAW,GAAG,OAAO,GAAG,UAAU,GAAG,QAAQ,GAAG,OAAO,CAAC,GACrF,OAAO,CAAC,IAAI,CAAC,CA4Bf;AAED,wBAAsB,eAAe,CAAC,OAAO,EAAE,SAAS;;eA2hDvD"}
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import type { MagicContextPluginConfig } from "../../config";
|
|
2
|
+
import type { DreamerConfig } from "../../config/schema/magic-context";
|
|
3
|
+
import type { HiddenCompletionExecutor } from "../../hooks/magic-context/compartment-runner-types";
|
|
4
|
+
import type { V2StoreReader } from "../store-reader";
|
|
5
|
+
/**
|
|
6
|
+
* Find the session a timer-started dream run's child sessions hang under.
|
|
7
|
+
*
|
|
8
|
+
* A run started by the schedule timer has no triggering session. OpenCode 2
|
|
9
|
+
* shows a hidden child created without a parent as a separate top-level
|
|
10
|
+
* session, so the run borrows the most recently updated user session in this
|
|
11
|
+
* location. Returns undefined when the location has none (or its store cannot
|
|
12
|
+
* be read); the executor then skips the tasks that need a child session.
|
|
13
|
+
*/
|
|
14
|
+
export declare function findV2DreamParentSession(openReader: () => Pick<V2StoreReader, "latestRootSessionInDirectory" | "close">, directory: string): string | undefined;
|
|
15
|
+
/**
|
|
16
|
+
* Register one OpenCode 2 plugin context's project with the process-wide dream
|
|
17
|
+
* schedule timer, so due dream tasks run on their cron schedule and not only
|
|
18
|
+
* after a session turn ends.
|
|
19
|
+
*
|
|
20
|
+
* OpenCode 1 registers from its `server` lane, which OpenCode 2 never calls.
|
|
21
|
+
* The timer is shared by every context in the process and keyed by directory;
|
|
22
|
+
* `dispose` removes only this context's registration, and the timer stops once
|
|
23
|
+
* no project is left. OpenCode 2 runs a context's cleanup when its location
|
|
24
|
+
* shuts down or is rebuilt, so disposal is tied to the context, not to an
|
|
25
|
+
* event.
|
|
26
|
+
*/
|
|
27
|
+
export declare function registerV2DreamScheduleTimer(args: {
|
|
28
|
+
directory: string;
|
|
29
|
+
projectIdentity: string;
|
|
30
|
+
config: MagicContextPluginConfig;
|
|
31
|
+
dreamer: DreamerConfig;
|
|
32
|
+
/** The live configuration, re-read before each timer pass. */
|
|
33
|
+
liveConfig: () => MagicContextPluginConfig;
|
|
34
|
+
executor: HiddenCompletionExecutor;
|
|
35
|
+
openReader: () => Pick<V2StoreReader, "latestRootSessionInDirectory" | "close">;
|
|
36
|
+
}): {
|
|
37
|
+
dispose(): Promise<void>;
|
|
38
|
+
};
|
|
39
|
+
//# sourceMappingURL=dream-timer.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"dream-timer.d.ts","sourceRoot":"","sources":["../../../src/v2/hooks/dream-timer.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,wBAAwB,EAAE,MAAM,cAAc,CAAC;AAE7D,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,mCAAmC,CAAC;AACvE,OAAO,KAAK,EAAE,wBAAwB,EAAE,MAAM,oDAAoD,CAAC;AAKnG,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,iBAAiB,CAAC;AAGrD;;;;;;;;GAQG;AACH,wBAAgB,wBAAwB,CACpC,UAAU,EAAE,MAAM,IAAI,CAAC,aAAa,EAAE,8BAA8B,GAAG,OAAO,CAAC,EAC/E,SAAS,EAAE,MAAM,GAClB,MAAM,GAAG,SAAS,CAiBpB;AAED;;;;;;;;;;;GAWG;AACH,wBAAgB,4BAA4B,CAAC,IAAI,EAAE;IAC/C,SAAS,EAAE,MAAM,CAAC;IAClB,eAAe,EAAE,MAAM,CAAC;IACxB,MAAM,EAAE,wBAAwB,CAAC;IACjC,OAAO,EAAE,aAAa,CAAC;IACvB,8DAA8D;IAC9D,UAAU,EAAE,MAAM,wBAAwB,CAAC;IAC3C,QAAQ,EAAE,wBAAwB,CAAC;IACnC,UAAU,EAAE,MAAM,IAAI,CAAC,aAAa,EAAE,8BAA8B,GAAG,OAAO,CAAC,CAAC;CACnF,GAAG;IAAE,OAAO,IAAI,OAAO,CAAC,IAAI,CAAC,CAAA;CAAE,CAmD/B"}
|
|
@@ -2,10 +2,24 @@ import type { DreamerConfig } from "../../config/schema/magic-context";
|
|
|
2
2
|
import type { HiddenCompletionExecutor } from "../../hooks/magic-context/compartment-runner-types";
|
|
3
3
|
import { V2StoreReader } from "../store-reader";
|
|
4
4
|
import type { V2Context } from "./types";
|
|
5
|
+
/**
|
|
6
|
+
* Whether a session belongs to this plugin instance's own location.
|
|
7
|
+
*
|
|
8
|
+
* OpenCode 2 builds one plugin instance per location (a directory, plus a
|
|
9
|
+
* workspace when one is set) and runs each session's hooks in the instance of
|
|
10
|
+
* that session's location, but `event.subscribe` delivers every location's
|
|
11
|
+
* events to every instance. A dream run started here for another location's
|
|
12
|
+
* session would hang its child under that session, the child would take that
|
|
13
|
+
* location, and its turns would reach the other instance, which never
|
|
14
|
+
* registered the run: the child would run unshaped, in the other directory,
|
|
15
|
+
* under the user's own permissions. A session that cannot be read is treated
|
|
16
|
+
* as foreign.
|
|
17
|
+
*/
|
|
18
|
+
export declare function sessionInThisLocation(context: Pick<V2Context, "location" | "session">, sessionID: string): Promise<boolean>;
|
|
5
19
|
/** The event carrier only wakes the shared scheduler; it never implements another
|
|
6
20
|
* queue or task loop. Generate completions have no execution-ended event, so a hidden
|
|
7
21
|
* completion cannot recursively schedule itself through this subscription. */
|
|
8
|
-
export declare function startDreamTrigger(context: V2Context, args: {
|
|
22
|
+
export declare function startDreamTrigger(context: Pick<V2Context, "location" | "event" | "session">, args: {
|
|
9
23
|
config: DreamerConfig;
|
|
10
24
|
sample?: () => {
|
|
11
25
|
config: DreamerConfig;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"dream-trigger.d.ts","sourceRoot":"","sources":["../../../src/v2/hooks/dream-trigger.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,mCAAmC,CAAC;AAMvE,OAAO,KAAK,EAAE,wBAAwB,EAAE,MAAM,oDAAoD,CAAC;AAInG,OAAO,EAAkB,aAAa,EAAE,MAAM,iBAAiB,CAAC;AAEhE,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,SAAS,CAAC;AAEzC;;8EAE8E;AAC9E,wBAAgB,iBAAiB,CAC7B,OAAO,EAAE,SAAS,
|
|
1
|
+
{"version":3,"file":"dream-trigger.d.ts","sourceRoot":"","sources":["../../../src/v2/hooks/dream-trigger.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,mCAAmC,CAAC;AAMvE,OAAO,KAAK,EAAE,wBAAwB,EAAE,MAAM,oDAAoD,CAAC;AAInG,OAAO,EAAkB,aAAa,EAAE,MAAM,iBAAiB,CAAC;AAEhE,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,SAAS,CAAC;AAEzC;;;;;;;;;;;;GAYG;AACH,wBAAsB,qBAAqB,CACvC,OAAO,EAAE,IAAI,CAAC,SAAS,EAAE,UAAU,GAAG,SAAS,CAAC,EAChD,SAAS,EAAE,MAAM,GAClB,OAAO,CAAC,OAAO,CAAC,CAWlB;AAED;;8EAE8E;AAC9E,wBAAgB,iBAAiB,CAC7B,OAAO,EAAE,IAAI,CAAC,SAAS,EAAE,UAAU,GAAG,OAAO,GAAG,SAAS,CAAC,EAC1D,IAAI,EAAE;IACF,MAAM,EAAE,aAAa,CAAC;IACtB,MAAM,CAAC,EAAE,MAAM;QAAE,MAAM,EAAE,aAAa,CAAC;QAAC,KAAK,CAAC,EAAE;YAAE,OAAO,EAAE,OAAO,CAAC;YAAC,KAAK,CAAC,EAAE,MAAM,CAAA;SAAE,CAAA;KAAE,CAAC;IACvF,QAAQ,EAAE,wBAAwB,CAAC;IACnC,eAAe,EAAE,MAAM,MAAM,CAAC;IAC9B,8EAA8E;IAC9E,oBAAoB,CAAC,EAAE,OAAO,CAAC;IAC/B,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,KAAK,CAAC,EAAE;QAAE,OAAO,EAAE,OAAO,CAAC;QAAC,KAAK,CAAC,EAAE,MAAM,CAAA;KAAE,CAAC;IAC7C,mEAAmE;IACnE,UAAU,CAAC,EAAE,MAAM,IAAI,CAAC,aAAa,EAAE,qBAAqB,GAAG,OAAO,CAAC,CAAC;CAC3E;;EA6EJ"}
|
|
@@ -7,7 +7,45 @@ export declare const HIDDEN_DREAMER_AGENT = "dreamer-classifier";
|
|
|
7
7
|
export declare const HIDDEN_CURATE_AGENT = "dreamer";
|
|
8
8
|
export declare function hiddenAgentFor(identity: HiddenRunIdentity): string;
|
|
9
9
|
export declare function hiddenToolLoop(identity: HiddenRunIdentity): boolean;
|
|
10
|
+
/**
|
|
11
|
+
* The tools a Magic Context hidden agent may call, or undefined when `agent` is
|
|
12
|
+
* not one of the hidden agents this plugin registers. Every id registered by
|
|
13
|
+
* `registerHiddenChildAgents` is a Magic Context carrier: the registration
|
|
14
|
+
* overwrites any agent of the same name, so a session running one of these ids
|
|
15
|
+
* is always running this plugin's carrier.
|
|
16
|
+
*/
|
|
17
|
+
export declare function hiddenAgentAllowedTools(agent: string | undefined): readonly string[] | undefined;
|
|
18
|
+
/** One OpenCode 2 permission rule: the action is the tool id, the resource a pattern. */
|
|
19
|
+
export interface HiddenPermissionRule {
|
|
20
|
+
action: string;
|
|
21
|
+
resource: string;
|
|
22
|
+
effect: "allow" | "deny";
|
|
23
|
+
}
|
|
24
|
+
/**
|
|
25
|
+
* Deny everything, then allow exactly the agent's own tools.
|
|
26
|
+
*
|
|
27
|
+
* OpenCode 2 evaluates a tool call against the agent's rules followed by the
|
|
28
|
+
* session's rules, and the LAST matching rule wins. Its config loader appends
|
|
29
|
+
* the user's global `permissions` to every agent after plugins have set theirs,
|
|
30
|
+
* so on the agent alone a user's `edit: allow` lands after this deny and wins.
|
|
31
|
+
* The same list is therefore also written onto each hidden child session when
|
|
32
|
+
* it is created: session rules come after every agent rule, which is the one
|
|
33
|
+
* place where these rules are guaranteed to be evaluated last.
|
|
34
|
+
*/
|
|
35
|
+
export declare function hiddenChildPermissions(agent: string): HiddenPermissionRule[];
|
|
10
36
|
export declare function registerHiddenChildAgents(agent: Pick<V2AgentDomain, "transform">): Promise<void>;
|
|
37
|
+
/**
|
|
38
|
+
* Why a tool call must not run, or undefined when it may. A call is refused
|
|
39
|
+
* when it comes from a Magic Context hidden child (a session this instance
|
|
40
|
+
* registered, or any session running one of the hidden agent ids) and the tool
|
|
41
|
+
* is not on that agent's allowlist. The user's own permission settings do not
|
|
42
|
+
* enter into it: these agents are unattended and their allowlists are fixed.
|
|
43
|
+
*/
|
|
44
|
+
export declare function hiddenToolCallRefusal(call: {
|
|
45
|
+
tool: string;
|
|
46
|
+
sessionID: string;
|
|
47
|
+
agent?: string;
|
|
48
|
+
}, hook: Pick<HiddenChildHook, "owns" | "agentFor">): string | undefined;
|
|
11
49
|
export declare class HiddenAgentStepLimit extends Error {
|
|
12
50
|
readonly agent: string;
|
|
13
51
|
readonly cap: number;
|
|
@@ -43,11 +81,14 @@ export declare function hostCheckpointSummary(text: string): string | undefined;
|
|
|
43
81
|
*/
|
|
44
82
|
export declare class HiddenChildHook {
|
|
45
83
|
private readonly note;
|
|
84
|
+
/** Each child this instance created, with the agent it was created to run. */
|
|
46
85
|
private readonly childIDs;
|
|
47
86
|
private readonly attempts;
|
|
48
87
|
private readonly active;
|
|
49
88
|
constructor(note?: (message: string) => void);
|
|
50
|
-
registerChild(sessionID: string): void;
|
|
89
|
+
registerChild(sessionID: string, agent?: string): void;
|
|
90
|
+
/** The agent a registered child was created to run, when it is known. */
|
|
91
|
+
agentFor(sessionID: string): string | undefined;
|
|
51
92
|
registerAttempt(marker: string, attempt: HiddenChildAttempt): void;
|
|
52
93
|
releaseAttempt(marker: string): void;
|
|
53
94
|
owns(sessionID: string): boolean;
|
|
@@ -62,7 +103,7 @@ export declare class HiddenChildHook {
|
|
|
62
103
|
* An owned child with no run in flight, or with more than one, is refused
|
|
63
104
|
* here exactly as the context guard would refuse its prompt.
|
|
64
105
|
*/
|
|
65
|
-
compactionSummary(sessionID: string): string | undefined;
|
|
106
|
+
compactionSummary(sessionID: string, agent?: string): string | undefined;
|
|
66
107
|
/**
|
|
67
108
|
* Log what the guard saw against what it expected, then throw. Only lengths,
|
|
68
109
|
* short hashes and the first differing bytes are written, so a mismatch can
|
|
@@ -70,7 +111,17 @@ export declare class HiddenChildHook {
|
|
|
70
111
|
*/
|
|
71
112
|
private refuse;
|
|
72
113
|
private calibratedParts;
|
|
73
|
-
/**
|
|
114
|
+
/**
|
|
115
|
+
* Returns false only for an ordinary user session that this bridge does not own.
|
|
116
|
+
*
|
|
117
|
+
* A session running one of the hidden agent ids that this instance did not
|
|
118
|
+
* register is refused, not passed through. OpenCode 2 runs each session's
|
|
119
|
+
* hooks in the plugin instance of that session's location, so a hidden child
|
|
120
|
+
* created by another instance (another directory, or this directory before a
|
|
121
|
+
* restart) arrives here unshaped: its user message is a bare run marker, and
|
|
122
|
+
* passing it on would send the marker to the model with whatever tools the
|
|
123
|
+
* user's own permissions allow.
|
|
124
|
+
*/
|
|
74
125
|
apply(draft: SessionContext): boolean;
|
|
75
126
|
}
|
|
76
127
|
//# sourceMappingURL=hidden-child.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"hidden-child.d.ts","sourceRoot":"","sources":["../../../src/v2/hooks/hidden-child.ts"],"names":[],"mappings":"AAQA,OAAO,EACH,sBAAsB,EAEzB,MAAM,mDAAmD,CAAC;AAC3D,OAAO,EACH,uBAAuB,EACvB,KAAK,iBAAiB,EACzB,MAAM,oDAAoD,CAAC;AAG5D,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,qCAAqC,CAAC;AACtE,OAAO,KAAK,EAAE,cAAc,EAAE,aAAa,EAAE,MAAM,SAAS,CAAC;AAE7D,eAAO,MAAM,sBAAsB,cAAc,CAAC;AAClD,eAAO,MAAM,oBAAoB,uBAAuB,CAAC;AACzD,eAAO,MAAM,mBAAmB,YAAgB,CAAC;AAmBjD,wBAAgB,cAAc,CAAC,QAAQ,EAAE,iBAAiB,GAAG,MAAM,CAQlE;AAED,wBAAgB,cAAc,CAAC,QAAQ,EAAE,iBAAiB,GAAG,OAAO,CAEnE;AAED,wBAAsB,yBAAyB,CAC3C,KAAK,EAAE,IAAI,CAAC,aAAa,EAAE,WAAW,CAAC,GACxC,OAAO,CAAC,IAAI,CAAC,
|
|
1
|
+
{"version":3,"file":"hidden-child.d.ts","sourceRoot":"","sources":["../../../src/v2/hooks/hidden-child.ts"],"names":[],"mappings":"AAQA,OAAO,EACH,sBAAsB,EAEzB,MAAM,mDAAmD,CAAC;AAC3D,OAAO,EACH,uBAAuB,EACvB,KAAK,iBAAiB,EACzB,MAAM,oDAAoD,CAAC;AAG5D,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM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,IAAI,CAAC,SAAS,EAAE,MAAM,GAAG,OAAO;IAIhC;;;;;;;;;;OAUG;IACH,iBAAiB,CAAC,SAAS,EAAE,MAAM,EAAE,KAAK,CAAC,EAAE,MAAM,GAAG,MAAM,GAAG,SAAS;IA8BxE;;;;OAIG;IACH,OAAO,CAAC,MAAM;IA0Cd,OAAO,CAAC,eAAe;IAWvB;;;;;;;;;;OAUG;IACH,KAAK,CAAC,KAAK,EAAE,cAAc,GAAG,OAAO;CAsHxC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"payload.d.ts","sourceRoot":"","sources":["../../../src/v2/hooks/payload.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,wCAAwC,CAAC;
|
|
1
|
+
{"version":3,"file":"payload.d.ts","sourceRoot":"","sources":["../../../src/v2/hooks/payload.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,wCAAwC,CAAC;AAI1E,OAAO,KAAK,EAAE,cAAc,EAAa,MAAM,SAAS,CAAC;AAEzD,eAAO,MAAM,QAAQ,iEAAkE,CAAC;AA+CxF;iFACiF;AACjF,wBAAgB,wBAAwB,CAAC,CAAC,EAAE,KAAK,EAAE,CAAC,GAAG,CAAC,CAUvD;AAoFD;;;GAGG;AACH,wBAAgB,YAAY,CAAC,KAAK,EAAE,cAAc,EAAE,WAAW,GAAE,WAAW,CAAC,MAAM,CAAa;;;EAmU/F"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"store.d.ts","sourceRoot":"","sources":["../../../src/v2/hooks/store.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,yBAAyB,EAAE,MAAM,8CAA8C,CAAC;AAC9F,OAAO,KAAK,EACR,UAAU,EACV,uBAAuB,EACvB,sBAAsB,EACtB,eAAe,EAClB,MAAM,4CAA4C,CAAC;AAEpD,OAAO,EAGH,KAAK,QAAQ,EACb,KAAK,aAAa,EACrB,M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A6G5F;AAED,wBAAgB,0BAA0B,CACtC,MAAM,EAAE,kBAAkB,EAC1B,SAAS,EAAE,MAAM,GAClB,yBAAyB,CAoB3B"}
|
package/dist/v2/hooks/tools.d.ts
CHANGED
|
@@ -11,7 +11,7 @@ import type { V2Context } from "./types";
|
|
|
11
11
|
* mode would let an agent's note or memory land in `context.db` alone, where the
|
|
12
12
|
* module — the authority for both — would never see it.
|
|
13
13
|
*/
|
|
14
|
-
export declare function registerTools(context: V2Context, db: Database, config: MagicContextPluginConfig, rustToolBackends?: RustToolBackends): Promise<{
|
|
14
|
+
export declare function registerTools(context: V2Context, db: Database, config: MagicContextPluginConfig, rustToolBackends?: RustToolBackends, isInternalChild?: (sessionId: string) => boolean): Promise<{
|
|
15
15
|
dispose: () => void;
|
|
16
16
|
}>;
|
|
17
17
|
//# sourceMappingURL=tools.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tools.d.ts","sourceRoot":"","sources":["../../../src/v2/hooks/tools.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,wBAAwB,EAAE,MAAM,cAAc,CAAC;AAO7D,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,iCAAiC,CAAC;
|
|
1
|
+
{"version":3,"file":"tools.d.ts","sourceRoot":"","sources":["../../../src/v2/hooks/tools.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,wBAAwB,EAAE,MAAM,cAAc,CAAC;AAO7D,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,iCAAiC,CAAC;AAExE,OAAO,EAAE,KAAK,QAAQ,EAA6B,MAAM,qBAAqB,CAAC;AAM/E,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,SAAS,CAAC;AAEzC;;;;;;;;GAQG;AACH,wBAAsB,aAAa,CAC/B,OAAO,EAAE,SAAS,EAClB,EAAE,EAAE,QAAQ,EACZ,MAAM,EAAE,wBAAwB,EAChC,gBAAgB,CAAC,EAAE,gBAAgB,EACnC,eAAe,CAAC,EAAE,CAAC,SAAS,EAAE,MAAM,KAAK,OAAO;;GAgGnD"}
|
package/dist/v2/hooks/types.d.ts
CHANGED
|
@@ -78,8 +78,10 @@ export interface V2CommandDomain {
|
|
|
78
78
|
reload(): Promise<void>;
|
|
79
79
|
}
|
|
80
80
|
export interface V2Context {
|
|
81
|
+
/** OpenCode 2 keys a location by directory and, when one is set, workspace. */
|
|
81
82
|
location: {
|
|
82
83
|
directory: string;
|
|
84
|
+
workspaceID?: string;
|
|
83
85
|
};
|
|
84
86
|
agent: V2AgentDomain;
|
|
85
87
|
/** Absent on hosts predating the command domain; registration is then skipped. */
|
|
@@ -149,6 +151,8 @@ export interface V2Context {
|
|
|
149
151
|
hook(name: "execute.before" | "execute.after", callback: (draft: {
|
|
150
152
|
tool: string;
|
|
151
153
|
sessionID: string;
|
|
154
|
+
/** The agent the calling session runs. */
|
|
155
|
+
agent?: string;
|
|
152
156
|
input: unknown;
|
|
153
157
|
status?: string;
|
|
154
158
|
result?: {
|
|
@@ -174,6 +178,12 @@ export interface V2Context {
|
|
|
174
178
|
};
|
|
175
179
|
/** Kept only by hosts that also have the optional `session.remove` declared below. */
|
|
176
180
|
parentID?: string;
|
|
181
|
+
/** Session rules, evaluated after every rule of the session's agent. */
|
|
182
|
+
permissions?: Array<{
|
|
183
|
+
action: string;
|
|
184
|
+
resource: string;
|
|
185
|
+
effect: "allow" | "deny";
|
|
186
|
+
}>;
|
|
177
187
|
}): Promise<{
|
|
178
188
|
id: string;
|
|
179
189
|
}>;
|
|
@@ -186,9 +196,10 @@ export interface V2Context {
|
|
|
186
196
|
variant?: string;
|
|
187
197
|
};
|
|
188
198
|
parentID?: string;
|
|
189
|
-
/** The
|
|
199
|
+
/** The location the host bound the session to when it was created. */
|
|
190
200
|
location?: {
|
|
191
201
|
directory?: string;
|
|
202
|
+
workspaceID?: string;
|
|
192
203
|
};
|
|
193
204
|
}>;
|
|
194
205
|
switchModel(input: {
|
|
@@ -1 +1 @@
|
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B,IAAI,CACA,IAAI,EAAE,SAAS,GAAG,YAAY,GAAG,UAAU,EAC3C,QAAQ,EAAE,CAAC,KAAK,EAAE,cAAc,KAAK,OAAO,CAAC,IAAI,CAAC,GACnD,OAAO,CAAC,OAAO,CAAC,CAAC;QACpB,SAAS,CAAC,KAAK,EAAE;YAAE,SAAS,EAAE,MAAM,CAAA;SAAE,GAAG,OAAO,CAAC;YAAE,WAAW,EAAE,OAAO,CAAA;SAAE,CAAC,CAAC;QAC3E;;;WAGG;QACH,MAAM,CAAC,CAAC,KAAK,EAAE;YAAE,SAAS,EAAE,MAAM,CAAA;SAAE,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;KACxD,CAAC;CACL"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"update-check.d.ts","sourceRoot":"","sources":["../../../src/v2/hooks/update-check.ts"],"names":[],"mappings":"AAOA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,SAAS,CAAC;
|
|
1
|
+
{"version":3,"file":"update-check.d.ts","sourceRoot":"","sources":["../../../src/v2/hooks/update-check.ts"],"names":[],"mappings":"AAOA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,SAAS,CAAC;AA4BzC;;;;;;GAMG;AACH,wBAAgB,4BAA4B,CAAC,MAAM,EAAE,MAAM,EAAE,OAAO,EAAE,MAAM,GAAG,MAAM,CAEpF;AAED;;;GAGG;AACH,wBAAgB,iBAAiB,CAC7B,OAAO,EAAE,IAAI,CAAC,SAAS,EAAE,OAAO,GAAG,SAAS,CAAC,EAC7C,KAAK,GAAE,CAAC,MAAM,EAAE,WAAW,KAAK,OAAO,CAAC,MAAM,GAAG,IAAI,CAKpD;;;EA6CJ"}
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import {
|
|
2
2
|
withSqliteBackgroundWriter,
|
|
3
3
|
withoutSqliteTransformPass
|
|
4
|
-
} from "./server-
|
|
5
|
-
import"./server-
|
|
4
|
+
} from "./server-fg34g6a5.js";
|
|
5
|
+
import"./server-1qbnzc80.js";
|
|
6
6
|
import {
|
|
7
7
|
logSlowWriteTransaction
|
|
8
|
-
} from "./server-
|
|
8
|
+
} from "./server-14vq4kpm.js";
|
|
9
9
|
|
|
10
10
|
// src/features/magic-context/message-time-backfill.ts
|
|
11
11
|
var MESSAGE_TIME_BACKFILL_BATCH_SIZE = 500;
|
|
@@ -1,20 +1,21 @@
|
|
|
1
1
|
import {
|
|
2
|
-
setLogLineForwarder
|
|
3
|
-
|
|
2
|
+
setLogLineForwarder,
|
|
3
|
+
log
|
|
4
|
+
} from "./server-1qbnzc80.js";
|
|
4
5
|
import {
|
|
5
6
|
Database
|
|
6
|
-
} from "./server-
|
|
7
|
+
} from "./server-fg34g6a5.js";
|
|
7
8
|
import {
|
|
8
9
|
runMigrationsWithRetry,
|
|
9
10
|
setSqlitePragmaConfig,
|
|
10
11
|
initializeDatabase
|
|
11
|
-
} from "./server-
|
|
12
|
+
} from "./server-frbm99q5.js";
|
|
13
|
+
import"./server-vs5gpnd4.js";
|
|
12
14
|
import {
|
|
13
15
|
closeQuietly
|
|
14
|
-
} from "./server-
|
|
15
|
-
import"./server-
|
|
16
|
-
import"./server-
|
|
17
|
-
import"./server-fgmxwrgy.js";
|
|
16
|
+
} from "./server-ajzeteqw.js";
|
|
17
|
+
import"./server-51dv1pr5.js";
|
|
18
|
+
import"./server-14vq4kpm.js";
|
|
18
19
|
|
|
19
20
|
// src/features/magic-context/migration-worker.ts
|
|
20
21
|
import { parentPort, workerData } from "node:worker_threads";
|
|
@@ -37,6 +38,10 @@ async function main() {
|
|
|
37
38
|
post({ type: "lock-wait", waiting: false });
|
|
38
39
|
}
|
|
39
40
|
});
|
|
41
|
+
const finished = db;
|
|
42
|
+
db = undefined;
|
|
43
|
+
finished.close();
|
|
44
|
+
log(`[migrations] migration worker connection closed: ${data.dbPath}`);
|
|
40
45
|
post({ type: "done" });
|
|
41
46
|
} catch (error) {
|
|
42
47
|
post({
|
|
@@ -32,18 +32,18 @@ import {
|
|
|
32
32
|
readSessionChunk2,
|
|
33
33
|
getRawSessionMessageIdsThrough2,
|
|
34
34
|
readRawSessionSeedTail2
|
|
35
|
-
} from "./server-
|
|
36
|
-
import"./server-
|
|
37
|
-
import"./server-
|
|
38
|
-
import"./server-
|
|
39
|
-
import"./server-
|
|
40
|
-
import"./server-
|
|
35
|
+
} from "./server-qp5hx1ad.js";
|
|
36
|
+
import"./server-wvjvfhck.js";
|
|
37
|
+
import"./server-1zx87sdm.js";
|
|
38
|
+
import"./server-g0fjrkta.js";
|
|
39
|
+
import"./server-vs5gpnd4.js";
|
|
40
|
+
import"./server-ajzeteqw.js";
|
|
41
41
|
import {
|
|
42
42
|
hasMeaningfulUserText2,
|
|
43
43
|
extractTexts2
|
|
44
|
-
} from "./server-
|
|
45
|
-
import"./server-
|
|
46
|
-
import"./server-
|
|
44
|
+
} from "./server-51dv1pr5.js";
|
|
45
|
+
import"./server-fg34g6a5.js";
|
|
46
|
+
import"./server-1qbnzc80.js";
|
|
47
47
|
export {
|
|
48
48
|
RAW_MESSAGE_VISIT_PAGE_SIZE2 as RAW_MESSAGE_VISIT_PAGE_SIZE,
|
|
49
49
|
RAW_SESSION_TAG_KEY_PAGE_SIZE2 as RAW_SESSION_TAG_KEY_PAGE_SIZE,
|