@ours.network/fleet 1.2.0-nightly.8 → 1.2.0-nightly.81
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 +280 -68
- package/dist/account-origin.d.ts +5 -0
- package/dist/account-origin.js +31 -0
- package/dist/agent-ours/bridge.js +26 -9
- package/dist/agent-ours/correspondence.d.ts +10 -0
- package/dist/agent-ours/correspondence.js +1 -0
- package/dist/agent-ours/file-rpc.d.ts +12 -0
- package/dist/agent-ours/file-rpc.js +18 -4
- package/dist/agent-ours/harness.js +9 -1
- package/dist/agent-ours/mcp-endpoint.d.ts +22 -0
- package/dist/agent-ours/mcp-endpoint.js +101 -25
- package/dist/agent-ours/runtime.d.ts +9 -1
- package/dist/agent-ours/runtime.js +50 -2
- package/dist/agent-ours/service.d.ts +27 -1
- package/dist/agent-ours/service.js +107 -13
- package/dist/application/codex-models.d.ts +15 -0
- package/dist/application/codex-models.js +56 -0
- package/dist/application/conversation-history.d.ts +34 -0
- package/dist/application/conversation-history.js +294 -0
- package/dist/application/conversation-role-observer.d.ts +62 -0
- package/dist/application/conversation-role-observer.js +206 -0
- package/dist/application/fleet-query-service.d.ts +1 -1
- package/dist/application/fleet-query-service.js +3 -3
- package/dist/application/log-service.js +8 -8
- package/dist/application/model-catalog.d.ts +1 -1
- package/dist/application/model-catalog.js +5 -2
- package/dist/application/preset-provenance.d.ts +19 -0
- package/dist/application/preset-provenance.js +59 -0
- package/dist/application/resource-observer.d.ts +43 -0
- package/dist/application/resource-observer.js +323 -0
- package/dist/application/role-creation-service.js +3 -2
- package/dist/application/role-removal-service.js +17 -3
- package/dist/application/role-repository.d.ts +1 -1
- package/dist/application/role-repository.js +30 -7
- package/dist/application/room-layout-definitions.d.ts +45 -0
- package/dist/application/room-layout-definitions.js +130 -0
- package/dist/application/session-control.d.ts +63 -17
- package/dist/application/session-control.js +221 -23
- package/dist/application/supervisor-ours-tools.js +5 -11
- package/dist/application/task-layouts.d.ts +91 -0
- package/dist/application/task-layouts.js +261 -0
- package/dist/application/task-room-service.d.ts +101 -3
- package/dist/application/task-room-service.js +286 -33
- package/dist/application/types.d.ts +2 -0
- package/dist/atomic-file.d.ts +34 -1
- package/dist/atomic-file.js +161 -18
- package/dist/briefing.d.ts +3 -1
- package/dist/briefing.js +120 -31
- package/dist/build-info.json +9 -4
- package/dist/capabilities.d.ts +9 -1
- package/dist/capabilities.js +13 -0
- package/dist/cli.js +402 -38
- package/dist/client-profile.d.ts +5 -17
- package/dist/client-profile.js +4 -127
- package/dist/config.d.ts +45 -0
- package/dist/config.js +57 -6
- package/dist/creation.d.ts +1 -1
- package/dist/creation.js +4 -4
- package/dist/daemon-recovery.d.ts +14 -9
- package/dist/daemon-recovery.js +124 -115
- package/dist/docs.d.ts +1 -1
- package/dist/docs.js +227 -19
- package/dist/doctor.d.ts +4 -1
- package/dist/doctor.js +75 -60
- package/dist/erased-resources.d.ts +9 -0
- package/dist/erased-resources.js +87 -0
- package/dist/file-delivery/reader.d.ts +15 -0
- package/dist/file-delivery/reader.js +63 -0
- package/dist/file-delivery/store.d.ts +15 -0
- package/dist/file-delivery/store.js +124 -0
- package/dist/file-delivery/types.d.ts +19 -0
- package/dist/file-delivery/types.js +1 -0
- package/dist/fleet-command-audit.d.ts +13 -0
- package/dist/fleet-command-audit.js +31 -9
- package/dist/harness/agent-session.d.ts +4 -0
- package/dist/harness/claude-code-session.js +1 -1
- package/dist/harness/claude-code.js +21 -11
- package/dist/harness/claude-runtime.d.ts +12 -0
- package/dist/harness/claude-runtime.js +43 -0
- package/dist/harness/codex-app-server-proxy.d.ts +4 -1
- package/dist/harness/codex-app-server-proxy.js +41 -5
- package/dist/harness/codex-reasoning.d.ts +5 -0
- package/dist/harness/codex-reasoning.js +12 -0
- package/dist/harness/codex-runtime.d.ts +11 -1
- package/dist/harness/codex-runtime.js +31 -4
- package/dist/harness/codex-session.js +2 -2
- package/dist/harness/codex.js +24 -12
- package/dist/init-wizard.d.ts +2 -0
- package/dist/init-wizard.js +38 -19
- package/dist/isolation/policy.js +6 -1
- package/dist/isolation/types.d.ts +5 -0
- package/dist/managed-cli.d.ts +253 -0
- package/dist/managed-cli.js +923 -0
- package/dist/managed-recovery.d.ts +13 -0
- package/dist/managed-recovery.js +31 -0
- package/dist/minimal-setup.d.ts +2 -0
- package/dist/minimal-setup.js +44 -0
- package/dist/monitor.d.ts +9 -34
- package/dist/monitor.js +90 -153
- package/dist/notifications/fleet-producer.d.ts +31 -0
- package/dist/notifications/fleet-producer.js +351 -0
- package/dist/notifications/outbox.d.ts +59 -0
- package/dist/notifications/outbox.js +199 -0
- package/dist/notifications/target-cleanup.d.ts +16 -0
- package/dist/notifications/target-cleanup.js +75 -0
- package/dist/notifications/task-producer.d.ts +20 -0
- package/dist/notifications/task-producer.js +100 -0
- package/dist/ops.d.ts +2 -0
- package/dist/ops.js +20 -3
- package/dist/owner-channel/channel.js +17 -6
- package/dist/owner-channel/commands.d.ts +4 -0
- package/dist/owner-channel/commands.js +8 -0
- package/dist/owner-channel/lifecycle-outbox.js +4 -3
- package/dist/owner-channel/ours-client.js +2 -17
- package/dist/paths.d.ts +5 -0
- package/dist/paths.js +5 -0
- package/dist/preset-migration.js +55 -0
- package/dist/process-incarnation.d.ts +23 -0
- package/dist/process-incarnation.js +42 -0
- package/dist/reminders/manager.d.ts +75 -0
- package/dist/reminders/manager.js +278 -0
- package/dist/reminders/runtime.d.ts +27 -0
- package/dist/reminders/runtime.js +32 -0
- package/dist/reminders/schedule.d.ts +37 -0
- package/dist/reminders/schedule.js +104 -0
- package/dist/reminders/store.d.ts +341 -0
- package/dist/reminders/store.js +762 -0
- package/dist/reminders/tools.d.ts +20 -0
- package/dist/reminders/tools.js +114 -0
- package/dist/resolved-plan.js +1 -0
- package/dist/rooms-tasks/add-member.d.ts +48 -0
- package/dist/rooms-tasks/add-member.js +84 -0
- package/dist/rooms-tasks/archived-absence.d.ts +4 -0
- package/dist/rooms-tasks/archived-absence.js +11 -0
- package/dist/rooms-tasks/cli.js +182 -5
- package/dist/rooms-tasks/close.d.ts +5 -2
- package/dist/rooms-tasks/close.js +224 -36
- package/dist/rooms-tasks/config.d.ts +1 -1
- package/dist/rooms-tasks/config.js +11 -4
- package/dist/rooms-tasks/cowork-adapter.d.ts +12 -5
- package/dist/rooms-tasks/cowork-adapter.js +15 -121
- package/dist/rooms-tasks/cowork-http.js +56 -6
- package/dist/rooms-tasks/deletion.d.ts +1 -1
- package/dist/rooms-tasks/deletion.js +66 -10
- package/dist/rooms-tasks/erasure.d.ts +6 -0
- package/dist/rooms-tasks/erasure.js +173 -0
- package/dist/rooms-tasks/external-worker.d.ts +1 -1
- package/dist/rooms-tasks/external-worker.js +3 -4
- package/dist/rooms-tasks/layout-binding-client.d.ts +11 -0
- package/dist/rooms-tasks/layout-binding-client.js +56 -0
- package/dist/rooms-tasks/layout-binding-grants.d.ts +21 -0
- package/dist/rooms-tasks/layout-binding-grants.js +128 -0
- package/dist/rooms-tasks/layout-cli.d.ts +4 -0
- package/dist/rooms-tasks/layout-cli.js +107 -0
- package/dist/rooms-tasks/layout-config.d.ts +11 -0
- package/dist/rooms-tasks/layout-config.js +89 -0
- package/dist/rooms-tasks/layout-control.d.ts +21 -0
- package/dist/rooms-tasks/layout-control.js +52 -0
- package/dist/rooms-tasks/layout-member-retirement.d.ts +10 -0
- package/dist/rooms-tasks/layout-member-retirement.js +90 -0
- package/dist/rooms-tasks/layout-service.d.ts +43 -0
- package/dist/rooms-tasks/layout-service.js +203 -0
- package/dist/rooms-tasks/layout.d.ts +121 -0
- package/dist/rooms-tasks/layout.js +286 -0
- package/dist/rooms-tasks/legacy-task-member.d.ts +19 -0
- package/dist/rooms-tasks/legacy-task-member.js +116 -0
- package/dist/rooms-tasks/live-readiness.d.ts +18 -0
- package/dist/rooms-tasks/live-readiness.js +85 -0
- package/dist/rooms-tasks/member-ownership.d.ts +5 -0
- package/dist/rooms-tasks/member-ownership.js +40 -0
- package/dist/rooms-tasks/member-startup.d.ts +1 -0
- package/dist/rooms-tasks/member-startup.js +2 -0
- package/dist/rooms-tasks/provision.d.ts +3 -0
- package/dist/rooms-tasks/provision.js +101 -49
- package/dist/rooms-tasks/recovery.d.ts +19 -0
- package/dist/rooms-tasks/recovery.js +110 -0
- package/dist/rooms-tasks/room-state.d.ts +4 -2
- package/dist/rooms-tasks/room-state.js +47 -8
- package/dist/rooms-tasks/task-review.d.ts +113 -0
- package/dist/rooms-tasks/task-review.js +561 -0
- package/dist/rooms-tasks/task-service-retirement.d.ts +11 -0
- package/dist/rooms-tasks/task-service-retirement.js +21 -0
- package/dist/rooms-tasks/task-state.d.ts +51 -5
- package/dist/rooms-tasks/task-state.js +358 -50
- package/dist/rooms-tasks/task-tools.d.ts +35 -0
- package/dist/rooms-tasks/task-tools.js +134 -0
- package/dist/rooms-tasks/types.d.ts +78 -0
- package/dist/rooms-tasks/workspace-artifacts.d.ts +6 -0
- package/dist/rooms-tasks/workspace-artifacts.js +93 -0
- package/dist/rooms-tasks/workspace.d.ts +35 -0
- package/dist/rooms-tasks/workspace.js +325 -0
- package/dist/runner.d.ts +33 -4
- package/dist/runner.js +410 -62
- package/dist/session/acp.d.ts +75 -2
- package/dist/session/acp.js +345 -82
- package/dist/session/arbiter.d.ts +98 -0
- package/dist/session/arbiter.js +272 -3
- package/dist/session/codex-app-server.d.ts +45 -1
- package/dist/session/codex-app-server.js +225 -32
- package/dist/session/control.d.ts +17 -3
- package/dist/session/control.js +219 -23
- package/dist/session/conversation-normalizer.d.ts +2 -1
- package/dist/session/conversation-normalizer.js +1 -1
- package/dist/session/conversation-observation.d.ts +25 -0
- package/dist/session/conversation-observation.js +100 -0
- package/dist/session/conversation-replay.d.ts +50 -0
- package/dist/session/conversation-replay.js +203 -0
- package/dist/session/conversation-store.d.ts +15 -1
- package/dist/session/conversation-store.js +213 -26
- package/dist/session/conversation-types.d.ts +57 -4
- package/dist/session/prompt-batch.d.ts +79 -0
- package/dist/session/prompt-batch.js +120 -0
- package/dist/session/task-notice.d.ts +14 -0
- package/dist/session/task-notice.js +13 -0
- package/dist/session/types.d.ts +42 -1
- package/dist/setup-tunnel-preflight.d.ts +34 -0
- package/dist/setup-tunnel-preflight.js +62 -0
- package/dist/socket-path.d.ts +2 -0
- package/dist/socket-path.js +22 -0
- package/dist/spawn.d.ts +5 -1
- package/dist/spawn.js +40 -4
- package/dist/startup-prompt.d.ts +15 -0
- package/dist/startup-prompt.js +71 -0
- package/dist/startup-readiness.d.ts +32 -0
- package/dist/startup-readiness.js +101 -0
- package/dist/startup-telemetry.d.ts +16 -0
- package/dist/startup-telemetry.js +46 -0
- package/dist/subscriptions/cli.d.ts +91 -0
- package/dist/subscriptions/cli.js +223 -0
- package/dist/subscriptions/launch.d.ts +37 -0
- package/dist/subscriptions/launch.js +93 -0
- package/dist/subscriptions/login.d.ts +77 -0
- package/dist/subscriptions/login.js +215 -0
- package/dist/subscriptions/observed.d.ts +7 -0
- package/dist/subscriptions/observed.js +44 -0
- package/dist/subscriptions/probe.d.ts +10 -0
- package/dist/subscriptions/probe.js +73 -0
- package/dist/subscriptions/service.d.ts +102 -0
- package/dist/subscriptions/service.js +364 -0
- package/dist/subscriptions/store.d.ts +71 -0
- package/dist/subscriptions/store.js +143 -0
- package/dist/supervisor/adoption.d.ts +8 -0
- package/dist/supervisor/adoption.js +78 -0
- package/dist/supervisor/catalog.d.ts +62 -0
- package/dist/supervisor/catalog.js +254 -0
- package/dist/supervisor/fleet.d.ts +8 -0
- package/dist/supervisor/fleet.js +89 -0
- package/dist/supervisor/index.js +3 -6
- package/dist/supervisor/launchd.d.ts +1 -1
- package/dist/supervisor/launchd.js +26 -13
- package/dist/supervisor/legacy.d.ts +35 -0
- package/dist/supervisor/legacy.js +524 -0
- package/dist/supervisor/manager.d.ts +15 -0
- package/dist/supervisor/manager.js +270 -0
- package/dist/supervisor/registration-refresh.d.ts +45 -0
- package/dist/supervisor/registration-refresh.js +266 -0
- package/dist/supervisor/scope.d.ts +4 -0
- package/dist/supervisor/scope.js +10 -0
- package/dist/supervisor/systemd.d.ts +2 -2
- package/dist/supervisor/systemd.js +19 -33
- package/dist/task-supervision.d.ts +9 -0
- package/dist/task-supervision.js +145 -0
- package/dist/temp-idle.d.ts +17 -0
- package/dist/temp-idle.js +42 -0
- package/dist/temp-lifecycle.d.ts +23 -8
- package/dist/temp-lifecycle.js +123 -66
- package/dist/temp-supervisor-recovery.d.ts +1 -1
- package/dist/temp-supervisor-recovery.js +2 -2
- package/dist/tunnel-setup-completion.d.ts +7 -0
- package/dist/tunnel-setup-completion.js +13 -0
- package/dist/tunnel-setup-input.d.ts +19 -0
- package/dist/tunnel-setup-input.js +130 -0
- package/dist/watchdog/query.d.ts +3 -1
- package/dist/watchdog/query.js +2 -1
- package/dist/web/agent-attachments.d.ts +29 -0
- package/dist/web/agent-attachments.js +162 -0
- package/dist/web/auth.d.ts +65 -2
- package/dist/web/auth.js +201 -11
- package/dist/web/available-port.d.ts +2 -0
- package/dist/web/available-port.js +23 -0
- package/dist/web/control.d.ts +3 -3
- package/dist/web/control.js +10 -8
- package/dist/web/conversation-stream-codec.d.ts +23 -0
- package/dist/web/conversation-stream-codec.js +110 -0
- package/dist/web/conversation-stream.d.ts +26 -0
- package/dist/web/conversation-stream.js +239 -0
- package/dist/web/events.d.ts +2 -0
- package/dist/web/events.js +9 -0
- package/dist/web/fleet-config-service.d.ts +7 -1
- package/dist/web/fleet-config-service.js +61 -16
- package/dist/web/prefix-gateway.d.ts +32 -0
- package/dist/web/prefix-gateway.js +248 -0
- package/dist/web/resource-views.d.ts +135 -0
- package/dist/web/resource-views.js +494 -0
- package/dist/web/runtime.d.ts +3 -1
- package/dist/web/runtime.js +132 -34
- package/dist/web/server.d.ts +19 -0
- package/dist/web/server.js +893 -71
- package/dist/web/service.d.ts +11 -2
- package/dist/web/service.js +30 -4
- package/dist/web/workspace-devices.d.ts +107 -0
- package/dist/web/workspace-devices.js +277 -0
- package/dist/web/workspace-tunnel.d.ts +1 -0
- package/dist/web/workspace-tunnel.js +34 -0
- package/dist/workspace-enrollment.d.ts +83 -0
- package/dist/workspace-enrollment.js +605 -0
- package/dist/workspace-replacement.d.ts +66 -0
- package/dist/workspace-replacement.js +238 -0
- package/docs/acp-files.md +146 -0
- package/docs/conversation-stream.md +216 -0
- package/docs/fleet-migration.md +54 -0
- package/docs/live-voice.md +13 -0
- package/docs/room-layouts.md +227 -0
- package/docs/self-reminders.md +374 -0
- package/docs/task-progress-review.md +143 -0
- package/docs/task-workspaces.md +225 -0
- package/docs/validation/managed-cli-permissions.md +421 -0
- package/examples/room-layouts/fresh.yaml +27 -0
- package/examples/room-layouts/scoped.yaml +21 -0
- package/examples/room-layouts/shared.yaml +19 -0
- package/package.json +25 -20
- package/presets/README.md +78 -0
- package/presets/brain-catalog.json +8 -2
- package/presets/fleet/agent_templates/Critic.yaml +1 -1
- package/presets/fleet/agent_templates/Developer.yaml +1 -1
- package/presets/fleet/agent_templates/Engineer.yaml +5 -0
- package/presets/fleet/agent_templates/LocalCoordinator.yaml +6 -3
- package/presets/fleet/agents/FleetCoordinator.yaml +1 -1
- package/presets/fleet/brains/claude-fable-5-1-high.yaml +5 -0
- package/presets/fleet/brains/claude-fable-5-1-low.yaml +5 -0
- package/presets/fleet/brains/claude-fable-5-1-max.yaml +5 -0
- package/presets/fleet/brains/claude-fable-5-1-medium.yaml +5 -0
- package/presets/fleet/brains/claude-fable-5-1-xhigh.yaml +5 -0
- package/presets/fleet/brains/claude-fable-5-high.yaml +1 -1
- package/presets/fleet/brains/claude-fable-5-low.yaml +1 -1
- package/presets/fleet/brains/claude-fable-5-max.yaml +1 -1
- package/presets/fleet/brains/claude-fable-5-medium.yaml +1 -1
- package/presets/fleet/brains/claude-fable-5-xhigh.yaml +1 -1
- package/presets/fleet/brains/claude-haiku-4-5-20251001-default.yaml +4 -0
- package/presets/fleet/brains/claude-opus-5-5-high.yaml +5 -0
- package/presets/fleet/brains/claude-opus-5-5-low.yaml +5 -0
- package/presets/fleet/brains/claude-opus-5-5-max.yaml +5 -0
- package/presets/fleet/brains/claude-opus-5-5-medium.yaml +5 -0
- package/presets/fleet/brains/claude-opus-5-5-xhigh.yaml +5 -0
- package/presets/fleet/brains/claude-opus-5-high.yaml +1 -1
- package/presets/fleet/brains/claude-opus-5-low.yaml +1 -1
- package/presets/fleet/brains/claude-opus-5-max.yaml +1 -1
- package/presets/fleet/brains/claude-opus-5-medium.yaml +1 -1
- package/presets/fleet/brains/claude-opus-5-xhigh.yaml +1 -1
- package/presets/fleet/brains/claude-sonnet-5-high.yaml +1 -1
- package/presets/fleet/brains/claude-sonnet-5-low.yaml +1 -1
- package/presets/fleet/brains/claude-sonnet-5-max.yaml +1 -1
- package/presets/fleet/brains/claude-sonnet-5-medium.yaml +1 -1
- package/presets/fleet/brains/claude-sonnet-5-xhigh.yaml +1 -1
- package/presets/fleet/brains/codex-gpt-5-3-codex-spark-high.yaml +1 -1
- package/presets/fleet/brains/codex-gpt-5-3-codex-spark-low.yaml +1 -1
- package/presets/fleet/brains/codex-gpt-5-3-codex-spark-medium.yaml +1 -1
- package/presets/fleet/brains/codex-gpt-5-3-codex-spark-xhigh.yaml +1 -1
- package/presets/fleet/brains/codex-gpt-5-4-high.yaml +1 -1
- package/presets/fleet/brains/codex-gpt-5-4-low.yaml +1 -1
- package/presets/fleet/brains/codex-gpt-5-4-medium.yaml +1 -1
- package/presets/fleet/brains/codex-gpt-5-4-mini-high.yaml +1 -1
- package/presets/fleet/brains/codex-gpt-5-4-mini-low.yaml +1 -1
- package/presets/fleet/brains/codex-gpt-5-4-mini-medium.yaml +1 -1
- package/presets/fleet/brains/codex-gpt-5-4-mini-xhigh.yaml +1 -1
- package/presets/fleet/brains/codex-gpt-5-4-xhigh.yaml +1 -1
- package/presets/fleet/brains/codex-gpt-5-5-high.yaml +1 -1
- package/presets/fleet/brains/codex-gpt-5-5-low.yaml +1 -1
- package/presets/fleet/brains/codex-gpt-5-5-medium.yaml +1 -1
- package/presets/fleet/brains/codex-gpt-5-5-xhigh.yaml +1 -1
- package/presets/fleet/brains/codex-gpt-5-6-luna-high.yaml +1 -1
- package/presets/fleet/brains/codex-gpt-5-6-luna-low.yaml +1 -1
- package/presets/fleet/brains/codex-gpt-5-6-luna-max.yaml +1 -1
- package/presets/fleet/brains/codex-gpt-5-6-luna-medium.yaml +1 -1
- package/presets/fleet/brains/codex-gpt-5-6-luna-xhigh.yaml +1 -1
- package/presets/fleet/brains/codex-gpt-5-6-sol-high.yaml +1 -1
- package/presets/fleet/brains/codex-gpt-5-6-sol-low.yaml +1 -1
- package/presets/fleet/brains/codex-gpt-5-6-sol-max.yaml +1 -1
- package/presets/fleet/brains/codex-gpt-5-6-sol-medium.yaml +1 -1
- package/presets/fleet/brains/codex-gpt-5-6-sol-ultra.yaml +1 -1
- package/presets/fleet/brains/codex-gpt-5-6-sol-xhigh.yaml +1 -1
- package/presets/fleet/brains/codex-gpt-5-6-terra-high.yaml +1 -1
- package/presets/fleet/brains/codex-gpt-5-6-terra-low.yaml +1 -1
- package/presets/fleet/brains/codex-gpt-5-6-terra-max.yaml +1 -1
- package/presets/fleet/brains/codex-gpt-5-6-terra-medium.yaml +1 -1
- package/presets/fleet/brains/codex-gpt-5-6-terra-ultra.yaml +1 -1
- package/presets/fleet/brains/codex-gpt-5-6-terra-xhigh.yaml +1 -1
- package/presets/fleet/brains/codex-gpt-6-1-sol-high.yaml +5 -0
- package/presets/fleet/brains/codex-gpt-6-1-sol-low.yaml +5 -0
- package/presets/fleet/brains/codex-gpt-6-1-sol-max.yaml +5 -0
- package/presets/fleet/brains/codex-gpt-6-1-sol-medium.yaml +5 -0
- package/presets/fleet/brains/codex-gpt-6-1-sol-ultra.yaml +5 -0
- package/presets/fleet/brains/codex-gpt-6-1-sol-xhigh.yaml +5 -0
- package/presets/fleet/brains/codex-gpt-6-astra-high.yaml +1 -1
- package/presets/fleet/brains/codex-gpt-6-astra-low.yaml +1 -1
- package/presets/fleet/brains/codex-gpt-6-astra-max.yaml +1 -1
- package/presets/fleet/brains/codex-gpt-6-astra-medium.yaml +1 -1
- package/presets/fleet/brains/codex-gpt-6-astra-ultra.yaml +1 -1
- package/presets/fleet/brains/codex-gpt-6-astra-xhigh.yaml +1 -1
- package/presets/fleet/brains/codex-gpt-6-luna-high.yaml +5 -0
- package/presets/fleet/brains/codex-gpt-6-luna-low.yaml +5 -0
- package/presets/fleet/brains/codex-gpt-6-luna-max.yaml +5 -0
- package/presets/fleet/brains/codex-gpt-6-luna-medium.yaml +5 -0
- package/presets/fleet/brains/codex-gpt-6-luna-xhigh.yaml +5 -0
- package/presets/fleet/brains/codex-gpt-6-sol-high.yaml +5 -0
- package/presets/fleet/brains/codex-gpt-6-sol-low.yaml +5 -0
- package/presets/fleet/brains/codex-gpt-6-sol-max.yaml +5 -0
- package/presets/fleet/brains/codex-gpt-6-sol-medium.yaml +5 -0
- package/presets/fleet/brains/codex-gpt-6-sol-ultra.yaml +5 -0
- package/presets/fleet/brains/codex-gpt-6-sol-xhigh.yaml +5 -0
- package/presets/fleet/roles/Coordinator.yaml +21 -13
- package/presets/fleet/roles/Critic.yaml +24 -0
- package/presets/fleet/roles/Developer.yaml +32 -0
- package/presets/fleet/roles/Engineer.yaml +72 -0
- package/presets/fleet/roles/LocalCoordinator.yaml +17 -0
- package/presets/fleet/room_layouts/engineering.yaml +25 -0
- package/presets/fleet/room_layouts/pair.yaml +24 -0
- package/presets/fleet/room_layouts/single.yaml +17 -0
- package/presets/fleet/room_layouts/team.yaml +30 -0
- package/presets/fleet/room_templates/engineering.yaml +19 -0
- package/presets/manifest.json +2 -2
- package/dist/web-app/assets/index-59GF-gsZ.css +0 -1
- package/dist/web-app/assets/index-C0h3ALvs.js +0 -10
- package/dist/web-app/icons/ours-fleet-maskable.svg +0 -4
- package/dist/web-app/icons/ours-fleet.svg +0 -4
- package/dist/web-app/index.html +0 -17
- package/dist/web-app/manifest.webmanifest +0 -15
- package/dist/web-app/offline.html +0 -18
- package/dist/web-app/sw.js +0 -51
|
@@ -300,9 +300,9 @@ function sandboxMode(policy) {
|
|
|
300
300
|
* Fleet keeps the preset's sandbox policy, but restores the independently
|
|
301
301
|
* configured approval policy on the request Codex actually executes.
|
|
302
302
|
*/
|
|
303
|
-
function rewriteMessage(value, approval, expectedSandbox, disableInheritedMcp) {
|
|
303
|
+
function rewriteMessage(value, approval, expectedSandbox, disableInheritedMcp, managedOursTools) {
|
|
304
304
|
if (Array.isArray(value))
|
|
305
|
-
return value.map(candidate => rewriteMessage(candidate, approval, expectedSandbox, disableInheritedMcp));
|
|
305
|
+
return value.map(candidate => rewriteMessage(candidate, approval, expectedSandbox, disableInheritedMcp, managedOursTools));
|
|
306
306
|
if (!isObject(value) || !isObject(value.params))
|
|
307
307
|
return value;
|
|
308
308
|
if (value.method === 'turn/start') {
|
|
@@ -318,17 +318,52 @@ function rewriteMessage(value, approval, expectedSandbox, disableInheritedMcp) {
|
|
|
318
318
|
params: { ...value.params, config: { ...config, mcp_servers: {} } },
|
|
319
319
|
};
|
|
320
320
|
}
|
|
321
|
+
if (managedOursTools
|
|
322
|
+
&& (value.method === 'thread/start' || value.method === 'thread/resume')) {
|
|
323
|
+
const config = isObject(value.params.config) ? value.params.config : {};
|
|
324
|
+
const servers = isObject(config.mcp_servers) ? config.mcp_servers : {};
|
|
325
|
+
const ours = servers.ours;
|
|
326
|
+
// Policy cannot create or re-enable a connector that ACP did not inject.
|
|
327
|
+
if (!isObject(ours) || ours.enabled === false)
|
|
328
|
+
return value;
|
|
329
|
+
const tools = isObject(ours.tools) ? { ...ours.tools } : {};
|
|
330
|
+
for (const [name, policy] of Object.entries(managedOursTools)) {
|
|
331
|
+
if (isObject(policy))
|
|
332
|
+
tools[name] = {
|
|
333
|
+
...(isObject(tools[name]) ? tools[name] : {}), ...policy,
|
|
334
|
+
};
|
|
335
|
+
}
|
|
336
|
+
return { ...value, params: { ...value.params, config: { ...config,
|
|
337
|
+
mcp_servers: { ...servers, ours: { ...ours, tools } },
|
|
338
|
+
} } };
|
|
339
|
+
}
|
|
321
340
|
return value;
|
|
322
341
|
}
|
|
323
342
|
/** Transform one app-server NDJSON request; malformed input passes through. */
|
|
324
|
-
export function rewriteCodexAppServerRequest(line, approval, expectedSandbox, disableInheritedMcp = false) {
|
|
343
|
+
export function rewriteCodexAppServerRequest(line, approval, expectedSandbox, disableInheritedMcp = false, managedOursTools) {
|
|
325
344
|
try {
|
|
326
|
-
return JSON.stringify(rewriteMessage(JSON.parse(line), approval, expectedSandbox, disableInheritedMcp));
|
|
345
|
+
return JSON.stringify(rewriteMessage(JSON.parse(line), approval, expectedSandbox, disableInheritedMcp, managedOursTools));
|
|
327
346
|
}
|
|
328
347
|
catch {
|
|
329
348
|
return line;
|
|
330
349
|
}
|
|
331
350
|
}
|
|
351
|
+
/** ACP only carries transport fields; read policy from Fleet's complete config. */
|
|
352
|
+
export function managedCodexToolPolicy(env) {
|
|
353
|
+
if (env.FLEET_OURS_MANAGED !== '1')
|
|
354
|
+
return undefined;
|
|
355
|
+
try {
|
|
356
|
+
const config = JSON.parse(env.CODEX_CONFIG ?? '{}');
|
|
357
|
+
const servers = isObject(config) ? config.mcp_servers : undefined;
|
|
358
|
+
const ours = isObject(servers) ? servers.ours : undefined;
|
|
359
|
+
return isObject(ours) && ours.enabled !== false && isObject(ours.tools)
|
|
360
|
+
? ours.tools : undefined;
|
|
361
|
+
}
|
|
362
|
+
catch {
|
|
363
|
+
// Invalid config never grants tool approval. ACP owns config diagnostics.
|
|
364
|
+
return undefined;
|
|
365
|
+
}
|
|
366
|
+
}
|
|
332
367
|
function requiredChoice(name, allowed) {
|
|
333
368
|
const value = process.env[name];
|
|
334
369
|
if (value && allowed.has(value))
|
|
@@ -355,6 +390,7 @@ export function runCodexAppServerProxy() {
|
|
|
355
390
|
const approval = requiredChoice(APPROVAL_ENV, APPROVAL_POLICIES);
|
|
356
391
|
const expectedSandbox = requiredChoice(SANDBOX_ENV, SANDBOX_MODES);
|
|
357
392
|
const disableInheritedMcp = process.env[DISABLE_INHERITED_MCP_ENV] === '1';
|
|
393
|
+
const managedOursTools = managedCodexToolPolicy(process.env);
|
|
358
394
|
const launch = realCodexLaunch();
|
|
359
395
|
const env = { ...process.env };
|
|
360
396
|
delete env.CODEX_PATH;
|
|
@@ -450,7 +486,7 @@ export function runCodexAppServerProxy() {
|
|
|
450
486
|
input.on('line', line => {
|
|
451
487
|
if (finished)
|
|
452
488
|
return;
|
|
453
|
-
const rewritten = rewriteCodexAppServerRequest(line, approval, expectedSandbox, disableInheritedMcp);
|
|
489
|
+
const rewritten = rewriteCodexAppServerRequest(line, approval, expectedSandbox, disableInheritedMcp, managedOursTools);
|
|
454
490
|
recovery.observeClientLine(rewritten);
|
|
455
491
|
writeToChild(rewritten);
|
|
456
492
|
});
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
/** Efforts supported by Fleet's Codex Brain contract. Keep native eligibility in sync. */
|
|
2
|
+
export declare const CODEX_REASONING_EFFORTS: readonly ["low", "medium", "high", "xhigh", "max", "ultra"];
|
|
3
|
+
export declare function isCodexReasoningEffort(value: unknown): value is string;
|
|
4
|
+
/** Only inspected model tuning may bypass the managed CLI native-config guard. */
|
|
5
|
+
export declare function isManagedCliCodexConfig(config: unknown): boolean;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
/** Efforts supported by Fleet's Codex Brain contract. Keep native eligibility in sync. */
|
|
2
|
+
export const CODEX_REASONING_EFFORTS = ['low', 'medium', 'high', 'xhigh', 'max', 'ultra'];
|
|
3
|
+
export function isCodexReasoningEffort(value) {
|
|
4
|
+
return typeof value === 'string' && CODEX_REASONING_EFFORTS.includes(value);
|
|
5
|
+
}
|
|
6
|
+
/** Only inspected model tuning may bypass the managed CLI native-config guard. */
|
|
7
|
+
export function isManagedCliCodexConfig(config) {
|
|
8
|
+
if (config == null)
|
|
9
|
+
return true;
|
|
10
|
+
return typeof config === 'object' && !Array.isArray(config)
|
|
11
|
+
&& Object.entries(config).every(([key, value]) => key === 'model_reasoning_effort' && isCodexReasoningEffort(value));
|
|
12
|
+
}
|
|
@@ -4,8 +4,18 @@ export declare const VERIFIED_CODEX_ACP_VERSIONS: Set<string>;
|
|
|
4
4
|
export declare function executableOnPath(command: string, env: NodeJS.ProcessEnv, cwd?: string): string;
|
|
5
5
|
/** Match the npm Codex wrapper's platform-package/vendor selection. */
|
|
6
6
|
export declare function codexExecutable(entry: string): string;
|
|
7
|
+
/**
|
|
8
|
+
* The host's own Codex, when ACP sessions should run it instead of the copy bundled with the adapter.
|
|
9
|
+
* The person signs in to, updates and checks the host Codex, and a newer Codex knows models the bundled
|
|
10
|
+
* one does not. It is used only when it is at least as new as the bundled copy; an explicit CODEX_PATH
|
|
11
|
+
* (including an empty one, which selects the bundled copy) always decides instead.
|
|
12
|
+
*/
|
|
13
|
+
export declare function hostCodex(adapterManifest: string | undefined, env: NodeJS.ProcessEnv, cwd?: string, version?: (path: string, env: NodeJS.ProcessEnv) => string | undefined): {
|
|
14
|
+
path: string;
|
|
15
|
+
version: string;
|
|
16
|
+
} | undefined;
|
|
7
17
|
export interface CodexRuntime {
|
|
8
|
-
source: 'CODEX_PATH' | 'bundled';
|
|
18
|
+
source: 'CODEX_PATH' | 'host' | 'bundled';
|
|
9
19
|
entry: string;
|
|
10
20
|
executable: string;
|
|
11
21
|
version: string;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { createRequire } from 'node:module';
|
|
2
|
-
import {
|
|
2
|
+
import { spawnSync } from 'node:child_process';
|
|
3
|
+
import { accessSync, constants, existsSync, readFileSync, realpathSync } from 'node:fs';
|
|
3
4
|
import { dirname, join, isAbsolute, resolve, delimiter } from 'node:path';
|
|
4
5
|
import { realExec } from '../exec.js';
|
|
5
6
|
export const VERIFIED_CODEX_ACP_VERSIONS = new Set(['1.1.7', '1.10.0']);
|
|
@@ -46,18 +47,44 @@ export function codexExecutable(entry) {
|
|
|
46
47
|
}
|
|
47
48
|
throw new Error(`Codex platform binary missing under ${vendor}; reinstall Fleet with optional dependencies`);
|
|
48
49
|
}
|
|
50
|
+
const versionOf = (text) => text.match(/\b(\d+\.\d+\.\d+)\b/)?.[1];
|
|
51
|
+
function installedCodexVersion(path, env) {
|
|
52
|
+
const result = spawnSync(path, ['--version'], { env, encoding: 'utf8', timeout: 5_000, stdio: ['ignore', 'pipe', 'ignore'] });
|
|
53
|
+
return result.status === 0 ? versionOf(result.stdout ?? '') : undefined;
|
|
54
|
+
}
|
|
55
|
+
/**
|
|
56
|
+
* The host's own Codex, when ACP sessions should run it instead of the copy bundled with the adapter.
|
|
57
|
+
* The person signs in to, updates and checks the host Codex, and a newer Codex knows models the bundled
|
|
58
|
+
* one does not. It is used only when it is at least as new as the bundled copy; an explicit CODEX_PATH
|
|
59
|
+
* (including an empty one, which selects the bundled copy) always decides instead.
|
|
60
|
+
*/
|
|
61
|
+
export function hostCodex(adapterManifest, env, cwd = process.cwd(), version = installedCodexVersion) {
|
|
62
|
+
if (env.CODEX_PATH !== undefined || !adapterManifest)
|
|
63
|
+
return undefined;
|
|
64
|
+
let path, bundled;
|
|
65
|
+
try {
|
|
66
|
+
path = executableOnPath('codex', env, cwd);
|
|
67
|
+
bundled = JSON.parse(readFileSync(createRequire(adapterManifest).resolve('@openai/codex/package.json'), 'utf8')).version;
|
|
68
|
+
}
|
|
69
|
+
catch {
|
|
70
|
+
return undefined;
|
|
71
|
+
}
|
|
72
|
+
const found = version(path, env);
|
|
73
|
+
return found && typeof bundled === 'string' && codexVersionAtLeast(found, bundled) ? { path, version: found } : undefined;
|
|
74
|
+
}
|
|
49
75
|
export async function probeCodexRuntime(adapter, env, exec = realExec, cwd = process.cwd()) {
|
|
50
|
-
const
|
|
76
|
+
const host = hostCodex(adapter.manifestPath, env, cwd);
|
|
77
|
+
const configured = env.CODEX_PATH || host?.path;
|
|
51
78
|
if (!configured && !adapter.manifestPath)
|
|
52
79
|
throw new Error('ACP runtime is unknown for a PATH/custom adapter; set CODEX_PATH to an absolute executable or use the bundled adapter');
|
|
53
80
|
const entry = configured ? executableOnPath(configured, env, cwd)
|
|
54
81
|
: createRequire(adapter.manifestPath).resolve('@openai/codex/bin/codex.js');
|
|
55
82
|
const executable = codexExecutable(entry);
|
|
56
83
|
const result = await exec(!configured ? process.execPath : entry, !configured ? [entry, '--version'] : ['--version'], { env, timeout: 5_000 });
|
|
57
|
-
const version = result.stdout
|
|
84
|
+
const version = versionOf(result.stdout);
|
|
58
85
|
if (result.code !== 0 || !version)
|
|
59
86
|
throw new Error(`Cannot read Codex version from ${entry}; check CODEX_PATH and executable permissions`);
|
|
60
|
-
return { source: configured ? 'CODEX_PATH' : 'bundled', entry, executable, version };
|
|
87
|
+
return { source: host ? 'host' : configured ? 'CODEX_PATH' : 'bundled', entry, executable, version };
|
|
61
88
|
}
|
|
62
89
|
export function codexVersionAtLeast(version, minimum) {
|
|
63
90
|
const actual = version.split('.').map(Number);
|
|
@@ -32,7 +32,7 @@ export class CodexAgentSessionAdapter {
|
|
|
32
32
|
if (role.session === 'codex-app-server')
|
|
33
33
|
return this.nativeTransport({
|
|
34
34
|
name: role.name, argv: launch.argv, cwd: options.cwd, env: launch.env,
|
|
35
|
-
stateDir: options.stateDir, mode: options.mode, permissions: options.permissions,
|
|
35
|
+
stateDir: options.stateDir, mode: options.mode, requireResume: options.requireResume, deferRecoveredPrompts: options.deferRecoveredPrompts, permissions: options.permissions,
|
|
36
36
|
permissionMode: options.permissionMode,
|
|
37
37
|
model: role.model, effort: role.effort,
|
|
38
38
|
approvalPolicy: this.strategy.approvalPolicy(role),
|
|
@@ -44,7 +44,7 @@ export class CodexAgentSessionAdapter {
|
|
|
44
44
|
return this.transport({
|
|
45
45
|
name: role.name, harness: role.harness,
|
|
46
46
|
argv: launch.argv, cwd: options.cwd, env: launch.env,
|
|
47
|
-
stateDir: options.stateDir, mode: options.mode, permissions: options.permissions,
|
|
47
|
+
stateDir: options.stateDir, mode: options.mode, requireResume: options.requireResume, deferRecoveredPrompts: options.deferRecoveredPrompts, permissions: options.permissions,
|
|
48
48
|
modeId: this.strategy.permissionModeId(role),
|
|
49
49
|
mcpServers: options.managedOurs ? [...(this.strategy.mcpServers(role) ?? []).filter(s => s.name !== 'ours'), options.managedOurs.server] : this.strategy.mcpServers(role),
|
|
50
50
|
inheritEnvironment: options.managedOurs ? false : undefined,
|
package/dist/harness/codex.js
CHANGED
|
@@ -6,8 +6,9 @@ import { realExec } from '../exec.js';
|
|
|
6
6
|
import { registerAdapter } from './registry.js';
|
|
7
7
|
import { harnessRuntimeDir } from '../isolation/policy.js';
|
|
8
8
|
import { resolveBundledAcpAgent, } from './acp-agent.js';
|
|
9
|
-
import { VERIFIED_CODEX_ACP_VERSIONS, probeCodexRuntime, codexVersionAtLeast } from './codex-runtime.js';
|
|
9
|
+
import { VERIFIED_CODEX_ACP_VERSIONS, probeCodexRuntime, codexVersionAtLeast, hostCodex } from './codex-runtime.js';
|
|
10
10
|
import { CodexAgentSessionAdapter } from './codex-session.js';
|
|
11
|
+
import { CODEX_REASONING_EFFORTS, isCodexReasoningEffort } from './codex-reasoning.js';
|
|
11
12
|
const OPTION_KEYS = [
|
|
12
13
|
'launcher', 'sandbox', 'approval', 'permission_mode', 'search', 'profile', 'config', 'add_dirs',
|
|
13
14
|
'monitor',
|
|
@@ -141,6 +142,13 @@ function neutralSandboxMode(role) {
|
|
|
141
142
|
function isNativeConfigKeyAllowed(key) {
|
|
142
143
|
return NATIVE_CONFIG_ALLOWLIST.has(key);
|
|
143
144
|
}
|
|
145
|
+
/** Brain wins; a validated native effort also needs delivery through ACP's selection API. */
|
|
146
|
+
function reasoningEffort(role) {
|
|
147
|
+
if (typeof role.effort === 'string')
|
|
148
|
+
return role.effort;
|
|
149
|
+
const value = role.harness_options?.config?.model_reasoning_effort;
|
|
150
|
+
return isCodexReasoningEffort(value) ? value : undefined;
|
|
151
|
+
}
|
|
144
152
|
/** Defense in depth for callers which launch a role after validation was bypassed. */
|
|
145
153
|
export function nativeCodexConfig(role) {
|
|
146
154
|
const options = role.harness_options;
|
|
@@ -266,7 +274,9 @@ function codexAcpEnvironment(role, dirs) {
|
|
|
266
274
|
[CODEX_PROXY_APPROVAL_ENV]: approvalPolicy(role) ?? 'on-request',
|
|
267
275
|
[CODEX_PROXY_SANDBOX_ENV]: acpRuntimeSandbox(role),
|
|
268
276
|
[CODEX_PROXY_MANIFEST_ENV]: resolution.manifestPath,
|
|
269
|
-
|
|
277
|
+
// Same choice as probeCodexRuntime: an explicit CODEX_PATH, else a host Codex at least as new as the bundled one.
|
|
278
|
+
[CODEX_PROXY_REAL_PATH_ENV]: role.env?.CODEX_PATH ?? process.env.CODEX_PATH
|
|
279
|
+
?? hostCodex(resolution.manifestPath, { ...process.env, ...role.env }, dirs.runCwd)?.path ?? '',
|
|
270
280
|
};
|
|
271
281
|
}
|
|
272
282
|
function encodeTomlValue(value) {
|
|
@@ -316,10 +326,8 @@ export function makeCodexAdapter(exec = realExec, transport, nativeTransport) {
|
|
|
316
326
|
id: 'codex',
|
|
317
327
|
agentSession: new CodexAgentSessionAdapter({
|
|
318
328
|
resolveBrain(brain) {
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
&& (typeof brain.effort !== 'string' || !levels.includes(brain.effort)))
|
|
322
|
-
throw new Error(`Codex Brain effort must be one of: ${levels.join(', ')}`);
|
|
329
|
+
if (brain.effort != null && !isCodexReasoningEffort(brain.effort))
|
|
330
|
+
throw new Error(`Codex Brain effort must be one of: ${CODEX_REASONING_EFFORTS.join(', ')}`);
|
|
323
331
|
const harnessOptions = { ...(brain.harnessOptions ?? {}) };
|
|
324
332
|
if (brain.effort)
|
|
325
333
|
harnessOptions.config = {
|
|
@@ -341,8 +349,8 @@ export function makeCodexAdapter(exec = realExec, transport, nativeTransport) {
|
|
|
341
349
|
sessionConfigSelections: role => [
|
|
342
350
|
...(typeof role.model === 'string'
|
|
343
351
|
? [{ configId: 'model', value: role.model }] : []),
|
|
344
|
-
...(
|
|
345
|
-
? [{ configId: 'reasoning_effort', value: role
|
|
352
|
+
...(reasoningEffort(role)
|
|
353
|
+
? [{ configId: 'reasoning_effort', value: reasoningEffort(role) }] : []),
|
|
346
354
|
],
|
|
347
355
|
permissionModeId: role => acpAgentMode(role),
|
|
348
356
|
mcpServers: () => undefined,
|
|
@@ -613,12 +621,16 @@ export function makeCodexAdapter(exec = realExec, transport, nativeTransport) {
|
|
|
613
621
|
supervisedWakeNote: () => 'Your mail wake-ups are delivered by the fleet supervisor directly into this console as ' +
|
|
614
622
|
'`[fleet-monitor]` lines — do NOT arm arm_monitor or foreground_monitor. When such a line ' +
|
|
615
623
|
'appears, call **get_messages**, handle the mail, and reply with send_message.',
|
|
616
|
-
launchNote: name => `You were launched as the fleet role \`${name}\` under a Codex session.
|
|
624
|
+
launchNote: name => `You were launched as the fleet role \`${name}\` under a Codex session. Announce console readiness before task details.`,
|
|
617
625
|
restartPrompt: (id, worklog, configuredRole) => {
|
|
618
626
|
if (configuredRole?.monitor?.mode === 'fleet')
|
|
619
|
-
return `Session restarted.
|
|
620
|
-
'
|
|
621
|
-
`NOT arm arm_monitor/foreground_monitor.
|
|
627
|
+
return `Session restarted. The supervisor has verified assigned identity "${id}"; ` +
|
|
628
|
+
'accept that readiness and continue without rebinding or profile reconciliation. ' +
|
|
629
|
+
'Mail wakes arrive as `[fleet-monitor]` lines; do NOT arm arm_monitor/foreground_monitor. ' +
|
|
630
|
+
'Announce console readiness first without tools, then end that readiness turn. ' +
|
|
631
|
+
`For a separate continuation task, read ${worklog} once for continuity if it records previous work; ` +
|
|
632
|
+
'do not read it again later in this session. ' +
|
|
633
|
+
'Do not re-run whatever crashed you.';
|
|
622
634
|
const consented = configuredRole?.harness_options?.monitor === true;
|
|
623
635
|
return `Session restarted. Re-bind your ours identity now (choose_identity name "${id}" force=true), ` +
|
|
624
636
|
(consented
|
package/dist/init-wizard.d.ts
CHANGED
|
@@ -53,6 +53,8 @@ export declare function validateCatalog(value: BrainCatalog, path?: string): Bra
|
|
|
53
53
|
export declare function readInitSettings(path: string): InitAnswers;
|
|
54
54
|
export declare function askInitQuestions(prompter: InitPrompter, configuration: string): Promise<InitAnswers | undefined>;
|
|
55
55
|
export declare function formatSetupSummary(answers: InitAnswers, configuration: string): string;
|
|
56
|
+
/** The packaged Brain preset for a catalog model at one effort; the same naming the presets are generated with. */
|
|
57
|
+
export declare function brainPresetId(model: Pick<CatalogModel, 'harness' | 'model'>, effort: string): string;
|
|
56
58
|
/** Build the exact, deterministic default experience without writing to disk. */
|
|
57
59
|
export declare function generateSetup(answers: InitAnswers): GeneratedSetup;
|
|
58
60
|
/** Run the mutation boundary only after the complete questionnaire is accepted. */
|
package/dist/init-wizard.js
CHANGED
|
@@ -7,13 +7,19 @@ import { packagedPresetRoot } from './preset-bootstrap.js';
|
|
|
7
7
|
import { listTemplates } from './rooms-tasks/templates.js';
|
|
8
8
|
const WORK_KINDS = ['development', 'review', 'coordination'];
|
|
9
9
|
const ROLE_WORK = {
|
|
10
|
-
Developer: 'development', Critic: 'review',
|
|
10
|
+
Developer: 'development', Engineer: 'development', Critic: 'review',
|
|
11
11
|
LocalCoordinator: 'coordination', Coordinator: 'coordination', FleetCoordinator: 'coordination',
|
|
12
12
|
};
|
|
13
13
|
const REASONING_EFFORT = {
|
|
14
14
|
quick: 'low', balanced: 'medium', thorough: 'high',
|
|
15
15
|
};
|
|
16
16
|
const MODEL_LABELS = {
|
|
17
|
+
'gpt-6.1-sol': 'GPT-6.1 Sol',
|
|
18
|
+
'gpt-6-sol': 'GPT-6 Sol',
|
|
19
|
+
'gpt-6-luna': 'GPT-6 Luna',
|
|
20
|
+
'claude-fable-5-1': 'Claude Fable 5.1',
|
|
21
|
+
'claude-opus-5-5': 'Claude Opus 5.5',
|
|
22
|
+
'claude-haiku-4-5-20251001': 'Claude Haiku 4.5',
|
|
17
23
|
'gpt-6-astra': 'GPT-6 Astra',
|
|
18
24
|
'gpt-5.6-sol': 'GPT-5.6 Sol',
|
|
19
25
|
'gpt-5.6-terra': 'GPT-5.6 Terra',
|
|
@@ -33,10 +39,10 @@ export function validateCatalog(value, path = 'supported model catalog') {
|
|
|
33
39
|
for (const model of value.models) {
|
|
34
40
|
if (!['codex', 'claude-code'].includes(model.harness) || model.session !== 'acp'
|
|
35
41
|
|| typeof model.model !== 'string' || !MODEL_LABELS[model.model]
|
|
36
|
-
|| !Array.isArray(model.efforts)
|
|
42
|
+
|| !Array.isArray(model.efforts)
|
|
37
43
|
|| new Set(model.efforts).size !== model.efforts.length
|
|
38
44
|
|| model.efforts.some(effort => !['low', 'medium', 'high', 'xhigh', 'max', 'ultra'].includes(effort))
|
|
39
|
-
|| !['low', 'medium', 'high'].every(effort => model.efforts.includes(effort)))
|
|
45
|
+
|| (model.efforts.length > 0 && !['low', 'medium', 'high'].every(effort => model.efforts.includes(effort))))
|
|
40
46
|
throw new Error(`unsupported model state in ${path}`);
|
|
41
47
|
const tuple = `${model.harness}\0${model.session}\0${model.model}`;
|
|
42
48
|
if (tuples.has(tuple))
|
|
@@ -90,7 +96,9 @@ export async function askInitQuestions(prompter, configuration) {
|
|
|
90
96
|
return undefined;
|
|
91
97
|
if (subscriptions.length === 0)
|
|
92
98
|
throw new Error('Select at least one subscription.');
|
|
93
|
-
|
|
99
|
+
// The wizard assigns low/medium/high; no-effort models remain available as named presets.
|
|
100
|
+
const available = catalog().models.filter(model => subscriptions.includes(subscriptionFor(model))
|
|
101
|
+
&& model.efforts.length > 0);
|
|
94
102
|
if (!available.length)
|
|
95
103
|
throw new Error('None of the selected subscriptions has a supported model.');
|
|
96
104
|
prompter.note([
|
|
@@ -163,7 +171,9 @@ export function formatSetupSummary(answers, configuration) {
|
|
|
163
171
|
' One-agent work: one Developer',
|
|
164
172
|
' Reviewed pair: Developer + independent Critic',
|
|
165
173
|
' Team: LocalCoordinator + Developer + Critic',
|
|
174
|
+
' Gated engineering: Engineer (gate pipeline) + independent Critic',
|
|
166
175
|
' FleetCoordinator: coordination model',
|
|
176
|
+
' Brains: the packaged presets; each prepared agent references the preset of its chosen model',
|
|
167
177
|
'',
|
|
168
178
|
'After the final Yes, Fleet performs host service setup before publishing the complete configuration.',
|
|
169
179
|
'A hard termination after that Yes can leave host integration or private stage/recovery evidence to inspect.',
|
|
@@ -172,6 +182,11 @@ export function formatSetupSummary(answers, configuration) {
|
|
|
172
182
|
function preset(relative) {
|
|
173
183
|
return readFileSync(join(packagedPresetRoot(), 'fleet', relative), 'utf8');
|
|
174
184
|
}
|
|
185
|
+
/** The packaged Brain preset for a catalog model at one effort; the same naming the presets are generated with. */
|
|
186
|
+
export function brainPresetId(model, effort) {
|
|
187
|
+
return `${model.harness === 'claude-code' ? 'claude' : 'codex'}-${model.model
|
|
188
|
+
.replace(/^claude-/, '').replace(/\./g, '-').toLowerCase()}-${effort}`;
|
|
189
|
+
}
|
|
175
190
|
/** Build the exact, deterministic default experience without writing to disk. */
|
|
176
191
|
export function generateSetup(answers) {
|
|
177
192
|
const effort = REASONING_EFFORT[answers.reasoning];
|
|
@@ -192,6 +207,7 @@ export function generateSetup(answers) {
|
|
|
192
207
|
' permissions: { approval: ask, filesystem: workspace, unattended: deny }',
|
|
193
208
|
'',
|
|
194
209
|
].join('\n'));
|
|
210
|
+
const assigned = {};
|
|
195
211
|
for (const work of WORK_KINDS) {
|
|
196
212
|
const proposed = answers.models[work];
|
|
197
213
|
if (!proposed || !answers.subscriptions.includes(subscriptionFor(proposed)))
|
|
@@ -205,14 +221,14 @@ export function generateSetup(answers) {
|
|
|
205
221
|
throw new Error(`${work} contains tampered model capabilities`);
|
|
206
222
|
if (!model.efforts.includes(effort))
|
|
207
223
|
throw new Error(`${MODEL_LABELS[model.model]} does not support ${answers.reasoning} reasoning`);
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
`
|
|
212
|
-
|
|
213
|
-
'',
|
|
214
|
-
].join('\n'));
|
|
224
|
+
// The chosen model is assigned by reference to its packaged Brain preset; setup defines no Brain of its own.
|
|
225
|
+
const id = brainPresetId(model, effort);
|
|
226
|
+
if (!existsSync(join(packagedPresetRoot(), 'fleet', 'brains', `${id}.yaml`)))
|
|
227
|
+
throw new Error(`no packaged Brain preset for ${MODEL_LABELS[model.model]} at ${effort} reasoning`);
|
|
228
|
+
assigned[work] = id;
|
|
215
229
|
}
|
|
230
|
+
for (const name of readdirSync(join(packagedPresetRoot(), 'fleet', 'brains')).filter(name => name.endsWith('.yaml')).sort())
|
|
231
|
+
files.set(`brains/${name}`, preset(`brains/${name}`));
|
|
216
232
|
if (answers.assignmentStrategy === 'one-model') {
|
|
217
233
|
const tuples = new Set(WORK_KINDS.map(work => {
|
|
218
234
|
const model = answers.models[work];
|
|
@@ -221,23 +237,26 @@ export function generateSetup(answers) {
|
|
|
221
237
|
if (tuples.size !== 1)
|
|
222
238
|
throw new Error('one-model assignment requires the same exact model for development, review, and coordination');
|
|
223
239
|
}
|
|
224
|
-
for (const role of ['Coordinator', 'LocalCoordinator', 'Developer', 'Critic']) {
|
|
240
|
+
for (const role of ['Coordinator', 'LocalCoordinator', 'Developer', 'Engineer', 'Critic']) {
|
|
225
241
|
files.set(`roles/${role}.yaml`, preset(`roles/${role}.yaml`));
|
|
226
242
|
if (role === 'Coordinator')
|
|
227
243
|
continue;
|
|
228
244
|
files.set(`agent_templates/${role}.yaml`, [
|
|
229
245
|
`role: { ref: ${role} }`,
|
|
230
|
-
`brain: { ref: ${ROLE_WORK[role]} }`,
|
|
246
|
+
`brain: { ref: ${assigned[ROLE_WORK[role]]} }`,
|
|
231
247
|
'coordinator: FleetCoordinator',
|
|
232
|
-
|
|
248
|
+
// Temporary default while the product is being tested: prepared agents work without asking.
|
|
249
|
+
'permissions: { approval: allow, filesystem: unrestricted, unattended: deny }',
|
|
233
250
|
'monitor: { mode: fleet, interrupt: after_tool }',
|
|
234
251
|
'',
|
|
235
252
|
].join('\n'));
|
|
236
253
|
}
|
|
237
254
|
files.set('agents/FleetCoordinator.yaml', preset('agents/FleetCoordinator.yaml')
|
|
238
|
-
.replace('brain: { ref: claude-default }',
|
|
239
|
-
for (const name of ['single', 'pair', 'team'])
|
|
255
|
+
.replace('brain: { ref: claude-default }', `brain: { ref: ${assigned.coordination} }`));
|
|
256
|
+
for (const name of ['single', 'pair', 'team', 'engineering']) {
|
|
240
257
|
files.set(`room_templates/${name}.yaml`, preset(`room_templates/${name}.yaml`));
|
|
258
|
+
files.set(`room_layouts/${name}.yaml`, preset(`room_layouts/${name}.yaml`));
|
|
259
|
+
}
|
|
241
260
|
return { files, answers };
|
|
242
261
|
}
|
|
243
262
|
/** Run the mutation boundary only after the complete questionnaire is accepted. */
|
|
@@ -385,7 +404,7 @@ function writeStaged(stageManifest, setup) {
|
|
|
385
404
|
replaceFileAtomically(target, contents, 0o600);
|
|
386
405
|
fsyncPath(target);
|
|
387
406
|
}
|
|
388
|
-
for (const kind of ['agents', 'agent_templates', 'roles', 'brains', 'room_templates'])
|
|
407
|
+
for (const kind of ['agents', 'agent_templates', 'roles', 'brains', 'room_templates', 'room_layouts'])
|
|
389
408
|
fsyncPath(join(stageRoot, kind));
|
|
390
409
|
fsyncPath(stageRoot);
|
|
391
410
|
fsyncPath(dirname(stageManifest));
|
|
@@ -394,8 +413,8 @@ function validateStaged(stageManifest) {
|
|
|
394
413
|
const config = loadConfig(stageManifest, { yamlMode: 'strict' });
|
|
395
414
|
const templates = listTemplates(config.roomTemplates ?? {});
|
|
396
415
|
const names = new Set(templates.map(template => template.name));
|
|
397
|
-
if (!['pair', 'single', 'team'].every(name => names.has(name)))
|
|
398
|
-
throw new Error('generated setup did not resolve the default single, pair, and
|
|
416
|
+
if (!['pair', 'single', 'team', 'engineering'].every(name => names.has(name)))
|
|
417
|
+
throw new Error('generated setup did not resolve the default single, pair, team, and engineering experiences');
|
|
399
418
|
for (const template of templates)
|
|
400
419
|
for (const member of template.members)
|
|
401
420
|
if (!config.agentTemplates?.[member.agent_template])
|
package/dist/isolation/policy.js
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { stateRoot } from '../paths.js';
|
|
1
2
|
import { realpathSync } from 'node:fs';
|
|
2
3
|
import { basename, dirname, join, resolve, sep } from 'node:path';
|
|
3
4
|
import { BACKENDS, ON_UNAVAILABLE, NETWORK_MODES, } from './types.js';
|
|
@@ -57,7 +58,7 @@ const SYSTEM_RO = ['/usr', '/bin', '/sbin', '/lib', '/lib64', '/etc'];
|
|
|
57
58
|
/** Ephemeral scratch mounts. */
|
|
58
59
|
const scratchTmpfs = (home) => ['/tmp', join(home, '.cache')];
|
|
59
60
|
/** Home-relative sensitive paths never exposed (the blocklist's teeth). */
|
|
60
|
-
const SENSITIVE_HOME = ['.ssh', '.aws', '.docker', '.gnupg', '.ours', 'fleet.yaml', 'fleet.d'];
|
|
61
|
+
const SENSITIVE_HOME = ['.ssh', '.aws', '.docker', '.gnupg', '.ours', '.ours-fleet/private-ours', '.ours-fleet/private-file-delivery', 'fleet.yaml', 'fleet.d'];
|
|
61
62
|
const ISOLATION_KEYS = ['backend', 'on_unavailable', 'fs', 'network', 'allow_hosts', 'resources', 'secrets'];
|
|
62
63
|
const FS_KEYS = ['read', 'write'];
|
|
63
64
|
const RESOURCE_KEYS = ['cpu', 'mem', 'pids'];
|
|
@@ -168,6 +169,8 @@ export function resolveIsolation(cfg, ctx) {
|
|
|
168
169
|
}
|
|
169
170
|
for (const dir of ctx.additionalWriteDirs ?? [])
|
|
170
171
|
addRw(dir);
|
|
172
|
+
if (ctx.subscriptionHome)
|
|
173
|
+
addRw(ctx.subscriptionHome);
|
|
171
174
|
// The selected harness/session command may live outside the system allowlist
|
|
172
175
|
// (for example Node and a bundled ACP adapter under ~/.local). The runner
|
|
173
176
|
// resolves its exact executable/package closure; keep every such bind RO.
|
|
@@ -187,6 +190,8 @@ export function resolveIsolation(cfg, ctx) {
|
|
|
187
190
|
const agentsRoot = dirname(stateDir);
|
|
188
191
|
const blocklist = [
|
|
189
192
|
...SENSITIVE_HOME.map(p => join(home, p)),
|
|
193
|
+
join(stateRoot(), 'private-ours'),
|
|
194
|
+
join(stateRoot(), 'private-file-delivery'),
|
|
190
195
|
agentsRoot, // sibling agents' state dirs (this agent's own is explicitly mounted)
|
|
191
196
|
];
|
|
192
197
|
// ENFORCE the list, before anything builds a backend argv. Until now it was
|
|
@@ -63,6 +63,11 @@ export interface WrapContext {
|
|
|
63
63
|
* them for itself or for its peers.
|
|
64
64
|
*/
|
|
65
65
|
harnessSharedPaths?: string[];
|
|
66
|
+
/**
|
|
67
|
+
* The pinned subscription profile home (CLAUDE_CONFIG_DIR / CODEX_HOME), mounted
|
|
68
|
+
* read-write so the CLI can refresh that profile's login. Absent for the default.
|
|
69
|
+
*/
|
|
70
|
+
subscriptionHome?: string;
|
|
66
71
|
/** Exact launcher/interpreter/module closure required by the selected command. */
|
|
67
72
|
runtimeReadPaths?: string[];
|
|
68
73
|
brokerEndpoint?: string;
|