@intentic/sandbox-contract 1.430.0 → 1.432.0
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 +22 -5
- package/dist/app-routes/app-pages.d.ts +1 -0
- package/dist/app-routes/app-pages.d.ts.map +1 -1
- package/dist/app-routes/app-pages.js +1 -0
- package/dist/app-routes/app-pages.js.map +1 -1
- package/dist/app-routes/index.d.ts +1 -0
- package/dist/app-routes/index.d.ts.map +1 -1
- package/dist/app-routes/index.js +1 -0
- package/dist/app-routes/index.js.map +1 -1
- package/dist/app-routes/return-path.d.ts +2 -0
- package/dist/app-routes/return-path.d.ts.map +1 -0
- package/dist/app-routes/return-path.js +8 -0
- package/dist/app-routes/return-path.js.map +1 -0
- package/dist/briefs/agent-ask.d.ts +10 -0
- package/dist/briefs/agent-ask.d.ts.map +1 -0
- package/dist/briefs/agent-ask.js +2 -0
- package/dist/briefs/agent-ask.js.map +1 -0
- package/dist/{chores/extension-update.d.ts → briefs/extension-update-brief.d.ts} +1 -1
- package/dist/briefs/extension-update-brief.d.ts.map +1 -0
- package/dist/{chores/extension-update.js → briefs/extension-update-brief.js} +2 -2
- package/dist/briefs/extension-update-brief.js.map +1 -0
- package/dist/chores/digest.d.ts.map +1 -1
- package/dist/chores/digest.js.map +1 -1
- package/dist/chores/index.d.ts +2 -2
- package/dist/chores/index.d.ts.map +1 -1
- package/dist/chores/index.js +1 -1
- package/dist/chores/index.js.map +1 -1
- package/dist/chores/prompt.d.ts +1 -9
- package/dist/chores/prompt.d.ts.map +1 -1
- package/dist/chores/prompt.js +1 -1
- package/dist/chores/prompt.js.map +1 -1
- package/dist/chores/stack.d.ts.map +1 -1
- package/dist/chores/stack.js.map +1 -1
- package/dist/chores/verdict.d.ts.map +1 -1
- package/dist/chores/verdict.js.map +1 -1
- package/dist/chores/workspace-scope.d.ts +1 -3
- package/dist/chores/workspace-scope.d.ts.map +1 -1
- package/dist/chores/workspace-scope.js +1 -3
- package/dist/chores/workspace-scope.js.map +1 -1
- package/dist/contracts/accounts.contract.d.ts.map +1 -1
- package/dist/contracts/accounts.contract.js +2 -0
- package/dist/contracts/accounts.contract.js.map +1 -1
- package/dist/contracts/agent.contract.d.ts +1226 -12
- package/dist/contracts/agent.contract.d.ts.map +1 -1
- package/dist/contracts/agents.contract.d.ts +2665 -733
- package/dist/contracts/agents.contract.d.ts.map +1 -1
- package/dist/contracts/agents.contract.js +35 -5
- package/dist/contracts/agents.contract.js.map +1 -1
- package/dist/contracts/automations.contract.d.ts +90 -8
- package/dist/contracts/automations.contract.d.ts.map +1 -1
- package/dist/contracts/automations.contract.js +1 -0
- package/dist/contracts/automations.contract.js.map +1 -1
- package/dist/contracts/capabilities.contract.d.ts +49 -0
- package/dist/contracts/capabilities.contract.d.ts.map +1 -1
- package/dist/contracts/capabilities.contract.js +24 -1
- package/dist/contracts/capabilities.contract.js.map +1 -1
- package/dist/contracts/ci.contract.d.ts +222 -95
- package/dist/contracts/ci.contract.d.ts.map +1 -1
- package/dist/contracts/ci.contract.js +87 -26
- package/dist/contracts/ci.contract.js.map +1 -1
- package/dist/contracts/device-ci-runners.contract.d.ts +108 -0
- package/dist/contracts/device-ci-runners.contract.d.ts.map +1 -0
- package/dist/contracts/device-ci-runners.contract.js +56 -0
- package/dist/contracts/device-ci-runners.contract.js.map +1 -0
- package/dist/contracts/device-stacks.contract.d.ts +129 -0
- package/dist/contracts/device-stacks.contract.d.ts.map +1 -0
- package/dist/contracts/device-stacks.contract.js +66 -0
- package/dist/contracts/device-stacks.contract.js.map +1 -0
- package/dist/contracts/device.contract.d.ts +74 -0
- package/dist/contracts/device.contract.d.ts.map +1 -1
- package/dist/contracts/extensions.contract.d.ts +604 -0
- package/dist/contracts/extensions.contract.d.ts.map +1 -1
- package/dist/contracts/extensions.contract.js +11 -2
- package/dist/contracts/extensions.contract.js.map +1 -1
- package/dist/contracts/git.contract.d.ts +7 -0
- package/dist/contracts/git.contract.d.ts.map +1 -1
- package/dist/contracts/needs.contract.d.ts +1097 -18
- package/dist/contracts/needs.contract.d.ts.map +1 -1
- package/dist/contracts/offload.contract.d.ts +25 -0
- package/dist/contracts/offload.contract.d.ts.map +1 -1
- package/dist/contracts/ports.contract.d.ts +8 -0
- package/dist/contracts/ports.contract.d.ts.map +1 -1
- package/dist/contracts/ports.contract.js +6 -5
- package/dist/contracts/ports.contract.js.map +1 -1
- package/dist/contracts/remote.contract.d.ts +1 -0
- package/dist/contracts/remote.contract.d.ts.map +1 -1
- package/dist/contracts/runner.contract.d.ts +1203 -9
- package/dist/contracts/runner.contract.d.ts.map +1 -1
- package/dist/contracts/runner.contract.js +49 -2
- package/dist/contracts/runner.contract.js.map +1 -1
- package/dist/contracts/runners.contract.d.ts +16 -0
- package/dist/contracts/runners.contract.d.ts.map +1 -0
- package/dist/contracts/runners.contract.js +15 -0
- package/dist/contracts/runners.contract.js.map +1 -0
- package/dist/contracts/safety.contract.d.ts.map +1 -1
- package/dist/contracts/safety.contract.js +1 -0
- package/dist/contracts/safety.contract.js.map +1 -1
- package/dist/contracts/seal.contract.d.ts +100 -0
- package/dist/contracts/seal.contract.d.ts.map +1 -1
- package/dist/contracts/secrets.contract.d.ts +15 -0
- package/dist/contracts/secrets.contract.d.ts.map +1 -1
- package/dist/contracts/secrets.contract.js +27 -1
- package/dist/contracts/secrets.contract.js.map +1 -1
- package/dist/contracts/sessions.contract.d.ts +159 -2
- package/dist/contracts/sessions.contract.d.ts.map +1 -1
- package/dist/contracts/settings.contract.d.ts +59 -42
- package/dist/contracts/settings.contract.d.ts.map +1 -1
- package/dist/contracts/settings.contract.js +19 -0
- package/dist/contracts/settings.contract.js.map +1 -1
- package/dist/contracts/skills.contract.d.ts +6 -0
- package/dist/contracts/skills.contract.d.ts.map +1 -1
- package/dist/contracts/stack-grants.contract.d.ts +418 -0
- package/dist/contracts/stack-grants.contract.d.ts.map +1 -0
- package/dist/contracts/stack-grants.contract.js +46 -0
- package/dist/contracts/stack-grants.contract.js.map +1 -0
- package/dist/contracts/system.contract.d.ts +516 -69
- package/dist/contracts/system.contract.d.ts.map +1 -1
- package/dist/contracts/system.contract.js +26 -45
- package/dist/contracts/system.contract.js.map +1 -1
- package/dist/contracts/usage.contract.d.ts +3 -0
- package/dist/contracts/usage.contract.d.ts.map +1 -1
- package/dist/contracts/workspace.contract.d.ts +0 -55
- package/dist/contracts/workspace.contract.d.ts.map +1 -1
- package/dist/contracts/workspace.contract.js +0 -19
- package/dist/contracts/workspace.contract.js.map +1 -1
- package/dist/events/agent-events.d.ts +615 -8
- package/dist/events/agent-events.d.ts.map +1 -1
- package/dist/events/agent-events.js +2 -2
- package/dist/events/agent-events.js.map +1 -1
- package/dist/events/agent-transcript.d.ts +159 -2
- package/dist/events/agent-transcript.d.ts.map +1 -1
- package/dist/events/agent-words.d.ts +5 -0
- package/dist/events/agent-words.d.ts.map +1 -1
- package/dist/events/agent-words.js +22 -2
- package/dist/events/agent-words.js.map +1 -1
- package/dist/events/child-news.d.ts +32 -0
- package/dist/events/child-news.d.ts.map +1 -0
- package/dist/events/child-news.js +171 -0
- package/dist/events/child-news.js.map +1 -0
- package/dist/events/prompt-origins.d.ts +42 -0
- package/dist/events/prompt-origins.d.ts.map +1 -1
- package/dist/events/prompt-origins.js +28 -0
- package/dist/events/prompt-origins.js.map +1 -1
- package/dist/events/refusal-incidents.d.ts +1 -0
- package/dist/events/refusal-incidents.d.ts.map +1 -1
- package/dist/events/refusal-incidents.js +42 -19
- package/dist/events/refusal-incidents.js.map +1 -1
- package/dist/events/requests.d.ts +14 -0
- package/dist/events/requests.d.ts.map +1 -1
- package/dist/events/requests.js +12 -0
- package/dist/events/requests.js.map +1 -1
- package/dist/events/system-events.d.ts +98 -0
- package/dist/events/system-events.d.ts.map +1 -1
- package/dist/events/transcript.d.ts +799 -10
- package/dist/events/transcript.d.ts.map +1 -1
- package/dist/events/transcript.js +2 -1
- package/dist/events/transcript.js.map +1 -1
- package/dist/ids/conversation-ids.d.ts +1 -0
- package/dist/ids/conversation-ids.d.ts.map +1 -1
- package/dist/ids/conversation-ids.js +2 -1
- package/dist/ids/conversation-ids.js.map +1 -1
- package/dist/ids/project-id.d.ts.map +1 -1
- package/dist/ids/project-id.js +4 -4
- package/dist/ids/project-id.js.map +1 -1
- package/dist/ids/run-row-ids.d.ts +8 -0
- package/dist/ids/run-row-ids.d.ts.map +1 -0
- package/dist/ids/run-row-ids.js +32 -0
- package/dist/ids/run-row-ids.js.map +1 -0
- package/dist/index.d.ts +4 -4
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +4 -4
- package/dist/index.js.map +1 -1
- package/dist/models/agent-catalog.d.ts.map +1 -1
- package/dist/models/agent-catalog.js +3 -2
- package/dist/models/agent-catalog.js.map +1 -1
- package/dist/models/agent-lanes.d.ts.map +1 -1
- package/dist/models/agent-lanes.js +4 -1
- package/dist/models/agent-lanes.js.map +1 -1
- package/dist/models/agent-runtimes.d.ts.map +1 -1
- package/dist/models/agent-runtimes.js +2 -2
- package/dist/models/agent-runtimes.js.map +1 -1
- package/dist/models/agent-standing.d.ts +6 -1
- package/dist/models/agent-standing.d.ts.map +1 -1
- package/dist/models/agent-standing.js +1 -0
- package/dist/models/agent-standing.js.map +1 -1
- package/dist/models/model-roles.d.ts +91 -37
- package/dist/models/model-roles.d.ts.map +1 -1
- package/dist/models/model-roles.js +106 -35
- package/dist/models/model-roles.js.map +1 -1
- package/dist/models/model-setups.d.ts +10 -8
- package/dist/models/model-setups.d.ts.map +1 -1
- package/dist/models/model-setups.js +15 -15
- package/dist/models/model-setups.js.map +1 -1
- package/dist/models/providers/provider-traits.d.ts +215 -0
- package/dist/models/providers/provider-traits.d.ts.map +1 -0
- package/dist/models/providers/provider-traits.js +60 -0
- package/dist/models/providers/provider-traits.js.map +1 -0
- package/dist/netd/browser-wire.d.ts +8 -0
- package/dist/netd/browser-wire.d.ts.map +1 -1
- package/dist/netd/browser-wire.js +5 -0
- package/dist/netd/browser-wire.js.map +1 -1
- package/dist/netd/generated/wire.d.ts +42 -1
- package/dist/netd/generated/wire.d.ts.map +1 -1
- package/dist/policy/admin/admin-grant.d.ts +21 -0
- package/dist/policy/admin/admin-grant.d.ts.map +1 -0
- package/dist/policy/admin/admin-grant.js +41 -0
- package/dist/policy/admin/admin-grant.js.map +1 -0
- package/dist/policy/approvals-execution.d.ts +5 -2
- package/dist/policy/approvals-execution.d.ts.map +1 -1
- package/dist/policy/approvals-execution.js +3 -4
- package/dist/policy/approvals-execution.js.map +1 -1
- package/dist/policy/batch-runs.d.ts +1 -1
- package/dist/policy/batch-runs.d.ts.map +1 -1
- package/dist/policy/batch-runs.js +2 -1
- package/dist/policy/batch-runs.js.map +1 -1
- package/dist/policy/capabilities/capability-kinds.d.ts +268 -0
- package/dist/policy/capabilities/capability-kinds.d.ts.map +1 -0
- package/dist/policy/capabilities/capability-kinds.js +47 -0
- package/dist/policy/capabilities/capability-kinds.js.map +1 -0
- package/dist/policy/command-classes.d.ts.map +1 -1
- package/dist/policy/command-classes.js +3 -1
- package/dist/policy/command-classes.js.map +1 -1
- package/dist/policy/device-programs.d.ts +79 -2
- package/dist/policy/device-programs.d.ts.map +1 -1
- package/dist/policy/device-programs.js +15 -16
- package/dist/policy/device-programs.js.map +1 -1
- package/dist/policy/message-limits.d.ts.map +1 -1
- package/dist/policy/message-limits.js.map +1 -1
- package/dist/policy/org-locks.d.ts +1 -1
- package/dist/policy/org-locks.d.ts.map +1 -1
- package/dist/policy/org-locks.js +1 -0
- package/dist/policy/org-locks.js.map +1 -1
- package/dist/policy/reserved-servers.d.ts.map +1 -1
- package/dist/policy/reserved-servers.js +5 -1
- package/dist/policy/reserved-servers.js.map +1 -1
- package/dist/policy/role-capability.d.ts.map +1 -1
- package/dist/policy/role-capability.js +2 -1
- package/dist/policy/role-capability.js.map +1 -1
- package/dist/policy/shell/command-normalise.d.ts +10 -0
- package/dist/policy/shell/command-normalise.d.ts.map +1 -0
- package/dist/policy/shell/command-normalise.js +153 -0
- package/dist/policy/shell/command-normalise.js.map +1 -0
- package/dist/policy/shell/workspace-root-exclude.d.ts +4 -0
- package/dist/policy/shell/workspace-root-exclude.d.ts.map +1 -0
- package/dist/policy/shell/workspace-root-exclude.js +4 -0
- package/dist/policy/shell/workspace-root-exclude.js.map +1 -0
- package/dist/protocol/doors/listener-protocol.d.ts +11 -0
- package/dist/protocol/doors/listener-protocol.d.ts.map +1 -1
- package/dist/protocol/doors/listener-protocol.js +5 -0
- package/dist/protocol/doors/listener-protocol.js.map +1 -1
- package/dist/protocol/doors/loopback-proof.d.ts +8 -0
- package/dist/protocol/doors/loopback-proof.d.ts.map +1 -0
- package/dist/protocol/doors/loopback-proof.js +11 -0
- package/dist/protocol/doors/loopback-proof.js.map +1 -0
- package/dist/protocol/doors/pass-scopes.d.ts +4 -0
- package/dist/protocol/doors/pass-scopes.d.ts.map +1 -0
- package/dist/protocol/doors/pass-scopes.js +3 -0
- package/dist/protocol/doors/pass-scopes.js.map +1 -0
- package/dist/protocol/doors/runner-protocol.d.ts +187 -0
- package/dist/protocol/doors/runner-protocol.d.ts.map +1 -1
- package/dist/protocol/doors/runner-protocol.js +48 -1
- package/dist/protocol/doors/runner-protocol.js.map +1 -1
- package/dist/protocol/doors/sandbox-pass.d.ts +19 -2
- package/dist/protocol/doors/sandbox-pass.d.ts.map +1 -1
- package/dist/protocol/doors/sandbox-pass.js +42 -10
- package/dist/protocol/doors/sandbox-pass.js.map +1 -1
- package/dist/protocol/doors/webext-links.d.ts.map +1 -1
- package/dist/protocol/doors/webext-links.js.map +1 -1
- package/dist/protocol/member-reach.d.ts +6 -0
- package/dist/protocol/member-reach.d.ts.map +1 -1
- package/dist/protocol/member-reach.js +24 -0
- package/dist/protocol/member-reach.js.map +1 -1
- package/dist/protocol/peer-mcp-server.d.ts +2 -0
- package/dist/protocol/peer-mcp-server.d.ts.map +1 -1
- package/dist/protocol/peer-mcp-server.js +1 -0
- package/dist/protocol/peer-mcp-server.js.map +1 -1
- package/dist/protocol/raw/extension-protocol.d.ts +518 -0
- package/dist/protocol/raw/extension-protocol.d.ts.map +1 -1
- package/dist/protocol/raw/extension-protocol.js +276 -0
- package/dist/protocol/raw/extension-protocol.js.map +1 -1
- package/dist/protocol/raw/raw-json-routes.d.ts +572 -0
- package/dist/protocol/raw/raw-json-routes.d.ts.map +1 -1
- package/dist/protocol/raw/raw-json-routes.js +25 -2
- package/dist/protocol/raw/raw-json-routes.js.map +1 -1
- package/dist/protocol/raw/raw-routes.d.ts +245 -3
- package/dist/protocol/raw/raw-routes.d.ts.map +1 -1
- package/dist/protocol/raw/raw-routes.js +79 -36
- package/dist/protocol/raw/raw-routes.js.map +1 -1
- package/dist/protocol/route-meta.d.ts.map +1 -1
- package/dist/protocol/route-meta.js.map +1 -1
- package/dist/schemas/account-routes.d.ts +176 -0
- package/dist/schemas/account-routes.d.ts.map +1 -0
- package/dist/schemas/account-routes.js +73 -0
- package/dist/schemas/account-routes.js.map +1 -0
- package/dist/schemas/activity.d.ts.map +1 -1
- package/dist/schemas/activity.js.map +1 -1
- package/dist/schemas/agent-background.d.ts +48 -0
- package/dist/schemas/agent-background.d.ts.map +1 -0
- package/dist/schemas/agent-background.js +63 -0
- package/dist/schemas/agent-background.js.map +1 -0
- package/dist/schemas/agent-land.d.ts +7 -0
- package/dist/schemas/agent-land.d.ts.map +1 -1
- package/dist/schemas/agent-land.js +11 -0
- package/dist/schemas/agent-land.js.map +1 -1
- package/dist/schemas/agent.d.ts +4 -0
- package/dist/schemas/agent.d.ts.map +1 -1
- package/dist/schemas/agent.js +4 -2
- package/dist/schemas/agent.js.map +1 -1
- package/dist/schemas/agents-list.d.ts +40 -0
- package/dist/schemas/agents-list.d.ts.map +1 -1
- package/dist/schemas/agents.d.ts +668 -17
- package/dist/schemas/agents.d.ts.map +1 -1
- package/dist/schemas/agents.js +16 -41
- package/dist/schemas/agents.js.map +1 -1
- package/dist/schemas/auto-approve.d.ts +12 -0
- package/dist/schemas/auto-approve.d.ts.map +1 -0
- package/dist/schemas/auto-approve.js +12 -0
- package/dist/schemas/auto-approve.js.map +1 -0
- package/dist/schemas/automations.d.ts +170 -27
- package/dist/schemas/automations.d.ts.map +1 -1
- package/dist/schemas/automations.js +26 -34
- package/dist/schemas/automations.js.map +1 -1
- package/dist/schemas/bridge-heads.d.ts +57 -0
- package/dist/schemas/bridge-heads.d.ts.map +1 -0
- package/dist/schemas/bridge-heads.js +22 -0
- package/dist/schemas/bridge-heads.js.map +1 -0
- package/dist/schemas/capabilities.d.ts +21 -0
- package/dist/schemas/capabilities.d.ts.map +1 -1
- package/dist/schemas/capabilities.js +6 -0
- package/dist/schemas/capabilities.js.map +1 -1
- package/dist/schemas/checkout-hooks.d.ts +24 -0
- package/dist/schemas/checkout-hooks.d.ts.map +1 -0
- package/dist/schemas/checkout-hooks.js +23 -0
- package/dist/schemas/checkout-hooks.js.map +1 -0
- package/dist/schemas/ci-deployments.d.ts +30 -0
- package/dist/schemas/ci-deployments.d.ts.map +1 -0
- package/dist/schemas/ci-deployments.js +18 -0
- package/dist/schemas/ci-deployments.js.map +1 -0
- package/dist/schemas/ci-fleet.d.ts +216 -0
- package/dist/schemas/ci-fleet.d.ts.map +1 -0
- package/dist/schemas/ci-fleet.js +87 -0
- package/dist/schemas/ci-fleet.js.map +1 -0
- package/dist/schemas/ci.d.ts +348 -21
- package/dist/schemas/ci.d.ts.map +1 -1
- package/dist/schemas/ci.js +110 -19
- package/dist/schemas/ci.js.map +1 -1
- package/dist/schemas/command-run.d.ts +29 -0
- package/dist/schemas/command-run.d.ts.map +1 -0
- package/dist/schemas/command-run.js +20 -0
- package/dist/schemas/command-run.js.map +1 -0
- package/dist/schemas/connection-hub.d.ts +3 -1
- package/dist/schemas/connection-hub.d.ts.map +1 -1
- package/dist/schemas/connection-hub.js +2 -1
- package/dist/schemas/connection-hub.js.map +1 -1
- package/dist/schemas/context-continues.d.ts.map +1 -1
- package/dist/schemas/context-continues.js +2 -2
- package/dist/schemas/context-continues.js.map +1 -1
- package/dist/schemas/data-protection.d.ts +15 -2
- package/dist/schemas/data-protection.d.ts.map +1 -1
- package/dist/schemas/data-protection.js +15 -23
- package/dist/schemas/data-protection.js.map +1 -1
- package/dist/schemas/device-stacks.d.ts +131 -0
- package/dist/schemas/device-stacks.d.ts.map +1 -1
- package/dist/schemas/device-stacks.js +81 -0
- package/dist/schemas/device-stacks.js.map +1 -1
- package/dist/schemas/devices.d.ts +137 -0
- package/dist/schemas/devices.d.ts.map +1 -1
- package/dist/schemas/devices.js +11 -2
- package/dist/schemas/devices.js.map +1 -1
- package/dist/schemas/environment.d.ts +1 -0
- package/dist/schemas/environment.d.ts.map +1 -1
- package/dist/schemas/environment.js +1 -0
- package/dist/schemas/environment.js.map +1 -1
- package/dist/schemas/extension-updates.d.ts +1186 -0
- package/dist/schemas/extension-updates.d.ts.map +1 -1
- package/dist/schemas/extension-updates.js +22 -4
- package/dist/schemas/extension-updates.js.map +1 -1
- package/dist/schemas/git/git.d.ts +13 -0
- package/dist/schemas/git/git.d.ts.map +1 -1
- package/dist/schemas/git/git.js +7 -7
- package/dist/schemas/git/git.js.map +1 -1
- package/dist/schemas/git/index-run.d.ts +1 -0
- package/dist/schemas/git/index-run.d.ts.map +1 -1
- package/dist/schemas/host-power.d.ts +76 -0
- package/dist/schemas/host-power.d.ts.map +1 -0
- package/dist/schemas/host-power.js +101 -0
- package/dist/schemas/host-power.js.map +1 -0
- package/dist/schemas/hosts.d.ts +365 -0
- package/dist/schemas/hosts.d.ts.map +1 -1
- package/dist/schemas/hosts.js +33 -1
- package/dist/schemas/hosts.js.map +1 -1
- package/dist/schemas/issues.d.ts +55 -225
- package/dist/schemas/issues.d.ts.map +1 -1
- package/dist/schemas/issues.js +21 -43
- package/dist/schemas/issues.js.map +1 -1
- package/dist/schemas/keyring-native.d.ts.map +1 -1
- package/dist/schemas/keyring-native.js +3 -1
- package/dist/schemas/keyring-native.js.map +1 -1
- package/dist/schemas/keyring.d.ts +1 -0
- package/dist/schemas/keyring.d.ts.map +1 -1
- package/dist/schemas/keyring.js +3 -1
- package/dist/schemas/keyring.js.map +1 -1
- package/dist/schemas/maintenance.d.ts.map +1 -1
- package/dist/schemas/maintenance.js.map +1 -1
- package/dist/schemas/members.d.ts.map +1 -1
- package/dist/schemas/members.js +2 -14
- package/dist/schemas/members.js.map +1 -1
- package/dist/schemas/metrics.d.ts +33 -0
- package/dist/schemas/metrics.d.ts.map +1 -1
- package/dist/schemas/metrics.js +26 -0
- package/dist/schemas/metrics.js.map +1 -1
- package/dist/schemas/need-kinds.d.ts +19 -0
- package/dist/schemas/need-kinds.d.ts.map +1 -0
- package/dist/schemas/need-kinds.js +7 -0
- package/dist/schemas/need-kinds.js.map +1 -0
- package/dist/schemas/needs.d.ts +868 -27
- package/dist/schemas/needs.d.ts.map +1 -1
- package/dist/schemas/needs.js +79 -9
- package/dist/schemas/needs.js.map +1 -1
- package/dist/schemas/offload.d.ts +61 -0
- package/dist/schemas/offload.d.ts.map +1 -1
- package/dist/schemas/offload.js +14 -1
- package/dist/schemas/offload.js.map +1 -1
- package/dist/schemas/outward-action.d.ts +39 -0
- package/dist/schemas/outward-action.d.ts.map +1 -0
- package/dist/schemas/outward-action.js +40 -0
- package/dist/schemas/outward-action.js.map +1 -0
- package/dist/schemas/ports.d.ts +4 -0
- package/dist/schemas/ports.d.ts.map +1 -1
- package/dist/schemas/ports.js +3 -0
- package/dist/schemas/ports.js.map +1 -1
- package/dist/schemas/providers/capacity.d.ts +6 -0
- package/dist/schemas/providers/capacity.d.ts.map +1 -1
- package/dist/schemas/providers/plan-limits.d.ts +1 -0
- package/dist/schemas/providers/plan-limits.d.ts.map +1 -1
- package/dist/schemas/providers/plan-limits.js +1 -0
- package/dist/schemas/providers/plan-limits.js.map +1 -1
- package/dist/schemas/providers/refusals.d.ts +12 -0
- package/dist/schemas/providers/refusals.d.ts.map +1 -1
- package/dist/schemas/providers/refusals.js +4 -0
- package/dist/schemas/providers/refusals.js.map +1 -1
- package/dist/schemas/remote-access.d.ts +1 -0
- package/dist/schemas/remote-access.d.ts.map +1 -1
- package/dist/schemas/remote-access.js +1 -0
- package/dist/schemas/remote-access.js.map +1 -1
- package/dist/schemas/run-targets.d.ts.map +1 -1
- package/dist/schemas/run-targets.js +2 -1
- package/dist/schemas/run-targets.js.map +1 -1
- package/dist/schemas/runner-views.d.ts +24 -0
- package/dist/schemas/runner-views.d.ts.map +1 -0
- package/dist/schemas/runner-views.js +16 -0
- package/dist/schemas/runner-views.js.map +1 -0
- package/dist/schemas/sandbox-reach.d.ts +157 -0
- package/dist/schemas/sandbox-reach.d.ts.map +1 -0
- package/dist/schemas/sandbox-reach.js +112 -0
- package/dist/schemas/sandbox-reach.js.map +1 -0
- package/dist/schemas/secrets.d.ts +17 -0
- package/dist/schemas/secrets.d.ts.map +1 -1
- package/dist/schemas/secrets.js +12 -5
- package/dist/schemas/secrets.js.map +1 -1
- package/dist/schemas/settings-history.d.ts +1 -1
- package/dist/schemas/settings-history.d.ts.map +1 -1
- package/dist/schemas/settings-history.js +5 -4
- package/dist/schemas/settings-history.js.map +1 -1
- package/dist/schemas/settings-savings.d.ts +58 -0
- package/dist/schemas/settings-savings.d.ts.map +1 -1
- package/dist/schemas/settings-savings.js +22 -0
- package/dist/schemas/settings-savings.js.map +1 -1
- package/dist/schemas/settings.d.ts +20 -42
- package/dist/schemas/settings.d.ts.map +1 -1
- package/dist/schemas/settings.js +24 -7
- package/dist/schemas/settings.js.map +1 -1
- package/dist/schemas/stack-grants.d.ts +60 -0
- package/dist/schemas/stack-grants.d.ts.map +1 -0
- package/dist/schemas/stack-grants.js +33 -0
- package/dist/schemas/stack-grants.js.map +1 -0
- package/dist/schemas/system.d.ts +19 -0
- package/dist/schemas/system.d.ts.map +1 -1
- package/dist/schemas/system.js +9 -0
- package/dist/schemas/system.js.map +1 -1
- package/dist/schemas/terminal.d.ts +46 -0
- package/dist/schemas/terminal.d.ts.map +1 -1
- package/dist/schemas/terminal.js +19 -0
- package/dist/schemas/terminal.js.map +1 -1
- package/dist/schemas/watch-sources.d.ts +72 -0
- package/dist/schemas/watch-sources.d.ts.map +1 -0
- package/dist/schemas/watch-sources.js +88 -0
- package/dist/schemas/watch-sources.js.map +1 -0
- package/dist/schemas/workspace/workspace-search.d.ts.map +1 -1
- package/dist/schemas/workspace/workspace-search.js +1 -1
- package/dist/schemas/workspace/workspace-search.js.map +1 -1
- package/dist/schemas/wsl-memory.d.ts +76 -0
- package/dist/schemas/wsl-memory.d.ts.map +1 -0
- package/dist/schemas/wsl-memory.js +36 -0
- package/dist/schemas/wsl-memory.js.map +1 -0
- package/dist/state/auth-state.d.ts.map +1 -1
- package/dist/state/auth-state.js +3 -0
- package/dist/state/auth-state.js.map +1 -1
- package/dist/state/definition.d.ts +16 -8
- package/dist/state/definition.d.ts.map +1 -1
- package/dist/state/runtime-state.d.ts +1 -1
- package/dist/state/runtime-state.d.ts.map +1 -1
- package/dist/state/runtime-state.js +1 -1
- package/dist/state/runtime-state.js.map +1 -1
- package/dist/state/workspace-state.d.ts +9 -4
- package/dist/state/workspace-state.d.ts.map +1 -1
- package/dist/state/workspace-state.js +9 -4
- package/dist/state/workspace-state.js.map +1 -1
- package/dist/sync/workspace-sync-ignores.d.ts +4 -0
- package/dist/sync/workspace-sync-ignores.d.ts.map +1 -0
- package/dist/sync/workspace-sync-ignores.js +75 -0
- package/dist/sync/workspace-sync-ignores.js.map +1 -0
- package/dist/text/pages.d.ts.map +1 -1
- package/dist/text/pages.js +17 -4
- package/dist/text/pages.js.map +1 -1
- package/dist/text/transcript-fold.js +2 -2
- package/dist/text/transcript-fold.js.map +1 -1
- package/package.json +5 -5
- package/src/app-routes/app-pages.ts +3 -0
- package/src/app-routes/index.ts +1 -0
- package/src/app-routes/return-path.ts +16 -0
- package/src/briefs/agent-ask.ts +23 -0
- package/src/{chores/extension-update.ts → briefs/extension-update-brief.ts} +3 -2
- package/src/chores/digest.ts +1 -0
- package/src/chores/index.ts +13 -2
- package/src/chores/prompt.ts +3 -18
- package/src/chores/stack.ts +1 -0
- package/src/chores/verdict.ts +1 -0
- package/src/chores/workspace-scope.ts +3 -8
- package/src/contracts/accounts.contract.ts +3 -0
- package/src/contracts/agents.contract.ts +41 -5
- package/src/contracts/automations.contract.ts +2 -0
- package/src/contracts/capabilities.contract.ts +31 -2
- package/src/contracts/ci.contract.ts +119 -37
- package/src/contracts/device-ci-runners.contract.ts +81 -0
- package/src/contracts/device-stacks.contract.ts +97 -0
- package/src/contracts/extensions.contract.ts +12 -1
- package/src/contracts/ports.contract.ts +6 -6
- package/src/contracts/runner.contract.ts +117 -3
- package/src/contracts/runners.contract.ts +19 -0
- package/src/contracts/safety.contract.ts +2 -0
- package/src/contracts/secrets.contract.ts +39 -0
- package/src/contracts/settings.contract.ts +26 -0
- package/src/contracts/stack-grants.contract.ts +51 -0
- package/src/contracts/system.contract.ts +36 -62
- package/src/contracts/workspace.contract.ts +0 -22
- package/src/events/agent-events.ts +3 -2
- package/src/events/agent-words.test.ts +19 -1
- package/src/events/agent-words.ts +36 -2
- package/src/events/child-news.test.ts +91 -0
- package/src/events/child-news.ts +269 -0
- package/src/events/prompt-origins.ts +35 -0
- package/src/events/refusal-incidents.ts +60 -19
- package/src/events/requests.ts +18 -0
- package/src/events/transcript.ts +10 -1
- package/src/ids/conversation-ids.test.ts +3 -1
- package/src/ids/conversation-ids.ts +6 -4
- package/src/ids/project-dir.test.ts +1 -1
- package/src/ids/project-dir.ts +1 -1
- package/src/ids/project-id.test.ts +14 -0
- package/src/ids/project-id.ts +6 -4
- package/src/ids/run-row-ids.test.ts +38 -0
- package/src/ids/run-row-ids.ts +49 -0
- package/src/index.ts +6 -6
- package/src/models/agent-catalog.test.ts +7 -4
- package/src/models/agent-catalog.ts +3 -2
- package/src/models/agent-lanes.ts +8 -1
- package/src/models/agent-runtimes.ts +7 -6
- package/src/models/agent-standing.ts +13 -0
- package/src/models/model-roles.test.ts +61 -4
- package/src/models/model-roles.ts +153 -49
- package/src/models/model-setups.ts +49 -26
- package/src/models/provider-specs.test.ts +2 -2
- package/src/models/providers/provider-traits.test.ts +71 -0
- package/src/models/providers/provider-traits.ts +144 -0
- package/src/netd/browser-wire.ts +13 -0
- package/src/netd/generated/browser-wire.json +10 -0
- package/src/netd/generated/netd-wire.json +224 -1
- package/src/netd/generated/wire.ts +18 -6
- package/src/netd/wire-manifests.test.ts +16 -0
- package/src/policy/admin/admin-grant.ts +69 -0
- package/src/policy/approvals-execution.ts +11 -6
- package/src/policy/batch-runs.ts +2 -2
- package/src/policy/capabilities/capability-kinds.test.ts +112 -0
- package/src/policy/capabilities/capability-kinds.ts +110 -0
- package/src/policy/command-classes.ts +5 -3
- package/src/policy/credential-material.ts +1 -1
- package/src/policy/device-programs.ts +29 -20
- package/src/policy/message-limits.ts +8 -4
- package/src/policy/org-locks.ts +1 -0
- package/src/policy/overlay-lint.ts +1 -1
- package/src/policy/reserved-servers.ts +5 -1
- package/src/policy/role-capability.ts +3 -1
- package/src/policy/shell/command-normalise.test.ts +72 -0
- package/src/policy/shell/command-normalise.ts +212 -0
- package/src/policy/shell/workspace-root-exclude.ts +11 -0
- package/src/policy/tests/admin-grant.test.ts +35 -0
- package/src/policy/tests/command-classes.test.ts +41 -0
- package/src/protocol/doors/listener-protocol.ts +32 -1
- package/src/protocol/doors/loopback-proof.ts +34 -0
- package/src/protocol/doors/pass-scopes.ts +12 -0
- package/src/protocol/doors/runner-protocol.ts +133 -4
- package/src/protocol/doors/sandbox-pass.test.ts +33 -1
- package/src/protocol/doors/sandbox-pass.ts +92 -16
- package/src/protocol/doors/webext-links.ts +3 -1
- package/src/protocol/ingress-contract.fixture.json +5 -1
- package/src/protocol/member-reach.test.ts +40 -1
- package/src/protocol/member-reach.ts +40 -0
- package/src/protocol/peer-mcp-server.ts +6 -0
- package/src/protocol/raw/extension-protocol.ts +469 -2
- package/src/protocol/raw/raw-json-routes.ts +45 -1
- package/src/protocol/raw/raw-routes.ts +133 -40
- package/src/protocol/route-meta.ts +4 -1
- package/src/schemas/account-routes.ts +126 -0
- package/src/schemas/activity.ts +6 -4
- package/src/schemas/agent-background.ts +104 -0
- package/src/schemas/agent-land.ts +21 -2
- package/src/schemas/agent.test.ts +3 -0
- package/src/schemas/agent.ts +10 -4
- package/src/schemas/agents.ts +26 -65
- package/src/schemas/auto-approve.ts +31 -0
- package/src/schemas/automations.ts +51 -42
- package/src/schemas/bridge-heads.ts +33 -0
- package/src/schemas/capabilities.ts +23 -0
- package/src/schemas/checkout-hooks.ts +44 -0
- package/src/schemas/ci-deployments.ts +26 -0
- package/src/schemas/ci-fleet.ts +180 -0
- package/src/schemas/ci.ts +185 -45
- package/src/schemas/command-run.ts +44 -0
- package/src/schemas/compose-overlay.test.ts +1 -1
- package/src/schemas/compose-overlay.ts +1 -1
- package/src/schemas/connection-hub.ts +4 -2
- package/src/schemas/context-continues.ts +6 -3
- package/src/schemas/data-protection.ts +28 -34
- package/src/schemas/device-stacks.ts +162 -3
- package/src/schemas/device-swaps.test.ts +1 -1
- package/src/schemas/devices.ts +31 -2
- package/src/schemas/egress-private.test.ts +1 -1
- package/src/schemas/environment.ts +4 -0
- package/src/schemas/extension-updates.ts +35 -7
- package/src/schemas/git/git.ts +14 -14
- package/src/schemas/host-power.test.ts +53 -0
- package/src/schemas/host-power.ts +173 -0
- package/src/schemas/hosts.test.ts +32 -0
- package/src/schemas/hosts.ts +86 -2
- package/src/schemas/intentic-os.ts +2 -2
- package/src/schemas/issues.ts +43 -86
- package/src/schemas/keyring-native.test.ts +11 -3
- package/src/schemas/keyring-native.ts +3 -1
- package/src/schemas/keyring.ts +6 -1
- package/src/schemas/maintenance.ts +4 -3
- package/src/schemas/members.ts +4 -16
- package/src/schemas/metrics.test.ts +9 -1
- package/src/schemas/metrics.ts +43 -0
- package/src/schemas/need-kinds.ts +13 -0
- package/src/schemas/needs.ts +118 -14
- package/src/schemas/offload.ts +37 -3
- package/src/schemas/outward-action.ts +47 -0
- package/src/schemas/ports.ts +5 -0
- package/src/schemas/providers/plan-limits.ts +1 -0
- package/src/schemas/providers/refusals.ts +9 -0
- package/src/schemas/remote-access.ts +3 -0
- package/src/schemas/run-targets.ts +2 -1
- package/src/schemas/runner-views.ts +27 -0
- package/src/schemas/sandbox-reach.ts +161 -0
- package/src/schemas/secrets.ts +23 -5
- package/src/schemas/settings-history.ts +10 -5
- package/src/schemas/settings-savings.ts +29 -0
- package/src/schemas/settings.test.ts +24 -23
- package/src/schemas/settings.ts +55 -22
- package/src/schemas/stack-grants.ts +59 -0
- package/src/schemas/state-plan.test.ts +1 -1
- package/src/schemas/state-plan.ts +2 -2
- package/src/schemas/system.ts +16 -1
- package/src/schemas/terminal.ts +28 -0
- package/src/schemas/updates.test.ts +1 -1
- package/src/schemas/updates.ts +1 -1
- package/src/schemas/version-seam.test.ts +4 -1
- package/src/schemas/watch-sources.ts +127 -0
- package/src/schemas/workspace/workspace-search.ts +5 -2
- package/src/schemas/wsl-memory.ts +59 -0
- package/src/state/auth-state.ts +10 -0
- package/src/state/runtime-state.test.ts +3 -2
- package/src/state/runtime-state.ts +3 -1
- package/src/state/update-probation.ts +1 -1
- package/src/state/ways-back.test.ts +1 -1
- package/src/state/workspace-state.test.ts +2 -0
- package/src/state/workspace-state.ts +21 -21
- package/src/sync/workspace-sync-ignores.test.ts +48 -0
- package/src/sync/workspace-sync-ignores.ts +143 -0
- package/src/text/embed.ts +2 -2
- package/src/text/pages.ts +34 -7
- package/src/text/transcript-fold.test.ts +40 -2
- package/src/text/transcript-fold.ts +2 -2
- package/dist/chores/extension-update.d.ts.map +0 -1
- package/dist/chores/extension-update.js.map +0 -1
- package/dist/contracts/chores.contract.d.ts +0 -213
- package/dist/contracts/chores.contract.d.ts.map +0 -1
- package/dist/contracts/chores.contract.js +0 -32
- package/dist/contracts/chores.contract.js.map +0 -1
- package/dist/contracts/issues.contract.d.ts +0 -95
- package/dist/contracts/issues.contract.d.ts.map +0 -1
- package/dist/contracts/issues.contract.js +0 -50
- package/dist/contracts/issues.contract.js.map +0 -1
- package/src/chores/chores.test.ts +0 -24
- package/src/chores/digest.test.ts +0 -27
- package/src/chores/probes.integration.test.ts +0 -494
- package/src/chores/stack.test.ts +0 -140
- package/src/chores/verdict.test.ts +0 -761
- package/src/contracts/chores.contract.ts +0 -39
- package/src/contracts/issues.contract.ts +0 -53
|
@@ -0,0 +1,161 @@
|
|
|
1
|
+
import { z } from "zod";
|
|
2
|
+
import { MemberTierSchema } from "./shared.js";
|
|
3
|
+
|
|
4
|
+
// ONE SANDBOX'S TIES TO EVERYTHING OUTSIDE IT, as the person reading may see them (GET /system/reach). The editor asks
|
|
5
|
+
// every sandbox an account reaches for this answer and joins them into the account's access map (Settings ▸ Access
|
|
6
|
+
// map, docs/architecture/accounts.md): the other sandboxes this one hands work to and takes work from, the computers
|
|
7
|
+
// and servers its agents reach, and whether it may create sandboxes on its owner's account. Each daemon answers for
|
|
8
|
+
// its own ties alone, from what it stores and enforces, so the platform never learns them.
|
|
9
|
+
//
|
|
10
|
+
// Nothing here is a credential: no token, no address path, no secret. What joins two answers is an id both sides hold:
|
|
11
|
+
// a sandbox's platform id (else its address's host name), a computer's machine id (else its host name), a server's
|
|
12
|
+
// host name. Open sets (a link's answer, a device's kind, the switches it has on) are strings rather than enums, so a
|
|
13
|
+
// value a newer daemon adds never fails an older editor's parse; the known values are named below.
|
|
14
|
+
|
|
15
|
+
/** What a link's far side answered the last time this sandbox asked it (`GET /link`). */
|
|
16
|
+
export const REACH_LINK_ANSWERS = ["answering", "silent", "revoked"] as const;
|
|
17
|
+
export type ReachLinkAnswer = (typeof REACH_LINK_ANSWERS)[number];
|
|
18
|
+
|
|
19
|
+
/** What kind of thing a device card connects. */
|
|
20
|
+
export const REACH_DEVICE_KINDS = ["computer", "phone", "browser"] as const;
|
|
21
|
+
export type ReachDeviceKind = (typeof REACH_DEVICE_KINDS)[number];
|
|
22
|
+
|
|
23
|
+
/**
|
|
24
|
+
* A device card's switches that let an agent or a person act on the machine, in the order they are said. A card's
|
|
25
|
+
* switch that is on and named here is listed in `grants`; `roots` and the rest are settings, not grants.
|
|
26
|
+
*/
|
|
27
|
+
export const REACH_DEVICE_GRANTS = [
|
|
28
|
+
"shell",
|
|
29
|
+
"write",
|
|
30
|
+
"screen",
|
|
31
|
+
"control",
|
|
32
|
+
"sandboxes",
|
|
33
|
+
"destructive",
|
|
34
|
+
"admin",
|
|
35
|
+
"programs",
|
|
36
|
+
"remoteView",
|
|
37
|
+
"remoteControl",
|
|
38
|
+
"remoteTerminal",
|
|
39
|
+
] as const;
|
|
40
|
+
export type ReachDeviceGrant = (typeof REACH_DEVICE_GRANTS)[number];
|
|
41
|
+
|
|
42
|
+
/** The grants that let whoever holds them act on the machine as themselves (run, change or drive it), not only look. */
|
|
43
|
+
export const REACH_DEVICE_ACTING_GRANTS: readonly ReachDeviceGrant[] = ["shell", "write", "control", "destructive", "programs", "remoteControl", "remoteTerminal", "admin"];
|
|
44
|
+
|
|
45
|
+
/** A link's terms as the taking sandbox sets them, in the words both ends of a tie read. */
|
|
46
|
+
export const ReachLinkTermsSchema = z.object({
|
|
47
|
+
tasks: z.boolean().describe("Its agents may hand that sandbox tasks."),
|
|
48
|
+
records: z.boolean().describe("They may read that sandbox's conversations and diagnostics."),
|
|
49
|
+
operate: z.boolean().describe("They may run commands and read and write files there, as its owner's terminal would."),
|
|
50
|
+
approve: z.boolean().describe("Each new task waits for that sandbox's owner to allow it."),
|
|
51
|
+
role: z.string().optional().describe("The name of the role its tasks wear there; absent, they wear none."),
|
|
52
|
+
});
|
|
53
|
+
export type ReachLinkTerms = z.infer<typeof ReachLinkTermsSchema>;
|
|
54
|
+
|
|
55
|
+
// How many other people here may use one card through their own conversations: the owner and everyone on the roster
|
|
56
|
+
// who runs agents here and whose own access reaches the card. Only for a reader who runs people and access.
|
|
57
|
+
const othersField = z
|
|
58
|
+
.number()
|
|
59
|
+
.int()
|
|
60
|
+
.nonnegative()
|
|
61
|
+
.optional()
|
|
62
|
+
.describe("How many other people here may have their own agents use it. Absent when the roster is not the reader's to read.");
|
|
63
|
+
|
|
64
|
+
// Whether the reader's own conversations here may use one card: they run agents here, and their access reaches it.
|
|
65
|
+
const yoursField = z.boolean().describe("Whether the reader's own conversations here may use it.");
|
|
66
|
+
|
|
67
|
+
/** A `link` card here: this sandbox's agents may hand work to that one, under that sandbox's terms. */
|
|
68
|
+
export const ReachLinkOutSchema = z.object({
|
|
69
|
+
card: z.string().describe("The card's id here: what this sandbox's agents hand work `to`."),
|
|
70
|
+
name: z.string().optional().describe("What the other sandbox is called, as pairing named it."),
|
|
71
|
+
sandboxId: z.string().optional().describe("The other sandbox's platform id, when pairing named it."),
|
|
72
|
+
host: z.string().describe("The host name of the other sandbox's address, the join key when no id was named."),
|
|
73
|
+
answer: z.string().describe("What it answered when last asked: answering, silent (off or unreachable) or revoked."),
|
|
74
|
+
terms: ReachLinkTermsSchema.optional().describe("Its terms as the other sandbox last said them; absent while it has not answered."),
|
|
75
|
+
yours: yoursField,
|
|
76
|
+
others: othersField,
|
|
77
|
+
});
|
|
78
|
+
export type ReachLinkOut = z.infer<typeof ReachLinkOutSchema>;
|
|
79
|
+
|
|
80
|
+
/** An inbound link here: that sandbox's agents may hand work to this one, under the terms this sandbox's owner set. */
|
|
81
|
+
export const ReachLinkInSchema = z.object({
|
|
82
|
+
id: z.string(),
|
|
83
|
+
label: z.string().describe("What the asking sandbox is called here."),
|
|
84
|
+
sandboxId: z.string().optional().describe("The asking sandbox's platform id, when pairing named it."),
|
|
85
|
+
host: z.string().optional().describe("The host name of the asking sandbox's address, when pairing named it."),
|
|
86
|
+
terms: ReachLinkTermsSchema.extend({
|
|
87
|
+
runAs: z.string().optional().describe("The name of the service its tasks act as; absent, they act for this sandbox's owner."),
|
|
88
|
+
}),
|
|
89
|
+
lastUsedAt: z.number().optional().describe("When it was last used, epoch milliseconds; absent means never."),
|
|
90
|
+
waiting: z.number().int().nonnegative().describe("Tasks it handed over that wait for this sandbox's owner."),
|
|
91
|
+
});
|
|
92
|
+
export type ReachLinkIn = z.infer<typeof ReachLinkInSchema>;
|
|
93
|
+
|
|
94
|
+
/** A computer, phone or browser this sandbox's agents reach through a card of its own. */
|
|
95
|
+
export const ReachDeviceSchema = z.object({
|
|
96
|
+
card: z.string(),
|
|
97
|
+
kind: z.string().describe("computer, phone or browser."),
|
|
98
|
+
label: z.string().describe("What the owner calls it."),
|
|
99
|
+
machineId: z.string().optional().describe("The computer's own stable id, shared by every environment on it: the join key across sandboxes."),
|
|
100
|
+
hostname: z.string().optional().describe("Its OS host name, the join key when it has said no machine id."),
|
|
101
|
+
platform: z.string().optional().describe("windows, macos, linux, android, ios."),
|
|
102
|
+
online: z.boolean().optional().describe("Connected now; absent where nothing could say."),
|
|
103
|
+
grants: z.array(z.string()).describe("The card's switches that are on (REACH_DEVICE_GRANTS)."),
|
|
104
|
+
yours: yoursField,
|
|
105
|
+
others: othersField,
|
|
106
|
+
});
|
|
107
|
+
export type ReachDevice = z.infer<typeof ReachDeviceSchema>;
|
|
108
|
+
|
|
109
|
+
/** A server this sandbox's agents sign in to over SSH. */
|
|
110
|
+
export const ReachServerSchema = z.object({
|
|
111
|
+
card: z.string(),
|
|
112
|
+
host: z.string().describe("The host it dials, lowercased: the join key across sandboxes."),
|
|
113
|
+
user: z.string().optional(),
|
|
114
|
+
admin: z.boolean().describe("The card holds an admin password its agents may type to sudo or su."),
|
|
115
|
+
yours: yoursField,
|
|
116
|
+
others: othersField,
|
|
117
|
+
});
|
|
118
|
+
export type ReachServer = z.infer<typeof ReachServerSchema>;
|
|
119
|
+
|
|
120
|
+
export const SandboxReachSchema = z.object({
|
|
121
|
+
self: z.object({
|
|
122
|
+
sandboxId: z.string().optional().describe("This sandbox's platform id, as its last announce was answered; absent before one."),
|
|
123
|
+
runsOn: z
|
|
124
|
+
.object({ host: z.string().optional(), os: z.string().optional() })
|
|
125
|
+
.optional()
|
|
126
|
+
.describe("The machine this copy runs on and its side, as its host named them. Only for the owner and Full access."),
|
|
127
|
+
org: z
|
|
128
|
+
.object({ id: z.string(), name: z.string() })
|
|
129
|
+
.optional()
|
|
130
|
+
.describe("The organisation whose policy this daemon enforces here; absent for a personal sandbox."),
|
|
131
|
+
}),
|
|
132
|
+
reader: z.object({
|
|
133
|
+
tier: MemberTierSchema.describe("The reader's tier here, as this daemon enforces it now."),
|
|
134
|
+
agents: z.boolean().describe("Whether the reader's conversations here run agents."),
|
|
135
|
+
}),
|
|
136
|
+
linksOut: z.array(ReachLinkOutSchema),
|
|
137
|
+
linksIn: z.array(ReachLinkInSchema).optional().describe("Absent below Full access: minting and reading inbound links is theirs."),
|
|
138
|
+
devices: z.array(ReachDeviceSchema),
|
|
139
|
+
servers: z.array(ReachServerSchema),
|
|
140
|
+
fleet: z
|
|
141
|
+
.object({ yours: yoursField, others: othersField })
|
|
142
|
+
.optional()
|
|
143
|
+
.describe("This sandbox holds a fleet card: its agents may create and manage sandboxes on its owner's account."),
|
|
144
|
+
people: z
|
|
145
|
+
.number()
|
|
146
|
+
.int()
|
|
147
|
+
.nonnegative()
|
|
148
|
+
.optional()
|
|
149
|
+
.describe("How many other people may sign in here, the owner included when the reader is not them. Absent when the roster is not the reader's to read."),
|
|
150
|
+
readAt: z.number().describe("When this answer was put together, epoch milliseconds."),
|
|
151
|
+
});
|
|
152
|
+
export type SandboxReach = z.infer<typeof SandboxReachSchema>;
|
|
153
|
+
|
|
154
|
+
/** The host name of an address, lowercased, with no scheme, port, path or credentials: the join key two answers share. */
|
|
155
|
+
export const reachHostOf = (address: string): string =>
|
|
156
|
+
address
|
|
157
|
+
.trim()
|
|
158
|
+
.toLowerCase()
|
|
159
|
+
.replace(/^[a-z][a-z0-9+.-]*:\/\//, "")
|
|
160
|
+
.replace(/^[^@/]*@/, "")
|
|
161
|
+
.replace(/[/:?#].*$/, "");
|
package/src/schemas/secrets.ts
CHANGED
|
@@ -22,6 +22,16 @@ export const SecretKeysSchema = z.object({
|
|
|
22
22
|
export const SecretKeyParamSchema = z.object({ key: secretKey.describe("Which secret, by name.") });
|
|
23
23
|
export const SecretRevealSchema = z.object({ value: z.string().describe("The value itself. The only place in this API one is ever returned.") });
|
|
24
24
|
|
|
25
|
+
// (2026-11-25) A value the agent already holds the way to, moved into the store without passing through the chat or its
|
|
26
|
+
// own context: `secrets import NAME --stdin`, a value piped from where it lives now (another orchestrator's variables,
|
|
27
|
+
// a file on a server). A new name only, never one anything here holds: the agent token can add a credential and never
|
|
28
|
+
// replace one, so a value the owner stored cannot be swapped under the references that read it.
|
|
29
|
+
export const SECRET_IMPORT_MAX = 64_000;
|
|
30
|
+
export const SecretImportSchema = z.object({
|
|
31
|
+
key: secretKey.describe("The name to store it under: one nothing here holds yet."),
|
|
32
|
+
value: z.string().min(1).max(SECRET_IMPORT_MAX).describe("The value, as read from the command's input. Stored, never echoed or logged."),
|
|
33
|
+
});
|
|
34
|
+
|
|
25
35
|
// A secret nobody has to find or paste: a session key, a webhook signing secret, a database password the task sets up
|
|
26
36
|
// itself. The sandbox makes it and keeps it; the caller gets its reference and length, never the value.
|
|
27
37
|
// The shortest stored value the sandbox masks wherever it appears; a shorter one masks only in a secret-like context. The
|
|
@@ -72,9 +82,9 @@ export const CredentialGateKindSchema = z
|
|
|
72
82
|
export type CredentialGateKind = z.infer<typeof CredentialGateKindSchema>;
|
|
73
83
|
|
|
74
84
|
export const CredentialLaneSchema = z
|
|
75
|
-
.enum(["shell", "code", "browser", "session", "otp", "gateway", "ssh", "device", "desktop"])
|
|
85
|
+
.enum(["shell", "code", "browser", "session", "otp", "gateway", "ssh", "device", "desktop", "mcp"])
|
|
76
86
|
.describe(
|
|
77
|
-
"What the credential was about to be used for: a shell command, a script, typing into a page, mounting a connected account, one one-time code, a request the credential gateway attaches it to, a signature the sandbox's ssh agent makes with a held key, typing into a window or phone app on one of the owner's computers,
|
|
87
|
+
"What the credential was about to be used for: a shell command, a script, typing into a page, mounting a connected account, one one-time code, a request the credential gateway attaches it to, a signature the sandbox's ssh agent makes with a held key, typing into a window or phone app on one of the owner's computers, typing into a window on the sandbox's own desktop, or an argument of a tool call to an MCP server the owner connected.",
|
|
78
88
|
);
|
|
79
89
|
export type CredentialLane = z.infer<typeof CredentialLaneSchema>;
|
|
80
90
|
|
|
@@ -319,14 +329,14 @@ export const SecretInventoryEntrySchema = z.object({
|
|
|
319
329
|
.object({
|
|
320
330
|
at: z.number().describe("When, in milliseconds."),
|
|
321
331
|
lane: z
|
|
322
|
-
.enum(["shell", "code", "browser", "gateway", "ssh", "device", "desktop"])
|
|
332
|
+
.enum(["shell", "code", "browser", "gateway", "ssh", "device", "desktop", "mcp", "deploy"])
|
|
323
333
|
.describe(
|
|
324
|
-
"How it was used: a command, a script, typed into a page, attached by the credential gateway to a request the agent sent, a key the sandbox's ssh agent signed with for the agent, typed into a window or app on one of the owner's computers,
|
|
334
|
+
"How it was used: a command, a script, typed into a page, attached by the credential gateway to a request the agent sent, a key the sandbox's ssh agent signed with for the agent, typed into a window or app on one of the owner's computers, typed into a window on the sandbox's desktop, sent in a tool call to an MCP server the owner connected, or rendered by the sandbox into a managed stack's .env or registry login as it deployed it.",
|
|
325
335
|
),
|
|
326
336
|
detail: z
|
|
327
337
|
.string()
|
|
328
338
|
.optional()
|
|
329
|
-
.describe("Where it went: the start of the command or script, or the
|
|
339
|
+
.describe("Where it went: the start of the command or script, the site, the MCP tool and its server's host, or the stack and the computer it was deployed to. Names and destinations only, never values."),
|
|
330
340
|
approvedBy: z.string().optional().describe("Who released it for that use, when it is gated. Absent when nothing had to be approved."),
|
|
331
341
|
})
|
|
332
342
|
.optional()
|
|
@@ -376,3 +386,11 @@ export const SecretInventorySchema = z.object({
|
|
|
376
386
|
.array(SecretInventoryEntrySchema)
|
|
377
387
|
.describe("One entry per secret this sandbox knows about, from every place they live. No values, ever."),
|
|
378
388
|
});
|
|
389
|
+
|
|
390
|
+
// (2026-11-25) A keyed mark of each named value: an HMAC under a key this sandbox keeps in its auth root, never a plain
|
|
391
|
+
// hash, so a mark says nothing about the value to anyone without that key. A managed deploy answers the marks of the
|
|
392
|
+
// values it filled (device-stacks.ts); comparing them later with these tells the Deployments extension that a stack's
|
|
393
|
+
// secret changed in the store, without it ever holding one. A name nothing holds answers no mark.
|
|
394
|
+
export const SecretMarksRequestSchema = z.object({ names: z.array(secretKey).min(1).max(200) });
|
|
395
|
+
export const SecretMarksResponseSchema = z.object({ marks: z.record(z.string(), z.string()) });
|
|
396
|
+
export type SecretMarksResponse = z.infer<typeof SecretMarksResponseSchema>;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { z } from "zod";
|
|
2
2
|
import { at, drop, dropAll, fold, isJsonObject, type JsonObject, mapValue, rename, retype, transform } from "../documents/conversions.js";
|
|
3
|
-
import { type ModelRole,
|
|
3
|
+
import { type ModelRole, ROLES_BEFORE_CONTRIBUTIONS } from "../models/model-roles.js";
|
|
4
4
|
import { setupsFromRoleLists } from "../models/model-setups.js";
|
|
5
5
|
import { ModelPinSchema, type ModelPin } from "./agent.js";
|
|
6
6
|
import { RESTORE_POINT_KEEP_DAYS_DEFAULT } from "./data-protection.js";
|
|
@@ -84,18 +84,20 @@ const refactorsFromChores = transform(
|
|
|
84
84
|
// (`modelDefault`); it runs on a named setup it shares with other jobs. Jobs that held the same list share one setup, a
|
|
85
85
|
// list most of whose jobs are suggested a preset becomes that preset, and a job that held none, or an empty one, is on
|
|
86
86
|
// none, which runs it exactly as before: not at all. A list that does not read (a role this version does not know, a malformed pin) is left out rather than refusing
|
|
87
|
-
// the whole file, the same reading the schema gave it.
|
|
87
|
+
// the whole file, the same reading the schema gave it. The jobs it reads are the table's of 2026-11-26, frozen
|
|
88
|
+
// (ROLES_BEFORE_CONTRIBUTIONS): six of them moved to their extensions' manifests that day, and a file this converts still
|
|
89
|
+
// names them.
|
|
88
90
|
const PinList = z.array(ModelPinSchema);
|
|
89
91
|
const holdsRoleLists = (settings: JsonObject): settings is JsonObject => Object.hasOwn(settings, "modelRoles") || Object.hasOwn(settings, "modelDefault");
|
|
90
92
|
const roleListsIntoSetups = transform("folds modelRoles and modelDefault into setups (modelSetups, roleSetups)", holdsRoleLists, (settings): JsonObject => {
|
|
91
93
|
const { modelRoles, modelDefault, ...rest } = settings;
|
|
92
94
|
const fallback = PinList.safeParse(modelDefault);
|
|
93
95
|
const lists: Partial<Record<ModelRole, ModelPin[]>> = {};
|
|
94
|
-
for (const
|
|
95
|
-
const own = isJsonObject(modelRoles) ? PinList.safeParse(modelRoles[
|
|
96
|
+
for (const { id } of ROLES_BEFORE_CONTRIBUTIONS) {
|
|
97
|
+
const own = isJsonObject(modelRoles) ? PinList.safeParse(modelRoles[id]) : undefined;
|
|
96
98
|
const list = own?.success === true ? own.data : fallback.success && fallback.data.length > 0 ? fallback.data : undefined;
|
|
97
99
|
if (list !== undefined) {
|
|
98
|
-
lists[
|
|
100
|
+
lists[id] = list;
|
|
99
101
|
}
|
|
100
102
|
}
|
|
101
103
|
const { modelSetups, roleSetups } = setupsFromRoleLists(lists);
|
|
@@ -182,4 +184,7 @@ export const SETTINGS_HISTORY = [
|
|
|
182
184
|
...dropAll(["iqSearch", "iqSearchHoldout"]),
|
|
183
185
|
// Personas were renamed roles (2026-11-18): the switch that matches a new chat to one moves with them.
|
|
184
186
|
rename("personaRouting", "roleRouting"),
|
|
187
|
+
// Planning fan-outs by allowance became the only way (2026-11-25): off, a second child started on an account that could
|
|
188
|
+
// not carry it, ran its allowance out and waited for the reset anyway. `subagentReservePercent` at 0 is the loosest plan.
|
|
189
|
+
...dropAll(["subagentBudget"]),
|
|
185
190
|
] as const;
|
|
@@ -23,6 +23,35 @@ export const InputSavingsSchema = z.object({
|
|
|
23
23
|
holdout: z.object({ cleaned: z.number(), heldOut: z.number(), measuredSavedPct: z.number().optional() }),
|
|
24
24
|
// Grouped by command text: worth a handler is judged by total tokens across runs, not one outlier's size.
|
|
25
25
|
gaps: z.array(z.object({ command: z.string(), commands: z.number(), tokens: z.number() })),
|
|
26
|
+
// Harm: per stage, of the commands it trimmed, how many the model came back for (retrieve-output of the run's raw
|
|
27
|
+
// file, or the same command again within K), next to the held-out conversations' own re-run share. Absent when the
|
|
28
|
+
// ledger has no per-conversation rows.
|
|
29
|
+
harm: z
|
|
30
|
+
.object({
|
|
31
|
+
K: z.number(),
|
|
32
|
+
perStage: z.array(
|
|
33
|
+
z.object({
|
|
34
|
+
id: z.string(),
|
|
35
|
+
trimmed: z.number(),
|
|
36
|
+
retrieved: z.number(),
|
|
37
|
+
reRun: z.number(),
|
|
38
|
+
followedUp: z.number(),
|
|
39
|
+
harmRate: z.number(),
|
|
40
|
+
}),
|
|
41
|
+
),
|
|
42
|
+
heldOutReRun: z.object({ commands: z.number(), reRunRate: z.number() }).optional(),
|
|
43
|
+
caveat: z.string().optional(),
|
|
44
|
+
})
|
|
45
|
+
.optional(),
|
|
46
|
+
// Arm comparison: per-conversation tool calls and emitted bytes, cleaned vs held-out. Absent when fewer
|
|
47
|
+
// than 5 conversations per arm carry conversationHash.
|
|
48
|
+
arms: z
|
|
49
|
+
.object({
|
|
50
|
+
cleaned: z.object({ conversations: z.number(), medianCommands: z.number(), medianEmittedBytes: z.number() }),
|
|
51
|
+
heldOut: z.object({ conversations: z.number(), medianCommands: z.number(), medianEmittedBytes: z.number() }),
|
|
52
|
+
emittedBytesDeltaPct: z.number().optional(),
|
|
53
|
+
})
|
|
54
|
+
.optional(),
|
|
26
55
|
});
|
|
27
56
|
export type InputSavings = z.infer<typeof InputSavingsSchema>;
|
|
28
57
|
// One arm of a turn-level experiment; mean is per turn, since the two arms never hold the same count.
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { convertDocument } from "../documents/conversions.js";
|
|
2
|
-
import {
|
|
2
|
+
import { CORE_MODEL_ROLES, type ModelRole } from "../models/model-roles.js";
|
|
3
3
|
import { rolePins } from "../models/model-setups.js";
|
|
4
4
|
import { SETTINGS_HISTORY } from "./settings-history.js";
|
|
5
5
|
import { RepoChecksFileSchema, RuleSchema, SandboxSettingsSchema, SandboxSettingsWriteSchema } from "./settings.js";
|
|
@@ -156,7 +156,8 @@ describe(`the retired pre-push fix role`, () => {
|
|
|
156
156
|
|
|
157
157
|
test(`is dropped from a stored file, leaving every other job's list, and the file reads`, () => {
|
|
158
158
|
const stored = { modelRoles: { "pipeline-fix": [pin], "pre-push-fix": [pin] } };
|
|
159
|
-
|
|
159
|
+
// (2026-11-26) Any job's id reads since extensions declare their own, so a choice naming one nobody declares is kept.
|
|
160
|
+
expect(SandboxSettingsSchema.safeParse({ roleSetups: { "pre-push-fix": `high` } }).success).toBe(true);
|
|
160
161
|
expect(runsOn(stored, `pipeline-fix`)).toEqual([pin]);
|
|
161
162
|
});
|
|
162
163
|
});
|
|
@@ -244,6 +245,7 @@ test("build output defaults: six idle hours, reaping under 15% free, full debug
|
|
|
244
245
|
expect(defaults.buildOutputIdleHours).toBe(6);
|
|
245
246
|
expect(defaults.diskReapBelowPercent).toBe(15);
|
|
246
247
|
expect(defaults.leanRustBuilds).toBe(false);
|
|
248
|
+
expect(defaults.rustIncrementalOff).toBe(false);
|
|
247
249
|
expect(SandboxSettingsSchema.safeParse({ buildOutputIdleHours: 0 }).success).toBe(false);
|
|
248
250
|
expect(SandboxSettingsSchema.safeParse({ diskReapBelowPercent: 4 }).success).toBe(false);
|
|
249
251
|
});
|
|
@@ -277,17 +279,21 @@ describe(`restore points' retention, renamed so a stored zero is the owner's own
|
|
|
277
279
|
});
|
|
278
280
|
|
|
279
281
|
describe(`default job setups`, () => {
|
|
280
|
-
|
|
282
|
+
const sources = [{ provider: `claude`, ready: true, models: [`claude-haiku-4-5`, `claude-sonnet-5`, `claude-opus-5`] }] as const;
|
|
283
|
+
|
|
284
|
+
test(`new settings place no job, and every job runs on its suggested preset`, () => {
|
|
281
285
|
const settings = SandboxSettingsSchema.parse({});
|
|
282
|
-
expect(settings.roleSetups).
|
|
283
|
-
expect(
|
|
284
|
-
expect(settings.roleSetups[`safety-judge`]).toBe(`medium`);
|
|
285
|
-
expect(settings.roleSetups[`pipeline-fix`]).toBe(`high`);
|
|
286
|
-
const sources = [{ provider: `claude`, ready: true, models: [`claude-haiku-4-5`, `claude-sonnet-5`, `claude-opus-5`] }] as const;
|
|
286
|
+
expect(settings.roleSetups).toBeUndefined();
|
|
287
|
+
expect(CORE_MODEL_ROLES.find((role) => role.id === `commit-message`)?.setup).toBe(`low`);
|
|
287
288
|
expect(rolePins(settings, `commit-message`, sources)).toEqual([{ provider: `claude`, model: `claude-haiku-4-5` }]);
|
|
288
289
|
expect(rolePins(settings, `safety-judge`, sources)).toEqual([{ provider: `claude`, model: `claude-sonnet-5` }]);
|
|
289
|
-
expect(rolePins(settings, `
|
|
290
|
-
|
|
290
|
+
expect(rolePins(settings, `safety-judge`, [])).toEqual([]);
|
|
291
|
+
});
|
|
292
|
+
|
|
293
|
+
test(`an extension's job runs on what its declaration suggests, and a job nobody declares on none`, () => {
|
|
294
|
+
const settings = SandboxSettingsSchema.parse({});
|
|
295
|
+
expect(rolePins(settings, `pipeline-fix`, sources, `high`)).toEqual([{ provider: `claude`, model: `claude-opus-5` }]);
|
|
296
|
+
expect(rolePins(settings, `pipeline-fix`, sources)).toEqual([]);
|
|
291
297
|
});
|
|
292
298
|
|
|
293
299
|
test(`saved assignments keep their choices and jobs left off`, () => {
|
|
@@ -295,20 +301,15 @@ describe(`default job setups`, () => {
|
|
|
295
301
|
expect(SandboxSettingsSchema.parse({ roleSetups: { "commit-message": `high` } }).roleSetups).toEqual({ "commit-message": `high` });
|
|
296
302
|
const saved = SandboxSettingsSchema.parse({ roleSetups: {} });
|
|
297
303
|
expect(SandboxSettingsWriteSchema.parse({ ...saved, commandJudge: `watch` }).roleSetups).toEqual({});
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
// A memory kill's answer is on to begin with where the restart switch is off: the sandbox knows the cause, and lets its
|
|
302
|
-
// victims back one at a time once memory settles (turn-break.ts). Only the two answers it takes are written.
|
|
303
|
-
describe(`the answer to a memory kill`, () => {
|
|
304
|
-
test(`resumes by default, while resuming after any restart stays off`, () => {
|
|
305
|
-
const defaults = SandboxSettingsSchema.parse({});
|
|
306
|
-
expect(defaults.memoryKillPolicy).toBe(`resume`);
|
|
307
|
-
expect(defaults.autoResumeOnRestart).toBe(false);
|
|
304
|
+
// A saved map leaves a job it does not name on none, whatever it is suggested.
|
|
305
|
+
expect(rolePins(saved, `commit-message`, sources)).toEqual([]);
|
|
306
|
+
expect(rolePins(saved, `pipeline-fix`, sources, `high`)).toEqual([]);
|
|
308
307
|
});
|
|
309
308
|
|
|
310
|
-
test(`
|
|
311
|
-
|
|
312
|
-
|
|
309
|
+
test(`a choice for an extension's job is kept through a save, whether or not anything declares it now`, () => {
|
|
310
|
+
const saved = SandboxSettingsSchema.parse({ roleSetups: { "commit-message": `low`, "deployment-fix": `medium`, "saldeo-reconcile": `high` } });
|
|
311
|
+
const written = SandboxSettingsWriteSchema.parse({ ...saved, commandJudge: `watch` });
|
|
312
|
+
expect(written.roleSetups).toEqual({ "commit-message": `low`, "deployment-fix": `medium`, "saldeo-reconcile": `high` });
|
|
313
|
+
expect(rolePins(written, `deployment-fix`, sources)).toEqual([{ provider: `claude`, model: `claude-sonnet-5` }]);
|
|
313
314
|
});
|
|
314
315
|
});
|
package/src/schemas/settings.ts
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
import { z } from "zod";
|
|
3
3
|
import { claudeExperimentSettings } from "./settings-experiments.js";
|
|
4
4
|
import { CommandJudgeModeSchema, ProjectInstallModeSchema } from "../policy/safety-policy.js";
|
|
5
|
-
import {
|
|
5
|
+
import { ModelRoleSchema } from "../models/model-roles.js";
|
|
6
6
|
import { MODEL_SETUP_ID, ModelSetupSchema } from "../models/model-setups.js";
|
|
7
7
|
import { AdmissionPolicySchema, AdmissionRuleSchema } from "./command-admission.js";
|
|
8
8
|
import { KeepWarmSettingsSchema } from "./keep-warm.js";
|
|
@@ -159,6 +159,14 @@ export type SkillOrigin = z.infer<typeof SkillOriginSchema>;
|
|
|
159
159
|
// Same slug shape the SDK's loader accepts, checked here so a bad name is a refused save, not a skill that silently
|
|
160
160
|
// never loads.
|
|
161
161
|
export const SkillNameSchema = z.string().regex(/^[a-z0-9][a-z0-9-]*$/, "a skill name is lowercase letters, digits and dashes");
|
|
162
|
+
// Counted from the turns that loaded the skill (a skill tool call naming it, or a read of its SKILL.md), so a skill that
|
|
163
|
+
// is only listed never counts. A window, not a lifetime total: the question is whether it still earns its place.
|
|
164
|
+
export const SKILL_USES_WINDOW_DAYS = 7;
|
|
165
|
+
export const SkillUsesSchema = z.object({
|
|
166
|
+
week: z.number().int().nonnegative().describe("Turns that loaded it in the last seven days."),
|
|
167
|
+
last: z.string().optional().describe("When a turn last loaded it, as an ISO time. Absent when no turn has since the count began."),
|
|
168
|
+
});
|
|
169
|
+
export type SkillUses = z.infer<typeof SkillUsesSchema>;
|
|
162
170
|
export const SkillSummarySchema = z.object({
|
|
163
171
|
// Qualified as `<origin>:<owner>:<name>` for anything not `own`/`builtin`.
|
|
164
172
|
id: z
|
|
@@ -190,6 +198,10 @@ export const SkillSummarySchema = z.object({
|
|
|
190
198
|
// Wider than `editable` by one case: a dropped skill isn't the owner's to edit, but is theirs to remove, with no
|
|
191
199
|
// other way to short of the file tree.
|
|
192
200
|
removable: z.boolean(),
|
|
201
|
+
// Optional for the daemon-older-than-browser seam: a sandbox from before the count answers nothing, which is not zero.
|
|
202
|
+
uses: SkillUsesSchema.optional().describe(
|
|
203
|
+
"How often turns have loaded it lately. Absent where nothing counts (a sandbox from before the count), which is not the same as never.",
|
|
204
|
+
),
|
|
193
205
|
});
|
|
194
206
|
export type SkillSummary = z.infer<typeof SkillSummarySchema>;
|
|
195
207
|
export const SkillsListSchema = z.array(SkillSummarySchema);
|
|
@@ -200,6 +212,20 @@ export const SkillBodySchema = z.object({
|
|
|
200
212
|
name: z.string().describe("Its name."),
|
|
201
213
|
// Everything after the frontmatter.
|
|
202
214
|
body: z.string().describe("The instructions themselves, as written."),
|
|
215
|
+
// Only where the folder is what the agent reads, so a file opened from it is the file that matters: the loaded folder
|
|
216
|
+
// (a dropped skill, a connection's cheatsheet) or a role kit's. The owner's own skill is written through this
|
|
217
|
+
// contract instead, and a built-in's, an extension's or a plugin's lives outside the workspace.
|
|
218
|
+
folder: z
|
|
219
|
+
.string()
|
|
220
|
+
.optional()
|
|
221
|
+
.describe(
|
|
222
|
+
"The workspace-relative folder holding it, when that folder is what the agent reads. Absent for your own skills, which are written here rather than as files, and for anything kept outside the workspace.",
|
|
223
|
+
),
|
|
224
|
+
// Defaulted for the daemon-older-than-browser seam. Relative to the skill's folder, SKILL.md left out, capped.
|
|
225
|
+
files: z
|
|
226
|
+
.array(z.string())
|
|
227
|
+
.default([])
|
|
228
|
+
.describe("The other files in its folder (references, scripts, licences), relative to it, SKILL.md left out. Capped at 50."),
|
|
203
229
|
});
|
|
204
230
|
export type SkillBody = z.infer<typeof SkillBodySchema>;
|
|
205
231
|
export const SkillIdSchema = z.object({
|
|
@@ -393,14 +419,13 @@ export const SandboxSettingsSchema = z.object({
|
|
|
393
419
|
.describe(
|
|
394
420
|
"The model setups jobs run on: Low, Medium and High, which every sandbox has, and any you make. Each is an ordered list of models, tried in order so one spent account does not take its jobs down. A preset left out of this list, or listed without models, is worked out from the accounts you have connected. A setup runs only the jobs put on it (`roleSetups`).",
|
|
395
421
|
),
|
|
396
|
-
//
|
|
397
|
-
//
|
|
398
|
-
// map stays as written, including an empty one or a job removed from it.
|
|
422
|
+
// Any job's id, an extension's too, kept as written while it is off; absent until a job is placed, every job on its
|
|
423
|
+
// suggestion (2026-11-26: the schema wrote the core table at the first save, leaving later extensions' jobs on none).
|
|
399
424
|
roleSetups: z
|
|
400
|
-
.
|
|
401
|
-
.
|
|
425
|
+
.record(ModelRoleSchema, z.string().regex(MODEL_SETUP_ID))
|
|
426
|
+
.optional()
|
|
402
427
|
.describe(
|
|
403
|
-
"Which setup each job runs on: commit messages, session titles, the safety judge, pipeline fixes and every other place this sandbox picks a model for you.
|
|
428
|
+
"Which setup each job runs on: commit messages, session titles, the safety judge, the jobs your extensions start runs for (pipeline fixes, maintenance chores) and every other place this sandbox picks a model for you. Left out, every job runs on its suggested Low, Medium or High setup. In a saved map, a job left out, or on a setup with no models, has none, so a one-shot job does not run and a whole session opens on whatever your own chat is set to. A choice for an extension's job is kept while the extension is switched off.",
|
|
404
429
|
),
|
|
405
430
|
// Folded into the router's prompt (agent/prompt/chat-router.ts), never into a turn's own. Capped small on
|
|
406
431
|
// purpose: the reading runs under a 5s deadline, and this text is paid for on every chat that opens on Auto.
|
|
@@ -451,6 +476,16 @@ export const SandboxSettingsSchema = z.object({
|
|
|
451
476
|
.describe(
|
|
452
477
|
"Build Rust with line tables only for debug info (CARGO_PROFILE_DEV_DEBUG and CARGO_PROFILE_TEST_DEBUG set to `line-tables-only` in agents' shells). A debug target takes less disk and backtraces keep their file and line, but a debugger sees no local variables. It overrides what a repository's own Cargo.toml says about debug info.",
|
|
453
478
|
),
|
|
479
|
+
// Read live into every turn's shell (agent/run/harness/turn-env.ts); off by default, since it overrides a repository's
|
|
480
|
+
// own incremental setting and costs repeated rebuilds of one big crate. Measured 2026-11-24 (disk I/O audit on rog):
|
|
481
|
+
// the shinobi-society sandbox's Rust builds wrote 173 GB of the engine's 197 GB in 4.3 h, and each checkout's
|
|
482
|
+
// `target/debug/incremental/` held 0.15-12 GB rewritten on every compile; sccache cannot cache incremental crates.
|
|
483
|
+
rustIncrementalOff: z
|
|
484
|
+
.boolean()
|
|
485
|
+
.default(false)
|
|
486
|
+
.describe(
|
|
487
|
+
"Turn off Cargo's incremental compilation (CARGO_INCREMENTAL=0 in agents' shells). Builds stop writing each checkout's `target/debug/incremental/` (0.15-12 GB per checkout, rewritten on every compile) and the compiler cache can cache the workspace's own crates too. A repeated edit and rebuild of one big crate in the same checkout recompiles that crate whole. It overrides a repository's own `[profile] incremental` and CARGO_INCREMENTAL.",
|
|
488
|
+
),
|
|
454
489
|
commitAttribution: commitAttributionSetting,
|
|
455
490
|
// A prototype, off by default (2026-11-04): an isolated checkout's Cargo `target/` laid over a frozen copy of the main
|
|
456
491
|
// checkout's, so each checkout keeps only what it compiled differently (conversations/worktrees/cargo-warm.ts).
|
|
@@ -484,15 +519,14 @@ export const SandboxSettingsSchema = z.object({
|
|
|
484
519
|
memoryPolicy: RoomPolicySchema.default("resend").describe(
|
|
485
520
|
"What happens to a message the sandbox held because it was short of memory: nothing ran, so nothing was spent. `resend` sends it by itself once memory has stayed free for a while, one held conversation at a time. `wait` holds it until somebody presses Send anyway. The sandbox-wide default; any one conversation can say otherwise.",
|
|
486
521
|
),
|
|
487
|
-
//
|
|
488
|
-
//
|
|
489
|
-
//
|
|
490
|
-
//
|
|
491
|
-
//
|
|
492
|
-
//
|
|
493
|
-
//
|
|
494
|
-
//
|
|
495
|
-
// to avoid that would have re-run the cause too, all at once, into a machine still recovering.
|
|
522
|
+
// Both this and autoResumeOnRestart (below) re-run a turn which RAN without being asked, and both are on by default;
|
|
523
|
+
// they differ in what the sandbox knows. A restart is any cause (an update, a rebuild, a crash nobody named), and its
|
|
524
|
+
// switch resumes everything it cut, short of a restart storm. A memory kill is one named cause the sandbox can steer
|
|
525
|
+
// around: its turns go one at a time, only once memory has stayed free, never the turn whose own process was the one
|
|
526
|
+
// killed, and not after a second memory kill of the same request (MEMORY_KILL_RERUNS), so what comes back is the
|
|
527
|
+
// victims and not the runaway. Held for a press instead, every victim of the 2026-11-05 runaway sat in Attention with
|
|
528
|
+
// "autoResumeOnRestart is off" though only one conversation had caused it; and resuming everything the restart cut
|
|
529
|
+
// would have re-run the cause too, all at once, into a machine still recovering.
|
|
496
530
|
memoryKillPolicy: MemoryKillPolicySchema.default("resume").describe(
|
|
497
531
|
"What happens to a turn the sandbox killed because it ran out of memory, whether only that turn was killed or the whole sandbox restarted. `resume` sends it again by itself once memory has stayed free for a while, one conversation at a time, and tells it what happened. Never a turn whose own process was the one using the memory, and never one killed for memory twice already: those wait for a press whatever this says. `wait` holds every such turn until somebody presses Continue. After a restart that ran out of memory this decides for the turns it cut, instead of the switch for resuming after a restart. The sandbox-wide default; any one conversation can say otherwise.",
|
|
498
532
|
),
|
|
@@ -539,14 +573,14 @@ export const SandboxSettingsSchema = z.object({
|
|
|
539
573
|
),
|
|
540
574
|
// Worth it since the container is recreated on every update or environment approval — otherwise approving a
|
|
541
575
|
// Dockerfile change costs the run that asked for it.
|
|
542
|
-
//
|
|
543
|
-
//
|
|
544
|
-
//
|
|
576
|
+
// Deprecated (2026-11-26): main's fix agent moved to the pipelines extension, whose own `autoRepair` setting decides.
|
|
577
|
+
// Kept so an owner's choice is read once more, by the hand-over that writes it into that setting
|
|
578
|
+
// (ci/repair-hand-over.ts); nothing else reads it. Leaves with settings.json's next major conversion.
|
|
545
579
|
autoRepair: z
|
|
546
580
|
.boolean()
|
|
547
581
|
.default(true)
|
|
548
582
|
.describe(
|
|
549
|
-
"
|
|
583
|
+
"Deprecated: whether main's CI failing is repaired without asking is the Pipelines extension's own setting now. Read only to carry a choice made here into it.",
|
|
550
584
|
),
|
|
551
585
|
// What another writer pushes reaches the main tree within minutes instead of at the owner's next pull
|
|
552
586
|
// (git/remote/follow-origin.ts), so an agent whose work clashes with it meets the clash at its own land.
|
|
@@ -673,7 +707,7 @@ export const SandboxSettingsSchema = z.object({
|
|
|
673
707
|
// Three separate ceilings since they stop different things: width (parallel fan-out), lifetime (per conversation),
|
|
674
708
|
// depth (how far a child may delegate) — raising width alone just hits the lifetime cap sooner. Defaults mirror the
|
|
675
709
|
// CLI's own unset behavior; hitting one stops the agent rather than retrying.
|
|
676
|
-
subagentsAtOnce: z.number().min(1).max(200).default(20).describe("How many subagents may
|
|
710
|
+
subagentsAtOnce: z.number().min(1).max(200).default(20).describe("How many subagents one conversation may run at the same time."),
|
|
677
711
|
subagentsPerTurn: z.number().min(1).max(2000).default(200).describe("How many a single turn may start in total."),
|
|
678
712
|
// Depth 1 means an agent may delegate but its children may not; unlike the other two, a runaway here is
|
|
679
713
|
// multiplicative, not merely wide.
|
|
@@ -688,7 +722,6 @@ export const SandboxSettingsSchema = z.object({
|
|
|
688
722
|
childRerunHorizonHours: z.number().int().min(0).max(24).default(6).describe(
|
|
689
723
|
"How long a subagent refused for a spent allowance waits for the provider's reset before it goes again by itself. Past it, or at 0, it stops and its parent hears where else the work can go. One spawned with fallbacks waits at most 90 minutes and then moves to them.",
|
|
690
724
|
),
|
|
691
|
-
subagentBudget: z.boolean().default(true).describe("Start a subagent only where an account's allowance can carry it through its windows, on the account whose allowance renews first among those that can carry it, since what is left of an allowance at its reset is lost. The rest wait as pending and start by themselves as running ones end or a window reopens. Off, every subagent starts at once, on the account that renews first or, where none carries it, the one that holds out longest."),
|
|
692
725
|
subagentReservePercent: z.number().int().min(0).max(50).default(10).describe("How much of each allowance window, in points of 100, subagents leave for your own conversations: a fan-out is planned against what is left past it."),
|
|
693
726
|
// Width again, for a team-chat automation rather than a turn: each thread a message lands in is a conversation of
|
|
694
727
|
// its own, and threads of one automation are worked on side by side up to this many (automations/scheduler.ts in
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
import { z } from "zod";
|
|
2
|
+
import { StackNameSchema } from "./device-stacks.js";
|
|
3
|
+
|
|
4
|
+
/* WHICH SECRETS A STACK MAY RECEIVE (2026-11-25). Managed stacks are the Deployments extension's: its engine reads a
|
|
5
|
+
repository's stacks manifest, queues, triggers, rolls back (extensions/deployments). The one thing it cannot do is
|
|
6
|
+
hold a secret's value, so a managed deploy (device-stacks.ts DeviceStackManagedDeployInputSchema) sends `{{secret:…}}`
|
|
7
|
+
references and the daemon fills them, but only the names the OWNER granted that stack, on that computer, from that
|
|
8
|
+
repository. A grant lives in the auth root, where no agent and no extension can write it; an agent asks for one on a
|
|
9
|
+
card (a `deploy` need), the owner's press writes it, and the Deployments board's owner-only button does the same. */
|
|
10
|
+
|
|
11
|
+
// A stack, from a repository, on one computer (its device card's id): what a grant is for. Moving a stack to another
|
|
12
|
+
// computer, or declaring it in another repository, needs a grant of its own.
|
|
13
|
+
export const StackGrantRefSchema = z.object({
|
|
14
|
+
repo: z.string().min(1).max(500),
|
|
15
|
+
stack: StackNameSchema,
|
|
16
|
+
device: z.string().min(1).max(200),
|
|
17
|
+
});
|
|
18
|
+
export type StackGrantRef = z.infer<typeof StackGrantRefSchema>;
|
|
19
|
+
|
|
20
|
+
const SecretNameSchema = z.string().regex(/^[A-Za-z0-9_./-]{1,200}$/, "a secret's name as `{{secret:NAME}}` writes it");
|
|
21
|
+
|
|
22
|
+
export const StackGrantSchema = StackGrantRefSchema.extend({
|
|
23
|
+
secrets: z.array(z.string()),
|
|
24
|
+
grantedBy: z.string().optional(),
|
|
25
|
+
grantedAt: z.string(),
|
|
26
|
+
});
|
|
27
|
+
export type StackGrant = z.infer<typeof StackGrantSchema>;
|
|
28
|
+
|
|
29
|
+
export const StackGrantsResponseSchema = z.object({ grants: z.array(StackGrantSchema) });
|
|
30
|
+
export type StackGrantsResponse = z.infer<typeof StackGrantsResponseSchema>;
|
|
31
|
+
|
|
32
|
+
// The owner's grant: exactly these names, added to what the stack already holds there.
|
|
33
|
+
export const StackGrantSetSchema = StackGrantRefSchema.extend({ secrets: z.array(SecretNameSchema).min(1).max(100) });
|
|
34
|
+
export type StackGrantSet = z.infer<typeof StackGrantSetSchema>;
|
|
35
|
+
|
|
36
|
+
// An agent's ask: a card in its conversation listing the names; answered as a raised need is (needs.ts NeedRaisedSchema).
|
|
37
|
+
export const StackGrantRequestSchema = StackGrantSetSchema.extend({ why: z.string().max(280).optional() });
|
|
38
|
+
export type StackGrantRequest = z.infer<typeof StackGrantRequestSchema>;
|
|
39
|
+
|
|
40
|
+
// The owner's card (needs.ts, kind `deploy`). Only the owner, or someone with Full access, signed in, can press it, and
|
|
41
|
+
// a yes grants exactly the names the card showed, on the computer it showed.
|
|
42
|
+
export const DeployNeedSchema = z.object({
|
|
43
|
+
kind: z.literal("deploy"),
|
|
44
|
+
repo: z.string().min(1).max(500).describe("The repository that declares the stack, workspace-relative."),
|
|
45
|
+
stack: StackNameSchema.describe("The stack's name."),
|
|
46
|
+
device: z.string().min(1).max(200).describe("The computer it deploys to, by its device card: a grant is for that computer alone."),
|
|
47
|
+
deviceName: z.string().max(200).optional().describe("That computer's name, for the card."),
|
|
48
|
+
secrets: z.array(z.string()).describe("The secret names a yes grants it."),
|
|
49
|
+
ungranted: z.array(z.string()).describe("Those it has not been granted yet, when the card was raised."),
|
|
50
|
+
});
|
|
51
|
+
export type DeployNeed = z.infer<typeof DeployNeedSchema>;
|
|
52
|
+
// What an agent sends: the stack and the names (`secrets grant-stack`).
|
|
53
|
+
export const DeployNeedAskSchema = z.object({
|
|
54
|
+
kind: z.literal("deploy"),
|
|
55
|
+
repo: z.string().min(1).max(500),
|
|
56
|
+
stack: StackNameSchema,
|
|
57
|
+
device: z.string().min(1).max(200),
|
|
58
|
+
secrets: z.array(SecretNameSchema).min(1).max(100),
|
|
59
|
+
});
|
|
@@ -5,7 +5,7 @@ import { packageRoot } from "@intentic/constants/node";
|
|
|
5
5
|
import { STATE_PLAN_FORMAT, type StatePlan, StatePlanSchema, type StateStatus, StateStatusSchema } from "./state-plan.js";
|
|
6
6
|
|
|
7
7
|
// The documents `ic` reads by field name, spelled once here: each golden file under golden/ is one of these examples
|
|
8
|
-
// as JSON, and the Rust tests (
|
|
8
|
+
// as JSON, and the Rust tests (_hosts/ic/src/sandbox/preflight.rs, health.rs) parse the same files. A change here
|
|
9
9
|
// that the committed file does not carry fails, naming the file; `INTENTIC_WRITE_GOLDEN=1` rewrites them, and the Rust
|
|
10
10
|
// tests then say whether ic still reads them.
|
|
11
11
|
|