@openrig/cli 0.7.21 → 0.7.23
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 +7 -7
- package/daemon/assets/onboarding/01-world-and-purpose.md +2 -1
- package/daemon/assets/onboarding/02-self-and-competent-action.md +6 -0
- package/daemon/assets/plugins/openrig/.claude-plugin/plugin.json +1 -1
- package/daemon/assets/plugins/openrig/.codex-plugin/plugin.json +1 -1
- package/daemon/assets/plugins/openrig/.cursor-plugin/plugin.json +1 -1
- package/daemon/assets/plugins/openrig/plugin.json +1 -1
- package/daemon/assets/plugins/openrig-core/.claude-plugin/plugin.json +1 -1
- package/daemon/assets/plugins/openrig-core/.codex-plugin/plugin.json +1 -1
- package/daemon/assets/plugins/openrig-core/hooks/claude.json +22 -0
- package/daemon/assets/plugins/openrig-core/hooks/scripts/activity-relay.cjs +23 -0
- package/daemon/assets/plugins/openrig-core/hooks/scripts/compaction-restore-bridge.cjs +82 -9
- package/daemon/assets/plugins/openrig-core/skills/claude-compaction-restore/scripts/precompact-hook.mjs +138 -20
- package/daemon/assets/plugins/openrig-core/skills/claude-compaction-restore/scripts/restore-from-jsonl.mjs +110 -35
- package/daemon/assets/plugins/openrig-core/skills/messaging-the-human/SKILL.md +1 -1
- package/daemon/assets/plugins/openrig-core/skills/openrig-user/SKILL.md +7 -5
- package/daemon/assets/plugins/openrig-core/skills/refocusing/scripts/trace-to-root.py +32 -6
- package/daemon/assets/skills/rigs/SKILL.md +27 -6
- package/daemon/context-packs/help/help.md +12 -0
- package/daemon/context-packs/help/manifest.yaml +1 -1
- package/daemon/context-packs/onboarding-width/manifest.yaml +1 -1
- package/daemon/context-packs/onboarding-width/public-what-you-can-do.md +27 -7
- package/daemon/context-packs/reference/acp-agents.md +2 -1
- package/daemon/context-packs/reference/getting-started.md +129 -13
- package/daemon/context-packs/reference/manifest.yaml +1 -1
- package/daemon/context-packs/reference/rig-spec.md +210 -7
- package/daemon/context-packs/reference/tmux-servers.md +46 -2
- package/daemon/context-packs/reference/whats-new.md +167 -5
- package/daemon/context-packs/skills/agent-operated-software/manifest.yaml +1 -1
- package/daemon/context-packs/skills/agent-operated-workflows/manifest.yaml +1 -1
- package/daemon/context-packs/skills/applying-a-permission-policy/manifest.yaml +1 -1
- package/daemon/context-packs/skills/claude-compaction-restore/manifest.yaml +1 -1
- package/daemon/context-packs/skills/claude-compaction-restore/scripts/precompact-hook.mjs +138 -20
- package/daemon/context-packs/skills/claude-compaction-restore/scripts/restore-from-jsonl.mjs +110 -35
- package/daemon/context-packs/skills/core/agent-starters/manifest.yaml +1 -1
- package/daemon/context-packs/skills/core/agent-startup-and-context-ingestion/manifest.yaml +1 -1
- package/daemon/context-packs/skills/core/cross-host-rig-commands/manifest.yaml +1 -1
- package/daemon/context-packs/skills/core/human-in-the-loop/manifest.yaml +1 -1
- package/daemon/context-packs/skills/core/messaging-the-human/SKILL.md +1 -1
- package/daemon/context-packs/skills/core/messaging-the-human/manifest.yaml +3 -3
- package/daemon/context-packs/skills/core/openrig-architect/manifest.yaml +1 -1
- package/daemon/context-packs/skills/core/openrig-cmux/manifest.yaml +1 -1
- package/daemon/context-packs/skills/core/openrig-herdr/manifest.yaml +1 -1
- package/daemon/context-packs/skills/core/openrig-skills/manifest.yaml +1 -1
- package/daemon/context-packs/skills/core/openrig-software-factory/manifest.yaml +1 -1
- package/daemon/context-packs/skills/core/openrig-upgrade/manifest.yaml +1 -1
- package/daemon/context-packs/skills/core/rig-bundles-and-shareable-artifacts/manifest.yaml +1 -1
- package/daemon/context-packs/skills/core/rig-lifecycle/manifest.yaml +1 -1
- package/daemon/context-packs/skills/core/session-source-fork/manifest.yaml +1 -1
- package/daemon/context-packs/skills/core/specification-system/manifest.yaml +1 -1
- package/daemon/context-packs/skills/core/topology-mutation-and-seat-management/manifest.yaml +1 -1
- package/daemon/context-packs/skills/core/watchdog/manifest.yaml +1 -1
- package/daemon/context-packs/skills/core/working-with-an-openrig-team/manifest.yaml +1 -1
- package/daemon/context-packs/skills/delegating-work/manifest.yaml +1 -1
- package/daemon/context-packs/skills/forming-an-openrig-mental-model/manifest.yaml +1 -1
- package/daemon/context-packs/skills/loading-addressable-markdown/manifest.yaml +1 -1
- package/daemon/context-packs/skills/mission-slice-sop/manifest.yaml +1 -1
- package/daemon/context-packs/skills/openrig-operating-model/manifest.yaml +1 -1
- package/daemon/context-packs/skills/openrig-user/SKILL.md +7 -5
- package/daemon/context-packs/skills/openrig-user/manifest.yaml +1 -1
- package/daemon/context-packs/skills/orienting-to-an-inherited-seat/manifest.yaml +1 -1
- package/daemon/context-packs/skills/pm/backlog-capture/manifest.yaml +1 -1
- package/daemon/context-packs/skills/pm/context-builder/manifest.yaml +1 -1
- package/daemon/context-packs/skills/pm/exec-summary/manifest.yaml +1 -1
- package/daemon/context-packs/skills/pm/office-hours/manifest.yaml +1 -1
- package/daemon/context-packs/skills/pm/plan-review/manifest.yaml +1 -1
- package/daemon/context-packs/skills/pm/requirements-writer/manifest.yaml +1 -1
- package/daemon/context-packs/skills/pm/ui-mockup/manifest.yaml +1 -1
- package/daemon/context-packs/skills/pods/development-team/manifest.yaml +1 -1
- package/daemon/context-packs/skills/pods/orchestration-team/manifest.yaml +1 -1
- package/daemon/context-packs/skills/pods/oversight-team/manifest.yaml +1 -1
- package/daemon/context-packs/skills/pods/review-team/manifest.yaml +1 -1
- package/daemon/context-packs/skills/process/agent-browser/manifest.yaml +1 -1
- package/daemon/context-packs/skills/process/context-engineering/manifest.yaml +1 -1
- package/daemon/context-packs/skills/process/dogfood/manifest.yaml +1 -1
- package/daemon/context-packs/skills/process/frontend-design/manifest.yaml +1 -1
- package/daemon/context-packs/skills/process/systematic-debugging/manifest.yaml +1 -1
- package/daemon/context-packs/skills/process/test-driven-development/manifest.yaml +1 -1
- package/daemon/context-packs/skills/process/verification-before-completion/manifest.yaml +1 -1
- package/daemon/context-packs/skills/queue-handoff/manifest.yaml +1 -1
- package/daemon/context-packs/skills/refocusing/manifest.yaml +1 -1
- package/daemon/context-packs/skills/refocusing/scripts/trace-to-root.py +32 -6
- package/daemon/context-packs/skills/retiring-and-inheriting-a-seat/manifest.yaml +1 -1
- package/daemon/context-packs/skills/seat-continuity-and-handover/manifest.yaml +1 -1
- package/daemon/context-packs/skills/session-compaction-and-restore/manifest.yaml +1 -1
- package/daemon/context-packs/skills/software-for-agents/manifest.yaml +1 -1
- package/daemon/context-packs/world-example/manifest.yaml +1 -1
- package/daemon/context-packs/world-public/manifest.yaml +1 -1
- package/daemon/dist/adapters/claude-code-adapter.d.ts +14 -1
- package/daemon/dist/adapters/claude-code-adapter.d.ts.map +1 -1
- package/daemon/dist/adapters/claude-code-adapter.js +98 -23
- package/daemon/dist/adapters/claude-code-adapter.js.map +1 -1
- package/daemon/dist/adapters/claude-resume.d.ts +3 -1
- package/daemon/dist/adapters/claude-resume.d.ts.map +1 -1
- package/daemon/dist/adapters/claude-resume.js +35 -11
- package/daemon/dist/adapters/claude-resume.js.map +1 -1
- package/daemon/dist/adapters/claude-settings-transport.d.ts +10 -0
- package/daemon/dist/adapters/claude-settings-transport.d.ts.map +1 -0
- package/daemon/dist/adapters/claude-settings-transport.js +95 -0
- package/daemon/dist/adapters/claude-settings-transport.js.map +1 -0
- package/daemon/dist/adapters/codex-activity-relay.d.ts +6 -0
- package/daemon/dist/adapters/codex-activity-relay.d.ts.map +1 -0
- package/daemon/dist/adapters/codex-activity-relay.js +29 -0
- package/daemon/dist/adapters/codex-activity-relay.js.map +1 -0
- package/daemon/dist/adapters/codex-runtime-adapter.d.ts +2 -1
- package/daemon/dist/adapters/codex-runtime-adapter.d.ts.map +1 -1
- package/daemon/dist/adapters/codex-runtime-adapter.js +30 -17
- package/daemon/dist/adapters/codex-runtime-adapter.js.map +1 -1
- package/daemon/dist/adapters/community-harness-runtime-adapter.d.ts.map +1 -1
- package/daemon/dist/adapters/community-harness-runtime-adapter.js +19 -4
- package/daemon/dist/adapters/community-harness-runtime-adapter.js.map +1 -1
- package/daemon/dist/adapters/pi-recovery-rpc.d.ts +17 -0
- package/daemon/dist/adapters/pi-recovery-rpc.d.ts.map +1 -0
- package/daemon/dist/adapters/pi-recovery-rpc.js +94 -0
- package/daemon/dist/adapters/pi-recovery-rpc.js.map +1 -0
- package/daemon/dist/adapters/pi-runner-protocol.d.ts +6 -0
- package/daemon/dist/adapters/pi-runner-protocol.d.ts.map +1 -1
- package/daemon/dist/adapters/pi-runner-protocol.js.map +1 -1
- package/daemon/dist/adapters/pi-runner.d.ts +77 -0
- package/daemon/dist/adapters/pi-runner.d.ts.map +1 -1
- package/daemon/dist/adapters/pi-runner.js +644 -43
- package/daemon/dist/adapters/pi-runner.js.map +1 -1
- package/daemon/dist/adapters/pi-runtime-adapter.d.ts +6 -0
- package/daemon/dist/adapters/pi-runtime-adapter.d.ts.map +1 -1
- package/daemon/dist/adapters/pi-runtime-adapter.js +11 -0
- package/daemon/dist/adapters/pi-runtime-adapter.js.map +1 -1
- package/daemon/dist/adapters/pi-runtime-recovery.d.ts +10 -0
- package/daemon/dist/adapters/pi-runtime-recovery.d.ts.map +1 -0
- package/daemon/dist/adapters/pi-runtime-recovery.js +82 -0
- package/daemon/dist/adapters/pi-runtime-recovery.js.map +1 -0
- package/daemon/dist/adapters/replace-file.d.ts +5 -2
- package/daemon/dist/adapters/replace-file.d.ts.map +1 -1
- package/daemon/dist/adapters/replace-file.js +6 -3
- package/daemon/dist/adapters/replace-file.js.map +1 -1
- package/daemon/dist/adapters/seat-slice.d.ts +19 -0
- package/daemon/dist/adapters/seat-slice.d.ts.map +1 -0
- package/daemon/dist/adapters/seat-slice.js +29 -0
- package/daemon/dist/adapters/seat-slice.js.map +1 -0
- package/daemon/dist/adapters/shell-quote.d.ts +1 -0
- package/daemon/dist/adapters/shell-quote.d.ts.map +1 -1
- package/daemon/dist/adapters/shell-quote.js +6 -0
- package/daemon/dist/adapters/shell-quote.js.map +1 -1
- package/daemon/dist/adapters/tmux-exec.d.ts.map +1 -1
- package/daemon/dist/adapters/tmux-exec.js +4 -2
- package/daemon/dist/adapters/tmux-exec.js.map +1 -1
- package/daemon/dist/adapters/tmux.d.ts +78 -13
- package/daemon/dist/adapters/tmux.d.ts.map +1 -1
- package/daemon/dist/adapters/tmux.js +361 -82
- package/daemon/dist/adapters/tmux.js.map +1 -1
- package/daemon/dist/build-info.js +3 -3
- package/daemon/dist/daemon-shutdown.d.ts +8 -0
- package/daemon/dist/daemon-shutdown.d.ts.map +1 -1
- package/daemon/dist/daemon-shutdown.js +18 -2
- package/daemon/dist/daemon-shutdown.js.map +1 -1
- package/daemon/dist/db/all-migrations.d.ts.map +1 -1
- package/daemon/dist/db/all-migrations.js +24 -0
- package/daemon/dist/db/all-migrations.js.map +1 -1
- package/daemon/dist/db/migrate.d.ts +15 -1
- package/daemon/dist/db/migrate.d.ts.map +1 -1
- package/daemon/dist/db/migrate.js +41 -6
- package/daemon/dist/db/migrate.js.map +1 -1
- package/daemon/dist/db/migrations/179_remote_control_observations.d.ts +10 -0
- package/daemon/dist/db/migrations/179_remote_control_observations.d.ts.map +1 -0
- package/daemon/dist/db/migrations/179_remote_control_observations.js +20 -0
- package/daemon/dist/db/migrations/179_remote_control_observations.js.map +1 -0
- package/daemon/dist/db/migrations/180_session_stop_attempt.d.ts +5 -0
- package/daemon/dist/db/migrations/180_session_stop_attempt.d.ts.map +1 -0
- package/daemon/dist/db/migrations/180_session_stop_attempt.js +7 -0
- package/daemon/dist/db/migrations/180_session_stop_attempt.js.map +1 -0
- package/daemon/dist/db/migrations/181_node_keep_alive.d.ts +8 -0
- package/daemon/dist/db/migrations/181_node_keep_alive.d.ts.map +1 -0
- package/daemon/dist/db/migrations/181_node_keep_alive.js +26 -0
- package/daemon/dist/db/migrations/181_node_keep_alive.js.map +1 -0
- package/daemon/dist/db/migrations/182_queue_items_blocked_on_index.d.ts +7 -0
- package/daemon/dist/db/migrations/182_queue_items_blocked_on_index.d.ts.map +1 -0
- package/daemon/dist/db/migrations/182_queue_items_blocked_on_index.js +11 -0
- package/daemon/dist/db/migrations/182_queue_items_blocked_on_index.js.map +1 -0
- package/daemon/dist/db/migrations/183_queue_items_scan_indexes.d.ts +8 -0
- package/daemon/dist/db/migrations/183_queue_items_scan_indexes.d.ts.map +1 -0
- package/daemon/dist/db/migrations/183_queue_items_scan_indexes.js +13 -0
- package/daemon/dist/db/migrations/183_queue_items_scan_indexes.js.map +1 -0
- package/daemon/dist/db/migrations/184_network_requests.d.ts +11 -0
- package/daemon/dist/db/migrations/184_network_requests.d.ts.map +1 -0
- package/daemon/dist/db/migrations/184_network_requests.js +32 -0
- package/daemon/dist/db/migrations/184_network_requests.js.map +1 -0
- package/daemon/dist/db/migrations/185_seat_cold_starts.d.ts +9 -0
- package/daemon/dist/db/migrations/185_seat_cold_starts.d.ts.map +1 -0
- package/daemon/dist/db/migrations/185_seat_cold_starts.js +19 -0
- package/daemon/dist/db/migrations/185_seat_cold_starts.js.map +1 -0
- package/daemon/dist/db/migrations/186_queue_relayed_answers.d.ts +3 -0
- package/daemon/dist/db/migrations/186_queue_relayed_answers.d.ts.map +1 -0
- package/daemon/dist/db/migrations/186_queue_relayed_answers.js +5 -0
- package/daemon/dist/db/migrations/186_queue_relayed_answers.js.map +1 -0
- package/daemon/dist/db/migrations/189_rig_seat_slice.d.ts +5 -0
- package/daemon/dist/db/migrations/189_rig_seat_slice.d.ts.map +1 -0
- package/daemon/dist/db/migrations/189_rig_seat_slice.js +7 -0
- package/daemon/dist/db/migrations/189_rig_seat_slice.js.map +1 -0
- package/daemon/dist/db/migrations/190_queue_transfer_staging.d.ts +3 -0
- package/daemon/dist/db/migrations/190_queue_transfer_staging.d.ts.map +1 -0
- package/daemon/dist/db/migrations/190_queue_transfer_staging.js +20 -0
- package/daemon/dist/db/migrations/190_queue_transfer_staging.js.map +1 -0
- package/daemon/dist/db/migrations/191_network_binding_providers.d.ts +3 -0
- package/daemon/dist/db/migrations/191_network_binding_providers.d.ts.map +1 -0
- package/daemon/dist/db/migrations/191_network_binding_providers.js +27 -0
- package/daemon/dist/db/migrations/191_network_binding_providers.js.map +1 -0
- package/daemon/dist/db/migrations/194_workflow_run_title.d.ts +4 -0
- package/daemon/dist/db/migrations/194_workflow_run_title.d.ts.map +1 -0
- package/daemon/dist/db/migrations/194_workflow_run_title.js +6 -0
- package/daemon/dist/db/migrations/194_workflow_run_title.js.map +1 -0
- package/daemon/dist/domain/activity-taxonomy.d.ts +14 -0
- package/daemon/dist/domain/activity-taxonomy.d.ts.map +1 -1
- package/daemon/dist/domain/activity-taxonomy.js.map +1 -1
- package/daemon/dist/domain/agent-activity-store.d.ts +61 -0
- package/daemon/dist/domain/agent-activity-store.d.ts.map +1 -1
- package/daemon/dist/domain/agent-activity-store.js +261 -48
- package/daemon/dist/domain/agent-activity-store.js.map +1 -1
- package/daemon/dist/domain/agent-manifest.d.ts.map +1 -1
- package/daemon/dist/domain/agent-manifest.js +6 -0
- package/daemon/dist/domain/agent-manifest.js.map +1 -1
- package/daemon/dist/domain/bootstrap-orchestrator.d.ts.map +1 -1
- package/daemon/dist/domain/bootstrap-orchestrator.js +14 -3
- package/daemon/dist/domain/bootstrap-orchestrator.js.map +1 -1
- package/daemon/dist/domain/claude-compaction-enforcer.d.ts +58 -2
- package/daemon/dist/domain/claude-compaction-enforcer.d.ts.map +1 -1
- package/daemon/dist/domain/claude-compaction-enforcer.js +142 -9
- package/daemon/dist/domain/claude-compaction-enforcer.js.map +1 -1
- package/daemon/dist/domain/claude-continuation-launch.d.ts +3 -2
- package/daemon/dist/domain/claude-continuation-launch.d.ts.map +1 -1
- package/daemon/dist/domain/claude-continuation-launch.js +12 -11
- package/daemon/dist/domain/claude-continuation-launch.js.map +1 -1
- package/daemon/dist/domain/codex-thread-id.d.ts +20 -2
- package/daemon/dist/domain/codex-thread-id.d.ts.map +1 -1
- package/daemon/dist/domain/codex-thread-id.js +69 -4
- package/daemon/dist/domain/codex-thread-id.js.map +1 -1
- package/daemon/dist/domain/compaction-restore-notice.d.ts +14 -1
- package/daemon/dist/domain/compaction-restore-notice.d.ts.map +1 -1
- package/daemon/dist/domain/compaction-restore-notice.js +174 -19
- package/daemon/dist/domain/compaction-restore-notice.js.map +1 -1
- package/daemon/dist/domain/context-packs/seat-recap-store.d.ts.map +1 -1
- package/daemon/dist/domain/context-packs/seat-recap-store.js +20 -3
- package/daemon/dist/domain/context-packs/seat-recap-store.js.map +1 -1
- package/daemon/dist/domain/continuity-policy-materializer.d.ts.map +1 -1
- package/daemon/dist/domain/continuity-policy-materializer.js +11 -3
- package/daemon/dist/domain/continuity-policy-materializer.js.map +1 -1
- package/daemon/dist/domain/core-app-job.d.ts +4 -4
- package/daemon/dist/domain/core-app-job.d.ts.map +1 -1
- package/daemon/dist/domain/core-app-job.js +4 -59
- package/daemon/dist/domain/core-app-job.js.map +1 -1
- package/daemon/dist/domain/current-work.d.ts +12 -0
- package/daemon/dist/domain/current-work.d.ts.map +1 -1
- package/daemon/dist/domain/current-work.js +4 -0
- package/daemon/dist/domain/current-work.js.map +1 -1
- package/daemon/dist/domain/escalation-owner.d.ts +3 -0
- package/daemon/dist/domain/escalation-owner.d.ts.map +1 -1
- package/daemon/dist/domain/escalation-owner.js +9 -3
- package/daemon/dist/domain/escalation-owner.js.map +1 -1
- package/daemon/dist/domain/execution-candidate-reader.d.ts +3 -0
- package/daemon/dist/domain/execution-candidate-reader.d.ts.map +1 -1
- package/daemon/dist/domain/execution-candidate-reader.js +8 -2
- package/daemon/dist/domain/execution-candidate-reader.js.map +1 -1
- package/daemon/dist/domain/existing-rig-restore.d.ts +2 -0
- package/daemon/dist/domain/existing-rig-restore.d.ts.map +1 -1
- package/daemon/dist/domain/existing-rig-restore.js +11 -1
- package/daemon/dist/domain/existing-rig-restore.js.map +1 -1
- package/daemon/dist/domain/expected-conversation.js +2 -2
- package/daemon/dist/domain/expected-conversation.js.map +1 -1
- package/daemon/dist/domain/gateway/slack/inbound.d.ts +3 -1
- package/daemon/dist/domain/gateway/slack/inbound.d.ts.map +1 -1
- package/daemon/dist/domain/gateway/slack/inbound.js +56 -11
- package/daemon/dist/domain/gateway/slack/inbound.js.map +1 -1
- package/daemon/dist/domain/gateway/slack/message.d.ts +1 -4
- package/daemon/dist/domain/gateway/slack/message.d.ts.map +1 -1
- package/daemon/dist/domain/gateway/slack/message.js +17 -5
- package/daemon/dist/domain/gateway/slack/message.js.map +1 -1
- package/daemon/dist/domain/gateway/slack/notice-content-dedup.d.ts +23 -0
- package/daemon/dist/domain/gateway/slack/notice-content-dedup.d.ts.map +1 -0
- package/daemon/dist/domain/gateway/slack/notice-content-dedup.js +87 -0
- package/daemon/dist/domain/gateway/slack/notice-content-dedup.js.map +1 -0
- package/daemon/dist/domain/gateway/slack/queue-access.d.ts +7 -1
- package/daemon/dist/domain/gateway/slack/queue-access.d.ts.map +1 -1
- package/daemon/dist/domain/gateway/slack/queue-access.js +1 -0
- package/daemon/dist/domain/gateway/slack/queue-access.js.map +1 -1
- package/daemon/dist/domain/gateway/slack/settled-asks.d.ts.map +1 -1
- package/daemon/dist/domain/gateway/slack/settled-asks.js +17 -3
- package/daemon/dist/domain/gateway/slack/settled-asks.js.map +1 -1
- package/daemon/dist/domain/gateway/slack/slack-delivery.d.ts +0 -17
- package/daemon/dist/domain/gateway/slack/slack-delivery.d.ts.map +1 -1
- package/daemon/dist/domain/gateway/slack/slack-delivery.js +10 -40
- package/daemon/dist/domain/gateway/slack/slack-delivery.js.map +1 -1
- package/daemon/dist/domain/gateway/slack/slack-subsystem.d.ts +3 -1
- package/daemon/dist/domain/gateway/slack/slack-subsystem.d.ts.map +1 -1
- package/daemon/dist/domain/gateway/slack/slack-subsystem.js +21 -7
- package/daemon/dist/domain/gateway/slack/slack-subsystem.js.map +1 -1
- package/daemon/dist/domain/harness-not-started-notice.d.ts +5 -2
- package/daemon/dist/domain/harness-not-started-notice.d.ts.map +1 -1
- package/daemon/dist/domain/harness-not-started-notice.js +46 -15
- package/daemon/dist/domain/harness-not-started-notice.js.map +1 -1
- package/daemon/dist/domain/health-passive-ceremony.d.ts.map +1 -1
- package/daemon/dist/domain/health-passive-ceremony.js +3 -2
- package/daemon/dist/domain/health-passive-ceremony.js.map +1 -1
- package/daemon/dist/domain/hosts/read-through.d.ts +1 -1
- package/daemon/dist/domain/hosts/read-through.d.ts.map +1 -1
- package/daemon/dist/domain/hosts/read-through.js +3 -2
- package/daemon/dist/domain/hosts/read-through.js.map +1 -1
- package/daemon/dist/domain/hosts/remote-daemon-http.d.ts +2 -0
- package/daemon/dist/domain/hosts/remote-daemon-http.d.ts.map +1 -1
- package/daemon/dist/domain/hosts/remote-daemon-http.js +1 -1
- package/daemon/dist/domain/hosts/remote-daemon-http.js.map +1 -1
- package/daemon/dist/domain/hot-potato-enforcer.d.ts +3 -3
- package/daemon/dist/domain/hot-potato-enforcer.d.ts.map +1 -1
- package/daemon/dist/domain/hot-potato-enforcer.js +2 -2
- package/daemon/dist/domain/hot-potato-enforcer.js.map +1 -1
- package/daemon/dist/domain/human-questions.d.ts +1 -1
- package/daemon/dist/domain/human-questions.d.ts.map +1 -1
- package/daemon/dist/domain/human-questions.js +2 -0
- package/daemon/dist/domain/human-questions.js.map +1 -1
- package/daemon/dist/domain/input-read-diagnostic.js +1 -1
- package/daemon/dist/domain/input-read-diagnostic.js.map +1 -1
- package/daemon/dist/domain/install-planner.d.ts +8 -0
- package/daemon/dist/domain/install-planner.d.ts.map +1 -1
- package/daemon/dist/domain/install-planner.js +26 -6
- package/daemon/dist/domain/install-planner.js.map +1 -1
- package/daemon/dist/domain/keep-alive-supervisor.d.ts +178 -0
- package/daemon/dist/domain/keep-alive-supervisor.d.ts.map +1 -0
- package/daemon/dist/domain/keep-alive-supervisor.js +523 -0
- package/daemon/dist/domain/keep-alive-supervisor.js.map +1 -0
- package/daemon/dist/domain/mission-control/mission-control-fleet-cli-capability.d.ts +6 -0
- package/daemon/dist/domain/mission-control/mission-control-fleet-cli-capability.d.ts.map +1 -1
- package/daemon/dist/domain/mission-control/mission-control-fleet-cli-capability.js +39 -9
- package/daemon/dist/domain/mission-control/mission-control-fleet-cli-capability.js.map +1 -1
- package/daemon/dist/domain/mission-control/mission-control-write-contract.d.ts.map +1 -1
- package/daemon/dist/domain/mission-control/mission-control-write-contract.js +29 -1
- package/daemon/dist/domain/mission-control/mission-control-write-contract.js.map +1 -1
- package/daemon/dist/domain/model-divergence/current-generation-record.d.ts +4 -1
- package/daemon/dist/domain/model-divergence/current-generation-record.d.ts.map +1 -1
- package/daemon/dist/domain/model-divergence/current-generation-record.js +18 -2
- package/daemon/dist/domain/model-divergence/current-generation-record.js.map +1 -1
- package/daemon/dist/domain/mutation-trace.d.ts +28 -0
- package/daemon/dist/domain/mutation-trace.d.ts.map +1 -0
- package/daemon/dist/domain/mutation-trace.js +38 -0
- package/daemon/dist/domain/mutation-trace.js.map +1 -0
- package/daemon/dist/domain/native-resume-probe.d.ts +13 -3
- package/daemon/dist/domain/native-resume-probe.d.ts.map +1 -1
- package/daemon/dist/domain/native-resume-probe.js +54 -17
- package/daemon/dist/domain/native-resume-probe.js.map +1 -1
- package/daemon/dist/domain/network/hub-client.d.ts +30 -1
- package/daemon/dist/domain/network/hub-client.d.ts.map +1 -1
- package/daemon/dist/domain/network/hub-client.js +62 -9
- package/daemon/dist/domain/network/hub-client.js.map +1 -1
- package/daemon/dist/domain/network/network-bindings.d.ts +52 -2
- package/daemon/dist/domain/network/network-bindings.d.ts.map +1 -1
- package/daemon/dist/domain/network/network-bindings.js +217 -23
- package/daemon/dist/domain/network/network-bindings.js.map +1 -1
- package/daemon/dist/domain/network/network-connector.d.ts +9 -1
- package/daemon/dist/domain/network/network-connector.d.ts.map +1 -1
- package/daemon/dist/domain/network/network-connector.js +95 -7
- package/daemon/dist/domain/network/network-connector.js.map +1 -1
- package/daemon/dist/domain/network/network-installations.d.ts.map +1 -1
- package/daemon/dist/domain/network/network-installations.js +22 -7
- package/daemon/dist/domain/network/network-installations.js.map +1 -1
- package/daemon/dist/domain/network/network-provider-removal.d.ts +9 -0
- package/daemon/dist/domain/network/network-provider-removal.d.ts.map +1 -0
- package/daemon/dist/domain/network/network-provider-removal.js +75 -0
- package/daemon/dist/domain/network/network-provider-removal.js.map +1 -0
- package/daemon/dist/domain/network/network-requests.d.ts +59 -0
- package/daemon/dist/domain/network/network-requests.d.ts.map +1 -0
- package/daemon/dist/domain/network/network-requests.js +476 -0
- package/daemon/dist/domain/network/network-requests.js.map +1 -0
- package/daemon/dist/domain/node-inventory.d.ts +26 -0
- package/daemon/dist/domain/node-inventory.d.ts.map +1 -1
- package/daemon/dist/domain/node-inventory.js +93 -9
- package/daemon/dist/domain/node-inventory.js.map +1 -1
- package/daemon/dist/domain/occupant-invalidator.d.ts +1 -1
- package/daemon/dist/domain/occupant-invalidator.d.ts.map +1 -1
- package/daemon/dist/domain/occupant-invalidator.js +1 -1
- package/daemon/dist/domain/occupant-invalidator.js.map +1 -1
- package/daemon/dist/domain/outbox-handler.d.ts +11 -0
- package/daemon/dist/domain/outbox-handler.d.ts.map +1 -1
- package/daemon/dist/domain/outbox-handler.js +20 -0
- package/daemon/dist/domain/outbox-handler.js.map +1 -1
- package/daemon/dist/domain/package-install-service.d.ts +1 -0
- package/daemon/dist/domain/package-install-service.d.ts.map +1 -1
- package/daemon/dist/domain/package-install-service.js +1 -0
- package/daemon/dist/domain/package-install-service.js.map +1 -1
- package/daemon/dist/domain/parked-owner-escalation.d.ts +16 -0
- package/daemon/dist/domain/parked-owner-escalation.d.ts.map +1 -0
- package/daemon/dist/domain/parked-owner-escalation.js +53 -0
- package/daemon/dist/domain/parked-owner-escalation.js.map +1 -0
- package/daemon/dist/domain/parked-query.d.ts +6 -0
- package/daemon/dist/domain/parked-query.d.ts.map +1 -1
- package/daemon/dist/domain/parked-query.js +20 -7
- package/daemon/dist/domain/parked-query.js.map +1 -1
- package/daemon/dist/domain/permission-stop-observation.d.ts +8 -1
- package/daemon/dist/domain/permission-stop-observation.d.ts.map +1 -1
- package/daemon/dist/domain/permission-stop-observation.js +19 -2
- package/daemon/dist/domain/permission-stop-observation.js.map +1 -1
- package/daemon/dist/domain/policies/parked-owner-consumer.d.ts +13 -0
- package/daemon/dist/domain/policies/parked-owner-consumer.d.ts.map +1 -1
- package/daemon/dist/domain/policies/parked-owner-consumer.js +24 -1
- package/daemon/dist/domain/policies/parked-owner-consumer.js.map +1 -1
- package/daemon/dist/domain/policies/seat-pool.d.ts +15 -1
- package/daemon/dist/domain/policies/seat-pool.d.ts.map +1 -1
- package/daemon/dist/domain/policies/seat-pool.js +31 -8
- package/daemon/dist/domain/policies/seat-pool.js.map +1 -1
- package/daemon/dist/domain/process-census.d.ts +5 -1
- package/daemon/dist/domain/process-census.d.ts.map +1 -1
- package/daemon/dist/domain/process-census.js +20 -11
- package/daemon/dist/domain/process-census.js.map +1 -1
- package/daemon/dist/domain/profile-resolver.d.ts +7 -1
- package/daemon/dist/domain/profile-resolver.d.ts.map +1 -1
- package/daemon/dist/domain/profile-resolver.js +7 -0
- package/daemon/dist/domain/profile-resolver.js.map +1 -1
- package/daemon/dist/domain/progress/progress-indexer.d.ts.map +1 -1
- package/daemon/dist/domain/progress/progress-indexer.js +11 -0
- package/daemon/dist/domain/progress/progress-indexer.js.map +1 -1
- package/daemon/dist/domain/project-lifecycle-compiler.d.ts.map +1 -1
- package/daemon/dist/domain/project-lifecycle-compiler.js +4 -1
- package/daemon/dist/domain/project-lifecycle-compiler.js.map +1 -1
- package/daemon/dist/domain/proof/judgments.d.ts +10 -0
- package/daemon/dist/domain/proof/judgments.d.ts.map +1 -1
- package/daemon/dist/domain/proof/judgments.js +31 -11
- package/daemon/dist/domain/proof/judgments.js.map +1 -1
- package/daemon/dist/domain/proof/source-watch.js +4 -4
- package/daemon/dist/domain/proof/source-watch.js.map +1 -1
- package/daemon/dist/domain/provider/claude-interruption.d.ts +6 -0
- package/daemon/dist/domain/provider/claude-interruption.d.ts.map +1 -1
- package/daemon/dist/domain/provider/claude-interruption.js +18 -0
- package/daemon/dist/domain/provider/claude-interruption.js.map +1 -1
- package/daemon/dist/domain/provider/codex-limit-banner.d.ts +17 -1
- package/daemon/dist/domain/provider/codex-limit-banner.d.ts.map +1 -1
- package/daemon/dist/domain/provider/codex-limit-banner.js +38 -5
- package/daemon/dist/domain/provider/codex-limit-banner.js.map +1 -1
- package/daemon/dist/domain/ps-projection.d.ts +17 -1
- package/daemon/dist/domain/ps-projection.d.ts.map +1 -1
- package/daemon/dist/domain/ps-projection.js +41 -6
- package/daemon/dist/domain/ps-projection.js.map +1 -1
- package/daemon/dist/domain/queue-erasure.d.ts +3 -0
- package/daemon/dist/domain/queue-erasure.d.ts.map +1 -1
- package/daemon/dist/domain/queue-erasure.js +2 -2
- package/daemon/dist/domain/queue-erasure.js.map +1 -1
- package/daemon/dist/domain/queue-owner.d.ts +5 -0
- package/daemon/dist/domain/queue-owner.d.ts.map +1 -1
- package/daemon/dist/domain/queue-owner.js +16 -8
- package/daemon/dist/domain/queue-owner.js.map +1 -1
- package/daemon/dist/domain/queue-read-wait.d.ts +12 -0
- package/daemon/dist/domain/queue-read-wait.d.ts.map +1 -0
- package/daemon/dist/domain/queue-read-wait.js +43 -0
- package/daemon/dist/domain/queue-read-wait.js.map +1 -0
- package/daemon/dist/domain/queue-recorded-graph.d.ts +32 -0
- package/daemon/dist/domain/queue-recorded-graph.d.ts.map +1 -0
- package/daemon/dist/domain/queue-recorded-graph.js +84 -0
- package/daemon/dist/domain/queue-recorded-graph.js.map +1 -0
- package/daemon/dist/domain/queue-repository.d.ts +143 -8
- package/daemon/dist/domain/queue-repository.d.ts.map +1 -1
- package/daemon/dist/domain/queue-repository.js +689 -59
- package/daemon/dist/domain/queue-repository.js.map +1 -1
- package/daemon/dist/domain/queue-retention.d.ts +1 -1
- package/daemon/dist/domain/queue-retention.d.ts.map +1 -1
- package/daemon/dist/domain/queue-retention.js +4 -0
- package/daemon/dist/domain/queue-retention.js.map +1 -1
- package/daemon/dist/domain/queue-stuck-sweep.d.ts +10 -4
- package/daemon/dist/domain/queue-stuck-sweep.d.ts.map +1 -1
- package/daemon/dist/domain/queue-stuck-sweep.js +169 -21
- package/daemon/dist/domain/queue-stuck-sweep.js.map +1 -1
- package/daemon/dist/domain/queue-transfer-export.d.ts +75 -0
- package/daemon/dist/domain/queue-transfer-export.d.ts.map +1 -0
- package/daemon/dist/domain/queue-transfer-export.js +156 -0
- package/daemon/dist/domain/queue-transfer-export.js.map +1 -0
- package/daemon/dist/domain/queue-transfer-format.d.ts +15 -0
- package/daemon/dist/domain/queue-transfer-format.d.ts.map +1 -0
- package/daemon/dist/domain/queue-transfer-format.js +32 -0
- package/daemon/dist/domain/queue-transfer-format.js.map +1 -0
- package/daemon/dist/domain/queue-transfer-parse.d.ts +40 -0
- package/daemon/dist/domain/queue-transfer-parse.d.ts.map +1 -0
- package/daemon/dist/domain/queue-transfer-parse.js +131 -0
- package/daemon/dist/domain/queue-transfer-parse.js.map +1 -0
- package/daemon/dist/domain/queue-transfer-review.d.ts +22 -0
- package/daemon/dist/domain/queue-transfer-review.d.ts.map +1 -0
- package/daemon/dist/domain/queue-transfer-review.js +81 -0
- package/daemon/dist/domain/queue-transfer-review.js.map +1 -0
- package/daemon/dist/domain/queue-transfer-staging.d.ts +79 -0
- package/daemon/dist/domain/queue-transfer-staging.d.ts.map +1 -0
- package/daemon/dist/domain/queue-transfer-staging.js +67 -0
- package/daemon/dist/domain/queue-transfer-staging.js.map +1 -0
- package/daemon/dist/domain/queue-transition-log.js +3 -3
- package/daemon/dist/domain/queue-wake-ladder.d.ts +20 -3
- package/daemon/dist/domain/queue-wake-ladder.d.ts.map +1 -1
- package/daemon/dist/domain/queue-wake-ladder.js +299 -41
- package/daemon/dist/domain/queue-wake-ladder.js.map +1 -1
- package/daemon/dist/domain/reconciler.d.ts +27 -2
- package/daemon/dist/domain/reconciler.d.ts.map +1 -1
- package/daemon/dist/domain/reconciler.js +184 -16
- package/daemon/dist/domain/reconciler.js.map +1 -1
- package/daemon/dist/domain/refusal-trace.d.ts +15 -0
- package/daemon/dist/domain/refusal-trace.d.ts.map +1 -0
- package/daemon/dist/domain/refusal-trace.js +23 -0
- package/daemon/dist/domain/refusal-trace.js.map +1 -0
- package/daemon/dist/domain/relayed-answers.d.ts +80 -0
- package/daemon/dist/domain/relayed-answers.d.ts.map +1 -0
- package/daemon/dist/domain/relayed-answers.js +8 -0
- package/daemon/dist/domain/relayed-answers.js.map +1 -0
- package/daemon/dist/domain/remote-control-observations.d.ts +50 -0
- package/daemon/dist/domain/remote-control-observations.d.ts.map +1 -0
- package/daemon/dist/domain/remote-control-observations.js +72 -0
- package/daemon/dist/domain/remote-control-observations.js.map +1 -0
- package/daemon/dist/domain/restore-attempt-receipt.d.ts.map +1 -1
- package/daemon/dist/domain/restore-attempt-receipt.js +8 -2
- package/daemon/dist/domain/restore-attempt-receipt.js.map +1 -1
- package/daemon/dist/domain/restore-check-service.d.ts.map +1 -1
- package/daemon/dist/domain/restore-check-service.js +3 -2
- package/daemon/dist/domain/restore-check-service.js.map +1 -1
- package/daemon/dist/domain/restore-orchestrator.d.ts +70 -14
- package/daemon/dist/domain/restore-orchestrator.d.ts.map +1 -1
- package/daemon/dist/domain/restore-orchestrator.js +429 -107
- package/daemon/dist/domain/restore-orchestrator.js.map +1 -1
- package/daemon/dist/domain/return-route.d.ts +9 -2
- package/daemon/dist/domain/return-route.d.ts.map +1 -1
- package/daemon/dist/domain/return-route.js +22 -1
- package/daemon/dist/domain/return-route.js.map +1 -1
- package/daemon/dist/domain/rig-lifecycle-service.d.ts.map +1 -1
- package/daemon/dist/domain/rig-lifecycle-service.js +4 -1
- package/daemon/dist/domain/rig-lifecycle-service.js.map +1 -1
- package/daemon/dist/domain/rig-repository.d.ts +38 -3
- package/daemon/dist/domain/rig-repository.d.ts.map +1 -1
- package/daemon/dist/domain/rig-repository.js +95 -3
- package/daemon/dist/domain/rig-repository.js.map +1 -1
- package/daemon/dist/domain/rig-teardown.d.ts +22 -7
- package/daemon/dist/domain/rig-teardown.d.ts.map +1 -1
- package/daemon/dist/domain/rig-teardown.js +108 -24
- package/daemon/dist/domain/rig-teardown.js.map +1 -1
- package/daemon/dist/domain/rigspec-codec.d.ts.map +1 -1
- package/daemon/dist/domain/rigspec-codec.js +12 -0
- package/daemon/dist/domain/rigspec-codec.js.map +1 -1
- package/daemon/dist/domain/rigspec-exporter.d.ts +14 -0
- package/daemon/dist/domain/rigspec-exporter.d.ts.map +1 -1
- package/daemon/dist/domain/rigspec-exporter.js +56 -14
- package/daemon/dist/domain/rigspec-exporter.js.map +1 -1
- package/daemon/dist/domain/rigspec-instantiator.d.ts +32 -3
- package/daemon/dist/domain/rigspec-instantiator.d.ts.map +1 -1
- package/daemon/dist/domain/rigspec-instantiator.js +135 -29
- package/daemon/dist/domain/rigspec-instantiator.js.map +1 -1
- package/daemon/dist/domain/rigspec-preflight.d.ts +4 -1
- package/daemon/dist/domain/rigspec-preflight.d.ts.map +1 -1
- package/daemon/dist/domain/rigspec-preflight.js +9 -1
- package/daemon/dist/domain/rigspec-preflight.js.map +1 -1
- package/daemon/dist/domain/rigspec-schema.d.ts.map +1 -1
- package/daemon/dist/domain/rigspec-schema.js +30 -4
- package/daemon/dist/domain/rigspec-schema.js.map +1 -1
- package/daemon/dist/domain/rosters.d.ts +1 -0
- package/daemon/dist/domain/rosters.d.ts.map +1 -1
- package/daemon/dist/domain/rosters.js +5 -4
- package/daemon/dist/domain/rosters.js.map +1 -1
- package/daemon/dist/domain/runtime-adapter.d.ts +2 -0
- package/daemon/dist/domain/runtime-adapter.d.ts.map +1 -1
- package/daemon/dist/domain/runtime-recovery.d.ts +41 -0
- package/daemon/dist/domain/runtime-recovery.d.ts.map +1 -0
- package/daemon/dist/domain/runtime-recovery.js +2 -0
- package/daemon/dist/domain/runtime-recovery.js.map +1 -0
- package/daemon/dist/domain/seat-activity-service.d.ts +37 -1
- package/daemon/dist/domain/seat-activity-service.d.ts.map +1 -1
- package/daemon/dist/domain/seat-activity-service.js +160 -7
- package/daemon/dist/domain/seat-activity-service.js.map +1 -1
- package/daemon/dist/domain/seat-attention-reconciler.d.ts +7 -0
- package/daemon/dist/domain/seat-attention-reconciler.d.ts.map +1 -1
- package/daemon/dist/domain/seat-attention-reconciler.js +149 -65
- package/daemon/dist/domain/seat-attention-reconciler.js.map +1 -1
- package/daemon/dist/domain/seat-cold-start.d.ts +150 -0
- package/daemon/dist/domain/seat-cold-start.d.ts.map +1 -0
- package/daemon/dist/domain/seat-cold-start.js +371 -0
- package/daemon/dist/domain/seat-cold-start.js.map +1 -0
- package/daemon/dist/domain/seat-delivery-guard.d.ts +11 -2
- package/daemon/dist/domain/seat-delivery-guard.d.ts.map +1 -1
- package/daemon/dist/domain/seat-delivery-guard.js +34 -6
- package/daemon/dist/domain/seat-delivery-guard.js.map +1 -1
- package/daemon/dist/domain/seat-identity-reconciler.d.ts +43 -0
- package/daemon/dist/domain/seat-identity-reconciler.d.ts.map +1 -1
- package/daemon/dist/domain/seat-identity-reconciler.js +109 -23
- package/daemon/dist/domain/seat-identity-reconciler.js.map +1 -1
- package/daemon/dist/domain/seat-identity-store.d.ts +5 -3
- package/daemon/dist/domain/seat-identity-store.d.ts.map +1 -1
- package/daemon/dist/domain/seat-identity-store.js +7 -3
- package/daemon/dist/domain/seat-identity-store.js.map +1 -1
- package/daemon/dist/domain/seat-launch-environment.d.ts +2 -0
- package/daemon/dist/domain/seat-launch-environment.d.ts.map +1 -1
- package/daemon/dist/domain/seat-launch-environment.js +9 -1
- package/daemon/dist/domain/seat-launch-environment.js.map +1 -1
- package/daemon/dist/domain/seat-lifecycle-service.d.ts +17 -0
- package/daemon/dist/domain/seat-lifecycle-service.d.ts.map +1 -1
- package/daemon/dist/domain/seat-lifecycle-service.js +180 -23
- package/daemon/dist/domain/seat-lifecycle-service.js.map +1 -1
- package/daemon/dist/domain/seat-pool-executor.d.ts +116 -0
- package/daemon/dist/domain/seat-pool-executor.d.ts.map +1 -0
- package/daemon/dist/domain/seat-pool-executor.js +565 -0
- package/daemon/dist/domain/seat-pool-executor.js.map +1 -0
- package/daemon/dist/domain/seat-pool-registration.d.ts +93 -0
- package/daemon/dist/domain/seat-pool-registration.d.ts.map +1 -0
- package/daemon/dist/domain/seat-pool-registration.js +149 -0
- package/daemon/dist/domain/seat-pool-registration.js.map +1 -0
- package/daemon/dist/domain/seat-pool-slots.d.ts +42 -0
- package/daemon/dist/domain/seat-pool-slots.d.ts.map +1 -1
- package/daemon/dist/domain/seat-pool-slots.js +51 -0
- package/daemon/dist/domain/seat-pool-slots.js.map +1 -1
- package/daemon/dist/domain/seat-pool-spec.d.ts +10 -0
- package/daemon/dist/domain/seat-pool-spec.d.ts.map +1 -1
- package/daemon/dist/domain/seat-pool-spec.js +22 -2
- package/daemon/dist/domain/seat-pool-spec.js.map +1 -1
- package/daemon/dist/domain/seat-restart-in-place.d.ts +17 -0
- package/daemon/dist/domain/seat-restart-in-place.d.ts.map +1 -1
- package/daemon/dist/domain/seat-restart-in-place.js +57 -4
- package/daemon/dist/domain/seat-restart-in-place.js.map +1 -1
- package/daemon/dist/domain/seat-runtime-home-record.d.ts +8 -0
- package/daemon/dist/domain/seat-runtime-home-record.d.ts.map +1 -1
- package/daemon/dist/domain/seat-runtime-home-record.js +1 -1
- package/daemon/dist/domain/seat-runtime-home-record.js.map +1 -1
- package/daemon/dist/domain/session-registry.d.ts +25 -3
- package/daemon/dist/domain/session-registry.d.ts.map +1 -1
- package/daemon/dist/domain/session-registry.js +47 -6
- package/daemon/dist/domain/session-registry.js.map +1 -1
- package/daemon/dist/domain/session-transport.d.ts +28 -1
- package/daemon/dist/domain/session-transport.d.ts.map +1 -1
- package/daemon/dist/domain/session-transport.js +80 -33
- package/daemon/dist/domain/session-transport.js.map +1 -1
- package/daemon/dist/domain/slices/slice-indexer.d.ts +59 -0
- package/daemon/dist/domain/slices/slice-indexer.d.ts.map +1 -1
- package/daemon/dist/domain/slices/slice-indexer.js +288 -63
- package/daemon/dist/domain/slices/slice-indexer.js.map +1 -1
- package/daemon/dist/domain/slow-op-recorder.d.ts +3 -1
- package/daemon/dist/domain/slow-op-recorder.d.ts.map +1 -1
- package/daemon/dist/domain/slow-op-recorder.js +7 -1
- package/daemon/dist/domain/slow-op-recorder.js.map +1 -1
- package/daemon/dist/domain/startup-orchestrator.d.ts +1 -1
- package/daemon/dist/domain/startup-orchestrator.d.ts.map +1 -1
- package/daemon/dist/domain/startup-orchestrator.js +75 -23
- package/daemon/dist/domain/startup-orchestrator.js.map +1 -1
- package/daemon/dist/domain/startup-proof.d.ts +6 -0
- package/daemon/dist/domain/startup-proof.d.ts.map +1 -1
- package/daemon/dist/domain/startup-proof.js +11 -0
- package/daemon/dist/domain/startup-proof.js.map +1 -1
- package/daemon/dist/domain/startup-submission-evidence.d.ts +2 -0
- package/daemon/dist/domain/startup-submission-evidence.d.ts.map +1 -1
- package/daemon/dist/domain/startup-submission-evidence.js +31 -3
- package/daemon/dist/domain/startup-submission-evidence.js.map +1 -1
- package/daemon/dist/domain/stream-intake.d.ts +10 -1
- package/daemon/dist/domain/stream-intake.d.ts.map +1 -1
- package/daemon/dist/domain/stream-intake.js +27 -0
- package/daemon/dist/domain/stream-intake.js.map +1 -1
- package/daemon/dist/domain/terminal/herdr-adapter.d.ts +7 -0
- package/daemon/dist/domain/terminal/herdr-adapter.d.ts.map +1 -1
- package/daemon/dist/domain/terminal/herdr-adapter.js +5 -3
- package/daemon/dist/domain/terminal/herdr-adapter.js.map +1 -1
- package/daemon/dist/domain/terminal/herdr-follow-view.d.ts +13 -0
- package/daemon/dist/domain/terminal/herdr-follow-view.d.ts.map +1 -1
- package/daemon/dist/domain/terminal/herdr-follow-view.js +126 -3
- package/daemon/dist/domain/terminal/herdr-follow-view.js.map +1 -1
- package/daemon/dist/domain/terminal/herdr-viewer.d.ts +10 -0
- package/daemon/dist/domain/terminal/herdr-viewer.d.ts.map +1 -1
- package/daemon/dist/domain/terminal/herdr-viewer.js +38 -12
- package/daemon/dist/domain/terminal/herdr-viewer.js.map +1 -1
- package/daemon/dist/domain/terminal/scope-task-terminal-view.d.ts +2 -1
- package/daemon/dist/domain/terminal/scope-task-terminal-view.d.ts.map +1 -1
- package/daemon/dist/domain/terminal/scope-task-terminal-view.js +80 -38
- package/daemon/dist/domain/terminal/scope-task-terminal-view.js.map +1 -1
- package/daemon/dist/domain/terminal/terminal-provider.d.ts +2 -0
- package/daemon/dist/domain/terminal/terminal-provider.d.ts.map +1 -1
- package/daemon/dist/domain/terminal/terminal-service.d.ts +3 -0
- package/daemon/dist/domain/terminal/terminal-service.d.ts.map +1 -1
- package/daemon/dist/domain/terminal/terminal-service.js +30 -26
- package/daemon/dist/domain/terminal/terminal-service.js.map +1 -1
- package/daemon/dist/domain/terminal/tile-attach.d.ts +22 -0
- package/daemon/dist/domain/terminal/tile-attach.d.ts.map +1 -1
- package/daemon/dist/domain/terminal/tile-attach.js +71 -0
- package/daemon/dist/domain/terminal/tile-attach.js.map +1 -1
- package/daemon/dist/domain/terminal/view-composer.d.ts +2 -0
- package/daemon/dist/domain/terminal/view-composer.d.ts.map +1 -1
- package/daemon/dist/domain/terminal/view-composer.js +4 -2
- package/daemon/dist/domain/terminal/view-composer.js.map +1 -1
- package/daemon/dist/domain/terminal-server-reachability.d.ts +14 -7
- package/daemon/dist/domain/terminal-server-reachability.d.ts.map +1 -1
- package/daemon/dist/domain/terminal-server-reachability.js +29 -11
- package/daemon/dist/domain/terminal-server-reachability.js.map +1 -1
- package/daemon/dist/domain/terminal-server-seats.d.ts +1 -1
- package/daemon/dist/domain/terminal-server-seats.d.ts.map +1 -1
- package/daemon/dist/domain/terminal-server-seats.js +4 -1
- package/daemon/dist/domain/terminal-server-seats.js.map +1 -1
- package/daemon/dist/domain/topology/remote-up-leaf.d.ts.map +1 -1
- package/daemon/dist/domain/topology/remote-up-leaf.js +41 -2
- package/daemon/dist/domain/topology/remote-up-leaf.js.map +1 -1
- package/daemon/dist/domain/topology-trace.d.ts +40 -0
- package/daemon/dist/domain/topology-trace.d.ts.map +1 -0
- package/daemon/dist/domain/topology-trace.js +106 -0
- package/daemon/dist/domain/topology-trace.js.map +1 -0
- package/daemon/dist/domain/transcript-store.d.ts.map +1 -1
- package/daemon/dist/domain/transcript-store.js +12 -1
- package/daemon/dist/domain/transcript-store.js.map +1 -1
- package/daemon/dist/domain/types.d.ts +111 -14
- package/daemon/dist/domain/types.d.ts.map +1 -1
- package/daemon/dist/domain/types.js +3 -2
- package/daemon/dist/domain/types.js.map +1 -1
- package/daemon/dist/domain/user-settings/settings-browser.d.ts.map +1 -1
- package/daemon/dist/domain/user-settings/settings-browser.js +6 -2
- package/daemon/dist/domain/user-settings/settings-browser.js.map +1 -1
- package/daemon/dist/domain/user-settings/settings-store.d.ts +1 -1
- package/daemon/dist/domain/user-settings/settings-store.d.ts.map +1 -1
- package/daemon/dist/domain/user-settings/settings-store.js +26 -0
- package/daemon/dist/domain/user-settings/settings-store.js.map +1 -1
- package/daemon/dist/domain/watchdog-jobs-repository.d.ts +11 -3
- package/daemon/dist/domain/watchdog-jobs-repository.d.ts.map +1 -1
- package/daemon/dist/domain/watchdog-jobs-repository.js +23 -1
- package/daemon/dist/domain/watchdog-jobs-repository.js.map +1 -1
- package/daemon/dist/domain/watchdog-policy-engine.d.ts +35 -1
- package/daemon/dist/domain/watchdog-policy-engine.d.ts.map +1 -1
- package/daemon/dist/domain/watchdog-policy-engine.js +99 -23
- package/daemon/dist/domain/watchdog-policy-engine.js.map +1 -1
- package/daemon/dist/domain/workflow-instance-store.d.ts +2 -0
- package/daemon/dist/domain/workflow-instance-store.d.ts.map +1 -1
- package/daemon/dist/domain/workflow-instance-store.js +11 -2
- package/daemon/dist/domain/workflow-instance-store.js.map +1 -1
- package/daemon/dist/domain/workflow-projector.d.ts +3 -1
- package/daemon/dist/domain/workflow-projector.d.ts.map +1 -1
- package/daemon/dist/domain/workflow-projector.js +58 -10
- package/daemon/dist/domain/workflow-projector.js.map +1 -1
- package/daemon/dist/domain/workflow-run-title.d.ts +4 -0
- package/daemon/dist/domain/workflow-run-title.d.ts.map +1 -0
- package/daemon/dist/domain/workflow-run-title.js +5 -0
- package/daemon/dist/domain/workflow-run-title.js.map +1 -0
- package/daemon/dist/domain/workflow-runtime.d.ts +4 -0
- package/daemon/dist/domain/workflow-runtime.d.ts.map +1 -1
- package/daemon/dist/domain/workflow-runtime.js +45 -14
- package/daemon/dist/domain/workflow-runtime.js.map +1 -1
- package/daemon/dist/domain/workflow-spec-cache.d.ts +2 -2
- package/daemon/dist/domain/workflow-spec-cache.d.ts.map +1 -1
- package/daemon/dist/domain/workflow-spec-cache.js +20 -1
- package/daemon/dist/domain/workflow-spec-cache.js.map +1 -1
- package/daemon/dist/domain/workflow-types.d.ts +15 -0
- package/daemon/dist/domain/workflow-types.d.ts.map +1 -1
- package/daemon/dist/domain/workflow-types.js +4 -0
- package/daemon/dist/domain/workflow-types.js.map +1 -1
- package/daemon/dist/domain/workspace/project-catalog.d.ts +7 -0
- package/daemon/dist/domain/workspace/project-catalog.d.ts.map +1 -1
- package/daemon/dist/domain/workspace/project-catalog.js +20 -3
- package/daemon/dist/domain/workspace/project-catalog.js.map +1 -1
- package/daemon/dist/domain/workspace/project-read.d.ts +12 -0
- package/daemon/dist/domain/workspace/project-read.d.ts.map +1 -1
- package/daemon/dist/domain/workspace/project-read.js +37 -5
- package/daemon/dist/domain/workspace/project-read.js.map +1 -1
- package/daemon/dist/index.d.ts +2 -2
- package/daemon/dist/index.d.ts.map +1 -1
- package/daemon/dist/index.js +40 -4
- package/daemon/dist/index.js.map +1 -1
- package/daemon/dist/queue-transfer-export-surface.d.ts +33 -0
- package/daemon/dist/queue-transfer-export-surface.d.ts.map +1 -0
- package/daemon/dist/queue-transfer-export-surface.js +13 -0
- package/daemon/dist/queue-transfer-export-surface.js.map +1 -0
- package/daemon/dist/queue-transfer-staging-surface.d.ts +86 -0
- package/daemon/dist/queue-transfer-staging-surface.d.ts.map +1 -0
- package/daemon/dist/queue-transfer-staging-surface.js +91 -0
- package/daemon/dist/queue-transfer-staging-surface.js.map +1 -0
- package/daemon/dist/routes/activity.d.ts +9 -1
- package/daemon/dist/routes/activity.d.ts.map +1 -1
- package/daemon/dist/routes/activity.js +79 -3
- package/daemon/dist/routes/activity.js.map +1 -1
- package/daemon/dist/routes/compaction.d.ts.map +1 -1
- package/daemon/dist/routes/compaction.js +7 -2
- package/daemon/dist/routes/compaction.js.map +1 -1
- package/daemon/dist/routes/context-packs.d.ts.map +1 -1
- package/daemon/dist/routes/context-packs.js +23 -1
- package/daemon/dist/routes/context-packs.js.map +1 -1
- package/daemon/dist/routes/events.js +7 -4
- package/daemon/dist/routes/events.js.map +1 -1
- package/daemon/dist/routes/missions.js +4 -4
- package/daemon/dist/routes/missions.js.map +1 -1
- package/daemon/dist/routes/network.d.ts +2 -0
- package/daemon/dist/routes/network.d.ts.map +1 -1
- package/daemon/dist/routes/network.js +62 -1
- package/daemon/dist/routes/network.js.map +1 -1
- package/daemon/dist/routes/packages.js +2 -0
- package/daemon/dist/routes/packages.js.map +1 -1
- package/daemon/dist/routes/ps.js +13 -2
- package/daemon/dist/routes/ps.js.map +1 -1
- package/daemon/dist/routes/queue.d.ts +22 -1
- package/daemon/dist/routes/queue.d.ts.map +1 -1
- package/daemon/dist/routes/queue.js +250 -69
- package/daemon/dist/routes/queue.js.map +1 -1
- package/daemon/dist/routes/require-sender-identity.d.ts.map +1 -1
- package/daemon/dist/routes/require-sender-identity.js +6 -3
- package/daemon/dist/routes/require-sender-identity.js.map +1 -1
- package/daemon/dist/routes/rigs.js +2 -0
- package/daemon/dist/routes/rigs.js.map +1 -1
- package/daemon/dist/routes/seat.d.ts.map +1 -1
- package/daemon/dist/routes/seat.js +12 -5
- package/daemon/dist/routes/seat.js.map +1 -1
- package/daemon/dist/routes/sessions.d.ts.map +1 -1
- package/daemon/dist/routes/sessions.js +16 -2
- package/daemon/dist/routes/sessions.js.map +1 -1
- package/daemon/dist/routes/slices.d.ts.map +1 -1
- package/daemon/dist/routes/slices.js +16 -7
- package/daemon/dist/routes/slices.js.map +1 -1
- package/daemon/dist/routes/startup.d.ts.map +1 -1
- package/daemon/dist/routes/startup.js +49 -4
- package/daemon/dist/routes/startup.js.map +1 -1
- package/daemon/dist/routes/stream.d.ts.map +1 -1
- package/daemon/dist/routes/stream.js +9 -0
- package/daemon/dist/routes/stream.js.map +1 -1
- package/daemon/dist/routes/terminal-ws.js +28 -2
- package/daemon/dist/routes/terminal-ws.js.map +1 -1
- package/daemon/dist/routes/terminal.d.ts.map +1 -1
- package/daemon/dist/routes/terminal.js +3 -2
- package/daemon/dist/routes/terminal.js.map +1 -1
- package/daemon/dist/routes/transport.d.ts.map +1 -1
- package/daemon/dist/routes/transport.js +14 -2
- package/daemon/dist/routes/transport.js.map +1 -1
- package/daemon/dist/routes/up.js +2 -0
- package/daemon/dist/routes/up.js.map +1 -1
- package/daemon/dist/routes/watchdog.d.ts +1 -1
- package/daemon/dist/routes/watchdog.d.ts.map +1 -1
- package/daemon/dist/routes/watchdog.js +7 -2
- package/daemon/dist/routes/watchdog.js.map +1 -1
- package/daemon/dist/routes/workflow.d.ts.map +1 -1
- package/daemon/dist/routes/workflow.js +9 -3
- package/daemon/dist/routes/workflow.js.map +1 -1
- package/daemon/dist/server.d.ts +7 -0
- package/daemon/dist/server.d.ts.map +1 -1
- package/daemon/dist/server.js +8 -0
- package/daemon/dist/server.js.map +1 -1
- package/daemon/dist/startup.d.ts +3 -0
- package/daemon/dist/startup.d.ts.map +1 -1
- package/daemon/dist/startup.js +226 -17
- package/daemon/dist/startup.js.map +1 -1
- package/daemon/dist/terminal/TerminalSessionBroker.d.ts +10 -0
- package/daemon/dist/terminal/TerminalSessionBroker.d.ts.map +1 -1
- package/daemon/dist/terminal/TerminalSessionBroker.js +63 -4
- package/daemon/dist/terminal/TerminalSessionBroker.js.map +1 -1
- package/daemon/dist/tmux-server-start.d.ts +18 -0
- package/daemon/dist/tmux-server-start.d.ts.map +1 -1
- package/daemon/dist/tmux-server-start.js +29 -0
- package/daemon/dist/tmux-server-start.js.map +1 -1
- package/daemon/dist/topology-trace-surface.d.ts +2 -0
- package/daemon/dist/topology-trace-surface.d.ts.map +1 -0
- package/daemon/dist/topology-trace-surface.js +2 -0
- package/daemon/dist/topology-trace-surface.js.map +1 -0
- package/daemon/docs/reference/acp-agents.md +2 -1
- package/daemon/docs/reference/agent-spec.md +3 -1
- package/daemon/docs/reference/agent-startup-guide.md +3 -1
- package/daemon/docs/reference/agent-state-taxonomy.md +39 -1
- package/daemon/docs/reference/author-contracts.md +4 -0
- package/daemon/docs/reference/checked-seat-stop.md +11 -1
- package/daemon/docs/reference/claude-status-line.md +7 -0
- package/daemon/docs/reference/community-harness-examples/agy/agy-plain.yaml +28 -0
- package/daemon/docs/reference/community-harness-examples/agy/agy.yaml +27 -0
- package/daemon/docs/reference/community-harness-examples/agy/openrig-agy-launch +81 -0
- package/daemon/docs/reference/community-harness-examples/agy/openrig-agy-runner.mjs +667 -0
- package/daemon/docs/reference/community-harness-presets.md +78 -0
- package/daemon/docs/reference/daemon-http-clients.md +133 -20
- package/daemon/docs/reference/gateway-participants.md +6 -0
- package/daemon/docs/reference/getting-started.md +129 -13
- package/daemon/docs/reference/harness-runner-contract.md +7 -5
- package/daemon/docs/reference/help.md +12 -0
- package/daemon/docs/reference/hosted-members.md +163 -2
- package/daemon/docs/reference/inventory-request-diagnostics.md +22 -0
- package/daemon/docs/reference/network-connector.md +112 -4
- package/daemon/docs/reference/project-workspace.md +19 -2
- package/daemon/docs/reference/queue-erasure.md +1 -1
- package/daemon/docs/reference/queue-transfer-export.md +38 -0
- package/daemon/docs/reference/queue-transfer-staging.md +39 -0
- package/daemon/docs/reference/quickstart.md +4 -4
- package/daemon/docs/reference/refocus-channel.md +5 -2
- package/daemon/docs/reference/rig-bundle.md +1 -1
- package/daemon/docs/reference/rig-spec.md +210 -7
- package/daemon/docs/reference/rosters.md +18 -3
- package/daemon/docs/reference/sdlc-conventions.md +6 -2
- package/daemon/docs/reference/seat-delivery.md +41 -7
- package/daemon/docs/reference/seat-pools.md +116 -0
- package/daemon/docs/reference/terminal-sessions.md +57 -11
- package/daemon/docs/reference/tmux-servers.md +46 -2
- package/daemon/docs/reference/whats-new.md +167 -5
- package/daemon/specs/agents/shared/skills/core/messaging-the-human/SKILL.md +1 -1
- package/dist/build-info.js +3 -3
- package/dist/bundle-behaviour.d.ts +1 -1
- package/dist/client.d.ts +2 -1
- package/dist/client.d.ts.map +1 -1
- package/dist/client.js +3 -2
- package/dist/client.js.map +1 -1
- package/dist/commands/broadcast.d.ts.map +1 -1
- package/dist/commands/broadcast.js +89 -8
- package/dist/commands/broadcast.js.map +1 -1
- package/dist/commands/bundle.js +1 -1
- package/dist/commands/bundle.js.map +1 -1
- package/dist/commands/chatroom.d.ts +3 -0
- package/dist/commands/chatroom.d.ts.map +1 -1
- package/dist/commands/chatroom.js +9 -2
- package/dist/commands/chatroom.js.map +1 -1
- package/dist/commands/config-init-workspace.d.ts +1 -1
- package/dist/commands/config.d.ts.map +1 -1
- package/dist/commands/config.js +4 -2
- package/dist/commands/config.js.map +1 -1
- package/dist/commands/daemon.d.ts.map +1 -1
- package/dist/commands/daemon.js +24 -19
- package/dist/commands/daemon.js.map +1 -1
- package/dist/commands/exec.d.ts.map +1 -1
- package/dist/commands/exec.js +22 -13
- package/dist/commands/exec.js.map +1 -1
- package/dist/commands/export.d.ts.map +1 -1
- package/dist/commands/export.js +5 -1
- package/dist/commands/export.js.map +1 -1
- package/dist/commands/gateway.d.ts +4 -0
- package/dist/commands/gateway.d.ts.map +1 -1
- package/dist/commands/gateway.js +37 -0
- package/dist/commands/gateway.js.map +1 -1
- package/dist/commands/mcp.d.ts.map +1 -1
- package/dist/commands/mcp.js +4 -2
- package/dist/commands/mcp.js.map +1 -1
- package/dist/commands/network.d.ts.map +1 -1
- package/dist/commands/network.js +54 -1
- package/dist/commands/network.js.map +1 -1
- package/dist/commands/package.d.ts.map +1 -1
- package/dist/commands/package.js +10 -0
- package/dist/commands/package.js.map +1 -1
- package/dist/commands/parked.d.ts.map +1 -1
- package/dist/commands/parked.js +12 -6
- package/dist/commands/parked.js.map +1 -1
- package/dist/commands/project-jev.d.ts +1 -1
- package/dist/commands/project-worker.d.ts +3 -3
- package/dist/commands/provider.d.ts.map +1 -1
- package/dist/commands/provider.js +3 -2
- package/dist/commands/provider.js.map +1 -1
- package/dist/commands/ps.d.ts +12 -1
- package/dist/commands/ps.d.ts.map +1 -1
- package/dist/commands/ps.js +43 -10
- package/dist/commands/ps.js.map +1 -1
- package/dist/commands/queue-export.d.ts +3 -0
- package/dist/commands/queue-export.d.ts.map +1 -0
- package/dist/commands/queue-export.js +67 -0
- package/dist/commands/queue-export.js.map +1 -0
- package/dist/commands/queue-import.d.ts +4 -0
- package/dist/commands/queue-import.d.ts.map +1 -0
- package/dist/commands/queue-import.js +47 -0
- package/dist/commands/queue-import.js.map +1 -0
- package/dist/commands/queue.d.ts +1 -1
- package/dist/commands/queue.d.ts.map +1 -1
- package/dist/commands/queue.js +56 -1
- package/dist/commands/queue.js.map +1 -1
- package/dist/commands/restore.d.ts.map +1 -1
- package/dist/commands/restore.js +51 -8
- package/dist/commands/restore.js.map +1 -1
- package/dist/commands/roster.d.ts +1 -1
- package/dist/commands/roster.js +1 -1
- package/dist/commands/roster.js.map +1 -1
- package/dist/commands/scope.d.ts.map +1 -1
- package/dist/commands/scope.js +30 -18
- package/dist/commands/scope.js.map +1 -1
- package/dist/commands/seat.d.ts.map +1 -1
- package/dist/commands/seat.js +26 -2
- package/dist/commands/seat.js.map +1 -1
- package/dist/commands/send.d.ts.map +1 -1
- package/dist/commands/send.js +24 -8
- package/dist/commands/send.js.map +1 -1
- package/dist/commands/slack.d.ts +1 -1
- package/dist/commands/snapshot.d.ts.map +1 -1
- package/dist/commands/snapshot.js +29 -10
- package/dist/commands/snapshot.js.map +1 -1
- package/dist/commands/start.d.ts +14 -0
- package/dist/commands/start.d.ts.map +1 -1
- package/dist/commands/start.js +203 -110
- package/dist/commands/start.js.map +1 -1
- package/dist/commands/stream-outcome.d.ts +96 -32
- package/dist/commands/stream-outcome.d.ts.map +1 -1
- package/dist/commands/stream-outcome.js +25 -2
- package/dist/commands/stream-outcome.js.map +1 -1
- package/dist/commands/up.d.ts +2 -4
- package/dist/commands/up.d.ts.map +1 -1
- package/dist/commands/up.js +35 -3
- package/dist/commands/up.js.map +1 -1
- package/dist/commands/watchdog.js +2 -2
- package/dist/commands/watchdog.js.map +1 -1
- package/dist/commands/workflow.d.ts.map +1 -1
- package/dist/commands/workflow.js +8 -1
- package/dist/commands/workflow.js.map +1 -1
- package/dist/config-store.d.ts +3 -1
- package/dist/config-store.d.ts.map +1 -1
- package/dist/config-store.js +27 -1
- package/dist/config-store.js.map +1 -1
- package/dist/cross-host-executor.d.ts +3 -0
- package/dist/cross-host-executor.d.ts.map +1 -1
- package/dist/cross-host-executor.js +5 -0
- package/dist/cross-host-executor.js.map +1 -1
- package/dist/daemon-auto-start.d.ts.map +1 -1
- package/dist/daemon-auto-start.js +1 -0
- package/dist/daemon-auto-start.js.map +1 -1
- package/dist/daemon-lifecycle.d.ts +9 -3
- package/dist/daemon-lifecycle.d.ts.map +1 -1
- package/dist/daemon-lifecycle.js +109 -37
- package/dist/daemon-lifecycle.js.map +1 -1
- package/dist/daemon-start-lock.d.ts +38 -3
- package/dist/daemon-start-lock.d.ts.map +1 -1
- package/dist/daemon-start-lock.js +201 -48
- package/dist/daemon-start-lock.js.map +1 -1
- package/dist/daemon-transport.d.ts +10 -0
- package/dist/daemon-transport.d.ts.map +1 -0
- package/dist/daemon-transport.js +89 -0
- package/dist/daemon-transport.js.map +1 -0
- package/dist/decisions/stream-consumer.d.ts +2 -2
- package/dist/lib/bundle-source.d.ts.map +1 -1
- package/dist/lib/bundle-source.js +2 -1
- package/dist/lib/bundle-source.js.map +1 -1
- package/dist/lib/codex-auth.d.ts +1 -1
- package/dist/lib/context-git.d.ts.map +1 -1
- package/dist/lib/context-git.js +8 -3
- package/dist/lib/context-git.js.map +1 -1
- package/dist/lib/scope/progress-edit.d.ts.map +1 -1
- package/dist/lib/scope/progress-edit.js +10 -0
- package/dist/lib/scope/progress-edit.js.map +1 -1
- package/dist/lib/scope/scope-fs.d.ts.map +1 -1
- package/dist/lib/scope/scope-fs.js +13 -10
- package/dist/lib/scope/scope-fs.js.map +1 -1
- package/dist/lib/topology-trace.d.ts +3 -34
- package/dist/lib/topology-trace.d.ts.map +1 -1
- package/dist/lib/topology-trace.js +3 -97
- package/dist/lib/topology-trace.js.map +1 -1
- package/dist/lib/work-install.d.ts +1 -1
- package/dist/local-db.d.ts +2 -0
- package/dist/local-db.d.ts.map +1 -1
- package/dist/local-db.js +14 -11
- package/dist/local-db.js.map +1 -1
- package/dist/long-request-fetch.d.ts +2 -1
- package/dist/long-request-fetch.d.ts.map +1 -1
- package/dist/long-request-fetch.js +39 -35
- package/dist/long-request-fetch.js.map +1 -1
- package/dist/mcp-caller-resolver.d.ts +36 -0
- package/dist/mcp-caller-resolver.d.ts.map +1 -0
- package/dist/mcp-caller-resolver.js +82 -0
- package/dist/mcp-caller-resolver.js.map +1 -0
- package/dist/mcp-http.d.ts +48 -5
- package/dist/mcp-http.d.ts.map +1 -1
- package/dist/mcp-http.js +303 -61
- package/dist/mcp-http.js.map +1 -1
- package/dist/mcp-server.d.ts +31 -3
- package/dist/mcp-server.d.ts.map +1 -1
- package/dist/mcp-server.js +191 -58
- package/dist/mcp-server.js.map +1 -1
- package/dist/mcp-surface.d.ts +8 -0
- package/dist/mcp-surface.d.ts.map +1 -0
- package/dist/mcp-surface.js +5 -0
- package/dist/mcp-surface.js.map +1 -0
- package/dist/node-support.d.ts.map +1 -1
- package/dist/node-support.js +10 -0
- package/dist/node-support.js.map +1 -1
- package/dist/release-surface/extract-surface.d.ts.map +1 -1
- package/dist/release-surface/extract-surface.js +14 -2
- package/dist/release-surface/extract-surface.js.map +1 -1
- package/dist/remote-host-ops.d.ts +3 -0
- package/dist/remote-host-ops.d.ts.map +1 -1
- package/dist/remote-host-ops.js +15 -1
- package/dist/remote-host-ops.js.map +1 -1
- package/dist/snapshot-rig-handle.d.ts +12 -0
- package/dist/snapshot-rig-handle.d.ts.map +1 -0
- package/dist/snapshot-rig-handle.js +39 -0
- package/dist/snapshot-rig-handle.js.map +1 -0
- package/mcp.d.ts +1 -0
- package/mcp.js +1 -0
- package/package.json +8 -5
- package/scripts/check-abi.mjs +15 -0
- package/tui/dist/attention/attention-model.d.ts +1 -1
- package/tui/dist/attention/attention-model.d.ts.map +1 -1
- package/tui/dist/attention/attention-model.js +8 -4
- package/tui/dist/attention/attention-model.js.map +1 -1
- package/tui/dist/attention/source-continuity.d.ts +1 -1
- package/tui/dist/crash-cart/start-daemon.d.ts +20 -0
- package/tui/dist/crash-cart/start-daemon.d.ts.map +1 -1
- package/tui/dist/crash-cart/start-daemon.js +56 -0
- package/tui/dist/crash-cart/start-daemon.js.map +1 -1
- package/tui/dist/execution/execution-model.d.ts +2 -0
- package/tui/dist/execution/execution-model.d.ts.map +1 -1
- package/tui/dist/execution/execution-model.js +27 -5
- package/tui/dist/execution/execution-model.js.map +1 -1
- package/tui/dist/execution/workflow-model.d.ts.map +1 -1
- package/tui/dist/execution/workflow-model.js +2 -1
- package/tui/dist/execution/workflow-model.js.map +1 -1
- package/tui/dist/hydrate.d.ts.map +1 -1
- package/tui/dist/hydrate.js +4 -2
- package/tui/dist/hydrate.js.map +1 -1
- package/tui/dist/main.js +26 -9
- package/tui/dist/main.js.map +1 -1
- package/tui/dist/print-for-copy.d.ts +7 -1
- package/tui/dist/print-for-copy.d.ts.map +1 -1
- package/tui/dist/print-for-copy.js +10 -3
- package/tui/dist/print-for-copy.js.map +1 -1
- package/tui/dist/render.d.ts +2 -0
- package/tui/dist/render.d.ts.map +1 -1
- package/tui/dist/render.js +75 -19
- package/tui/dist/render.js.map +1 -1
- package/tui/dist/socket-copy.d.ts +6 -0
- package/tui/dist/socket-copy.d.ts.map +1 -0
- package/tui/dist/socket-copy.js +13 -0
- package/tui/dist/socket-copy.js.map +1 -0
- package/tui/dist/terminal-safe-text.d.ts +39 -0
- package/tui/dist/terminal-safe-text.d.ts.map +1 -0
- package/tui/dist/terminal-safe-text.js +44 -0
- package/tui/dist/terminal-safe-text.js.map +1 -0
- package/tui/dist/topology/host-label.js +5 -5
- package/tui/dist/topology/host-label.js.map +1 -1
- package/tui/dist/types.d.ts +3 -3
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type { CatalogMissionsRoots } from "../workspace/project-read.js";
|
|
1
2
|
import type Database from "better-sqlite3";
|
|
2
3
|
export type SliceStatus = "active" | "done" | "closed" | "blocked" | "draft";
|
|
3
4
|
declare const QUEUE_COUNT_STATES: readonly ["pending", "in-progress", "done", "blocked", "failed", "denied", "canceled", "handed-off"];
|
|
@@ -101,6 +102,10 @@ export interface SliceIndexerOpts {
|
|
|
101
102
|
slicesRoot: string;
|
|
102
103
|
/** Additional compatible roots to scan after the primary root. */
|
|
103
104
|
additionalSliceRoots?: string[];
|
|
105
|
+
/** Catalogued projects' missions roots (#3553). Carried for terminal mission/slice view index contexts only; the indexer's own listing keeps using `slicesRoot` + `additionalSliceRoots`.
|
|
106
|
+
* When a getter is given, the roots are re-read on every access, so a project added after daemon start joins terminal scope resolution without a restart.
|
|
107
|
+
* The getter also names the roots it couldn't read, so a scope that may live there reads as unavailable, not gone. */
|
|
108
|
+
catalogMissionsRoots?: readonly string[] | (() => CatalogMissionsRoots);
|
|
104
109
|
/** Root directory containing dogfood-evidence directories. */
|
|
105
110
|
dogfoodEvidenceRoot: string | null;
|
|
106
111
|
/** SQLite handle for read-only joins to queue_items + transitions + actions. */
|
|
@@ -110,6 +115,10 @@ export interface SliceIndexerOpts {
|
|
|
110
115
|
}
|
|
111
116
|
/** The bucket a slice's frontmatter `status:` word falls in, as `GET /api/slices` reports it (sdlc-conventions.md A2). */
|
|
112
117
|
export declare function sliceStatusBucket(raw: string | undefined): SliceStatus;
|
|
118
|
+
export type QueueCountRow = {
|
|
119
|
+
state: string;
|
|
120
|
+
tags: string | null;
|
|
121
|
+
};
|
|
113
122
|
export declare class SliceIndexer {
|
|
114
123
|
readonly projectId?: string;
|
|
115
124
|
/** `projectId` and its declared former ids: the tags this indexer's project membership accepts. */
|
|
@@ -124,16 +133,24 @@ export declare class SliceIndexer {
|
|
|
124
133
|
* the db handle elsewhere. Internal callers continue to use it
|
|
125
134
|
* the same way; read-only consumer outside the class. */
|
|
126
135
|
readonly db: Database.Database;
|
|
136
|
+
private readonly catalogMissionsRootsSource;
|
|
127
137
|
private readonly cacheTtlMs;
|
|
128
138
|
private listingCache;
|
|
129
139
|
private detailCache;
|
|
130
140
|
private membershipIndex;
|
|
141
|
+
private preparedMembership;
|
|
142
|
+
private invalidations;
|
|
131
143
|
private idAliases;
|
|
132
144
|
private missionAliases;
|
|
133
145
|
private batchDepth;
|
|
134
146
|
private compositionBasis;
|
|
135
147
|
private missionStatusCache;
|
|
136
148
|
constructor(opts: SliceIndexerOpts);
|
|
149
|
+
/** The walkable catalog roots (catalogRoots().roots). */
|
|
150
|
+
get catalogMissionsRoots(): readonly string[];
|
|
151
|
+
/** The catalog's walkable and unreadable roots from one read: an array source unchanged with none unreadable, or a
|
|
152
|
+
* getter called on every access. Any throw degrades to none, so catalog discovery failure keeps today's fallback. */
|
|
153
|
+
catalogRoots(): CatalogMissionsRoots;
|
|
137
154
|
/** Returns true when any configured slice root exists on disk. */
|
|
138
155
|
isReady(): boolean;
|
|
139
156
|
/** The explicit COMPOSITE-OPERATION scope: a
|
|
@@ -182,7 +199,27 @@ export declare class SliceIndexer {
|
|
|
182
199
|
* doc above; the lockstep test pins both reads agree on the same bytes). */
|
|
183
200
|
private readMissionAuthoredStatus;
|
|
184
201
|
list(): SliceListEntry[];
|
|
202
|
+
/** The folder of the mission whose first slice list() would show, or null when
|
|
203
|
+
* no listed slice belongs to it. Walks the same locations as list() but builds
|
|
204
|
+
* no listing entries, so it never reads queue membership. */
|
|
205
|
+
missionPath(missionId: string): string | null;
|
|
185
206
|
get(name: string): SliceRecord | null;
|
|
207
|
+
/** get(), for a route: when the record isn't cached, its membership scans are read first on their own read-only
|
|
208
|
+
* connection, one rowid window at a time, yielding to the event loop between windows (readRowsCooperatively).
|
|
209
|
+
* A standalone get() otherwise reads every queue row, bodies included, in one synchronous stretch. The record is
|
|
210
|
+
* then built exactly as get() builds it, from that index. Inside an open withMembershipBatch scope, or when the
|
|
211
|
+
* read can't run cooperatively (a transaction, a memory database or a non-WAL file), this is get(). */
|
|
212
|
+
getCooperatively(name: string): Promise<SliceRecord | null>;
|
|
213
|
+
/** withMembershipBatch(), for a route whose batch starts with list(): when the listing isn't cached, the batch's
|
|
214
|
+
* membership index is read first as getCooperatively reads it, then `fn` runs in the batch with that index. */
|
|
215
|
+
withMembershipBatchCooperatively<T>(fn: () => T): Promise<T>;
|
|
216
|
+
/** Reads the membership index for `served` cooperatively, then runs `fn` with it as the next membership build. An
|
|
217
|
+
* invalidate() during the read's awaits makes that index older than the caches `fn` fills: the request is still
|
|
218
|
+
* answered from it, as of the read's start, and nothing it cached is kept. */
|
|
219
|
+
private withCooperativeMembership;
|
|
220
|
+
/** Runs `fn` with `index` as the next membership build for `served`. The await that read it is over, so nothing
|
|
221
|
+
* else runs between here and that build; a cache drop in between (invalidate) discards it. */
|
|
222
|
+
private withPreparedMembership;
|
|
186
223
|
private reconcileComposition;
|
|
187
224
|
/** The `slice:` tag values that name this slice: its directory name and, when
|
|
188
225
|
* its node file declares one that no other slice shares, its frontmatter id. */
|
|
@@ -206,7 +243,20 @@ export declare class SliceIndexer {
|
|
|
206
243
|
additionalSliceRoots?: readonly string[];
|
|
207
244
|
complete?: boolean;
|
|
208
245
|
canonicalProjectId?: (id: string) => string;
|
|
246
|
+
/** Hands over the per-row count instead of running the statement: the caller runs it over rows it read itself
|
|
247
|
+
* (readQueueCountRowsCooperatively, countQueueRowsCooperatively), filling the returned counts in place. It's
|
|
248
|
+
* not called when there's nothing to count. */
|
|
249
|
+
deferRows?: (countRow: (row: QueueCountRow) => void) => void;
|
|
209
250
|
}): Map<string, SliceQueueCounts | null>;
|
|
251
|
+
/** observedQueueCounts' rows, read on their own read-only connection one rowid window at a time, yielding to the event
|
|
252
|
+
* loop between windows (readRowsCooperatively), for a route to pass in as `rows` before its synchronous work. The
|
|
253
|
+
* statement reads every row's tags, which sit past its body, in one stretch. Null when the read can't run this way
|
|
254
|
+
* (a transaction, a memory database or a non-WAL file) or there's no tags column: the count then reads them itself. */
|
|
255
|
+
/** Runs a deferred count (observedQueueCounts' deferRows) over the rows in time-sized chunks, yielding to the event
|
|
256
|
+
* loop between chunks, so counting a large queue's tagged rows isn't one synchronous stretch. A chunk ends once it
|
|
257
|
+
* has run `targetMs`; each row is counted once, in order. */
|
|
258
|
+
countQueueRowsCooperatively(rows: readonly QueueCountRow[], countRow: (row: QueueCountRow) => void, targetMs?: number): Promise<void>;
|
|
259
|
+
readQueueCountRowsCooperatively(): Promise<QueueCountRow[] | null>;
|
|
210
260
|
private readSliceLocations;
|
|
211
261
|
/** Every slice location under the roots. A requested mission is filtered before
|
|
212
262
|
* directory-name deduplication; otherwise the first matching name wins unless
|
|
@@ -277,6 +327,15 @@ export declare class SliceIndexer {
|
|
|
277
327
|
* and the all-location typedMissions verdict are established FIRST, so the
|
|
278
328
|
* cross-slice modern/legacy rule stays byte-identical (R5 differential). */
|
|
279
329
|
private ensureMembershipIndex;
|
|
330
|
+
/** The membership build readRowsCooperatively drives: the same scans, read on their own read-only connection one
|
|
331
|
+
* rowid window at a time, yielding to the event loop between windows. Each scan is one read transaction, so the
|
|
332
|
+
* fallback scan's snapshot can be newer than the typed scan's. A read or build failure propagates and nothing is
|
|
333
|
+
* published; the caller hands the index to the next build (withPreparedMembership). */
|
|
334
|
+
private readMembershipIndexCooperatively;
|
|
335
|
+
/** One membership build (ensureMembershipIndex's doc above), as a generator that asks its driver for each scan's
|
|
336
|
+
* rows: the typed scan's in TYPED_MEMBERSHIP_SQL's order, then the fallback scan's in rowid-ordered batches ending
|
|
337
|
+
* with null. It reads frontmatter and builds the maps itself, so both drivers build the same index. */
|
|
338
|
+
private membershipBuild;
|
|
280
339
|
private discoverMissionIds;
|
|
281
340
|
private proofDirectoryMissionOwner;
|
|
282
341
|
private findProofPacket;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"slice-indexer.d.ts","sourceRoot":"","sources":["../../../src/domain/slices/slice-indexer.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"slice-indexer.d.ts","sourceRoot":"","sources":["../../../src/domain/slices/slice-indexer.ts"],"names":[],"mappings":"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"}
|
|
@@ -17,7 +17,9 @@ import * as fs from "node:fs";
|
|
|
17
17
|
import * as path from "node:path";
|
|
18
18
|
import { parseScopeTags } from "./qitem-membership.js";
|
|
19
19
|
import { AsciiLiteralMatcher } from "./ascii-literal-matcher.js";
|
|
20
|
+
import { cooperativeReadFile, readRowsCooperatively } from "../execution-candidate-reader.js";
|
|
20
21
|
import { NODE_FILE_PRECEDENCE, resolveNodeFile, withSpecFirst } from "../scope/node-file.js";
|
|
22
|
+
import { runSyncSite } from "../sync-site-wrap.js";
|
|
21
23
|
const QUEUE_COUNT_STATES = [
|
|
22
24
|
"pending",
|
|
23
25
|
"in-progress",
|
|
@@ -88,6 +90,56 @@ function parseTypedQueueScope(rawTags) {
|
|
|
88
90
|
}
|
|
89
91
|
return { projects, missions, slices };
|
|
90
92
|
}
|
|
93
|
+
const TYPED_MEMBERSHIP_SQL = `SELECT qitem_id, tags FROM queue_items WHERE tags LIKE '%slice:%' ORDER BY ts_created DESC, qitem_id DESC`;
|
|
94
|
+
const FALLBACK_MEMBERSHIP_SQL = `SELECT qitem_id, body, tags FROM queue_items`;
|
|
95
|
+
const FALLBACK_BODY_MEMBERSHIP_SQL = `SELECT qitem_id, body FROM queue_items`;
|
|
96
|
+
// The same scans one rowid window at a time, for readRowsCooperatively. The typed window carries ts_created so the
|
|
97
|
+
// rows can be put in TYPED_MEMBERSHIP_SQL's order afterwards.
|
|
98
|
+
const WINDOW = `queue_items.rowid > ? AND queue_items.rowid <= ?`;
|
|
99
|
+
const TYPED_MEMBERSHIP_WINDOW_SQL = `SELECT qitem_id, tags, ts_created FROM queue_items WHERE ${WINDOW} AND tags LIKE '%slice:%'`;
|
|
100
|
+
const FALLBACK_MEMBERSHIP_WINDOW_SQL = `SELECT qitem_id, body, tags FROM queue_items WHERE ${WINDOW}`;
|
|
101
|
+
const FALLBACK_BODY_MEMBERSHIP_WINDOW_SQL = `SELECT qitem_id, body FROM queue_items WHERE ${WINDOW}`;
|
|
102
|
+
/** SQLite's ascending order for one column value: NULL, then numbers, then text by its UTF-8 bytes (BINARY), then
|
|
103
|
+
* blobs by their bytes. Nothing is allocated per comparison: the typed sort makes O(n log n) of them. */
|
|
104
|
+
function compareSqliteValues(a, b) {
|
|
105
|
+
const rank = (v) => v === null || v === undefined ? 0 : typeof v === "number" || typeof v === "bigint" ? 1 : typeof v === "string" ? 2 : 3;
|
|
106
|
+
const ra = rank(a), rb = rank(b);
|
|
107
|
+
if (ra !== rb)
|
|
108
|
+
return ra - rb;
|
|
109
|
+
if (ra === 0)
|
|
110
|
+
return 0;
|
|
111
|
+
if (ra === 1)
|
|
112
|
+
return a < b ? -1 : a > b ? 1 : 0;
|
|
113
|
+
if (ra === 2)
|
|
114
|
+
return compareUtf8(a, b);
|
|
115
|
+
return Buffer.compare(a, b);
|
|
116
|
+
}
|
|
117
|
+
/** Two strings in the order of their UTF-8 bytes, which is code point order. UTF-16 unit order differs only where a
|
|
118
|
+
* surrogate (U+D800-DFFF, half of a code point above U+FFFF) meets a unit in U+E000-FFFF: moving surrogates above
|
|
119
|
+
* that range at the first differing unit gives code point order. */
|
|
120
|
+
function compareUtf8(a, b) {
|
|
121
|
+
const n = Math.min(a.length, b.length);
|
|
122
|
+
for (let i = 0; i < n; i++) {
|
|
123
|
+
let x = a.charCodeAt(i), y = b.charCodeAt(i);
|
|
124
|
+
if (x === y)
|
|
125
|
+
continue;
|
|
126
|
+
if (x >= 0xd800 && y >= 0xd800) {
|
|
127
|
+
x = x >= 0xe000 ? x - 0x800 : x + 0x2000;
|
|
128
|
+
y = y >= 0xe000 ? y - 0x800 : y + 0x2000;
|
|
129
|
+
}
|
|
130
|
+
return x - y;
|
|
131
|
+
}
|
|
132
|
+
return a.length - b.length;
|
|
133
|
+
}
|
|
134
|
+
/** Puts windowed typed rows in TYPED_MEMBERSHIP_SQL's order: ts_created DESC, then qitem_id DESC. */
|
|
135
|
+
function inTypedMembershipOrder(rows) {
|
|
136
|
+
return rows.sort((a, b) => compareSqliteValues(b.ts_created, a.ts_created) || compareSqliteValues(b.qitem_id, a.qitem_id));
|
|
137
|
+
}
|
|
138
|
+
function sameServedScope(a, b) {
|
|
139
|
+
if (a === null || b === null)
|
|
140
|
+
return a === b;
|
|
141
|
+
return a.size === b.size && [...a].every((name) => b.has(name));
|
|
142
|
+
}
|
|
91
143
|
// --- SQL-LIKE-equivalent matching -------------------------
|
|
92
144
|
// SQLite LIKE semantics, replicated byte-for-byte (test-pinned):
|
|
93
145
|
// - ASCII-ONLY case folding (A-Z <-> a-z; æ vs Æ do NOT fold),
|
|
@@ -192,6 +244,9 @@ export function sliceStatusBucket(raw) {
|
|
|
192
244
|
return "draft";
|
|
193
245
|
return "active";
|
|
194
246
|
}
|
|
247
|
+
const QUEUE_COUNT_SQL = `SELECT state, tags FROM queue_items WHERE tags LIKE '%slice:%'`;
|
|
248
|
+
// The same rows one rowid window at a time, for readRowsCooperatively. The count is per row, so their order is free.
|
|
249
|
+
const QUEUE_COUNT_WINDOW_SQL = `SELECT state, tags FROM queue_items WHERE queue_items.rowid > ? AND queue_items.rowid <= ? AND tags LIKE '%slice:%'`;
|
|
195
250
|
export class SliceIndexer {
|
|
196
251
|
projectId;
|
|
197
252
|
/** `projectId` and its declared former ids: the tags this indexer's project membership accepts. */
|
|
@@ -206,11 +261,16 @@ export class SliceIndexer {
|
|
|
206
261
|
* the db handle elsewhere. Internal callers continue to use it
|
|
207
262
|
* the same way; read-only consumer outside the class. */
|
|
208
263
|
db;
|
|
264
|
+
catalogMissionsRootsSource;
|
|
209
265
|
cacheTtlMs;
|
|
210
266
|
listingCache = null;
|
|
211
267
|
detailCache = new Map();
|
|
212
268
|
// batch membership index (see MembershipIndex doc).
|
|
213
269
|
membershipIndex = null;
|
|
270
|
+
// An index read cooperatively for the next build with the same served scope (getCooperatively).
|
|
271
|
+
preparedMembership = null;
|
|
272
|
+
// Counts invalidate() calls, so a cooperative read can tell that one landed during its awaits.
|
|
273
|
+
invalidations = 0;
|
|
214
274
|
// Slice id <-> directory name map, built once per cache window (same TTL as the listing).
|
|
215
275
|
idAliases = null;
|
|
216
276
|
missionAliases = null;
|
|
@@ -225,10 +285,27 @@ export class SliceIndexer {
|
|
|
225
285
|
this.missionId = opts.missionId;
|
|
226
286
|
this.slicesRoot = opts.slicesRoot;
|
|
227
287
|
this.additionalSliceRoots = opts.additionalSliceRoots ?? [];
|
|
288
|
+
this.catalogMissionsRootsSource = opts.catalogMissionsRoots ?? [];
|
|
228
289
|
this.dogfoodEvidenceRoot = opts.dogfoodEvidenceRoot;
|
|
229
290
|
this.db = opts.db;
|
|
230
291
|
this.cacheTtlMs = opts.cacheTtlMs ?? DEFAULT_CACHE_TTL_MS;
|
|
231
292
|
}
|
|
293
|
+
/** The walkable catalog roots (catalogRoots().roots). */
|
|
294
|
+
get catalogMissionsRoots() {
|
|
295
|
+
return this.catalogRoots().roots;
|
|
296
|
+
}
|
|
297
|
+
/** The catalog's walkable and unreadable roots from one read: an array source unchanged with none unreadable, or a
|
|
298
|
+
* getter called on every access. Any throw degrades to none, so catalog discovery failure keeps today's fallback. */
|
|
299
|
+
catalogRoots() {
|
|
300
|
+
if (typeof this.catalogMissionsRootsSource !== "function")
|
|
301
|
+
return { roots: this.catalogMissionsRootsSource, unavailable: [] };
|
|
302
|
+
try {
|
|
303
|
+
return this.catalogMissionsRootsSource();
|
|
304
|
+
}
|
|
305
|
+
catch {
|
|
306
|
+
return { roots: [], unavailable: [] };
|
|
307
|
+
}
|
|
308
|
+
}
|
|
232
309
|
/** Returns true when any configured slice root exists on disk. */
|
|
233
310
|
isReady() {
|
|
234
311
|
return this.sliceRoots().some((root) => this.isDirectory(root));
|
|
@@ -267,10 +344,12 @@ export class SliceIndexer {
|
|
|
267
344
|
}
|
|
268
345
|
/** Drops both caches. Used by tests + by a future explicit-refresh route. */
|
|
269
346
|
invalidate() {
|
|
347
|
+
this.invalidations++;
|
|
270
348
|
this.listingCache = null;
|
|
271
349
|
this.detailCache.clear();
|
|
272
350
|
this.missionStatusCache = null;
|
|
273
351
|
this.membershipIndex = null;
|
|
352
|
+
this.preparedMembership = null;
|
|
274
353
|
this.idAliases = null;
|
|
275
354
|
this.missionAliases = null;
|
|
276
355
|
}
|
|
@@ -374,6 +453,15 @@ export class SliceIndexer {
|
|
|
374
453
|
this.listingCache = { entries, expiresAt: now + this.cacheTtlMs };
|
|
375
454
|
return entries;
|
|
376
455
|
}
|
|
456
|
+
/** The folder of the mission whose first slice list() would show, or null when
|
|
457
|
+
* no listed slice belongs to it. Walks the same locations as list() but builds
|
|
458
|
+
* no listing entries, so it never reads queue membership. */
|
|
459
|
+
missionPath(missionId) {
|
|
460
|
+
if (!this.isReady())
|
|
461
|
+
return null;
|
|
462
|
+
const location = this.readSliceLocations().find((candidate) => candidate.missionId === missionId);
|
|
463
|
+
return location ? path.resolve(location.slicePath, "..", "..") : null;
|
|
464
|
+
}
|
|
377
465
|
get(name) {
|
|
378
466
|
if (!this.isReady())
|
|
379
467
|
return null;
|
|
@@ -404,6 +492,58 @@ export class SliceIndexer {
|
|
|
404
492
|
this.detailCache.set(name, { record, expiresAt: now + this.cacheTtlMs });
|
|
405
493
|
return record;
|
|
406
494
|
}
|
|
495
|
+
/** get(), for a route: when the record isn't cached, its membership scans are read first on their own read-only
|
|
496
|
+
* connection, one rowid window at a time, yielding to the event loop between windows (readRowsCooperatively).
|
|
497
|
+
* A standalone get() otherwise reads every queue row, bodies included, in one synchronous stretch. The record is
|
|
498
|
+
* then built exactly as get() builds it, from that index. Inside an open withMembershipBatch scope, or when the
|
|
499
|
+
* read can't run cooperatively (a transaction, a memory database or a non-WAL file), this is get(). */
|
|
500
|
+
async getCooperatively(name) {
|
|
501
|
+
if (this.batchDepth > 0 || !this.isReady())
|
|
502
|
+
return this.get(name);
|
|
503
|
+
this.reconcileComposition();
|
|
504
|
+
const cached = this.detailCache.get(name);
|
|
505
|
+
const file = cached && cached.expiresAt > Date.now() ? null : cooperativeReadFile(this.db);
|
|
506
|
+
if (!file || !this.findSliceLocation(name))
|
|
507
|
+
return this.get(name);
|
|
508
|
+
return this.withCooperativeMembership(file, new Set([name]), () => this.get(name));
|
|
509
|
+
}
|
|
510
|
+
/** withMembershipBatch(), for a route whose batch starts with list(): when the listing isn't cached, the batch's
|
|
511
|
+
* membership index is read first as getCooperatively reads it, then `fn` runs in the batch with that index. */
|
|
512
|
+
async withMembershipBatchCooperatively(fn) {
|
|
513
|
+
if (this.batchDepth > 0 || !this.isReady())
|
|
514
|
+
return this.withMembershipBatch(fn);
|
|
515
|
+
this.reconcileComposition();
|
|
516
|
+
const file = this.listingCache && this.listingCache.expiresAt > Date.now() ? null : cooperativeReadFile(this.db);
|
|
517
|
+
if (!file)
|
|
518
|
+
return this.withMembershipBatch(fn);
|
|
519
|
+
return this.withCooperativeMembership(file, null, () => this.withMembershipBatch(fn));
|
|
520
|
+
}
|
|
521
|
+
/** Reads the membership index for `served` cooperatively, then runs `fn` with it as the next membership build. An
|
|
522
|
+
* invalidate() during the read's awaits makes that index older than the caches `fn` fills: the request is still
|
|
523
|
+
* answered from it, as of the read's start, and nothing it cached is kept. */
|
|
524
|
+
async withCooperativeMembership(file, served, fn) {
|
|
525
|
+
const invalidations = this.invalidations;
|
|
526
|
+
const index = await this.readMembershipIndexCooperatively(file, served);
|
|
527
|
+
if (invalidations === this.invalidations)
|
|
528
|
+
return this.withPreparedMembership(served, index, fn);
|
|
529
|
+
try {
|
|
530
|
+
return this.withPreparedMembership(served, index, fn);
|
|
531
|
+
}
|
|
532
|
+
finally {
|
|
533
|
+
this.invalidate();
|
|
534
|
+
}
|
|
535
|
+
}
|
|
536
|
+
/** Runs `fn` with `index` as the next membership build for `served`. The await that read it is over, so nothing
|
|
537
|
+
* else runs between here and that build; a cache drop in between (invalidate) discards it. */
|
|
538
|
+
withPreparedMembership(served, index, fn) {
|
|
539
|
+
this.preparedMembership = { served, index };
|
|
540
|
+
try {
|
|
541
|
+
return fn();
|
|
542
|
+
}
|
|
543
|
+
finally {
|
|
544
|
+
this.preparedMembership = null;
|
|
545
|
+
}
|
|
546
|
+
}
|
|
407
547
|
// Quiet reconciliation must notice new native membership before the legacy metadata TTL.
|
|
408
548
|
// This is a cache key over authored bytes and directory entries, not another scope parser.
|
|
409
549
|
reconcileComposition() {
|
|
@@ -593,20 +733,19 @@ export class SliceIndexer {
|
|
|
593
733
|
if (columns.length === 0 || !columns.some((c) => c.name === "tags")) {
|
|
594
734
|
return result;
|
|
595
735
|
}
|
|
596
|
-
const
|
|
597
|
-
for (const row of stmt.iterate()) {
|
|
736
|
+
const countRow = (row) => {
|
|
598
737
|
if (!KNOWN_QUEUE_STATES.has(row.state))
|
|
599
|
-
|
|
738
|
+
return;
|
|
600
739
|
const scope = parseTypedQueueScope(row.tags);
|
|
601
740
|
if (!scope || scope.projects.size > 1 || scope.slices.size === 0)
|
|
602
|
-
|
|
741
|
+
return;
|
|
603
742
|
const taggedProject = scope.projects.values().next().value;
|
|
604
743
|
// A former id a catalogued project declares counts as that project (#3261).
|
|
605
744
|
const rowProject = taggedProject === undefined ? undefined : candidateOptions.canonicalProjectId?.(taggedProject) ?? taggedProject;
|
|
606
745
|
const firstSlice = scope.slices.values().next().value;
|
|
607
746
|
const candidates = targetsBySliceToken.get(firstSlice);
|
|
608
747
|
if (!candidates)
|
|
609
|
-
|
|
748
|
+
return;
|
|
610
749
|
let uniqueMatch = null;
|
|
611
750
|
for (const target of candidates) {
|
|
612
751
|
if (rowProject !== undefined && target.projectId !== rowProject)
|
|
@@ -636,12 +775,48 @@ export class SliceIndexer {
|
|
|
636
775
|
uniqueMatch = target;
|
|
637
776
|
}
|
|
638
777
|
if (!uniqueMatch?.projectId || !uniqueMatch.missionId || !uniqueMatch.counts)
|
|
639
|
-
|
|
778
|
+
return;
|
|
640
779
|
uniqueMatch.counts[row.state]++;
|
|
780
|
+
};
|
|
781
|
+
if (candidateOptions.deferRows) {
|
|
782
|
+
candidateOptions.deferRows(countRow);
|
|
783
|
+
return result;
|
|
641
784
|
}
|
|
785
|
+
const rows = this.db.prepare(QUEUE_COUNT_SQL).iterate();
|
|
786
|
+
runSyncSite("slices.queue_counts_scan", () => {
|
|
787
|
+
for (const row of rows)
|
|
788
|
+
countRow(row);
|
|
789
|
+
});
|
|
642
790
|
return result;
|
|
643
791
|
}
|
|
644
792
|
// --- internals ---
|
|
793
|
+
/** observedQueueCounts' rows, read on their own read-only connection one rowid window at a time, yielding to the event
|
|
794
|
+
* loop between windows (readRowsCooperatively), for a route to pass in as `rows` before its synchronous work. The
|
|
795
|
+
* statement reads every row's tags, which sit past its body, in one stretch. Null when the read can't run this way
|
|
796
|
+
* (a transaction, a memory database or a non-WAL file) or there's no tags column: the count then reads them itself. */
|
|
797
|
+
/** Runs a deferred count (observedQueueCounts' deferRows) over the rows in time-sized chunks, yielding to the event
|
|
798
|
+
* loop between chunks, so counting a large queue's tagged rows isn't one synchronous stretch. A chunk ends once it
|
|
799
|
+
* has run `targetMs`; each row is counted once, in order. */
|
|
800
|
+
async countQueueRowsCooperatively(rows, countRow, targetMs = 16) {
|
|
801
|
+
let next = 0;
|
|
802
|
+
while (next < rows.length) {
|
|
803
|
+
const started = performance.now();
|
|
804
|
+
do
|
|
805
|
+
countRow(rows[next++]);
|
|
806
|
+
while (next < rows.length && performance.now() - started < targetMs);
|
|
807
|
+
if (next < rows.length)
|
|
808
|
+
await new Promise((resolve) => setImmediate(resolve));
|
|
809
|
+
}
|
|
810
|
+
}
|
|
811
|
+
async readQueueCountRowsCooperatively() {
|
|
812
|
+
const file = cooperativeReadFile(this.db);
|
|
813
|
+
if (!file)
|
|
814
|
+
return null;
|
|
815
|
+
const columns = this.db.prepare(`PRAGMA table_info(queue_items)`).all();
|
|
816
|
+
if (!columns.some((c) => c.name === "tags"))
|
|
817
|
+
return null;
|
|
818
|
+
return (await readRowsCooperatively(file, "queue_items", QUEUE_COUNT_WINDOW_SQL, [])).rows;
|
|
819
|
+
}
|
|
645
820
|
readSliceLocations() {
|
|
646
821
|
return this.walkSliceLocations(false, [], undefined, this.missionId || undefined);
|
|
647
822
|
}
|
|
@@ -1220,6 +1395,57 @@ export class SliceIndexer {
|
|
|
1220
1395
|
if (this.membershipIndex) {
|
|
1221
1396
|
return this.membershipIndex;
|
|
1222
1397
|
}
|
|
1398
|
+
// A cooperative read made for this operation's scope serves its first build, once.
|
|
1399
|
+
const prepared = this.preparedMembership;
|
|
1400
|
+
if (prepared && sameServedScope(prepared.served, served)) {
|
|
1401
|
+
this.preparedMembership = null;
|
|
1402
|
+
this.membershipIndex = prepared.index;
|
|
1403
|
+
return prepared.index;
|
|
1404
|
+
}
|
|
1405
|
+
// The same build as readMembershipIndexCooperatively, over synchronous statements on this connection.
|
|
1406
|
+
const build = this.membershipBuild(served);
|
|
1407
|
+
let step = build.next();
|
|
1408
|
+
while (!step.done) {
|
|
1409
|
+
if (step.value.kind === "typed") {
|
|
1410
|
+
step = build.next(this.db.prepare(TYPED_MEMBERSHIP_SQL).iterate());
|
|
1411
|
+
}
|
|
1412
|
+
else {
|
|
1413
|
+
const scan = this.db.prepare(step.value.tagsColumnPresent ? FALLBACK_MEMBERSHIP_SQL : FALLBACK_BODY_MEMBERSHIP_SQL);
|
|
1414
|
+
// The build reads the whole scan as one batch, so this labels the scan as main did. The cooperative read's
|
|
1415
|
+
// windows aren't labelled: each is bounded, and a label writes two log records per call.
|
|
1416
|
+
runSyncSite("slices.membership_term_scan", () => build.next(scan.iterate()));
|
|
1417
|
+
step = build.next(null);
|
|
1418
|
+
}
|
|
1419
|
+
}
|
|
1420
|
+
this.membershipIndex = step.value;
|
|
1421
|
+
return this.membershipIndex;
|
|
1422
|
+
}
|
|
1423
|
+
/** The membership build readRowsCooperatively drives: the same scans, read on their own read-only connection one
|
|
1424
|
+
* rowid window at a time, yielding to the event loop between windows. Each scan is one read transaction, so the
|
|
1425
|
+
* fallback scan's snapshot can be newer than the typed scan's. A read or build failure propagates and nothing is
|
|
1426
|
+
* published; the caller hands the index to the next build (withPreparedMembership). */
|
|
1427
|
+
async readMembershipIndexCooperatively(file, served) {
|
|
1428
|
+
const build = this.membershipBuild(served);
|
|
1429
|
+
let step = build.next();
|
|
1430
|
+
while (!step.done) {
|
|
1431
|
+
if (step.value.kind === "typed") {
|
|
1432
|
+
const typed = await readRowsCooperatively(file, "queue_items", TYPED_MEMBERSHIP_WINDOW_SQL, []);
|
|
1433
|
+
step = build.next(inTypedMembershipOrder(typed.rows));
|
|
1434
|
+
}
|
|
1435
|
+
else {
|
|
1436
|
+
const sql = step.value.tagsColumnPresent ? FALLBACK_MEMBERSHIP_WINDOW_SQL : FALLBACK_BODY_MEMBERSHIP_WINDOW_SQL;
|
|
1437
|
+
await readRowsCooperatively(file, "queue_items", sql, [], undefined, undefined, {
|
|
1438
|
+
onWindow: (rows) => { build.next(rows); },
|
|
1439
|
+
});
|
|
1440
|
+
step = build.next(null);
|
|
1441
|
+
}
|
|
1442
|
+
}
|
|
1443
|
+
return step.value;
|
|
1444
|
+
}
|
|
1445
|
+
/** One membership build (ensureMembershipIndex's doc above), as a generator that asks its driver for each scan's
|
|
1446
|
+
* rows: the typed scan's in TYPED_MEMBERSHIP_SQL's order, then the fallback scan's in rowid-ordered batches ending
|
|
1447
|
+
* with null. It reads frontmatter and builds the maps itself, so both drivers build the same index. */
|
|
1448
|
+
*membershipBuild(served) {
|
|
1223
1449
|
const typedBySlice = new Map();
|
|
1224
1450
|
const fallbackTermsBySlice = new Map();
|
|
1225
1451
|
const fallbackByTerm = new Map();
|
|
@@ -1248,20 +1474,22 @@ export class SliceIndexer {
|
|
|
1248
1474
|
// real fault, not a shape fact, and must not be laundered into a
|
|
1249
1475
|
// "tags column missing" degrade nor allow a later fallback scan.
|
|
1250
1476
|
if (!tableAbsent && tagsColumnPresent) {
|
|
1251
|
-
const
|
|
1477
|
+
const typedRows = (yield { kind: "typed" });
|
|
1252
1478
|
const scanOrder = new Map();
|
|
1253
|
-
|
|
1254
|
-
|
|
1255
|
-
|
|
1256
|
-
|
|
1257
|
-
|
|
1258
|
-
const
|
|
1259
|
-
|
|
1260
|
-
|
|
1261
|
-
|
|
1262
|
-
bucket.
|
|
1479
|
+
runSyncSite("slices.membership_typed_scan", () => {
|
|
1480
|
+
for (const r of typedRows) {
|
|
1481
|
+
if (this.projectId && !belongsToProject(r.tags, this.projectIds))
|
|
1482
|
+
continue;
|
|
1483
|
+
scanOrder.set(r.qitem_id, scanOrder.size);
|
|
1484
|
+
for (const tagged of parseScopeTags(r.tags).slices) {
|
|
1485
|
+
const bucket = typedBySlice.get(tagged);
|
|
1486
|
+
if (!bucket)
|
|
1487
|
+
typedBySlice.set(tagged, [r.qitem_id]);
|
|
1488
|
+
else if (bucket.length < 500)
|
|
1489
|
+
bucket.push(r.qitem_id);
|
|
1490
|
+
}
|
|
1263
1491
|
}
|
|
1264
|
-
}
|
|
1492
|
+
});
|
|
1265
1493
|
// A tag may name a slice by its frontmatter id instead of its directory
|
|
1266
1494
|
// name. Fold such rows into that slice's bucket. The id map is read only
|
|
1267
1495
|
// when some tag matches no directory name.
|
|
@@ -1353,57 +1581,54 @@ export class SliceIndexer {
|
|
|
1353
1581
|
const localBuckets = new Map();
|
|
1354
1582
|
for (const term of termList)
|
|
1355
1583
|
localBuckets.set(term, []);
|
|
1356
|
-
const scan = tagsColumnPresent
|
|
1357
|
-
? this.db.prepare(`SELECT qitem_id, body, tags FROM queue_items`)
|
|
1358
|
-
: this.db.prepare(`SELECT qitem_id, body FROM queue_items`);
|
|
1359
1584
|
let stamp = 0;
|
|
1360
|
-
for (
|
|
1361
|
-
|
|
1362
|
-
|
|
1363
|
-
|
|
1364
|
-
|
|
1365
|
-
|
|
1366
|
-
|
|
1367
|
-
|
|
1368
|
-
|
|
1369
|
-
|
|
1370
|
-
|
|
1371
|
-
|
|
1372
|
-
|
|
1373
|
-
|
|
1374
|
-
|
|
1375
|
-
|
|
1376
|
-
|
|
1377
|
-
|
|
1378
|
-
|
|
1379
|
-
|
|
1380
|
-
|
|
1381
|
-
|
|
1382
|
-
|
|
1383
|
-
|
|
1384
|
-
|
|
1385
|
-
|
|
1386
|
-
|
|
1387
|
-
|
|
1388
|
-
|
|
1389
|
-
|
|
1390
|
-
|
|
1391
|
-
|
|
1392
|
-
|
|
1393
|
-
|
|
1394
|
-
|
|
1395
|
-
|
|
1396
|
-
|
|
1397
|
-
|
|
1398
|
-
bucket.
|
|
1585
|
+
for (let batch = (yield { kind: "fallback", tagsColumnPresent }); batch !== null; batch = (yield { kind: "fallback", tagsColumnPresent }))
|
|
1586
|
+
for (const r of batch) {
|
|
1587
|
+
if (this.projectId && !belongsToProject(r.tags, this.projectIds))
|
|
1588
|
+
continue;
|
|
1589
|
+
// A non-TEXT value (a BLOB) failed the build here before this matcher:
|
|
1590
|
+
// asciiFold/sqliteVisiblePrefix threw on it. The literal pass reads
|
|
1591
|
+
// code units and would skip it silently, so fail it the same way.
|
|
1592
|
+
if (typeof r.body !== "string" || (r.tags != null && typeof r.tags !== "string")) {
|
|
1593
|
+
throw new TypeError(`queue_items row ${r.qitem_id}: body and tags must be TEXT`);
|
|
1594
|
+
}
|
|
1595
|
+
// Stamps tell this row's marks from earlier rows' without clearing;
|
|
1596
|
+
// restart them before the Uint32 wraps.
|
|
1597
|
+
if (stamp === 0xffffffff) {
|
|
1598
|
+
literalMarks.fill(0);
|
|
1599
|
+
stamp = 0;
|
|
1600
|
+
}
|
|
1601
|
+
stamp++;
|
|
1602
|
+
// Both haystacks are scanned (no short-circuit) so every literal hit is marked.
|
|
1603
|
+
const bodyHit = literal !== null && literal.scan(r.body, literalMarks, stamp);
|
|
1604
|
+
const tagsHit = literal !== null && r.tags != null && literal.scan(r.tags, literalMarks, stamp);
|
|
1605
|
+
let hayBody = null;
|
|
1606
|
+
let hayTags = null;
|
|
1607
|
+
let patternHit = false;
|
|
1608
|
+
if (patternPrefilter) {
|
|
1609
|
+
hayBody = asciiFold(sqliteVisiblePrefix(r.body));
|
|
1610
|
+
hayTags = r.tags != null ? asciiFold(sqliteVisiblePrefix(r.tags)) : null;
|
|
1611
|
+
patternHit = patternPrefilter.test(hayBody) || (hayTags !== null && patternPrefilter.test(hayTags));
|
|
1612
|
+
}
|
|
1613
|
+
if (!bodyHit && !tagsHit && !patternHit)
|
|
1614
|
+
continue;
|
|
1615
|
+
for (let index = 0; index < termList.length; index++) {
|
|
1616
|
+
const literalId = literalIdOfTerm[index];
|
|
1617
|
+
const re = patternRegexes[index];
|
|
1618
|
+
const hit = literalId !== -1
|
|
1619
|
+
? literalMarks[literalId] === stamp
|
|
1620
|
+
: patternHit && (re.test(hayBody) || (hayTags !== null && re.test(hayTags)));
|
|
1621
|
+
if (hit) {
|
|
1622
|
+
const bucket = localBuckets.get(termList[index]);
|
|
1623
|
+
if (bucket.length < 500)
|
|
1624
|
+
bucket.push(r.qitem_id);
|
|
1625
|
+
}
|
|
1399
1626
|
}
|
|
1400
1627
|
}
|
|
1401
|
-
}
|
|
1402
1628
|
for (const [term, ids] of localBuckets)
|
|
1403
1629
|
fallbackByTerm.set(term, ids);
|
|
1404
1630
|
}
|
|
1405
|
-
|
|
1406
|
-
return this.membershipIndex;
|
|
1631
|
+
return { typedBySlice, fallbackTermsBySlice, fallbackByTerm, knownSlices };
|
|
1407
1632
|
}
|
|
1408
1633
|
discoverMissionIds() {
|
|
1409
1634
|
const missionIds = new Set();
|