@openrig/cli 0.7.7 → 0.7.8
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 +5 -5
- package/daemon/assets/openshell/Dockerfile +15 -0
- package/daemon/assets/openshell/README.md +137 -0
- package/daemon/assets/openshell/agents/coordinator/agent.yaml +20 -0
- package/daemon/assets/openshell/agents/coordinator/role.md +1 -0
- package/daemon/assets/openshell/agents/worker/agent.yaml +20 -0
- package/daemon/assets/openshell/agents/worker/role.md +3 -0
- package/daemon/assets/openshell/claude-code-provider.yaml +55 -0
- package/daemon/assets/openshell/driver-v1.schema.json +81 -0
- package/daemon/assets/openshell/guest.py +306 -0
- package/daemon/assets/openshell/policy.yaml +33 -0
- package/daemon/assets/openshell/preset.yaml +12 -0
- package/daemon/assets/openshell/rig.yaml +20 -0
- 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/skills/seat-continuity-and-handover/SKILL.md +1 -1
- 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 +16 -6
- package/daemon/context-packs/reference/getting-started.md +8 -3
- package/daemon/context-packs/reference/manifest.yaml +1 -1
- package/daemon/context-packs/reference/rig-spec.md +69 -12
- package/daemon/context-packs/reference/whats-new.md +119 -15
- 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/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/manifest.yaml +1 -1
- 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/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/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/retiring-and-inheriting-a-seat/manifest.yaml +1 -1
- package/daemon/context-packs/skills/seat-continuity-and-handover/SKILL.md +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.map +1 -1
- package/daemon/dist/adapters/claude-code-adapter.js +37 -6
- package/daemon/dist/adapters/claude-code-adapter.js.map +1 -1
- package/daemon/dist/adapters/claude-resume.d.ts +2 -1
- package/daemon/dist/adapters/claude-resume.d.ts.map +1 -1
- package/daemon/dist/adapters/claude-resume.js +6 -3
- package/daemon/dist/adapters/claude-resume.js.map +1 -1
- package/daemon/dist/adapters/codex-runtime-adapter.d.ts +4 -7
- package/daemon/dist/adapters/codex-runtime-adapter.d.ts.map +1 -1
- package/daemon/dist/adapters/codex-runtime-adapter.js +86 -33
- package/daemon/dist/adapters/codex-runtime-adapter.js.map +1 -1
- package/daemon/dist/adapters/community-harness-runtime-adapter.d.ts +13 -1
- package/daemon/dist/adapters/community-harness-runtime-adapter.d.ts.map +1 -1
- package/daemon/dist/adapters/community-harness-runtime-adapter.js +28 -1
- package/daemon/dist/adapters/community-harness-runtime-adapter.js.map +1 -1
- package/daemon/dist/adapters/openshell-driver.d.ts +39 -0
- package/daemon/dist/adapters/openshell-driver.d.ts.map +1 -0
- package/daemon/dist/adapters/openshell-driver.js +139 -0
- package/daemon/dist/adapters/openshell-driver.js.map +1 -0
- package/daemon/dist/adapters/openshell-podman-observer.d.ts +30 -0
- package/daemon/dist/adapters/openshell-podman-observer.d.ts.map +1 -0
- package/daemon/dist/adapters/openshell-podman-observer.js +94 -0
- package/daemon/dist/adapters/openshell-podman-observer.js.map +1 -0
- package/daemon/dist/adapters/pi-openrouter-charge.d.ts +1 -0
- package/daemon/dist/adapters/pi-openrouter-charge.d.ts.map +1 -1
- package/daemon/dist/adapters/pi-openrouter-charge.js +17 -3
- package/daemon/dist/adapters/pi-openrouter-charge.js.map +1 -1
- package/daemon/dist/adapters/tmux-control.d.ts +12 -6
- package/daemon/dist/adapters/tmux-control.d.ts.map +1 -1
- package/daemon/dist/adapters/tmux-control.js +42 -21
- package/daemon/dist/adapters/tmux-control.js.map +1 -1
- package/daemon/dist/adapters/tmux-server.d.ts +6 -3
- package/daemon/dist/adapters/tmux-server.d.ts.map +1 -1
- package/daemon/dist/adapters/tmux-server.js +13 -8
- package/daemon/dist/adapters/tmux-server.js.map +1 -1
- package/daemon/dist/adapters/tmux.d.ts +8 -2
- package/daemon/dist/adapters/tmux.d.ts.map +1 -1
- package/daemon/dist/adapters/tmux.js +38 -11
- package/daemon/dist/adapters/tmux.js.map +1 -1
- package/daemon/dist/build-info.js +3 -3
- package/daemon/dist/db/all-migrations.d.ts.map +1 -1
- package/daemon/dist/db/all-migrations.js +8 -0
- package/daemon/dist/db/all-migrations.js.map +1 -1
- package/daemon/dist/db/migrations/142_node_claude_mcp.d.ts +3 -0
- package/daemon/dist/db/migrations/142_node_claude_mcp.d.ts.map +1 -0
- package/daemon/dist/db/migrations/142_node_claude_mcp.js +5 -0
- package/daemon/dist/db/migrations/142_node_claude_mcp.js.map +1 -0
- package/daemon/dist/db/migrations/143_activity_grants.d.ts +8 -0
- package/daemon/dist/db/migrations/143_activity_grants.d.ts.map +1 -0
- package/daemon/dist/db/migrations/143_activity_grants.js +22 -0
- package/daemon/dist/db/migrations/143_activity_grants.js.map +1 -0
- package/daemon/dist/db/migrations/144_environment_bindings.d.ts +4 -0
- package/daemon/dist/db/migrations/144_environment_bindings.d.ts.map +1 -0
- package/daemon/dist/db/migrations/144_environment_bindings.js +31 -0
- package/daemon/dist/db/migrations/144_environment_bindings.js.map +1 -0
- package/daemon/dist/db/migrations/145_node_permissions_to.d.ts +5 -0
- package/daemon/dist/db/migrations/145_node_permissions_to.d.ts.map +1 -0
- package/daemon/dist/db/migrations/145_node_permissions_to.js +7 -0
- package/daemon/dist/db/migrations/145_node_permissions_to.js.map +1 -0
- package/daemon/dist/domain/active-occupant.d.ts +2 -0
- package/daemon/dist/domain/active-occupant.d.ts.map +1 -1
- package/daemon/dist/domain/active-occupant.js +9 -1
- package/daemon/dist/domain/active-occupant.js.map +1 -1
- package/daemon/dist/domain/activity-grants.d.ts +63 -0
- package/daemon/dist/domain/activity-grants.d.ts.map +1 -0
- package/daemon/dist/domain/activity-grants.js +106 -0
- package/daemon/dist/domain/activity-grants.js.map +1 -0
- package/daemon/dist/domain/agent-images/agent-image-library-service.d.ts.map +1 -1
- package/daemon/dist/domain/agent-images/agent-image-library-service.js +5 -2
- package/daemon/dist/domain/agent-images/agent-image-library-service.js.map +1 -1
- package/daemon/dist/domain/claude-compaction-enforcer.d.ts +11 -4
- package/daemon/dist/domain/claude-compaction-enforcer.d.ts.map +1 -1
- package/daemon/dist/domain/claude-compaction-enforcer.js +34 -10
- package/daemon/dist/domain/claude-compaction-enforcer.js.map +1 -1
- package/daemon/dist/domain/claude-mcp.d.ts +10 -0
- package/daemon/dist/domain/claude-mcp.d.ts.map +1 -0
- package/daemon/dist/domain/claude-mcp.js +19 -0
- package/daemon/dist/domain/claude-mcp.js.map +1 -0
- package/daemon/dist/domain/codex-owned-plugin-trust.d.ts.map +1 -1
- package/daemon/dist/domain/codex-owned-plugin-trust.js +2 -1
- package/daemon/dist/domain/codex-owned-plugin-trust.js.map +1 -1
- package/daemon/dist/domain/community-harness-presets.d.ts +2 -1
- package/daemon/dist/domain/community-harness-presets.d.ts.map +1 -1
- package/daemon/dist/domain/community-harness-presets.js +3 -2
- package/daemon/dist/domain/community-harness-presets.js.map +1 -1
- package/daemon/dist/domain/context-monitor.d.ts +2 -2
- package/daemon/dist/domain/context-monitor.d.ts.map +1 -1
- package/daemon/dist/domain/context-monitor.js +8 -2
- package/daemon/dist/domain/context-monitor.js.map +1 -1
- package/daemon/dist/domain/desired-claude-activity-hooks.d.ts +21 -0
- package/daemon/dist/domain/desired-claude-activity-hooks.d.ts.map +1 -0
- package/daemon/dist/domain/desired-claude-activity-hooks.js +30 -0
- package/daemon/dist/domain/desired-claude-activity-hooks.js.map +1 -0
- package/daemon/dist/domain/draft-aware-delivery.d.ts.map +1 -1
- package/daemon/dist/domain/draft-aware-delivery.js +6 -2
- package/daemon/dist/domain/draft-aware-delivery.js.map +1 -1
- package/daemon/dist/domain/environment-artifacts.d.ts +49 -0
- package/daemon/dist/domain/environment-artifacts.d.ts.map +1 -0
- package/daemon/dist/domain/environment-artifacts.js +158 -0
- package/daemon/dist/domain/environment-artifacts.js.map +1 -0
- package/daemon/dist/domain/environment-lifecycle.d.ts +119 -0
- package/daemon/dist/domain/environment-lifecycle.d.ts.map +1 -0
- package/daemon/dist/domain/environment-lifecycle.js +461 -0
- package/daemon/dist/domain/environment-lifecycle.js.map +1 -0
- package/daemon/dist/domain/environment-platform.d.ts +121 -0
- package/daemon/dist/domain/environment-platform.d.ts.map +1 -0
- package/daemon/dist/domain/environment-platform.js +280 -0
- package/daemon/dist/domain/environment-platform.js.map +1 -0
- package/daemon/dist/domain/environment-startup.d.ts +41 -0
- package/daemon/dist/domain/environment-startup.d.ts.map +1 -0
- package/daemon/dist/domain/environment-startup.js +281 -0
- package/daemon/dist/domain/environment-startup.js.map +1 -0
- package/daemon/dist/domain/expected-conversation.d.ts +20 -0
- package/daemon/dist/domain/expected-conversation.d.ts.map +1 -0
- package/daemon/dist/domain/expected-conversation.js +101 -0
- package/daemon/dist/domain/expected-conversation.js.map +1 -0
- package/daemon/dist/domain/gateway/operator-delivery-engine.d.ts +8 -1
- package/daemon/dist/domain/gateway/operator-delivery-engine.d.ts.map +1 -1
- package/daemon/dist/domain/gateway/operator-delivery-engine.js +61 -4
- package/daemon/dist/domain/gateway/operator-delivery-engine.js.map +1 -1
- package/daemon/dist/domain/gateway/slack/inbound.d.ts +2 -0
- package/daemon/dist/domain/gateway/slack/inbound.d.ts.map +1 -1
- package/daemon/dist/domain/gateway/slack/inbound.js +40 -8
- package/daemon/dist/domain/gateway/slack/inbound.js.map +1 -1
- package/daemon/dist/domain/gateway/slack/message.d.ts +16 -0
- package/daemon/dist/domain/gateway/slack/message.d.ts.map +1 -1
- package/daemon/dist/domain/gateway/slack/message.js +216 -7
- package/daemon/dist/domain/gateway/slack/message.js.map +1 -1
- package/daemon/dist/domain/gateway/slack/queue-access.d.ts +14 -0
- package/daemon/dist/domain/gateway/slack/queue-access.d.ts.map +1 -1
- package/daemon/dist/domain/gateway/slack/queue-access.js +9 -1
- package/daemon/dist/domain/gateway/slack/queue-access.js.map +1 -1
- package/daemon/dist/domain/gateway/slack/slack-delivery.d.ts.map +1 -1
- package/daemon/dist/domain/gateway/slack/slack-delivery.js +9 -4
- package/daemon/dist/domain/gateway/slack/slack-delivery.js.map +1 -1
- package/daemon/dist/domain/gateway/slack/slack-subsystem.d.ts +2 -0
- package/daemon/dist/domain/gateway/slack/slack-subsystem.d.ts.map +1 -1
- package/daemon/dist/domain/gateway/slack/slack-subsystem.js +6 -1
- package/daemon/dist/domain/gateway/slack/slack-subsystem.js.map +1 -1
- package/daemon/dist/domain/hosts/hosts-registry-writer.d.ts +22 -0
- package/daemon/dist/domain/hosts/hosts-registry-writer.d.ts.map +1 -1
- package/daemon/dist/domain/hosts/hosts-registry-writer.js +116 -0
- package/daemon/dist/domain/hosts/hosts-registry-writer.js.map +1 -1
- package/daemon/dist/domain/kernel-hook-review.d.ts +16 -0
- package/daemon/dist/domain/kernel-hook-review.d.ts.map +1 -0
- package/daemon/dist/domain/kernel-hook-review.js +49 -0
- package/daemon/dist/domain/kernel-hook-review.js.map +1 -0
- package/daemon/dist/domain/mission-control/mission-control-write-contract.d.ts +3 -0
- 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 +20 -5
- 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.map +1 -1
- package/daemon/dist/domain/model-divergence/current-generation-record.js +10 -6
- package/daemon/dist/domain/model-divergence/current-generation-record.js.map +1 -1
- package/daemon/dist/domain/native-process-lineage.d.ts +3 -0
- package/daemon/dist/domain/native-process-lineage.d.ts.map +1 -1
- package/daemon/dist/domain/native-process-lineage.js +34 -1
- package/daemon/dist/domain/native-process-lineage.js.map +1 -1
- package/daemon/dist/domain/native-resume-probe.d.ts +2 -1
- package/daemon/dist/domain/native-resume-probe.d.ts.map +1 -1
- package/daemon/dist/domain/native-resume-probe.js +4 -2
- package/daemon/dist/domain/native-resume-probe.js.map +1 -1
- package/daemon/dist/domain/node-inventory.d.ts.map +1 -1
- package/daemon/dist/domain/node-inventory.js +18 -8
- package/daemon/dist/domain/node-inventory.js.map +1 -1
- package/daemon/dist/domain/node-launcher.d.ts +3 -0
- package/daemon/dist/domain/node-launcher.d.ts.map +1 -1
- package/daemon/dist/domain/node-launcher.js +6 -0
- package/daemon/dist/domain/node-launcher.js.map +1 -1
- package/daemon/dist/domain/outbox-handler.d.ts +12 -0
- package/daemon/dist/domain/outbox-handler.d.ts.map +1 -1
- package/daemon/dist/domain/outbox-handler.js +32 -3
- package/daemon/dist/domain/outbox-handler.js.map +1 -1
- package/daemon/dist/domain/policies/parked-owner-consumer.d.ts +10 -0
- package/daemon/dist/domain/policies/parked-owner-consumer.d.ts.map +1 -1
- package/daemon/dist/domain/policies/parked-owner-consumer.js +60 -4
- package/daemon/dist/domain/policies/parked-owner-consumer.js.map +1 -1
- package/daemon/dist/domain/provider/claude-seat-switch.d.ts +9 -3
- package/daemon/dist/domain/provider/claude-seat-switch.d.ts.map +1 -1
- package/daemon/dist/domain/provider/claude-seat-switch.js +100 -17
- package/daemon/dist/domain/provider/claude-seat-switch.js.map +1 -1
- package/daemon/dist/domain/provider/provider-service-impl.js +1 -1
- package/daemon/dist/domain/provider/provider-service-impl.js.map +1 -1
- package/daemon/dist/domain/provider/provider-service.d.ts +32 -2
- package/daemon/dist/domain/provider/provider-service.d.ts.map +1 -1
- package/daemon/dist/domain/provider/provider-types.d.ts +1 -1
- package/daemon/dist/domain/provider/provider-types.d.ts.map +1 -1
- package/daemon/dist/domain/queue-repository.d.ts +36 -5
- package/daemon/dist/domain/queue-repository.d.ts.map +1 -1
- package/daemon/dist/domain/queue-repository.js +155 -37
- package/daemon/dist/domain/queue-repository.js.map +1 -1
- package/daemon/dist/domain/queue-stuck-sweep.d.ts +1 -1
- package/daemon/dist/domain/queue-stuck-sweep.d.ts.map +1 -1
- package/daemon/dist/domain/queue-stuck-sweep.js +31 -0
- package/daemon/dist/domain/queue-stuck-sweep.js.map +1 -1
- package/daemon/dist/domain/queue-wake-ladder.d.ts +3 -0
- package/daemon/dist/domain/queue-wake-ladder.d.ts.map +1 -1
- package/daemon/dist/domain/queue-wake-ladder.js +124 -25
- package/daemon/dist/domain/queue-wake-ladder.js.map +1 -1
- package/daemon/dist/domain/restore-check-service.d.ts +2 -7
- package/daemon/dist/domain/restore-check-service.d.ts.map +1 -1
- package/daemon/dist/domain/restore-check-service.js.map +1 -1
- package/daemon/dist/domain/restore-orchestrator.d.ts +35 -3
- package/daemon/dist/domain/restore-orchestrator.d.ts.map +1 -1
- package/daemon/dist/domain/restore-orchestrator.js +166 -21
- package/daemon/dist/domain/restore-orchestrator.js.map +1 -1
- package/daemon/dist/domain/resume-metadata-refresher.d.ts +2 -1
- package/daemon/dist/domain/resume-metadata-refresher.d.ts.map +1 -1
- package/daemon/dist/domain/resume-metadata-refresher.js +20 -6
- package/daemon/dist/domain/resume-metadata-refresher.js.map +1 -1
- package/daemon/dist/domain/rig-expansion-service.js +1 -1
- package/daemon/dist/domain/rig-expansion-service.js.map +1 -1
- package/daemon/dist/domain/rig-repository.d.ts +10 -0
- package/daemon/dist/domain/rig-repository.d.ts.map +1 -1
- package/daemon/dist/domain/rig-repository.js +37 -0
- package/daemon/dist/domain/rig-repository.js.map +1 -1
- package/daemon/dist/domain/rigspec-codec.d.ts.map +1 -1
- package/daemon/dist/domain/rigspec-codec.js +4 -0
- package/daemon/dist/domain/rigspec-codec.js.map +1 -1
- package/daemon/dist/domain/rigspec-exporter.d.ts +8 -0
- package/daemon/dist/domain/rigspec-exporter.d.ts.map +1 -1
- package/daemon/dist/domain/rigspec-exporter.js +60 -2
- package/daemon/dist/domain/rigspec-exporter.js.map +1 -1
- package/daemon/dist/domain/rigspec-instantiator.d.ts.map +1 -1
- package/daemon/dist/domain/rigspec-instantiator.js +19 -4
- package/daemon/dist/domain/rigspec-instantiator.js.map +1 -1
- package/daemon/dist/domain/rigspec-schema.d.ts.map +1 -1
- package/daemon/dist/domain/rigspec-schema.js +24 -1
- package/daemon/dist/domain/rigspec-schema.js.map +1 -1
- package/daemon/dist/domain/runner-permissions.d.ts +135 -0
- package/daemon/dist/domain/runner-permissions.d.ts.map +1 -0
- package/daemon/dist/domain/runner-permissions.js +318 -0
- package/daemon/dist/domain/runner-permissions.js.map +1 -0
- package/daemon/dist/domain/runtime-adapter.d.ts +10 -0
- package/daemon/dist/domain/runtime-adapter.d.ts.map +1 -1
- package/daemon/dist/domain/runtime-adapter.js.map +1 -1
- package/daemon/dist/domain/seat-effort.d.ts +6 -0
- package/daemon/dist/domain/seat-effort.d.ts.map +1 -1
- package/daemon/dist/domain/seat-effort.js +0 -2
- package/daemon/dist/domain/seat-effort.js.map +1 -1
- package/daemon/dist/domain/seat-handover-planner.js +1 -1
- package/daemon/dist/domain/seat-handover-planner.js.map +1 -1
- package/daemon/dist/domain/seat-handover-service.d.ts +2 -0
- package/daemon/dist/domain/seat-handover-service.d.ts.map +1 -1
- package/daemon/dist/domain/seat-handover-service.js +45 -28
- package/daemon/dist/domain/seat-handover-service.js.map +1 -1
- package/daemon/dist/domain/seat-lifecycle-service.d.ts +24 -2
- package/daemon/dist/domain/seat-lifecycle-service.d.ts.map +1 -1
- package/daemon/dist/domain/seat-lifecycle-service.js +62 -1
- package/daemon/dist/domain/seat-lifecycle-service.js.map +1 -1
- package/daemon/dist/domain/seat-restart-in-place.d.ts.map +1 -1
- package/daemon/dist/domain/seat-restart-in-place.js +6 -1
- package/daemon/dist/domain/seat-restart-in-place.js.map +1 -1
- package/daemon/dist/domain/seat-runtime-switch-service.d.ts.map +1 -1
- package/daemon/dist/domain/seat-runtime-switch-service.js +4 -0
- package/daemon/dist/domain/seat-runtime-switch-service.js.map +1 -1
- package/daemon/dist/domain/seat-skill-storage.d.ts +6 -4
- package/daemon/dist/domain/seat-skill-storage.d.ts.map +1 -1
- package/daemon/dist/domain/seat-skill-storage.js +25 -5
- package/daemon/dist/domain/seat-skill-storage.js.map +1 -1
- package/daemon/dist/domain/seat-status-service.d.ts +5 -0
- package/daemon/dist/domain/seat-status-service.d.ts.map +1 -1
- package/daemon/dist/domain/seat-status-service.js +9 -0
- package/daemon/dist/domain/seat-status-service.js.map +1 -1
- package/daemon/dist/domain/self-attach-service.d.ts +8 -1
- package/daemon/dist/domain/self-attach-service.d.ts.map +1 -1
- package/daemon/dist/domain/self-attach-service.js +26 -0
- package/daemon/dist/domain/self-attach-service.js.map +1 -1
- package/daemon/dist/domain/session-transport.d.ts +10 -0
- package/daemon/dist/domain/session-transport.d.ts.map +1 -1
- package/daemon/dist/domain/session-transport.js +112 -10
- package/daemon/dist/domain/session-transport.js.map +1 -1
- package/daemon/dist/domain/snapshot-capture.d.ts.map +1 -1
- package/daemon/dist/domain/snapshot-capture.js +14 -0
- package/daemon/dist/domain/snapshot-capture.js.map +1 -1
- package/daemon/dist/domain/startup-orchestrator.d.ts.map +1 -1
- package/daemon/dist/domain/startup-orchestrator.js +32 -1
- package/daemon/dist/domain/startup-orchestrator.js.map +1 -1
- package/daemon/dist/domain/successor-session-launcher.d.ts +1 -0
- package/daemon/dist/domain/successor-session-launcher.d.ts.map +1 -1
- package/daemon/dist/domain/successor-session-launcher.js +1 -0
- package/daemon/dist/domain/successor-session-launcher.js.map +1 -1
- package/daemon/dist/domain/terminal/herdr-follow-view.d.ts.map +1 -1
- package/daemon/dist/domain/terminal/herdr-follow-view.js +22 -4
- package/daemon/dist/domain/terminal/herdr-follow-view.js.map +1 -1
- package/daemon/dist/domain/terminal/scope-task-terminal-view.d.ts +12 -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 +120 -18
- package/daemon/dist/domain/terminal/scope-task-terminal-view.js.map +1 -1
- package/daemon/dist/domain/terminal/terminal-following.js +1 -1
- package/daemon/dist/domain/terminal/terminal-following.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 -2
- package/daemon/dist/domain/terminal/terminal-service.d.ts.map +1 -1
- package/daemon/dist/domain/terminal/terminal-service.js +18 -27
- package/daemon/dist/domain/terminal/terminal-service.js.map +1 -1
- package/daemon/dist/domain/terminal/view-composer.d.ts +6 -3
- package/daemon/dist/domain/terminal/view-composer.d.ts.map +1 -1
- package/daemon/dist/domain/terminal/view-composer.js +15 -5
- package/daemon/dist/domain/terminal/view-composer.js.map +1 -1
- package/daemon/dist/domain/tmux-server-selection.d.ts +47 -0
- package/daemon/dist/domain/tmux-server-selection.d.ts.map +1 -0
- package/daemon/dist/domain/tmux-server-selection.js +220 -0
- package/daemon/dist/domain/tmux-server-selection.js.map +1 -0
- package/daemon/dist/domain/transcript-store.d.ts.map +1 -1
- package/daemon/dist/domain/transcript-store.js +8 -5
- package/daemon/dist/domain/transcript-store.js.map +1 -1
- package/daemon/dist/domain/types.d.ts +38 -0
- package/daemon/dist/domain/types.d.ts.map +1 -1
- 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 +3 -1
- 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 +9 -0
- package/daemon/dist/domain/user-settings/settings-store.js.map +1 -1
- package/daemon/dist/domain/watchdog-delivery.d.ts +1 -0
- package/daemon/dist/domain/watchdog-delivery.d.ts.map +1 -1
- package/daemon/dist/domain/watchdog-delivery.js +15 -3
- package/daemon/dist/domain/watchdog-delivery.js.map +1 -1
- package/daemon/dist/domain/watchdog-policy-engine.d.ts +2 -0
- package/daemon/dist/domain/watchdog-policy-engine.d.ts.map +1 -1
- package/daemon/dist/domain/watchdog-policy-engine.js +3 -1
- package/daemon/dist/domain/watchdog-policy-engine.js.map +1 -1
- package/daemon/dist/domain/workflow-runtime.d.ts +1 -1
- package/daemon/dist/index.d.ts +4 -0
- package/daemon/dist/index.d.ts.map +1 -1
- package/daemon/dist/index.js +14 -0
- package/daemon/dist/index.js.map +1 -1
- package/daemon/dist/routes/activity.d.ts +4 -0
- package/daemon/dist/routes/activity.d.ts.map +1 -1
- package/daemon/dist/routes/activity.js +258 -18
- package/daemon/dist/routes/activity.js.map +1 -1
- package/daemon/dist/routes/compaction.js +4 -2
- package/daemon/dist/routes/compaction.js.map +1 -1
- package/daemon/dist/routes/environments.d.ts +3 -0
- package/daemon/dist/routes/environments.d.ts.map +1 -0
- package/daemon/dist/routes/environments.js +104 -0
- package/daemon/dist/routes/environments.js.map +1 -0
- package/daemon/dist/routes/hosts.d.ts.map +1 -1
- package/daemon/dist/routes/hosts.js +80 -4
- package/daemon/dist/routes/hosts.js.map +1 -1
- package/daemon/dist/routes/provider.d.ts.map +1 -1
- package/daemon/dist/routes/provider.js +53 -7
- package/daemon/dist/routes/provider.js.map +1 -1
- package/daemon/dist/routes/restore-check.d.ts.map +1 -1
- package/daemon/dist/routes/restore-check.js +5 -19
- package/daemon/dist/routes/restore-check.js.map +1 -1
- package/daemon/dist/routes/rigs.js +3 -0
- package/daemon/dist/routes/rigs.js.map +1 -1
- package/daemon/dist/routes/rigspec.d.ts.map +1 -1
- package/daemon/dist/routes/rigspec.js +8 -3
- package/daemon/dist/routes/rigspec.js.map +1 -1
- package/daemon/dist/routes/seat.d.ts.map +1 -1
- package/daemon/dist/routes/seat.js +29 -2
- 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 +66 -20
- package/daemon/dist/routes/sessions.js.map +1 -1
- package/daemon/dist/routes/transport.d.ts.map +1 -1
- package/daemon/dist/routes/transport.js +23 -2
- package/daemon/dist/routes/transport.js.map +1 -1
- package/daemon/dist/server.d.ts +6 -0
- package/daemon/dist/server.d.ts.map +1 -1
- package/daemon/dist/server.js +56 -1
- package/daemon/dist/server.js.map +1 -1
- package/daemon/dist/startup.d.ts +2 -0
- package/daemon/dist/startup.d.ts.map +1 -1
- package/daemon/dist/startup.js +61 -26
- package/daemon/dist/startup.js.map +1 -1
- package/daemon/docs/reference/agent-startup-guide.md +4 -0
- package/daemon/docs/reference/author-contracts.md +6 -6
- package/daemon/docs/reference/community-harness-examples/dsh/README.md +71 -0
- package/daemon/docs/reference/community-harness-examples/dsh/dsh.yaml +20 -0
- package/daemon/docs/reference/community-harness-examples/dsh/openrig-dsh-runner.mjs +543 -0
- package/daemon/docs/reference/community-harness-examples/openshell/README.md +5 -0
- package/daemon/docs/reference/community-harness-presets.md +25 -1
- package/daemon/docs/reference/execution-platform-contract.md +1 -1
- package/daemon/docs/reference/getting-started.md +8 -3
- package/daemon/docs/reference/harness-runner-contract.md +151 -16
- package/daemon/docs/reference/pi-tool-selection-recovery.md +83 -0
- package/daemon/docs/reference/quickstart.md +1 -1
- package/daemon/docs/reference/rig-spec.md +69 -12
- package/daemon/docs/reference/runner-conformance/README.md +75 -0
- package/daemon/docs/reference/runner-conformance/check-runner.mjs +698 -0
- package/daemon/docs/reference/runner-conformance/fake-acp-agent.mjs +143 -0
- package/daemon/docs/reference/terminal-sessions.md +85 -9
- package/daemon/docs/reference/tmux-servers.md +166 -0
- package/daemon/docs/reference/whats-new.md +119 -15
- package/dist/acp/connector.d.ts.map +1 -1
- package/dist/acp/connector.js +6 -1
- package/dist/acp/connector.js.map +1 -1
- package/dist/build-info.js +3 -3
- package/dist/client.d.ts +3 -0
- package/dist/client.d.ts.map +1 -1
- package/dist/client.js +28 -0
- package/dist/client.js.map +1 -1
- package/dist/commands/attach.d.ts +1 -0
- package/dist/commands/attach.d.ts.map +1 -1
- package/dist/commands/attach.js +8 -2
- package/dist/commands/attach.js.map +1 -1
- package/dist/commands/compact.d.ts.map +1 -1
- package/dist/commands/compact.js +7 -4
- package/dist/commands/compact.js.map +1 -1
- package/dist/commands/config.d.ts.map +1 -1
- package/dist/commands/config.js +8 -3
- package/dist/commands/config.js.map +1 -1
- package/dist/commands/daemon.d.ts.map +1 -1
- package/dist/commands/daemon.js +7 -1
- package/dist/commands/daemon.js.map +1 -1
- package/dist/commands/destroy.d.ts.map +1 -1
- package/dist/commands/destroy.js +2 -0
- package/dist/commands/destroy.js.map +1 -1
- package/dist/commands/doctor.d.ts +8 -1
- package/dist/commands/doctor.d.ts.map +1 -1
- package/dist/commands/doctor.js +79 -5
- package/dist/commands/doctor.js.map +1 -1
- package/dist/commands/env.js +1 -1
- package/dist/commands/env.js.map +1 -1
- package/dist/commands/environment.d.ts +8 -0
- package/dist/commands/environment.d.ts.map +1 -0
- package/dist/commands/environment.js +194 -0
- package/dist/commands/environment.js.map +1 -0
- package/dist/commands/export.d.ts.map +1 -1
- package/dist/commands/export.js +5 -2
- package/dist/commands/export.js.map +1 -1
- package/dist/commands/host.d.ts.map +1 -1
- package/dist/commands/host.js +77 -7
- package/dist/commands/host.js.map +1 -1
- package/dist/commands/provider.d.ts.map +1 -1
- package/dist/commands/provider.js +2 -0
- package/dist/commands/provider.js.map +1 -1
- package/dist/commands/queue.d.ts.map +1 -1
- package/dist/commands/queue.js +12 -2
- package/dist/commands/queue.js.map +1 -1
- package/dist/commands/seat.d.ts.map +1 -1
- package/dist/commands/seat.js +54 -4
- package/dist/commands/seat.js.map +1 -1
- package/dist/commands/setup.d.ts.map +1 -1
- package/dist/commands/setup.js +18 -0
- package/dist/commands/setup.js.map +1 -1
- package/dist/commands/terminal.d.ts +2 -0
- package/dist/commands/terminal.d.ts.map +1 -1
- package/dist/commands/terminal.js +31 -2
- package/dist/commands/terminal.js.map +1 -1
- package/dist/commands/tui.d.ts +3 -2
- package/dist/commands/tui.d.ts.map +1 -1
- package/dist/commands/tui.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 +10 -0
- package/dist/config-store.js.map +1 -1
- package/dist/cross-host-target.d.ts.map +1 -1
- package/dist/cross-host-target.js +3 -1
- package/dist/cross-host-target.js.map +1 -1
- package/dist/daemon-lifecycle.d.ts +6 -0
- package/dist/daemon-lifecycle.d.ts.map +1 -1
- package/dist/daemon-lifecycle.js +66 -4
- package/dist/daemon-lifecycle.js.map +1 -1
- package/dist/daemon-reachability.d.ts +2 -1
- package/dist/daemon-reachability.d.ts.map +1 -1
- package/dist/daemon-reachability.js +3 -2
- package/dist/daemon-reachability.js.map +1 -1
- package/dist/destroy-helpers.d.ts +3 -2
- package/dist/destroy-helpers.d.ts.map +1 -1
- package/dist/destroy-helpers.js +6 -3
- package/dist/destroy-helpers.js.map +1 -1
- package/dist/host-bindings.js +1 -1
- package/dist/host-bindings.js.map +1 -1
- package/dist/host-registry.d.ts +22 -0
- package/dist/host-registry.d.ts.map +1 -1
- package/dist/host-registry.js +121 -0
- package/dist/host-registry.js.map +1 -1
- package/dist/index.d.ts +2 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +2 -0
- package/dist/index.js.map +1 -1
- package/dist/lazy-program.d.ts.map +1 -1
- package/dist/lazy-program.js +1 -0
- package/dist/lazy-program.js.map +1 -1
- package/dist/mcp-server.d.ts.map +1 -1
- package/dist/mcp-server.js +36 -2
- package/dist/mcp-server.js.map +1 -1
- package/dist/openrig-compat.d.ts +1 -1
- package/dist/openrig-compat.d.ts.map +1 -1
- package/dist/openrig-compat.js +2 -2
- package/dist/openrig-compat.js.map +1 -1
- package/dist/shared-tui.d.ts +4 -2
- package/dist/shared-tui.d.ts.map +1 -1
- package/dist/shared-tui.js +4 -11
- package/dist/shared-tui.js.map +1 -1
- package/dist/terminal-window.d.ts.map +1 -1
- package/dist/terminal-window.js +34 -29
- package/dist/terminal-window.js.map +1 -1
- package/dist/tmux-attachment.d.ts +17 -0
- package/dist/tmux-attachment.d.ts.map +1 -0
- package/dist/tmux-attachment.js +89 -0
- package/dist/tmux-attachment.js.map +1 -0
- package/package.json +2 -2
- package/tui/dist/hydrate.d.ts.map +1 -1
- package/tui/dist/hydrate.js +8 -3
- package/tui/dist/hydrate.js.map +1 -1
- package/tui/dist/render.d.ts.map +1 -1
- package/tui/dist/render.js +7 -1
- package/tui/dist/render.js.map +1 -1
- package/tui/dist/terminals/terminal-model.d.ts.map +1 -1
- package/tui/dist/terminals/terminal-model.js +2 -1
- package/tui/dist/terminals/terminal-model.js.map +1 -1
- package/ui/dist/assets/{index-CMBgYrS7.js → index-Ch6UxNld.js} +88 -88
- package/ui/dist/index.html +1 -1
|
@@ -0,0 +1,306 @@
|
|
|
1
|
+
#!/usr/bin/env python3
|
|
2
|
+
"""OpenRig environment-driver v1 guest operations and bounded Claude startup latch.
|
|
3
|
+
|
|
4
|
+
Baked into the selected image. No provider credentials, model policy, histories or
|
|
5
|
+
work payloads are built into this helper. Native restore belongs to a separate effect.
|
|
6
|
+
"""
|
|
7
|
+
import argparse
|
|
8
|
+
import base64
|
|
9
|
+
import fcntl
|
|
10
|
+
import hashlib
|
|
11
|
+
import json
|
|
12
|
+
import os
|
|
13
|
+
from pathlib import Path
|
|
14
|
+
import re
|
|
15
|
+
import sys
|
|
16
|
+
import subprocess
|
|
17
|
+
import signal
|
|
18
|
+
import stat
|
|
19
|
+
import time
|
|
20
|
+
import uuid
|
|
21
|
+
|
|
22
|
+
LIMIT = 1024 * 1024
|
|
23
|
+
DEFAULT_ROOT = "/sandbox/openrig"
|
|
24
|
+
|
|
25
|
+
|
|
26
|
+
class Refused(Exception):
|
|
27
|
+
pass
|
|
28
|
+
|
|
29
|
+
|
|
30
|
+
def digest(data):
|
|
31
|
+
return hashlib.sha256(data).hexdigest()
|
|
32
|
+
|
|
33
|
+
|
|
34
|
+
def safe(root, raw):
|
|
35
|
+
root = Path(root)
|
|
36
|
+
path = Path(raw)
|
|
37
|
+
if not root.is_absolute() or root == Path("/") or any(part.is_symlink() for part in (root, *root.parents)):
|
|
38
|
+
raise Refused("environment_root_invalid")
|
|
39
|
+
if not path.is_absolute():
|
|
40
|
+
path = root / path
|
|
41
|
+
try:
|
|
42
|
+
parts = path.relative_to(root).parts
|
|
43
|
+
except ValueError:
|
|
44
|
+
raise Refused("environment_path_outside_root")
|
|
45
|
+
if not parts or any(part in ("", ".", "..") for part in parts):
|
|
46
|
+
raise Refused("environment_path_invalid")
|
|
47
|
+
current = root
|
|
48
|
+
for part in parts:
|
|
49
|
+
current = current / part
|
|
50
|
+
if current.is_symlink():
|
|
51
|
+
raise Refused("environment_symlink")
|
|
52
|
+
return path
|
|
53
|
+
|
|
54
|
+
|
|
55
|
+
def regular(root, raw, limit=LIMIT):
|
|
56
|
+
path = safe(root, raw)
|
|
57
|
+
parts = path.relative_to(root).parts
|
|
58
|
+
directory = None
|
|
59
|
+
try:
|
|
60
|
+
# Ancestors need traversal, not a directory-read grant. Anchor reads at the selected root.
|
|
61
|
+
directory = os.open(root, os.O_RDONLY | os.O_DIRECTORY | os.O_NOFOLLOW)
|
|
62
|
+
for part in parts[:-1]:
|
|
63
|
+
child = os.open(part, os.O_RDONLY | os.O_DIRECTORY | os.O_NOFOLLOW, dir_fd=directory)
|
|
64
|
+
os.close(directory)
|
|
65
|
+
directory = child
|
|
66
|
+
fd = os.open(parts[-1], os.O_RDONLY | os.O_NOFOLLOW | os.O_NONBLOCK, dir_fd=directory)
|
|
67
|
+
try:
|
|
68
|
+
before = os.fstat(fd)
|
|
69
|
+
if not stat.S_ISREG(before.st_mode) or before.st_size > limit:
|
|
70
|
+
raise Refused("environment_file_invalid")
|
|
71
|
+
with os.fdopen(fd, "rb", closefd=False) as stream:
|
|
72
|
+
data = stream.read(limit + 1)
|
|
73
|
+
after = os.fstat(fd)
|
|
74
|
+
if len(data) > limit or len(data) != before.st_size or after.st_size != before.st_size or after.st_mtime_ns != before.st_mtime_ns:
|
|
75
|
+
raise Refused("environment_file_invalid")
|
|
76
|
+
return data
|
|
77
|
+
finally:
|
|
78
|
+
os.close(fd)
|
|
79
|
+
except FileNotFoundError:
|
|
80
|
+
raise Refused("environment_file_missing")
|
|
81
|
+
except OSError:
|
|
82
|
+
raise Refused("environment_file_invalid")
|
|
83
|
+
finally:
|
|
84
|
+
if directory is not None:
|
|
85
|
+
os.close(directory)
|
|
86
|
+
|
|
87
|
+
|
|
88
|
+
def atomic(root, raw, data):
|
|
89
|
+
path = safe(root, raw)
|
|
90
|
+
path.parent.mkdir(parents=True, exist_ok=True)
|
|
91
|
+
safe(root, path)
|
|
92
|
+
temp = path.parent / (".openrig-" + uuid.uuid4().hex)
|
|
93
|
+
fd = os.open(temp, os.O_WRONLY | os.O_CREAT | os.O_EXCL | os.O_NOFOLLOW, 0o600)
|
|
94
|
+
try:
|
|
95
|
+
with os.fdopen(fd, "wb") as stream:
|
|
96
|
+
stream.write(data)
|
|
97
|
+
stream.flush()
|
|
98
|
+
os.fsync(stream.fileno())
|
|
99
|
+
os.replace(temp, path)
|
|
100
|
+
finally:
|
|
101
|
+
if temp.exists():
|
|
102
|
+
temp.unlink()
|
|
103
|
+
|
|
104
|
+
|
|
105
|
+
def descriptor(root, pending=False):
|
|
106
|
+
name = "control/launch.pending.json" if pending else "control/launch.json"
|
|
107
|
+
value = json.loads(regular(root, name))
|
|
108
|
+
if value.get("version") != 1 or not value.get("generation") or not value.get("bindingId"):
|
|
109
|
+
raise Refused("environment_descriptor_invalid")
|
|
110
|
+
for file in value["files"]:
|
|
111
|
+
data = regular(root, file["path"])
|
|
112
|
+
if len(data) != file["bytes"] or digest(data) != file["sha256"]:
|
|
113
|
+
raise Refused("environment_projection_changed")
|
|
114
|
+
# P1-P3 never silently replace a requested native conversation with a fresh one.
|
|
115
|
+
if value.get("resumeToken"):
|
|
116
|
+
if value.get("nativeType") != "community:openshell-claude" or value["resumeToken"] != value["nativeId"]:
|
|
117
|
+
raise Refused("environment_native_identity_invalid")
|
|
118
|
+
checkpoint = value.get("checkpoint", {})
|
|
119
|
+
files = checkpoint.get("files", []) if isinstance(checkpoint, dict) else []
|
|
120
|
+
if not isinstance(files, list) or not 1 <= len(files) <= 129:
|
|
121
|
+
raise Refused("environment_checkpoint_invalid")
|
|
122
|
+
history = [file for file in files if file.get("path", "").startswith("native/projects/")]
|
|
123
|
+
if len(history) != 1 or not history[0]["path"].endswith("/" + value["nativeId"] + ".jsonl"):
|
|
124
|
+
raise Refused("environment_checkpoint_identity_mismatch")
|
|
125
|
+
if checkpoint.get("nativeId") != value["nativeId"] or checkpoint.get("nativeType") != value["nativeType"]:
|
|
126
|
+
raise Refused("environment_checkpoint_identity_mismatch")
|
|
127
|
+
for file in files:
|
|
128
|
+
data = regular(root, file["path"])
|
|
129
|
+
if digest(data) != file["sha256"] or len(data) != file["bytes"]:
|
|
130
|
+
raise Refused("environment_checkpoint_changed")
|
|
131
|
+
if not file["path"].startswith("native/projects/"):
|
|
132
|
+
continue
|
|
133
|
+
rows = [json.loads(line) for line in data.decode().splitlines()]
|
|
134
|
+
if not any(row.get("sessionId") == value["nativeId"] and row.get("type") in ("user", "assistant") for row in rows):
|
|
135
|
+
raise Refused("environment_checkpoint_identity_mismatch")
|
|
136
|
+
if any(row.get("sessionId", value["nativeId"]) != value["nativeId"] for row in rows):
|
|
137
|
+
raise Refused("environment_checkpoint_identity_mismatch")
|
|
138
|
+
if not checkpoint.get("files"):
|
|
139
|
+
raise Refused("environment_checkpoint_missing")
|
|
140
|
+
if not re.fullmatch(r"[0-9a-f-]{36}", value["nativeId"]):
|
|
141
|
+
raise Refused("environment_native_identity_invalid")
|
|
142
|
+
return value
|
|
143
|
+
|
|
144
|
+
|
|
145
|
+
def launch(root):
|
|
146
|
+
deadline = time.monotonic() + 600
|
|
147
|
+
while not safe(root, "control/launch.json").exists():
|
|
148
|
+
if time.monotonic() >= deadline:
|
|
149
|
+
raise Refused("environment_preparation_expired")
|
|
150
|
+
time.sleep(.2)
|
|
151
|
+
value = descriptor(root)
|
|
152
|
+
fd = os.open(safe(root, "control/native.lock"), os.O_CREAT | os.O_RDWR | os.O_NOFOLLOW, 0o600)
|
|
153
|
+
fcntl.flock(fd, fcntl.LOCK_EX | fcntl.LOCK_NB)
|
|
154
|
+
os.set_inheritable(fd, True)
|
|
155
|
+
env = {"PATH": "/usr/local/bin:/usr/bin:/bin", "HOME": str(Path(root) / "native"),
|
|
156
|
+
"CLAUDE_CONFIG_DIR": str(Path(root) / "native")}
|
|
157
|
+
secret = json.loads(regular(root, "control/activity.json"))
|
|
158
|
+
allowed = {"OPENRIG_URL", "OPENRIG_ACTIVITY_HOOK_TOKEN", "OPENRIG_NODE_ID", "OPENRIG_SESSION_NAME", "OPENRIG_OCCUPANT_GENERATION"}
|
|
159
|
+
if set(secret) != allowed or secret["OPENRIG_OCCUPANT_GENERATION"] != value["generation"]:
|
|
160
|
+
raise Refused("environment_activity_projection_invalid")
|
|
161
|
+
env.update(secret)
|
|
162
|
+
env.update({"DISABLE_AUTOUPDATER": "1", "CLAUDE_CODE_DISABLE_NONESSENTIAL_TRAFFIC": "1",
|
|
163
|
+
"OPENRIG_RUNTIME": "openshell-claude", "OPENRIG_NODE": "/usr/bin/node",
|
|
164
|
+
"OPENRIG_ENVIRONMENT_BINDING": value["bindingId"]})
|
|
165
|
+
if safe(root, "control/provider-api-ref").exists():
|
|
166
|
+
atomic(root, "native/settings.json", json.dumps({"apiKeyHelper": "cat /sandbox/openrig/control/provider-api-ref"}).encode())
|
|
167
|
+
# Provider-owned injection may supply these native endpoint references. No host environment is copied.
|
|
168
|
+
for name in ("ANTHROPIC_BASE_URL", "ANTHROPIC_API_KEY"):
|
|
169
|
+
if name in os.environ:
|
|
170
|
+
env[name] = os.environ[name]
|
|
171
|
+
argv = ["/usr/local/bin/claude", "--resume" if value.get("resumeToken") else "--session-id", value["nativeId"], "--strict-mcp-config", "--mcp-config", str(safe(root, "control/coordination.json"))]
|
|
172
|
+
for plugin in value.get("plugins", []):
|
|
173
|
+
argv.extend(["--plugin-dir", str(safe(root, plugin))])
|
|
174
|
+
if value.get("model"):
|
|
175
|
+
argv.extend(["--model", value["model"]])
|
|
176
|
+
if value.get("effort"):
|
|
177
|
+
argv.extend(["--effort", value["effort"]])
|
|
178
|
+
if value.get("permissionMode"):
|
|
179
|
+
argv.extend(["--permission-mode", value["permissionMode"]])
|
|
180
|
+
work = safe(root, "work")
|
|
181
|
+
work.mkdir(exist_ok=True)
|
|
182
|
+
os.chdir(work)
|
|
183
|
+
child = subprocess.Popen(argv, env=env, stdin=sys.stdin, stdout=sys.stdout, stderr=sys.stderr)
|
|
184
|
+
started = process_start(child.pid)
|
|
185
|
+
atomic(root, "control/native.json", json.dumps({"nativeId": value["nativeId"], "generation": value["generation"], "pid": child.pid, "started": started}).encode())
|
|
186
|
+
code = child.wait()
|
|
187
|
+
atomic(root, "control/native-exit.json", json.dumps({"nativeId": value["nativeId"], "generation": value["generation"], "pid": child.pid, "exitCode": code}).encode())
|
|
188
|
+
# Keep bounded file/control access after native exit, so checkpoint/export do not depend on a live model.
|
|
189
|
+
deadline = time.monotonic() + 1800
|
|
190
|
+
while time.monotonic() < deadline:
|
|
191
|
+
time.sleep(1)
|
|
192
|
+
|
|
193
|
+
|
|
194
|
+
def process_start(pid):
|
|
195
|
+
raw = (Path("/proc") / str(pid) / "stat").read_text()
|
|
196
|
+
return raw[raw.rfind(")") + 2:].split()[19]
|
|
197
|
+
|
|
198
|
+
|
|
199
|
+
def native_identity(root):
|
|
200
|
+
value = json.loads(regular(root, "control/native.json"))
|
|
201
|
+
try:
|
|
202
|
+
if process_start(value["pid"]) != value["started"]:
|
|
203
|
+
raise Refused("environment_native_changed")
|
|
204
|
+
fields = (Path("/proc") / str(value["pid"]) / "cmdline").read_bytes().split(b"\0")
|
|
205
|
+
if value["nativeId"].encode() not in fields or not any(b"claude" in field for field in fields):
|
|
206
|
+
raise Refused("environment_native_changed")
|
|
207
|
+
return {"ok": True, **value, "running": True}
|
|
208
|
+
except FileNotFoundError:
|
|
209
|
+
exit_record = json.loads(regular(root, "control/native-exit.json"))
|
|
210
|
+
if any(exit_record.get(key) != value.get(key) for key in ("nativeId", "generation", "pid")):
|
|
211
|
+
raise Refused("environment_native_unconfirmed")
|
|
212
|
+
return {"ok": True, **value, "running": False, "exitCode": exit_record["exitCode"]}
|
|
213
|
+
|
|
214
|
+
|
|
215
|
+
|
|
216
|
+
def main():
|
|
217
|
+
p = argparse.ArgumentParser(description=__doc__)
|
|
218
|
+
p.add_argument("--root", default=DEFAULT_ROOT)
|
|
219
|
+
for option in ("read", "stat", "stage", "install"):
|
|
220
|
+
p.add_argument("--" + option)
|
|
221
|
+
p.add_argument("--destination")
|
|
222
|
+
p.add_argument("--previous")
|
|
223
|
+
p.add_argument("--mode", choices=("0600", "0700"), default="0600")
|
|
224
|
+
p.add_argument("--prepare", action="store_true")
|
|
225
|
+
p.add_argument("--identity", action="store_true")
|
|
226
|
+
p.add_argument("--stop-native")
|
|
227
|
+
p.add_argument("--generation")
|
|
228
|
+
p.add_argument("--checkpoint-files", action="store_true")
|
|
229
|
+
args = p.parse_args()
|
|
230
|
+
root = Path(args.root)
|
|
231
|
+
if not root.is_absolute() or any(part.is_symlink() for part in (root, *root.parents)):
|
|
232
|
+
raise Refused("environment_root_invalid")
|
|
233
|
+
root.mkdir(parents=True, exist_ok=True)
|
|
234
|
+
if args.stage:
|
|
235
|
+
path = safe(root, args.stage)
|
|
236
|
+
if path.exists():
|
|
237
|
+
raise Refused("environment_stage_exists")
|
|
238
|
+
path.parent.mkdir(parents=True, exist_ok=True)
|
|
239
|
+
return {"ok": True}
|
|
240
|
+
if args.read or args.stat:
|
|
241
|
+
data = regular(root, args.read or args.stat)
|
|
242
|
+
return {"ok": True, "sha256": digest(data), "bytes": len(data),
|
|
243
|
+
**({"base64": base64.b64encode(data).decode()} if args.read else {})}
|
|
244
|
+
if args.install:
|
|
245
|
+
data = regular(root, args.install)
|
|
246
|
+
destination = safe(root, args.destination)
|
|
247
|
+
if destination.exists():
|
|
248
|
+
if args.previous == "missing" or digest(regular(root, destination)) != args.previous:
|
|
249
|
+
raise Refused("environment_projection_conflict")
|
|
250
|
+
elif args.previous != "missing":
|
|
251
|
+
raise Refused("environment_projection_changed")
|
|
252
|
+
atomic(root, destination, data)
|
|
253
|
+
os.chmod(destination, int(args.mode, 8))
|
|
254
|
+
safe(root, args.install).unlink()
|
|
255
|
+
return {"ok": True, "sha256": digest(data), "bytes": len(data)}
|
|
256
|
+
if args.prepare:
|
|
257
|
+
value = descriptor(root, pending=True)
|
|
258
|
+
encoded = json.dumps(value, sort_keys=True, separators=(",", ":")).encode()
|
|
259
|
+
published = safe(root, "control/launch.json")
|
|
260
|
+
if published.exists():
|
|
261
|
+
if regular(root, published) != encoded:
|
|
262
|
+
raise Refused("environment_native_already_selected")
|
|
263
|
+
return {"ok": True, "generation": value["generation"], "nativeId": value["nativeId"]}
|
|
264
|
+
# This is the guest provider's injected reference, never an owner-host environment value.
|
|
265
|
+
reference = os.environ.get("ANTHROPIC_API_KEY") or os.environ.get("CLAUDE_API_KEY")
|
|
266
|
+
if not reference:
|
|
267
|
+
raise Refused("environment_provider_reference_missing")
|
|
268
|
+
atomic(root, "control/provider-api-ref", reference.encode())
|
|
269
|
+
Path(root, "native").mkdir(exist_ok=True)
|
|
270
|
+
atomic(root, "control/launch.json", encoded)
|
|
271
|
+
return {"ok": True, "generation": value["generation"], "nativeId": value["nativeId"]}
|
|
272
|
+
if args.identity:
|
|
273
|
+
return native_identity(root)
|
|
274
|
+
if args.stop_native:
|
|
275
|
+
value = native_identity(root)
|
|
276
|
+
if value["nativeId"] != args.stop_native or value["generation"] != args.generation:
|
|
277
|
+
raise Refused("environment_native_changed")
|
|
278
|
+
if value["running"]:
|
|
279
|
+
os.kill(value["pid"], signal.SIGTERM)
|
|
280
|
+
deadline = time.monotonic() + 5
|
|
281
|
+
while time.monotonic() < deadline:
|
|
282
|
+
try:
|
|
283
|
+
if not native_identity(root)["running"]:
|
|
284
|
+
break
|
|
285
|
+
except (Refused, OSError):
|
|
286
|
+
pass
|
|
287
|
+
time.sleep(.1)
|
|
288
|
+
return {"ok": True, "signal": "TERM", "nativeId": value["nativeId"], "generation": value["generation"]}
|
|
289
|
+
if args.checkpoint_files:
|
|
290
|
+
value = native_identity(root)
|
|
291
|
+
relative = "native/projects/-sandbox-openrig-work/" + value["nativeId"] + ".jsonl"
|
|
292
|
+
data = regular(root, relative)
|
|
293
|
+
# A running writer's trailing partial record is not a checkpoint; retry after it settles.
|
|
294
|
+
if not data.endswith(b"\n"):
|
|
295
|
+
raise Refused("environment_checkpoint_incomplete")
|
|
296
|
+
return {"ok": True, "files": [{"path": relative, "bytes": len(data), "sha256": digest(data)}]}
|
|
297
|
+
launch(root)
|
|
298
|
+
|
|
299
|
+
|
|
300
|
+
if __name__ == "__main__":
|
|
301
|
+
try:
|
|
302
|
+
result = main()
|
|
303
|
+
if result is not None:
|
|
304
|
+
print(json.dumps(result))
|
|
305
|
+
except (Refused, ValueError, KeyError, OSError) as error:
|
|
306
|
+
print(json.dumps({"ok": False, "code": str(error) if isinstance(error, Refused) else "environment_guest_unconfirmed"}))
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
version: 1
|
|
2
|
+
filesystem_policy:
|
|
3
|
+
include_workdir: true
|
|
4
|
+
read_only: [/usr, /lib, /lib64, /etc, /opt/openrig, /proc, /sys]
|
|
5
|
+
read_write: [/sandbox/openrig, /tmp]
|
|
6
|
+
network_policies:
|
|
7
|
+
openrig_mcp:
|
|
8
|
+
endpoints:
|
|
9
|
+
- host: host.openshell.internal
|
|
10
|
+
port: 7781
|
|
11
|
+
protocol: rest
|
|
12
|
+
access: read-write
|
|
13
|
+
enforcement: enforce
|
|
14
|
+
binaries:
|
|
15
|
+
- path: /usr/local/bin/claude
|
|
16
|
+
openrig_activity:
|
|
17
|
+
endpoints:
|
|
18
|
+
- host: host.openshell.internal
|
|
19
|
+
port: 7782
|
|
20
|
+
protocol: rest
|
|
21
|
+
access: read-write
|
|
22
|
+
enforcement: enforce
|
|
23
|
+
binaries:
|
|
24
|
+
- path: /usr/bin/node
|
|
25
|
+
claude_startup_connectivity:
|
|
26
|
+
endpoints:
|
|
27
|
+
- host: platform.claude.com
|
|
28
|
+
port: 443
|
|
29
|
+
protocol: rest
|
|
30
|
+
access: read-only
|
|
31
|
+
enforcement: enforce
|
|
32
|
+
binaries:
|
|
33
|
+
- path: /usr/local/bin/claude
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
format: 1
|
|
2
|
+
name: openshell-claude
|
|
3
|
+
command: rig environment connect
|
|
4
|
+
maintainer: OpenRig contributors
|
|
5
|
+
limits:
|
|
6
|
+
- Requires explicit environment create or attach before rig up; driver protocol 1, OpenShell 0.1.6 and Claude Code 2.1.310.
|
|
7
|
+
- Projects required context and verifies destination bytes; native ingestion and provider readiness need separate observation.
|
|
8
|
+
- Closing the viewer does not stop native execution or compute.
|
|
9
|
+
- Native restore requires a verified private checkpoint and explicitly recreated same-host compute; missing state never starts fresh.
|
|
10
|
+
launch_result: true
|
|
11
|
+
resume: true
|
|
12
|
+
passes_model: true
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
version: "0.2"
|
|
2
|
+
name: openshell-example
|
|
3
|
+
pods:
|
|
4
|
+
- id: team
|
|
5
|
+
label: Team
|
|
6
|
+
members:
|
|
7
|
+
- id: coordinator
|
|
8
|
+
agent_ref: local:agents/coordinator
|
|
9
|
+
runtime: claude-code
|
|
10
|
+
profile: default
|
|
11
|
+
cwd: .
|
|
12
|
+
- id: worker
|
|
13
|
+
agent_ref: local:agents/worker
|
|
14
|
+
runtime: openshell-claude
|
|
15
|
+
profile: default
|
|
16
|
+
cwd: .
|
|
17
|
+
edges:
|
|
18
|
+
- kind: delegates_to
|
|
19
|
+
from: coordinator
|
|
20
|
+
to: worker
|
|
@@ -113,7 +113,7 @@ A fork can create a candidate occupant; handover binds it into an existing seat.
|
|
|
113
113
|
The continuity outcome is `forked`; the binding outcome is independent.
|
|
114
114
|
|
|
115
115
|
The packaged `rig handover <seat>` and `rig seat handover <seat>` accept `fresh`,
|
|
116
|
-
`discovered:<id>`, `fork:<
|
|
116
|
+
`discovered:<id>`, `fork:<seat>` and `rebuild` sources. Use `--dry-run` to request
|
|
117
117
|
planning only. Without it, these surfaces can execute; do not infer read-only
|
|
118
118
|
behavior from the shorter seat command's planning-oriented description.
|
|
119
119
|
`rig seat status <seat>` is the read-only observability surface.
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# Agent help: the single troubleshooting and escalation guide (docs/reference/help.md).
|
|
2
2
|
name: help
|
|
3
|
-
version: "0.7.
|
|
3
|
+
version: "0.7.8"
|
|
4
4
|
taxonomy: world
|
|
5
5
|
purpose: "What an agent does when its user says OpenRig isn't working: diagnose, fix within permissions, verify, and escalate to OpenRig support."
|
|
6
6
|
files:
|
|
@@ -234,10 +234,12 @@ unseen — which makes messages the one delivery channel that never gets skipped
|
|
|
234
234
|
Associate rows with `rig queue create --slice <name-or-id>`; handoffs inherit tags unless replaced.
|
|
235
235
|
New slice views default to four automatic tiles (`--max-tiles` overrides it). Known empty slices
|
|
236
236
|
stay following; incomplete reads keep prior viewers, and draft/focus protection still applies.
|
|
237
|
-
A join refused before a pane split can join on a later refresh
|
|
237
|
+
A join refused before a pane split can join on a later refresh. Hold notices keep the seat and phase.
|
|
238
|
+
The first notice keeps the original reason; later notices can show a generic reason, while the
|
|
239
|
+
original failure remains in the journal.
|
|
238
240
|
An attach that ran and then exited to a shell is not restarted automatically; the whole slice view
|
|
239
241
|
can hold until that tile is resolved. No tested workaround is offered for that case.
|
|
240
|
-
Slice following targets the Linux Herdr 0.9.5 / protocol 22 path. Mission following is not included.
|
|
242
|
+
Slice following targets the Linux Herdr 0.9.5 / protocol 22 path. Mission following is not included in 0.7.6.
|
|
241
243
|
An unconfirmed pane is reported as `pane_unconfirmed`, not counted as opened. Inspect before
|
|
242
244
|
retrying: an unconfirmed result does not prove that nothing opened.
|
|
243
245
|
Add `--session <name>` to select a Herdr session for that request; `--session default`
|
|
@@ -347,11 +349,17 @@ your context, your compaction and your replacement — and it is the only thing
|
|
|
347
349
|
`rig config set queue.wake_human_rung explicit-only` (default `always`) keeps that post
|
|
348
350
|
for rows addressed to a person (an `@external` address or a registered human); the rest stop at
|
|
349
351
|
`rig view show escalations`. A seat stuck at a prompt only a person can clear still reaches one,
|
|
350
|
-
and an unreadable human registry
|
|
352
|
+
and an unreadable human registry keeps every row eligible for that last step; it does not
|
|
353
|
+
establish that a channel can deliver. A seat held at a choice prompt that no hook
|
|
351
354
|
announces (a usage-limit dialog, say) escalates once the refusal has held for one retry interval
|
|
352
355
|
(`queue.wake_retry_interval_seconds`, 300 seconds by default). Choice-prompt alerts follow this
|
|
353
356
|
setting and reach a person one at a time per machine; later ones wait as rows while the first
|
|
354
|
-
seat stays blocked.
|
|
357
|
+
seat stays blocked. Escalations aren't posted while the person's channel can't take them. They stay visible
|
|
358
|
+
as rows with a reason and are tried again later. The configured escalation route still runs first.
|
|
359
|
+
An older, unaccepted alert addressed to a person is kept on the same row and rerouted locally;
|
|
360
|
+
a delivery already accepted by the gateway keeps its existing route. Findings about an undelivered
|
|
361
|
+
wake-escalation notice stay visible without creating another wake escalation. Scheduling notices
|
|
362
|
+
are sent by OpenRig; their member rows keep their original senders and obligations.
|
|
355
363
|
- **`rig queue inbox-drop` / `inbox-pending` / `inbox-absorb` / `inbox-deny`** — put something in
|
|
356
364
|
front of a seat that it can *refuse*. Mail, not assignment.
|
|
357
365
|
- **`rig queue outbox-record` / `outbox-list`** — what you dispatched, in a record that survives
|
|
@@ -1062,8 +1070,10 @@ reaching them is ordinary work rather than an escalation.
|
|
|
1062
1070
|
request, then boundedly inspect its transport receipt. Posted means posted, not read;
|
|
1063
1071
|
pending, failed, or indeterminate delivery leaves the row intact. Inspect the same row's
|
|
1064
1072
|
transitions before retrying. `rig send` remains agent-terminal delivery only.
|
|
1065
|
-
`--human-questions-file` adds clickable decision questions.
|
|
1066
|
-
in `humanAnswers
|
|
1073
|
+
`--human-questions-file` adds clickable decision questions. On an unparked ask, a typed Slack
|
|
1074
|
+
reply is kept in `humanAnswers` under the first unanswered question. On a question parked on
|
|
1075
|
+
its own person, a typed reply resumes it but isn't recorded as the answer; the owner receives
|
|
1076
|
+
it as a message instead. Buttons work in both cases. Closing isn't approval.
|
|
1067
1077
|
- **When project policy calls for human judgment or an update, load `messaging-the-human`.**
|
|
1068
1078
|
Use `rig context get skills/core/messaging-the-human/SKILL.md` for a complete decision brief,
|
|
1069
1079
|
related supplemental detail and explicit quiet-update intent. An FYI creates no approval
|
|
@@ -191,11 +191,11 @@ You can also read [`skills/rigs/SKILL.md`](../../skills/rigs/SKILL.md) directly.
|
|
|
191
191
|
script will do and changes nothing:
|
|
192
192
|
|
|
193
193
|
```sh
|
|
194
|
-
curl -fsSL https://raw.githubusercontent.com/mvschwarz/openrig/v0.7.
|
|
194
|
+
curl -fsSL https://raw.githubusercontent.com/mvschwarz/openrig/v0.7.8/scripts/install.sh | sh -s -- --dry-run
|
|
195
195
|
```
|
|
196
196
|
|
|
197
197
|
The same command without `--dry-run`,
|
|
198
|
-
`curl -fsSL https://raw.githubusercontent.com/mvschwarz/openrig/v0.7.
|
|
198
|
+
`curl -fsSL https://raw.githubusercontent.com/mvschwarz/openrig/v0.7.8/scripts/install.sh | sh`, installs the
|
|
199
199
|
latest published `@openrig/cli` with `npm install -g`,
|
|
200
200
|
runs the Node.js and SQLite check, then `rig setup --dry-run` and `rig setup`. `rig setup` checks both Claude Code and
|
|
201
201
|
Codex and may install a missing one, as described below. A failed step prints
|
|
@@ -509,7 +509,12 @@ rig terminal open saved:kernel --provider herdr --json
|
|
|
509
509
|
rig terminal open saved:kernel --provider cmux --json
|
|
510
510
|
```
|
|
511
511
|
|
|
512
|
-
Use `rig terminal status --json` to inspect provider availability and
|
|
512
|
+
Use `rig terminal status --json` to inspect provider availability, liveness and the
|
|
513
|
+
daemon's effective tmux server. To keep managed seats out of your personal tmux
|
|
514
|
+
session list, opt into [an isolated server](tmux-servers.md) with
|
|
515
|
+
`rig config set terminal.tmux_server isolated`; existing live seats defer the
|
|
516
|
+
switch until they are stopped and the daemon restarts.
|
|
517
|
+
|
|
513
518
|
To keep rigs in separate Herdr sessions, select one explicitly:
|
|
514
519
|
`rig terminal open future-prod-rig --provider herdr --session future-prod`.
|
|
515
520
|
`--session default` selects Herdr's default session; omitting the option keeps
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
# Reference guides the help pack and command help link to, loaded one file or section at a time by address
|
|
2
2
|
# (rig context get reference/<file>#<section>). Each file is a symlink to docs/reference/.
|
|
3
3
|
name: reference
|
|
4
|
-
version: "0.7.
|
|
4
|
+
version: "0.7.8"
|
|
5
5
|
taxonomy: world
|
|
6
6
|
purpose: "Version-matched reference guides the help guide and command help link to. Load a single file or section by address; don't load the whole pack."
|
|
7
7
|
files:
|
|
@@ -635,8 +635,15 @@ Use `env:` for settings only. Credentials belong in the provider's own login or
|
|
|
635
635
|
|
|
636
636
|
### Switching credentials while keeping the conversation
|
|
637
637
|
|
|
638
|
-
`rig provider switch` resumes a running seat in its existing home and pane.
|
|
639
|
-
|
|
638
|
+
`rig provider switch` resumes a running seat in its existing home and pane. A stopped Claude Code
|
|
639
|
+
seat isn't relaunched: the switch saves the new reference for its next launch, but only when the
|
|
640
|
+
launch it predicts resumes the seat's conversation. That prediction covers the snapshot that
|
|
641
|
+
launch would use and restore's automatic periodic carry. It then prints the launch that resumes:
|
|
642
|
+
`rig launch <rig> <seat> --snapshot-id <id>` for a saved conversation, or a plain
|
|
643
|
+
`rig launch <rig> <seat>` when the resume comes through the periodic carry, which naming a
|
|
644
|
+
snapshot would turn off. Otherwise it refuses and changes nothing. `rig provider precheck` gives
|
|
645
|
+
the same answer.
|
|
646
|
+
For Claude Code, select an API-key file, a subscription-token file, or the home's stored login:
|
|
640
647
|
|
|
641
648
|
```sh
|
|
642
649
|
rig provider precheck --seat dev-a@my-rig --to-account api-budget --api-key-file /secure/claude-api-key
|
|
@@ -742,6 +749,7 @@ directory's `CLAUDE.md`, including blocks written by other rigs.
|
|
|
742
749
|
| `model` | string | no | — | Model override. Runtime-specific (e.g., `claude-opus-4-6` for Claude Code). |
|
|
743
750
|
| `effort` | string | no | — | Reasoning effort override, trimmed. Claude gets `--effort`, Codex `-c model_reasoning_effort=…`, Pi `--thinking` (see "Pi" below). A non-string value is ignored with an advisory. |
|
|
744
751
|
| `advisor` | string | no | — | Claude-only Advisor model for this seat. Overrides the AgentSpec profile/default; blank or non-string values are ignored with an advisory. |
|
|
752
|
+
| `claude_mcp` | `none` | no | normal loading | Claude members only. Disable MCP server loading for this agent on every launch and resume. Omit the field to keep Claude's normal configuration; see [Claude MCP loading](#claude-mcp-loading-runtime-claude-code). |
|
|
745
753
|
| `permission_policy` | string | no | — | Member-level permission policy; overrides the rig's. Not valid on terminal members. |
|
|
746
754
|
| `env` | map | no | — | Launch environment for this seat, laid over the rig's `env`. Same rules as the rig-level field. Valid on terminal members too. See "Launch environment" below. |
|
|
747
755
|
| `agent_file` | string | no | — | Claude members only. A Claude agent definition (a `.md` file with `name` in its frontmatter) for this seat. It's copied into the seat's own storage and launched as `--agent openrig:<name>`. A path beside the spec: no `..`, not absolute. |
|
|
@@ -755,6 +763,53 @@ directory's `CLAUDE.md`, including blocks written by other rigs.
|
|
|
755
763
|
| `starter_ref` | object | no | — | `{ name }` of an agent starter (`^[a-zA-Z0-9][a-zA-Z0-9_-]*$`) whose files lead the seat's startup. Not valid on terminal members or with a fork. |
|
|
756
764
|
| `startup` | StartupBlock | no | — | Member-level startup files and actions. Applied only to this member. |
|
|
757
765
|
|
|
766
|
+
### Claude MCP loading (`runtime: claude-code`)
|
|
767
|
+
|
|
768
|
+
Set `claude_mcp: none` on an individual member to launch it without MCP servers:
|
|
769
|
+
|
|
770
|
+
```yaml
|
|
771
|
+
members:
|
|
772
|
+
- id: reviewer
|
|
773
|
+
agent_ref: local:agents/reviewer
|
|
774
|
+
profile: default
|
|
775
|
+
runtime: claude-code
|
|
776
|
+
cwd: .
|
|
777
|
+
claude_mcp: none
|
|
778
|
+
```
|
|
779
|
+
|
|
780
|
+
OpenRig passes `--strict-mcp-config --mcp-config '{"mcpServers":{}}'` to
|
|
781
|
+
Claude for this seat. Strict mode selects only the supplied empty server set,
|
|
782
|
+
excluding servers from user, project, team and plugin configuration. It does
|
|
783
|
+
not disable plugin skills or change the seat's permission mode. The choice is
|
|
784
|
+
saved on the seat and carried through fresh starts, forks, resumes (including
|
|
785
|
+
saved startup context) and handover successors. Export and bundle round trips
|
|
786
|
+
preserve it. The same field is supported on legacy `nodes` declarations.
|
|
787
|
+
|
|
788
|
+
Other agents in the same directory keep their own choices; OpenRig does not
|
|
789
|
+
rewrite shared MCP configuration files. Omit the field for Claude's normal
|
|
790
|
+
loading. A later launch from an authored spec without the field clears the
|
|
791
|
+
seat's saved opt-out once the launch is accepted for startup; a rejected
|
|
792
|
+
launch leaves the choice unchanged. Restarting from saved context keeps it.
|
|
793
|
+
Only `none` is accepted, and the field is invalid on other runtimes. If the
|
|
794
|
+
seat switches to another runtime, the Claude choice stays dormant and applies
|
|
795
|
+
again if it switches back. A currently running Claude process is unaffected.
|
|
796
|
+
Export describes the current runtime and omits a dormant Claude choice. YAML
|
|
797
|
+
exports name each affected agent in a `# Not carried:` comment, which `rig export`
|
|
798
|
+
also prints after writing the file; JSON exports keep their existing shape. If
|
|
799
|
+
you rebuild from that export and switch back to Claude, restore `claude_mcp: none`
|
|
800
|
+
in the Claude declaration. Re-check this setting after downgrading
|
|
801
|
+
OpenRig too: older versions can ignore it.
|
|
802
|
+
|
|
803
|
+
Shutdown resume probes and the displayed native recovery commands (including
|
|
804
|
+
the conversation picker) also carry the saved MCP choice. If shutdown cannot
|
|
805
|
+
read that choice, it skips the probe and retains the token; shutdown proceeds.
|
|
806
|
+
|
|
807
|
+
This opt-out is incompatible with an active enterprise `managed-mcp.json`:
|
|
808
|
+
[Claude rejects strict overrides of that managed server set](https://code.claude.com/docs/en/managed-mcp#servers-passed-with---mcp-config-or---strict-mcp-config).
|
|
809
|
+
OpenRig keeps the requested opt-out flags, so startup and resume remain subject
|
|
810
|
+
to that native refusal; it does not fall back to loading servers. Use a host
|
|
811
|
+
without that managed configuration, or omit the opt-out to use the managed set.
|
|
812
|
+
|
|
758
813
|
### Claude Advisor (`runtime: claude-code`)
|
|
759
814
|
|
|
760
815
|
Set `advisor` independently of the primary `model`:
|
|
@@ -944,19 +999,21 @@ the modified topology, run `rig snapshot <rig-id>` and use its returned ID with
|
|
|
944
999
|
|
|
945
1000
|
Startup blocks can appear at three levels: rig, pod, and member. They are merged additively via the startup layering model (see [the layering model](agent-startup-guide.md#the-layering-model)). The rig's `culture_file` joins as a required file with the `auto` hint in the culture layer, on both fresh start and restore.
|
|
946
1001
|
|
|
947
|
-
`
|
|
948
|
-
|
|
949
|
-
|
|
950
|
-
|
|
951
|
-
|
|
952
|
-
|
|
1002
|
+
For member `startup:`, export uses that seat's retained launch recipe (or its pre-launch materialization) rather than guessing from projected files. If that source is unavailable or a member's files came from a different rig root, the YAML names the member's omitted startup; JSON export names omissions in the `X-OpenRig-Export-Warnings` response header. An older seat without a recipe may have had no member startup or an unretained one: inspect its source before re-importing. When member startup files are present in the export, `rig export` checks required paths against the output folder and warns for missing files. The export does not copy member startup files.
|
|
1003
|
+
|
|
1004
|
+
`rig export` includes the rig's saved culture file and startup block, and writes
|
|
1005
|
+
saved pod startup files and actions under their pod. The file and action order,
|
|
1006
|
+
delivery hints, required flags, orientation and `applies_on` selections are retained.
|
|
1007
|
+
Pod actions are saved for export when a new rig is created; older rigs and pods
|
|
1008
|
+
added from a separate expansion may not have those declarations recorded. Export
|
|
1009
|
+
does not reconstruct them from a member's combined startup context; keep the source
|
|
1010
|
+
spec when those declarations are needed. This does not change which startup actions
|
|
1011
|
+
are inherited when a seat is added later.
|
|
953
1012
|
|
|
954
1013
|
File paths remain relative to the exported spec's folder. When exporting to a
|
|
955
1014
|
different folder, supply the referenced startup files there or import with the
|
|
956
|
-
original `--rig-root`. The CLI warns once per missing required rig or
|
|
957
|
-
missing optional files do not trigger that warning.
|
|
958
|
-
member startup blocks remain outside this export; keep the source spec when you
|
|
959
|
-
need those declarations.
|
|
1015
|
+
original `--rig-root`. The CLI warns once per missing required rig, pod or member
|
|
1016
|
+
file; missing optional files do not trigger that warning.
|
|
960
1017
|
|
|
961
1018
|
### Files
|
|
962
1019
|
|