@microvac/adapter-utils 0.0.0-stage → 0.1.0-rc.14
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 +69 -2
- package/dist/acpx-engine/accounting-model.d.ts +7 -0
- package/dist/acpx-engine/accounting-model.d.ts.map +1 -0
- package/dist/acpx-engine/accounting-model.js +12 -0
- package/dist/acpx-engine/accounting-model.js.map +1 -0
- package/dist/acpx-engine/accounting-model.test.d.ts +2 -0
- package/dist/acpx-engine/accounting-model.test.d.ts.map +1 -0
- package/dist/acpx-engine/accounting-model.test.js +28 -0
- package/dist/acpx-engine/accounting-model.test.js.map +1 -0
- package/dist/acpx-engine/cli.d.ts +2 -0
- package/dist/acpx-engine/cli.d.ts.map +1 -0
- package/dist/acpx-engine/cli.js +128 -0
- package/dist/acpx-engine/cli.js.map +1 -0
- package/dist/acpx-engine/constants.d.ts +28 -0
- package/dist/acpx-engine/constants.d.ts.map +1 -0
- package/dist/acpx-engine/constants.js +74 -0
- package/dist/acpx-engine/constants.js.map +1 -0
- package/dist/acpx-engine/ephemeral-session-environment.d.ts +4 -0
- package/dist/acpx-engine/ephemeral-session-environment.d.ts.map +1 -0
- package/dist/acpx-engine/ephemeral-session-environment.js +45 -0
- package/dist/acpx-engine/ephemeral-session-environment.js.map +1 -0
- package/dist/acpx-engine/ephemeral-session-environment.test.d.ts +2 -0
- package/dist/acpx-engine/ephemeral-session-environment.test.d.ts.map +1 -0
- package/dist/acpx-engine/ephemeral-session-environment.test.js +219 -0
- package/dist/acpx-engine/ephemeral-session-environment.test.js.map +1 -0
- package/dist/acpx-engine/execute-identity.test.d.ts +2 -0
- package/dist/acpx-engine/execute-identity.test.d.ts.map +1 -0
- package/dist/acpx-engine/execute-identity.test.js +218 -0
- package/dist/acpx-engine/execute-identity.test.js.map +1 -0
- package/dist/acpx-engine/execute.d.ts +366 -0
- package/dist/acpx-engine/execute.d.ts.map +1 -0
- package/dist/acpx-engine/execute.js +5021 -0
- package/dist/acpx-engine/execute.js.map +1 -0
- package/dist/acpx-engine/execute.test.d.ts +2 -0
- package/dist/acpx-engine/execute.test.d.ts.map +1 -0
- package/dist/acpx-engine/execute.test.js +8269 -0
- package/dist/acpx-engine/execute.test.js.map +1 -0
- package/dist/acpx-engine/filesystem-protocol.test.d.ts +2 -0
- package/dist/acpx-engine/filesystem-protocol.test.d.ts.map +1 -0
- package/dist/acpx-engine/filesystem-protocol.test.js +96 -0
- package/dist/acpx-engine/filesystem-protocol.test.js.map +1 -0
- package/dist/acpx-engine/index.d.ts +6 -0
- package/dist/acpx-engine/index.d.ts.map +1 -0
- package/dist/acpx-engine/index.js +6 -0
- package/dist/acpx-engine/index.js.map +1 -0
- package/dist/acpx-engine/local-process-control.d.ts +5 -0
- package/dist/acpx-engine/local-process-control.d.ts.map +1 -0
- package/dist/acpx-engine/local-process-control.js +39 -0
- package/dist/acpx-engine/local-process-control.js.map +1 -0
- package/dist/acpx-engine/local-process-control.test.d.ts +2 -0
- package/dist/acpx-engine/local-process-control.test.d.ts.map +1 -0
- package/dist/acpx-engine/local-process-control.test.js +38 -0
- package/dist/acpx-engine/local-process-control.test.js.map +1 -0
- package/dist/acpx-engine/operator-stop.test.d.ts +2 -0
- package/dist/acpx-engine/operator-stop.test.d.ts.map +1 -0
- package/dist/acpx-engine/operator-stop.test.js +107 -0
- package/dist/acpx-engine/operator-stop.test.js.map +1 -0
- package/dist/acpx-engine/remote-spawn-smoke.test.d.ts +2 -0
- package/dist/acpx-engine/remote-spawn-smoke.test.d.ts.map +1 -0
- package/dist/acpx-engine/remote-spawn-smoke.test.js +152 -0
- package/dist/acpx-engine/remote-spawn-smoke.test.js.map +1 -0
- package/dist/acpx-engine/run-contracts.d.ts +414 -0
- package/dist/acpx-engine/run-contracts.d.ts.map +1 -0
- package/dist/acpx-engine/run-contracts.js +20 -0
- package/dist/acpx-engine/run-contracts.js.map +1 -0
- package/dist/acpx-engine/run-contracts.test.d.ts +2 -0
- package/dist/acpx-engine/run-contracts.test.d.ts.map +1 -0
- package/dist/acpx-engine/run-contracts.test.js +57 -0
- package/dist/acpx-engine/run-contracts.test.js.map +1 -0
- package/dist/acpx-engine/run-coordinator.d.ts +57 -0
- package/dist/acpx-engine/run-coordinator.d.ts.map +1 -0
- package/dist/acpx-engine/run-coordinator.js +63 -0
- package/dist/acpx-engine/run-coordinator.js.map +1 -0
- package/dist/acpx-engine/run-coordinator.test.d.ts +2 -0
- package/dist/acpx-engine/run-coordinator.test.d.ts.map +1 -0
- package/dist/acpx-engine/run-coordinator.test.js +160 -0
- package/dist/acpx-engine/run-coordinator.test.js.map +1 -0
- package/dist/acpx-engine/run-fault-matrix.test.d.ts +2 -0
- package/dist/acpx-engine/run-fault-matrix.test.d.ts.map +1 -0
- package/dist/acpx-engine/run-fault-matrix.test.js +877 -0
- package/dist/acpx-engine/run-fault-matrix.test.js.map +1 -0
- package/dist/acpx-engine/run-resource-ledger.d.ts +30 -0
- package/dist/acpx-engine/run-resource-ledger.d.ts.map +1 -0
- package/dist/acpx-engine/run-resource-ledger.js +148 -0
- package/dist/acpx-engine/run-resource-ledger.js.map +1 -0
- package/dist/acpx-engine/run-resource-ledger.test.d.ts +2 -0
- package/dist/acpx-engine/run-resource-ledger.test.d.ts.map +1 -0
- package/dist/acpx-engine/run-resource-ledger.test.js +154 -0
- package/dist/acpx-engine/run-resource-ledger.test.js.map +1 -0
- package/dist/acpx-engine/run-site-host.d.ts +78 -0
- package/dist/acpx-engine/run-site-host.d.ts.map +1 -0
- package/dist/acpx-engine/run-site-host.js +65 -0
- package/dist/acpx-engine/run-site-host.js.map +1 -0
- package/dist/acpx-engine/run-site-host.test.d.ts +2 -0
- package/dist/acpx-engine/run-site-host.test.d.ts.map +1 -0
- package/dist/acpx-engine/run-site-host.test.js +98 -0
- package/dist/acpx-engine/run-site-host.test.js.map +1 -0
- package/dist/acpx-engine/run-site-sandbox.d.ts +155 -0
- package/dist/acpx-engine/run-site-sandbox.d.ts.map +1 -0
- package/dist/acpx-engine/run-site-sandbox.js +285 -0
- package/dist/acpx-engine/run-site-sandbox.js.map +1 -0
- package/dist/acpx-engine/run-site-sandbox.test.d.ts +2 -0
- package/dist/acpx-engine/run-site-sandbox.test.d.ts.map +1 -0
- package/dist/acpx-engine/run-site-sandbox.test.js +307 -0
- package/dist/acpx-engine/run-site-sandbox.test.js.map +1 -0
- package/dist/acpx-engine/session-codec.d.ts +3 -0
- package/dist/acpx-engine/session-codec.d.ts.map +1 -0
- package/dist/acpx-engine/session-codec.js +50 -0
- package/dist/acpx-engine/session-codec.js.map +1 -0
- package/dist/acpx-engine/session-reuse-store.d.ts +62 -0
- package/dist/acpx-engine/session-reuse-store.d.ts.map +1 -0
- package/dist/acpx-engine/session-reuse-store.js +134 -0
- package/dist/acpx-engine/session-reuse-store.js.map +1 -0
- package/dist/acpx-engine/session-reuse-store.test.d.ts +2 -0
- package/dist/acpx-engine/session-reuse-store.test.d.ts.map +1 -0
- package/dist/acpx-engine/session-reuse-store.test.js +134 -0
- package/dist/acpx-engine/session-reuse-store.test.js.map +1 -0
- package/dist/acpx-engine/settlement-sequence.d.ts +77 -0
- package/dist/acpx-engine/settlement-sequence.d.ts.map +1 -0
- package/dist/acpx-engine/settlement-sequence.js +119 -0
- package/dist/acpx-engine/settlement-sequence.js.map +1 -0
- package/dist/acpx-engine/settlement-sequence.test.d.ts +2 -0
- package/dist/acpx-engine/settlement-sequence.test.d.ts.map +1 -0
- package/dist/acpx-engine/settlement-sequence.test.js +272 -0
- package/dist/acpx-engine/settlement-sequence.test.js.map +1 -0
- package/dist/acpx-engine/spawn-smoke.test.d.ts +2 -0
- package/dist/acpx-engine/spawn-smoke.test.d.ts.map +1 -0
- package/dist/acpx-engine/spawn-smoke.test.js +193 -0
- package/dist/acpx-engine/spawn-smoke.test.js.map +1 -0
- package/dist/acpx-engine/startup-cancellation.d.ts +9 -0
- package/dist/acpx-engine/startup-cancellation.d.ts.map +1 -0
- package/dist/acpx-engine/startup-cancellation.js +97 -0
- package/dist/acpx-engine/startup-cancellation.js.map +1 -0
- package/dist/acpx-engine/startup-cancellation.test.d.ts +2 -0
- package/dist/acpx-engine/startup-cancellation.test.d.ts.map +1 -0
- package/dist/acpx-engine/startup-cancellation.test.js +115 -0
- package/dist/acpx-engine/startup-cancellation.test.js.map +1 -0
- package/dist/acpx-engine/startup-timing.d.ts +433 -0
- package/dist/acpx-engine/startup-timing.d.ts.map +1 -0
- package/dist/acpx-engine/startup-timing.js +631 -0
- package/dist/acpx-engine/startup-timing.js.map +1 -0
- package/dist/acpx-engine/startup-timing.test.d.ts +2 -0
- package/dist/acpx-engine/startup-timing.test.d.ts.map +1 -0
- package/dist/acpx-engine/startup-timing.test.js +619 -0
- package/dist/acpx-engine/startup-timing.test.js.map +1 -0
- package/dist/acpx-engine/stock-runtime-options.d.ts +37 -0
- package/dist/acpx-engine/stock-runtime-options.d.ts.map +1 -0
- package/dist/acpx-engine/stock-runtime-options.js +101 -0
- package/dist/acpx-engine/stock-runtime-options.js.map +1 -0
- package/dist/acpx-engine/stock-runtime-options.test.d.ts +2 -0
- package/dist/acpx-engine/stock-runtime-options.test.d.ts.map +1 -0
- package/dist/acpx-engine/stock-runtime-options.test.js +91 -0
- package/dist/acpx-engine/stock-runtime-options.test.js.map +1 -0
- package/dist/acpx-engine/terminal-session-failure.d.ts +48 -0
- package/dist/acpx-engine/terminal-session-failure.d.ts.map +1 -0
- package/dist/acpx-engine/terminal-session-failure.js +123 -0
- package/dist/acpx-engine/terminal-session-failure.js.map +1 -0
- package/dist/acpx-engine/terminal-session-failure.test.d.ts +2 -0
- package/dist/acpx-engine/terminal-session-failure.test.d.ts.map +1 -0
- package/dist/acpx-engine/terminal-session-failure.test.js +150 -0
- package/dist/acpx-engine/terminal-session-failure.test.js.map +1 -0
- package/dist/acpx-engine/turn-sequence.d.ts +54 -0
- package/dist/acpx-engine/turn-sequence.d.ts.map +1 -0
- package/dist/acpx-engine/turn-sequence.js +75 -0
- package/dist/acpx-engine/turn-sequence.js.map +1 -0
- package/dist/acpx-engine/turn-sequence.test.d.ts +2 -0
- package/dist/acpx-engine/turn-sequence.test.d.ts.map +1 -0
- package/dist/acpx-engine/turn-sequence.test.js +177 -0
- package/dist/acpx-engine/turn-sequence.test.js.map +1 -0
- package/dist/acpx-engine/ui.d.ts +3 -0
- package/dist/acpx-engine/ui.d.ts.map +1 -0
- package/dist/acpx-engine/ui.js +162 -0
- package/dist/acpx-engine/ui.js.map +1 -0
- package/dist/agent-observability.d.ts +25 -0
- package/dist/agent-observability.d.ts.map +1 -0
- package/dist/agent-observability.js +92 -0
- package/dist/agent-observability.js.map +1 -0
- package/dist/agent-observability.test.d.ts +2 -0
- package/dist/agent-observability.test.d.ts.map +1 -0
- package/dist/agent-observability.test.js +127 -0
- package/dist/agent-observability.test.js.map +1 -0
- package/dist/api-billing-type.d.ts +5 -0
- package/dist/api-billing-type.d.ts.map +1 -0
- package/dist/api-billing-type.js +16 -0
- package/dist/api-billing-type.js.map +1 -0
- package/dist/api-billing-type.test.d.ts +2 -0
- package/dist/api-billing-type.test.d.ts.map +1 -0
- package/dist/api-billing-type.test.js +20 -0
- package/dist/api-billing-type.test.js.map +1 -0
- package/dist/billing.d.ts +9 -0
- package/dist/billing.d.ts.map +1 -0
- package/dist/billing.js +39 -0
- package/dist/billing.js.map +1 -0
- package/dist/billing.test.d.ts +2 -0
- package/dist/billing.test.d.ts.map +1 -0
- package/dist/billing.test.js +30 -0
- package/dist/billing.test.js.map +1 -0
- package/dist/bridge-transport-contract.d.ts +43 -0
- package/dist/bridge-transport-contract.d.ts.map +1 -0
- package/dist/bridge-transport-contract.js +33 -0
- package/dist/bridge-transport-contract.js.map +1 -0
- package/dist/chat-file-delivery.d.ts +10 -0
- package/dist/chat-file-delivery.d.ts.map +1 -0
- package/dist/chat-file-delivery.js +39 -0
- package/dist/chat-file-delivery.js.map +1 -0
- package/dist/chat-file-delivery.test.d.ts +2 -0
- package/dist/chat-file-delivery.test.d.ts.map +1 -0
- package/dist/chat-file-delivery.test.js +92 -0
- package/dist/chat-file-delivery.test.js.map +1 -0
- package/dist/codex-observability-home.d.ts +7 -0
- package/dist/codex-observability-home.d.ts.map +1 -0
- package/dist/codex-observability-home.js +75 -0
- package/dist/codex-observability-home.js.map +1 -0
- package/dist/codex-observability-profile.d.ts +16 -0
- package/dist/codex-observability-profile.d.ts.map +1 -0
- package/dist/codex-observability-profile.js +51 -0
- package/dist/codex-observability-profile.js.map +1 -0
- package/dist/codex-shell-environment.d.ts +6 -0
- package/dist/codex-shell-environment.d.ts.map +1 -0
- package/dist/codex-shell-environment.js +32 -0
- package/dist/codex-shell-environment.js.map +1 -0
- package/dist/codex-shell-environment.test.d.ts +2 -0
- package/dist/codex-shell-environment.test.d.ts.map +1 -0
- package/dist/codex-shell-environment.test.js +49 -0
- package/dist/codex-shell-environment.test.js.map +1 -0
- package/dist/command-managed-runtime.d.ts +178 -0
- package/dist/command-managed-runtime.d.ts.map +1 -0
- package/dist/command-managed-runtime.js +486 -0
- package/dist/command-managed-runtime.js.map +1 -0
- package/dist/command-managed-runtime.test.d.ts +2 -0
- package/dist/command-managed-runtime.test.d.ts.map +1 -0
- package/dist/command-managed-runtime.test.js +900 -0
- package/dist/command-managed-runtime.test.js.map +1 -0
- package/dist/command-redaction.d.ts +32 -0
- package/dist/command-redaction.d.ts.map +1 -0
- package/dist/command-redaction.js +280 -0
- package/dist/command-redaction.js.map +1 -0
- package/dist/command-redaction.test.d.ts +2 -0
- package/dist/command-redaction.test.d.ts.map +1 -0
- package/dist/command-redaction.test.js +297 -0
- package/dist/command-redaction.test.js.map +1 -0
- package/dist/connection-failure.d.ts +33 -0
- package/dist/connection-failure.d.ts.map +1 -0
- package/dist/connection-failure.js +43 -0
- package/dist/connection-failure.js.map +1 -0
- package/dist/connection-failure.test.d.ts +2 -0
- package/dist/connection-failure.test.d.ts.map +1 -0
- package/dist/connection-failure.test.js +94 -0
- package/dist/connection-failure.test.js.map +1 -0
- package/dist/directory-merge-lock-diagnostics.d.ts +24 -0
- package/dist/directory-merge-lock-diagnostics.d.ts.map +1 -0
- package/dist/directory-merge-lock-diagnostics.js +54 -0
- package/dist/directory-merge-lock-diagnostics.js.map +1 -0
- package/dist/directory-merge-lock-diagnostics.test.d.ts +2 -0
- package/dist/directory-merge-lock-diagnostics.test.d.ts.map +1 -0
- package/dist/directory-merge-lock-diagnostics.test.js +44 -0
- package/dist/directory-merge-lock-diagnostics.test.js.map +1 -0
- package/dist/directory-merge-lock.test.d.ts +2 -0
- package/dist/directory-merge-lock.test.d.ts.map +1 -0
- package/dist/directory-merge-lock.test.js +168 -0
- package/dist/directory-merge-lock.test.js.map +1 -0
- package/dist/duplex-frame-codec.d.ts +124 -0
- package/dist/duplex-frame-codec.d.ts.map +1 -0
- package/dist/duplex-frame-codec.js +134 -0
- package/dist/duplex-frame-codec.js.map +1 -0
- package/dist/duplex-frame-codec.test.d.ts +2 -0
- package/dist/duplex-frame-codec.test.d.ts.map +1 -0
- package/dist/duplex-frame-codec.test.js +172 -0
- package/dist/duplex-frame-codec.test.js.map +1 -0
- package/dist/duplex-observability.d.ts +220 -0
- package/dist/duplex-observability.d.ts.map +1 -0
- package/dist/duplex-observability.js +248 -0
- package/dist/duplex-observability.js.map +1 -0
- package/dist/duplex-observability.test.d.ts +2 -0
- package/dist/duplex-observability.test.d.ts.map +1 -0
- package/dist/duplex-observability.test.js +55 -0
- package/dist/duplex-observability.test.js.map +1 -0
- package/dist/env-bindings.d.ts +17 -0
- package/dist/env-bindings.d.ts.map +1 -0
- package/dist/env-bindings.js +98 -0
- package/dist/env-bindings.js.map +1 -0
- package/dist/env-bindings.test.d.ts +2 -0
- package/dist/env-bindings.test.d.ts.map +1 -0
- package/dist/env-bindings.test.js +66 -0
- package/dist/env-bindings.test.js.map +1 -0
- package/dist/exclude-patterns.d.ts +13 -0
- package/dist/exclude-patterns.d.ts.map +1 -0
- package/dist/exclude-patterns.js +37 -0
- package/dist/exclude-patterns.js.map +1 -0
- package/dist/execution-phase.d.ts +10 -0
- package/dist/execution-phase.d.ts.map +1 -0
- package/dist/execution-phase.js +27 -0
- package/dist/execution-phase.js.map +1 -0
- package/dist/execution-phase.test.d.ts +2 -0
- package/dist/execution-phase.test.d.ts.map +1 -0
- package/dist/execution-phase.test.js +26 -0
- package/dist/execution-phase.test.js.map +1 -0
- package/dist/execution-target-sandbox.test.d.ts +2 -0
- package/dist/execution-target-sandbox.test.d.ts.map +1 -0
- package/dist/execution-target-sandbox.test.js +5599 -0
- package/dist/execution-target-sandbox.test.js.map +1 -0
- package/dist/execution-target-stdin-race.test.d.ts +2 -0
- package/dist/execution-target-stdin-race.test.d.ts.map +1 -0
- package/dist/execution-target-stdin-race.test.js +2166 -0
- package/dist/execution-target-stdin-race.test.js.map +1 -0
- package/dist/execution-target.d.ts +604 -0
- package/dist/execution-target.d.ts.map +1 -0
- package/dist/execution-target.js +4018 -0
- package/dist/execution-target.js.map +1 -0
- package/dist/execution-target.test.d.ts +2 -0
- package/dist/execution-target.test.d.ts.map +1 -0
- package/dist/execution-target.test.js +404 -0
- package/dist/execution-target.test.js.map +1 -0
- package/dist/git-shallow-import-budget.test.d.ts +2 -0
- package/dist/git-shallow-import-budget.test.d.ts.map +1 -0
- package/dist/git-shallow-import-budget.test.js +72 -0
- package/dist/git-shallow-import-budget.test.js.map +1 -0
- package/dist/git-workspace-sync.d.ts +224 -0
- package/dist/git-workspace-sync.d.ts.map +1 -0
- package/dist/git-workspace-sync.js +1081 -0
- package/dist/git-workspace-sync.js.map +1 -0
- package/dist/git-workspace-sync.test.d.ts +2 -0
- package/dist/git-workspace-sync.test.d.ts.map +1 -0
- package/dist/git-workspace-sync.test.js +1262 -0
- package/dist/git-workspace-sync.test.js.map +1 -0
- package/dist/github-launcher-environment.test.d.ts +2 -0
- package/dist/github-launcher-environment.test.d.ts.map +1 -0
- package/dist/github-launcher-environment.test.js +557 -0
- package/dist/github-launcher-environment.test.js.map +1 -0
- package/dist/github-launcher.d.ts +12 -0
- package/dist/github-launcher.d.ts.map +1 -0
- package/dist/github-launcher.js +240 -0
- package/dist/github-launcher.js.map +1 -0
- package/dist/github-launcher.test.d.ts +2 -0
- package/dist/github-launcher.test.d.ts.map +1 -0
- package/dist/github-launcher.test.js +608 -0
- package/dist/github-launcher.test.js.map +1 -0
- package/dist/http2-bridge-server.d.ts +464 -0
- package/dist/http2-bridge-server.d.ts.map +1 -0
- package/dist/http2-bridge-server.js +1086 -0
- package/dist/http2-bridge-server.js.map +1 -0
- package/dist/http2-bridge-server.test.d.ts +2 -0
- package/dist/http2-bridge-server.test.d.ts.map +1 -0
- package/dist/http2-bridge-server.test.js +2183 -0
- package/dist/http2-bridge-server.test.js.map +1 -0
- package/dist/index.d.ts +20 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +12 -0
- package/dist/index.js.map +1 -0
- package/dist/local-process-sandbox.d.ts +41 -0
- package/dist/local-process-sandbox.d.ts.map +1 -0
- package/dist/local-process-sandbox.js +432 -0
- package/dist/local-process-sandbox.js.map +1 -0
- package/dist/local-process-sandbox.test.d.ts +2 -0
- package/dist/local-process-sandbox.test.d.ts.map +1 -0
- package/dist/local-process-sandbox.test.js +399 -0
- package/dist/local-process-sandbox.test.js.map +1 -0
- package/dist/log-redaction.d.ts +9 -0
- package/dist/log-redaction.d.ts.map +1 -0
- package/dist/log-redaction.js +88 -0
- package/dist/log-redaction.js.map +1 -0
- package/dist/login-capability.d.ts +88 -0
- package/dist/login-capability.d.ts.map +1 -0
- package/dist/login-capability.js +78 -0
- package/dist/login-capability.js.map +1 -0
- package/dist/login-capability.test.d.ts +2 -0
- package/dist/login-capability.test.d.ts.map +1 -0
- package/dist/login-capability.test.js +78 -0
- package/dist/login-capability.test.js.map +1 -0
- package/dist/login-pty-transport.d.ts +80 -0
- package/dist/login-pty-transport.d.ts.map +1 -0
- package/dist/login-pty-transport.js +75 -0
- package/dist/login-pty-transport.js.map +1 -0
- package/dist/login-pty-transport.test.d.ts +2 -0
- package/dist/login-pty-transport.test.d.ts.map +1 -0
- package/dist/login-pty-transport.test.js +185 -0
- package/dist/login-pty-transport.test.js.map +1 -0
- package/dist/login-runner-lifecycle.d.ts +70 -0
- package/dist/login-runner-lifecycle.d.ts.map +1 -0
- package/dist/login-runner-lifecycle.js +52 -0
- package/dist/login-runner-lifecycle.js.map +1 -0
- package/dist/login-runner-lifecycle.test.d.ts +2 -0
- package/dist/login-runner-lifecycle.test.d.ts.map +1 -0
- package/dist/login-runner-lifecycle.test.js +122 -0
- package/dist/login-runner-lifecycle.test.js.map +1 -0
- package/dist/managed-ai-runtime-env.d.ts +4 -0
- package/dist/managed-ai-runtime-env.d.ts.map +1 -0
- package/dist/managed-ai-runtime-env.js +47 -0
- package/dist/managed-ai-runtime-env.js.map +1 -0
- package/dist/managed-clone-staging.test.d.ts +2 -0
- package/dist/managed-clone-staging.test.d.ts.map +1 -0
- package/dist/managed-clone-staging.test.js +167 -0
- package/dist/managed-clone-staging.test.js.map +1 -0
- package/dist/mcp-isolation.integration.test.d.ts +2 -0
- package/dist/mcp-isolation.integration.test.d.ts.map +1 -0
- package/dist/mcp-isolation.integration.test.js +202 -0
- package/dist/mcp-isolation.integration.test.js.map +1 -0
- package/dist/model-facing-history.d.ts +10 -0
- package/dist/model-facing-history.d.ts.map +1 -0
- package/dist/model-facing-history.js +44 -0
- package/dist/model-facing-history.js.map +1 -0
- package/dist/model-facing-history.test.d.ts +2 -0
- package/dist/model-facing-history.test.d.ts.map +1 -0
- package/dist/model-facing-history.test.js +27 -0
- package/dist/model-facing-history.test.js.map +1 -0
- package/dist/openrouter-attribution.d.ts +2 -0
- package/dist/openrouter-attribution.d.ts.map +1 -0
- package/dist/openrouter-attribution.js +2 -0
- package/dist/openrouter-attribution.js.map +1 -0
- package/dist/paperclip-runner-lifecycle-default.test.d.ts +2 -0
- package/dist/paperclip-runner-lifecycle-default.test.d.ts.map +1 -0
- package/dist/paperclip-runner-lifecycle-default.test.js +30 -0
- package/dist/paperclip-runner-lifecycle-default.test.js.map +1 -0
- package/dist/paperclip-runner-permissions.d.ts +182 -0
- package/dist/paperclip-runner-permissions.d.ts.map +1 -0
- package/dist/paperclip-runner-permissions.js +205 -0
- package/dist/paperclip-runner-permissions.js.map +1 -0
- package/dist/paperclip-runner-permissions.test.d.ts +2 -0
- package/dist/paperclip-runner-permissions.test.d.ts.map +1 -0
- package/dist/paperclip-runner-permissions.test.js +104 -0
- package/dist/paperclip-runner-permissions.test.js.map +1 -0
- package/dist/prompt-sections.test.d.ts +2 -0
- package/dist/prompt-sections.test.d.ts.map +1 -0
- package/dist/prompt-sections.test.js +53 -0
- package/dist/prompt-sections.test.js.map +1 -0
- package/dist/provider-stopped-boundary.d.ts +7 -0
- package/dist/provider-stopped-boundary.d.ts.map +1 -0
- package/dist/provider-stopped-boundary.js +22 -0
- package/dist/provider-stopped-boundary.js.map +1 -0
- package/dist/provider-stopped-boundary.test.d.ts +2 -0
- package/dist/provider-stopped-boundary.test.d.ts.map +1 -0
- package/dist/provider-stopped-boundary.test.js +76 -0
- package/dist/provider-stopped-boundary.test.js.map +1 -0
- package/dist/published-exports.test.d.ts +2 -0
- package/dist/published-exports.test.d.ts.map +1 -0
- package/dist/published-exports.test.js +17 -0
- package/dist/published-exports.test.js.map +1 -0
- package/dist/remote-execution-env.d.ts +3 -0
- package/dist/remote-execution-env.d.ts.map +1 -0
- package/dist/remote-execution-env.js +56 -0
- package/dist/remote-execution-env.js.map +1 -0
- package/dist/remote-managed-runtime.d.ts +52 -0
- package/dist/remote-managed-runtime.d.ts.map +1 -0
- package/dist/remote-managed-runtime.js +265 -0
- package/dist/remote-managed-runtime.js.map +1 -0
- package/dist/remote-managed-runtime.test.d.ts +2 -0
- package/dist/remote-managed-runtime.test.d.ts.map +1 -0
- package/dist/remote-managed-runtime.test.js +425 -0
- package/dist/remote-managed-runtime.test.js.map +1 -0
- package/dist/remote-pid-lock.d.ts +3 -0
- package/dist/remote-pid-lock.d.ts.map +1 -0
- package/dist/remote-pid-lock.js +35 -0
- package/dist/remote-pid-lock.js.map +1 -0
- package/dist/remote-text-file-sync.d.ts +41 -0
- package/dist/remote-text-file-sync.d.ts.map +1 -0
- package/dist/remote-text-file-sync.js +103 -0
- package/dist/remote-text-file-sync.js.map +1 -0
- package/dist/runner-connectivity.d.ts +61 -0
- package/dist/runner-connectivity.d.ts.map +1 -0
- package/dist/runner-connectivity.js +81 -0
- package/dist/runner-connectivity.js.map +1 -0
- package/dist/runner-connectivity.test.d.ts +2 -0
- package/dist/runner-connectivity.test.d.ts.map +1 -0
- package/dist/runner-connectivity.test.js +183 -0
- package/dist/runner-connectivity.test.js.map +1 -0
- package/dist/runtime-progress.d.ts +48 -0
- package/dist/runtime-progress.d.ts.map +1 -0
- package/dist/runtime-progress.js +99 -0
- package/dist/runtime-progress.js.map +1 -0
- package/dist/runtime-progress.test.d.ts +2 -0
- package/dist/runtime-progress.test.d.ts.map +1 -0
- package/dist/runtime-progress.test.js +240 -0
- package/dist/runtime-progress.test.js.map +1 -0
- package/dist/sandbox-callback-bridge-body.d.ts +12 -0
- package/dist/sandbox-callback-bridge-body.d.ts.map +1 -0
- package/dist/sandbox-callback-bridge-body.js +39 -0
- package/dist/sandbox-callback-bridge-body.js.map +1 -0
- package/dist/sandbox-callback-bridge-body.test.d.ts +2 -0
- package/dist/sandbox-callback-bridge-body.test.d.ts.map +1 -0
- package/dist/sandbox-callback-bridge-body.test.js +31 -0
- package/dist/sandbox-callback-bridge-body.test.js.map +1 -0
- package/dist/sandbox-callback-bridge.d.ts +249 -0
- package/dist/sandbox-callback-bridge.d.ts.map +1 -0
- package/dist/sandbox-callback-bridge.js +2309 -0
- package/dist/sandbox-callback-bridge.js.map +1 -0
- package/dist/sandbox-callback-bridge.test.d.ts +2 -0
- package/dist/sandbox-callback-bridge.test.d.ts.map +1 -0
- package/dist/sandbox-callback-bridge.test.js +3434 -0
- package/dist/sandbox-callback-bridge.test.js.map +1 -0
- package/dist/sandbox-callback-context-routes.test.d.ts +2 -0
- package/dist/sandbox-callback-context-routes.test.d.ts.map +1 -0
- package/dist/sandbox-callback-context-routes.test.js +40 -0
- package/dist/sandbox-callback-context-routes.test.js.map +1 -0
- package/dist/sandbox-file-sync.test.d.ts +2 -0
- package/dist/sandbox-file-sync.test.d.ts.map +1 -0
- package/dist/sandbox-file-sync.test.js +419 -0
- package/dist/sandbox-file-sync.test.js.map +1 -0
- package/dist/sandbox-install-command.d.ts +2 -0
- package/dist/sandbox-install-command.d.ts.map +1 -0
- package/dist/sandbox-install-command.js +47 -0
- package/dist/sandbox-install-command.js.map +1 -0
- package/dist/sandbox-install-command.test.d.ts +2 -0
- package/dist/sandbox-install-command.test.d.ts.map +1 -0
- package/dist/sandbox-install-command.test.js +22 -0
- package/dist/sandbox-install-command.test.js.map +1 -0
- package/dist/sandbox-managed-deletions.test.d.ts +2 -0
- package/dist/sandbox-managed-deletions.test.d.ts.map +1 -0
- package/dist/sandbox-managed-deletions.test.js +85 -0
- package/dist/sandbox-managed-deletions.test.js.map +1 -0
- package/dist/sandbox-managed-runtime.d.ts +465 -0
- package/dist/sandbox-managed-runtime.d.ts.map +1 -0
- package/dist/sandbox-managed-runtime.js +1801 -0
- package/dist/sandbox-managed-runtime.js.map +1 -0
- package/dist/sandbox-managed-runtime.test.d.ts +2 -0
- package/dist/sandbox-managed-runtime.test.d.ts.map +1 -0
- package/dist/sandbox-managed-runtime.test.js +3824 -0
- package/dist/sandbox-managed-runtime.test.js.map +1 -0
- package/dist/sandbox-managed-seed.test.d.ts +2 -0
- package/dist/sandbox-managed-seed.test.d.ts.map +1 -0
- package/dist/sandbox-managed-seed.test.js +223 -0
- package/dist/sandbox-managed-seed.test.js.map +1 -0
- package/dist/sandbox-run-log-stream.d.ts +44 -0
- package/dist/sandbox-run-log-stream.d.ts.map +1 -0
- package/dist/sandbox-run-log-stream.js +203 -0
- package/dist/sandbox-run-log-stream.js.map +1 -0
- package/dist/sandbox-shell.d.ts +3 -0
- package/dist/sandbox-shell.d.ts.map +1 -0
- package/dist/sandbox-shell.js +7 -0
- package/dist/sandbox-shell.js.map +1 -0
- package/dist/server-utils-env.test.d.ts +2 -0
- package/dist/server-utils-env.test.d.ts.map +1 -0
- package/dist/server-utils-env.test.js +15 -0
- package/dist/server-utils-env.test.js.map +1 -0
- package/dist/server-utils.d.ts +691 -0
- package/dist/server-utils.d.ts.map +1 -0
- package/dist/server-utils.js +3479 -0
- package/dist/server-utils.js.map +1 -0
- package/dist/server-utils.test.d.ts +2 -0
- package/dist/server-utils.test.d.ts.map +1 -0
- package/dist/server-utils.test.js +3571 -0
- package/dist/server-utils.test.js.map +1 -0
- package/dist/session-compaction.d.ts +25 -0
- package/dist/session-compaction.d.ts.map +1 -0
- package/dist/session-compaction.js +166 -0
- package/dist/session-compaction.js.map +1 -0
- package/dist/sigv4-presigned-url.d.ts +7 -0
- package/dist/sigv4-presigned-url.d.ts.map +1 -0
- package/dist/sigv4-presigned-url.js +119 -0
- package/dist/sigv4-presigned-url.js.map +1 -0
- package/dist/skill-library-manifest.d.ts +6 -0
- package/dist/skill-library-manifest.d.ts.map +1 -0
- package/dist/skill-library-manifest.js +53 -0
- package/dist/skill-library-manifest.js.map +1 -0
- package/dist/skill-library-manifest.test.d.ts +2 -0
- package/dist/skill-library-manifest.test.d.ts.map +1 -0
- package/dist/skill-library-manifest.test.js +84 -0
- package/dist/skill-library-manifest.test.js.map +1 -0
- package/dist/skills-staging-follow-symlinks.test.d.ts +2 -0
- package/dist/skills-staging-follow-symlinks.test.d.ts.map +1 -0
- package/dist/skills-staging-follow-symlinks.test.js +126 -0
- package/dist/skills-staging-follow-symlinks.test.js.map +1 -0
- package/dist/ssh-auth.test.d.ts +2 -0
- package/dist/ssh-auth.test.d.ts.map +1 -0
- package/dist/ssh-auth.test.js +20 -0
- package/dist/ssh-auth.test.js.map +1 -0
- package/dist/ssh-command-managed.test.d.ts +2 -0
- package/dist/ssh-command-managed.test.d.ts.map +1 -0
- package/dist/ssh-command-managed.test.js +136 -0
- package/dist/ssh-command-managed.test.js.map +1 -0
- package/dist/ssh-conversation-state.d.ts +22 -0
- package/dist/ssh-conversation-state.d.ts.map +1 -0
- package/dist/ssh-conversation-state.js +36 -0
- package/dist/ssh-conversation-state.js.map +1 -0
- package/dist/ssh-export-stream.test.d.ts +2 -0
- package/dist/ssh-export-stream.test.d.ts.map +1 -0
- package/dist/ssh-export-stream.test.js +104 -0
- package/dist/ssh-export-stream.test.js.map +1 -0
- package/dist/ssh-export.test.d.ts +2 -0
- package/dist/ssh-export.test.d.ts.map +1 -0
- package/dist/ssh-export.test.js +102 -0
- package/dist/ssh-export.test.js.map +1 -0
- package/dist/ssh-fixture.test.d.ts +2 -0
- package/dist/ssh-fixture.test.d.ts.map +1 -0
- package/dist/ssh-fixture.test.js +1107 -0
- package/dist/ssh-fixture.test.js.map +1 -0
- package/dist/ssh-tailscale.test.d.ts +2 -0
- package/dist/ssh-tailscale.test.d.ts.map +1 -0
- package/dist/ssh-tailscale.test.js +58 -0
- package/dist/ssh-tailscale.test.js.map +1 -0
- package/dist/ssh.d.ts +138 -0
- package/dist/ssh.d.ts.map +1 -0
- package/dist/ssh.js +1868 -0
- package/dist/ssh.js.map +1 -0
- package/dist/startup-reuse.d.ts +38 -0
- package/dist/startup-reuse.d.ts.map +1 -0
- package/dist/startup-reuse.js +90 -0
- package/dist/startup-reuse.js.map +1 -0
- package/dist/startup-reuse.test.d.ts +2 -0
- package/dist/startup-reuse.test.d.ts.map +1 -0
- package/dist/startup-reuse.test.js +71 -0
- package/dist/startup-reuse.test.js.map +1 -0
- package/dist/sync-operation-schedule.d.ts +17 -0
- package/dist/sync-operation-schedule.d.ts.map +1 -0
- package/dist/sync-operation-schedule.js +66 -0
- package/dist/sync-operation-schedule.js.map +1 -0
- package/dist/sync-operation-schedule.test.d.ts +2 -0
- package/dist/sync-operation-schedule.test.d.ts.map +1 -0
- package/dist/sync-operation-schedule.test.js +130 -0
- package/dist/sync-operation-schedule.test.js.map +1 -0
- package/dist/test-fixtures/follow-up-after-swarm-wake.d.ts +45 -0
- package/dist/test-fixtures/follow-up-after-swarm-wake.d.ts.map +1 -0
- package/dist/test-fixtures/follow-up-after-swarm-wake.js +80 -0
- package/dist/test-fixtures/follow-up-after-swarm-wake.js.map +1 -0
- package/dist/test-fixtures/prompt-context.d.ts +54 -0
- package/dist/test-fixtures/prompt-context.d.ts.map +1 -0
- package/dist/test-fixtures/prompt-context.js +55 -0
- package/dist/test-fixtures/prompt-context.js.map +1 -0
- package/dist/test-support/mcp-isolation-harness.d.ts +23 -0
- package/dist/test-support/mcp-isolation-harness.d.ts.map +1 -0
- package/dist/test-support/mcp-isolation-harness.js +67 -0
- package/dist/test-support/mcp-isolation-harness.js.map +1 -0
- package/dist/types.d.ts +910 -0
- package/dist/types.d.ts.map +1 -0
- package/dist/types.js +5 -0
- package/dist/types.js.map +1 -0
- package/dist/usage-checkpoint.d.ts +11 -0
- package/dist/usage-checkpoint.d.ts.map +1 -0
- package/dist/usage-checkpoint.js +165 -0
- package/dist/usage-checkpoint.js.map +1 -0
- package/dist/usage-checkpoint.test.d.ts +2 -0
- package/dist/usage-checkpoint.test.d.ts.map +1 -0
- package/dist/usage-checkpoint.test.js +131 -0
- package/dist/usage-checkpoint.test.js.map +1 -0
- package/dist/workspace-checkpoint-capture.test.d.ts +2 -0
- package/dist/workspace-checkpoint-capture.test.d.ts.map +1 -0
- package/dist/workspace-checkpoint-capture.test.js +232 -0
- package/dist/workspace-checkpoint-capture.test.js.map +1 -0
- package/dist/workspace-checkpoint.d.ts +16 -0
- package/dist/workspace-checkpoint.d.ts.map +1 -0
- package/dist/workspace-checkpoint.js +236 -0
- package/dist/workspace-checkpoint.js.map +1 -0
- package/dist/workspace-checkpoint.test.d.ts +2 -0
- package/dist/workspace-checkpoint.test.d.ts.map +1 -0
- package/dist/workspace-checkpoint.test.js +588 -0
- package/dist/workspace-checkpoint.test.js.map +1 -0
- package/dist/workspace-git-stream.d.ts +19 -0
- package/dist/workspace-git-stream.d.ts.map +1 -0
- package/dist/workspace-git-stream.js +99 -0
- package/dist/workspace-git-stream.js.map +1 -0
- package/dist/workspace-git-stream.test.d.ts +2 -0
- package/dist/workspace-git-stream.test.d.ts.map +1 -0
- package/dist/workspace-git-stream.test.js +71 -0
- package/dist/workspace-git-stream.test.js.map +1 -0
- package/dist/workspace-manifest.d.ts +61 -0
- package/dist/workspace-manifest.d.ts.map +1 -0
- package/dist/workspace-manifest.js +257 -0
- package/dist/workspace-manifest.js.map +1 -0
- package/dist/workspace-manifest.test.d.ts +2 -0
- package/dist/workspace-manifest.test.d.ts.map +1 -0
- package/dist/workspace-manifest.test.js +160 -0
- package/dist/workspace-manifest.test.js.map +1 -0
- package/dist/workspace-restore-diagnostics.d.ts +41 -0
- package/dist/workspace-restore-diagnostics.d.ts.map +1 -0
- package/dist/workspace-restore-diagnostics.js +265 -0
- package/dist/workspace-restore-diagnostics.js.map +1 -0
- package/dist/workspace-restore-diagnostics.test.d.ts +2 -0
- package/dist/workspace-restore-diagnostics.test.d.ts.map +1 -0
- package/dist/workspace-restore-diagnostics.test.js +294 -0
- package/dist/workspace-restore-diagnostics.test.js.map +1 -0
- package/dist/workspace-restore-merge.d.ts +126 -0
- package/dist/workspace-restore-merge.d.ts.map +1 -0
- package/dist/workspace-restore-merge.js +768 -0
- package/dist/workspace-restore-merge.js.map +1 -0
- package/dist/workspace-restore-merge.test.d.ts +2 -0
- package/dist/workspace-restore-merge.test.d.ts.map +1 -0
- package/dist/workspace-restore-merge.test.js +805 -0
- package/dist/workspace-restore-merge.test.js.map +1 -0
- package/dist/workspace-restore-result.d.ts +6 -0
- package/dist/workspace-restore-result.d.ts.map +1 -0
- package/dist/workspace-restore-result.js +72 -0
- package/dist/workspace-restore-result.js.map +1 -0
- package/dist/workspace-restore-result.test.d.ts +2 -0
- package/dist/workspace-restore-result.test.d.ts.map +1 -0
- package/dist/workspace-restore-result.test.js +74 -0
- package/dist/workspace-restore-result.test.js.map +1 -0
- package/dist/workspace-restore-teardown.d.ts +29 -0
- package/dist/workspace-restore-teardown.d.ts.map +1 -0
- package/dist/workspace-restore-teardown.js +36 -0
- package/dist/workspace-restore-teardown.js.map +1 -0
- package/dist/workspace-restore-teardown.test.d.ts +2 -0
- package/dist/workspace-restore-teardown.test.d.ts.map +1 -0
- package/dist/workspace-restore-teardown.test.js +104 -0
- package/dist/workspace-restore-teardown.test.js.map +1 -0
- package/dist/workspace-restore-unchanged.test.d.ts +2 -0
- package/dist/workspace-restore-unchanged.test.d.ts.map +1 -0
- package/dist/workspace-restore-unchanged.test.js +143 -0
- package/dist/workspace-restore-unchanged.test.js.map +1 -0
- package/dist/workspace-seed-cache.d.ts +41 -0
- package/dist/workspace-seed-cache.d.ts.map +1 -0
- package/dist/workspace-seed-cache.js +354 -0
- package/dist/workspace-seed-cache.js.map +1 -0
- package/dist/workspace-seed-cache.test.d.ts +2 -0
- package/dist/workspace-seed-cache.test.d.ts.map +1 -0
- package/dist/workspace-seed-cache.test.js +522 -0
- package/dist/workspace-seed-cache.test.js.map +1 -0
- package/dist/workspace-seed-reuse.test.d.ts +2 -0
- package/dist/workspace-seed-reuse.test.d.ts.map +1 -0
- package/dist/workspace-seed-reuse.test.js +274 -0
- package/dist/workspace-seed-reuse.test.js.map +1 -0
- package/dist/workspace-snapshot-concurrency.test.d.ts +2 -0
- package/dist/workspace-snapshot-concurrency.test.d.ts.map +1 -0
- package/dist/workspace-snapshot-concurrency.test.js +165 -0
- package/dist/workspace-snapshot-concurrency.test.js.map +1 -0
- package/dist/workspace-snapshot-thread-limit.test.d.ts +2 -0
- package/dist/workspace-snapshot-thread-limit.test.d.ts.map +1 -0
- package/dist/workspace-snapshot-thread-limit.test.js +84 -0
- package/dist/workspace-snapshot-thread-limit.test.js.map +1 -0
- package/dist/workspace-snapshot-thread-worker.d.ts +2 -0
- package/dist/workspace-snapshot-thread-worker.d.ts.map +1 -0
- package/dist/workspace-snapshot-thread-worker.js +28 -0
- package/dist/workspace-snapshot-thread-worker.js.map +1 -0
- package/dist/workspace-snapshot-thread.d.ts +27 -0
- package/dist/workspace-snapshot-thread.d.ts.map +1 -0
- package/dist/workspace-snapshot-thread.js +77 -0
- package/dist/workspace-snapshot-thread.js.map +1 -0
- package/dist/workspace-snapshot-thread.test.d.ts +2 -0
- package/dist/workspace-snapshot-thread.test.d.ts.map +1 -0
- package/dist/workspace-snapshot-thread.test.js +140 -0
- package/dist/workspace-snapshot-thread.test.js.map +1 -0
- package/node_modules/@agentclientprotocol/sdk/LICENSE +191 -0
- package/node_modules/@agentclientprotocol/sdk/README.md +77 -0
- package/node_modules/@agentclientprotocol/sdk/dist/acp.d.ts +1637 -0
- package/node_modules/@agentclientprotocol/sdk/dist/acp.js +1729 -0
- package/node_modules/@agentclientprotocol/sdk/dist/acp.js.map +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/acp.test.d.ts +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/acp.test.js +5093 -0
- package/node_modules/@agentclientprotocol/sdk/dist/acp.test.js.map +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/connection.d.ts +277 -0
- package/node_modules/@agentclientprotocol/sdk/dist/connection.js +898 -0
- package/node_modules/@agentclientprotocol/sdk/dist/connection.js.map +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/connection.test.d.ts +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/connection.test.js +666 -0
- package/node_modules/@agentclientprotocol/sdk/dist/connection.test.js.map +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/cookie-store.d.ts +26 -0
- package/node_modules/@agentclientprotocol/sdk/dist/cookie-store.js +96 -0
- package/node_modules/@agentclientprotocol/sdk/dist/cookie-store.js.map +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/cookie-store.test.d.ts +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/cookie-store.test.js +77 -0
- package/node_modules/@agentclientprotocol/sdk/dist/cookie-store.test.js.map +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/examples/agent.d.ts +2 -0
- package/node_modules/@agentclientprotocol/sdk/dist/examples/agent.js +232 -0
- package/node_modules/@agentclientprotocol/sdk/dist/examples/agent.js.map +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/examples/client.d.ts +2 -0
- package/node_modules/@agentclientprotocol/sdk/dist/examples/client.js +132 -0
- package/node_modules/@agentclientprotocol/sdk/dist/examples/client.js.map +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/examples/dual-version-agent.d.ts +9 -0
- package/node_modules/@agentclientprotocol/sdk/dist/examples/dual-version-agent.js +229 -0
- package/node_modules/@agentclientprotocol/sdk/dist/examples/dual-version-agent.js.map +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/examples/http-client.d.ts +2 -0
- package/node_modules/@agentclientprotocol/sdk/dist/examples/http-client.js +86 -0
- package/node_modules/@agentclientprotocol/sdk/dist/examples/http-client.js.map +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/examples/http-server.d.ts +2 -0
- package/node_modules/@agentclientprotocol/sdk/dist/examples/http-server.js +117 -0
- package/node_modules/@agentclientprotocol/sdk/dist/examples/http-server.js.map +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/examples/ws-client.d.ts +2 -0
- package/node_modules/@agentclientprotocol/sdk/dist/examples/ws-client.js +88 -0
- package/node_modules/@agentclientprotocol/sdk/dist/examples/ws-client.js.map +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/http-stream.d.ts +35 -0
- package/node_modules/@agentclientprotocol/sdk/dist/http-stream.js +473 -0
- package/node_modules/@agentclientprotocol/sdk/dist/http-stream.js.map +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/http-stream.test.d.ts +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/http-stream.test.js +1380 -0
- package/node_modules/@agentclientprotocol/sdk/dist/http-stream.test.js.map +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/jsonrpc.d.ts +604 -0
- package/node_modules/@agentclientprotocol/sdk/dist/jsonrpc.js +1082 -0
- package/node_modules/@agentclientprotocol/sdk/dist/jsonrpc.js.map +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/jsonrpc.test.d.ts +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/jsonrpc.test.js +917 -0
- package/node_modules/@agentclientprotocol/sdk/dist/jsonrpc.test.js.map +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/line-buffer.d.ts +24 -0
- package/node_modules/@agentclientprotocol/sdk/dist/line-buffer.js +71 -0
- package/node_modules/@agentclientprotocol/sdk/dist/line-buffer.js.map +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/line-buffer.test.d.ts +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/line-buffer.test.js +45 -0
- package/node_modules/@agentclientprotocol/sdk/dist/line-buffer.test.js.map +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/nes/acp.d.ts +563 -0
- package/node_modules/@agentclientprotocol/sdk/dist/nes/acp.js +106 -0
- package/node_modules/@agentclientprotocol/sdk/dist/nes/acp.js.map +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/nes/schema/types.gen.d.ts +1261 -0
- package/node_modules/@agentclientprotocol/sdk/dist/nes/schema/types.gen.js +4 -0
- package/node_modules/@agentclientprotocol/sdk/dist/nes/schema/types.gen.js.map +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/nes/schema/zod.gen.d.ts +962 -0
- package/node_modules/@agentclientprotocol/sdk/dist/nes/schema/zod.gen.js +526 -0
- package/node_modules/@agentclientprotocol/sdk/dist/nes/schema/zod.gen.js.map +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/node-adapter.d.ts +17 -0
- package/node_modules/@agentclientprotocol/sdk/dist/node-adapter.js +457 -0
- package/node_modules/@agentclientprotocol/sdk/dist/node-adapter.js.map +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/node-adapter.test.d.ts +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/node-adapter.test.js +586 -0
- package/node_modules/@agentclientprotocol/sdk/dist/node-adapter.test.js.map +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/protocol-router.d.ts +43 -0
- package/node_modules/@agentclientprotocol/sdk/dist/protocol-router.js +467 -0
- package/node_modules/@agentclientprotocol/sdk/dist/protocol-router.js.map +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/protocol-router.test.d.ts +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/protocol-router.test.js +592 -0
- package/node_modules/@agentclientprotocol/sdk/dist/protocol-router.test.js.map +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/protocol.d.ts +11 -0
- package/node_modules/@agentclientprotocol/sdk/dist/protocol.js +60 -0
- package/node_modules/@agentclientprotocol/sdk/dist/protocol.js.map +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/protocol.test.d.ts +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/protocol.test.js +72 -0
- package/node_modules/@agentclientprotocol/sdk/dist/protocol.test.js.map +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/schema/guards.gen.d.ts +305 -0
- package/node_modules/@agentclientprotocol/sdk/dist/schema/guards.gen.js +355 -0
- package/node_modules/@agentclientprotocol/sdk/dist/schema/guards.gen.js.map +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/schema/index.d.ts +39 -0
- package/node_modules/@agentclientprotocol/sdk/dist/schema/index.js +40 -0
- package/node_modules/@agentclientprotocol/sdk/dist/schema/index.js.map +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/schema/types.gen.d.ts +5438 -0
- package/node_modules/@agentclientprotocol/sdk/dist/schema/types.gen.js +3 -0
- package/node_modules/@agentclientprotocol/sdk/dist/schema/types.gen.js.map +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/schema/zod.gen.d.ts +15955 -0
- package/node_modules/@agentclientprotocol/sdk/dist/schema/zod.gen.js +2827 -0
- package/node_modules/@agentclientprotocol/sdk/dist/schema/zod.gen.js.map +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/schema-deserialize.d.ts +31 -0
- package/node_modules/@agentclientprotocol/sdk/dist/schema-deserialize.js +117 -0
- package/node_modules/@agentclientprotocol/sdk/dist/schema-deserialize.js.map +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/schema-deserialize.test.d.ts +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/schema-deserialize.test.js +93 -0
- package/node_modules/@agentclientprotocol/sdk/dist/schema-deserialize.test.js.map +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/server-permission.test.d.ts +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/server-permission.test.js +261 -0
- package/node_modules/@agentclientprotocol/sdk/dist/server-permission.test.js.map +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/server-session-sse.test.d.ts +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/server-session-sse.test.js +536 -0
- package/node_modules/@agentclientprotocol/sdk/dist/server-session-sse.test.js.map +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/server-sse.d.ts +7 -0
- package/node_modules/@agentclientprotocol/sdk/dist/server-sse.js +136 -0
- package/node_modules/@agentclientprotocol/sdk/dist/server-sse.js.map +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/server-sse.test.d.ts +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/server-sse.test.js +106 -0
- package/node_modules/@agentclientprotocol/sdk/dist/server-sse.test.js.map +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/server-websocket-upgrade.test.d.ts +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/server-websocket-upgrade.test.js +1310 -0
- package/node_modules/@agentclientprotocol/sdk/dist/server-websocket-upgrade.test.js.map +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/server.d.ts +82 -0
- package/node_modules/@agentclientprotocol/sdk/dist/server.js +414 -0
- package/node_modules/@agentclientprotocol/sdk/dist/server.js.map +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/server.test.d.ts +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/server.test.js +1646 -0
- package/node_modules/@agentclientprotocol/sdk/dist/server.test.js.map +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/sse.d.ts +6 -0
- package/node_modules/@agentclientprotocol/sdk/dist/sse.js +114 -0
- package/node_modules/@agentclientprotocol/sdk/dist/sse.js.map +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/sse.test.d.ts +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/sse.test.js +126 -0
- package/node_modules/@agentclientprotocol/sdk/dist/sse.test.js.map +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/stream-limits.d.ts +15 -0
- package/node_modules/@agentclientprotocol/sdk/dist/stream-limits.js +58 -0
- package/node_modules/@agentclientprotocol/sdk/dist/stream-limits.js.map +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/stream.d.ts +38 -0
- package/node_modules/@agentclientprotocol/sdk/dist/stream.js +119 -0
- package/node_modules/@agentclientprotocol/sdk/dist/stream.js.map +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/stream.test.d.ts +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/stream.test.js +195 -0
- package/node_modules/@agentclientprotocol/sdk/dist/stream.test.js.map +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/test-support/streams.d.ts +8 -0
- package/node_modules/@agentclientprotocol/sdk/dist/test-support/streams.js +51 -0
- package/node_modules/@agentclientprotocol/sdk/dist/test-support/streams.js.map +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/test-support/test-agent.d.ts +24 -0
- package/node_modules/@agentclientprotocol/sdk/dist/test-support/test-agent.js +163 -0
- package/node_modules/@agentclientprotocol/sdk/dist/test-support/test-agent.js.map +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/test-support/test-http-server.d.ts +9 -0
- package/node_modules/@agentclientprotocol/sdk/dist/test-support/test-http-server.js +74 -0
- package/node_modules/@agentclientprotocol/sdk/dist/test-support/test-http-server.js.map +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/test-support/until.d.ts +5 -0
- package/node_modules/@agentclientprotocol/sdk/dist/test-support/until.js +14 -0
- package/node_modules/@agentclientprotocol/sdk/dist/test-support/until.js.map +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/v2/acp.d.ts +961 -0
- package/node_modules/@agentclientprotocol/sdk/dist/v2/acp.js +1451 -0
- package/node_modules/@agentclientprotocol/sdk/dist/v2/acp.js.map +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/v2/acp.test.d.ts +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/v2/acp.test.js +1423 -0
- package/node_modules/@agentclientprotocol/sdk/dist/v2/acp.test.js.map +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/v2/schema/guards.gen.d.ts +1084 -0
- package/node_modules/@agentclientprotocol/sdk/dist/v2/schema/guards.gen.js +1157 -0
- package/node_modules/@agentclientprotocol/sdk/dist/v2/schema/guards.gen.js.map +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/v2/schema/index.d.ts +30 -0
- package/node_modules/@agentclientprotocol/sdk/dist/v2/schema/index.js +31 -0
- package/node_modules/@agentclientprotocol/sdk/dist/v2/schema/index.js.map +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/v2/schema/types.gen.d.ts +5672 -0
- package/node_modules/@agentclientprotocol/sdk/dist/v2/schema/types.gen.js +3 -0
- package/node_modules/@agentclientprotocol/sdk/dist/v2/schema/types.gen.js.map +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/v2/schema/zod.gen.d.ts +37653 -0
- package/node_modules/@agentclientprotocol/sdk/dist/v2/schema/zod.gen.js +2952 -0
- package/node_modules/@agentclientprotocol/sdk/dist/v2/schema/zod.gen.js.map +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/ws-server.d.ts +14 -0
- package/node_modules/@agentclientprotocol/sdk/dist/ws-server.js +485 -0
- package/node_modules/@agentclientprotocol/sdk/dist/ws-server.js.map +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/ws-stream.d.ts +54 -0
- package/node_modules/@agentclientprotocol/sdk/dist/ws-stream.js +253 -0
- package/node_modules/@agentclientprotocol/sdk/dist/ws-stream.js.map +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/ws-stream.test.d.ts +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/ws-stream.test.js +836 -0
- package/node_modules/@agentclientprotocol/sdk/dist/ws-stream.test.js.map +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/ws-utils.d.ts +19 -0
- package/node_modules/@agentclientprotocol/sdk/dist/ws-utils.js +78 -0
- package/node_modules/@agentclientprotocol/sdk/dist/ws-utils.js.map +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/ws-utils.test.d.ts +1 -0
- package/node_modules/@agentclientprotocol/sdk/dist/ws-utils.test.js +42 -0
- package/node_modules/@agentclientprotocol/sdk/dist/ws-utils.test.js.map +1 -0
- package/node_modules/@agentclientprotocol/sdk/package.json +110 -0
- package/node_modules/@agentclientprotocol/sdk/schema/schema.json +7852 -0
- package/node_modules/@agentclientprotocol/sdk/schema/v2/schema.unstable.json +8814 -0
- package/node_modules/@clack/core/LICENSE +9 -0
- package/node_modules/@clack/core/README.md +22 -0
- package/node_modules/@clack/core/dist/index.d.mts +505 -0
- package/node_modules/@clack/core/dist/index.mjs +1006 -0
- package/node_modules/@clack/core/package.json +64 -0
- package/node_modules/@clack/prompts/LICENSE +9 -0
- package/node_modules/@clack/prompts/README.md +396 -0
- package/node_modules/@clack/prompts/dist/index.d.mts +950 -0
- package/node_modules/@clack/prompts/dist/index.mjs +1448 -0
- package/node_modules/@clack/prompts/package.json +67 -0
- package/node_modules/@openclaw/fs-safe/CHANGELOG.md +1772 -0
- package/node_modules/@openclaw/fs-safe/LICENSE +22 -0
- package/node_modules/@openclaw/fs-safe/README.md +383 -0
- package/node_modules/@openclaw/fs-safe/SECURITY.md +45 -0
- package/node_modules/@openclaw/fs-safe/dist/absolute-path.d.ts +32 -0
- package/node_modules/@openclaw/fs-safe/dist/absolute-path.js +307 -0
- package/node_modules/@openclaw/fs-safe/dist/advanced.d.ts +45 -0
- package/node_modules/@openclaw/fs-safe/dist/advanced.js +43 -0
- package/node_modules/@openclaw/fs-safe/dist/archive-crc32.d.ts +1 -0
- package/node_modules/@openclaw/fs-safe/dist/archive-crc32.js +19 -0
- package/node_modules/@openclaw/fs-safe/dist/archive-deadline.d.ts +11 -0
- package/node_modules/@openclaw/fs-safe/dist/archive-deadline.js +101 -0
- package/node_modules/@openclaw/fs-safe/dist/archive-durability.d.ts +23 -0
- package/node_modules/@openclaw/fs-safe/dist/archive-durability.js +180 -0
- package/node_modules/@openclaw/fs-safe/dist/archive-entry.d.ts +13 -0
- package/node_modules/@openclaw/fs-safe/dist/archive-entry.js +89 -0
- package/node_modules/@openclaw/fs-safe/dist/archive-errors.d.ts +12 -0
- package/node_modules/@openclaw/fs-safe/dist/archive-errors.js +23 -0
- package/node_modules/@openclaw/fs-safe/dist/archive-gzip-tail.d.ts +20 -0
- package/node_modules/@openclaw/fs-safe/dist/archive-gzip-tail.js +99 -0
- package/node_modules/@openclaw/fs-safe/dist/archive-input.d.ts +18 -0
- package/node_modules/@openclaw/fs-safe/dist/archive-input.js +100 -0
- package/node_modules/@openclaw/fs-safe/dist/archive-kind.d.ts +7 -0
- package/node_modules/@openclaw/fs-safe/dist/archive-kind.js +71 -0
- package/node_modules/@openclaw/fs-safe/dist/archive-limits.d.ts +56 -0
- package/node_modules/@openclaw/fs-safe/dist/archive-limits.js +131 -0
- package/node_modules/@openclaw/fs-safe/dist/archive-merge.d.ts +22 -0
- package/node_modules/@openclaw/fs-safe/dist/archive-merge.js +307 -0
- package/node_modules/@openclaw/fs-safe/dist/archive-parser-errors.d.ts +1 -0
- package/node_modules/@openclaw/fs-safe/dist/archive-parser-errors.js +12 -0
- package/node_modules/@openclaw/fs-safe/dist/archive-parser.wasm +0 -0
- package/node_modules/@openclaw/fs-safe/dist/archive-plan.d.ts +85 -0
- package/node_modules/@openclaw/fs-safe/dist/archive-plan.js +119 -0
- package/node_modules/@openclaw/fs-safe/dist/archive-read.d.ts +5 -0
- package/node_modules/@openclaw/fs-safe/dist/archive-read.js +241 -0
- package/node_modules/@openclaw/fs-safe/dist/archive-staging.d.ts +32 -0
- package/node_modules/@openclaw/fs-safe/dist/archive-staging.js +291 -0
- package/node_modules/@openclaw/fs-safe/dist/archive-tar-stream.d.ts +27 -0
- package/node_modules/@openclaw/fs-safe/dist/archive-tar-stream.js +127 -0
- package/node_modules/@openclaw/fs-safe/dist/archive-tar-wasm.d.ts +29 -0
- package/node_modules/@openclaw/fs-safe/dist/archive-tar-wasm.js +203 -0
- package/node_modules/@openclaw/fs-safe/dist/archive-zip-admission.d.ts +7 -0
- package/node_modules/@openclaw/fs-safe/dist/archive-zip-admission.js +96 -0
- package/node_modules/@openclaw/fs-safe/dist/archive-zip-count.d.ts +1 -0
- package/node_modules/@openclaw/fs-safe/dist/archive-zip-count.js +160 -0
- package/node_modules/@openclaw/fs-safe/dist/archive-zip-directory.d.ts +21 -0
- package/node_modules/@openclaw/fs-safe/dist/archive-zip-directory.js +267 -0
- package/node_modules/@openclaw/fs-safe/dist/archive-zip-entry.d.ts +24 -0
- package/node_modules/@openclaw/fs-safe/dist/archive-zip-entry.js +10 -0
- package/node_modules/@openclaw/fs-safe/dist/archive-zip-integrity.d.ts +4 -0
- package/node_modules/@openclaw/fs-safe/dist/archive-zip-integrity.js +30 -0
- package/node_modules/@openclaw/fs-safe/dist/archive-zip-loader.d.ts +12 -0
- package/node_modules/@openclaw/fs-safe/dist/archive-zip-loader.js +152 -0
- package/node_modules/@openclaw/fs-safe/dist/archive-zip-manifest.d.ts +4 -0
- package/node_modules/@openclaw/fs-safe/dist/archive-zip-manifest.js +24 -0
- package/node_modules/@openclaw/fs-safe/dist/archive-zip-names.d.ts +17 -0
- package/node_modules/@openclaw/fs-safe/dist/archive-zip-names.js +149 -0
- package/node_modules/@openclaw/fs-safe/dist/archive-zip-preflight.d.ts +4 -0
- package/node_modules/@openclaw/fs-safe/dist/archive-zip-preflight.js +21 -0
- package/node_modules/@openclaw/fs-safe/dist/archive.d.ts +20 -0
- package/node_modules/@openclaw/fs-safe/dist/archive.js +329 -0
- package/node_modules/@openclaw/fs-safe/dist/async-lock.d.ts +1 -0
- package/node_modules/@openclaw/fs-safe/dist/async-lock.js +17 -0
- package/node_modules/@openclaw/fs-safe/dist/atomic-io.d.ts +52 -0
- package/node_modules/@openclaw/fs-safe/dist/atomic-io.js +248 -0
- package/node_modules/@openclaw/fs-safe/dist/atomic.d.ts +7 -0
- package/node_modules/@openclaw/fs-safe/dist/atomic.js +4 -0
- package/node_modules/@openclaw/fs-safe/dist/bounded-read-stream.d.ts +2 -0
- package/node_modules/@openclaw/fs-safe/dist/bounded-read-stream.js +15 -0
- package/node_modules/@openclaw/fs-safe/dist/bounded-read.d.ts +26 -0
- package/node_modules/@openclaw/fs-safe/dist/bounded-read.js +161 -0
- package/node_modules/@openclaw/fs-safe/dist/byte-budget.d.ts +3 -0
- package/node_modules/@openclaw/fs-safe/dist/byte-budget.js +9 -0
- package/node_modules/@openclaw/fs-safe/dist/byte-view.d.ts +2 -0
- package/node_modules/@openclaw/fs-safe/dist/byte-view.js +13 -0
- package/node_modules/@openclaw/fs-safe/dist/clone-metadata.d.ts +21 -0
- package/node_modules/@openclaw/fs-safe/dist/clone-metadata.js +37 -0
- package/node_modules/@openclaw/fs-safe/dist/config.d.ts +8 -0
- package/node_modules/@openclaw/fs-safe/dist/config.js +7 -0
- package/node_modules/@openclaw/fs-safe/dist/containment.d.ts +1 -0
- package/node_modules/@openclaw/fs-safe/dist/containment.js +1 -0
- package/node_modules/@openclaw/fs-safe/dist/copy-file-input.d.ts +23 -0
- package/node_modules/@openclaw/fs-safe/dist/copy-file-input.js +74 -0
- package/node_modules/@openclaw/fs-safe/dist/copy-link.d.ts +26 -0
- package/node_modules/@openclaw/fs-safe/dist/copy-link.js +170 -0
- package/node_modules/@openclaw/fs-safe/dist/copy-metadata.d.ts +9 -0
- package/node_modules/@openclaw/fs-safe/dist/copy-metadata.js +39 -0
- package/node_modules/@openclaw/fs-safe/dist/copy-path-admission.d.ts +17 -0
- package/node_modules/@openclaw/fs-safe/dist/copy-path-admission.js +126 -0
- package/node_modules/@openclaw/fs-safe/dist/copy-policy.d.ts +2 -0
- package/node_modules/@openclaw/fs-safe/dist/copy-policy.js +8 -0
- package/node_modules/@openclaw/fs-safe/dist/copy-publication.d.ts +18 -0
- package/node_modules/@openclaw/fs-safe/dist/copy-publication.js +29 -0
- package/node_modules/@openclaw/fs-safe/dist/copy-root-file-sync.d.ts +36 -0
- package/node_modules/@openclaw/fs-safe/dist/copy-root-file-sync.js +204 -0
- package/node_modules/@openclaw/fs-safe/dist/copy-tree-portable.d.ts +8 -0
- package/node_modules/@openclaw/fs-safe/dist/copy-tree-portable.js +244 -0
- package/node_modules/@openclaw/fs-safe/dist/copy.d.ts +15 -0
- package/node_modules/@openclaw/fs-safe/dist/copy.js +143 -0
- package/node_modules/@openclaw/fs-safe/dist/create-owned-file.d.ts +7 -0
- package/node_modules/@openclaw/fs-safe/dist/create-owned-file.js +16 -0
- package/node_modules/@openclaw/fs-safe/dist/create.d.ts +18 -0
- package/node_modules/@openclaw/fs-safe/dist/create.js +398 -0
- package/node_modules/@openclaw/fs-safe/dist/creation-boundary.d.ts +60 -0
- package/node_modules/@openclaw/fs-safe/dist/creation-boundary.js +374 -0
- package/node_modules/@openclaw/fs-safe/dist/darwin-acl.d.ts +12 -0
- package/node_modules/@openclaw/fs-safe/dist/darwin-acl.js +29 -0
- package/node_modules/@openclaw/fs-safe/dist/deny-mutation-match.d.ts +2 -0
- package/node_modules/@openclaw/fs-safe/dist/deny-mutation-match.js +71 -0
- package/node_modules/@openclaw/fs-safe/dist/deny-mutations.d.ts +11 -0
- package/node_modules/@openclaw/fs-safe/dist/deny-mutations.js +96 -0
- package/node_modules/@openclaw/fs-safe/dist/device-path.d.ts +14 -0
- package/node_modules/@openclaw/fs-safe/dist/device-path.js +139 -0
- package/node_modules/@openclaw/fs-safe/dist/directory-durability.d.ts +46 -0
- package/node_modules/@openclaw/fs-safe/dist/directory-durability.js +286 -0
- package/node_modules/@openclaw/fs-safe/dist/directory-entry-path.d.ts +2 -0
- package/node_modules/@openclaw/fs-safe/dist/directory-entry-path.js +21 -0
- package/node_modules/@openclaw/fs-safe/dist/directory-guard.d.ts +65 -0
- package/node_modules/@openclaw/fs-safe/dist/directory-guard.js +197 -0
- package/node_modules/@openclaw/fs-safe/dist/directory-mode-node.d.ts +47 -0
- package/node_modules/@openclaw/fs-safe/dist/directory-mode-node.js +323 -0
- package/node_modules/@openclaw/fs-safe/dist/directory-mode-options.d.ts +3 -0
- package/node_modules/@openclaw/fs-safe/dist/directory-mode-options.js +6 -0
- package/node_modules/@openclaw/fs-safe/dist/directory-receipt.d.ts +23 -0
- package/node_modules/@openclaw/fs-safe/dist/directory-receipt.js +126 -0
- package/node_modules/@openclaw/fs-safe/dist/durability.d.ts +5 -0
- package/node_modules/@openclaw/fs-safe/dist/durability.js +3 -0
- package/node_modules/@openclaw/fs-safe/dist/effective-uid.d.ts +1 -0
- package/node_modules/@openclaw/fs-safe/dist/effective-uid.js +22 -0
- package/node_modules/@openclaw/fs-safe/dist/entry-publication-types.d.ts +55 -0
- package/node_modules/@openclaw/fs-safe/dist/entry-publication-types.js +1 -0
- package/node_modules/@openclaw/fs-safe/dist/entry-publication.d.ts +8 -0
- package/node_modules/@openclaw/fs-safe/dist/entry-publication.js +264 -0
- package/node_modules/@openclaw/fs-safe/dist/error-detail.d.ts +2 -0
- package/node_modules/@openclaw/fs-safe/dist/error-detail.js +13 -0
- package/node_modules/@openclaw/fs-safe/dist/errors.d.ts +17 -0
- package/node_modules/@openclaw/fs-safe/dist/errors.js +33 -0
- package/node_modules/@openclaw/fs-safe/dist/exact-identity.d.ts +17 -0
- package/node_modules/@openclaw/fs-safe/dist/exact-identity.js +29 -0
- package/node_modules/@openclaw/fs-safe/dist/exclusive-create.d.ts +3 -0
- package/node_modules/@openclaw/fs-safe/dist/exclusive-create.js +22 -0
- package/node_modules/@openclaw/fs-safe/dist/file-cleanup.d.ts +14 -0
- package/node_modules/@openclaw/fs-safe/dist/file-cleanup.js +78 -0
- package/node_modules/@openclaw/fs-safe/dist/file-contents.d.ts +5 -0
- package/node_modules/@openclaw/fs-safe/dist/file-contents.js +40 -0
- package/node_modules/@openclaw/fs-safe/dist/file-handle-transfer.d.ts +15 -0
- package/node_modules/@openclaw/fs-safe/dist/file-handle-transfer.js +192 -0
- package/node_modules/@openclaw/fs-safe/dist/file-hash.d.ts +16 -0
- package/node_modules/@openclaw/fs-safe/dist/file-hash.js +298 -0
- package/node_modules/@openclaw/fs-safe/dist/file-identity.d.ts +13 -0
- package/node_modules/@openclaw/fs-safe/dist/file-identity.js +75 -0
- package/node_modules/@openclaw/fs-safe/dist/file-lock-sync-acquisition.d.ts +22 -0
- package/node_modules/@openclaw/fs-safe/dist/file-lock-sync-acquisition.js +98 -0
- package/node_modules/@openclaw/fs-safe/dist/file-lock-sync-admission.d.ts +16 -0
- package/node_modules/@openclaw/fs-safe/dist/file-lock-sync-admission.js +47 -0
- package/node_modules/@openclaw/fs-safe/dist/file-lock-sync-root-acquire.d.ts +6 -0
- package/node_modules/@openclaw/fs-safe/dist/file-lock-sync-root-acquire.js +349 -0
- package/node_modules/@openclaw/fs-safe/dist/file-lock-sync-root-held.d.ts +25 -0
- package/node_modules/@openclaw/fs-safe/dist/file-lock-sync-root-held.js +392 -0
- package/node_modules/@openclaw/fs-safe/dist/file-lock-sync-root-io.d.ts +40 -0
- package/node_modules/@openclaw/fs-safe/dist/file-lock-sync-root-io.js +209 -0
- package/node_modules/@openclaw/fs-safe/dist/file-lock-sync-root-mutation.d.ts +16 -0
- package/node_modules/@openclaw/fs-safe/dist/file-lock-sync-root-mutation.js +284 -0
- package/node_modules/@openclaw/fs-safe/dist/file-lock-sync-root-options.d.ts +11 -0
- package/node_modules/@openclaw/fs-safe/dist/file-lock-sync-root-options.js +58 -0
- package/node_modules/@openclaw/fs-safe/dist/file-lock-sync-root-registration.d.ts +1 -0
- package/node_modules/@openclaw/fs-safe/dist/file-lock-sync-root-registration.js +90 -0
- package/node_modules/@openclaw/fs-safe/dist/file-lock-sync-root.d.ts +34 -0
- package/node_modules/@openclaw/fs-safe/dist/file-lock-sync-root.js +286 -0
- package/node_modules/@openclaw/fs-safe/dist/file-lock-sync-stale-admission.d.ts +19 -0
- package/node_modules/@openclaw/fs-safe/dist/file-lock-sync-stale-admission.js +198 -0
- package/node_modules/@openclaw/fs-safe/dist/file-lock-sync.d.ts +17 -0
- package/node_modules/@openclaw/fs-safe/dist/file-lock-sync.js +356 -0
- package/node_modules/@openclaw/fs-safe/dist/file-lock.d.ts +24 -0
- package/node_modules/@openclaw/fs-safe/dist/file-lock.js +67 -0
- package/node_modules/@openclaw/fs-safe/dist/file-observation.d.ts +8 -0
- package/node_modules/@openclaw/fs-safe/dist/file-observation.js +22 -0
- package/node_modules/@openclaw/fs-safe/dist/file-open-error.d.ts +2 -0
- package/node_modules/@openclaw/fs-safe/dist/file-open-error.js +14 -0
- package/node_modules/@openclaw/fs-safe/dist/file-store-boundary.d.ts +34 -0
- package/node_modules/@openclaw/fs-safe/dist/file-store-boundary.js +202 -0
- package/node_modules/@openclaw/fs-safe/dist/file-store-prune.d.ts +11 -0
- package/node_modules/@openclaw/fs-safe/dist/file-store-prune.js +116 -0
- package/node_modules/@openclaw/fs-safe/dist/file-store-sync-directory.d.ts +15 -0
- package/node_modules/@openclaw/fs-safe/dist/file-store-sync-directory.js +345 -0
- package/node_modules/@openclaw/fs-safe/dist/file-store-sync-write.d.ts +9 -0
- package/node_modules/@openclaw/fs-safe/dist/file-store-sync-write.js +132 -0
- package/node_modules/@openclaw/fs-safe/dist/file-store.d.ts +63 -0
- package/node_modules/@openclaw/fs-safe/dist/file-store.js +359 -0
- package/node_modules/@openclaw/fs-safe/dist/file-sync.d.ts +5 -0
- package/node_modules/@openclaw/fs-safe/dist/file-sync.js +24 -0
- package/node_modules/@openclaw/fs-safe/dist/file-write-lease.d.ts +9 -0
- package/node_modules/@openclaw/fs-safe/dist/file-write-lease.js +42 -0
- package/node_modules/@openclaw/fs-safe/dist/filename.d.ts +8 -0
- package/node_modules/@openclaw/fs-safe/dist/filename.js +138 -0
- package/node_modules/@openclaw/fs-safe/dist/fs.d.ts +4 -0
- package/node_modules/@openclaw/fs-safe/dist/fs.js +22 -0
- package/node_modules/@openclaw/fs-safe/dist/guarded-mkdir.d.ts +27 -0
- package/node_modules/@openclaw/fs-safe/dist/guarded-mkdir.js +285 -0
- package/node_modules/@openclaw/fs-safe/dist/guarded-mutation.d.ts +32 -0
- package/node_modules/@openclaw/fs-safe/dist/guarded-mutation.js +81 -0
- package/node_modules/@openclaw/fs-safe/dist/guest-dispatch-python.d.ts +1 -0
- package/node_modules/@openclaw/fs-safe/dist/guest-dispatch-python.js +68 -0
- package/node_modules/@openclaw/fs-safe/dist/guest-native-python.d.ts +3 -0
- package/node_modules/@openclaw/fs-safe/dist/guest-native-python.js +178 -0
- package/node_modules/@openclaw/fs-safe/dist/guest.d.ts +8 -0
- package/node_modules/@openclaw/fs-safe/dist/guest.js +427 -0
- package/node_modules/@openclaw/fs-safe/dist/hardlink-fallback.d.ts +1 -0
- package/node_modules/@openclaw/fs-safe/dist/hardlink-fallback.js +5 -0
- package/node_modules/@openclaw/fs-safe/dist/home-dir.d.ts +11 -0
- package/node_modules/@openclaw/fs-safe/dist/home-dir.js +149 -0
- package/node_modules/@openclaw/fs-safe/dist/index.d.ts +10 -0
- package/node_modules/@openclaw/fs-safe/dist/index.js +6 -0
- package/node_modules/@openclaw/fs-safe/dist/install-path.d.ts +25 -0
- package/node_modules/@openclaw/fs-safe/dist/install-path.js +136 -0
- package/node_modules/@openclaw/fs-safe/dist/json-document-store.d.ts +32 -0
- package/node_modules/@openclaw/fs-safe/dist/json-document-store.js +105 -0
- package/node_modules/@openclaw/fs-safe/dist/json-durable-queue-directory.d.ts +14 -0
- package/node_modules/@openclaw/fs-safe/dist/json-durable-queue-directory.js +150 -0
- package/node_modules/@openclaw/fs-safe/dist/json-durable-queue-ownership.d.ts +19 -0
- package/node_modules/@openclaw/fs-safe/dist/json-durable-queue-ownership.js +368 -0
- package/node_modules/@openclaw/fs-safe/dist/json-durable-queue-read.d.ts +5 -0
- package/node_modules/@openclaw/fs-safe/dist/json-durable-queue-read.js +65 -0
- package/node_modules/@openclaw/fs-safe/dist/json-durable-queue.d.ts +44 -0
- package/node_modules/@openclaw/fs-safe/dist/json-durable-queue.js +210 -0
- package/node_modules/@openclaw/fs-safe/dist/json-store.d.ts +9 -0
- package/node_modules/@openclaw/fs-safe/dist/json-store.js +15 -0
- package/node_modules/@openclaw/fs-safe/dist/json-stringify.d.ts +1 -0
- package/node_modules/@openclaw/fs-safe/dist/json-stringify.js +7 -0
- package/node_modules/@openclaw/fs-safe/dist/json.d.ts +49 -0
- package/node_modules/@openclaw/fs-safe/dist/json.js +305 -0
- package/node_modules/@openclaw/fs-safe/dist/local-file-access.d.ts +8 -0
- package/node_modules/@openclaw/fs-safe/dist/local-file-access.js +81 -0
- package/node_modules/@openclaw/fs-safe/dist/local-file-descriptor.d.ts +13 -0
- package/node_modules/@openclaw/fs-safe/dist/local-file-descriptor.js +101 -0
- package/node_modules/@openclaw/fs-safe/dist/local-roots.d.ts +20 -0
- package/node_modules/@openclaw/fs-safe/dist/local-roots.js +160 -0
- package/node_modules/@openclaw/fs-safe/dist/lock-config.d.ts +9 -0
- package/node_modules/@openclaw/fs-safe/dist/lock-config.js +12 -0
- package/node_modules/@openclaw/fs-safe/dist/move-path-cleanup.d.ts +30 -0
- package/node_modules/@openclaw/fs-safe/dist/move-path-cleanup.js +224 -0
- package/node_modules/@openclaw/fs-safe/dist/move-path-stage.d.ts +7 -0
- package/node_modules/@openclaw/fs-safe/dist/move-path-stage.js +56 -0
- package/node_modules/@openclaw/fs-safe/dist/move-path.d.ts +20 -0
- package/node_modules/@openclaw/fs-safe/dist/move-path.js +392 -0
- package/node_modules/@openclaw/fs-safe/dist/mutation-authority.d.ts +9 -0
- package/node_modules/@openclaw/fs-safe/dist/mutation-authority.js +49 -0
- package/node_modules/@openclaw/fs-safe/dist/native-binding.d.ts +323 -0
- package/node_modules/@openclaw/fs-safe/dist/native-binding.js +8 -0
- package/node_modules/@openclaw/fs-safe/dist/native-config.d.ts +13 -0
- package/node_modules/@openclaw/fs-safe/dist/native-config.js +59 -0
- package/node_modules/@openclaw/fs-safe/dist/native-directory-observation.d.ts +16 -0
- package/node_modules/@openclaw/fs-safe/dist/native-directory-observation.js +39 -0
- package/node_modules/@openclaw/fs-safe/dist/native-fallback-warning.d.ts +4 -0
- package/node_modules/@openclaw/fs-safe/dist/native-fallback-warning.js +35 -0
- package/node_modules/@openclaw/fs-safe/dist/native-guidance.d.ts +3 -0
- package/node_modules/@openclaw/fs-safe/dist/native-guidance.js +21 -0
- package/node_modules/@openclaw/fs-safe/dist/native-move-fallback.d.ts +3 -0
- package/node_modules/@openclaw/fs-safe/dist/native-move-fallback.js +56 -0
- package/node_modules/@openclaw/fs-safe/dist/native-noreplace.d.ts +8 -0
- package/node_modules/@openclaw/fs-safe/dist/native-noreplace.js +55 -0
- package/node_modules/@openclaw/fs-safe/dist/native-operations.d.ts +14 -0
- package/node_modules/@openclaw/fs-safe/dist/native-operations.js +111 -0
- package/node_modules/@openclaw/fs-safe/dist/native-parent-admission.d.ts +76 -0
- package/node_modules/@openclaw/fs-safe/dist/native-parent-admission.js +220 -0
- package/node_modules/@openclaw/fs-safe/dist/native-pinned-write-windows.d.ts +6 -0
- package/node_modules/@openclaw/fs-safe/dist/native-pinned-write-windows.js +290 -0
- package/node_modules/@openclaw/fs-safe/dist/native-pinned-write.d.ts +7 -0
- package/node_modules/@openclaw/fs-safe/dist/native-pinned-write.js +202 -0
- package/node_modules/@openclaw/fs-safe/dist/native-policy-directory-observation.d.ts +11 -0
- package/node_modules/@openclaw/fs-safe/dist/native-policy-directory-observation.js +62 -0
- package/node_modules/@openclaw/fs-safe/dist/native-policy-parent-windows.d.ts +13 -0
- package/node_modules/@openclaw/fs-safe/dist/native-policy-parent-windows.js +62 -0
- package/node_modules/@openclaw/fs-safe/dist/native-policy-parent.d.ts +15 -0
- package/node_modules/@openclaw/fs-safe/dist/native-policy-parent.js +421 -0
- package/node_modules/@openclaw/fs-safe/dist/native-rename-outcome.d.ts +3 -0
- package/node_modules/@openclaw/fs-safe/dist/native-rename-outcome.js +15 -0
- package/node_modules/@openclaw/fs-safe/dist/native-staged-file-metadata.d.ts +3 -0
- package/node_modules/@openclaw/fs-safe/dist/native-staged-file-metadata.js +16 -0
- package/node_modules/@openclaw/fs-safe/dist/native-staged-file.d.ts +45 -0
- package/node_modules/@openclaw/fs-safe/dist/native-staged-file.js +516 -0
- package/node_modules/@openclaw/fs-safe/dist/native-staged-symlink.d.ts +13 -0
- package/node_modules/@openclaw/fs-safe/dist/native-staged-symlink.js +285 -0
- package/node_modules/@openclaw/fs-safe/dist/native-stat-identity.d.ts +3 -0
- package/node_modules/@openclaw/fs-safe/dist/native-stat-identity.js +7 -0
- package/node_modules/@openclaw/fs-safe/dist/native-status.d.ts +17 -0
- package/node_modules/@openclaw/fs-safe/dist/native-status.js +30 -0
- package/node_modules/@openclaw/fs-safe/dist/native.d.ts +40 -0
- package/node_modules/@openclaw/fs-safe/dist/native.js +311 -0
- package/node_modules/@openclaw/fs-safe/dist/opened-file-failure.d.ts +7 -0
- package/node_modules/@openclaw/fs-safe/dist/opened-file-failure.js +48 -0
- package/node_modules/@openclaw/fs-safe/dist/opened-realpath.d.ts +15 -0
- package/node_modules/@openclaw/fs-safe/dist/opened-realpath.js +110 -0
- package/node_modules/@openclaw/fs-safe/dist/output.d.ts +16 -0
- package/node_modules/@openclaw/fs-safe/dist/output.js +145 -0
- package/node_modules/@openclaw/fs-safe/dist/overwrite-file-handle.d.ts +9 -0
- package/node_modules/@openclaw/fs-safe/dist/overwrite-file-handle.js +71 -0
- package/node_modules/@openclaw/fs-safe/dist/owner-dacl-batch-worker.d.ts +1 -0
- package/node_modules/@openclaw/fs-safe/dist/owner-dacl-batch-worker.js +54 -0
- package/node_modules/@openclaw/fs-safe/dist/owner-dacl-batch.d.ts +5 -0
- package/node_modules/@openclaw/fs-safe/dist/owner-dacl-batch.js +64 -0
- package/node_modules/@openclaw/fs-safe/dist/owner-dacl.d.ts +34 -0
- package/node_modules/@openclaw/fs-safe/dist/owner-dacl.js +40 -0
- package/node_modules/@openclaw/fs-safe/dist/path-case.d.ts +6 -0
- package/node_modules/@openclaw/fs-safe/dist/path-case.js +137 -0
- package/node_modules/@openclaw/fs-safe/dist/path-policy.d.ts +24 -0
- package/node_modules/@openclaw/fs-safe/dist/path-policy.js +49 -0
- package/node_modules/@openclaw/fs-safe/dist/path-prefix.d.ts +7 -0
- package/node_modules/@openclaw/fs-safe/dist/path-prefix.js +181 -0
- package/node_modules/@openclaw/fs-safe/dist/path-scope-lexical.d.ts +13 -0
- package/node_modules/@openclaw/fs-safe/dist/path-scope-lexical.js +40 -0
- package/node_modules/@openclaw/fs-safe/dist/path-segment-route.d.ts +7 -0
- package/node_modules/@openclaw/fs-safe/dist/path-segment-route.js +27 -0
- package/node_modules/@openclaw/fs-safe/dist/path-suffix-aliases.d.ts +11 -0
- package/node_modules/@openclaw/fs-safe/dist/path-suffix-aliases.js +394 -0
- package/node_modules/@openclaw/fs-safe/dist/path.d.ts +20 -0
- package/node_modules/@openclaw/fs-safe/dist/path.js +192 -0
- package/node_modules/@openclaw/fs-safe/dist/permission-exec.d.ts +32 -0
- package/node_modules/@openclaw/fs-safe/dist/permission-exec.js +203 -0
- package/node_modules/@openclaw/fs-safe/dist/permissions-public.d.ts +6 -0
- package/node_modules/@openclaw/fs-safe/dist/permissions-public.js +5 -0
- package/node_modules/@openclaw/fs-safe/dist/permissions-windows.d.ts +47 -0
- package/node_modules/@openclaw/fs-safe/dist/permissions-windows.js +380 -0
- package/node_modules/@openclaw/fs-safe/dist/permissions.d.ts +52 -0
- package/node_modules/@openclaw/fs-safe/dist/permissions.js +131 -0
- package/node_modules/@openclaw/fs-safe/dist/pinned-mutation-admission.d.ts +23 -0
- package/node_modules/@openclaw/fs-safe/dist/pinned-mutation-admission.js +419 -0
- package/node_modules/@openclaw/fs-safe/dist/pinned-mutation-observation.d.ts +38 -0
- package/node_modules/@openclaw/fs-safe/dist/pinned-mutation-observation.js +205 -0
- package/node_modules/@openclaw/fs-safe/dist/pinned-mutation-shared-route.d.ts +18 -0
- package/node_modules/@openclaw/fs-safe/dist/pinned-mutation-shared-route.js +70 -0
- package/node_modules/@openclaw/fs-safe/dist/pinned-open.d.ts +37 -0
- package/node_modules/@openclaw/fs-safe/dist/pinned-open.js +118 -0
- package/node_modules/@openclaw/fs-safe/dist/pinned-operation.d.ts +1 -0
- package/node_modules/@openclaw/fs-safe/dist/pinned-operation.js +22 -0
- package/node_modules/@openclaw/fs-safe/dist/pinned-write-input.d.ts +5 -0
- package/node_modules/@openclaw/fs-safe/dist/pinned-write-input.js +54 -0
- package/node_modules/@openclaw/fs-safe/dist/pinned-write-mode.d.ts +4 -0
- package/node_modules/@openclaw/fs-safe/dist/pinned-write-mode.js +31 -0
- package/node_modules/@openclaw/fs-safe/dist/pinned-write-staged.d.ts +5 -0
- package/node_modules/@openclaw/fs-safe/dist/pinned-write-staged.js +212 -0
- package/node_modules/@openclaw/fs-safe/dist/pinned-write-types.d.ts +74 -0
- package/node_modules/@openclaw/fs-safe/dist/pinned-write-types.js +1 -0
- package/node_modules/@openclaw/fs-safe/dist/pinned-write.d.ts +12 -0
- package/node_modules/@openclaw/fs-safe/dist/pinned-write.js +301 -0
- package/node_modules/@openclaw/fs-safe/dist/pipe.d.ts +9 -0
- package/node_modules/@openclaw/fs-safe/dist/pipe.js +26 -0
- package/node_modules/@openclaw/fs-safe/dist/positional-read.d.ts +8 -0
- package/node_modules/@openclaw/fs-safe/dist/positional-read.js +36 -0
- package/node_modules/@openclaw/fs-safe/dist/prepare-directory-mode.d.ts +9 -0
- package/node_modules/@openclaw/fs-safe/dist/prepare-directory-mode.js +61 -0
- package/node_modules/@openclaw/fs-safe/dist/private-directory.d.ts +4 -0
- package/node_modules/@openclaw/fs-safe/dist/private-directory.js +30 -0
- package/node_modules/@openclaw/fs-safe/dist/private-producer-handoff-sync.d.ts +3 -0
- package/node_modules/@openclaw/fs-safe/dist/private-producer-handoff-sync.js +72 -0
- package/node_modules/@openclaw/fs-safe/dist/private-producer-handoff.d.ts +53 -0
- package/node_modules/@openclaw/fs-safe/dist/private-producer-handoff.js +352 -0
- package/node_modules/@openclaw/fs-safe/dist/private-temp-workspace.d.ts +8 -0
- package/node_modules/@openclaw/fs-safe/dist/private-temp-workspace.js +370 -0
- package/node_modules/@openclaw/fs-safe/dist/publication-handle.d.ts +4 -0
- package/node_modules/@openclaw/fs-safe/dist/publication-handle.js +32 -0
- package/node_modules/@openclaw/fs-safe/dist/publish-copy-stage.d.ts +14 -0
- package/node_modules/@openclaw/fs-safe/dist/publish-copy-stage.js +152 -0
- package/node_modules/@openclaw/fs-safe/dist/publish-file-failure.d.ts +35 -0
- package/node_modules/@openclaw/fs-safe/dist/publish-file-failure.js +26 -0
- package/node_modules/@openclaw/fs-safe/dist/publish-file.d.ts +23 -0
- package/node_modules/@openclaw/fs-safe/dist/publish-file.js +371 -0
- package/node_modules/@openclaw/fs-safe/dist/publish-rename-fallback.d.ts +21 -0
- package/node_modules/@openclaw/fs-safe/dist/publish-rename-fallback.js +102 -0
- package/node_modules/@openclaw/fs-safe/dist/read-open-flags.d.ts +7 -0
- package/node_modules/@openclaw/fs-safe/dist/read-open-flags.js +13 -0
- package/node_modules/@openclaw/fs-safe/dist/read-opened-file.d.ts +19 -0
- package/node_modules/@openclaw/fs-safe/dist/read-opened-file.js +17 -0
- package/node_modules/@openclaw/fs-safe/dist/realpath.d.ts +5 -0
- package/node_modules/@openclaw/fs-safe/dist/realpath.js +102 -0
- package/node_modules/@openclaw/fs-safe/dist/recursive-mkdir-path.d.ts +2 -0
- package/node_modules/@openclaw/fs-safe/dist/recursive-mkdir-path.js +8 -0
- package/node_modules/@openclaw/fs-safe/dist/regular-file.d.ts +41 -0
- package/node_modules/@openclaw/fs-safe/dist/regular-file.js +313 -0
- package/node_modules/@openclaw/fs-safe/dist/replace-directory.d.ts +6 -0
- package/node_modules/@openclaw/fs-safe/dist/replace-directory.js +276 -0
- package/node_modules/@openclaw/fs-safe/dist/replace-file-buffer.d.ts +3 -0
- package/node_modules/@openclaw/fs-safe/dist/replace-file-buffer.js +22 -0
- package/node_modules/@openclaw/fs-safe/dist/replace-file-copy-fallback.d.ts +20 -0
- package/node_modules/@openclaw/fs-safe/dist/replace-file-copy-fallback.js +228 -0
- package/node_modules/@openclaw/fs-safe/dist/replace-file-copy-source.d.ts +9 -0
- package/node_modules/@openclaw/fs-safe/dist/replace-file-copy-source.js +60 -0
- package/node_modules/@openclaw/fs-safe/dist/replace-file-descriptor.d.ts +22 -0
- package/node_modules/@openclaw/fs-safe/dist/replace-file-descriptor.js +172 -0
- package/node_modules/@openclaw/fs-safe/dist/replace-file-destination.d.ts +19 -0
- package/node_modules/@openclaw/fs-safe/dist/replace-file-destination.js +89 -0
- package/node_modules/@openclaw/fs-safe/dist/replace-file-mode.d.ts +2 -0
- package/node_modules/@openclaw/fs-safe/dist/replace-file-mode.js +10 -0
- package/node_modules/@openclaw/fs-safe/dist/replace-file-mutation.d.ts +26 -0
- package/node_modules/@openclaw/fs-safe/dist/replace-file-mutation.js +47 -0
- package/node_modules/@openclaw/fs-safe/dist/replace-file-rename-policy.d.ts +5 -0
- package/node_modules/@openclaw/fs-safe/dist/replace-file-rename-policy.js +30 -0
- package/node_modules/@openclaw/fs-safe/dist/replace-file-temp-owner.d.ts +32 -0
- package/node_modules/@openclaw/fs-safe/dist/replace-file-temp-owner.js +229 -0
- package/node_modules/@openclaw/fs-safe/dist/replace-file-types.d.ts +51 -0
- package/node_modules/@openclaw/fs-safe/dist/replace-file-types.js +1 -0
- package/node_modules/@openclaw/fs-safe/dist/replace-file.d.ts +6 -0
- package/node_modules/@openclaw/fs-safe/dist/replace-file.js +223 -0
- package/node_modules/@openclaw/fs-safe/dist/retained-directory-replacement.d.ts +26 -0
- package/node_modules/@openclaw/fs-safe/dist/retained-directory-replacement.js +193 -0
- package/node_modules/@openclaw/fs-safe/dist/retained-file-types.d.ts +50 -0
- package/node_modules/@openclaw/fs-safe/dist/retained-file-types.js +1 -0
- package/node_modules/@openclaw/fs-safe/dist/retained-file.d.ts +3 -0
- package/node_modules/@openclaw/fs-safe/dist/retained-file.js +121 -0
- package/node_modules/@openclaw/fs-safe/dist/root-boundary.d.ts +29 -0
- package/node_modules/@openclaw/fs-safe/dist/root-boundary.js +176 -0
- package/node_modules/@openclaw/fs-safe/dist/root-context.d.ts +40 -0
- package/node_modules/@openclaw/fs-safe/dist/root-context.js +237 -0
- package/node_modules/@openclaw/fs-safe/dist/root-copy.d.ts +18 -0
- package/node_modules/@openclaw/fs-safe/dist/root-copy.js +128 -0
- package/node_modules/@openclaw/fs-safe/dist/root-create-input.d.ts +30 -0
- package/node_modules/@openclaw/fs-safe/dist/root-create-input.js +97 -0
- package/node_modules/@openclaw/fs-safe/dist/root-create-native.d.ts +47 -0
- package/node_modules/@openclaw/fs-safe/dist/root-create-native.js +586 -0
- package/node_modules/@openclaw/fs-safe/dist/root-directory-creation.d.ts +12 -0
- package/node_modules/@openclaw/fs-safe/dist/root-directory-creation.js +229 -0
- package/node_modules/@openclaw/fs-safe/dist/root-directory-entry.d.ts +11 -0
- package/node_modules/@openclaw/fs-safe/dist/root-directory-entry.js +31 -0
- package/node_modules/@openclaw/fs-safe/dist/root-directory-list-types.d.ts +41 -0
- package/node_modules/@openclaw/fs-safe/dist/root-directory-list-types.js +1 -0
- package/node_modules/@openclaw/fs-safe/dist/root-directory-list.d.ts +21 -0
- package/node_modules/@openclaw/fs-safe/dist/root-directory-list.js +462 -0
- package/node_modules/@openclaw/fs-safe/dist/root-directory.d.ts +22 -0
- package/node_modules/@openclaw/fs-safe/dist/root-directory.js +138 -0
- package/node_modules/@openclaw/fs-safe/dist/root-entries.d.ts +10 -0
- package/node_modules/@openclaw/fs-safe/dist/root-entries.js +61 -0
- package/node_modules/@openclaw/fs-safe/dist/root-errors.d.ts +18 -0
- package/node_modules/@openclaw/fs-safe/dist/root-errors.js +156 -0
- package/node_modules/@openclaw/fs-safe/dist/root-file-final-admission.d.ts +24 -0
- package/node_modules/@openclaw/fs-safe/dist/root-file-final-admission.js +98 -0
- package/node_modules/@openclaw/fs-safe/dist/root-file-open-batch-sync.d.ts +8 -0
- package/node_modules/@openclaw/fs-safe/dist/root-file-open-batch-sync.js +108 -0
- package/node_modules/@openclaw/fs-safe/dist/root-file.d.ts +53 -0
- package/node_modules/@openclaw/fs-safe/dist/root-file.js +216 -0
- package/node_modules/@openclaw/fs-safe/dist/root-handle-context.d.ts +4 -0
- package/node_modules/@openclaw/fs-safe/dist/root-handle-context.js +12 -0
- package/node_modules/@openclaw/fs-safe/dist/root-impl.d.ts +119 -0
- package/node_modules/@openclaw/fs-safe/dist/root-impl.js +1496 -0
- package/node_modules/@openclaw/fs-safe/dist/root-mkdir-native.d.ts +2 -0
- package/node_modules/@openclaw/fs-safe/dist/root-mkdir-native.js +258 -0
- package/node_modules/@openclaw/fs-safe/dist/root-move-noreplace.d.ts +17 -0
- package/node_modules/@openclaw/fs-safe/dist/root-move-noreplace.js +252 -0
- package/node_modules/@openclaw/fs-safe/dist/root-native-creation-path.d.ts +32 -0
- package/node_modules/@openclaw/fs-safe/dist/root-native-creation-path.js +56 -0
- package/node_modules/@openclaw/fs-safe/dist/root-observed-path.d.ts +7 -0
- package/node_modules/@openclaw/fs-safe/dist/root-observed-path.js +88 -0
- package/node_modules/@openclaw/fs-safe/dist/root-options.d.ts +85 -0
- package/node_modules/@openclaw/fs-safe/dist/root-options.js +18 -0
- package/node_modules/@openclaw/fs-safe/dist/root-path-errors.d.ts +12 -0
- package/node_modules/@openclaw/fs-safe/dist/root-path-errors.js +22 -0
- package/node_modules/@openclaw/fs-safe/dist/root-path-existing.d.ts +16 -0
- package/node_modules/@openclaw/fs-safe/dist/root-path-existing.js +188 -0
- package/node_modules/@openclaw/fs-safe/dist/root-path-observation.d.ts +55 -0
- package/node_modules/@openclaw/fs-safe/dist/root-path-observation.js +180 -0
- package/node_modules/@openclaw/fs-safe/dist/root-path-stat.d.ts +4 -0
- package/node_modules/@openclaw/fs-safe/dist/root-path-stat.js +134 -0
- package/node_modules/@openclaw/fs-safe/dist/root-path.d.ts +53 -0
- package/node_modules/@openclaw/fs-safe/dist/root-path.js +452 -0
- package/node_modules/@openclaw/fs-safe/dist/root-paths-lexical.d.ts +12 -0
- package/node_modules/@openclaw/fs-safe/dist/root-paths-lexical.js +22 -0
- package/node_modules/@openclaw/fs-safe/dist/root-paths.d.ts +58 -0
- package/node_modules/@openclaw/fs-safe/dist/root-paths.js +291 -0
- package/node_modules/@openclaw/fs-safe/dist/root-public-types.d.ts +12 -0
- package/node_modules/@openclaw/fs-safe/dist/root-public-types.js +1 -0
- package/node_modules/@openclaw/fs-safe/dist/root-read-admission.d.ts +25 -0
- package/node_modules/@openclaw/fs-safe/dist/root-read-admission.js +108 -0
- package/node_modules/@openclaw/fs-safe/dist/root-remove-identity.d.ts +12 -0
- package/node_modules/@openclaw/fs-safe/dist/root-remove-identity.js +87 -0
- package/node_modules/@openclaw/fs-safe/dist/root-remove-native.d.ts +4 -0
- package/node_modules/@openclaw/fs-safe/dist/root-remove-native.js +390 -0
- package/node_modules/@openclaw/fs-safe/dist/root-remove-receipt.d.ts +16 -0
- package/node_modules/@openclaw/fs-safe/dist/root-remove-receipt.js +37 -0
- package/node_modules/@openclaw/fs-safe/dist/root-remove.d.ts +17 -0
- package/node_modules/@openclaw/fs-safe/dist/root-remove.js +468 -0
- package/node_modules/@openclaw/fs-safe/dist/root-symlink-policy.d.ts +13 -0
- package/node_modules/@openclaw/fs-safe/dist/root-symlink-policy.js +34 -0
- package/node_modules/@openclaw/fs-safe/dist/root-walk.d.ts +48 -0
- package/node_modules/@openclaw/fs-safe/dist/root-walk.js +236 -0
- package/node_modules/@openclaw/fs-safe/dist/root-write-admission.d.ts +65 -0
- package/node_modules/@openclaw/fs-safe/dist/root-write-admission.js +302 -0
- package/node_modules/@openclaw/fs-safe/dist/root-write-compatibility.d.ts +11 -0
- package/node_modules/@openclaw/fs-safe/dist/root-write-compatibility.js +23 -0
- package/node_modules/@openclaw/fs-safe/dist/root-write-complete-parent.d.ts +43 -0
- package/node_modules/@openclaw/fs-safe/dist/root-write-complete-parent.js +180 -0
- package/node_modules/@openclaw/fs-safe/dist/root-write-lock-binding.d.ts +14 -0
- package/node_modules/@openclaw/fs-safe/dist/root-write-lock-binding.js +162 -0
- package/node_modules/@openclaw/fs-safe/dist/root-write-mode.d.ts +7 -0
- package/node_modules/@openclaw/fs-safe/dist/root-write-mode.js +72 -0
- package/node_modules/@openclaw/fs-safe/dist/root-write-publication.d.ts +23 -0
- package/node_modules/@openclaw/fs-safe/dist/root-write-publication.js +89 -0
- package/node_modules/@openclaw/fs-safe/dist/root-write-verification.d.ts +20 -0
- package/node_modules/@openclaw/fs-safe/dist/root-write-verification.js +115 -0
- package/node_modules/@openclaw/fs-safe/dist/root.d.ts +2 -0
- package/node_modules/@openclaw/fs-safe/dist/root.js +1 -0
- package/node_modules/@openclaw/fs-safe/dist/safe-path-segment.d.ts +11 -0
- package/node_modules/@openclaw/fs-safe/dist/safe-path-segment.js +76 -0
- package/node_modules/@openclaw/fs-safe/dist/secret-file.d.ts +30 -0
- package/node_modules/@openclaw/fs-safe/dist/secret-file.js +338 -0
- package/node_modules/@openclaw/fs-safe/dist/secret-read-async.d.ts +3 -0
- package/node_modules/@openclaw/fs-safe/dist/secret-read-async.js +58 -0
- package/node_modules/@openclaw/fs-safe/dist/secret-read-policy.d.ts +20 -0
- package/node_modules/@openclaw/fs-safe/dist/secret-read-policy.js +68 -0
- package/node_modules/@openclaw/fs-safe/dist/secret.d.ts +3 -0
- package/node_modules/@openclaw/fs-safe/dist/secret.js +3 -0
- package/node_modules/@openclaw/fs-safe/dist/secure-file-windows.d.ts +10 -0
- package/node_modules/@openclaw/fs-safe/dist/secure-file-windows.js +81 -0
- package/node_modules/@openclaw/fs-safe/dist/secure-file.d.ts +33 -0
- package/node_modules/@openclaw/fs-safe/dist/secure-file.js +304 -0
- package/node_modules/@openclaw/fs-safe/dist/secure-temp-dir.d.ts +27 -0
- package/node_modules/@openclaw/fs-safe/dist/secure-temp-dir.js +188 -0
- package/node_modules/@openclaw/fs-safe/dist/secure-temp-repair.d.ts +34 -0
- package/node_modules/@openclaw/fs-safe/dist/secure-temp-repair.js +110 -0
- package/node_modules/@openclaw/fs-safe/dist/sibling-staged-file.d.ts +20 -0
- package/node_modules/@openclaw/fs-safe/dist/sibling-staged-file.js +333 -0
- package/node_modules/@openclaw/fs-safe/dist/sibling-temp.d.ts +29 -0
- package/node_modules/@openclaw/fs-safe/dist/sibling-temp.js +136 -0
- package/node_modules/@openclaw/fs-safe/dist/sidecar-lock-acquire.d.ts +4 -0
- package/node_modules/@openclaw/fs-safe/dist/sidecar-lock-acquire.js +471 -0
- package/node_modules/@openclaw/fs-safe/dist/sidecar-lock-admission-context.d.ts +18 -0
- package/node_modules/@openclaw/fs-safe/dist/sidecar-lock-admission-context.js +60 -0
- package/node_modules/@openclaw/fs-safe/dist/sidecar-lock-admission-parser.d.ts +41 -0
- package/node_modules/@openclaw/fs-safe/dist/sidecar-lock-admission-parser.js +113 -0
- package/node_modules/@openclaw/fs-safe/dist/sidecar-lock-admission.d.ts +33 -0
- package/node_modules/@openclaw/fs-safe/dist/sidecar-lock-admission.js +1 -0
- package/node_modules/@openclaw/fs-safe/dist/sidecar-lock-handle.d.ts +20 -0
- package/node_modules/@openclaw/fs-safe/dist/sidecar-lock-handle.js +48 -0
- package/node_modules/@openclaw/fs-safe/dist/sidecar-lock-policy.d.ts +15 -0
- package/node_modules/@openclaw/fs-safe/dist/sidecar-lock-policy.js +112 -0
- package/node_modules/@openclaw/fs-safe/dist/sidecar-lock-reclaim.d.ts +64 -0
- package/node_modules/@openclaw/fs-safe/dist/sidecar-lock-reclaim.js +356 -0
- package/node_modules/@openclaw/fs-safe/dist/sidecar-lock-registration.d.ts +13 -0
- package/node_modules/@openclaw/fs-safe/dist/sidecar-lock-registration.js +47 -0
- package/node_modules/@openclaw/fs-safe/dist/sidecar-lock-retained.d.ts +14 -0
- package/node_modules/@openclaw/fs-safe/dist/sidecar-lock-retained.js +187 -0
- package/node_modules/@openclaw/fs-safe/dist/sidecar-lock-root.d.ts +2 -0
- package/node_modules/@openclaw/fs-safe/dist/sidecar-lock-root.js +79 -0
- package/node_modules/@openclaw/fs-safe/dist/sidecar-lock-stale-admission.d.ts +34 -0
- package/node_modules/@openclaw/fs-safe/dist/sidecar-lock-stale-admission.js +230 -0
- package/node_modules/@openclaw/fs-safe/dist/sidecar-lock-target.d.ts +7 -0
- package/node_modules/@openclaw/fs-safe/dist/sidecar-lock-target.js +62 -0
- package/node_modules/@openclaw/fs-safe/dist/sidecar-lock-types.d.ts +68 -0
- package/node_modules/@openclaw/fs-safe/dist/sidecar-lock-types.js +1 -0
- package/node_modules/@openclaw/fs-safe/dist/sidecar-lock.d.ts +13 -0
- package/node_modules/@openclaw/fs-safe/dist/sidecar-lock.js +296 -0
- package/node_modules/@openclaw/fs-safe/dist/staged-directory.d.ts +40 -0
- package/node_modules/@openclaw/fs-safe/dist/staged-directory.js +177 -0
- package/node_modules/@openclaw/fs-safe/dist/staged-file-settlement.d.ts +17 -0
- package/node_modules/@openclaw/fs-safe/dist/staged-file-settlement.js +65 -0
- package/node_modules/@openclaw/fs-safe/dist/staged-file-types.d.ts +55 -0
- package/node_modules/@openclaw/fs-safe/dist/staged-file-types.js +1 -0
- package/node_modules/@openclaw/fs-safe/dist/staged-symlink-types.d.ts +39 -0
- package/node_modules/@openclaw/fs-safe/dist/staged-symlink-types.js +1 -0
- package/node_modules/@openclaw/fs-safe/dist/stat-observation.d.ts +10 -0
- package/node_modules/@openclaw/fs-safe/dist/stat-observation.js +57 -0
- package/node_modules/@openclaw/fs-safe/dist/store.d.ts +3 -0
- package/node_modules/@openclaw/fs-safe/dist/store.js +3 -0
- package/node_modules/@openclaw/fs-safe/dist/strict-file-identity.d.ts +7 -0
- package/node_modules/@openclaw/fs-safe/dist/strict-file-identity.js +88 -0
- package/node_modules/@openclaw/fs-safe/dist/string-coerce.d.ts +4 -0
- package/node_modules/@openclaw/fs-safe/dist/string-coerce.js +16 -0
- package/node_modules/@openclaw/fs-safe/dist/suppressed-error.d.ts +5 -0
- package/node_modules/@openclaw/fs-safe/dist/suppressed-error.js +15 -0
- package/node_modules/@openclaw/fs-safe/dist/symlink-parents.d.ts +11 -0
- package/node_modules/@openclaw/fs-safe/dist/symlink-parents.js +109 -0
- package/node_modules/@openclaw/fs-safe/dist/temp-cleanup.d.ts +13 -0
- package/node_modules/@openclaw/fs-safe/dist/temp-cleanup.js +81 -0
- package/node_modules/@openclaw/fs-safe/dist/temp-directory-diagnostics.d.ts +10 -0
- package/node_modules/@openclaw/fs-safe/dist/temp-directory-diagnostics.js +29 -0
- package/node_modules/@openclaw/fs-safe/dist/temp-target.d.ts +31 -0
- package/node_modules/@openclaw/fs-safe/dist/temp-target.js +251 -0
- package/node_modules/@openclaw/fs-safe/dist/temp-workspace-admission.d.ts +14 -0
- package/node_modules/@openclaw/fs-safe/dist/temp-workspace-admission.js +387 -0
- package/node_modules/@openclaw/fs-safe/dist/temp-workspace-child-admission.d.ts +23 -0
- package/node_modules/@openclaw/fs-safe/dist/temp-workspace-child-admission.js +146 -0
- package/node_modules/@openclaw/fs-safe/dist/temp-workspace-descriptor.d.ts +50 -0
- package/node_modules/@openclaw/fs-safe/dist/temp-workspace-descriptor.js +344 -0
- package/node_modules/@openclaw/fs-safe/dist/temp-workspace-owner.d.ts +25 -0
- package/node_modules/@openclaw/fs-safe/dist/temp-workspace-owner.js +489 -0
- package/node_modules/@openclaw/fs-safe/dist/temp-workspace-ownership.d.ts +9 -0
- package/node_modules/@openclaw/fs-safe/dist/temp-workspace-ownership.js +74 -0
- package/node_modules/@openclaw/fs-safe/dist/temp-workspace-types.d.ts +43 -0
- package/node_modules/@openclaw/fs-safe/dist/temp-workspace-types.js +1 -0
- package/node_modules/@openclaw/fs-safe/dist/temp.d.ts +3 -0
- package/node_modules/@openclaw/fs-safe/dist/temp.js +2 -0
- package/node_modules/@openclaw/fs-safe/dist/test-hooks.d.ts +36 -0
- package/node_modules/@openclaw/fs-safe/dist/test-hooks.js +14 -0
- package/node_modules/@openclaw/fs-safe/dist/text-atomic.d.ts +10 -0
- package/node_modules/@openclaw/fs-safe/dist/text-atomic.js +18 -0
- package/node_modules/@openclaw/fs-safe/dist/timing.d.ts +8 -0
- package/node_modules/@openclaw/fs-safe/dist/timing.js +59 -0
- package/node_modules/@openclaw/fs-safe/dist/trash.d.ts +4 -0
- package/node_modules/@openclaw/fs-safe/dist/trash.js +249 -0
- package/node_modules/@openclaw/fs-safe/dist/types.d.ts +27 -0
- package/node_modules/@openclaw/fs-safe/dist/types.js +1 -0
- package/node_modules/@openclaw/fs-safe/dist/unicode-path.d.ts +2 -0
- package/node_modules/@openclaw/fs-safe/dist/unicode-path.js +16 -0
- package/node_modules/@openclaw/fs-safe/dist/walk.d.ts +37 -0
- package/node_modules/@openclaw/fs-safe/dist/walk.js +250 -0
- package/node_modules/@openclaw/fs-safe/dist/watch-hints.d.ts +16 -0
- package/node_modules/@openclaw/fs-safe/dist/watch-hints.js +365 -0
- package/node_modules/@openclaw/fs-safe/dist/watch-io-error.d.ts +2 -0
- package/node_modules/@openclaw/fs-safe/dist/watch-io-error.js +27 -0
- package/node_modules/@openclaw/fs-safe/dist/watch-io-worker.d.ts +1 -0
- package/node_modules/@openclaw/fs-safe/dist/watch-io-worker.js +93 -0
- package/node_modules/@openclaw/fs-safe/dist/watch-io.d.ts +47 -0
- package/node_modules/@openclaw/fs-safe/dist/watch-io.js +236 -0
- package/node_modules/@openclaw/fs-safe/dist/watch-native.d.ts +55 -0
- package/node_modules/@openclaw/fs-safe/dist/watch-native.js +93 -0
- package/node_modules/@openclaw/fs-safe/dist/watch-probe.d.ts +16 -0
- package/node_modules/@openclaw/fs-safe/dist/watch-probe.js +135 -0
- package/node_modules/@openclaw/fs-safe/dist/watch-rescan.d.ts +6 -0
- package/node_modules/@openclaw/fs-safe/dist/watch-rescan.js +167 -0
- package/node_modules/@openclaw/fs-safe/dist/watch-scan.d.ts +45 -0
- package/node_modules/@openclaw/fs-safe/dist/watch-scan.js +385 -0
- package/node_modules/@openclaw/fs-safe/dist/watch-stream.d.ts +10 -0
- package/node_modules/@openclaw/fs-safe/dist/watch-stream.js +57 -0
- package/node_modules/@openclaw/fs-safe/dist/watch-types.d.ts +62 -0
- package/node_modules/@openclaw/fs-safe/dist/watch-types.js +1 -0
- package/node_modules/@openclaw/fs-safe/dist/watch.d.ts +5 -0
- package/node_modules/@openclaw/fs-safe/dist/watch.js +667 -0
- package/node_modules/@openclaw/fs-safe/dist/windows-appcontainer.d.ts +5 -0
- package/node_modules/@openclaw/fs-safe/dist/windows-appcontainer.js +39 -0
- package/node_modules/@openclaw/fs-safe/dist/windows-command.d.ts +1 -0
- package/node_modules/@openclaw/fs-safe/dist/windows-command.js +34 -0
- package/node_modules/@openclaw/fs-safe/dist/windows-owner.d.ts +26 -0
- package/node_modules/@openclaw/fs-safe/dist/windows-owner.js +90 -0
- package/node_modules/@openclaw/fs-safe/dist/windows-path-alias.d.ts +47 -0
- package/node_modules/@openclaw/fs-safe/dist/windows-path-alias.js +140 -0
- package/node_modules/@openclaw/fs-safe/dist/windows-path-syntax.d.ts +18 -0
- package/node_modules/@openclaw/fs-safe/dist/windows-path-syntax.js +72 -0
- package/node_modules/@openclaw/fs-safe/dist/windows-security-command.d.ts +33 -0
- package/node_modules/@openclaw/fs-safe/dist/windows-security-command.js +433 -0
- package/node_modules/@openclaw/fs-safe/dist/windows-security-facts.d.ts +10 -0
- package/node_modules/@openclaw/fs-safe/dist/windows-security-facts.js +117 -0
- package/node_modules/@openclaw/fs-safe/dist/windows-security-helper.d.ts +2 -0
- package/node_modules/@openclaw/fs-safe/dist/windows-security-helper.exe +0 -0
- package/node_modules/@openclaw/fs-safe/dist/windows-security-helper.js +7 -0
- package/node_modules/@openclaw/fs-safe/dist/windows-test-hooks.d.ts +16 -0
- package/node_modules/@openclaw/fs-safe/dist/windows-test-hooks.js +51 -0
- package/node_modules/@openclaw/fs-safe/dist/write-file-handle.d.ts +13 -0
- package/node_modules/@openclaw/fs-safe/dist/write-file-handle.js +49 -0
- package/node_modules/@openclaw/fs-safe/dist/write-open-flags.d.ts +4 -0
- package/node_modules/@openclaw/fs-safe/dist/write-open-flags.js +27 -0
- package/node_modules/@openclaw/fs-safe/dist/write-queue.d.ts +1 -0
- package/node_modules/@openclaw/fs-safe/dist/write-queue.js +15 -0
- package/node_modules/@openclaw/fs-safe/docs/advanced.md +285 -0
- package/node_modules/@openclaw/fs-safe/docs/archive.md +879 -0
- package/node_modules/@openclaw/fs-safe/docs/assets/readme-banner.jpg +0 -0
- package/node_modules/@openclaw/fs-safe/docs/atomic.md +635 -0
- package/node_modules/@openclaw/fs-safe/docs/compiler-qualification.md +392 -0
- package/node_modules/@openclaw/fs-safe/docs/config.md +204 -0
- package/node_modules/@openclaw/fs-safe/docs/contributing.md +445 -0
- package/node_modules/@openclaw/fs-safe/docs/copy.md +357 -0
- package/node_modules/@openclaw/fs-safe/docs/creation.md +132 -0
- package/node_modules/@openclaw/fs-safe/docs/directory-identity.md +85 -0
- package/node_modules/@openclaw/fs-safe/docs/durability.md +500 -0
- package/node_modules/@openclaw/fs-safe/docs/entries.md +109 -0
- package/node_modules/@openclaw/fs-safe/docs/entry-publication.md +146 -0
- package/node_modules/@openclaw/fs-safe/docs/errors.md +316 -0
- package/node_modules/@openclaw/fs-safe/docs/file-contents.md +68 -0
- package/node_modules/@openclaw/fs-safe/docs/file-store.md +404 -0
- package/node_modules/@openclaw/fs-safe/docs/filename.md +110 -0
- package/node_modules/@openclaw/fs-safe/docs/guest.md +171 -0
- package/node_modules/@openclaw/fs-safe/docs/in-place-write.md +112 -0
- package/node_modules/@openclaw/fs-safe/docs/index.md +58 -0
- package/node_modules/@openclaw/fs-safe/docs/install-path.md +216 -0
- package/node_modules/@openclaw/fs-safe/docs/install.md +251 -0
- package/node_modules/@openclaw/fs-safe/docs/json-store.md +245 -0
- package/node_modules/@openclaw/fs-safe/docs/json.md +229 -0
- package/node_modules/@openclaw/fs-safe/docs/local-roots.md +149 -0
- package/node_modules/@openclaw/fs-safe/docs/migrating-to-0.5.md +207 -0
- package/node_modules/@openclaw/fs-safe/docs/migrating-to-0.6.md +48 -0
- package/node_modules/@openclaw/fs-safe/docs/native-helper.md +209 -0
- package/node_modules/@openclaw/fs-safe/docs/native.md +657 -0
- package/node_modules/@openclaw/fs-safe/docs/output.md +195 -0
- package/node_modules/@openclaw/fs-safe/docs/path-case.md +64 -0
- package/node_modules/@openclaw/fs-safe/docs/path-prefix.md +84 -0
- package/node_modules/@openclaw/fs-safe/docs/path-scope.md +163 -0
- package/node_modules/@openclaw/fs-safe/docs/path-suffix-aliases.md +204 -0
- package/node_modules/@openclaw/fs-safe/docs/path.md +222 -0
- package/node_modules/@openclaw/fs-safe/docs/permissions.md +428 -0
- package/node_modules/@openclaw/fs-safe/docs/pipe.md +81 -0
- package/node_modules/@openclaw/fs-safe/docs/platform-capabilities.md +63 -0
- package/node_modules/@openclaw/fs-safe/docs/positional-read.md +63 -0
- package/node_modules/@openclaw/fs-safe/docs/public-api.md +201 -0
- package/node_modules/@openclaw/fs-safe/docs/queue-link-free-design.md +237 -0
- package/node_modules/@openclaw/fs-safe/docs/quickstart.md +174 -0
- package/node_modules/@openclaw/fs-safe/docs/reading.md +256 -0
- package/node_modules/@openclaw/fs-safe/docs/regular-file.md +195 -0
- package/node_modules/@openclaw/fs-safe/docs/retained-file.md +115 -0
- package/node_modules/@openclaw/fs-safe/docs/root.md +413 -0
- package/node_modules/@openclaw/fs-safe/docs/secret-file.md +322 -0
- package/node_modules/@openclaw/fs-safe/docs/secure-file.md +112 -0
- package/node_modules/@openclaw/fs-safe/docs/security-model.md +428 -0
- package/node_modules/@openclaw/fs-safe/docs/sidecar-lock.md +659 -0
- package/node_modules/@openclaw/fs-safe/docs/staged-file.md +219 -0
- package/node_modules/@openclaw/fs-safe/docs/staged-symlink.md +124 -0
- package/node_modules/@openclaw/fs-safe/docs/store.md +144 -0
- package/node_modules/@openclaw/fs-safe/docs/temp.md +810 -0
- package/node_modules/@openclaw/fs-safe/docs/testing.md +444 -0
- package/node_modules/@openclaw/fs-safe/docs/timing.md +123 -0
- package/node_modules/@openclaw/fs-safe/docs/types.md +178 -0
- package/node_modules/@openclaw/fs-safe/docs/walk.md +314 -0
- package/node_modules/@openclaw/fs-safe/docs/watch.md +394 -0
- package/node_modules/@openclaw/fs-safe/docs/writing.md +959 -0
- package/node_modules/@openclaw/fs-safe/package.json +219 -0
- package/node_modules/@openclaw/fs-safe-linux-x64-gnu/fs-safe-native.node +0 -0
- package/node_modules/@openclaw/fs-safe-linux-x64-gnu/package.json +32 -0
- package/node_modules/acpx/LICENSE +21 -0
- package/node_modules/acpx/README.md +142 -0
- package/node_modules/acpx/dist/agent-registry-CxpAF3nI.js +844 -0
- package/node_modules/acpx/dist/agent-registry-CxpAF3nI.js.map +1 -0
- package/node_modules/acpx/dist/agent-registry.d.ts +69 -0
- package/node_modules/acpx/dist/agent-registry.d.ts.map +1 -0
- package/node_modules/acpx/dist/agent-registry.js +1 -0
- package/node_modules/acpx/dist/cli-DeYZhjw6.js +187 -0
- package/node_modules/acpx/dist/cli-DeYZhjw6.js.map +1 -0
- package/node_modules/acpx/dist/cli.d.ts +9 -0
- package/node_modules/acpx/dist/cli.d.ts.map +1 -0
- package/node_modules/acpx/dist/cli.js +2573 -0
- package/node_modules/acpx/dist/cli.js.map +1 -0
- package/node_modules/acpx/dist/client-BqZW_W14.d.ts +217 -0
- package/node_modules/acpx/dist/client-BqZW_W14.d.ts.map +1 -0
- package/node_modules/acpx/dist/flows-Bxlp6H8u.js +2541 -0
- package/node_modules/acpx/dist/flows-Bxlp6H8u.js.map +1 -0
- package/node_modules/acpx/dist/flows.d.ts +344 -0
- package/node_modules/acpx/dist/flows.d.ts.map +1 -0
- package/node_modules/acpx/dist/flows.js +1 -0
- package/node_modules/acpx/dist/invocation-options-8lEkbe7g.js +349 -0
- package/node_modules/acpx/dist/invocation-options-8lEkbe7g.js.map +1 -0
- package/node_modules/acpx/dist/ipc-CQUNQ8QQ.js +5304 -0
- package/node_modules/acpx/dist/ipc-CQUNQ8QQ.js.map +1 -0
- package/node_modules/acpx/dist/output-C_T39Ap1.js +1055 -0
- package/node_modules/acpx/dist/output-C_T39Ap1.js.map +1 -0
- package/node_modules/acpx/dist/queue-owner-runtime-ucHvXJ33.js +8387 -0
- package/node_modules/acpx/dist/queue-owner-runtime-ucHvXJ33.js.map +1 -0
- package/node_modules/acpx/dist/runtime.d.ts +899 -0
- package/node_modules/acpx/dist/runtime.d.ts.map +1 -0
- package/node_modules/acpx/dist/runtime.js +2896 -0
- package/node_modules/acpx/dist/runtime.js.map +1 -0
- package/node_modules/acpx/dist/session-options-D9KL7-d8.d.ts +371 -0
- package/node_modules/acpx/dist/session-options-D9KL7-d8.d.ts.map +1 -0
- package/node_modules/acpx/dist/session-watch-D0YvKsnQ.js +75 -0
- package/node_modules/acpx/dist/session-watch-D0YvKsnQ.js.map +1 -0
- package/node_modules/acpx/dist/watch-CXy2A5VY.js +84 -0
- package/node_modules/acpx/dist/watch-CXy2A5VY.js.map +1 -0
- package/node_modules/acpx/package.json +131 -0
- package/node_modules/acpx/skills/acpx/SKILL.md +722 -0
- package/node_modules/b4a/LICENSE +201 -0
- package/node_modules/b4a/README.md +153 -0
- package/node_modules/b4a/browser.js +546 -0
- package/node_modules/b4a/index.d.ts +144 -0
- package/node_modules/b4a/index.js +193 -0
- package/node_modules/b4a/lib/ascii.js +31 -0
- package/node_modules/b4a/lib/base64.js +64 -0
- package/node_modules/b4a/lib/hex.js +51 -0
- package/node_modules/b4a/lib/latin1.js +31 -0
- package/node_modules/b4a/lib/utf16le.js +40 -0
- package/node_modules/b4a/lib/utf8.js +144 -0
- package/node_modules/b4a/package.json +54 -0
- package/node_modules/b4a/react-native.js +5 -0
- package/node_modules/b4a/runtime.d.ts +14 -0
- package/node_modules/bare-buffer/CMakeLists.txt +20 -0
- package/node_modules/bare-buffer/LICENSE +201 -0
- package/node_modules/bare-buffer/README.md +30 -0
- package/node_modules/bare-buffer/binding.c +2041 -0
- package/node_modules/bare-buffer/binding.js +1 -0
- package/node_modules/bare-buffer/global.d.ts +21 -0
- package/node_modules/bare-buffer/global.js +6 -0
- package/node_modules/bare-buffer/index.d.ts +769 -0
- package/node_modules/bare-buffer/index.js +1339 -0
- package/node_modules/bare-buffer/lib/ascii.js +36 -0
- package/node_modules/bare-buffer/lib/base64.js +25 -0
- package/node_modules/bare-buffer/lib/base64url.js +25 -0
- package/node_modules/bare-buffer/lib/checked.js +23 -0
- package/node_modules/bare-buffer/lib/constants.d.ts +7 -0
- package/node_modules/bare-buffer/lib/constants.js +3 -0
- package/node_modules/bare-buffer/lib/hex.js +20 -0
- package/node_modules/bare-buffer/lib/latin1.js +14 -0
- package/node_modules/bare-buffer/lib/utf16le.js +20 -0
- package/node_modules/bare-buffer/lib/utf8.js +18 -0
- package/node_modules/bare-buffer/package.json +59 -0
- package/node_modules/bare-buffer/prebuilds/android-arm/bare-buffer.bare +0 -0
- package/node_modules/bare-buffer/prebuilds/android-arm64/bare-buffer.bare +0 -0
- package/node_modules/bare-buffer/prebuilds/android-ia32/bare-buffer.bare +0 -0
- package/node_modules/bare-buffer/prebuilds/android-x64/bare-buffer.bare +0 -0
- package/node_modules/bare-buffer/prebuilds/darwin-arm64/bare-buffer.bare +0 -0
- package/node_modules/bare-buffer/prebuilds/darwin-x64/bare-buffer.bare +0 -0
- package/node_modules/bare-buffer/prebuilds/ios-arm64/bare-buffer.bare +0 -0
- package/node_modules/bare-buffer/prebuilds/ios-arm64-simulator/bare-buffer.bare +0 -0
- package/node_modules/bare-buffer/prebuilds/ios-x64-simulator/bare-buffer.bare +0 -0
- package/node_modules/bare-buffer/prebuilds/linux-arm64/bare-buffer.bare +0 -0
- package/node_modules/bare-buffer/prebuilds/linux-x64/bare-buffer.bare +0 -0
- package/node_modules/bare-buffer/prebuilds/win32-arm64/bare-buffer.bare +0 -0
- package/node_modules/bare-buffer/prebuilds/win32-x64/bare-buffer.bare +0 -0
- package/node_modules/bare-events/LICENSE +201 -0
- package/node_modules/bare-events/README.md +29 -0
- package/node_modules/bare-events/global.d.ts +15 -0
- package/node_modules/bare-events/global.js +5 -0
- package/node_modules/bare-events/index.d.ts +246 -0
- package/node_modules/bare-events/index.js +423 -0
- package/node_modules/bare-events/lib/errors.js +23 -0
- package/node_modules/bare-events/package.json +63 -0
- package/node_modules/bare-events/web.d.ts +108 -0
- package/node_modules/bare-events/web.js +417 -0
- package/node_modules/bare-fs/CMakeLists.txt +13 -0
- package/node_modules/bare-fs/LICENSE +201 -0
- package/node_modules/bare-fs/README.md +33 -0
- package/node_modules/bare-fs/binding.c +3055 -0
- package/node_modules/bare-fs/binding.js +1 -0
- package/node_modules/bare-fs/index.d.ts +1504 -0
- package/node_modules/bare-fs/index.js +2902 -0
- package/node_modules/bare-fs/lib/constants.d.ts +50 -0
- package/node_modules/bare-fs/lib/constants.js +49 -0
- package/node_modules/bare-fs/lib/errors.d.ts +13 -0
- package/node_modules/bare-fs/lib/errors.js +55 -0
- package/node_modules/bare-fs/lib/queue.js +29 -0
- package/node_modules/bare-fs/package.json +74 -0
- package/node_modules/bare-fs/prebuilds/android-arm/bare-fs.bare +0 -0
- package/node_modules/bare-fs/prebuilds/android-arm64/bare-fs.bare +0 -0
- package/node_modules/bare-fs/prebuilds/android-ia32/bare-fs.bare +0 -0
- package/node_modules/bare-fs/prebuilds/android-x64/bare-fs.bare +0 -0
- package/node_modules/bare-fs/prebuilds/darwin-arm64/bare-fs.bare +0 -0
- package/node_modules/bare-fs/prebuilds/darwin-x64/bare-fs.bare +0 -0
- package/node_modules/bare-fs/prebuilds/ios-arm64/bare-fs.bare +0 -0
- package/node_modules/bare-fs/prebuilds/ios-arm64-simulator/bare-fs.bare +0 -0
- package/node_modules/bare-fs/prebuilds/ios-x64-simulator/bare-fs.bare +0 -0
- package/node_modules/bare-fs/prebuilds/linux-arm64/bare-fs.bare +0 -0
- package/node_modules/bare-fs/prebuilds/linux-x64/bare-fs.bare +0 -0
- package/node_modules/bare-fs/prebuilds/win32-arm64/bare-fs.bare +0 -0
- package/node_modules/bare-fs/prebuilds/win32-x64/bare-fs.bare +0 -0
- package/node_modules/bare-fs/promises.d.ts +480 -0
- package/node_modules/bare-fs/promises.js +119 -0
- package/node_modules/bare-path/CMakeLists.txt +13 -0
- package/node_modules/bare-path/LICENSE +201 -0
- package/node_modules/bare-path/NOTICE +28 -0
- package/node_modules/bare-path/README.md +27 -0
- package/node_modules/bare-path/binding.c +127 -0
- package/node_modules/bare-path/binding.js +1 -0
- package/node_modules/bare-path/index.d.ts +91 -0
- package/node_modules/bare-path/index.js +9 -0
- package/node_modules/bare-path/lib/constants.js +11 -0
- package/node_modules/bare-path/lib/posix.js +263 -0
- package/node_modules/bare-path/lib/shared.js +81 -0
- package/node_modules/bare-path/lib/win32.js +564 -0
- package/node_modules/bare-path/package.json +47 -0
- package/node_modules/bare-path/prebuilds/android-arm/bare-path.bare +0 -0
- package/node_modules/bare-path/prebuilds/android-arm64/bare-path.bare +0 -0
- package/node_modules/bare-path/prebuilds/android-ia32/bare-path.bare +0 -0
- package/node_modules/bare-path/prebuilds/android-x64/bare-path.bare +0 -0
- package/node_modules/bare-path/prebuilds/darwin-arm64/bare-path.bare +0 -0
- package/node_modules/bare-path/prebuilds/darwin-x64/bare-path.bare +0 -0
- package/node_modules/bare-path/prebuilds/ios-arm64/bare-path.bare +0 -0
- package/node_modules/bare-path/prebuilds/ios-arm64-simulator/bare-path.bare +0 -0
- package/node_modules/bare-path/prebuilds/ios-x64-simulator/bare-path.bare +0 -0
- package/node_modules/bare-path/prebuilds/linux-arm64/bare-path.bare +0 -0
- package/node_modules/bare-path/prebuilds/linux-x64/bare-path.bare +0 -0
- package/node_modules/bare-path/prebuilds/win32-arm64/bare-path.bare +0 -0
- package/node_modules/bare-path/prebuilds/win32-x64/bare-path.bare +0 -0
- package/node_modules/bare-stream/LICENSE +201 -0
- package/node_modules/bare-stream/README.md +354 -0
- package/node_modules/bare-stream/global.d.ts +31 -0
- package/node_modules/bare-stream/global.js +15 -0
- package/node_modules/bare-stream/index.d.ts +235 -0
- package/node_modules/bare-stream/index.js +493 -0
- package/node_modules/bare-stream/package.json +75 -0
- package/node_modules/bare-stream/promises.js +3 -0
- package/node_modules/bare-stream/web.d.ts +152 -0
- package/node_modules/bare-stream/web.js +607 -0
- package/node_modules/bare-url/CMakeLists.txt +36 -0
- package/node_modules/bare-url/LICENSE +201 -0
- package/node_modules/bare-url/README.md +37 -0
- package/node_modules/bare-url/binding.c +465 -0
- package/node_modules/bare-url/binding.js +1 -0
- package/node_modules/bare-url/global.d.ts +24 -0
- package/node_modules/bare-url/global.js +2 -0
- package/node_modules/bare-url/index.d.ts +115 -0
- package/node_modules/bare-url/index.js +734 -0
- package/node_modules/bare-url/lib/errors.d.ts +10 -0
- package/node_modules/bare-url/lib/errors.js +37 -0
- package/node_modules/bare-url/lib/url-search-params.d.ts +66 -0
- package/node_modules/bare-url/lib/url-search-params.js +291 -0
- package/node_modules/bare-url/package.json +55 -0
- package/node_modules/bare-url/prebuilds/android-arm/bare-url.bare +0 -0
- package/node_modules/bare-url/prebuilds/android-arm64/bare-url.bare +0 -0
- package/node_modules/bare-url/prebuilds/android-ia32/bare-url.bare +0 -0
- package/node_modules/bare-url/prebuilds/android-x64/bare-url.bare +0 -0
- package/node_modules/bare-url/prebuilds/darwin-arm64/bare-url.bare +0 -0
- package/node_modules/bare-url/prebuilds/darwin-x64/bare-url.bare +0 -0
- package/node_modules/bare-url/prebuilds/ios-arm64/bare-url.bare +0 -0
- package/node_modules/bare-url/prebuilds/ios-arm64-simulator/bare-url.bare +0 -0
- package/node_modules/bare-url/prebuilds/ios-x64-simulator/bare-url.bare +0 -0
- package/node_modules/bare-url/prebuilds/linux-arm64/bare-url.bare +0 -0
- package/node_modules/bare-url/prebuilds/linux-x64/bare-url.bare +0 -0
- package/node_modules/bare-url/prebuilds/win32-arm64/bare-url.bare +0 -0
- package/node_modules/bare-url/prebuilds/win32-x64/bare-url.bare +0 -0
- package/node_modules/commander/LICENSE +22 -0
- package/node_modules/commander/Readme.md +1146 -0
- package/node_modules/commander/index.js +21 -0
- package/node_modules/commander/lib/argument.js +147 -0
- package/node_modules/commander/lib/command.js +2803 -0
- package/node_modules/commander/lib/error.js +36 -0
- package/node_modules/commander/lib/help.js +735 -0
- package/node_modules/commander/lib/option.js +377 -0
- package/node_modules/commander/lib/suggestSimilar.js +99 -0
- package/node_modules/commander/package-support.json +19 -0
- package/node_modules/commander/package.json +65 -0
- package/node_modules/commander/typings/index.d.ts +1116 -0
- package/node_modules/core-util-is/LICENSE +19 -0
- package/node_modules/core-util-is/README.md +3 -0
- package/node_modules/core-util-is/lib/util.js +107 -0
- package/node_modules/core-util-is/package.json +38 -0
- package/node_modules/esbuild/LICENSE.md +21 -0
- package/node_modules/esbuild/README.md +3 -0
- package/node_modules/esbuild/bin/esbuild +223 -0
- package/node_modules/esbuild/install.js +300 -0
- package/node_modules/esbuild/lib/main.d.ts +720 -0
- package/node_modules/esbuild/lib/main.js +2536 -0
- package/node_modules/esbuild/package.json +74 -0
- package/node_modules/events-universal/LICENSE +201 -0
- package/node_modules/events-universal/README.md +17 -0
- package/node_modules/events-universal/bare.js +1 -0
- package/node_modules/events-universal/default.js +1 -0
- package/node_modules/events-universal/index.js +1 -0
- package/node_modules/events-universal/package.json +39 -0
- package/node_modules/events-universal/react-native.js +1 -0
- package/node_modules/fast-fifo/LICENSE +21 -0
- package/node_modules/fast-fifo/README.md +78 -0
- package/node_modules/fast-fifo/fixed-size.js +39 -0
- package/node_modules/fast-fifo/index.js +48 -0
- package/node_modules/fast-fifo/package.json +28 -0
- package/node_modules/fast-string-truncated-width/dist/index.d.ts +4 -0
- package/node_modules/fast-string-truncated-width/dist/index.js +111 -0
- package/node_modules/fast-string-truncated-width/dist/types.d.ts +19 -0
- package/node_modules/fast-string-truncated-width/dist/types.js +2 -0
- package/node_modules/fast-string-truncated-width/dist/utils.d.ts +4 -0
- package/node_modules/fast-string-truncated-width/dist/utils.js +20 -0
- package/node_modules/fast-string-truncated-width/license +21 -0
- package/node_modules/fast-string-truncated-width/package.json +35 -0
- package/node_modules/fast-string-truncated-width/readme.md +59 -0
- package/node_modules/fast-string-width/dist/index.d.ts +4 -0
- package/node_modules/fast-string-width/dist/index.js +14 -0
- package/node_modules/fast-string-width/license +21 -0
- package/node_modules/fast-string-width/package.json +34 -0
- package/node_modules/fast-string-width/readme.md +42 -0
- package/node_modules/fast-wrap-ansi/LICENSE +23 -0
- package/node_modules/fast-wrap-ansi/README.md +26 -0
- package/node_modules/fast-wrap-ansi/lib/main.d.ts +6 -0
- package/node_modules/fast-wrap-ansi/lib/main.js +218 -0
- package/node_modules/fast-wrap-ansi/package.json +51 -0
- package/node_modules/immediate/LICENSE.txt +20 -0
- package/node_modules/immediate/README.md +93 -0
- package/node_modules/immediate/dist/immediate.js +75 -0
- package/node_modules/immediate/dist/immediate.min.js +1 -0
- package/node_modules/immediate/lib/browser.js +69 -0
- package/node_modules/immediate/lib/index.js +73 -0
- package/node_modules/immediate/package.json +42 -0
- package/node_modules/inherits/LICENSE +16 -0
- package/node_modules/inherits/README.md +42 -0
- package/node_modules/inherits/inherits.js +9 -0
- package/node_modules/inherits/inherits_browser.js +27 -0
- package/node_modules/inherits/package.json +29 -0
- package/node_modules/isarray/.npmignore +1 -0
- package/node_modules/isarray/.travis.yml +4 -0
- package/node_modules/isarray/Makefile +6 -0
- package/node_modules/isarray/README.md +60 -0
- package/node_modules/isarray/component.json +19 -0
- package/node_modules/isarray/index.js +5 -0
- package/node_modules/isarray/package.json +45 -0
- package/node_modules/isarray/test.js +20 -0
- package/node_modules/jszip/.codeclimate.yml +16 -0
- package/node_modules/jszip/.editorconfig +8 -0
- package/node_modules/jszip/.eslintrc.js +43 -0
- package/node_modules/jszip/.github/FUNDING.yml +1 -0
- package/node_modules/jszip/.github/actions/setup/action.yml +23 -0
- package/node_modules/jszip/.github/workflows/benchmark.yml +38 -0
- package/node_modules/jszip/.github/workflows/main.yml +55 -0
- package/node_modules/jszip/CHANGES.md +210 -0
- package/node_modules/jszip/LICENSE.markdown +651 -0
- package/node_modules/jszip/README.markdown +33 -0
- package/node_modules/jszip/dist/jszip.js +11586 -0
- package/node_modules/jszip/dist/jszip.min.js +13 -0
- package/node_modules/jszip/index.d.ts +344 -0
- package/node_modules/jszip/lib/base64.js +106 -0
- package/node_modules/jszip/lib/compressedObject.js +74 -0
- package/node_modules/jszip/lib/compressions.js +14 -0
- package/node_modules/jszip/lib/crc32.js +77 -0
- package/node_modules/jszip/lib/defaults.js +11 -0
- package/node_modules/jszip/lib/external.js +18 -0
- package/node_modules/jszip/lib/flate.js +85 -0
- package/node_modules/jszip/lib/generate/ZipFileWorker.js +539 -0
- package/node_modules/jszip/lib/generate/index.js +57 -0
- package/node_modules/jszip/lib/index.js +55 -0
- package/node_modules/jszip/lib/license_header.js +11 -0
- package/node_modules/jszip/lib/load.js +88 -0
- package/node_modules/jszip/lib/nodejs/NodejsStreamInputAdapter.js +74 -0
- package/node_modules/jszip/lib/nodejs/NodejsStreamOutputAdapter.js +42 -0
- package/node_modules/jszip/lib/nodejsUtils.js +57 -0
- package/node_modules/jszip/lib/object.js +384 -0
- package/node_modules/jszip/lib/readable-stream-browser.js +10 -0
- package/node_modules/jszip/lib/reader/ArrayReader.js +57 -0
- package/node_modules/jszip/lib/reader/DataReader.js +116 -0
- package/node_modules/jszip/lib/reader/NodeBufferReader.js +19 -0
- package/node_modules/jszip/lib/reader/StringReader.js +38 -0
- package/node_modules/jszip/lib/reader/Uint8ArrayReader.js +22 -0
- package/node_modules/jszip/lib/reader/readerFor.js +28 -0
- package/node_modules/jszip/lib/signature.js +7 -0
- package/node_modules/jszip/lib/stream/ConvertWorker.js +26 -0
- package/node_modules/jszip/lib/stream/Crc32Probe.js +24 -0
- package/node_modules/jszip/lib/stream/DataLengthProbe.js +29 -0
- package/node_modules/jszip/lib/stream/DataWorker.js +116 -0
- package/node_modules/jszip/lib/stream/GenericWorker.js +263 -0
- package/node_modules/jszip/lib/stream/StreamHelper.js +214 -0
- package/node_modules/jszip/lib/support.js +38 -0
- package/node_modules/jszip/lib/utf8.js +275 -0
- package/node_modules/jszip/lib/utils.js +510 -0
- package/node_modules/jszip/lib/zipEntries.js +261 -0
- package/node_modules/jszip/lib/zipEntry.js +293 -0
- package/node_modules/jszip/lib/zipObject.js +133 -0
- package/node_modules/jszip/package.json +67 -0
- package/node_modules/jszip/sponsors.md +21 -0
- package/node_modules/jszip/tsconfig.json +101 -0
- package/node_modules/jszip/vendor/FileSaver.js +247 -0
- package/node_modules/lie/README.md +62 -0
- package/node_modules/lie/dist/lie.js +350 -0
- package/node_modules/lie/dist/lie.min.js +1 -0
- package/node_modules/lie/dist/lie.polyfill.js +358 -0
- package/node_modules/lie/dist/lie.polyfill.min.js +1 -0
- package/node_modules/lie/lib/browser.js +273 -0
- package/node_modules/lie/lib/index.js +298 -0
- package/node_modules/lie/license.md +7 -0
- package/node_modules/lie/lie.d.ts +244 -0
- package/node_modules/lie/package.json +69 -0
- package/node_modules/lie/polyfill.js +4 -0
- package/node_modules/pako/LICENSE +21 -0
- package/node_modules/pako/README.md +191 -0
- package/node_modules/pako/dist/pako.js +6818 -0
- package/node_modules/pako/dist/pako.min.js +1 -0
- package/node_modules/pako/dist/pako_deflate.js +3997 -0
- package/node_modules/pako/dist/pako_deflate.min.js +1 -0
- package/node_modules/pako/dist/pako_inflate.js +3300 -0
- package/node_modules/pako/dist/pako_inflate.min.js +1 -0
- package/node_modules/pako/index.js +14 -0
- package/node_modules/pako/lib/deflate.js +400 -0
- package/node_modules/pako/lib/inflate.js +423 -0
- package/node_modules/pako/lib/utils/common.js +105 -0
- package/node_modules/pako/lib/utils/strings.js +187 -0
- package/node_modules/pako/lib/zlib/README +59 -0
- package/node_modules/pako/lib/zlib/adler32.js +51 -0
- package/node_modules/pako/lib/zlib/constants.js +68 -0
- package/node_modules/pako/lib/zlib/crc32.js +59 -0
- package/node_modules/pako/lib/zlib/deflate.js +1874 -0
- package/node_modules/pako/lib/zlib/gzheader.js +58 -0
- package/node_modules/pako/lib/zlib/inffast.js +345 -0
- package/node_modules/pako/lib/zlib/inflate.js +1556 -0
- package/node_modules/pako/lib/zlib/inftrees.js +343 -0
- package/node_modules/pako/lib/zlib/messages.js +32 -0
- package/node_modules/pako/lib/zlib/trees.js +1222 -0
- package/node_modules/pako/lib/zlib/zstream.js +47 -0
- package/node_modules/pako/package.json +44 -0
- package/node_modules/process-nextick-args/index.js +45 -0
- package/node_modules/process-nextick-args/license.md +19 -0
- package/node_modules/process-nextick-args/package.json +25 -0
- package/node_modules/process-nextick-args/readme.md +18 -0
- package/node_modules/readable-stream/.travis.yml +34 -0
- package/node_modules/readable-stream/CONTRIBUTING.md +38 -0
- package/node_modules/readable-stream/GOVERNANCE.md +136 -0
- package/node_modules/readable-stream/LICENSE +47 -0
- package/node_modules/readable-stream/README.md +58 -0
- package/node_modules/readable-stream/doc/wg-meetings/2015-01-30.md +60 -0
- package/node_modules/readable-stream/duplex-browser.js +1 -0
- package/node_modules/readable-stream/duplex.js +1 -0
- package/node_modules/readable-stream/lib/_stream_duplex.js +131 -0
- package/node_modules/readable-stream/lib/_stream_passthrough.js +47 -0
- package/node_modules/readable-stream/lib/_stream_readable.js +1019 -0
- package/node_modules/readable-stream/lib/_stream_transform.js +214 -0
- package/node_modules/readable-stream/lib/_stream_writable.js +685 -0
- package/node_modules/readable-stream/lib/internal/streams/BufferList.js +78 -0
- package/node_modules/readable-stream/lib/internal/streams/destroy.js +84 -0
- package/node_modules/readable-stream/lib/internal/streams/stream-browser.js +1 -0
- package/node_modules/readable-stream/lib/internal/streams/stream.js +1 -0
- package/node_modules/readable-stream/package.json +52 -0
- package/node_modules/readable-stream/passthrough.js +1 -0
- package/node_modules/readable-stream/readable-browser.js +7 -0
- package/node_modules/readable-stream/readable.js +19 -0
- package/node_modules/readable-stream/transform.js +1 -0
- package/node_modules/readable-stream/writable-browser.js +1 -0
- package/node_modules/readable-stream/writable.js +8 -0
- package/node_modules/safe-buffer/LICENSE +21 -0
- package/node_modules/safe-buffer/README.md +584 -0
- package/node_modules/safe-buffer/index.d.ts +187 -0
- package/node_modules/safe-buffer/index.js +62 -0
- package/node_modules/safe-buffer/package.json +37 -0
- package/node_modules/setimmediate/LICENSE.txt +20 -0
- package/node_modules/setimmediate/package.json +30 -0
- package/node_modules/setimmediate/setImmediate.js +186 -0
- package/node_modules/sisteransi/dist/index.d.ts +33 -0
- package/node_modules/sisteransi/dist/index.js +57 -0
- package/node_modules/sisteransi/license +21 -0
- package/node_modules/sisteransi/package.json +45 -0
- package/node_modules/sisteransi/readme.md +126 -0
- package/node_modules/skillflag/LICENSE +21 -0
- package/node_modules/skillflag/README.md +44 -0
- package/node_modules/skillflag/dist/bin/skill-install.d.ts +3 -0
- package/node_modules/skillflag/dist/bin/skill-install.d.ts.map +1 -0
- package/node_modules/skillflag/dist/bin/skill-install.js +6 -0
- package/node_modules/skillflag/dist/bin/skill-install.js.map +1 -0
- package/node_modules/skillflag/dist/bin/skillflag.d.ts +3 -0
- package/node_modules/skillflag/dist/bin/skillflag.d.ts.map +1 -0
- package/node_modules/skillflag/dist/bin/skillflag.js +25 -0
- package/node_modules/skillflag/dist/bin/skillflag.js.map +1 -0
- package/node_modules/skillflag/dist/core/digest.d.ts +2 -0
- package/node_modules/skillflag/dist/core/digest.d.ts.map +1 -0
- package/node_modules/skillflag/dist/core/digest.js +15 -0
- package/node_modules/skillflag/dist/core/digest.js.map +1 -0
- package/node_modules/skillflag/dist/core/errors.d.ts +6 -0
- package/node_modules/skillflag/dist/core/errors.d.ts.map +1 -0
- package/node_modules/skillflag/dist/core/errors.js +13 -0
- package/node_modules/skillflag/dist/core/errors.js.map +1 -0
- package/node_modules/skillflag/dist/core/export.d.ts +2 -0
- package/node_modules/skillflag/dist/core/export.d.ts.map +1 -0
- package/node_modules/skillflag/dist/core/export.js +28 -0
- package/node_modules/skillflag/dist/core/export.js.map +1 -0
- package/node_modules/skillflag/dist/core/list.d.ts +21 -0
- package/node_modules/skillflag/dist/core/list.d.ts.map +1 -0
- package/node_modules/skillflag/dist/core/list.js +71 -0
- package/node_modules/skillflag/dist/core/list.js.map +1 -0
- package/node_modules/skillflag/dist/core/paths.d.ts +15 -0
- package/node_modules/skillflag/dist/core/paths.d.ts.map +1 -0
- package/node_modules/skillflag/dist/core/paths.js +149 -0
- package/node_modules/skillflag/dist/core/paths.js.map +1 -0
- package/node_modules/skillflag/dist/core/show.d.ts +2 -0
- package/node_modules/skillflag/dist/core/show.d.ts.map +1 -0
- package/node_modules/skillflag/dist/core/show.js +8 -0
- package/node_modules/skillflag/dist/core/show.js.map +1 -0
- package/node_modules/skillflag/dist/core/skillflag.d.ts +3 -0
- package/node_modules/skillflag/dist/core/skillflag.d.ts.map +1 -0
- package/node_modules/skillflag/dist/core/skillflag.js +2 -0
- package/node_modules/skillflag/dist/core/skillflag.js.map +1 -0
- package/node_modules/skillflag/dist/core/tar.d.ts +16 -0
- package/node_modules/skillflag/dist/core/tar.d.ts.map +1 -0
- package/node_modules/skillflag/dist/core/tar.js +140 -0
- package/node_modules/skillflag/dist/core/tar.js.map +1 -0
- package/node_modules/skillflag/dist/index.d.ts +5 -0
- package/node_modules/skillflag/dist/index.d.ts.map +1 -0
- package/node_modules/skillflag/dist/index.js +3 -0
- package/node_modules/skillflag/dist/index.js.map +1 -0
- package/node_modules/skillflag/dist/install/cli.d.ts +57 -0
- package/node_modules/skillflag/dist/install/cli.d.ts.map +1 -0
- package/node_modules/skillflag/dist/install/cli.js +653 -0
- package/node_modules/skillflag/dist/install/cli.js.map +1 -0
- package/node_modules/skillflag/dist/install/copy.d.ts +2 -0
- package/node_modules/skillflag/dist/install/copy.d.ts.map +1 -0
- package/node_modules/skillflag/dist/install/copy.js +19 -0
- package/node_modules/skillflag/dist/install/copy.js.map +1 -0
- package/node_modules/skillflag/dist/install/errors.d.ts +6 -0
- package/node_modules/skillflag/dist/install/errors.d.ts.map +1 -0
- package/node_modules/skillflag/dist/install/errors.js +13 -0
- package/node_modules/skillflag/dist/install/errors.js.map +1 -0
- package/node_modules/skillflag/dist/install/extract.d.ts +3 -0
- package/node_modules/skillflag/dist/install/extract.d.ts.map +1 -0
- package/node_modules/skillflag/dist/install/extract.js +76 -0
- package/node_modules/skillflag/dist/install/extract.js.map +1 -0
- package/node_modules/skillflag/dist/install/install.d.ts +21 -0
- package/node_modules/skillflag/dist/install/install.d.ts.map +1 -0
- package/node_modules/skillflag/dist/install/install.js +35 -0
- package/node_modules/skillflag/dist/install/install.js.map +1 -0
- package/node_modules/skillflag/dist/install/resolve.d.ts +12 -0
- package/node_modules/skillflag/dist/install/resolve.d.ts.map +1 -0
- package/node_modules/skillflag/dist/install/resolve.js +119 -0
- package/node_modules/skillflag/dist/install/resolve.js.map +1 -0
- package/node_modules/skillflag/dist/install/validate.d.ts +7 -0
- package/node_modules/skillflag/dist/install/validate.d.ts.map +1 -0
- package/node_modules/skillflag/dist/install/validate.js +28 -0
- package/node_modules/skillflag/dist/install/validate.js.map +1 -0
- package/node_modules/skillflag/dist/shared/frontmatter.d.ts +2 -0
- package/node_modules/skillflag/dist/shared/frontmatter.d.ts.map +1 -0
- package/node_modules/skillflag/dist/shared/frontmatter.js +28 -0
- package/node_modules/skillflag/dist/shared/frontmatter.js.map +1 -0
- package/node_modules/skillflag/dist/skillflag.d.ts +29 -0
- package/node_modules/skillflag/dist/skillflag.d.ts.map +1 -0
- package/node_modules/skillflag/dist/skillflag.js +230 -0
- package/node_modules/skillflag/dist/skillflag.js.map +1 -0
- package/node_modules/skillflag/dist/utils/collections.d.ts +3 -0
- package/node_modules/skillflag/dist/utils/collections.d.ts.map +1 -0
- package/node_modules/skillflag/dist/utils/collections.js +18 -0
- package/node_modules/skillflag/dist/utils/collections.js.map +1 -0
- package/node_modules/skillflag/package.json +78 -0
- package/node_modules/skillflag/skills/skillflag/SKILL.md +144 -0
- package/node_modules/streamx/LICENSE +21 -0
- package/node_modules/streamx/README.md +550 -0
- package/node_modules/streamx/index.d.ts +198 -0
- package/node_modules/streamx/index.js +1314 -0
- package/node_modules/streamx/lib/errors.d.ts +13 -0
- package/node_modules/streamx/lib/errors.js +47 -0
- package/node_modules/streamx/package.json +51 -0
- package/node_modules/streamx/runtime.d.ts +55 -0
- package/node_modules/string_decoder/.travis.yml +50 -0
- package/node_modules/string_decoder/LICENSE +48 -0
- package/node_modules/string_decoder/README.md +47 -0
- package/node_modules/string_decoder/lib/string_decoder.js +296 -0
- package/node_modules/string_decoder/package.json +31 -0
- package/node_modules/tar-stream/LICENSE +21 -0
- package/node_modules/tar-stream/README.md +183 -0
- package/node_modules/tar-stream/constants.js +14 -0
- package/node_modules/tar-stream/extract.js +439 -0
- package/node_modules/tar-stream/headers.js +322 -0
- package/node_modules/tar-stream/index.d.ts +60 -0
- package/node_modules/tar-stream/index.js +2 -0
- package/node_modules/tar-stream/pack.js +287 -0
- package/node_modules/tar-stream/package.json +50 -0
- package/node_modules/teex/LICENSE +21 -0
- package/node_modules/teex/README.md +31 -0
- package/node_modules/teex/example.js +16 -0
- package/node_modules/teex/index.js +52 -0
- package/node_modules/teex/package.json +26 -0
- package/node_modules/teex/test.js +68 -0
- package/node_modules/text-decoder/LICENSE +201 -0
- package/node_modules/text-decoder/README.md +36 -0
- package/node_modules/text-decoder/index.js +64 -0
- package/node_modules/text-decoder/lib/pass-through-decoder.js +19 -0
- package/node_modules/text-decoder/lib/utf8-decoder.js +185 -0
- package/node_modules/text-decoder/package.json +39 -0
- package/node_modules/tsx/LICENSE +21 -0
- package/node_modules/tsx/README.md +32 -0
- package/node_modules/tsx/dist/cjs/api/index.cjs +2 -0
- package/node_modules/tsx/dist/cjs/api/index.d.cts +35 -0
- package/node_modules/tsx/dist/cjs/api/index.d.mts +35 -0
- package/node_modules/tsx/dist/cjs/api/index.mjs +2 -0
- package/node_modules/tsx/dist/cjs/index.cjs +1 -0
- package/node_modules/tsx/dist/cli.mjs +55 -0
- package/node_modules/tsx/dist/client-XItNFmsq.cjs +1 -0
- package/node_modules/tsx/dist/esm/api/index.cjs +2 -0
- package/node_modules/tsx/dist/esm/api/index.d.cts +37 -0
- package/node_modules/tsx/dist/esm/api/index.d.mts +37 -0
- package/node_modules/tsx/dist/esm/api/index.mjs +2 -0
- package/node_modules/tsx/dist/esm/index.mjs +2 -0
- package/node_modules/tsx/dist/index-Bqjv9TxC.mjs +1 -0
- package/node_modules/tsx/dist/index-DE3OBZuV.mjs +14 -0
- package/node_modules/tsx/dist/lexer-CGfpMDSb.cjs +3 -0
- package/node_modules/tsx/dist/lexer-CanA6ArK.mjs +3 -0
- package/node_modules/tsx/dist/loader.mjs +2 -0
- package/node_modules/tsx/dist/package-Dj0mHsMt.mjs +1 -0
- package/node_modules/tsx/dist/patch-repl.cjs +1 -0
- package/node_modules/tsx/dist/preflight.cjs +1 -0
- package/node_modules/tsx/dist/register-B1c7OH6V.cjs +23 -0
- package/node_modules/tsx/dist/register-nyXW-TH3.mjs +2 -0
- package/node_modules/tsx/dist/repl.mjs +4 -0
- package/node_modules/tsx/dist/require-CBjy4Foe.mjs +10 -0
- package/node_modules/tsx/dist/require-CVaYn9z3.cjs +1 -0
- package/node_modules/tsx/dist/suppress-warnings.cjs +1 -0
- package/node_modules/tsx/dist/temporary-directory-Du7LpLp9.mjs +1 -0
- package/node_modules/tsx/package.json +70 -0
- package/node_modules/util-deprecate/History.md +16 -0
- package/node_modules/util-deprecate/LICENSE +24 -0
- package/node_modules/util-deprecate/README.md +53 -0
- package/node_modules/util-deprecate/browser.js +67 -0
- package/node_modules/util-deprecate/node.js +6 -0
- package/node_modules/util-deprecate/package.json +27 -0
- package/node_modules/zod/LICENSE +21 -0
- package/node_modules/zod/README.md +218 -0
- package/node_modules/zod/compile.cjs +96 -0
- package/node_modules/zod/compile.d.cts +1 -0
- package/node_modules/zod/compile.d.ts +1 -0
- package/node_modules/zod/compile.js +52 -0
- package/node_modules/zod/index.cjs +52 -0
- package/node_modules/zod/index.d.cts +3 -0
- package/node_modules/zod/index.d.ts +3 -0
- package/node_modules/zod/index.js +7 -0
- package/node_modules/zod/locales/index.cjs +36 -0
- package/node_modules/zod/locales/index.d.cts +1 -0
- package/node_modules/zod/locales/index.d.ts +1 -0
- package/node_modules/zod/locales/index.js +1 -0
- package/node_modules/zod/locales/package.json +7 -0
- package/node_modules/zod/mini/index.cjs +51 -0
- package/node_modules/zod/mini/index.d.cts +3 -0
- package/node_modules/zod/mini/index.d.ts +3 -0
- package/node_modules/zod/mini/index.js +3 -0
- package/node_modules/zod/mini/package.json +7 -0
- package/node_modules/zod/package.json +147 -0
- package/node_modules/zod/src/compile.ts +56 -0
- package/node_modules/zod/src/index.ts +7 -0
- package/node_modules/zod/src/locales/index.ts +1 -0
- package/node_modules/zod/src/mini/index.ts +3 -0
- package/node_modules/zod/src/v3/ZodError.ts +340 -0
- package/node_modules/zod/src/v3/benchmarks/datetime.ts +58 -0
- package/node_modules/zod/src/v3/benchmarks/discriminatedUnion.ts +80 -0
- package/node_modules/zod/src/v3/benchmarks/index.ts +59 -0
- package/node_modules/zod/src/v3/benchmarks/ipv4.ts +57 -0
- package/node_modules/zod/src/v3/benchmarks/object.ts +69 -0
- package/node_modules/zod/src/v3/benchmarks/primitives.ts +162 -0
- package/node_modules/zod/src/v3/benchmarks/realworld.ts +63 -0
- package/node_modules/zod/src/v3/benchmarks/string.ts +55 -0
- package/node_modules/zod/src/v3/benchmarks/union.ts +80 -0
- package/node_modules/zod/src/v3/errors.ts +13 -0
- package/node_modules/zod/src/v3/external.ts +6 -0
- package/node_modules/zod/src/v3/helpers/enumUtil.ts +17 -0
- package/node_modules/zod/src/v3/helpers/errorUtil.ts +8 -0
- package/node_modules/zod/src/v3/helpers/parseUtil.ts +176 -0
- package/node_modules/zod/src/v3/helpers/partialUtil.ts +34 -0
- package/node_modules/zod/src/v3/helpers/typeAliases.ts +2 -0
- package/node_modules/zod/src/v3/helpers/util.ts +224 -0
- package/node_modules/zod/src/v3/index.ts +4 -0
- package/node_modules/zod/src/v3/locales/en.ts +124 -0
- package/node_modules/zod/src/v3/standard-schema.ts +113 -0
- package/node_modules/zod/src/v3/tests/Mocker.ts +54 -0
- package/node_modules/zod/src/v3/tests/all-errors.test.ts +157 -0
- package/node_modules/zod/src/v3/tests/anyunknown.test.ts +28 -0
- package/node_modules/zod/src/v3/tests/array.test.ts +71 -0
- package/node_modules/zod/src/v3/tests/async-parsing.test.ts +388 -0
- package/node_modules/zod/src/v3/tests/async-refinements.test.ts +46 -0
- package/node_modules/zod/src/v3/tests/base.test.ts +29 -0
- package/node_modules/zod/src/v3/tests/bigint.test.ts +55 -0
- package/node_modules/zod/src/v3/tests/branded.test.ts +53 -0
- package/node_modules/zod/src/v3/tests/catch.test.ts +220 -0
- package/node_modules/zod/src/v3/tests/coerce.test.ts +133 -0
- package/node_modules/zod/src/v3/tests/complex.test.ts +70 -0
- package/node_modules/zod/src/v3/tests/custom.test.ts +31 -0
- package/node_modules/zod/src/v3/tests/date.test.ts +32 -0
- package/node_modules/zod/src/v3/tests/deepmasking.test.ts +186 -0
- package/node_modules/zod/src/v3/tests/default.test.ts +112 -0
- package/node_modules/zod/src/v3/tests/description.test.ts +33 -0
- package/node_modules/zod/src/v3/tests/discriminated-unions.test.ts +315 -0
- package/node_modules/zod/src/v3/tests/enum.test.ts +80 -0
- package/node_modules/zod/src/v3/tests/error.test.ts +586 -0
- package/node_modules/zod/src/v3/tests/firstparty.test.ts +87 -0
- package/node_modules/zod/src/v3/tests/firstpartyschematypes.test.ts +21 -0
- package/node_modules/zod/src/v3/tests/function.test.ts +261 -0
- package/node_modules/zod/src/v3/tests/generics.test.ts +48 -0
- package/node_modules/zod/src/v3/tests/instanceof.test.ts +37 -0
- package/node_modules/zod/src/v3/tests/intersection.test.ts +128 -0
- package/node_modules/zod/src/v3/tests/language-server.source.ts +76 -0
- package/node_modules/zod/src/v3/tests/language-server.test.ts +206 -0
- package/node_modules/zod/src/v3/tests/literal.test.ts +36 -0
- package/node_modules/zod/src/v3/tests/map.test.ts +110 -0
- package/node_modules/zod/src/v3/tests/masking.test.ts +4 -0
- package/node_modules/zod/src/v3/tests/mocker.test.ts +19 -0
- package/node_modules/zod/src/v3/tests/nan.test.ts +24 -0
- package/node_modules/zod/src/v3/tests/nativeEnum.test.ts +87 -0
- package/node_modules/zod/src/v3/tests/nullable.test.ts +42 -0
- package/node_modules/zod/src/v3/tests/number.test.ts +176 -0
- package/node_modules/zod/src/v3/tests/object-augmentation.test.ts +29 -0
- package/node_modules/zod/src/v3/tests/object-in-es5-env.test.ts +29 -0
- package/node_modules/zod/src/v3/tests/object.test.ts +431 -0
- package/node_modules/zod/src/v3/tests/optional.test.ts +42 -0
- package/node_modules/zod/src/v3/tests/parseUtil.test.ts +23 -0
- package/node_modules/zod/src/v3/tests/parser.test.ts +41 -0
- package/node_modules/zod/src/v3/tests/partials.test.ts +243 -0
- package/node_modules/zod/src/v3/tests/pickomit.test.ts +111 -0
- package/node_modules/zod/src/v3/tests/pipeline.test.ts +29 -0
- package/node_modules/zod/src/v3/tests/preprocess.test.ts +186 -0
- package/node_modules/zod/src/v3/tests/primitive.test.ts +440 -0
- package/node_modules/zod/src/v3/tests/promise.test.ts +90 -0
- package/node_modules/zod/src/v3/tests/readonly.test.ts +114 -0
- package/node_modules/zod/src/v3/tests/record.test.ts +171 -0
- package/node_modules/zod/src/v3/tests/recursive.test.ts +197 -0
- package/node_modules/zod/src/v3/tests/refine.test.ts +313 -0
- package/node_modules/zod/src/v3/tests/safeparse.test.ts +27 -0
- package/node_modules/zod/src/v3/tests/set.test.ts +142 -0
- package/node_modules/zod/src/v3/tests/standard-schema.test.ts +83 -0
- package/node_modules/zod/src/v3/tests/string.test.ts +922 -0
- package/node_modules/zod/src/v3/tests/transformer.test.ts +233 -0
- package/node_modules/zod/src/v3/tests/tuple.test.ts +90 -0
- package/node_modules/zod/src/v3/tests/unions.test.ts +57 -0
- package/node_modules/zod/src/v3/tests/validations.test.ts +133 -0
- package/node_modules/zod/src/v3/tests/void.test.ts +15 -0
- package/node_modules/zod/src/v3/types.ts +5138 -0
- package/node_modules/zod/src/v4/classic/checks.ts +33 -0
- package/node_modules/zod/src/v4/classic/coerce.ts +27 -0
- package/node_modules/zod/src/v4/classic/compat.ts +78 -0
- package/node_modules/zod/src/v4/classic/deep-partial.ts +76 -0
- package/node_modules/zod/src/v4/classic/errors.ts +97 -0
- package/node_modules/zod/src/v4/classic/external.ts +57 -0
- package/node_modules/zod/src/v4/classic/from-json-schema.ts +944 -0
- package/node_modules/zod/src/v4/classic/in-out.ts +45 -0
- package/node_modules/zod/src/v4/classic/index.ts +5 -0
- package/node_modules/zod/src/v4/classic/iso.ts +20 -0
- package/node_modules/zod/src/v4/classic/parse.ts +88 -0
- package/node_modules/zod/src/v4/classic/schemas.ts +2937 -0
- package/node_modules/zod/src/v4/classic/tests/anyunknown.test.ts +26 -0
- package/node_modules/zod/src/v4/classic/tests/apply.test.ts +86 -0
- package/node_modules/zod/src/v4/classic/tests/array.test.ts +291 -0
- package/node_modules/zod/src/v4/classic/tests/assignability.test.ts +402 -0
- package/node_modules/zod/src/v4/classic/tests/async-parsing.test.ts +381 -0
- package/node_modules/zod/src/v4/classic/tests/async-refinements.test.ts +68 -0
- package/node_modules/zod/src/v4/classic/tests/base.test.ts +7 -0
- package/node_modules/zod/src/v4/classic/tests/bigint.test.ts +89 -0
- package/node_modules/zod/src/v4/classic/tests/brand.test.ts +106 -0
- package/node_modules/zod/src/v4/classic/tests/catch.test.ts +604 -0
- package/node_modules/zod/src/v4/classic/tests/coalesce.test.ts +20 -0
- package/node_modules/zod/src/v4/classic/tests/codec-examples.test.ts +572 -0
- package/node_modules/zod/src/v4/classic/tests/codec.test.ts +704 -0
- package/node_modules/zod/src/v4/classic/tests/coerce.test.ts +160 -0
- package/node_modules/zod/src/v4/classic/tests/continuability.test.ts +374 -0
- package/node_modules/zod/src/v4/classic/tests/credit-card.test.ts +76 -0
- package/node_modules/zod/src/v4/classic/tests/custom.test.ts +40 -0
- package/node_modules/zod/src/v4/classic/tests/cyclic-data.test.ts +985 -0
- package/node_modules/zod/src/v4/classic/tests/date.test.ts +92 -0
- package/node_modules/zod/src/v4/classic/tests/datetime.test.ts +316 -0
- package/node_modules/zod/src/v4/classic/tests/deep-partial.test.ts +380 -0
- package/node_modules/zod/src/v4/classic/tests/default-locale.test.ts +32 -0
- package/node_modules/zod/src/v4/classic/tests/default.test.ts +455 -0
- package/node_modules/zod/src/v4/classic/tests/describe-meta-checks.test.ts +27 -0
- package/node_modules/zod/src/v4/classic/tests/description.test.ts +32 -0
- package/node_modules/zod/src/v4/classic/tests/detached-methods.test.ts +221 -0
- package/node_modules/zod/src/v4/classic/tests/discriminated-unions.test.ts +942 -0
- package/node_modules/zod/src/v4/classic/tests/enum.test.ts +305 -0
- package/node_modules/zod/src/v4/classic/tests/error-utils.test.ts +917 -0
- package/node_modules/zod/src/v4/classic/tests/error.test.ts +1108 -0
- package/node_modules/zod/src/v4/classic/tests/file.test.ts +96 -0
- package/node_modules/zod/src/v4/classic/tests/firstparty.test.ts +179 -0
- package/node_modules/zod/src/v4/classic/tests/fix-json-issue.test.ts +26 -0
- package/node_modules/zod/src/v4/classic/tests/from-json-schema.test.ts +1467 -0
- package/node_modules/zod/src/v4/classic/tests/function.test.ts +391 -0
- package/node_modules/zod/src/v4/classic/tests/generics.test.ts +72 -0
- package/node_modules/zod/src/v4/classic/tests/global-config.test.ts +32 -0
- package/node_modules/zod/src/v4/classic/tests/hash.test.ts +67 -0
- package/node_modules/zod/src/v4/classic/tests/iban.test.ts +81 -0
- package/node_modules/zod/src/v4/classic/tests/in-out.test.ts +159 -0
- package/node_modules/zod/src/v4/classic/tests/index.test.ts +958 -0
- package/node_modules/zod/src/v4/classic/tests/instance-footprint.test.ts +319 -0
- package/node_modules/zod/src/v4/classic/tests/instanceof.test.ts +127 -0
- package/node_modules/zod/src/v4/classic/tests/intersection.test.ts +334 -0
- package/node_modules/zod/src/v4/classic/tests/issue-schema.test.ts +215 -0
- package/node_modules/zod/src/v4/classic/tests/jitless-allows-eval.test.ts +39 -0
- package/node_modules/zod/src/v4/classic/tests/json.test.ts +109 -0
- package/node_modules/zod/src/v4/classic/tests/lazy.test.ts +262 -0
- package/node_modules/zod/src/v4/classic/tests/literal.test.ts +128 -0
- package/node_modules/zod/src/v4/classic/tests/locales_ka.test.ts +29 -0
- package/node_modules/zod/src/v4/classic/tests/locales_ro.test.ts +24 -0
- package/node_modules/zod/src/v4/classic/tests/map.test.ts +349 -0
- package/node_modules/zod/src/v4/classic/tests/nan.test.ts +21 -0
- package/node_modules/zod/src/v4/classic/tests/nested-refine.test.ts +168 -0
- package/node_modules/zod/src/v4/classic/tests/nonoptional.test.ts +101 -0
- package/node_modules/zod/src/v4/classic/tests/nullable.test.ts +22 -0
- package/node_modules/zod/src/v4/classic/tests/number.test.ts +401 -0
- package/node_modules/zod/src/v4/classic/tests/object.test.ts +1006 -0
- package/node_modules/zod/src/v4/classic/tests/optin-ladder.test.ts +235 -0
- package/node_modules/zod/src/v4/classic/tests/optional.test.ts +366 -0
- package/node_modules/zod/src/v4/classic/tests/partial.test.ts +497 -0
- package/node_modules/zod/src/v4/classic/tests/pickomit.test.ts +211 -0
- package/node_modules/zod/src/v4/classic/tests/pipe.test.ts +101 -0
- package/node_modules/zod/src/v4/classic/tests/prefault.test.ts +144 -0
- package/node_modules/zod/src/v4/classic/tests/preprocess-types.test.ts +44 -0
- package/node_modules/zod/src/v4/classic/tests/preprocess.test.ts +351 -0
- package/node_modules/zod/src/v4/classic/tests/primitive.test.ts +175 -0
- package/node_modules/zod/src/v4/classic/tests/promise.test.ts +81 -0
- package/node_modules/zod/src/v4/classic/tests/properties.test.ts +141 -0
- package/node_modules/zod/src/v4/classic/tests/prototypes.test.ts +23 -0
- package/node_modules/zod/src/v4/classic/tests/readonly.test.ts +184 -0
- package/node_modules/zod/src/v4/classic/tests/record.test.ts +885 -0
- package/node_modules/zod/src/v4/classic/tests/recursive-types.test.ts +707 -0
- package/node_modules/zod/src/v4/classic/tests/redos.test.ts +68 -0
- package/node_modules/zod/src/v4/classic/tests/refine.test.ts +693 -0
- package/node_modules/zod/src/v4/classic/tests/registries.test.ts +243 -0
- package/node_modules/zod/src/v4/classic/tests/set.test.ts +196 -0
- package/node_modules/zod/src/v4/classic/tests/standard-schema.test.ts +153 -0
- package/node_modules/zod/src/v4/classic/tests/string-formats.test.ts +125 -0
- package/node_modules/zod/src/v4/classic/tests/string.test.ts +1440 -0
- package/node_modules/zod/src/v4/classic/tests/stringbool.test.ts +124 -0
- package/node_modules/zod/src/v4/classic/tests/template-literal.test.ts +812 -0
- package/node_modules/zod/src/v4/classic/tests/to-json-schema-methods.test.ts +438 -0
- package/node_modules/zod/src/v4/classic/tests/to-json-schema.test.ts +4733 -0
- package/node_modules/zod/src/v4/classic/tests/transform.test.ts +378 -0
- package/node_modules/zod/src/v4/classic/tests/tuple.test.ts +511 -0
- package/node_modules/zod/src/v4/classic/tests/union.test.ts +310 -0
- package/node_modules/zod/src/v4/classic/tests/url.test.ts +13 -0
- package/node_modules/zod/src/v4/classic/tests/validate.test.ts +645 -0
- package/node_modules/zod/src/v4/classic/tests/validations.test.ts +283 -0
- package/node_modules/zod/src/v4/classic/tests/void.test.ts +12 -0
- package/node_modules/zod/src/v4/core/api.ts +1875 -0
- package/node_modules/zod/src/v4/core/checks.ts +1266 -0
- package/node_modules/zod/src/v4/core/compile.ts +2322 -0
- package/node_modules/zod/src/v4/core/core.ts +230 -0
- package/node_modules/zod/src/v4/core/doc.ts +52 -0
- package/node_modules/zod/src/v4/core/errors.ts +543 -0
- package/node_modules/zod/src/v4/core/index.ts +19 -0
- package/node_modules/zod/src/v4/core/json-schema-generator.ts +131 -0
- package/node_modules/zod/src/v4/core/json-schema-processors.ts +934 -0
- package/node_modules/zod/src/v4/core/json-schema.ts +148 -0
- package/node_modules/zod/src/v4/core/memoizer.ts +331 -0
- package/node_modules/zod/src/v4/core/parse.ts +309 -0
- package/node_modules/zod/src/v4/core/regexes.ts +217 -0
- package/node_modules/zod/src/v4/core/registries.ts +105 -0
- package/node_modules/zod/src/v4/core/schemas.ts +5226 -0
- package/node_modules/zod/src/v4/core/standard-schema.ts +159 -0
- package/node_modules/zod/src/v4/core/tests/cached.test.ts +54 -0
- package/node_modules/zod/src/v4/core/tests/compile-differential.test.ts +1004 -0
- package/node_modules/zod/src/v4/core/tests/compile-generative.test.ts +445 -0
- package/node_modules/zod/src/v4/core/tests/compile-global.test.ts +89 -0
- package/node_modules/zod/src/v4/core/tests/compile-off-by-default.test.ts +26 -0
- package/node_modules/zod/src/v4/core/tests/compile-stats.test.ts +34 -0
- package/node_modules/zod/src/v4/core/tests/compile.test.ts +2036 -0
- package/node_modules/zod/src/v4/core/tests/email-regex.test.ts +140 -0
- package/node_modules/zod/src/v4/core/tests/extend.test.ts +59 -0
- package/node_modules/zod/src/v4/core/tests/index.test.ts +46 -0
- package/node_modules/zod/src/v4/core/tests/locales/be.test.ts +124 -0
- package/node_modules/zod/src/v4/core/tests/locales/el.test.ts +214 -0
- package/node_modules/zod/src/v4/core/tests/locales/en.test.ts +22 -0
- package/node_modules/zod/src/v4/core/tests/locales/es.test.ts +180 -0
- package/node_modules/zod/src/v4/core/tests/locales/fr.test.ts +72 -0
- package/node_modules/zod/src/v4/core/tests/locales/he.test.ts +379 -0
- package/node_modules/zod/src/v4/core/tests/locales/hr.test.ts +163 -0
- package/node_modules/zod/src/v4/core/tests/locales/nl.test.ts +46 -0
- package/node_modules/zod/src/v4/core/tests/locales/parity.test.ts +42 -0
- package/node_modules/zod/src/v4/core/tests/locales/ru.test.ts +128 -0
- package/node_modules/zod/src/v4/core/tests/locales/tg.test.ts +85 -0
- package/node_modules/zod/src/v4/core/tests/locales/tk.test.ts +69 -0
- package/node_modules/zod/src/v4/core/tests/locales/tr.test.ts +69 -0
- package/node_modules/zod/src/v4/core/tests/locales/uz.test.ts +105 -0
- package/node_modules/zod/src/v4/core/tests/polyfill-collision.test.ts +46 -0
- package/node_modules/zod/src/v4/core/tests/record-constructor.test.ts +125 -0
- package/node_modules/zod/src/v4/core/tests/recursive-tuples.test.ts +45 -0
- package/node_modules/zod/src/v4/core/tests/treeshake.test.ts +51 -0
- package/node_modules/zod/src/v4/core/tests/url-no-canparse.test.ts +133 -0
- package/node_modules/zod/src/v4/core/to-json-schema.ts +857 -0
- package/node_modules/zod/src/v4/core/util.ts +1293 -0
- package/node_modules/zod/src/v4/core/versions.ts +5 -0
- package/node_modules/zod/src/v4/core/visit.ts +193 -0
- package/node_modules/zod/src/v4/core/zsf.ts +323 -0
- package/node_modules/zod/src/v4/index.ts +4 -0
- package/node_modules/zod/src/v4/locales/ar.ts +120 -0
- package/node_modules/zod/src/v4/locales/az.ts +116 -0
- package/node_modules/zod/src/v4/locales/be.ts +188 -0
- package/node_modules/zod/src/v4/locales/bg.ts +133 -0
- package/node_modules/zod/src/v4/locales/bn.ts +123 -0
- package/node_modules/zod/src/v4/locales/ca.ts +121 -0
- package/node_modules/zod/src/v4/locales/ckb.ts +140 -0
- package/node_modules/zod/src/v4/locales/cs.ts +123 -0
- package/node_modules/zod/src/v4/locales/da.ts +128 -0
- package/node_modules/zod/src/v4/locales/de.ts +121 -0
- package/node_modules/zod/src/v4/locales/el.ts +124 -0
- package/node_modules/zod/src/v4/locales/en.ts +136 -0
- package/node_modules/zod/src/v4/locales/eo.ts +123 -0
- package/node_modules/zod/src/v4/locales/es.ts +145 -0
- package/node_modules/zod/src/v4/locales/fa.ts +131 -0
- package/node_modules/zod/src/v4/locales/fi.ts +126 -0
- package/node_modules/zod/src/v4/locales/fr-CA.ts +121 -0
- package/node_modules/zod/src/v4/locales/fr.ts +139 -0
- package/node_modules/zod/src/v4/locales/gu.ts +123 -0
- package/node_modules/zod/src/v4/locales/he.ts +253 -0
- package/node_modules/zod/src/v4/locales/hi.ts +126 -0
- package/node_modules/zod/src/v4/locales/hr.ts +135 -0
- package/node_modules/zod/src/v4/locales/hu.ts +122 -0
- package/node_modules/zod/src/v4/locales/hy.ts +175 -0
- package/node_modules/zod/src/v4/locales/id.ts +120 -0
- package/node_modules/zod/src/v4/locales/index.ts +63 -0
- package/node_modules/zod/src/v4/locales/is.ts +124 -0
- package/node_modules/zod/src/v4/locales/it.ts +121 -0
- package/node_modules/zod/src/v4/locales/ja.ts +119 -0
- package/node_modules/zod/src/v4/locales/ka.ts +128 -0
- package/node_modules/zod/src/v4/locales/kh.ts +7 -0
- package/node_modules/zod/src/v4/locales/km.ts +124 -0
- package/node_modules/zod/src/v4/locales/kn.ts +126 -0
- package/node_modules/zod/src/v4/locales/ko.ts +126 -0
- package/node_modules/zod/src/v4/locales/lt.ts +243 -0
- package/node_modules/zod/src/v4/locales/mk.ts +123 -0
- package/node_modules/zod/src/v4/locales/ms.ts +120 -0
- package/node_modules/zod/src/v4/locales/ne.ts +128 -0
- package/node_modules/zod/src/v4/locales/nl.ts +126 -0
- package/node_modules/zod/src/v4/locales/nn.ts +121 -0
- package/node_modules/zod/src/v4/locales/no.ts +121 -0
- package/node_modules/zod/src/v4/locales/ota.ts +122 -0
- package/node_modules/zod/src/v4/locales/pl.ts +123 -0
- package/node_modules/zod/src/v4/locales/ps.ts +131 -0
- package/node_modules/zod/src/v4/locales/pt-BR.ts +161 -0
- package/node_modules/zod/src/v4/locales/pt.ts +159 -0
- package/node_modules/zod/src/v4/locales/ro.ts +132 -0
- package/node_modules/zod/src/v4/locales/ru.ts +188 -0
- package/node_modules/zod/src/v4/locales/sk.ts +123 -0
- package/node_modules/zod/src/v4/locales/sl.ts +123 -0
- package/node_modules/zod/src/v4/locales/sv.ts +124 -0
- package/node_modules/zod/src/v4/locales/ta.ts +123 -0
- package/node_modules/zod/src/v4/locales/tg.ts +135 -0
- package/node_modules/zod/src/v4/locales/th.ts +124 -0
- package/node_modules/zod/src/v4/locales/tk.ts +113 -0
- package/node_modules/zod/src/v4/locales/tr.ts +116 -0
- package/node_modules/zod/src/v4/locales/ua.ts +7 -0
- package/node_modules/zod/src/v4/locales/uk.ts +122 -0
- package/node_modules/zod/src/v4/locales/ur.ts +124 -0
- package/node_modules/zod/src/v4/locales/uz.ts +120 -0
- package/node_modules/zod/src/v4/locales/vi.ts +122 -0
- package/node_modules/zod/src/v4/locales/yo.ts +129 -0
- package/node_modules/zod/src/v4/locales/zh-CN.ts +121 -0
- package/node_modules/zod/src/v4/locales/zh-TW.ts +120 -0
- package/node_modules/zod/src/v4/mini/checks.ts +33 -0
- package/node_modules/zod/src/v4/mini/coerce.ts +27 -0
- package/node_modules/zod/src/v4/mini/deep-partial.ts +73 -0
- package/node_modules/zod/src/v4/mini/external.ts +52 -0
- package/node_modules/zod/src/v4/mini/in-out.ts +45 -0
- package/node_modules/zod/src/v4/mini/index.ts +3 -0
- package/node_modules/zod/src/v4/mini/iso.ts +66 -0
- package/node_modules/zod/src/v4/mini/parse.ts +16 -0
- package/node_modules/zod/src/v4/mini/schemas.ts +2051 -0
- package/node_modules/zod/src/v4/mini/tests/apply.test.ts +57 -0
- package/node_modules/zod/src/v4/mini/tests/assignability.test.ts +190 -0
- package/node_modules/zod/src/v4/mini/tests/brand.test.ts +94 -0
- package/node_modules/zod/src/v4/mini/tests/checks.test.ts +158 -0
- package/node_modules/zod/src/v4/mini/tests/codec.test.ts +582 -0
- package/node_modules/zod/src/v4/mini/tests/computed.test.ts +30 -0
- package/node_modules/zod/src/v4/mini/tests/cyclic-data.test.ts +84 -0
- package/node_modules/zod/src/v4/mini/tests/deep-partial.test.ts +54 -0
- package/node_modules/zod/src/v4/mini/tests/error.test.ts +41 -0
- package/node_modules/zod/src/v4/mini/tests/functions.test.ts +14 -0
- package/node_modules/zod/src/v4/mini/tests/index.test.ts +1146 -0
- package/node_modules/zod/src/v4/mini/tests/number.test.ts +109 -0
- package/node_modules/zod/src/v4/mini/tests/object.test.ts +292 -0
- package/node_modules/zod/src/v4/mini/tests/prototypes.test.ts +43 -0
- package/node_modules/zod/src/v4/mini/tests/recursive-types.test.ts +341 -0
- package/node_modules/zod/src/v4/mini/tests/standard-schema.test.ts +50 -0
- package/node_modules/zod/src/v4/mini/tests/string.test.ts +396 -0
- package/node_modules/zod/src/v4-mini/index.ts +3 -0
- package/node_modules/zod/v3/ZodError.cjs +167 -0
- package/node_modules/zod/v3/ZodError.d.cts +164 -0
- package/node_modules/zod/v3/ZodError.d.ts +164 -0
- package/node_modules/zod/v3/ZodError.js +143 -0
- package/node_modules/zod/v3/errors.cjs +36 -0
- package/node_modules/zod/v3/errors.d.cts +5 -0
- package/node_modules/zod/v3/errors.d.ts +5 -0
- package/node_modules/zod/v3/errors.js +9 -0
- package/node_modules/zod/v3/external.cjs +41 -0
- package/node_modules/zod/v3/external.d.cts +6 -0
- package/node_modules/zod/v3/external.d.ts +6 -0
- package/node_modules/zod/v3/external.js +6 -0
- package/node_modules/zod/v3/helpers/enumUtil.cjs +21 -0
- package/node_modules/zod/v3/helpers/enumUtil.d.cts +8 -0
- package/node_modules/zod/v3/helpers/enumUtil.d.ts +8 -0
- package/node_modules/zod/v3/helpers/enumUtil.js +1 -0
- package/node_modules/zod/v3/helpers/errorUtil.cjs +28 -0
- package/node_modules/zod/v3/helpers/errorUtil.d.cts +9 -0
- package/node_modules/zod/v3/helpers/errorUtil.d.ts +9 -0
- package/node_modules/zod/v3/helpers/errorUtil.js +6 -0
- package/node_modules/zod/v3/helpers/parseUtil.cjs +143 -0
- package/node_modules/zod/v3/helpers/parseUtil.d.cts +78 -0
- package/node_modules/zod/v3/helpers/parseUtil.d.ts +78 -0
- package/node_modules/zod/v3/helpers/parseUtil.js +109 -0
- package/node_modules/zod/v3/helpers/partialUtil.cjs +21 -0
- package/node_modules/zod/v3/helpers/partialUtil.d.cts +8 -0
- package/node_modules/zod/v3/helpers/partialUtil.d.ts +8 -0
- package/node_modules/zod/v3/helpers/partialUtil.js +1 -0
- package/node_modules/zod/v3/helpers/typeAliases.cjs +21 -0
- package/node_modules/zod/v3/helpers/typeAliases.d.cts +2 -0
- package/node_modules/zod/v3/helpers/typeAliases.d.ts +2 -0
- package/node_modules/zod/v3/helpers/typeAliases.js +1 -0
- package/node_modules/zod/v3/helpers/util.cjs +156 -0
- package/node_modules/zod/v3/helpers/util.d.cts +85 -0
- package/node_modules/zod/v3/helpers/util.d.ts +85 -0
- package/node_modules/zod/v3/helpers/util.js +133 -0
- package/node_modules/zod/v3/index.cjs +52 -0
- package/node_modules/zod/v3/index.d.cts +4 -0
- package/node_modules/zod/v3/index.d.ts +4 -0
- package/node_modules/zod/v3/index.js +4 -0
- package/node_modules/zod/v3/locales/en.cjs +112 -0
- package/node_modules/zod/v3/locales/en.d.cts +3 -0
- package/node_modules/zod/v3/locales/en.d.ts +3 -0
- package/node_modules/zod/v3/locales/en.js +109 -0
- package/node_modules/zod/v3/package.json +7 -0
- package/node_modules/zod/v3/standard-schema.cjs +21 -0
- package/node_modules/zod/v3/standard-schema.d.cts +102 -0
- package/node_modules/zod/v3/standard-schema.d.ts +102 -0
- package/node_modules/zod/v3/standard-schema.js +1 -0
- package/node_modules/zod/v3/types.cjs +3798 -0
- package/node_modules/zod/v3/types.d.cts +1034 -0
- package/node_modules/zod/v3/types.d.ts +1034 -0
- package/node_modules/zod/v3/types.js +3697 -0
- package/node_modules/zod/v4/classic/checks.cjs +53 -0
- package/node_modules/zod/v4/classic/checks.d.cts +1 -0
- package/node_modules/zod/v4/classic/checks.d.ts +1 -0
- package/node_modules/zod/v4/classic/checks.js +1 -0
- package/node_modules/zod/v4/classic/coerce.cjs +66 -0
- package/node_modules/zod/v4/classic/coerce.d.cts +17 -0
- package/node_modules/zod/v4/classic/coerce.d.ts +17 -0
- package/node_modules/zod/v4/classic/coerce.js +17 -0
- package/node_modules/zod/v4/classic/compat.cjs +80 -0
- package/node_modules/zod/v4/classic/compat.d.cts +48 -0
- package/node_modules/zod/v4/classic/compat.d.ts +48 -0
- package/node_modules/zod/v4/classic/compat.js +31 -0
- package/node_modules/zod/v4/classic/deep-partial.cjs +58 -0
- package/node_modules/zod/v4/classic/deep-partial.d.cts +14 -0
- package/node_modules/zod/v4/classic/deep-partial.d.ts +14 -0
- package/node_modules/zod/v4/classic/deep-partial.js +13 -0
- package/node_modules/zod/v4/classic/errors.cjs +102 -0
- package/node_modules/zod/v4/classic/errors.d.cts +29 -0
- package/node_modules/zod/v4/classic/errors.d.ts +29 -0
- package/node_modules/zod/v4/classic/errors.js +57 -0
- package/node_modules/zod/v4/classic/external.cjs +97 -0
- package/node_modules/zod/v4/classic/external.d.cts +19 -0
- package/node_modules/zod/v4/classic/external.d.ts +19 -0
- package/node_modules/zod/v4/classic/external.js +17 -0
- package/node_modules/zod/v4/classic/from-json-schema.cjs +926 -0
- package/node_modules/zod/v4/classic/from-json-schema.d.cts +12 -0
- package/node_modules/zod/v4/classic/from-json-schema.d.ts +12 -0
- package/node_modules/zod/v4/classic/from-json-schema.js +881 -0
- package/node_modules/zod/v4/classic/in-out.cjs +82 -0
- package/node_modules/zod/v4/classic/in-out.d.cts +8 -0
- package/node_modules/zod/v4/classic/in-out.d.ts +8 -0
- package/node_modules/zod/v4/classic/in-out.js +36 -0
- package/node_modules/zod/v4/classic/index.cjs +52 -0
- package/node_modules/zod/v4/classic/index.d.cts +3 -0
- package/node_modules/zod/v4/classic/index.d.ts +3 -0
- package/node_modules/zod/v4/classic/index.js +4 -0
- package/node_modules/zod/v4/classic/iso.cjs +68 -0
- package/node_modules/zod/v4/classic/iso.d.cts +7 -0
- package/node_modules/zod/v4/classic/iso.d.ts +7 -0
- package/node_modules/zod/v4/classic/iso.js +15 -0
- package/node_modules/zod/v4/classic/package.json +7 -0
- package/node_modules/zod/v4/classic/parse.cjs +63 -0
- package/node_modules/zod/v4/classic/parse.d.cts +44 -0
- package/node_modules/zod/v4/classic/parse.d.ts +44 -0
- package/node_modules/zod/v4/classic/parse.js +16 -0
- package/node_modules/zod/v4/classic/schemas.cjs +1676 -0
- package/node_modules/zod/v4/classic/schemas.d.cts +816 -0
- package/node_modules/zod/v4/classic/schemas.d.ts +816 -0
- package/node_modules/zod/v4/classic/schemas.js +1535 -0
- package/node_modules/zod/v4/core/api.cjs +1269 -0
- package/node_modules/zod/v4/core/api.d.cts +335 -0
- package/node_modules/zod/v4/core/api.d.ts +335 -0
- package/node_modules/zod/v4/core/api.js +1107 -0
- package/node_modules/zod/v4/core/checks.cjs +561 -0
- package/node_modules/zod/v4/core/checks.d.cts +294 -0
- package/node_modules/zod/v4/core/checks.d.ts +294 -0
- package/node_modules/zod/v4/core/checks.js +516 -0
- package/node_modules/zod/v4/core/compile.cjs +1916 -0
- package/node_modules/zod/v4/core/compile.d.cts +65 -0
- package/node_modules/zod/v4/core/compile.d.ts +65 -0
- package/node_modules/zod/v4/core/compile.js +1866 -0
- package/node_modules/zod/v4/core/core.cjs +167 -0
- package/node_modules/zod/v4/core/core.d.cts +82 -0
- package/node_modules/zod/v4/core/core.d.ts +82 -0
- package/node_modules/zod/v4/core/core.js +141 -0
- package/node_modules/zod/v4/core/doc.cjs +61 -0
- package/node_modules/zod/v4/core/doc.d.cts +16 -0
- package/node_modules/zod/v4/core/doc.d.ts +16 -0
- package/node_modules/zod/v4/core/doc.js +38 -0
- package/node_modules/zod/v4/core/errors.cjs +317 -0
- package/node_modules/zod/v4/core/errors.d.cts +225 -0
- package/node_modules/zod/v4/core/errors.d.ts +225 -0
- package/node_modules/zod/v4/core/errors.js +267 -0
- package/node_modules/zod/v4/core/index.cjs +70 -0
- package/node_modules/zod/v4/core/index.d.cts +19 -0
- package/node_modules/zod/v4/core/index.d.ts +19 -0
- package/node_modules/zod/v4/core/index.js +19 -0
- package/node_modules/zod/v4/core/json-schema-generator.cjs +122 -0
- package/node_modules/zod/v4/core/json-schema-generator.d.cts +65 -0
- package/node_modules/zod/v4/core/json-schema-generator.d.ts +65 -0
- package/node_modules/zod/v4/core/json-schema-generator.js +99 -0
- package/node_modules/zod/v4/core/json-schema-processors.cjs +929 -0
- package/node_modules/zod/v4/core/json-schema-processors.d.cts +65 -0
- package/node_modules/zod/v4/core/json-schema-processors.d.ts +65 -0
- package/node_modules/zod/v4/core/json-schema-processors.js +843 -0
- package/node_modules/zod/v4/core/json-schema.cjs +21 -0
- package/node_modules/zod/v4/core/json-schema.d.cts +89 -0
- package/node_modules/zod/v4/core/json-schema.d.ts +89 -0
- package/node_modules/zod/v4/core/json-schema.js +1 -0
- package/node_modules/zod/v4/core/memoizer.cjs +360 -0
- package/node_modules/zod/v4/core/memoizer.d.cts +15 -0
- package/node_modules/zod/v4/core/memoizer.d.ts +15 -0
- package/node_modules/zod/v4/core/memoizer.js +311 -0
- package/node_modules/zod/v4/core/package.json +7 -0
- package/node_modules/zod/v4/core/parse.cjs +233 -0
- package/node_modules/zod/v4/core/parse.d.cts +52 -0
- package/node_modules/zod/v4/core/parse.d.ts +52 -0
- package/node_modules/zod/v4/core/parse.js +175 -0
- package/node_modules/zod/v4/core/regexes.cjs +209 -0
- package/node_modules/zod/v4/core/regexes.d.cts +90 -0
- package/node_modules/zod/v4/core/regexes.d.ts +90 -0
- package/node_modules/zod/v4/core/regexes.js +156 -0
- package/node_modules/zod/v4/core/registries.cjs +75 -0
- package/node_modules/zod/v4/core/registries.d.cts +35 -0
- package/node_modules/zod/v4/core/registries.d.ts +35 -0
- package/node_modules/zod/v4/core/registries.js +51 -0
- package/node_modules/zod/v4/core/schemas.cjs +2699 -0
- package/node_modules/zod/v4/core/schemas.d.cts +1275 -0
- package/node_modules/zod/v4/core/schemas.d.ts +1275 -0
- package/node_modules/zod/v4/core/schemas.js +2636 -0
- package/node_modules/zod/v4/core/standard-schema.cjs +21 -0
- package/node_modules/zod/v4/core/standard-schema.d.cts +126 -0
- package/node_modules/zod/v4/core/standard-schema.d.ts +126 -0
- package/node_modules/zod/v4/core/standard-schema.js +1 -0
- package/node_modules/zod/v4/core/to-json-schema.cjs +681 -0
- package/node_modules/zod/v4/core/to-json-schema.d.cts +154 -0
- package/node_modules/zod/v4/core/to-json-schema.d.ts +154 -0
- package/node_modules/zod/v4/core/to-json-schema.js +651 -0
- package/node_modules/zod/v4/core/util.cjs +964 -0
- package/node_modules/zod/v4/core/util.d.cts +280 -0
- package/node_modules/zod/v4/core/util.d.ts +280 -0
- package/node_modules/zod/v4/core/util.js +873 -0
- package/node_modules/zod/v4/core/versions.cjs +27 -0
- package/node_modules/zod/v4/core/versions.d.cts +5 -0
- package/node_modules/zod/v4/core/versions.d.ts +5 -0
- package/node_modules/zod/v4/core/versions.js +5 -0
- package/node_modules/zod/v4/core/visit.cjs +214 -0
- package/node_modules/zod/v4/core/visit.d.cts +30 -0
- package/node_modules/zod/v4/core/visit.d.ts +30 -0
- package/node_modules/zod/v4/core/visit.js +169 -0
- package/node_modules/zod/v4/index.cjs +51 -0
- package/node_modules/zod/v4/index.d.cts +3 -0
- package/node_modules/zod/v4/index.d.ts +3 -0
- package/node_modules/zod/v4/index.js +4 -0
- package/node_modules/zod/v4/locales/ar.cjs +138 -0
- package/node_modules/zod/v4/locales/ar.d.cts +5 -0
- package/node_modules/zod/v4/locales/ar.d.ts +4 -0
- package/node_modules/zod/v4/locales/ar.js +111 -0
- package/node_modules/zod/v4/locales/az.cjs +137 -0
- package/node_modules/zod/v4/locales/az.d.cts +5 -0
- package/node_modules/zod/v4/locales/az.d.ts +4 -0
- package/node_modules/zod/v4/locales/az.js +110 -0
- package/node_modules/zod/v4/locales/be.cjs +195 -0
- package/node_modules/zod/v4/locales/be.d.cts +5 -0
- package/node_modules/zod/v4/locales/be.d.ts +4 -0
- package/node_modules/zod/v4/locales/be.js +168 -0
- package/node_modules/zod/v4/locales/bg.cjs +152 -0
- package/node_modules/zod/v4/locales/bg.d.cts +5 -0
- package/node_modules/zod/v4/locales/bg.d.ts +4 -0
- package/node_modules/zod/v4/locales/bg.js +125 -0
- package/node_modules/zod/v4/locales/bn.cjs +140 -0
- package/node_modules/zod/v4/locales/bn.d.cts +5 -0
- package/node_modules/zod/v4/locales/bn.d.ts +4 -0
- package/node_modules/zod/v4/locales/bn.js +113 -0
- package/node_modules/zod/v4/locales/ca.cjs +139 -0
- package/node_modules/zod/v4/locales/ca.d.cts +5 -0
- package/node_modules/zod/v4/locales/ca.d.ts +4 -0
- package/node_modules/zod/v4/locales/ca.js +112 -0
- package/node_modules/zod/v4/locales/ckb.cjs +160 -0
- package/node_modules/zod/v4/locales/ckb.d.cts +5 -0
- package/node_modules/zod/v4/locales/ckb.d.ts +4 -0
- package/node_modules/zod/v4/locales/ckb.js +133 -0
- package/node_modules/zod/v4/locales/cs.cjs +143 -0
- package/node_modules/zod/v4/locales/cs.d.cts +5 -0
- package/node_modules/zod/v4/locales/cs.d.ts +4 -0
- package/node_modules/zod/v4/locales/cs.js +116 -0
- package/node_modules/zod/v4/locales/da.cjs +147 -0
- package/node_modules/zod/v4/locales/da.d.cts +5 -0
- package/node_modules/zod/v4/locales/da.d.ts +4 -0
- package/node_modules/zod/v4/locales/da.js +120 -0
- package/node_modules/zod/v4/locales/de.cjs +140 -0
- package/node_modules/zod/v4/locales/de.d.cts +5 -0
- package/node_modules/zod/v4/locales/de.d.ts +4 -0
- package/node_modules/zod/v4/locales/de.js +113 -0
- package/node_modules/zod/v4/locales/el.cjs +139 -0
- package/node_modules/zod/v4/locales/el.d.cts +5 -0
- package/node_modules/zod/v4/locales/el.d.ts +4 -0
- package/node_modules/zod/v4/locales/el.js +112 -0
- package/node_modules/zod/v4/locales/en.cjs +152 -0
- package/node_modules/zod/v4/locales/en.d.cts +5 -0
- package/node_modules/zod/v4/locales/en.d.ts +4 -0
- package/node_modules/zod/v4/locales/en.js +125 -0
- package/node_modules/zod/v4/locales/eo.cjs +141 -0
- package/node_modules/zod/v4/locales/eo.d.cts +5 -0
- package/node_modules/zod/v4/locales/eo.d.ts +4 -0
- package/node_modules/zod/v4/locales/eo.js +114 -0
- package/node_modules/zod/v4/locales/es.cjs +163 -0
- package/node_modules/zod/v4/locales/es.d.cts +5 -0
- package/node_modules/zod/v4/locales/es.d.ts +4 -0
- package/node_modules/zod/v4/locales/es.js +136 -0
- package/node_modules/zod/v4/locales/fa.cjs +146 -0
- package/node_modules/zod/v4/locales/fa.d.cts +5 -0
- package/node_modules/zod/v4/locales/fa.d.ts +4 -0
- package/node_modules/zod/v4/locales/fa.js +119 -0
- package/node_modules/zod/v4/locales/fi.cjs +144 -0
- package/node_modules/zod/v4/locales/fi.d.cts +5 -0
- package/node_modules/zod/v4/locales/fi.d.ts +4 -0
- package/node_modules/zod/v4/locales/fi.js +117 -0
- package/node_modules/zod/v4/locales/fr-CA.cjs +139 -0
- package/node_modules/zod/v4/locales/fr-CA.d.cts +5 -0
- package/node_modules/zod/v4/locales/fr-CA.d.ts +4 -0
- package/node_modules/zod/v4/locales/fr-CA.js +112 -0
- package/node_modules/zod/v4/locales/fr.cjs +156 -0
- package/node_modules/zod/v4/locales/fr.d.cts +5 -0
- package/node_modules/zod/v4/locales/fr.d.ts +4 -0
- package/node_modules/zod/v4/locales/fr.js +129 -0
- package/node_modules/zod/v4/locales/gu.cjs +140 -0
- package/node_modules/zod/v4/locales/gu.d.cts +5 -0
- package/node_modules/zod/v4/locales/gu.d.ts +4 -0
- package/node_modules/zod/v4/locales/gu.js +113 -0
- package/node_modules/zod/v4/locales/he.cjs +248 -0
- package/node_modules/zod/v4/locales/he.d.cts +5 -0
- package/node_modules/zod/v4/locales/he.d.ts +4 -0
- package/node_modules/zod/v4/locales/he.js +221 -0
- package/node_modules/zod/v4/locales/hi.cjs +138 -0
- package/node_modules/zod/v4/locales/hi.d.cts +5 -0
- package/node_modules/zod/v4/locales/hi.d.ts +4 -0
- package/node_modules/zod/v4/locales/hi.js +111 -0
- package/node_modules/zod/v4/locales/hr.cjs +153 -0
- package/node_modules/zod/v4/locales/hr.d.cts +5 -0
- package/node_modules/zod/v4/locales/hr.d.ts +4 -0
- package/node_modules/zod/v4/locales/hr.js +126 -0
- package/node_modules/zod/v4/locales/hu.cjs +140 -0
- package/node_modules/zod/v4/locales/hu.d.cts +5 -0
- package/node_modules/zod/v4/locales/hu.d.ts +4 -0
- package/node_modules/zod/v4/locales/hu.js +113 -0
- package/node_modules/zod/v4/locales/hy.cjs +185 -0
- package/node_modules/zod/v4/locales/hy.d.cts +5 -0
- package/node_modules/zod/v4/locales/hy.d.ts +4 -0
- package/node_modules/zod/v4/locales/hy.js +158 -0
- package/node_modules/zod/v4/locales/id.cjs +138 -0
- package/node_modules/zod/v4/locales/id.d.cts +5 -0
- package/node_modules/zod/v4/locales/id.d.ts +4 -0
- package/node_modules/zod/v4/locales/id.js +111 -0
- package/node_modules/zod/v4/locales/index.cjs +152 -0
- package/node_modules/zod/v4/locales/index.d.cts +63 -0
- package/node_modules/zod/v4/locales/index.d.ts +63 -0
- package/node_modules/zod/v4/locales/index.js +63 -0
- package/node_modules/zod/v4/locales/is.cjs +141 -0
- package/node_modules/zod/v4/locales/is.d.cts +5 -0
- package/node_modules/zod/v4/locales/is.d.ts +4 -0
- package/node_modules/zod/v4/locales/is.js +114 -0
- package/node_modules/zod/v4/locales/it.cjs +140 -0
- package/node_modules/zod/v4/locales/it.d.cts +5 -0
- package/node_modules/zod/v4/locales/it.d.ts +4 -0
- package/node_modules/zod/v4/locales/it.js +113 -0
- package/node_modules/zod/v4/locales/ja.cjs +139 -0
- package/node_modules/zod/v4/locales/ja.d.cts +5 -0
- package/node_modules/zod/v4/locales/ja.d.ts +4 -0
- package/node_modules/zod/v4/locales/ja.js +112 -0
- package/node_modules/zod/v4/locales/ka.cjs +144 -0
- package/node_modules/zod/v4/locales/ka.d.cts +5 -0
- package/node_modules/zod/v4/locales/ka.d.ts +4 -0
- package/node_modules/zod/v4/locales/ka.js +117 -0
- package/node_modules/zod/v4/locales/kh.cjs +12 -0
- package/node_modules/zod/v4/locales/kh.d.cts +5 -0
- package/node_modules/zod/v4/locales/kh.d.ts +5 -0
- package/node_modules/zod/v4/locales/kh.js +5 -0
- package/node_modules/zod/v4/locales/km.cjs +142 -0
- package/node_modules/zod/v4/locales/km.d.cts +5 -0
- package/node_modules/zod/v4/locales/km.d.ts +4 -0
- package/node_modules/zod/v4/locales/km.js +115 -0
- package/node_modules/zod/v4/locales/kn.cjs +143 -0
- package/node_modules/zod/v4/locales/kn.d.cts +5 -0
- package/node_modules/zod/v4/locales/kn.d.ts +4 -0
- package/node_modules/zod/v4/locales/kn.js +116 -0
- package/node_modules/zod/v4/locales/ko.cjs +143 -0
- package/node_modules/zod/v4/locales/ko.d.cts +5 -0
- package/node_modules/zod/v4/locales/ko.d.ts +4 -0
- package/node_modules/zod/v4/locales/ko.js +116 -0
- package/node_modules/zod/v4/locales/lt.cjs +234 -0
- package/node_modules/zod/v4/locales/lt.d.cts +5 -0
- package/node_modules/zod/v4/locales/lt.d.ts +4 -0
- package/node_modules/zod/v4/locales/lt.js +207 -0
- package/node_modules/zod/v4/locales/mk.cjs +141 -0
- package/node_modules/zod/v4/locales/mk.d.cts +5 -0
- package/node_modules/zod/v4/locales/mk.d.ts +4 -0
- package/node_modules/zod/v4/locales/mk.js +114 -0
- package/node_modules/zod/v4/locales/ms.cjs +139 -0
- package/node_modules/zod/v4/locales/ms.d.cts +5 -0
- package/node_modules/zod/v4/locales/ms.d.ts +4 -0
- package/node_modules/zod/v4/locales/ms.js +112 -0
- package/node_modules/zod/v4/locales/ne.cjs +138 -0
- package/node_modules/zod/v4/locales/ne.d.cts +5 -0
- package/node_modules/zod/v4/locales/ne.d.ts +4 -0
- package/node_modules/zod/v4/locales/ne.js +111 -0
- package/node_modules/zod/v4/locales/nl.cjs +142 -0
- package/node_modules/zod/v4/locales/nl.d.cts +5 -0
- package/node_modules/zod/v4/locales/nl.d.ts +4 -0
- package/node_modules/zod/v4/locales/nl.js +115 -0
- package/node_modules/zod/v4/locales/nn.cjs +140 -0
- package/node_modules/zod/v4/locales/nn.d.cts +5 -0
- package/node_modules/zod/v4/locales/nn.d.ts +4 -0
- package/node_modules/zod/v4/locales/nn.js +113 -0
- package/node_modules/zod/v4/locales/no.cjs +140 -0
- package/node_modules/zod/v4/locales/no.d.cts +5 -0
- package/node_modules/zod/v4/locales/no.d.ts +4 -0
- package/node_modules/zod/v4/locales/no.js +113 -0
- package/node_modules/zod/v4/locales/ota.cjs +141 -0
- package/node_modules/zod/v4/locales/ota.d.cts +5 -0
- package/node_modules/zod/v4/locales/ota.d.ts +4 -0
- package/node_modules/zod/v4/locales/ota.js +114 -0
- package/node_modules/zod/v4/locales/package.json +7 -0
- package/node_modules/zod/v4/locales/pl.cjs +141 -0
- package/node_modules/zod/v4/locales/pl.d.cts +5 -0
- package/node_modules/zod/v4/locales/pl.d.ts +4 -0
- package/node_modules/zod/v4/locales/pl.js +114 -0
- package/node_modules/zod/v4/locales/ps.cjs +146 -0
- package/node_modules/zod/v4/locales/ps.d.cts +5 -0
- package/node_modules/zod/v4/locales/ps.d.ts +4 -0
- package/node_modules/zod/v4/locales/ps.js +119 -0
- package/node_modules/zod/v4/locales/pt-BR.cjs +170 -0
- package/node_modules/zod/v4/locales/pt-BR.d.cts +5 -0
- package/node_modules/zod/v4/locales/pt-BR.d.ts +4 -0
- package/node_modules/zod/v4/locales/pt-BR.js +143 -0
- package/node_modules/zod/v4/locales/pt.cjs +169 -0
- package/node_modules/zod/v4/locales/pt.d.cts +5 -0
- package/node_modules/zod/v4/locales/pt.d.ts +4 -0
- package/node_modules/zod/v4/locales/pt.js +142 -0
- package/node_modules/zod/v4/locales/ro.cjs +149 -0
- package/node_modules/zod/v4/locales/ro.d.cts +5 -0
- package/node_modules/zod/v4/locales/ro.d.ts +4 -0
- package/node_modules/zod/v4/locales/ro.js +122 -0
- package/node_modules/zod/v4/locales/ru.cjs +195 -0
- package/node_modules/zod/v4/locales/ru.d.cts +5 -0
- package/node_modules/zod/v4/locales/ru.d.ts +4 -0
- package/node_modules/zod/v4/locales/ru.js +168 -0
- package/node_modules/zod/v4/locales/sk.cjs +143 -0
- package/node_modules/zod/v4/locales/sk.d.cts +5 -0
- package/node_modules/zod/v4/locales/sk.d.ts +4 -0
- package/node_modules/zod/v4/locales/sk.js +116 -0
- package/node_modules/zod/v4/locales/sl.cjs +141 -0
- package/node_modules/zod/v4/locales/sl.d.cts +5 -0
- package/node_modules/zod/v4/locales/sl.d.ts +4 -0
- package/node_modules/zod/v4/locales/sl.js +114 -0
- package/node_modules/zod/v4/locales/sv.cjs +142 -0
- package/node_modules/zod/v4/locales/sv.d.cts +5 -0
- package/node_modules/zod/v4/locales/sv.d.ts +4 -0
- package/node_modules/zod/v4/locales/sv.js +115 -0
- package/node_modules/zod/v4/locales/ta.cjs +142 -0
- package/node_modules/zod/v4/locales/ta.d.cts +5 -0
- package/node_modules/zod/v4/locales/ta.d.ts +4 -0
- package/node_modules/zod/v4/locales/ta.js +115 -0
- package/node_modules/zod/v4/locales/tg.cjs +144 -0
- package/node_modules/zod/v4/locales/tg.d.cts +5 -0
- package/node_modules/zod/v4/locales/tg.d.ts +4 -0
- package/node_modules/zod/v4/locales/tg.js +117 -0
- package/node_modules/zod/v4/locales/th.cjs +142 -0
- package/node_modules/zod/v4/locales/th.d.cts +5 -0
- package/node_modules/zod/v4/locales/th.d.ts +4 -0
- package/node_modules/zod/v4/locales/th.js +115 -0
- package/node_modules/zod/v4/locales/tk.cjs +134 -0
- package/node_modules/zod/v4/locales/tk.d.cts +5 -0
- package/node_modules/zod/v4/locales/tk.d.ts +4 -0
- package/node_modules/zod/v4/locales/tk.js +107 -0
- package/node_modules/zod/v4/locales/tr.cjs +137 -0
- package/node_modules/zod/v4/locales/tr.d.cts +5 -0
- package/node_modules/zod/v4/locales/tr.d.ts +4 -0
- package/node_modules/zod/v4/locales/tr.js +110 -0
- package/node_modules/zod/v4/locales/ua.cjs +12 -0
- package/node_modules/zod/v4/locales/ua.d.cts +5 -0
- package/node_modules/zod/v4/locales/ua.d.ts +5 -0
- package/node_modules/zod/v4/locales/ua.js +5 -0
- package/node_modules/zod/v4/locales/uk.cjs +140 -0
- package/node_modules/zod/v4/locales/uk.d.cts +5 -0
- package/node_modules/zod/v4/locales/uk.d.ts +4 -0
- package/node_modules/zod/v4/locales/uk.js +113 -0
- package/node_modules/zod/v4/locales/ur.cjs +142 -0
- package/node_modules/zod/v4/locales/ur.d.cts +5 -0
- package/node_modules/zod/v4/locales/ur.d.ts +4 -0
- package/node_modules/zod/v4/locales/ur.js +115 -0
- package/node_modules/zod/v4/locales/uz.cjs +140 -0
- package/node_modules/zod/v4/locales/uz.d.cts +5 -0
- package/node_modules/zod/v4/locales/uz.d.ts +4 -0
- package/node_modules/zod/v4/locales/uz.js +113 -0
- package/node_modules/zod/v4/locales/vi.cjs +140 -0
- package/node_modules/zod/v4/locales/vi.d.cts +5 -0
- package/node_modules/zod/v4/locales/vi.d.ts +4 -0
- package/node_modules/zod/v4/locales/vi.js +113 -0
- package/node_modules/zod/v4/locales/yo.cjs +139 -0
- package/node_modules/zod/v4/locales/yo.d.cts +5 -0
- package/node_modules/zod/v4/locales/yo.d.ts +4 -0
- package/node_modules/zod/v4/locales/yo.js +112 -0
- package/node_modules/zod/v4/locales/zh-CN.cjs +141 -0
- package/node_modules/zod/v4/locales/zh-CN.d.cts +5 -0
- package/node_modules/zod/v4/locales/zh-CN.d.ts +4 -0
- package/node_modules/zod/v4/locales/zh-CN.js +114 -0
- package/node_modules/zod/v4/locales/zh-TW.cjs +139 -0
- package/node_modules/zod/v4/locales/zh-TW.d.cts +5 -0
- package/node_modules/zod/v4/locales/zh-TW.d.ts +4 -0
- package/node_modules/zod/v4/locales/zh-TW.js +112 -0
- package/node_modules/zod/v4/mini/checks.cjs +54 -0
- package/node_modules/zod/v4/mini/checks.d.cts +1 -0
- package/node_modules/zod/v4/mini/checks.d.ts +1 -0
- package/node_modules/zod/v4/mini/checks.js +1 -0
- package/node_modules/zod/v4/mini/coerce.cjs +71 -0
- package/node_modules/zod/v4/mini/coerce.d.cts +7 -0
- package/node_modules/zod/v4/mini/coerce.d.ts +7 -0
- package/node_modules/zod/v4/mini/coerce.js +22 -0
- package/node_modules/zod/v4/mini/deep-partial.cjs +58 -0
- package/node_modules/zod/v4/mini/deep-partial.d.cts +14 -0
- package/node_modules/zod/v4/mini/deep-partial.d.ts +14 -0
- package/node_modules/zod/v4/mini/deep-partial.js +13 -0
- package/node_modules/zod/v4/mini/external.cjs +95 -0
- package/node_modules/zod/v4/mini/external.d.cts +16 -0
- package/node_modules/zod/v4/mini/external.d.ts +16 -0
- package/node_modules/zod/v4/mini/external.js +16 -0
- package/node_modules/zod/v4/mini/in-out.cjs +82 -0
- package/node_modules/zod/v4/mini/in-out.d.cts +8 -0
- package/node_modules/zod/v4/mini/in-out.d.ts +8 -0
- package/node_modules/zod/v4/mini/in-out.js +36 -0
- package/node_modules/zod/v4/mini/index.cjs +51 -0
- package/node_modules/zod/v4/mini/index.d.cts +3 -0
- package/node_modules/zod/v4/mini/index.d.ts +3 -0
- package/node_modules/zod/v4/mini/index.js +3 -0
- package/node_modules/zod/v4/mini/iso.cjs +83 -0
- package/node_modules/zod/v4/mini/iso.d.cts +22 -0
- package/node_modules/zod/v4/mini/iso.d.ts +22 -0
- package/node_modules/zod/v4/mini/iso.js +34 -0
- package/node_modules/zod/v4/mini/package.json +7 -0
- package/node_modules/zod/v4/mini/parse.cjs +37 -0
- package/node_modules/zod/v4/mini/parse.d.cts +1 -0
- package/node_modules/zod/v4/mini/parse.d.ts +1 -0
- package/node_modules/zod/v4/mini/parse.js +1 -0
- package/node_modules/zod/v4/mini/schemas.cjs +1147 -0
- package/node_modules/zod/v4/mini/schemas.d.cts +480 -0
- package/node_modules/zod/v4/mini/schemas.d.ts +480 -0
- package/node_modules/zod/v4/mini/schemas.js +1002 -0
- package/node_modules/zod/v4/package.json +7 -0
- package/node_modules/zod/v4-mini/index.cjs +51 -0
- package/node_modules/zod/v4-mini/index.d.cts +3 -0
- package/node_modules/zod/v4-mini/index.d.ts +3 -0
- package/node_modules/zod/v4-mini/index.js +3 -0
- package/node_modules/zod/v4-mini/package.json +7 -0
- package/package.json +73 -4
|
@@ -0,0 +1,2541 @@
|
|
|
1
|
+
import { a as MAX_TIMER_DELAY_MS, t as createOutputFormatter } from "./output-C_T39Ap1.js";
|
|
2
|
+
import { D as runTimedExecFile } from "./agent-registry-CxpAF3nI.js";
|
|
3
|
+
import { $t as spawnEnoentHint, C as textPrompt, Ft as SESSION_RECORD_SCHEMA, Nt as PERMISSION_MODES, R as resolveSessionRecord, S as promptToDisplayText, bt as writePrivateJsonFile, ft as defaultSessionEventLog, yt as writePrivateFile } from "./ipc-CQUNQ8QQ.js";
|
|
4
|
+
import { G as recordSessionUpdate, H as createSessionConversation, K as cloneSessionAcpxState, U as recordClientOperation, W as recordPromptSubmission, dt as TimeoutError, i as runOnce, m as createSessionWithClient, mt as withTimeout, o as sendSessionDirect, pt as withInterrupt, ut as InterruptedError } from "./queue-owner-runtime-ucHvXJ33.js";
|
|
5
|
+
import path from "node:path";
|
|
6
|
+
import { spawn } from "node:child_process";
|
|
7
|
+
import fs from "node:fs/promises";
|
|
8
|
+
import os from "node:os";
|
|
9
|
+
import { appendRegularFile } from "@openclaw/fs-safe/advanced";
|
|
10
|
+
import { setTimeout as setTimeout$1 } from "node:timers/promises";
|
|
11
|
+
import { ZodError, z } from "zod";
|
|
12
|
+
import { createHash, randomUUID } from "node:crypto";
|
|
13
|
+
import { performance } from "node:perf_hooks";
|
|
14
|
+
// src/flows/timeout.ts
|
|
15
|
+
function resolveFlowTimeoutMs(timeoutMs) {
|
|
16
|
+
if (timeoutMs === void 0) return;
|
|
17
|
+
if (!Number.isFinite(timeoutMs) || timeoutMs > 2147483647) throw new TypeError(`timeoutMs must be a finite number no greater than ${MAX_TIMER_DELAY_MS}`);
|
|
18
|
+
return timeoutMs > 0 ? timeoutMs : void 0;
|
|
19
|
+
}
|
|
20
|
+
// src/flows/attempt.ts
|
|
21
|
+
/** One node attempt owns admission and completion of its managed operations. */
|
|
22
|
+
var FlowAttempt = class {
|
|
23
|
+
signal;
|
|
24
|
+
nodeId;
|
|
25
|
+
attemptId;
|
|
26
|
+
startedAt;
|
|
27
|
+
terminationSignal = "SIGTERM";
|
|
28
|
+
controller = new AbortController();
|
|
29
|
+
pending = /* @__PURE__ */ new Set();
|
|
30
|
+
cancellations = /* @__PURE__ */ new Set();
|
|
31
|
+
cleanupFailures = [];
|
|
32
|
+
deadlineAt;
|
|
33
|
+
timeoutMs;
|
|
34
|
+
timer;
|
|
35
|
+
accepting = true;
|
|
36
|
+
finished = false;
|
|
37
|
+
constructor(options) {
|
|
38
|
+
this.nodeId = options.nodeId;
|
|
39
|
+
this.attemptId = options.attemptId;
|
|
40
|
+
this.startedAt = options.startedAt;
|
|
41
|
+
this.signal = this.controller.signal;
|
|
42
|
+
const timeoutMs = resolveFlowTimeoutMs(options.timeoutMs);
|
|
43
|
+
if (timeoutMs !== void 0) {
|
|
44
|
+
this.timeoutMs = timeoutMs;
|
|
45
|
+
this.deadlineAt = performance.now() + timeoutMs;
|
|
46
|
+
this.timer = setTimeout(() => this.cancel(new TimeoutError(timeoutMs)), timeoutMs);
|
|
47
|
+
}
|
|
48
|
+
}
|
|
49
|
+
get active() {
|
|
50
|
+
return this.accepting && !this.signal.aborted;
|
|
51
|
+
}
|
|
52
|
+
assertActive() {
|
|
53
|
+
this.checkDeadline();
|
|
54
|
+
this.signal.throwIfAborted();
|
|
55
|
+
if (!this.accepting) throw new Error("Flow attempt has finished accepting work");
|
|
56
|
+
}
|
|
57
|
+
remainingTimeoutMs() {
|
|
58
|
+
this.assertActive();
|
|
59
|
+
return this.deadlineAt === void 0 ? void 0 : Math.max(1, Math.ceil(this.deadlineAt - performance.now()));
|
|
60
|
+
}
|
|
61
|
+
cancel(reason, signal = "SIGTERM") {
|
|
62
|
+
if (this.finished || this.signal.aborted) return;
|
|
63
|
+
this.accepting = false;
|
|
64
|
+
this.terminationSignal = signal;
|
|
65
|
+
this.controller.abort(reason);
|
|
66
|
+
for (const cancel of this.cancellations) this.trackCancellation(cancel);
|
|
67
|
+
}
|
|
68
|
+
registerCancellation(cancel) {
|
|
69
|
+
if (!this.active) {
|
|
70
|
+
this.trackCancellation(cancel);
|
|
71
|
+
return () => {};
|
|
72
|
+
}
|
|
73
|
+
this.cancellations.add(cancel);
|
|
74
|
+
return () => {
|
|
75
|
+
this.cancellations.delete(cancel);
|
|
76
|
+
};
|
|
77
|
+
}
|
|
78
|
+
/** Track runtime work, never an arbitrary user callback that may ignore cancellation. */
|
|
79
|
+
own(run, options = {}) {
|
|
80
|
+
this.assertActive();
|
|
81
|
+
const operation = run().then((value) => {
|
|
82
|
+
this.checkDeadline();
|
|
83
|
+
if (this.signal.aborted) this.signal.throwIfAborted();
|
|
84
|
+
return value;
|
|
85
|
+
});
|
|
86
|
+
const outcome = operation.then(() => ({ ok: true }), (error) => options.bestEffort ? { ok: true } : {
|
|
87
|
+
ok: false,
|
|
88
|
+
error
|
|
89
|
+
});
|
|
90
|
+
this.pending.add(outcome);
|
|
91
|
+
outcome.then(() => this.pending.delete(outcome));
|
|
92
|
+
return operation;
|
|
93
|
+
}
|
|
94
|
+
async run(run) {
|
|
95
|
+
let rejectAbort = () => {};
|
|
96
|
+
const aborted = new Promise((_resolve, reject) => {
|
|
97
|
+
rejectAbort = reject;
|
|
98
|
+
});
|
|
99
|
+
const onAbort = () => rejectAbort(this.signal.reason);
|
|
100
|
+
this.signal.addEventListener("abort", onAbort, { once: true });
|
|
101
|
+
try {
|
|
102
|
+
this.assertActive();
|
|
103
|
+
const value = await Promise.race([run(), aborted]);
|
|
104
|
+
this.accepting = false;
|
|
105
|
+
const errors = await this.drain();
|
|
106
|
+
if (errors.length > 0) throw this.cleanupError(errors);
|
|
107
|
+
this.checkDeadline();
|
|
108
|
+
this.signal.throwIfAborted();
|
|
109
|
+
return value;
|
|
110
|
+
} catch (error) {
|
|
111
|
+
this.cancel(error);
|
|
112
|
+
const errors = await this.drain();
|
|
113
|
+
if (errors.length > 0) throw this.cleanupError([error, ...errors]);
|
|
114
|
+
throw error;
|
|
115
|
+
} finally {
|
|
116
|
+
this.accepting = false;
|
|
117
|
+
this.finished = true;
|
|
118
|
+
clearTimeout(this.timer);
|
|
119
|
+
this.signal.removeEventListener("abort", onAbort);
|
|
120
|
+
}
|
|
121
|
+
}
|
|
122
|
+
checkDeadline() {
|
|
123
|
+
if (this.deadlineAt !== void 0 && performance.now() >= this.deadlineAt) this.cancel(new TimeoutError(this.timeoutMs));
|
|
124
|
+
}
|
|
125
|
+
async drain() {
|
|
126
|
+
const errors = [];
|
|
127
|
+
while (this.pending.size > 0) for (const outcome of await Promise.all(this.pending)) if (!outcome.ok && outcome.error !== this.signal.reason) errors.push(outcome.error);
|
|
128
|
+
return [.../* @__PURE__ */ new Set([...errors, ...this.cleanupFailures.splice(0)])];
|
|
129
|
+
}
|
|
130
|
+
trackCancellation(cancel) {
|
|
131
|
+
const outcome = Promise.resolve().then(() => cancel(this.terminationSignal)).then(() => ({ ok: true }), (error) => {
|
|
132
|
+
this.cleanupFailures.push(error);
|
|
133
|
+
return { ok: true };
|
|
134
|
+
});
|
|
135
|
+
this.pending.add(outcome);
|
|
136
|
+
outcome.then(() => this.pending.delete(outcome));
|
|
137
|
+
}
|
|
138
|
+
cleanupError(errors) {
|
|
139
|
+
const reason = this.signal.reason;
|
|
140
|
+
const failures = [.../* @__PURE__ */ new Set([...this.signal.aborted ? [reason] : [], ...errors])];
|
|
141
|
+
return new AggregateError(failures, "Flow attempt cleanup failed", { cause: failures[0] });
|
|
142
|
+
}
|
|
143
|
+
};
|
|
144
|
+
// src/flows/authoring.ts
|
|
145
|
+
const FLOW_DEFINITION_BRAND = Symbol.for("acpx.flow.definition");
|
|
146
|
+
function markDefinedFlow(definition) {
|
|
147
|
+
if (isDefinedFlow(definition)) return definition;
|
|
148
|
+
Object.defineProperty(definition, FLOW_DEFINITION_BRAND, {
|
|
149
|
+
value: true,
|
|
150
|
+
enumerable: false,
|
|
151
|
+
configurable: false,
|
|
152
|
+
writable: false
|
|
153
|
+
});
|
|
154
|
+
return definition;
|
|
155
|
+
}
|
|
156
|
+
function isDefinedFlow(value) {
|
|
157
|
+
return value != null && typeof value === "object" && value[FLOW_DEFINITION_BRAND] === true;
|
|
158
|
+
}
|
|
159
|
+
// src/flows/schema.ts
|
|
160
|
+
const FLOW_NODE_TYPES = [
|
|
161
|
+
"acp",
|
|
162
|
+
"compute",
|
|
163
|
+
"action",
|
|
164
|
+
"checkpoint"
|
|
165
|
+
];
|
|
166
|
+
const finiteNonNegativeNumberSchema = z.number().finite().nonnegative();
|
|
167
|
+
const nonEmptyTrimmedStringSchema = z.string().refine((value) => value.trim().length > 0, { message: "must not be empty" });
|
|
168
|
+
function extensibleObject(shape) {
|
|
169
|
+
return z.object(shape).passthrough();
|
|
170
|
+
}
|
|
171
|
+
function functionSchema(label) {
|
|
172
|
+
return z.custom((value) => typeof value === "function", { message: `${label} must be a function` });
|
|
173
|
+
}
|
|
174
|
+
const flowNodeCommonShape = {
|
|
175
|
+
timeoutMs: finiteNonNegativeNumberSchema.max(MAX_TIMER_DELAY_MS).optional(),
|
|
176
|
+
heartbeatMs: finiteNonNegativeNumberSchema.optional(),
|
|
177
|
+
statusDetail: z.string().optional()
|
|
178
|
+
};
|
|
179
|
+
const flowPermissionRequirementsSchema = extensibleObject({
|
|
180
|
+
requiredMode: z.enum(PERMISSION_MODES),
|
|
181
|
+
requireExplicitGrant: z.boolean().optional(),
|
|
182
|
+
reason: nonEmptyTrimmedStringSchema.optional()
|
|
183
|
+
});
|
|
184
|
+
const flowRunDefinitionSchema = extensibleObject({ title: z.union([z.string(), functionSchema("run.title")]).optional() });
|
|
185
|
+
const acpSessionSchema = extensibleObject({
|
|
186
|
+
handle: z.string().optional(),
|
|
187
|
+
isolated: z.boolean().optional()
|
|
188
|
+
});
|
|
189
|
+
const acpNodeSchema = extensibleObject({
|
|
190
|
+
...flowNodeCommonShape,
|
|
191
|
+
nodeType: z.literal("acp"),
|
|
192
|
+
profile: z.string().optional(),
|
|
193
|
+
modelId: nonEmptyTrimmedStringSchema.optional(),
|
|
194
|
+
configOptions: z.array(extensibleObject({
|
|
195
|
+
configId: nonEmptyTrimmedStringSchema,
|
|
196
|
+
value: nonEmptyTrimmedStringSchema
|
|
197
|
+
})).optional(),
|
|
198
|
+
cwd: z.union([z.string(), functionSchema("cwd")]).optional(),
|
|
199
|
+
session: acpSessionSchema.optional(),
|
|
200
|
+
prompt: functionSchema("prompt"),
|
|
201
|
+
parse: functionSchema("parse").optional()
|
|
202
|
+
});
|
|
203
|
+
const computeNodeSchema = extensibleObject({
|
|
204
|
+
...flowNodeCommonShape,
|
|
205
|
+
nodeType: z.literal("compute"),
|
|
206
|
+
run: functionSchema("run")
|
|
207
|
+
});
|
|
208
|
+
const functionActionNodeSchema = extensibleObject({
|
|
209
|
+
...flowNodeCommonShape,
|
|
210
|
+
nodeType: z.literal("action"),
|
|
211
|
+
run: functionSchema("run")
|
|
212
|
+
});
|
|
213
|
+
const shellActionNodeSchema = extensibleObject({
|
|
214
|
+
...flowNodeCommonShape,
|
|
215
|
+
nodeType: z.literal("action"),
|
|
216
|
+
exec: functionSchema("exec"),
|
|
217
|
+
parse: functionSchema("parse").optional()
|
|
218
|
+
}).refine((node) => !hasOwn(node, "run"), { message: "shell action nodes must not define run" });
|
|
219
|
+
const checkpointNodeSchema = extensibleObject({
|
|
220
|
+
...flowNodeCommonShape,
|
|
221
|
+
nodeType: z.literal("checkpoint"),
|
|
222
|
+
summary: z.string().optional(),
|
|
223
|
+
run: functionSchema("run").optional()
|
|
224
|
+
});
|
|
225
|
+
const directFlowEdgeSchema = extensibleObject({
|
|
226
|
+
from: z.string(),
|
|
227
|
+
to: z.string()
|
|
228
|
+
});
|
|
229
|
+
const switchFlowEdgeSchema = extensibleObject({
|
|
230
|
+
from: z.string(),
|
|
231
|
+
switch: extensibleObject({
|
|
232
|
+
on: z.string(),
|
|
233
|
+
cases: z.record(z.string(), z.string())
|
|
234
|
+
})
|
|
235
|
+
});
|
|
236
|
+
const flowDefinitionSchema = extensibleObject({
|
|
237
|
+
name: nonEmptyTrimmedStringSchema,
|
|
238
|
+
run: flowRunDefinitionSchema.optional(),
|
|
239
|
+
permissions: flowPermissionRequirementsSchema.optional(),
|
|
240
|
+
startAt: z.string(),
|
|
241
|
+
nodes: z.record(z.string(), z.unknown()),
|
|
242
|
+
edges: z.array(z.unknown())
|
|
243
|
+
});
|
|
244
|
+
const flowNodeTypeSchema = z.object({ nodeType: z.enum(FLOW_NODE_TYPES) });
|
|
245
|
+
function assertValidFlowDefinitionShape(flow) {
|
|
246
|
+
const parsed = parseWithSchema("flow definition", flowDefinitionSchema, flow);
|
|
247
|
+
for (const [nodeId, node] of Object.entries(flow.nodes)) assertValidFlowNodeDefinitionShape(node, `flow node "${nodeId}"`);
|
|
248
|
+
parsed.edges.forEach((edge, index) => {
|
|
249
|
+
assertValidFlowEdgeShape(edge, `flow definition: edges.${index}`);
|
|
250
|
+
});
|
|
251
|
+
}
|
|
252
|
+
function assertValidAcpNodeDefinition(node) {
|
|
253
|
+
parseWithSchema("acp node definition", acpNodeSchema, node);
|
|
254
|
+
}
|
|
255
|
+
function assertValidComputeNodeDefinition(node) {
|
|
256
|
+
parseWithSchema("compute node definition", computeNodeSchema, node);
|
|
257
|
+
}
|
|
258
|
+
function assertValidActionNodeDefinition(node) {
|
|
259
|
+
assertValidActionNodeDefinitionShape(node, "action node definition");
|
|
260
|
+
}
|
|
261
|
+
function assertValidShellActionNodeDefinition(node) {
|
|
262
|
+
parseWithSchema("shell action node definition", shellActionNodeSchema, node);
|
|
263
|
+
}
|
|
264
|
+
function assertValidCheckpointNodeDefinition(node) {
|
|
265
|
+
parseWithSchema("checkpoint node definition", checkpointNodeSchema, node);
|
|
266
|
+
}
|
|
267
|
+
function assertValidFlowNodeDefinitionShape(node, label) {
|
|
268
|
+
const { nodeType } = parseWithSchema(label, flowNodeTypeSchema, node);
|
|
269
|
+
switch (nodeType) {
|
|
270
|
+
case "acp":
|
|
271
|
+
parseWithSchema(label, acpNodeSchema, node);
|
|
272
|
+
return;
|
|
273
|
+
case "compute":
|
|
274
|
+
parseWithSchema(label, computeNodeSchema, node);
|
|
275
|
+
return;
|
|
276
|
+
case "action":
|
|
277
|
+
assertValidActionNodeDefinitionShape(node, label);
|
|
278
|
+
return;
|
|
279
|
+
case "checkpoint":
|
|
280
|
+
parseWithSchema(label, checkpointNodeSchema, node);
|
|
281
|
+
return;
|
|
282
|
+
}
|
|
283
|
+
}
|
|
284
|
+
function assertValidActionNodeDefinitionShape(node, label) {
|
|
285
|
+
const hasRun = hasOwn(node, "run");
|
|
286
|
+
const hasExec = hasOwn(node, "exec");
|
|
287
|
+
if (hasRun === hasExec) throw new Error(`Invalid ${label}: action nodes must define exactly one of run or exec`);
|
|
288
|
+
if (hasExec) {
|
|
289
|
+
parseWithSchema(label, shellActionNodeSchema, node);
|
|
290
|
+
return;
|
|
291
|
+
}
|
|
292
|
+
parseWithSchema(label, functionActionNodeSchema, node);
|
|
293
|
+
}
|
|
294
|
+
function assertValidFlowEdgeShape(edge, label) {
|
|
295
|
+
const hasTo = hasOwn(edge, "to");
|
|
296
|
+
if (hasTo === hasOwn(edge, "switch")) throw new Error(`Invalid ${label}: edge must define exactly one of to or switch`);
|
|
297
|
+
if (hasTo) {
|
|
298
|
+
parseWithSchema(label, directFlowEdgeSchema, edge);
|
|
299
|
+
return;
|
|
300
|
+
}
|
|
301
|
+
parseWithSchema(label, switchFlowEdgeSchema, edge);
|
|
302
|
+
const cases = edge.switch.cases;
|
|
303
|
+
for (const [key, target] of Object.entries(cases)) parseWithSchema(`${label}: switch.cases.${key}`, z.string(), target);
|
|
304
|
+
}
|
|
305
|
+
function parseWithSchema(label, schema, value) {
|
|
306
|
+
try {
|
|
307
|
+
return schema.parse(value);
|
|
308
|
+
} catch (error) {
|
|
309
|
+
if (error instanceof ZodError) throw new Error(formatValidationError(label, error), { cause: error });
|
|
310
|
+
throw error;
|
|
311
|
+
}
|
|
312
|
+
}
|
|
313
|
+
function formatValidationError(label, error) {
|
|
314
|
+
return `Invalid ${label}: ${Array.from(new Set(error.issues.flatMap((issue) => formatIssue(issue)))).join("; ")}`;
|
|
315
|
+
}
|
|
316
|
+
function formatIssue(issue, parentPath = []) {
|
|
317
|
+
const path = [...parentPath, ...issue.path.map(String)];
|
|
318
|
+
if (issue.code === "invalid_union") return issue.errors.flatMap((branch) => branch.flatMap((nestedIssue) => formatIssue(nestedIssue, path)));
|
|
319
|
+
const renderedPath = path.join(".");
|
|
320
|
+
return [renderedPath ? `${renderedPath}: ${issue.message}` : issue.message];
|
|
321
|
+
}
|
|
322
|
+
function hasOwn(value, key) {
|
|
323
|
+
return value != null && typeof value === "object" && Object.prototype.hasOwnProperty.call(value, key);
|
|
324
|
+
}
|
|
325
|
+
// src/flows/definition.ts
|
|
326
|
+
function defineFlow(definition) {
|
|
327
|
+
assertValidFlowDefinitionShape(definition);
|
|
328
|
+
return markDefinedFlow(definition);
|
|
329
|
+
}
|
|
330
|
+
function acp(definition) {
|
|
331
|
+
const node = {
|
|
332
|
+
nodeType: "acp",
|
|
333
|
+
...definition
|
|
334
|
+
};
|
|
335
|
+
assertValidAcpNodeDefinition(node);
|
|
336
|
+
return node;
|
|
337
|
+
}
|
|
338
|
+
function compute(definition) {
|
|
339
|
+
const node = {
|
|
340
|
+
nodeType: "compute",
|
|
341
|
+
...definition
|
|
342
|
+
};
|
|
343
|
+
assertValidComputeNodeDefinition(node);
|
|
344
|
+
return node;
|
|
345
|
+
}
|
|
346
|
+
function action(definition) {
|
|
347
|
+
const node = {
|
|
348
|
+
nodeType: "action",
|
|
349
|
+
...definition
|
|
350
|
+
};
|
|
351
|
+
assertValidActionNodeDefinition(node);
|
|
352
|
+
return node;
|
|
353
|
+
}
|
|
354
|
+
function shell(definition) {
|
|
355
|
+
const node = {
|
|
356
|
+
nodeType: "action",
|
|
357
|
+
...definition
|
|
358
|
+
};
|
|
359
|
+
assertValidShellActionNodeDefinition(node);
|
|
360
|
+
return node;
|
|
361
|
+
}
|
|
362
|
+
function checkpoint(definition = {}) {
|
|
363
|
+
const node = {
|
|
364
|
+
nodeType: "checkpoint",
|
|
365
|
+
...definition
|
|
366
|
+
};
|
|
367
|
+
assertValidCheckpointNodeDefinition(node);
|
|
368
|
+
return node;
|
|
369
|
+
}
|
|
370
|
+
// src/flows/executors/shell-output.ts
|
|
371
|
+
function validateShellActionMaxBufferBytes(value) {
|
|
372
|
+
if (value === void 0) return;
|
|
373
|
+
if (!Number.isSafeInteger(value) || value < 0) throw new Error("Shell action maxBufferBytes must be a non-negative safe integer");
|
|
374
|
+
}
|
|
375
|
+
function createShellOutputCapture(maxBufferBytes, inactive, overflow) {
|
|
376
|
+
const output = {
|
|
377
|
+
stdout: "",
|
|
378
|
+
stderr: ""
|
|
379
|
+
};
|
|
380
|
+
const bytes = {
|
|
381
|
+
stdout: 0,
|
|
382
|
+
stderr: 0
|
|
383
|
+
};
|
|
384
|
+
return {
|
|
385
|
+
output,
|
|
386
|
+
append(stream, chunk) {
|
|
387
|
+
if (inactive()) return;
|
|
388
|
+
if (maxBufferBytes !== void 0) {
|
|
389
|
+
bytes[stream] += Buffer.byteLength(chunk, "utf8");
|
|
390
|
+
if (bytes[stream] > maxBufferBytes) {
|
|
391
|
+
overflow(/* @__PURE__ */ new Error(`Shell action exceeded maxBuffer (${maxBufferBytes} bytes) on ${stream}`));
|
|
392
|
+
return;
|
|
393
|
+
}
|
|
394
|
+
}
|
|
395
|
+
output[stream] += chunk;
|
|
396
|
+
}
|
|
397
|
+
};
|
|
398
|
+
}
|
|
399
|
+
// src/flows/executors/shell-process.ts
|
|
400
|
+
const KILL_GRACE_MS = 1e3;
|
|
401
|
+
async function readPosixProcesses() {
|
|
402
|
+
return (await runTimedExecFile("ps", ["-eo", "pid=,ppid=,pgid=,stat="])).trim().split("\n").map((line) => {
|
|
403
|
+
const [pid, parent, group, state = ""] = line.trim().split(/\s+/u);
|
|
404
|
+
return {
|
|
405
|
+
pid: Number(pid),
|
|
406
|
+
parent: Number(parent),
|
|
407
|
+
group: Number(group),
|
|
408
|
+
state
|
|
409
|
+
};
|
|
410
|
+
}).filter((entry) => Number.isInteger(entry.pid) && entry.pid > 0);
|
|
411
|
+
}
|
|
412
|
+
function isLive(entry) {
|
|
413
|
+
return entry.state.length > 0 && !entry.state.startsWith("Z");
|
|
414
|
+
}
|
|
415
|
+
function rememberOwnedProcesses(rows, root, owned) {
|
|
416
|
+
for (const entry of rows) if (entry.group === root) owned.add(entry.pid);
|
|
417
|
+
for (const parent of owned) for (const entry of rows) if (entry.parent === parent) owned.add(entry.pid);
|
|
418
|
+
}
|
|
419
|
+
function signalPid(pid, signal) {
|
|
420
|
+
try {
|
|
421
|
+
process.kill(pid, signal);
|
|
422
|
+
} catch (error) {
|
|
423
|
+
if (error.code !== "ESRCH") throw error;
|
|
424
|
+
}
|
|
425
|
+
}
|
|
426
|
+
async function signalGroup(root, signal) {
|
|
427
|
+
try {
|
|
428
|
+
process.kill(-root, signal);
|
|
429
|
+
} catch (error) {
|
|
430
|
+
const code = error.code;
|
|
431
|
+
if (code === "ESRCH") return;
|
|
432
|
+
if (code === "EPERM" && !(await readPosixProcesses()).some((entry) => entry.group === root && isLive(entry))) return;
|
|
433
|
+
throw error;
|
|
434
|
+
}
|
|
435
|
+
}
|
|
436
|
+
async function signalOwned(root, owned, signal) {
|
|
437
|
+
const rows = await readPosixProcesses();
|
|
438
|
+
rememberOwnedProcesses(rows, root, owned);
|
|
439
|
+
await signalGroup(root, signal);
|
|
440
|
+
for (const entry of rows) if (owned.has(entry.pid) && entry.group !== root && isLive(entry)) signalPid(entry.pid, signal);
|
|
441
|
+
}
|
|
442
|
+
async function waitForOwned(root, owned) {
|
|
443
|
+
const deadline = Date.now() + KILL_GRACE_MS;
|
|
444
|
+
do {
|
|
445
|
+
const rows = await readPosixProcesses();
|
|
446
|
+
rememberOwnedProcesses(rows, root, owned);
|
|
447
|
+
if (!rows.some((entry) => owned.has(entry.pid) && isLive(entry))) return true;
|
|
448
|
+
await setTimeout$1(25);
|
|
449
|
+
} while (Date.now() < deadline);
|
|
450
|
+
return false;
|
|
451
|
+
}
|
|
452
|
+
async function forceKnownProcesses(root, owned) {
|
|
453
|
+
const results = await Promise.allSettled([signalGroup(root, "SIGKILL"), ...[...owned].map(async (pid) => signalPid(pid, "SIGKILL"))]);
|
|
454
|
+
const errors = [];
|
|
455
|
+
for (const result of results) if (result.status === "rejected") errors.push(result.reason);
|
|
456
|
+
if (errors.length > 0) throw new AggregateError(errors, "Known shell processes could not be stopped", { cause: errors[0] });
|
|
457
|
+
}
|
|
458
|
+
async function stopPosixTree(pid, signal) {
|
|
459
|
+
const owned = /* @__PURE__ */ new Set([pid]);
|
|
460
|
+
try {
|
|
461
|
+
await signalOwned(pid, owned, signal);
|
|
462
|
+
if (await waitForOwned(pid, owned)) return;
|
|
463
|
+
await signalOwned(pid, owned, "SIGKILL");
|
|
464
|
+
if (!await waitForOwned(pid, owned)) throw new Error("Shell process tree did not terminate after SIGKILL");
|
|
465
|
+
} catch (error) {
|
|
466
|
+
try {
|
|
467
|
+
await forceKnownProcesses(pid, owned);
|
|
468
|
+
} catch (cleanupError) {
|
|
469
|
+
throw new AggregateError([error, cleanupError], "Shell process cleanup failed", { cause: cleanupError });
|
|
470
|
+
}
|
|
471
|
+
throw error;
|
|
472
|
+
}
|
|
473
|
+
}
|
|
474
|
+
async function stopWindowsTree(child) {
|
|
475
|
+
if (child.pid == null || child.exitCode != null || child.signalCode != null) return;
|
|
476
|
+
try {
|
|
477
|
+
await runTimedExecFile("taskkill", [
|
|
478
|
+
"/pid",
|
|
479
|
+
String(child.pid),
|
|
480
|
+
"/t",
|
|
481
|
+
"/f"
|
|
482
|
+
], { windowsHide: true });
|
|
483
|
+
} catch (error) {
|
|
484
|
+
child.kill("SIGKILL");
|
|
485
|
+
throw error;
|
|
486
|
+
}
|
|
487
|
+
}
|
|
488
|
+
async function waitForShellClose(closed) {
|
|
489
|
+
try {
|
|
490
|
+
await withTimeout(closed, KILL_GRACE_MS);
|
|
491
|
+
} catch (cause) {
|
|
492
|
+
throw new Error("Shell process streams did not close after termination", { cause });
|
|
493
|
+
}
|
|
494
|
+
}
|
|
495
|
+
async function stopShellProcess(child, closed, signal) {
|
|
496
|
+
try {
|
|
497
|
+
if (child.pid != null) {
|
|
498
|
+
if (process.platform === "win32") await stopWindowsTree(child);
|
|
499
|
+
else await stopPosixTree(child.pid, signal);
|
|
500
|
+
}
|
|
501
|
+
} catch (error) {
|
|
502
|
+
try {
|
|
503
|
+
await waitForShellClose(closed);
|
|
504
|
+
} catch (closeError) {
|
|
505
|
+
throw new AggregateError([error, closeError], "Shell process cleanup failed", { cause: closeError });
|
|
506
|
+
}
|
|
507
|
+
throw error;
|
|
508
|
+
}
|
|
509
|
+
await waitForShellClose(closed);
|
|
510
|
+
}
|
|
511
|
+
function hasShellProcesses(child) {
|
|
512
|
+
if (child.pid == null) return false;
|
|
513
|
+
if (process.platform === "win32") return child.exitCode == null && child.signalCode == null;
|
|
514
|
+
try {
|
|
515
|
+
process.kill(-child.pid, 0);
|
|
516
|
+
return true;
|
|
517
|
+
} catch (error) {
|
|
518
|
+
return error.code !== "ESRCH";
|
|
519
|
+
}
|
|
520
|
+
}
|
|
521
|
+
// src/flows/executors/shell.ts
|
|
522
|
+
function writeShellStdin(child, stdin) {
|
|
523
|
+
const stream = child.stdin;
|
|
524
|
+
if (!stream) return;
|
|
525
|
+
stream.on("error", () => {});
|
|
526
|
+
if (stdin != null && stream.writable && !stream.writableEnded) stream.write(stdin);
|
|
527
|
+
if (stream.writable && !stream.writableEnded) stream.end();
|
|
528
|
+
}
|
|
529
|
+
function formatShellActionSummary(spec) {
|
|
530
|
+
return `shell: ${renderShellCommand(spec.command, spec.args ?? [])}`;
|
|
531
|
+
}
|
|
532
|
+
function renderShellCommand(command, args) {
|
|
533
|
+
const renderedArgs = args.map((arg) => JSON.stringify(arg)).join(" ");
|
|
534
|
+
return renderedArgs.length > 0 ? `${command} ${renderedArgs}` : command;
|
|
535
|
+
}
|
|
536
|
+
function createShellFailureError(spec, args, exitCode, signal, stderr) {
|
|
537
|
+
const status = signal ? `signal ${signal}` : `exit ${String(exitCode)}`;
|
|
538
|
+
const details = stderr.length > 0 ? `\n${stderr.trim()}` : "";
|
|
539
|
+
return /* @__PURE__ */ new Error(`Shell action failed (${renderShellCommand(spec.command, args)}): ${status}${details}`);
|
|
540
|
+
}
|
|
541
|
+
function describeShellSpawnError(spec, args, cwd, env, error) {
|
|
542
|
+
const spawnError = error;
|
|
543
|
+
if (!(error instanceof Error) || spawnError.code !== "ENOENT" || !spawnError.syscall?.startsWith("spawn")) return error;
|
|
544
|
+
const hint = spawnEnoentHint({
|
|
545
|
+
command: spawnError.path ?? spec.command,
|
|
546
|
+
cwd,
|
|
547
|
+
env
|
|
548
|
+
});
|
|
549
|
+
const described = new Error(`Shell action failed (${renderShellCommand(spec.command, args)}): ${hint}${error.message}`, { cause: error });
|
|
550
|
+
return Object.assign(described, {
|
|
551
|
+
code: spawnError.code,
|
|
552
|
+
errno: spawnError.errno,
|
|
553
|
+
syscall: spawnError.syscall,
|
|
554
|
+
path: spawnError.path
|
|
555
|
+
});
|
|
556
|
+
}
|
|
557
|
+
/**
|
|
558
|
+
* Resolve a shell-action timeout.
|
|
559
|
+
* Non-positive values match withTimeout: no deadline (undefined).
|
|
560
|
+
* Positive values arm SIGTERM/SIGKILL after that many ms.
|
|
561
|
+
*/
|
|
562
|
+
function resolveShellActionTimeoutMs(timeoutMs) {
|
|
563
|
+
return resolveFlowTimeoutMs(timeoutMs);
|
|
564
|
+
}
|
|
565
|
+
function rejectIfShellFailed(spec, args, result, timedOut, timeoutMs) {
|
|
566
|
+
if (timedOut) return new TimeoutError(timeoutMs ?? spec.timeoutMs ?? 0);
|
|
567
|
+
if (((result.exitCode ?? 0) !== 0 || result.signal != null) && spec.allowNonZeroExit !== true) return createShellFailureError(spec, args, result.exitCode, result.signal, result.stderr);
|
|
568
|
+
}
|
|
569
|
+
function waitForShellResult(child, spec, args, cwd, startMs, termination, mode) {
|
|
570
|
+
const stdoutStream = child.stdout;
|
|
571
|
+
const stderrStream = child.stderr;
|
|
572
|
+
if (!stdoutStream || !stderrStream) throw new Error("Shell action child is missing stdio pipes");
|
|
573
|
+
return new Promise((resolve, reject) => {
|
|
574
|
+
let settled = false;
|
|
575
|
+
let drainDeadline;
|
|
576
|
+
const fail = (error) => {
|
|
577
|
+
clearTimeout(drainDeadline);
|
|
578
|
+
settled = true;
|
|
579
|
+
reject(error);
|
|
580
|
+
};
|
|
581
|
+
const capture = createShellOutputCapture(spec.maxBufferBytes, () => settled || mode === "node" && termination.cancelled(), (error) => {
|
|
582
|
+
if (termination.cancelled()) return;
|
|
583
|
+
fail(error);
|
|
584
|
+
termination.cancel("SIGTERM").catch(fail);
|
|
585
|
+
});
|
|
586
|
+
stdoutStream.setEncoding("utf8");
|
|
587
|
+
stderrStream.setEncoding("utf8");
|
|
588
|
+
stdoutStream.on("data", (chunk) => {
|
|
589
|
+
capture.append("stdout", chunk);
|
|
590
|
+
});
|
|
591
|
+
stderrStream.on("data", (chunk) => {
|
|
592
|
+
capture.append("stderr", chunk);
|
|
593
|
+
});
|
|
594
|
+
child.once("error", fail);
|
|
595
|
+
const finish = (exitCode, signal) => {
|
|
596
|
+
clearTimeout(drainDeadline);
|
|
597
|
+
if (settled) return;
|
|
598
|
+
settled = true;
|
|
599
|
+
if (mode === "node" && !termination.cancelled()) {
|
|
600
|
+
stdoutStream.unref();
|
|
601
|
+
stderrStream.unref();
|
|
602
|
+
}
|
|
603
|
+
const { stdout, stderr } = capture.output;
|
|
604
|
+
resolve({
|
|
605
|
+
command: spec.command,
|
|
606
|
+
args,
|
|
607
|
+
cwd,
|
|
608
|
+
stdout,
|
|
609
|
+
stderr,
|
|
610
|
+
combinedOutput: `${stdout}${stderr}`,
|
|
611
|
+
exitCode,
|
|
612
|
+
signal,
|
|
613
|
+
durationMs: Date.now() - startMs,
|
|
614
|
+
timedOut: mode === "node" ? termination.cancelled() : termination.timedOut()
|
|
615
|
+
});
|
|
616
|
+
};
|
|
617
|
+
child.once("close", finish);
|
|
618
|
+
if (mode === "node") child.once("exit", (exitCode, signal) => {
|
|
619
|
+
if (settled) return;
|
|
620
|
+
drainDeadline = setTimeout(() => finish(exitCode, signal), 100);
|
|
621
|
+
});
|
|
622
|
+
});
|
|
623
|
+
}
|
|
624
|
+
function createShellTermination(child, timeoutMs, options) {
|
|
625
|
+
const closed = new Promise((resolve) => child.once("close", () => resolve()));
|
|
626
|
+
let rejectCleanup = () => {};
|
|
627
|
+
const cleanupFailure = new Promise((_resolve, reject) => {
|
|
628
|
+
rejectCleanup = reject;
|
|
629
|
+
});
|
|
630
|
+
let termination;
|
|
631
|
+
let timedOut = false;
|
|
632
|
+
let cancelled = false;
|
|
633
|
+
let released = false;
|
|
634
|
+
let deadline;
|
|
635
|
+
let monitor;
|
|
636
|
+
let unregister;
|
|
637
|
+
const clearDeadline = () => {
|
|
638
|
+
if (deadline) clearTimeout(deadline);
|
|
639
|
+
};
|
|
640
|
+
const release = () => {
|
|
641
|
+
if (released) return;
|
|
642
|
+
released = true;
|
|
643
|
+
clearDeadline();
|
|
644
|
+
if (monitor) clearInterval(monitor);
|
|
645
|
+
options.signal?.removeEventListener("abort", onAbort);
|
|
646
|
+
unregister?.();
|
|
647
|
+
};
|
|
648
|
+
const cancel = (signal) => {
|
|
649
|
+
if (termination) return termination;
|
|
650
|
+
if (released) return Promise.resolve();
|
|
651
|
+
clearDeadline();
|
|
652
|
+
cancelled = true;
|
|
653
|
+
termination = stopShellProcess(child, closed, signal).finally(release);
|
|
654
|
+
termination.catch(rejectCleanup);
|
|
655
|
+
return termination;
|
|
656
|
+
};
|
|
657
|
+
const onAbort = () => {
|
|
658
|
+
cancel(options.terminationSignal ?? "SIGTERM");
|
|
659
|
+
};
|
|
660
|
+
options.signal?.addEventListener("abort", onAbort, { once: true });
|
|
661
|
+
if (timeoutMs != null) deadline = setTimeout(() => {
|
|
662
|
+
timedOut = true;
|
|
663
|
+
cancel("SIGTERM");
|
|
664
|
+
}, timeoutMs);
|
|
665
|
+
unregister = options.registerOwner?.({
|
|
666
|
+
cancel,
|
|
667
|
+
release
|
|
668
|
+
});
|
|
669
|
+
if (unregister) child.once("close", () => {
|
|
670
|
+
if (released || termination) return;
|
|
671
|
+
const prune = () => {
|
|
672
|
+
if (!termination && !hasShellProcesses(child)) release();
|
|
673
|
+
};
|
|
674
|
+
monitor = setInterval(prune, 100);
|
|
675
|
+
monitor.unref();
|
|
676
|
+
prune();
|
|
677
|
+
});
|
|
678
|
+
return {
|
|
679
|
+
cancel,
|
|
680
|
+
timedOut: () => timedOut,
|
|
681
|
+
cancelled: () => cancelled,
|
|
682
|
+
cleanupFailure,
|
|
683
|
+
async dispose() {
|
|
684
|
+
clearDeadline();
|
|
685
|
+
try {
|
|
686
|
+
await termination;
|
|
687
|
+
} finally {
|
|
688
|
+
if (!unregister) release();
|
|
689
|
+
}
|
|
690
|
+
}
|
|
691
|
+
};
|
|
692
|
+
}
|
|
693
|
+
async function runShellAction(spec, options = {}) {
|
|
694
|
+
const { timedOut, ...result } = await runShellProcess(spec, options, "node");
|
|
695
|
+
const failure = rejectIfShellFailed(spec, result.args, result, timedOut, resolveShellActionTimeoutMs(spec.timeoutMs));
|
|
696
|
+
if (failure) throw failure;
|
|
697
|
+
return result;
|
|
698
|
+
}
|
|
699
|
+
async function runShellCommand(spec, options) {
|
|
700
|
+
return await runShellProcess(spec, options, "command");
|
|
701
|
+
}
|
|
702
|
+
async function runShellProcess(spec, options, mode) {
|
|
703
|
+
options.signal?.throwIfAborted();
|
|
704
|
+
const cwd = spec.cwd ?? process.cwd();
|
|
705
|
+
const args = spec.args ?? [];
|
|
706
|
+
const startMs = Date.now();
|
|
707
|
+
const timeoutMs = resolveShellActionTimeoutMs(spec.timeoutMs);
|
|
708
|
+
validateShellActionMaxBufferBytes(spec.maxBufferBytes);
|
|
709
|
+
if (spec.stdin !== void 0 && typeof spec.stdin !== "string") throw new TypeError("stdin must be a string");
|
|
710
|
+
const env = {
|
|
711
|
+
...process.env,
|
|
712
|
+
...spec.env
|
|
713
|
+
};
|
|
714
|
+
const child = spawn(spec.command, args, {
|
|
715
|
+
cwd,
|
|
716
|
+
env,
|
|
717
|
+
shell: spec.shell,
|
|
718
|
+
stdio: [
|
|
719
|
+
"pipe",
|
|
720
|
+
"pipe",
|
|
721
|
+
"pipe"
|
|
722
|
+
],
|
|
723
|
+
windowsHide: true,
|
|
724
|
+
detached: process.platform !== "win32"
|
|
725
|
+
});
|
|
726
|
+
const termination = createShellTermination(child, timeoutMs, options);
|
|
727
|
+
const finish = waitForShellResult(child, spec, args, cwd, startMs, termination, mode);
|
|
728
|
+
try {
|
|
729
|
+
writeShellStdin(child, spec.stdin);
|
|
730
|
+
const result = await Promise.race([finish, termination.cleanupFailure]);
|
|
731
|
+
throwIfShellCancelled(options.signal, mode);
|
|
732
|
+
return result;
|
|
733
|
+
} catch (error) {
|
|
734
|
+
await termination.cancel("SIGTERM");
|
|
735
|
+
throw describeShellSpawnError(spec, args, cwd, env, error);
|
|
736
|
+
} finally {
|
|
737
|
+
await termination.dispose();
|
|
738
|
+
}
|
|
739
|
+
}
|
|
740
|
+
function throwIfShellCancelled(signal, mode) {
|
|
741
|
+
if (!signal?.aborted) return;
|
|
742
|
+
const reason = signal.reason;
|
|
743
|
+
if (mode === "command" || reason instanceof TimeoutError || reason instanceof InterruptedError) throw reason;
|
|
744
|
+
}
|
|
745
|
+
// src/flows/graph.ts
|
|
746
|
+
function validateFlowDefinition(flow) {
|
|
747
|
+
assertValidFlowDefinitionShape(flow);
|
|
748
|
+
assertKnownFlowNode(flow, flow.startAt, "Flow start node is missing");
|
|
749
|
+
const outgoingEdges = /* @__PURE__ */ new Set();
|
|
750
|
+
for (const edge of flow.edges) validateFlowEdge(flow, edge, outgoingEdges);
|
|
751
|
+
}
|
|
752
|
+
function assertKnownFlowNode(flow, nodeId, description) {
|
|
753
|
+
if (!Object.hasOwn(flow.nodes, nodeId)) throw new Error(`${description}: ${nodeId}`);
|
|
754
|
+
}
|
|
755
|
+
function isDirectEdge(edge) {
|
|
756
|
+
return Object.hasOwn(edge, "to");
|
|
757
|
+
}
|
|
758
|
+
function validateFlowEdge(flow, edge, outgoingEdges) {
|
|
759
|
+
assertKnownFlowNode(flow, edge.from, "Flow edge references unknown from-node");
|
|
760
|
+
if (outgoingEdges.has(edge.from)) throw new Error(`Flow node must not declare multiple outgoing edges: ${edge.from}`);
|
|
761
|
+
outgoingEdges.add(edge.from);
|
|
762
|
+
if (isDirectEdge(edge)) {
|
|
763
|
+
assertKnownFlowNode(flow, edge.to, "Flow edge references unknown to-node");
|
|
764
|
+
return;
|
|
765
|
+
}
|
|
766
|
+
for (const target of Object.values(edge.switch.cases)) assertKnownFlowNode(flow, target, "Flow switch references unknown to-node");
|
|
767
|
+
}
|
|
768
|
+
function canFollowEdge(edge, result) {
|
|
769
|
+
return !result || result.outcome === "ok" || !isDirectEdge(edge) && edge.switch.on.startsWith("$result.");
|
|
770
|
+
}
|
|
771
|
+
function resolveNext(edges, from, output, result) {
|
|
772
|
+
const edge = edges.find((candidate) => candidate.from === from);
|
|
773
|
+
if (!edge || !canFollowEdge(edge, result)) return null;
|
|
774
|
+
if (isDirectEdge(edge)) return edge.to;
|
|
775
|
+
const value = getBySwitchPath(output, result, edge.switch.on);
|
|
776
|
+
if (typeof value !== "string" && typeof value !== "number" && typeof value !== "boolean") throw new Error(`Flow switch value must be scalar for ${edge.switch.on}`);
|
|
777
|
+
const key = String(value);
|
|
778
|
+
if (!Object.hasOwn(edge.switch.cases, key)) throw new Error(`No flow switch case for ${edge.switch.on}=${JSON.stringify(value)}`);
|
|
779
|
+
return edge.switch.cases[key];
|
|
780
|
+
}
|
|
781
|
+
function getBySwitchPath(output, result, jsonPath) {
|
|
782
|
+
if (jsonPath.startsWith("$result.")) return getByPath(result, `$.${jsonPath.slice(8)}`);
|
|
783
|
+
if (jsonPath.startsWith("$output.")) return getByPath(output, `$.${jsonPath.slice(8)}`);
|
|
784
|
+
return getByPath(output, jsonPath);
|
|
785
|
+
}
|
|
786
|
+
function getByPath(value, jsonPath) {
|
|
787
|
+
if (!jsonPath.startsWith("$.")) throw new Error(`Unsupported JSON path: ${jsonPath}`);
|
|
788
|
+
return jsonPath.slice(2).split(".").reduce((current, key) => {
|
|
789
|
+
if (current == null || typeof current !== "object") return;
|
|
790
|
+
return current[key];
|
|
791
|
+
}, value);
|
|
792
|
+
}
|
|
793
|
+
// src/flows/runtime-support.ts
|
|
794
|
+
function isoNow$1() {
|
|
795
|
+
return (/* @__PURE__ */ new Date()).toISOString();
|
|
796
|
+
}
|
|
797
|
+
function persistRunFailure(store, runDir, state, error) {
|
|
798
|
+
if (state.finishedAt !== void 0 && (state.status === "failed" || state.status === "timed_out")) return Promise.resolve();
|
|
799
|
+
state.status = error instanceof TimeoutError ? "timed_out" : "failed";
|
|
800
|
+
state.updatedAt = isoNow$1();
|
|
801
|
+
state.finishedAt = state.updatedAt;
|
|
802
|
+
state.error = error instanceof Error ? error.message : String(error);
|
|
803
|
+
state.statusDetail = state.currentNode ? `Failed in ${state.currentNode}: ${state.error}` : state.error;
|
|
804
|
+
return store.writeSnapshot(runDir, state, {
|
|
805
|
+
scope: "run",
|
|
806
|
+
type: "run_failed",
|
|
807
|
+
payload: {
|
|
808
|
+
status: state.status,
|
|
809
|
+
error: state.error
|
|
810
|
+
}
|
|
811
|
+
});
|
|
812
|
+
}
|
|
813
|
+
function makeFlowNodeContext(state, input, services) {
|
|
814
|
+
return {
|
|
815
|
+
input,
|
|
816
|
+
outputs: state.outputs,
|
|
817
|
+
results: state.results,
|
|
818
|
+
state,
|
|
819
|
+
services
|
|
820
|
+
};
|
|
821
|
+
}
|
|
822
|
+
function markNodeStarted(state, nodeId, attemptId, nodeType, startedAt, detail) {
|
|
823
|
+
state.status = "running";
|
|
824
|
+
state.waitingOn = void 0;
|
|
825
|
+
state.currentNode = nodeId;
|
|
826
|
+
state.currentAttemptId = attemptId;
|
|
827
|
+
state.currentNodeType = nodeType;
|
|
828
|
+
state.currentNodeStartedAt = startedAt;
|
|
829
|
+
state.lastHeartbeatAt = startedAt;
|
|
830
|
+
state.statusDetail = detail ?? `Running ${nodeType} node ${nodeId}`;
|
|
831
|
+
}
|
|
832
|
+
function clearActiveNode(state, detail) {
|
|
833
|
+
state.currentNode = void 0;
|
|
834
|
+
state.currentAttemptId = void 0;
|
|
835
|
+
state.currentNodeType = void 0;
|
|
836
|
+
state.currentNodeStartedAt = void 0;
|
|
837
|
+
state.lastHeartbeatAt = void 0;
|
|
838
|
+
state.statusDetail = detail;
|
|
839
|
+
}
|
|
840
|
+
function updateStatusDetail(state, detail) {
|
|
841
|
+
if (!detail) return;
|
|
842
|
+
state.statusDetail = detail;
|
|
843
|
+
}
|
|
844
|
+
async function finalizeStepTrace(store, runDir, state, nodeId, attemptId, output, baseTrace) {
|
|
845
|
+
const trace = baseTrace ? structuredClone(baseTrace) : {};
|
|
846
|
+
if (output !== void 0) {
|
|
847
|
+
const inlineOutput = toInlineOutput(output);
|
|
848
|
+
if (inlineOutput !== void 0) trace.outputInline = inlineOutput;
|
|
849
|
+
else trace.outputArtifact = await store.writeArtifact(runDir, state, output, {
|
|
850
|
+
mediaType: outputArtifactMediaType(output),
|
|
851
|
+
extension: outputArtifactExtension(output),
|
|
852
|
+
nodeId,
|
|
853
|
+
attemptId
|
|
854
|
+
});
|
|
855
|
+
}
|
|
856
|
+
return Object.keys(trace).length > 0 ? trace : null;
|
|
857
|
+
}
|
|
858
|
+
function normalizePromptInput(prompt) {
|
|
859
|
+
return typeof prompt === "string" ? textPrompt(prompt) : prompt;
|
|
860
|
+
}
|
|
861
|
+
async function resolveNodeCwd(defaultCwd, cwd, context) {
|
|
862
|
+
if (typeof cwd === "function") {
|
|
863
|
+
const resolved = await cwd(context) ?? defaultCwd;
|
|
864
|
+
return path.resolve(defaultCwd, resolved);
|
|
865
|
+
}
|
|
866
|
+
return path.resolve(defaultCwd, cwd ?? defaultCwd);
|
|
867
|
+
}
|
|
868
|
+
function resolveShellActionCwd(defaultCwd, cwd) {
|
|
869
|
+
return path.resolve(defaultCwd, cwd ?? defaultCwd);
|
|
870
|
+
}
|
|
871
|
+
function summarizePrompt(promptText, explicitDetail) {
|
|
872
|
+
if (explicitDetail) return explicitDetail;
|
|
873
|
+
const line = promptText.split("\n").map((candidate) => candidate.trim()).find((candidate) => candidate.length > 0);
|
|
874
|
+
if (!line) return "Running ACP prompt";
|
|
875
|
+
return `ACP: ${line.length > 120 ? `${line.slice(0, 117)}...` : line}`;
|
|
876
|
+
}
|
|
877
|
+
function createQuietCaptureOutput() {
|
|
878
|
+
const chunks = [];
|
|
879
|
+
let sessionId;
|
|
880
|
+
const formatter = createOutputFormatter("quiet", { stdout: { write(chunk) {
|
|
881
|
+
chunks.push(chunk);
|
|
882
|
+
} } });
|
|
883
|
+
const setContext = formatter.setContext.bind(formatter);
|
|
884
|
+
formatter.setContext = (context) => {
|
|
885
|
+
sessionId = context.sessionId ?? sessionId;
|
|
886
|
+
setContext(context);
|
|
887
|
+
};
|
|
888
|
+
return {
|
|
889
|
+
formatter,
|
|
890
|
+
read: () => chunks.join("").trim(),
|
|
891
|
+
sessionId: () => sessionId
|
|
892
|
+
};
|
|
893
|
+
}
|
|
894
|
+
async function resolveFlowRunTitle(flow, input, flowPath) {
|
|
895
|
+
const titleDefinition = flow.run?.title;
|
|
896
|
+
if (titleDefinition === void 0) return;
|
|
897
|
+
return normalizeFlowRunTitle(typeof titleDefinition === "function" ? await Promise.resolve(titleDefinition({
|
|
898
|
+
input,
|
|
899
|
+
flowName: flow.name,
|
|
900
|
+
flowPath
|
|
901
|
+
})) : titleDefinition);
|
|
902
|
+
}
|
|
903
|
+
function normalizeFlowRunTitle(value) {
|
|
904
|
+
const trimmed = value?.trim();
|
|
905
|
+
return trimmed ? trimmed : void 0;
|
|
906
|
+
}
|
|
907
|
+
function createRunId(flowName) {
|
|
908
|
+
return `${isoNow$1().replaceAll(":", "").replaceAll(".", "")}-${slugifyAsciiIdPart(flowName)}-${randomUUID().slice(0, 8)}`;
|
|
909
|
+
}
|
|
910
|
+
function createSessionBindingKey(agentCommand, cwd, handle, agentArgv) {
|
|
911
|
+
return JSON.stringify([
|
|
912
|
+
agentCommand,
|
|
913
|
+
agentArgv ?? null,
|
|
914
|
+
cwd,
|
|
915
|
+
handle
|
|
916
|
+
]);
|
|
917
|
+
}
|
|
918
|
+
function createSessionName(flowName, handle, cwd, runId) {
|
|
919
|
+
return `${flowName}-${handle}-${stableShortHash(cwd)}-${runId.slice(-8)}`;
|
|
920
|
+
}
|
|
921
|
+
function createSessionBundleId(handle, key) {
|
|
922
|
+
return `${slugifyAsciiIdPart(handle) || "session"}-${stableShortHash(key)}`;
|
|
923
|
+
}
|
|
924
|
+
function slugifyAsciiIdPart(value) {
|
|
925
|
+
let slug = "";
|
|
926
|
+
let lastWasSeparator = false;
|
|
927
|
+
for (const char of value) {
|
|
928
|
+
const safeChar = toLowerAsciiAlphaNumeric(char);
|
|
929
|
+
if (safeChar) {
|
|
930
|
+
slug += safeChar;
|
|
931
|
+
lastWasSeparator = false;
|
|
932
|
+
continue;
|
|
933
|
+
}
|
|
934
|
+
if (slug.length > 0 && !lastWasSeparator) {
|
|
935
|
+
slug += "-";
|
|
936
|
+
lastWasSeparator = true;
|
|
937
|
+
}
|
|
938
|
+
}
|
|
939
|
+
return lastWasSeparator ? slug.slice(0, -1) : slug;
|
|
940
|
+
}
|
|
941
|
+
function toLowerAsciiAlphaNumeric(char) {
|
|
942
|
+
const code = char.charCodeAt(0);
|
|
943
|
+
if (code >= 48 && code <= 57) return char;
|
|
944
|
+
if (code >= 65 && code <= 90) return String.fromCharCode(code + 32);
|
|
945
|
+
if (code >= 97 && code <= 122) return char;
|
|
946
|
+
return null;
|
|
947
|
+
}
|
|
948
|
+
function createIsolatedSessionBinding(flowName, runId, attemptId, profile, agent) {
|
|
949
|
+
const key = `isolated::${attemptId}`;
|
|
950
|
+
const handle = "isolated";
|
|
951
|
+
return {
|
|
952
|
+
key,
|
|
953
|
+
handle,
|
|
954
|
+
bundleId: createSessionBundleId(`${handle}-${attemptId}`, `${key}::${agent.cwd}`),
|
|
955
|
+
name: `${flowName}-${attemptId}-${runId.slice(-8)}`,
|
|
956
|
+
profile,
|
|
957
|
+
agentName: agent.agentName,
|
|
958
|
+
agentCommand: agent.agentCommand,
|
|
959
|
+
agentArgv: agent.agentArgv,
|
|
960
|
+
cwd: agent.cwd,
|
|
961
|
+
acpxRecordId: key,
|
|
962
|
+
acpSessionId: key
|
|
963
|
+
};
|
|
964
|
+
}
|
|
965
|
+
function createSyntheticSessionRecord(options) {
|
|
966
|
+
return {
|
|
967
|
+
schema: SESSION_RECORD_SCHEMA,
|
|
968
|
+
acpxRecordId: options.binding.acpxRecordId,
|
|
969
|
+
acpSessionId: options.binding.acpSessionId,
|
|
970
|
+
agentSessionId: options.binding.agentSessionId,
|
|
971
|
+
agentCommand: options.binding.agentCommand,
|
|
972
|
+
agentArgv: options.binding.agentArgv,
|
|
973
|
+
cwd: options.binding.cwd,
|
|
974
|
+
name: options.binding.name,
|
|
975
|
+
createdAt: options.createdAt,
|
|
976
|
+
lastUsedAt: options.updatedAt,
|
|
977
|
+
lastSeq: options.lastSeq,
|
|
978
|
+
lastRequestId: void 0,
|
|
979
|
+
eventLog: defaultSessionEventLog(options.binding.acpxRecordId),
|
|
980
|
+
closed: true,
|
|
981
|
+
closedAt: options.updatedAt,
|
|
982
|
+
title: options.conversation.title,
|
|
983
|
+
messages: options.conversation.messages,
|
|
984
|
+
updated_at: options.conversation.updated_at,
|
|
985
|
+
cumulative_token_usage: options.conversation.cumulative_token_usage,
|
|
986
|
+
cumulative_cost: options.conversation.cumulative_cost,
|
|
987
|
+
request_token_usage: options.conversation.request_token_usage,
|
|
988
|
+
acpx: options.acpxState
|
|
989
|
+
};
|
|
990
|
+
}
|
|
991
|
+
function createNodeResult(options) {
|
|
992
|
+
return {
|
|
993
|
+
attemptId: options.attemptId,
|
|
994
|
+
nodeId: options.nodeId,
|
|
995
|
+
nodeType: options.nodeType,
|
|
996
|
+
outcome: options.outcome,
|
|
997
|
+
startedAt: options.startedAt,
|
|
998
|
+
finishedAt: options.finishedAt,
|
|
999
|
+
durationMs: new Date(options.finishedAt).getTime() - new Date(options.startedAt).getTime(),
|
|
1000
|
+
output: options.output,
|
|
1001
|
+
error: options.error
|
|
1002
|
+
};
|
|
1003
|
+
}
|
|
1004
|
+
function outcomeForError(error) {
|
|
1005
|
+
if (error instanceof TimeoutError) return "timed_out";
|
|
1006
|
+
if (error instanceof InterruptedError) return "cancelled";
|
|
1007
|
+
return "failed";
|
|
1008
|
+
}
|
|
1009
|
+
function stableShortHash(value) {
|
|
1010
|
+
return createHash("sha1").update(value).digest("hex").slice(0, 8);
|
|
1011
|
+
}
|
|
1012
|
+
function nextAttemptId(attemptCounts, nodeId) {
|
|
1013
|
+
const next = (attemptCounts.get(nodeId) ?? 0) + 1;
|
|
1014
|
+
attemptCounts.set(nodeId, next);
|
|
1015
|
+
return `${nodeId}#${next}`;
|
|
1016
|
+
}
|
|
1017
|
+
function createNodeOutcomePayload(result, trace) {
|
|
1018
|
+
return {
|
|
1019
|
+
nodeType: result.nodeType,
|
|
1020
|
+
outcome: result.outcome,
|
|
1021
|
+
durationMs: result.durationMs,
|
|
1022
|
+
error: result.error ?? null,
|
|
1023
|
+
...trace
|
|
1024
|
+
};
|
|
1025
|
+
}
|
|
1026
|
+
function attachStepTrace(error, trace) {
|
|
1027
|
+
const attached = error instanceof Error ? error : new Error(typeof error === "string" ? error : String(error));
|
|
1028
|
+
attached.flowStepTrace = trace;
|
|
1029
|
+
return attached;
|
|
1030
|
+
}
|
|
1031
|
+
function extractAttachedStepTrace(error) {
|
|
1032
|
+
if (!(error instanceof Error)) return;
|
|
1033
|
+
return error.flowStepTrace;
|
|
1034
|
+
}
|
|
1035
|
+
function toInlineOutput(value) {
|
|
1036
|
+
if (value == null || typeof value === "number" || typeof value === "boolean") return value;
|
|
1037
|
+
if (typeof value === "string") return isInlineSerializableText(value) ? value : void 0;
|
|
1038
|
+
try {
|
|
1039
|
+
if (isInlineSerializableText(JSON.stringify(value))) return value;
|
|
1040
|
+
} catch {
|
|
1041
|
+
return;
|
|
1042
|
+
}
|
|
1043
|
+
}
|
|
1044
|
+
function isInlineSerializableText(value) {
|
|
1045
|
+
return value.length <= 200 && !value.includes("\n");
|
|
1046
|
+
}
|
|
1047
|
+
function outputArtifactMediaType(value) {
|
|
1048
|
+
return typeof value === "string" ? "text/plain" : "application/json";
|
|
1049
|
+
}
|
|
1050
|
+
function outputArtifactExtension(value) {
|
|
1051
|
+
return typeof value === "string" ? "txt" : "json";
|
|
1052
|
+
}
|
|
1053
|
+
function findConversationDeltaStart(before, after) {
|
|
1054
|
+
const maxOverlap = Math.min(before.length, after.length);
|
|
1055
|
+
for (let overlap = maxOverlap; overlap >= 0; overlap -= 1) {
|
|
1056
|
+
let matches = true;
|
|
1057
|
+
for (let index = 0; index < overlap; index += 1) {
|
|
1058
|
+
const beforeMessage = before[before.length - overlap + index];
|
|
1059
|
+
const afterMessage = after[index];
|
|
1060
|
+
if (!deepEqualJson(beforeMessage, afterMessage)) {
|
|
1061
|
+
matches = false;
|
|
1062
|
+
break;
|
|
1063
|
+
}
|
|
1064
|
+
}
|
|
1065
|
+
if (matches) return overlap;
|
|
1066
|
+
}
|
|
1067
|
+
return 0;
|
|
1068
|
+
}
|
|
1069
|
+
function deepEqualJson(left, right) {
|
|
1070
|
+
return JSON.stringify(left) === JSON.stringify(right);
|
|
1071
|
+
}
|
|
1072
|
+
// src/flows/session-settings.ts
|
|
1073
|
+
function assertCompatibleSessionSettings(node, binding) {
|
|
1074
|
+
const pinned = binding.requestedSettings ?? { configOptions: [] };
|
|
1075
|
+
if (node.modelId !== void 0 && node.modelId.trim() !== normalizedModel(pinned.model)) throw new Error(`Conflicting model for persistent session handle "${binding.handle}"`);
|
|
1076
|
+
const pinnedOptions = finalSelections(pinned.configOptions);
|
|
1077
|
+
for (const [configId, value] of finalSelections(node.configOptions ?? [])) if (pinnedOptions.get(configId) !== value) throw new Error(`Conflicting config option "${configId}" for persistent session handle "${binding.handle}"`);
|
|
1078
|
+
}
|
|
1079
|
+
function normalizedModel(model) {
|
|
1080
|
+
return model?.trim();
|
|
1081
|
+
}
|
|
1082
|
+
function finalSelections(selections) {
|
|
1083
|
+
return new Map(selections.map(({ configId, value }) => [configId, value]));
|
|
1084
|
+
}
|
|
1085
|
+
function assertReplayedSessionSettings(binding, configuration) {
|
|
1086
|
+
const accepted = binding.acceptedSettings ?? { configOptions: [] };
|
|
1087
|
+
if (!replayedModelMatches(accepted.model, configuration.model)) throw new Error(`Cannot replay pinned model for persistent session handle "${binding.handle}"`);
|
|
1088
|
+
const expected = new Map(accepted.configOptions.map(({ configId, acceptedValue }) => [configId, acceptedValue]));
|
|
1089
|
+
for (const [configId, acceptedValue] of new Map(configuration.configOptions.map((selection) => [selection.configId, selection.acceptedValue]))) if (expected.get(configId) !== acceptedValue) throw new Error(`Cannot replay pinned config option "${configId}" for persistent session handle "${binding.handle}"`);
|
|
1090
|
+
}
|
|
1091
|
+
function replayedModelMatches(expected, actual) {
|
|
1092
|
+
if (!expected?.applied) return true;
|
|
1093
|
+
return actual?.applied === true && actual.accepted === expected.accepted;
|
|
1094
|
+
}
|
|
1095
|
+
// src/flows/store.ts
|
|
1096
|
+
const FLOW_BUNDLE_SCHEMA = "acpx.flow-run-bundle.v1";
|
|
1097
|
+
const FLOW_TRACE_SCHEMA = "acpx.flow-trace-event.v1";
|
|
1098
|
+
const FLOW_SNAPSHOT_SCHEMA = "acpx.flow-definition-snapshot.v1";
|
|
1099
|
+
const MANIFEST_PATH = "manifest.json";
|
|
1100
|
+
const FLOW_SNAPSHOT_PATH = "flow.json";
|
|
1101
|
+
const TRACE_PATH = "trace.ndjson";
|
|
1102
|
+
const PROJECTIONS_DIR = "projections";
|
|
1103
|
+
const RUN_PROJECTION_PATH = "projections/run.json";
|
|
1104
|
+
const LIVE_PROJECTION_PATH = "projections/live.json";
|
|
1105
|
+
const STEPS_PROJECTION_PATH = "projections/steps.json";
|
|
1106
|
+
const SESSIONS_DIR = "sessions";
|
|
1107
|
+
const ARTIFACTS_DIR = "artifacts";
|
|
1108
|
+
function flowRunsBaseDir(homeDir = os.homedir()) {
|
|
1109
|
+
return path.join(homeDir, ".acpx", "flows", "runs");
|
|
1110
|
+
}
|
|
1111
|
+
var FlowRunStore = class {
|
|
1112
|
+
outputRoot;
|
|
1113
|
+
traceSeqByRun = /* @__PURE__ */ new Map();
|
|
1114
|
+
sessionSeqByBundle = /* @__PURE__ */ new Map();
|
|
1115
|
+
manifestByRun = /* @__PURE__ */ new Map();
|
|
1116
|
+
writeChainByPath = /* @__PURE__ */ new Map();
|
|
1117
|
+
constructor(outputRoot = flowRunsBaseDir()) {
|
|
1118
|
+
this.outputRoot = outputRoot;
|
|
1119
|
+
}
|
|
1120
|
+
releaseRun(runDir) {
|
|
1121
|
+
this.traceSeqByRun.delete(runDir);
|
|
1122
|
+
this.manifestByRun.delete(runDir);
|
|
1123
|
+
for (const key of this.sessionSeqByBundle.keys()) if (key.startsWith(`${runDir}::`)) this.sessionSeqByBundle.delete(key);
|
|
1124
|
+
}
|
|
1125
|
+
async createRunDir(runId) {
|
|
1126
|
+
const runDir = path.join(this.outputRoot, runId);
|
|
1127
|
+
await fs.mkdir(path.join(runDir, PROJECTIONS_DIR), {
|
|
1128
|
+
recursive: true,
|
|
1129
|
+
mode: 448
|
|
1130
|
+
});
|
|
1131
|
+
await fs.mkdir(path.join(runDir, SESSIONS_DIR), {
|
|
1132
|
+
recursive: true,
|
|
1133
|
+
mode: 448
|
|
1134
|
+
});
|
|
1135
|
+
await fs.mkdir(path.join(runDir, ARTIFACTS_DIR), {
|
|
1136
|
+
recursive: true,
|
|
1137
|
+
mode: 448
|
|
1138
|
+
});
|
|
1139
|
+
this.traceSeqByRun.set(runDir, 0);
|
|
1140
|
+
return runDir;
|
|
1141
|
+
}
|
|
1142
|
+
async initializeRunBundle(runDir, options) {
|
|
1143
|
+
const snapshot = createFlowDefinitionSnapshot(options.flow);
|
|
1144
|
+
const manifest = createRunManifest(options.state);
|
|
1145
|
+
this.manifestByRun.set(runDir, manifest);
|
|
1146
|
+
await writePrivateJsonFile(this.resolveRunPath(runDir, FLOW_SNAPSHOT_PATH), snapshot);
|
|
1147
|
+
await writePrivateJsonFile(this.resolveRunPath(runDir, MANIFEST_PATH), manifest);
|
|
1148
|
+
await writePrivateJsonFile(this.resolveRunPath(runDir, RUN_PROJECTION_PATH), options.state);
|
|
1149
|
+
await writePrivateJsonFile(this.resolveRunPath(runDir, LIVE_PROJECTION_PATH), createLiveState(options.state));
|
|
1150
|
+
await writePrivateJsonFile(this.resolveRunPath(runDir, STEPS_PROJECTION_PATH), options.state.steps);
|
|
1151
|
+
await ensureFile(this.resolveRunPath(runDir, TRACE_PATH));
|
|
1152
|
+
await this.appendTrace(runDir, options.state, {
|
|
1153
|
+
scope: "run",
|
|
1154
|
+
type: "run_started",
|
|
1155
|
+
payload: {
|
|
1156
|
+
flowName: options.state.flowName,
|
|
1157
|
+
...options.state.runTitle ? { runTitle: options.state.runTitle } : {},
|
|
1158
|
+
...options.state.flowPath ? { flowPath: options.state.flowPath } : {},
|
|
1159
|
+
...options.inputArtifact ? { inputArtifact: options.inputArtifact } : {}
|
|
1160
|
+
}
|
|
1161
|
+
});
|
|
1162
|
+
}
|
|
1163
|
+
async writeSnapshot(runDir, state, event) {
|
|
1164
|
+
state.updatedAt = isoNow();
|
|
1165
|
+
await writePrivateJsonFile(this.resolveRunPath(runDir, RUN_PROJECTION_PATH), state);
|
|
1166
|
+
await writePrivateJsonFile(this.resolveRunPath(runDir, LIVE_PROJECTION_PATH), createLiveState(state));
|
|
1167
|
+
await writePrivateJsonFile(this.resolveRunPath(runDir, STEPS_PROJECTION_PATH), state.steps);
|
|
1168
|
+
await this.writeManifest(runDir, state);
|
|
1169
|
+
await this.appendTrace(runDir, state, event);
|
|
1170
|
+
}
|
|
1171
|
+
async writeLive(runDir, state, event) {
|
|
1172
|
+
state.updatedAt = isoNow();
|
|
1173
|
+
await writePrivateJsonFile(this.resolveRunPath(runDir, LIVE_PROJECTION_PATH), createLiveState(state));
|
|
1174
|
+
await this.writeManifest(runDir, state);
|
|
1175
|
+
await this.appendTrace(runDir, state, event);
|
|
1176
|
+
}
|
|
1177
|
+
async appendTrace(runDir, state, event) {
|
|
1178
|
+
const traceEvent = {
|
|
1179
|
+
seq: this.nextTraceSeq(runDir),
|
|
1180
|
+
at: isoNow(),
|
|
1181
|
+
runId: state.runId,
|
|
1182
|
+
...event
|
|
1183
|
+
};
|
|
1184
|
+
await this.appendJsonLine(this.resolveRunPath(runDir, TRACE_PATH), traceEvent);
|
|
1185
|
+
return traceEvent;
|
|
1186
|
+
}
|
|
1187
|
+
async writeArtifact(runDir, state, content, options) {
|
|
1188
|
+
const buffer = toArtifactBuffer(content, options.mediaType);
|
|
1189
|
+
const sha256 = createHash("sha256").update(buffer).digest("hex");
|
|
1190
|
+
const relativePath = path.posix.join(ARTIFACTS_DIR, `sha256-${sha256}${normalizeArtifactExtension(options.extension)}`);
|
|
1191
|
+
const filePath = this.resolveRunPath(runDir, relativePath);
|
|
1192
|
+
try {
|
|
1193
|
+
await fs.access(filePath);
|
|
1194
|
+
} catch {
|
|
1195
|
+
await writePrivateFile(filePath, buffer);
|
|
1196
|
+
}
|
|
1197
|
+
const artifact = {
|
|
1198
|
+
path: relativePath,
|
|
1199
|
+
mediaType: options.mediaType,
|
|
1200
|
+
bytes: buffer.byteLength,
|
|
1201
|
+
sha256
|
|
1202
|
+
};
|
|
1203
|
+
if (options.emitTrace !== false) await this.appendTrace(runDir, state, {
|
|
1204
|
+
scope: "artifact",
|
|
1205
|
+
type: "artifact_written",
|
|
1206
|
+
nodeId: options.nodeId,
|
|
1207
|
+
attemptId: options.attemptId,
|
|
1208
|
+
sessionId: options.sessionId,
|
|
1209
|
+
artifact,
|
|
1210
|
+
payload: { artifact }
|
|
1211
|
+
});
|
|
1212
|
+
return artifact;
|
|
1213
|
+
}
|
|
1214
|
+
async ensureSessionBundle(runDir, state, inputBinding, record) {
|
|
1215
|
+
const binding = structuredClone(inputBinding);
|
|
1216
|
+
const sessionDir = this.resolveRunPath(runDir, sessionDirPath(binding.bundleId));
|
|
1217
|
+
await this.serializeWrite(path.join(sessionDir, "binding.json"), async () => {
|
|
1218
|
+
await fs.mkdir(sessionDir, {
|
|
1219
|
+
recursive: true,
|
|
1220
|
+
mode: 448
|
|
1221
|
+
});
|
|
1222
|
+
await writePrivateJsonFile(path.join(sessionDir, "binding.json"), binding);
|
|
1223
|
+
await ensureFile(path.join(sessionDir, "events.ndjson"));
|
|
1224
|
+
if (record) await this.writeSessionRecord(runDir, state, binding, record);
|
|
1225
|
+
const manifest = this.getManifest(runDir, state);
|
|
1226
|
+
if (!manifest.sessions.find((entry) => entry.id === binding.bundleId)) {
|
|
1227
|
+
const bindingArtifact = await this.writeArtifact(runDir, state, binding, {
|
|
1228
|
+
mediaType: "application/json",
|
|
1229
|
+
extension: "json",
|
|
1230
|
+
emitTrace: false
|
|
1231
|
+
});
|
|
1232
|
+
const entry = {
|
|
1233
|
+
id: binding.bundleId,
|
|
1234
|
+
handle: binding.handle,
|
|
1235
|
+
bindingPath: path.posix.join(sessionDirPath(binding.bundleId), "binding.json"),
|
|
1236
|
+
recordPath: path.posix.join(sessionDirPath(binding.bundleId), "record.json"),
|
|
1237
|
+
eventsPath: path.posix.join(sessionDirPath(binding.bundleId), "events.ndjson")
|
|
1238
|
+
};
|
|
1239
|
+
manifest.sessions.push(entry);
|
|
1240
|
+
await writePrivateJsonFile(this.resolveRunPath(runDir, MANIFEST_PATH), manifest);
|
|
1241
|
+
await this.appendTrace(runDir, state, {
|
|
1242
|
+
scope: "session",
|
|
1243
|
+
type: "session_bound",
|
|
1244
|
+
sessionId: binding.bundleId,
|
|
1245
|
+
payload: {
|
|
1246
|
+
sessionId: binding.bundleId,
|
|
1247
|
+
handle: binding.handle,
|
|
1248
|
+
bindingArtifact
|
|
1249
|
+
}
|
|
1250
|
+
});
|
|
1251
|
+
}
|
|
1252
|
+
});
|
|
1253
|
+
}
|
|
1254
|
+
async writeSessionRecord(runDir, _state, binding, record) {
|
|
1255
|
+
const bundledRecord = createBundledSessionRecord(binding, record, this.sessionSeqByBundle.get(`${runDir}::${binding.bundleId}`)?.persisted ?? 0);
|
|
1256
|
+
await writePrivateJsonFile(this.resolveRunPath(runDir, path.posix.join(sessionDirPath(binding.bundleId), "record.json")), bundledRecord);
|
|
1257
|
+
}
|
|
1258
|
+
async appendSessionEvent(runDir, binding, direction, message) {
|
|
1259
|
+
const sessionKey = `${runDir}::${binding.bundleId}`;
|
|
1260
|
+
const sequence = this.sessionSeqByBundle.get(sessionKey) ?? {
|
|
1261
|
+
allocated: 0,
|
|
1262
|
+
persisted: 0
|
|
1263
|
+
};
|
|
1264
|
+
this.sessionSeqByBundle.set(sessionKey, sequence);
|
|
1265
|
+
const seq = ++sequence.allocated;
|
|
1266
|
+
await this.appendJsonLine(this.resolveRunPath(runDir, path.posix.join(sessionDirPath(binding.bundleId), "events.ndjson")), {
|
|
1267
|
+
seq,
|
|
1268
|
+
at: isoNow(),
|
|
1269
|
+
direction,
|
|
1270
|
+
message
|
|
1271
|
+
});
|
|
1272
|
+
sequence.persisted = Math.max(sequence.persisted, seq);
|
|
1273
|
+
return seq;
|
|
1274
|
+
}
|
|
1275
|
+
getManifest(runDir, state) {
|
|
1276
|
+
const existing = this.manifestByRun.get(runDir);
|
|
1277
|
+
if (existing) {
|
|
1278
|
+
existing.startedAt = state.startedAt;
|
|
1279
|
+
existing.finishedAt = state.finishedAt;
|
|
1280
|
+
existing.status = state.status;
|
|
1281
|
+
existing.flowPath = state.flowPath;
|
|
1282
|
+
existing.flowName = state.flowName;
|
|
1283
|
+
existing.runTitle = state.runTitle;
|
|
1284
|
+
return existing;
|
|
1285
|
+
}
|
|
1286
|
+
const created = createRunManifest(state);
|
|
1287
|
+
this.manifestByRun.set(runDir, created);
|
|
1288
|
+
return created;
|
|
1289
|
+
}
|
|
1290
|
+
async writeManifest(runDir, state) {
|
|
1291
|
+
const manifest = this.getManifest(runDir, state);
|
|
1292
|
+
await writePrivateJsonFile(this.resolveRunPath(runDir, MANIFEST_PATH), manifest);
|
|
1293
|
+
}
|
|
1294
|
+
nextTraceSeq(runDir) {
|
|
1295
|
+
const next = (this.traceSeqByRun.get(runDir) ?? 0) + 1;
|
|
1296
|
+
this.traceSeqByRun.set(runDir, next);
|
|
1297
|
+
return next;
|
|
1298
|
+
}
|
|
1299
|
+
resolveRunPath(runDir, relativePath) {
|
|
1300
|
+
return path.join(runDir, ...relativePath.split("/"));
|
|
1301
|
+
}
|
|
1302
|
+
async appendJsonLine(filePath, value) {
|
|
1303
|
+
await this.serializeWrite(filePath, async () => {
|
|
1304
|
+
await fs.mkdir(path.dirname(filePath), {
|
|
1305
|
+
recursive: true,
|
|
1306
|
+
mode: 448
|
|
1307
|
+
});
|
|
1308
|
+
await appendRegularFile({
|
|
1309
|
+
filePath,
|
|
1310
|
+
content: `${JSON.stringify(value)}\n`,
|
|
1311
|
+
mode: 384
|
|
1312
|
+
});
|
|
1313
|
+
});
|
|
1314
|
+
}
|
|
1315
|
+
async serializeWrite(filePath, write) {
|
|
1316
|
+
const tracked = (this.writeChainByPath.get(filePath) ?? Promise.resolve()).then(write).finally(() => {
|
|
1317
|
+
if (this.writeChainByPath.get(filePath) === tracked) this.writeChainByPath.delete(filePath);
|
|
1318
|
+
});
|
|
1319
|
+
this.writeChainByPath.set(filePath, tracked);
|
|
1320
|
+
await tracked;
|
|
1321
|
+
}
|
|
1322
|
+
};
|
|
1323
|
+
function createRunManifest(state) {
|
|
1324
|
+
return {
|
|
1325
|
+
schema: FLOW_BUNDLE_SCHEMA,
|
|
1326
|
+
runId: state.runId,
|
|
1327
|
+
flowName: state.flowName,
|
|
1328
|
+
runTitle: state.runTitle,
|
|
1329
|
+
flowPath: state.flowPath,
|
|
1330
|
+
startedAt: state.startedAt,
|
|
1331
|
+
finishedAt: state.finishedAt,
|
|
1332
|
+
status: state.status,
|
|
1333
|
+
traceSchema: FLOW_TRACE_SCHEMA,
|
|
1334
|
+
paths: {
|
|
1335
|
+
flow: FLOW_SNAPSHOT_PATH,
|
|
1336
|
+
trace: TRACE_PATH,
|
|
1337
|
+
runProjection: RUN_PROJECTION_PATH,
|
|
1338
|
+
liveProjection: LIVE_PROJECTION_PATH,
|
|
1339
|
+
stepsProjection: STEPS_PROJECTION_PATH,
|
|
1340
|
+
sessionsDir: SESSIONS_DIR,
|
|
1341
|
+
artifactsDir: ARTIFACTS_DIR
|
|
1342
|
+
},
|
|
1343
|
+
sessions: []
|
|
1344
|
+
};
|
|
1345
|
+
}
|
|
1346
|
+
function createLiveState(state) {
|
|
1347
|
+
return {
|
|
1348
|
+
runId: state.runId,
|
|
1349
|
+
flowName: state.flowName,
|
|
1350
|
+
runTitle: state.runTitle,
|
|
1351
|
+
flowPath: state.flowPath,
|
|
1352
|
+
startedAt: state.startedAt,
|
|
1353
|
+
finishedAt: state.finishedAt,
|
|
1354
|
+
updatedAt: state.updatedAt,
|
|
1355
|
+
status: state.status,
|
|
1356
|
+
currentNode: state.currentNode,
|
|
1357
|
+
currentAttemptId: state.currentAttemptId,
|
|
1358
|
+
currentNodeType: state.currentNodeType,
|
|
1359
|
+
currentNodeStartedAt: state.currentNodeStartedAt,
|
|
1360
|
+
lastHeartbeatAt: state.lastHeartbeatAt,
|
|
1361
|
+
statusDetail: state.statusDetail,
|
|
1362
|
+
waitingOn: state.waitingOn,
|
|
1363
|
+
error: state.error,
|
|
1364
|
+
sessionBindings: state.sessionBindings
|
|
1365
|
+
};
|
|
1366
|
+
}
|
|
1367
|
+
function createFlowDefinitionSnapshot(flow) {
|
|
1368
|
+
return {
|
|
1369
|
+
schema: FLOW_SNAPSHOT_SCHEMA,
|
|
1370
|
+
name: flow.name,
|
|
1371
|
+
...flow.run?.title !== void 0 ? { run: { hasTitle: true } } : {},
|
|
1372
|
+
...flow.permissions ? { permissions: structuredClone(flow.permissions) } : {},
|
|
1373
|
+
startAt: flow.startAt,
|
|
1374
|
+
nodes: Object.fromEntries(Object.entries(flow.nodes).map(([nodeId, node]) => [nodeId, snapshotNode(node)])),
|
|
1375
|
+
edges: structuredClone(flow.edges)
|
|
1376
|
+
};
|
|
1377
|
+
}
|
|
1378
|
+
function snapshotNode(node) {
|
|
1379
|
+
const common = snapshotCommonNodeFields(node);
|
|
1380
|
+
switch (node.nodeType) {
|
|
1381
|
+
case "acp": return snapshotAcpNode(node, common);
|
|
1382
|
+
case "compute": return {
|
|
1383
|
+
...common,
|
|
1384
|
+
hasRun: true
|
|
1385
|
+
};
|
|
1386
|
+
case "action": {
|
|
1387
|
+
const actionExecution = "exec" in node ? "shell" : "function";
|
|
1388
|
+
return {
|
|
1389
|
+
...common,
|
|
1390
|
+
actionExecution,
|
|
1391
|
+
hasRun: "run" in node,
|
|
1392
|
+
hasExec: "exec" in node,
|
|
1393
|
+
hasParse: "parse" in node && typeof node.parse === "function"
|
|
1394
|
+
};
|
|
1395
|
+
}
|
|
1396
|
+
case "checkpoint": return {
|
|
1397
|
+
...common,
|
|
1398
|
+
...node.summary ? { summary: node.summary } : {},
|
|
1399
|
+
hasRun: typeof node.run === "function"
|
|
1400
|
+
};
|
|
1401
|
+
}
|
|
1402
|
+
throw new Error(`Unsupported flow node type: ${String(node)}`);
|
|
1403
|
+
}
|
|
1404
|
+
function snapshotCommonNodeFields(node) {
|
|
1405
|
+
return {
|
|
1406
|
+
nodeType: node.nodeType,
|
|
1407
|
+
...node.timeoutMs !== void 0 ? { timeoutMs: node.timeoutMs } : {},
|
|
1408
|
+
...node.heartbeatMs !== void 0 ? { heartbeatMs: node.heartbeatMs } : {},
|
|
1409
|
+
...node.statusDetail ? { statusDetail: node.statusDetail } : {}
|
|
1410
|
+
};
|
|
1411
|
+
}
|
|
1412
|
+
function snapshotAcpNode(node, common) {
|
|
1413
|
+
return {
|
|
1414
|
+
...common,
|
|
1415
|
+
...node.profile ? { profile: node.profile } : {},
|
|
1416
|
+
...node.modelId === void 0 ? {} : { modelId: node.modelId },
|
|
1417
|
+
...node.configOptions === void 0 ? {} : { configOptions: node.configOptions.map((selection) => ({ ...selection })) },
|
|
1418
|
+
session: {
|
|
1419
|
+
...node.session?.handle ? { handle: node.session.handle } : {},
|
|
1420
|
+
...node.session?.isolated ? { isolated: true } : {}
|
|
1421
|
+
},
|
|
1422
|
+
cwd: snapshotCwd(node.cwd),
|
|
1423
|
+
hasPrompt: true,
|
|
1424
|
+
hasParse: typeof node.parse === "function"
|
|
1425
|
+
};
|
|
1426
|
+
}
|
|
1427
|
+
function snapshotCwd(cwd) {
|
|
1428
|
+
if (typeof cwd === "function") return { mode: "dynamic" };
|
|
1429
|
+
if (typeof cwd === "string") return {
|
|
1430
|
+
mode: "static",
|
|
1431
|
+
value: cwd
|
|
1432
|
+
};
|
|
1433
|
+
return { mode: "default" };
|
|
1434
|
+
}
|
|
1435
|
+
function createBundledSessionRecord(binding, record, bundleLastSeq) {
|
|
1436
|
+
return {
|
|
1437
|
+
...structuredClone(record),
|
|
1438
|
+
lastSeq: bundleLastSeq,
|
|
1439
|
+
eventLog: {
|
|
1440
|
+
...structuredClone(record.eventLog),
|
|
1441
|
+
active_path: path.posix.join(sessionDirPath(binding.bundleId), "events.ndjson"),
|
|
1442
|
+
segment_count: 1,
|
|
1443
|
+
max_segments: 1
|
|
1444
|
+
}
|
|
1445
|
+
};
|
|
1446
|
+
}
|
|
1447
|
+
async function ensureFile(filePath) {
|
|
1448
|
+
await appendRegularFile({
|
|
1449
|
+
filePath,
|
|
1450
|
+
content: "",
|
|
1451
|
+
mode: 384
|
|
1452
|
+
});
|
|
1453
|
+
}
|
|
1454
|
+
function toArtifactBuffer(content, mediaType) {
|
|
1455
|
+
if (typeof content === "string") return Buffer.from(content, "utf8");
|
|
1456
|
+
if (Buffer.isBuffer(content)) return content;
|
|
1457
|
+
if (content instanceof Uint8Array) return Buffer.from(content);
|
|
1458
|
+
if (mediaType === "application/json") return Buffer.from(`${JSON.stringify(content, null, 2)}\n`, "utf8");
|
|
1459
|
+
return Buffer.from(String(content), "utf8");
|
|
1460
|
+
}
|
|
1461
|
+
function normalizeArtifactExtension(extension) {
|
|
1462
|
+
if (!extension) return "";
|
|
1463
|
+
return extension.startsWith(".") ? extension : `.${extension}`;
|
|
1464
|
+
}
|
|
1465
|
+
function sessionDirPath(bundleId) {
|
|
1466
|
+
return path.posix.join(SESSIONS_DIR, bundleId);
|
|
1467
|
+
}
|
|
1468
|
+
function isoNow() {
|
|
1469
|
+
return (/* @__PURE__ */ new Date()).toISOString();
|
|
1470
|
+
}
|
|
1471
|
+
// src/flows/runtime.ts
|
|
1472
|
+
const DEFAULT_FLOW_HEARTBEAT_MS = 5e3;
|
|
1473
|
+
const DEFAULT_FLOW_STEP_TIMEOUT_MS = 9e5;
|
|
1474
|
+
function setNodeValue(values, nodeId, value) {
|
|
1475
|
+
Object.defineProperty(values, nodeId, {
|
|
1476
|
+
value,
|
|
1477
|
+
enumerable: true,
|
|
1478
|
+
configurable: true,
|
|
1479
|
+
writable: true
|
|
1480
|
+
});
|
|
1481
|
+
}
|
|
1482
|
+
var FlowRunner = class {
|
|
1483
|
+
resolveAgent;
|
|
1484
|
+
defaultCwd;
|
|
1485
|
+
connectionOptions;
|
|
1486
|
+
defaultNodeTimeoutMs;
|
|
1487
|
+
suppressSdkConsoleErrors;
|
|
1488
|
+
sessionOptions;
|
|
1489
|
+
configOptions;
|
|
1490
|
+
services;
|
|
1491
|
+
store;
|
|
1492
|
+
pendingPersistentSessionClients = /* @__PURE__ */ new Map();
|
|
1493
|
+
attempts = /* @__PURE__ */ new Map();
|
|
1494
|
+
pendingClientReleases = /* @__PURE__ */ new WeakMap();
|
|
1495
|
+
runInterruptions = /* @__PURE__ */ new Map();
|
|
1496
|
+
shellOwners = /* @__PURE__ */ new Map();
|
|
1497
|
+
constructor(options) {
|
|
1498
|
+
this.resolveAgent = options.resolveAgent;
|
|
1499
|
+
this.defaultCwd = options.resolveAgent(void 0).cwd;
|
|
1500
|
+
this.connectionOptions = {
|
|
1501
|
+
permissionMode: options.permissionMode,
|
|
1502
|
+
mcpServers: options.mcpServers,
|
|
1503
|
+
nonInteractivePermissions: options.nonInteractivePermissions,
|
|
1504
|
+
permissionPolicy: options.permissionPolicy,
|
|
1505
|
+
authCredentials: options.authCredentials,
|
|
1506
|
+
authPolicy: options.authPolicy,
|
|
1507
|
+
fs: options.fs,
|
|
1508
|
+
verbose: options.verbose
|
|
1509
|
+
};
|
|
1510
|
+
this.defaultNodeTimeoutMs = options.defaultNodeTimeoutMs ?? options.timeoutMs ?? DEFAULT_FLOW_STEP_TIMEOUT_MS;
|
|
1511
|
+
this.suppressSdkConsoleErrors = options.suppressSdkConsoleErrors;
|
|
1512
|
+
this.sessionOptions = options.sessionOptions;
|
|
1513
|
+
this.configOptions = options.configOptions ?? [];
|
|
1514
|
+
this.services = options.services ?? {};
|
|
1515
|
+
this.store = new FlowRunStore(options.outputRoot);
|
|
1516
|
+
}
|
|
1517
|
+
async run(flow, input, options = {}) {
|
|
1518
|
+
validateFlowDefinition(flow);
|
|
1519
|
+
const runId = createRunId(flow.name);
|
|
1520
|
+
const runTitle = await resolveFlowRunTitle(flow, input, options.flowPath);
|
|
1521
|
+
const runDir = await this.store.createRunDir(runId);
|
|
1522
|
+
const state = {
|
|
1523
|
+
runId,
|
|
1524
|
+
flowName: flow.name,
|
|
1525
|
+
runTitle,
|
|
1526
|
+
flowPath: options.flowPath,
|
|
1527
|
+
startedAt: isoNow$1(),
|
|
1528
|
+
updatedAt: isoNow$1(),
|
|
1529
|
+
status: "running",
|
|
1530
|
+
input,
|
|
1531
|
+
outputs: {},
|
|
1532
|
+
results: {},
|
|
1533
|
+
steps: [],
|
|
1534
|
+
sessionBindings: {}
|
|
1535
|
+
};
|
|
1536
|
+
try {
|
|
1537
|
+
const inputArtifact = await this.store.writeArtifact(runDir, state, input, {
|
|
1538
|
+
mediaType: "application/json",
|
|
1539
|
+
extension: "json",
|
|
1540
|
+
emitTrace: false
|
|
1541
|
+
});
|
|
1542
|
+
await this.store.initializeRunBundle(runDir, {
|
|
1543
|
+
flow,
|
|
1544
|
+
state,
|
|
1545
|
+
inputArtifact
|
|
1546
|
+
});
|
|
1547
|
+
return await this.runWithOwnership(flow, input, runDir, state);
|
|
1548
|
+
} finally {
|
|
1549
|
+
try {
|
|
1550
|
+
await this.closePendingPersistentSessionClients(runDir);
|
|
1551
|
+
} finally {
|
|
1552
|
+
this.store.releaseRun(runDir);
|
|
1553
|
+
}
|
|
1554
|
+
}
|
|
1555
|
+
}
|
|
1556
|
+
async runWithOwnership(flow, input, runDir, state) {
|
|
1557
|
+
let execution;
|
|
1558
|
+
let cancellation;
|
|
1559
|
+
let interruption;
|
|
1560
|
+
const result = await withInterrupt(() => {
|
|
1561
|
+
execution = this.executeFlowRun(flow, input, runDir, state);
|
|
1562
|
+
return execution;
|
|
1563
|
+
}, async (signal) => {
|
|
1564
|
+
const reason = interruption ?? new InterruptedError();
|
|
1565
|
+
interruption = reason;
|
|
1566
|
+
this.runInterruptions.set(runDir, reason);
|
|
1567
|
+
cancellation ??= this.cancelShellOwners(runDir, signal);
|
|
1568
|
+
cancellation.catch(() => {});
|
|
1569
|
+
this.attempts.get(runDir)?.cancel(reason, signal);
|
|
1570
|
+
await execution?.catch(() => {});
|
|
1571
|
+
}).then((value) => ({
|
|
1572
|
+
ok: true,
|
|
1573
|
+
value
|
|
1574
|
+
}), (error) => ({
|
|
1575
|
+
ok: false,
|
|
1576
|
+
error
|
|
1577
|
+
}));
|
|
1578
|
+
try {
|
|
1579
|
+
try {
|
|
1580
|
+
await cancellation;
|
|
1581
|
+
} catch (cleanupError) {
|
|
1582
|
+
const failure = result.ok || result.error === cleanupError ? cleanupError : new AggregateError([result.error, cleanupError], "Shell cleanup failed during interruption", { cause: cleanupError });
|
|
1583
|
+
await persistRunFailure(this.store, runDir, state, failure);
|
|
1584
|
+
throw failure;
|
|
1585
|
+
}
|
|
1586
|
+
if (result.ok && !interruption) return result.value;
|
|
1587
|
+
const failure = result.ok ? interruption : result.error;
|
|
1588
|
+
if (interruption) await persistRunFailure(this.store, runDir, state, failure);
|
|
1589
|
+
throw failure;
|
|
1590
|
+
} finally {
|
|
1591
|
+
this.releaseShellOwners(runDir);
|
|
1592
|
+
}
|
|
1593
|
+
}
|
|
1594
|
+
registerShellOwner(runDir, owner) {
|
|
1595
|
+
let owners = this.shellOwners.get(runDir);
|
|
1596
|
+
if (!owners) {
|
|
1597
|
+
owners = /* @__PURE__ */ new Set();
|
|
1598
|
+
this.shellOwners.set(runDir, owners);
|
|
1599
|
+
}
|
|
1600
|
+
owners.add(owner);
|
|
1601
|
+
const registered = owners;
|
|
1602
|
+
return () => {
|
|
1603
|
+
registered.delete(owner);
|
|
1604
|
+
if (registered.size === 0) this.shellOwners.delete(runDir);
|
|
1605
|
+
};
|
|
1606
|
+
}
|
|
1607
|
+
async cancelShellOwners(runDir, signal) {
|
|
1608
|
+
const owners = [...this.shellOwners.get(runDir) ?? []];
|
|
1609
|
+
const results = await Promise.allSettled(owners.map((owner) => owner.cancel(signal)));
|
|
1610
|
+
const errors = [];
|
|
1611
|
+
for (const result of results) if (result.status === "rejected") errors.push(result.reason);
|
|
1612
|
+
if (errors.length > 0) throw new AggregateError(errors, "Shell process cleanup failed", { cause: errors[0] });
|
|
1613
|
+
}
|
|
1614
|
+
releaseShellOwners(runDir) {
|
|
1615
|
+
for (const owner of this.shellOwners.get(runDir) ?? []) owner.release();
|
|
1616
|
+
this.shellOwners.delete(runDir);
|
|
1617
|
+
}
|
|
1618
|
+
async executeFlowRun(flow, input, runDir, state) {
|
|
1619
|
+
let current = flow.startAt;
|
|
1620
|
+
const attemptCounts = /* @__PURE__ */ new Map();
|
|
1621
|
+
try {
|
|
1622
|
+
while (current !== null) {
|
|
1623
|
+
this.throwIfRunInterrupted(runDir);
|
|
1624
|
+
const step = await this.executeFlowStep(flow, input, runDir, state, current, attemptCounts);
|
|
1625
|
+
this.throwIfRunInterrupted(runDir, step.executionError);
|
|
1626
|
+
const waiting = await this.maybeCompleteCheckpointStep(runDir, state, step);
|
|
1627
|
+
if (waiting) return waiting;
|
|
1628
|
+
await this.recordFlowStepOutcome(runDir, state, step);
|
|
1629
|
+
current = this.resolveNextNode(flow, step);
|
|
1630
|
+
}
|
|
1631
|
+
return await this.completeFlowRun(runDir, state);
|
|
1632
|
+
} catch (error) {
|
|
1633
|
+
if (!this.runInterruptions.has(runDir)) await persistRunFailure(this.store, runDir, state, error);
|
|
1634
|
+
throw error;
|
|
1635
|
+
} finally {
|
|
1636
|
+
this.runInterruptions.delete(runDir);
|
|
1637
|
+
}
|
|
1638
|
+
}
|
|
1639
|
+
throwIfRunInterrupted(runDir, error) {
|
|
1640
|
+
const interrupted = this.runInterruptions.get(runDir);
|
|
1641
|
+
if (interrupted) throw error ?? interrupted;
|
|
1642
|
+
}
|
|
1643
|
+
async executeFlowStep(flow, input, runDir, state, nodeId, attemptCounts) {
|
|
1644
|
+
if (!Object.hasOwn(flow.nodes, nodeId)) throw new Error(`Unknown flow node: ${nodeId}`);
|
|
1645
|
+
const node = flow.nodes[nodeId];
|
|
1646
|
+
const attemptId = nextAttemptId(attemptCounts, nodeId);
|
|
1647
|
+
const startedAt = isoNow$1();
|
|
1648
|
+
markNodeStarted(state, nodeId, attemptId, node.nodeType, startedAt, node.statusDetail);
|
|
1649
|
+
const attempt = new FlowAttempt({
|
|
1650
|
+
nodeId,
|
|
1651
|
+
attemptId,
|
|
1652
|
+
startedAt,
|
|
1653
|
+
timeoutMs: node.timeoutMs ?? this.defaultNodeTimeoutMs
|
|
1654
|
+
});
|
|
1655
|
+
this.attempts.set(runDir, attempt);
|
|
1656
|
+
const context = this.makeAttemptContext(runDir, state, input, node, attempt);
|
|
1657
|
+
let stopHeartbeat = () => {};
|
|
1658
|
+
let executed;
|
|
1659
|
+
let outcome = "ok";
|
|
1660
|
+
let executionError;
|
|
1661
|
+
try {
|
|
1662
|
+
this.throwIfRunInterrupted(runDir);
|
|
1663
|
+
executed = await attempt.run(async () => {
|
|
1664
|
+
await attempt.own(() => this.writeNodeStartedSnapshot(runDir, state, nodeId, attemptId, node));
|
|
1665
|
+
stopHeartbeat = this.startHeartbeat(runDir, state, node, attempt);
|
|
1666
|
+
const result = await this.executeNode(runDir, state, flow, nodeId, node, context);
|
|
1667
|
+
result.trace = await attempt.own(() => finalizeStepTrace(this.store, runDir, state, nodeId, attemptId, result.output, result.trace));
|
|
1668
|
+
return result;
|
|
1669
|
+
});
|
|
1670
|
+
this.throwIfRunInterrupted(runDir);
|
|
1671
|
+
} catch (error) {
|
|
1672
|
+
outcome = outcomeForError(error);
|
|
1673
|
+
executionError = error;
|
|
1674
|
+
executed = {
|
|
1675
|
+
output: void 0,
|
|
1676
|
+
promptText: null,
|
|
1677
|
+
rawText: null,
|
|
1678
|
+
sessionInfo: null,
|
|
1679
|
+
agentInfo: null,
|
|
1680
|
+
...context.acpResult,
|
|
1681
|
+
trace: await finalizeStepTrace(this.store, runDir, state, nodeId, attemptId, void 0, context.acpResult ? context.acpResult.trace : extractAttachedStepTrace(error) ?? null)
|
|
1682
|
+
};
|
|
1683
|
+
} finally {
|
|
1684
|
+
stopHeartbeat();
|
|
1685
|
+
this.attempts.delete(runDir);
|
|
1686
|
+
}
|
|
1687
|
+
const nodeResult = createNodeResult({
|
|
1688
|
+
attemptId,
|
|
1689
|
+
nodeId,
|
|
1690
|
+
nodeType: node.nodeType,
|
|
1691
|
+
outcome,
|
|
1692
|
+
startedAt,
|
|
1693
|
+
finishedAt: isoNow$1(),
|
|
1694
|
+
...outcome === "ok" ? { output: executed.output } : { error: executionError instanceof Error ? executionError.message : String(executionError) }
|
|
1695
|
+
});
|
|
1696
|
+
setNodeValue(state.results, nodeId, nodeResult);
|
|
1697
|
+
return {
|
|
1698
|
+
...executed,
|
|
1699
|
+
nodeResult,
|
|
1700
|
+
executionError,
|
|
1701
|
+
attemptId,
|
|
1702
|
+
nodeId,
|
|
1703
|
+
node,
|
|
1704
|
+
startedAt,
|
|
1705
|
+
state
|
|
1706
|
+
};
|
|
1707
|
+
}
|
|
1708
|
+
makeAttemptContext(runDir, state, input, node, attempt) {
|
|
1709
|
+
const context = {
|
|
1710
|
+
nodeContext: {
|
|
1711
|
+
...makeFlowNodeContext(state, input, this.services),
|
|
1712
|
+
signal: attempt.signal
|
|
1713
|
+
},
|
|
1714
|
+
attempt
|
|
1715
|
+
};
|
|
1716
|
+
if (node.nodeType === "action" && "run" in node) context.nodeContext.runShell = (execution) => this.runCallbackShell(runDir, attempt, execution);
|
|
1717
|
+
return context;
|
|
1718
|
+
}
|
|
1719
|
+
async writeNodeStartedSnapshot(runDir, state, nodeId, attemptId, node) {
|
|
1720
|
+
await this.store.writeSnapshot(runDir, state, {
|
|
1721
|
+
scope: "node",
|
|
1722
|
+
type: "node_started",
|
|
1723
|
+
nodeId,
|
|
1724
|
+
attemptId,
|
|
1725
|
+
payload: {
|
|
1726
|
+
nodeType: node.nodeType,
|
|
1727
|
+
timeoutMs: node.timeoutMs ?? this.defaultNodeTimeoutMs,
|
|
1728
|
+
...state.statusDetail ? { statusDetail: state.statusDetail } : {}
|
|
1729
|
+
}
|
|
1730
|
+
});
|
|
1731
|
+
}
|
|
1732
|
+
async maybeCompleteCheckpointStep(runDir, state, step) {
|
|
1733
|
+
if (step.nodeResult.outcome !== "ok" || step.node.nodeType !== "checkpoint") return;
|
|
1734
|
+
setNodeValue(state.outputs, step.nodeId, step.output);
|
|
1735
|
+
state.waitingOn = step.nodeId;
|
|
1736
|
+
state.updatedAt = isoNow$1();
|
|
1737
|
+
state.status = "waiting";
|
|
1738
|
+
await this.recordFlowStepOutcome(runDir, state, step, { statusDetail: step.output?.summary ?? step.nodeId });
|
|
1739
|
+
return {
|
|
1740
|
+
runDir,
|
|
1741
|
+
state
|
|
1742
|
+
};
|
|
1743
|
+
}
|
|
1744
|
+
resolveNextNode(flow, step) {
|
|
1745
|
+
if (step.nodeResult.outcome === "ok") {
|
|
1746
|
+
setNodeValue(step.state.outputs, step.nodeId, step.output);
|
|
1747
|
+
return resolveNext(flow.edges, step.nodeId, step.output, step.nodeResult);
|
|
1748
|
+
}
|
|
1749
|
+
const next = resolveNext(flow.edges, step.nodeId, void 0, step.nodeResult);
|
|
1750
|
+
if (next !== null) return next;
|
|
1751
|
+
throw step.executionError;
|
|
1752
|
+
}
|
|
1753
|
+
async completeFlowRun(runDir, state) {
|
|
1754
|
+
state.status = "completed";
|
|
1755
|
+
state.finishedAt = isoNow$1();
|
|
1756
|
+
state.updatedAt = state.finishedAt;
|
|
1757
|
+
clearActiveNode(state);
|
|
1758
|
+
await this.store.writeSnapshot(runDir, state, {
|
|
1759
|
+
scope: "run",
|
|
1760
|
+
type: "run_completed",
|
|
1761
|
+
payload: { status: state.status }
|
|
1762
|
+
});
|
|
1763
|
+
return {
|
|
1764
|
+
runDir,
|
|
1765
|
+
state
|
|
1766
|
+
};
|
|
1767
|
+
}
|
|
1768
|
+
async recordFlowStepOutcome(runDir, state, step, overrides = {}) {
|
|
1769
|
+
state.updatedAt = isoNow$1();
|
|
1770
|
+
clearActiveNode(state, overrides.statusDetail);
|
|
1771
|
+
state.steps.push({
|
|
1772
|
+
attemptId: step.attemptId,
|
|
1773
|
+
nodeId: step.nodeId,
|
|
1774
|
+
nodeType: step.node.nodeType,
|
|
1775
|
+
outcome: step.nodeResult.outcome,
|
|
1776
|
+
startedAt: step.startedAt,
|
|
1777
|
+
finishedAt: step.nodeResult.finishedAt,
|
|
1778
|
+
promptText: step.promptText,
|
|
1779
|
+
rawText: step.rawText,
|
|
1780
|
+
output: step.output,
|
|
1781
|
+
error: step.nodeResult.error,
|
|
1782
|
+
session: step.sessionInfo,
|
|
1783
|
+
agent: step.agentInfo,
|
|
1784
|
+
...step.trace ? { trace: step.trace } : {}
|
|
1785
|
+
});
|
|
1786
|
+
await this.store.writeSnapshot(runDir, state, {
|
|
1787
|
+
scope: "node",
|
|
1788
|
+
type: "node_outcome",
|
|
1789
|
+
nodeId: step.nodeId,
|
|
1790
|
+
attemptId: step.attemptId,
|
|
1791
|
+
payload: createNodeOutcomePayload(step.nodeResult, step.trace)
|
|
1792
|
+
});
|
|
1793
|
+
}
|
|
1794
|
+
async executeNode(runDir, state, flow, nodeId, node, context) {
|
|
1795
|
+
switch (node.nodeType) {
|
|
1796
|
+
case "compute": return await this.executeCallbackNode(nodeId, node, context);
|
|
1797
|
+
case "action": return "run" in node ? await this.executeCallbackNode(nodeId, node, context) : await this.executeShellNode(runDir, state, node, context);
|
|
1798
|
+
case "checkpoint": return await this.executeCallbackNode(nodeId, node, context);
|
|
1799
|
+
case "acp": return await this.executeAcpNode(runDir, state, flow, node, context);
|
|
1800
|
+
default: throw new Error(`Unsupported flow node: ${String(node)}`);
|
|
1801
|
+
}
|
|
1802
|
+
}
|
|
1803
|
+
async executeCallbackNode(nodeId, node, context) {
|
|
1804
|
+
context.attempt.assertActive();
|
|
1805
|
+
const output = node.nodeType === "checkpoint" && typeof node.run !== "function" ? {
|
|
1806
|
+
checkpoint: nodeId,
|
|
1807
|
+
summary: node.summary ?? nodeId
|
|
1808
|
+
} : await node.run?.(context.nodeContext);
|
|
1809
|
+
context.attempt.assertActive();
|
|
1810
|
+
return {
|
|
1811
|
+
output,
|
|
1812
|
+
promptText: null,
|
|
1813
|
+
rawText: null,
|
|
1814
|
+
sessionInfo: null,
|
|
1815
|
+
agentInfo: null,
|
|
1816
|
+
trace: node.nodeType === "action" ? { action: { actionType: "function" } } : null
|
|
1817
|
+
};
|
|
1818
|
+
}
|
|
1819
|
+
async executeShellNode(runDir, state, node, context) {
|
|
1820
|
+
const attempt = context.attempt;
|
|
1821
|
+
const execution = await node.exec(context.nodeContext);
|
|
1822
|
+
attempt.assertActive();
|
|
1823
|
+
const effectiveExecution = {
|
|
1824
|
+
...execution,
|
|
1825
|
+
cwd: resolveShellActionCwd(this.defaultCwd, execution.cwd),
|
|
1826
|
+
timeoutMs: resolveShellActionTimeoutMs(execution.timeoutMs ?? attempt.remainingTimeoutMs())
|
|
1827
|
+
};
|
|
1828
|
+
updateStatusDetail(state, formatShellActionSummary(effectiveExecution));
|
|
1829
|
+
await attempt.own(() => this.store.writeLive(runDir, state, {
|
|
1830
|
+
scope: "node",
|
|
1831
|
+
type: "node_heartbeat",
|
|
1832
|
+
nodeId: attempt.nodeId,
|
|
1833
|
+
attemptId: attempt.attemptId,
|
|
1834
|
+
payload: { statusDetail: state.statusDetail }
|
|
1835
|
+
}));
|
|
1836
|
+
await attempt.own(() => this.store.appendTrace(runDir, state, {
|
|
1837
|
+
scope: "action",
|
|
1838
|
+
type: "action_prepared",
|
|
1839
|
+
nodeId: attempt.nodeId,
|
|
1840
|
+
attemptId: attempt.attemptId,
|
|
1841
|
+
payload: { action: {
|
|
1842
|
+
actionType: "shell",
|
|
1843
|
+
command: effectiveExecution.command,
|
|
1844
|
+
args: effectiveExecution.args ?? [],
|
|
1845
|
+
cwd: effectiveExecution.cwd
|
|
1846
|
+
} }
|
|
1847
|
+
}));
|
|
1848
|
+
const result = await attempt.own(() => runShellAction(effectiveExecution, this.shellControl(runDir, attempt)));
|
|
1849
|
+
const stdoutArtifact = await attempt.own(() => this.store.writeArtifact(runDir, state, result.stdout, {
|
|
1850
|
+
mediaType: "text/plain",
|
|
1851
|
+
extension: "txt",
|
|
1852
|
+
nodeId: attempt.nodeId,
|
|
1853
|
+
attemptId: attempt.attemptId
|
|
1854
|
+
}));
|
|
1855
|
+
const stderrArtifact = await attempt.own(() => this.store.writeArtifact(runDir, state, result.stderr, {
|
|
1856
|
+
mediaType: "text/plain",
|
|
1857
|
+
extension: "txt",
|
|
1858
|
+
nodeId: attempt.nodeId,
|
|
1859
|
+
attemptId: attempt.attemptId
|
|
1860
|
+
}));
|
|
1861
|
+
const actionTrace = {
|
|
1862
|
+
actionType: "shell",
|
|
1863
|
+
command: result.command,
|
|
1864
|
+
args: result.args,
|
|
1865
|
+
cwd: result.cwd,
|
|
1866
|
+
exitCode: result.exitCode,
|
|
1867
|
+
signal: result.signal,
|
|
1868
|
+
durationMs: result.durationMs
|
|
1869
|
+
};
|
|
1870
|
+
await attempt.own(() => this.store.appendTrace(runDir, state, {
|
|
1871
|
+
scope: "action",
|
|
1872
|
+
type: "action_completed",
|
|
1873
|
+
nodeId: attempt.nodeId,
|
|
1874
|
+
attemptId: attempt.attemptId,
|
|
1875
|
+
payload: {
|
|
1876
|
+
action: actionTrace,
|
|
1877
|
+
stdoutArtifact,
|
|
1878
|
+
stderrArtifact
|
|
1879
|
+
}
|
|
1880
|
+
}));
|
|
1881
|
+
const trace = {
|
|
1882
|
+
action: actionTrace,
|
|
1883
|
+
stdoutArtifact,
|
|
1884
|
+
stderrArtifact
|
|
1885
|
+
};
|
|
1886
|
+
let output;
|
|
1887
|
+
try {
|
|
1888
|
+
output = node.parse ? await node.parse(result, context.nodeContext) : result;
|
|
1889
|
+
attempt.assertActive();
|
|
1890
|
+
} catch (error) {
|
|
1891
|
+
throw attachStepTrace(error, trace);
|
|
1892
|
+
}
|
|
1893
|
+
return {
|
|
1894
|
+
output,
|
|
1895
|
+
promptText: null,
|
|
1896
|
+
rawText: result.combinedOutput,
|
|
1897
|
+
sessionInfo: null,
|
|
1898
|
+
agentInfo: null,
|
|
1899
|
+
trace
|
|
1900
|
+
};
|
|
1901
|
+
}
|
|
1902
|
+
shellControl(runDir, attempt) {
|
|
1903
|
+
return {
|
|
1904
|
+
signal: attempt.signal,
|
|
1905
|
+
get terminationSignal() {
|
|
1906
|
+
return attempt.terminationSignal;
|
|
1907
|
+
},
|
|
1908
|
+
registerOwner: (owner) => {
|
|
1909
|
+
const releaseAttempt = attempt.registerCancellation((signal) => owner.cancel(signal));
|
|
1910
|
+
const releaseRun = this.registerShellOwner(runDir, owner);
|
|
1911
|
+
return () => {
|
|
1912
|
+
releaseAttempt();
|
|
1913
|
+
releaseRun();
|
|
1914
|
+
};
|
|
1915
|
+
}
|
|
1916
|
+
};
|
|
1917
|
+
}
|
|
1918
|
+
runCallbackShell(runDir, attempt, execution) {
|
|
1919
|
+
return attempt.own(() => runShellCommand({
|
|
1920
|
+
...execution,
|
|
1921
|
+
cwd: resolveShellActionCwd(this.defaultCwd, execution.cwd)
|
|
1922
|
+
}, this.shellControl(runDir, attempt)));
|
|
1923
|
+
}
|
|
1924
|
+
async executeAcpNode(runDir, state, flow, node, context) {
|
|
1925
|
+
const attempt = context.attempt;
|
|
1926
|
+
const prepared = await this.prepareAcpPrompt(runDir, state, node, context);
|
|
1927
|
+
const isolated = node.session?.isolated;
|
|
1928
|
+
const binding = isolated ? createIsolatedSessionBinding(flow.name, state.runId, attempt.attemptId, node.profile, prepared.agentInfo) : await this.ensureSessionBinding(runDir, state, flow, node, prepared.agentInfo, attempt);
|
|
1929
|
+
if (isolated) {
|
|
1930
|
+
const requestedSettings = this.resolveSessionSettings(node);
|
|
1931
|
+
if (requestedSettings.model !== void 0 || requestedSettings.configOptions.length > 0) binding.requestedSettings = requestedSettings;
|
|
1932
|
+
}
|
|
1933
|
+
prepared.result.sessionInfo = binding;
|
|
1934
|
+
if (isolated) await attempt.own(() => this.initializeIsolatedSessionBundle(runDir, state, binding, attempt));
|
|
1935
|
+
await attempt.own(() => this.appendAcpPromptPreparedTrace(runDir, state, binding, prepared.promptArtifact, attempt));
|
|
1936
|
+
const prompt = await attempt.own(() => isolated ? this.runIsolatedPrompt(runDir, state, binding, prepared) : this.runPersistentPrompt(runDir, state, binding, prepared));
|
|
1937
|
+
await attempt.own(() => this.appendAcpResponseParsedTrace(runDir, state, prompt, attempt));
|
|
1938
|
+
const output = await this.parseAcpOutput(node, context, prompt.rawText);
|
|
1939
|
+
return {
|
|
1940
|
+
...prepared.result,
|
|
1941
|
+
output
|
|
1942
|
+
};
|
|
1943
|
+
}
|
|
1944
|
+
async prepareAcpPrompt(runDir, state, node, context) {
|
|
1945
|
+
const resolvedAgent = this.resolveAgent(node.profile);
|
|
1946
|
+
const agentInfo = {
|
|
1947
|
+
...resolvedAgent,
|
|
1948
|
+
agentArgv: resolvedAgent.agentArgv?.slice(),
|
|
1949
|
+
cwd: await resolveNodeCwd(resolvedAgent.cwd, node.cwd, context.nodeContext)
|
|
1950
|
+
};
|
|
1951
|
+
context.attempt.assertActive();
|
|
1952
|
+
const prompt = normalizePromptInput(await Promise.resolve(node.prompt(context.nodeContext)));
|
|
1953
|
+
context.attempt.assertActive();
|
|
1954
|
+
const promptText = promptToDisplayText(prompt);
|
|
1955
|
+
const result = {
|
|
1956
|
+
output: void 0,
|
|
1957
|
+
promptText,
|
|
1958
|
+
rawText: null,
|
|
1959
|
+
sessionInfo: null,
|
|
1960
|
+
agentInfo,
|
|
1961
|
+
trace: null
|
|
1962
|
+
};
|
|
1963
|
+
context.acpResult = result;
|
|
1964
|
+
updateStatusDetail(state, summarizePrompt(promptText, node.statusDetail));
|
|
1965
|
+
await context.attempt.own(() => this.writeAcpPromptHeartbeat(runDir, state, context.attempt));
|
|
1966
|
+
const promptArtifact = await context.attempt.own(() => this.store.writeArtifact(runDir, state, promptText, {
|
|
1967
|
+
mediaType: "text/plain",
|
|
1968
|
+
extension: "txt",
|
|
1969
|
+
nodeId: context.attempt.nodeId,
|
|
1970
|
+
attemptId: context.attempt.attemptId
|
|
1971
|
+
}));
|
|
1972
|
+
result.trace = { promptArtifact };
|
|
1973
|
+
return {
|
|
1974
|
+
agentInfo,
|
|
1975
|
+
prompt,
|
|
1976
|
+
promptArtifact,
|
|
1977
|
+
attempt: context.attempt,
|
|
1978
|
+
result
|
|
1979
|
+
};
|
|
1980
|
+
}
|
|
1981
|
+
async writeAcpPromptHeartbeat(runDir, state, attempt) {
|
|
1982
|
+
await this.store.writeLive(runDir, state, {
|
|
1983
|
+
scope: "node",
|
|
1984
|
+
type: "node_heartbeat",
|
|
1985
|
+
nodeId: attempt.nodeId,
|
|
1986
|
+
attemptId: attempt.attemptId,
|
|
1987
|
+
payload: { statusDetail: state.statusDetail }
|
|
1988
|
+
});
|
|
1989
|
+
}
|
|
1990
|
+
async initializeIsolatedSessionBundle(runDir, state, binding, attempt) {
|
|
1991
|
+
const timestamp = attempt.startedAt;
|
|
1992
|
+
const initialRecord = createSyntheticSessionRecord({
|
|
1993
|
+
binding,
|
|
1994
|
+
createdAt: timestamp,
|
|
1995
|
+
updatedAt: timestamp,
|
|
1996
|
+
conversation: createSessionConversation(timestamp),
|
|
1997
|
+
acpxState: void 0,
|
|
1998
|
+
lastSeq: 0
|
|
1999
|
+
});
|
|
2000
|
+
await this.store.ensureSessionBundle(runDir, state, binding, initialRecord);
|
|
2001
|
+
}
|
|
2002
|
+
async appendAcpPromptPreparedTrace(runDir, state, binding, promptArtifact, attempt) {
|
|
2003
|
+
await this.store.appendTrace(runDir, state, {
|
|
2004
|
+
scope: "acp",
|
|
2005
|
+
type: "acp_prompt_prepared",
|
|
2006
|
+
nodeId: attempt.nodeId,
|
|
2007
|
+
attemptId: attempt.attemptId,
|
|
2008
|
+
sessionId: binding.bundleId,
|
|
2009
|
+
payload: {
|
|
2010
|
+
sessionId: binding.bundleId,
|
|
2011
|
+
promptArtifact
|
|
2012
|
+
}
|
|
2013
|
+
});
|
|
2014
|
+
}
|
|
2015
|
+
async publishAcpCapture(runDir, state, prepared, sessionInfo, record, messageStart, rawText, events) {
|
|
2016
|
+
const result = prepared.result;
|
|
2017
|
+
result.sessionInfo = sessionInfo;
|
|
2018
|
+
const trace = {
|
|
2019
|
+
sessionId: sessionInfo.bundleId,
|
|
2020
|
+
promptArtifact: prepared.promptArtifact
|
|
2021
|
+
};
|
|
2022
|
+
result.trace = trace;
|
|
2023
|
+
await this.store.ensureSessionBundle(runDir, state, sessionInfo);
|
|
2024
|
+
await this.store.writeSessionRecord(runDir, state, sessionInfo, record);
|
|
2025
|
+
if (events) trace.conversation = {
|
|
2026
|
+
sessionId: sessionInfo.bundleId,
|
|
2027
|
+
messageStart,
|
|
2028
|
+
messageEnd: Math.max(messageStart, record.messages.length - 1),
|
|
2029
|
+
...events
|
|
2030
|
+
};
|
|
2031
|
+
const rawResponseArtifact = await this.store.writeArtifact(runDir, state, rawText, {
|
|
2032
|
+
mediaType: "text/plain",
|
|
2033
|
+
extension: "txt",
|
|
2034
|
+
nodeId: prepared.attempt.nodeId,
|
|
2035
|
+
attemptId: prepared.attempt.attemptId,
|
|
2036
|
+
sessionId: sessionInfo.bundleId
|
|
2037
|
+
});
|
|
2038
|
+
trace.rawResponseArtifact = rawResponseArtifact;
|
|
2039
|
+
return {
|
|
2040
|
+
rawText,
|
|
2041
|
+
sessionInfo,
|
|
2042
|
+
conversation: trace.conversation,
|
|
2043
|
+
rawResponseArtifact
|
|
2044
|
+
};
|
|
2045
|
+
}
|
|
2046
|
+
async appendAcpResponseParsedTrace(runDir, state, prompt, attempt) {
|
|
2047
|
+
await this.store.appendTrace(runDir, state, {
|
|
2048
|
+
scope: "acp",
|
|
2049
|
+
type: "acp_response_parsed",
|
|
2050
|
+
nodeId: attempt.nodeId,
|
|
2051
|
+
attemptId: attempt.attemptId,
|
|
2052
|
+
sessionId: prompt.sessionInfo.bundleId,
|
|
2053
|
+
payload: {
|
|
2054
|
+
sessionId: prompt.sessionInfo.bundleId,
|
|
2055
|
+
conversation: prompt.conversation,
|
|
2056
|
+
rawResponseArtifact: prompt.rawResponseArtifact
|
|
2057
|
+
}
|
|
2058
|
+
});
|
|
2059
|
+
}
|
|
2060
|
+
async parseAcpOutput(node, context, rawText) {
|
|
2061
|
+
context.attempt.assertActive();
|
|
2062
|
+
const output = node.parse ? await node.parse(rawText, context.nodeContext) : rawText;
|
|
2063
|
+
context.attempt.assertActive();
|
|
2064
|
+
return output;
|
|
2065
|
+
}
|
|
2066
|
+
startHeartbeat(runDir, state, node, attempt) {
|
|
2067
|
+
const heartbeatMs = Math.max(0, Math.round(node.heartbeatMs ?? DEFAULT_FLOW_HEARTBEAT_MS));
|
|
2068
|
+
if (heartbeatMs === 0) return () => {};
|
|
2069
|
+
let pending = false;
|
|
2070
|
+
const heartbeat = async () => {
|
|
2071
|
+
if (!attempt.active || pending) return;
|
|
2072
|
+
pending = true;
|
|
2073
|
+
try {
|
|
2074
|
+
await attempt.own(async () => {
|
|
2075
|
+
state.lastHeartbeatAt = isoNow$1();
|
|
2076
|
+
state.updatedAt = state.lastHeartbeatAt;
|
|
2077
|
+
await this.store.writeLive(runDir, state, {
|
|
2078
|
+
scope: "node",
|
|
2079
|
+
type: "node_heartbeat",
|
|
2080
|
+
nodeId: attempt.nodeId,
|
|
2081
|
+
attemptId: attempt.attemptId,
|
|
2082
|
+
payload: { statusDetail: state.statusDetail }
|
|
2083
|
+
});
|
|
2084
|
+
}, { bestEffort: true });
|
|
2085
|
+
} catch {} finally {
|
|
2086
|
+
pending = false;
|
|
2087
|
+
}
|
|
2088
|
+
};
|
|
2089
|
+
const timer = setInterval(() => {
|
|
2090
|
+
heartbeat();
|
|
2091
|
+
}, heartbeatMs);
|
|
2092
|
+
return () => clearInterval(timer);
|
|
2093
|
+
}
|
|
2094
|
+
resolveSessionSettings(node) {
|
|
2095
|
+
return {
|
|
2096
|
+
model: node.modelId ?? this.sessionOptions?.model,
|
|
2097
|
+
configOptions: [...this.configOptions, ...node.configOptions ?? []].map(({ configId, value }) => ({
|
|
2098
|
+
configId,
|
|
2099
|
+
value
|
|
2100
|
+
}))
|
|
2101
|
+
};
|
|
2102
|
+
}
|
|
2103
|
+
async ensureSessionBinding(runDir, state, flow, node, agent, attempt) {
|
|
2104
|
+
const handle = node.session?.handle ?? "main";
|
|
2105
|
+
const key = createSessionBindingKey(agent.agentCommand, agent.cwd, handle, agent.agentArgv);
|
|
2106
|
+
const existing = state.sessionBindings[key];
|
|
2107
|
+
if (existing) {
|
|
2108
|
+
assertCompatibleSessionSettings(node, existing);
|
|
2109
|
+
await attempt.own(() => this.store.ensureSessionBundle(runDir, state, existing));
|
|
2110
|
+
return existing;
|
|
2111
|
+
}
|
|
2112
|
+
const requestedSettings = this.resolveSessionSettings(node);
|
|
2113
|
+
let acceptedSettings;
|
|
2114
|
+
const name = createSessionName(flow.name, handle, agent.cwd, state.runId);
|
|
2115
|
+
const created = await attempt.own(async () => {
|
|
2116
|
+
const acquired = await createSessionWithClient({
|
|
2117
|
+
agentCommand: agent.agentCommand,
|
|
2118
|
+
agentArgv: agent.agentArgv,
|
|
2119
|
+
cwd: agent.cwd,
|
|
2120
|
+
name,
|
|
2121
|
+
...this.connectionOptions,
|
|
2122
|
+
signal: attempt.signal,
|
|
2123
|
+
handleProcessInterrupts: false,
|
|
2124
|
+
sessionOptions: {
|
|
2125
|
+
...this.sessionOptions,
|
|
2126
|
+
model: requestedSettings.model
|
|
2127
|
+
},
|
|
2128
|
+
configOptions: requestedSettings.configOptions,
|
|
2129
|
+
onSessionConfigured: (configuration) => {
|
|
2130
|
+
acceptedSettings = configuration;
|
|
2131
|
+
}
|
|
2132
|
+
});
|
|
2133
|
+
this.pendingClientReleases.set(acquired.client, attempt.registerCancellation(async () => {
|
|
2134
|
+
const clients = this.pendingPersistentSessionClients.get(runDir);
|
|
2135
|
+
if (clients?.get(key) === acquired.client) clients.delete(key);
|
|
2136
|
+
await acquired.client.close();
|
|
2137
|
+
}));
|
|
2138
|
+
return acquired;
|
|
2139
|
+
});
|
|
2140
|
+
attempt.assertActive();
|
|
2141
|
+
const binding = {
|
|
2142
|
+
...requestedSettings.model !== void 0 || requestedSettings.configOptions.length > 0 ? {
|
|
2143
|
+
requestedSettings,
|
|
2144
|
+
acceptedSettings
|
|
2145
|
+
} : {},
|
|
2146
|
+
key,
|
|
2147
|
+
handle,
|
|
2148
|
+
bundleId: createSessionBundleId(handle, key),
|
|
2149
|
+
name,
|
|
2150
|
+
profile: node.profile,
|
|
2151
|
+
agentName: agent.agentName,
|
|
2152
|
+
agentCommand: agent.agentCommand,
|
|
2153
|
+
agentArgv: agent.agentArgv,
|
|
2154
|
+
cwd: agent.cwd,
|
|
2155
|
+
acpxRecordId: created.record.acpxRecordId,
|
|
2156
|
+
acpSessionId: created.record.acpSessionId,
|
|
2157
|
+
agentSessionId: created.record.agentSessionId
|
|
2158
|
+
};
|
|
2159
|
+
state.sessionBindings[key] = binding;
|
|
2160
|
+
let clients = this.pendingPersistentSessionClients.get(runDir);
|
|
2161
|
+
if (!clients) {
|
|
2162
|
+
clients = /* @__PURE__ */ new Map();
|
|
2163
|
+
this.pendingPersistentSessionClients.set(runDir, clients);
|
|
2164
|
+
}
|
|
2165
|
+
clients.set(binding.key, created.client);
|
|
2166
|
+
await attempt.own(() => this.store.ensureSessionBundle(runDir, state, binding, created.record));
|
|
2167
|
+
return binding;
|
|
2168
|
+
}
|
|
2169
|
+
createPromptEventCapture(runDir, binding) {
|
|
2170
|
+
const pending = /* @__PURE__ */ new Set();
|
|
2171
|
+
let ordinal = 0;
|
|
2172
|
+
let failure;
|
|
2173
|
+
let eventStartSeq;
|
|
2174
|
+
let eventEndSeq = 0;
|
|
2175
|
+
const snapshot = (outcome) => ({
|
|
2176
|
+
outcome,
|
|
2177
|
+
events: !failure && eventStartSeq !== void 0 ? {
|
|
2178
|
+
eventStartSeq,
|
|
2179
|
+
eventEndSeq
|
|
2180
|
+
} : void 0,
|
|
2181
|
+
lastSeq: eventEndSeq
|
|
2182
|
+
});
|
|
2183
|
+
return {
|
|
2184
|
+
onAcpMessage: (direction, message) => {
|
|
2185
|
+
const index = ordinal++;
|
|
2186
|
+
const write = this.store.appendSessionEvent(runDir, binding, direction, message).then((seq) => {
|
|
2187
|
+
eventStartSeq = Math.min(eventStartSeq ?? seq, seq);
|
|
2188
|
+
eventEndSeq = Math.max(eventEndSeq, seq);
|
|
2189
|
+
}, (reason) => {
|
|
2190
|
+
if (!failure || index < failure.ordinal) failure = {
|
|
2191
|
+
ordinal: index,
|
|
2192
|
+
reason
|
|
2193
|
+
};
|
|
2194
|
+
}).finally(() => pending.delete(write));
|
|
2195
|
+
pending.add(write);
|
|
2196
|
+
},
|
|
2197
|
+
async run(operation, finalize) {
|
|
2198
|
+
let result;
|
|
2199
|
+
try {
|
|
2200
|
+
result = {
|
|
2201
|
+
status: "fulfilled",
|
|
2202
|
+
value: await operation()
|
|
2203
|
+
};
|
|
2204
|
+
} catch (reason) {
|
|
2205
|
+
result = {
|
|
2206
|
+
status: "rejected",
|
|
2207
|
+
reason
|
|
2208
|
+
};
|
|
2209
|
+
}
|
|
2210
|
+
await Promise.all(pending);
|
|
2211
|
+
let finalized;
|
|
2212
|
+
try {
|
|
2213
|
+
finalized = {
|
|
2214
|
+
status: "fulfilled",
|
|
2215
|
+
value: await finalize(snapshot(result))
|
|
2216
|
+
};
|
|
2217
|
+
} catch (reason) {
|
|
2218
|
+
finalized = {
|
|
2219
|
+
status: "rejected",
|
|
2220
|
+
reason
|
|
2221
|
+
};
|
|
2222
|
+
}
|
|
2223
|
+
if (result.status === "rejected") throw result.reason;
|
|
2224
|
+
if (failure) throw failure.reason;
|
|
2225
|
+
if (eventStartSeq === void 0) throw new Error(`Missing ACP event capture for session ${binding.bundleId}`);
|
|
2226
|
+
if (finalized.status === "rejected") throw finalized.reason;
|
|
2227
|
+
return finalized.value;
|
|
2228
|
+
}
|
|
2229
|
+
};
|
|
2230
|
+
}
|
|
2231
|
+
async runPersistentPrompt(runDir, state, binding, prepared) {
|
|
2232
|
+
const { attempt, prompt } = prepared;
|
|
2233
|
+
const capture = createQuietCaptureOutput();
|
|
2234
|
+
const beforeRecord = await resolveSessionRecord(binding.acpxRecordId);
|
|
2235
|
+
attempt.assertActive();
|
|
2236
|
+
const events = this.createPromptEventCapture(runDir, binding);
|
|
2237
|
+
const clients = this.pendingPersistentSessionClients.get(runDir);
|
|
2238
|
+
const initialClient = clients?.get(binding.key);
|
|
2239
|
+
if (initialClient) {
|
|
2240
|
+
clients?.delete(binding.key);
|
|
2241
|
+
this.pendingClientReleases.get(initialClient)?.();
|
|
2242
|
+
this.pendingClientReleases.delete(initialClient);
|
|
2243
|
+
}
|
|
2244
|
+
return await events.run(() => sendSessionDirect({
|
|
2245
|
+
sessionId: binding.acpxRecordId,
|
|
2246
|
+
prompt,
|
|
2247
|
+
resumePolicy: "same-session-only",
|
|
2248
|
+
...this.connectionOptions,
|
|
2249
|
+
outputFormatter: capture.formatter,
|
|
2250
|
+
errorEmissionPolicy: { queueErrorAlreadyEmitted: false },
|
|
2251
|
+
onAcpMessage: events.onAcpMessage,
|
|
2252
|
+
suppressSdkConsoleErrors: this.suppressSdkConsoleErrors,
|
|
2253
|
+
client: initialClient,
|
|
2254
|
+
...initialClient ? {} : {
|
|
2255
|
+
sessionOptions: {
|
|
2256
|
+
...this.sessionOptions,
|
|
2257
|
+
model: binding.requestedSettings?.model
|
|
2258
|
+
},
|
|
2259
|
+
configOptions: binding.requestedSettings?.configOptions,
|
|
2260
|
+
onSessionConfigured: (configuration) => {
|
|
2261
|
+
assertReplayedSessionSettings(binding, configuration);
|
|
2262
|
+
if (binding.requestedSettings) binding.acceptedSettings = configuration;
|
|
2263
|
+
}
|
|
2264
|
+
}
|
|
2265
|
+
}, {
|
|
2266
|
+
signal: attempt.signal,
|
|
2267
|
+
handleProcessInterrupts: false
|
|
2268
|
+
}), async (receipt) => {
|
|
2269
|
+
const rawText = capture.read();
|
|
2270
|
+
prepared.result.rawText = rawText;
|
|
2271
|
+
const afterRecord = await resolveSessionRecord(binding.acpxRecordId);
|
|
2272
|
+
const sessionInfo = {
|
|
2273
|
+
...binding,
|
|
2274
|
+
acpSessionId: afterRecord.acpSessionId,
|
|
2275
|
+
agentSessionId: afterRecord.agentSessionId
|
|
2276
|
+
};
|
|
2277
|
+
state.sessionBindings[sessionInfo.key] = sessionInfo;
|
|
2278
|
+
return await this.publishAcpCapture(runDir, state, prepared, sessionInfo, afterRecord, findConversationDeltaStart(beforeRecord.messages, afterRecord.messages), rawText, receipt.events);
|
|
2279
|
+
});
|
|
2280
|
+
}
|
|
2281
|
+
async closePendingPersistentSessionClients(runDir) {
|
|
2282
|
+
const pendingClients = [...this.pendingPersistentSessionClients.get(runDir)?.values() ?? []];
|
|
2283
|
+
this.pendingPersistentSessionClients.delete(runDir);
|
|
2284
|
+
const failure = (await Promise.allSettled(pendingClients.map(async (client) => {
|
|
2285
|
+
this.pendingClientReleases.get(client)?.();
|
|
2286
|
+
this.pendingClientReleases.delete(client);
|
|
2287
|
+
await client.close();
|
|
2288
|
+
}))).find((result) => result.status === "rejected");
|
|
2289
|
+
if (failure?.status === "rejected") throw failure.reason;
|
|
2290
|
+
}
|
|
2291
|
+
async runIsolatedPrompt(runDir, state, binding, prepared) {
|
|
2292
|
+
const { agentInfo: agent, prompt, attempt } = prepared;
|
|
2293
|
+
const capture = createQuietCaptureOutput();
|
|
2294
|
+
const conversation = createSessionConversation(attempt.startedAt);
|
|
2295
|
+
let acpxState;
|
|
2296
|
+
recordPromptSubmission(conversation, prompt, attempt.startedAt);
|
|
2297
|
+
const events = this.createPromptEventCapture(runDir, binding);
|
|
2298
|
+
return await events.run(() => runOnce({
|
|
2299
|
+
agentCommand: agent.agentCommand,
|
|
2300
|
+
agentArgv: agent.agentArgv,
|
|
2301
|
+
cwd: agent.cwd,
|
|
2302
|
+
prompt,
|
|
2303
|
+
...this.connectionOptions,
|
|
2304
|
+
outputFormatter: capture.formatter,
|
|
2305
|
+
errorEmissionPolicy: { queueErrorAlreadyEmitted: false },
|
|
2306
|
+
onAcpMessage: events.onAcpMessage,
|
|
2307
|
+
onSessionUpdate: (notification) => {
|
|
2308
|
+
acpxState = recordSessionUpdate(conversation, acpxState, notification);
|
|
2309
|
+
},
|
|
2310
|
+
onClientOperation: (operation) => {
|
|
2311
|
+
acpxState = recordClientOperation(conversation, acpxState, operation);
|
|
2312
|
+
},
|
|
2313
|
+
suppressSdkConsoleErrors: this.suppressSdkConsoleErrors,
|
|
2314
|
+
sessionOptions: {
|
|
2315
|
+
...this.sessionOptions,
|
|
2316
|
+
model: binding.requestedSettings?.model
|
|
2317
|
+
},
|
|
2318
|
+
configOptions: binding.requestedSettings?.configOptions,
|
|
2319
|
+
onSessionConfigured: (configuration) => {
|
|
2320
|
+
if (binding.requestedSettings) binding.acceptedSettings = configuration;
|
|
2321
|
+
}
|
|
2322
|
+
}, {
|
|
2323
|
+
signal: attempt.signal,
|
|
2324
|
+
handleProcessInterrupts: false
|
|
2325
|
+
}), async (receipt) => {
|
|
2326
|
+
const rawText = capture.read();
|
|
2327
|
+
prepared.result.rawText = rawText;
|
|
2328
|
+
const sessionId = receipt.outcome.status === "fulfilled" ? receipt.outcome.value.sessionId : capture.sessionId();
|
|
2329
|
+
const sessionInfo = sessionId === void 0 ? binding : {
|
|
2330
|
+
...binding,
|
|
2331
|
+
acpxRecordId: sessionId,
|
|
2332
|
+
acpSessionId: sessionId
|
|
2333
|
+
};
|
|
2334
|
+
const record = createSyntheticSessionRecord({
|
|
2335
|
+
binding: sessionInfo,
|
|
2336
|
+
createdAt: attempt.startedAt,
|
|
2337
|
+
updatedAt: conversation.updated_at,
|
|
2338
|
+
conversation,
|
|
2339
|
+
acpxState: cloneSessionAcpxState(acpxState),
|
|
2340
|
+
lastSeq: receipt.lastSeq
|
|
2341
|
+
});
|
|
2342
|
+
return await this.publishAcpCapture(runDir, state, prepared, sessionInfo, record, 0, rawText, receipt.events);
|
|
2343
|
+
});
|
|
2344
|
+
}
|
|
2345
|
+
};
|
|
2346
|
+
// src/flows/json.ts
|
|
2347
|
+
function normalizeJsonText(text) {
|
|
2348
|
+
if (typeof text === "string") return text.trim();
|
|
2349
|
+
if (text == null) return "";
|
|
2350
|
+
if (typeof text === "number" || typeof text === "boolean" || typeof text === "bigint" || typeof text === "symbol") return String(text).trim();
|
|
2351
|
+
return "";
|
|
2352
|
+
}
|
|
2353
|
+
function parseJsonObject(text, options = {}) {
|
|
2354
|
+
const trimmed = normalizeJsonText(text);
|
|
2355
|
+
if (!trimmed) throw new Error("Expected JSON output, got empty text");
|
|
2356
|
+
const mode = options.mode ?? "compat";
|
|
2357
|
+
const direct = tryParse(trimmed);
|
|
2358
|
+
if (direct.ok) return direct.value;
|
|
2359
|
+
const fenced = parseFencedJsonIfAllowed(trimmed, mode);
|
|
2360
|
+
if (fenced.ok) return fenced.value;
|
|
2361
|
+
if (mode === "compat") {
|
|
2362
|
+
const balanced = parseBalancedJsonCandidate(trimmed);
|
|
2363
|
+
if (balanced.ok) return balanced.value;
|
|
2364
|
+
}
|
|
2365
|
+
throw new Error(`Could not parse JSON from assistant output:\n${trimmed}`);
|
|
2366
|
+
}
|
|
2367
|
+
function parseFencedJsonIfAllowed(text, mode) {
|
|
2368
|
+
if (mode !== "fenced" && mode !== "compat") return { ok: false };
|
|
2369
|
+
const fencedText = extractFencedJsonText(text);
|
|
2370
|
+
return fencedText === null ? { ok: false } : tryParse(fencedText);
|
|
2371
|
+
}
|
|
2372
|
+
const COMPAT_JSON_WORK_MULTIPLIER = 8;
|
|
2373
|
+
function consumeRecoveryWork(budget, units) {
|
|
2374
|
+
if (units > budget.remaining) {
|
|
2375
|
+
budget.remaining = 0;
|
|
2376
|
+
return false;
|
|
2377
|
+
}
|
|
2378
|
+
budget.remaining -= units;
|
|
2379
|
+
return true;
|
|
2380
|
+
}
|
|
2381
|
+
function parseBalancedJsonCandidate(text) {
|
|
2382
|
+
const budget = { remaining: text.length * COMPAT_JSON_WORK_MULTIPLIER };
|
|
2383
|
+
for (let index = 0; index < text.length && budget.remaining > 0; index += 1) {
|
|
2384
|
+
if (text[index] !== "{" && text[index] !== "[") continue;
|
|
2385
|
+
const end = scanBalanced(text, index, budget);
|
|
2386
|
+
if (end === null) continue;
|
|
2387
|
+
if (!consumeRecoveryWork(budget, end - index)) return { ok: false };
|
|
2388
|
+
const parsed = tryParse(text.slice(index, end));
|
|
2389
|
+
if (parsed.ok) return parsed;
|
|
2390
|
+
}
|
|
2391
|
+
return { ok: false };
|
|
2392
|
+
}
|
|
2393
|
+
function parseStrictJsonObject(text) {
|
|
2394
|
+
return parseJsonObject(text, { mode: "strict" });
|
|
2395
|
+
}
|
|
2396
|
+
function extractJsonObject(text) {
|
|
2397
|
+
return parseJsonObject(text, { mode: "compat" });
|
|
2398
|
+
}
|
|
2399
|
+
function tryParse(text) {
|
|
2400
|
+
try {
|
|
2401
|
+
return {
|
|
2402
|
+
ok: true,
|
|
2403
|
+
value: JSON.parse(text)
|
|
2404
|
+
};
|
|
2405
|
+
} catch {
|
|
2406
|
+
return { ok: false };
|
|
2407
|
+
}
|
|
2408
|
+
}
|
|
2409
|
+
function extractFencedJsonText(text) {
|
|
2410
|
+
const openingFenceIndex = text.indexOf("```");
|
|
2411
|
+
if (openingFenceIndex === -1) return null;
|
|
2412
|
+
let contentStart = openingFenceIndex + 3;
|
|
2413
|
+
if (text.slice(contentStart, contentStart + 4).toLowerCase() === "json" && isFenceWhitespace(text[contentStart + 4])) contentStart += 4;
|
|
2414
|
+
while (isFenceWhitespace(text[contentStart])) contentStart += 1;
|
|
2415
|
+
const closingFenceIndex = text.indexOf("```", contentStart);
|
|
2416
|
+
if (closingFenceIndex === -1) return null;
|
|
2417
|
+
return text.slice(contentStart, closingFenceIndex).trim();
|
|
2418
|
+
}
|
|
2419
|
+
function isFenceWhitespace(char) {
|
|
2420
|
+
return char === " " || char === "\n" || char === "\r" || char === " ";
|
|
2421
|
+
}
|
|
2422
|
+
function scanBalanced(text, startIndex, budget) {
|
|
2423
|
+
const stack = [];
|
|
2424
|
+
let inString = false;
|
|
2425
|
+
let escaped = false;
|
|
2426
|
+
for (let index = startIndex; index < text.length; index += 1) {
|
|
2427
|
+
if (!consumeRecoveryWork(budget, 1)) return null;
|
|
2428
|
+
const char = text[index];
|
|
2429
|
+
if (inString) {
|
|
2430
|
+
const next = scanStringChar(char, escaped);
|
|
2431
|
+
escaped = next.escaped;
|
|
2432
|
+
inString = next.inString;
|
|
2433
|
+
continue;
|
|
2434
|
+
}
|
|
2435
|
+
if (char === "\"") {
|
|
2436
|
+
inString = true;
|
|
2437
|
+
continue;
|
|
2438
|
+
}
|
|
2439
|
+
const result = scanBalancedToken(index, char, stack);
|
|
2440
|
+
if (result !== SCAN_CONTINUE) return result;
|
|
2441
|
+
}
|
|
2442
|
+
return null;
|
|
2443
|
+
}
|
|
2444
|
+
const SCAN_CONTINUE = Symbol("scan-continue");
|
|
2445
|
+
function scanBalancedToken(index, char, stack) {
|
|
2446
|
+
if (char === "{" || char === "[") {
|
|
2447
|
+
stack.push(char);
|
|
2448
|
+
return SCAN_CONTINUE;
|
|
2449
|
+
}
|
|
2450
|
+
if (char !== "}" && char !== "]") return SCAN_CONTINUE;
|
|
2451
|
+
if (!balancedClosingTokenMatches(stack.at(-1), char)) return null;
|
|
2452
|
+
stack.pop();
|
|
2453
|
+
return stack.length === 0 ? index + 1 : SCAN_CONTINUE;
|
|
2454
|
+
}
|
|
2455
|
+
function balancedClosingTokenMatches(open, close) {
|
|
2456
|
+
if (open === "{") return close === "}";
|
|
2457
|
+
if (open === "[") return close === "]";
|
|
2458
|
+
return false;
|
|
2459
|
+
}
|
|
2460
|
+
function scanStringChar(char, escaped) {
|
|
2461
|
+
if (escaped) return {
|
|
2462
|
+
escaped: false,
|
|
2463
|
+
inString: true
|
|
2464
|
+
};
|
|
2465
|
+
if (char === "\\") return {
|
|
2466
|
+
escaped: true,
|
|
2467
|
+
inString: true
|
|
2468
|
+
};
|
|
2469
|
+
return {
|
|
2470
|
+
escaped: false,
|
|
2471
|
+
inString: char !== "\""
|
|
2472
|
+
};
|
|
2473
|
+
}
|
|
2474
|
+
// src/flows/decision.ts
|
|
2475
|
+
const DEFAULT_FIELD = "route";
|
|
2476
|
+
const SIMPLE_FIELD_PATTERN = /^[A-Za-z_][A-Za-z0-9_]*$/;
|
|
2477
|
+
function decision(definition) {
|
|
2478
|
+
const { question, choices, field: fieldOverride, ...acpOptions } = definition;
|
|
2479
|
+
const field = normalizeField(fieldOverride);
|
|
2480
|
+
assertValidChoices(choices);
|
|
2481
|
+
const allowed = new Set(choices);
|
|
2482
|
+
return acp({
|
|
2483
|
+
...acpOptions,
|
|
2484
|
+
async prompt(context) {
|
|
2485
|
+
return formatDecisionPrompt(typeof question === "function" ? await question(context) : question, choices, field);
|
|
2486
|
+
},
|
|
2487
|
+
parse(text) {
|
|
2488
|
+
const raw = extractJsonObject(text);
|
|
2489
|
+
if (raw === null || typeof raw !== "object" || Array.isArray(raw)) throw new Error(`Decision response must be a JSON object, got ${typeof raw}`);
|
|
2490
|
+
const value = raw[field];
|
|
2491
|
+
if (typeof value !== "string" || !allowed.has(value)) {
|
|
2492
|
+
const allowedLabels = choices.map((choice) => JSON.stringify(choice)).join(", ");
|
|
2493
|
+
throw new Error(`Decision returned invalid ${field}=${JSON.stringify(value)}; expected one of ${allowedLabels}`);
|
|
2494
|
+
}
|
|
2495
|
+
return raw;
|
|
2496
|
+
}
|
|
2497
|
+
});
|
|
2498
|
+
}
|
|
2499
|
+
function decisionEdge(args) {
|
|
2500
|
+
const field = normalizeField(args.field);
|
|
2501
|
+
assertValidChoices(args.choices);
|
|
2502
|
+
for (const choice of args.choices) if (!Object.hasOwn(args.cases, choice)) throw new Error(`Decision edge is missing case for choice ${JSON.stringify(choice)}`);
|
|
2503
|
+
return {
|
|
2504
|
+
from: args.from,
|
|
2505
|
+
switch: {
|
|
2506
|
+
on: `$.${field}`,
|
|
2507
|
+
cases: args.cases
|
|
2508
|
+
}
|
|
2509
|
+
};
|
|
2510
|
+
}
|
|
2511
|
+
function assertValidChoices(choices) {
|
|
2512
|
+
if (choices.length === 0) throw new Error("Decision choices must include at least one value");
|
|
2513
|
+
const seen = /* @__PURE__ */ new Set();
|
|
2514
|
+
for (const choice of choices) {
|
|
2515
|
+
if (typeof choice !== "string" || choice.length === 0) throw new Error("Decision choices must be non-empty strings");
|
|
2516
|
+
if (seen.has(choice)) throw new Error(`Decision choices must be unique; duplicate ${JSON.stringify(choice)}`);
|
|
2517
|
+
seen.add(choice);
|
|
2518
|
+
}
|
|
2519
|
+
}
|
|
2520
|
+
function normalizeField(fieldOverride) {
|
|
2521
|
+
const field = fieldOverride ?? DEFAULT_FIELD;
|
|
2522
|
+
if (!SIMPLE_FIELD_PATTERN.test(field)) throw new Error(`Decision field must be a simple JSON key matching ${SIMPLE_FIELD_PATTERN.source}`);
|
|
2523
|
+
return field;
|
|
2524
|
+
}
|
|
2525
|
+
function formatDecisionPrompt(question, choices, field) {
|
|
2526
|
+
const allowed = choices.map((choice) => JSON.stringify(choice)).join(" | ");
|
|
2527
|
+
return [
|
|
2528
|
+
question,
|
|
2529
|
+
"",
|
|
2530
|
+
"Return exactly one JSON object with this shape:",
|
|
2531
|
+
"{",
|
|
2532
|
+
` ${JSON.stringify(field)}: ${allowed},`,
|
|
2533
|
+
" \"reason\": \"short justification\"",
|
|
2534
|
+
"}",
|
|
2535
|
+
"",
|
|
2536
|
+
"Do not include any other text outside the JSON object."
|
|
2537
|
+
].join("\n");
|
|
2538
|
+
}
|
|
2539
|
+
export { parseStrictJsonObject as a, validateFlowDefinition as c, checkpoint as d, compute as f, isDefinedFlow as h, parseJsonObject as i, acp as l, shell as m, decisionEdge as n, FlowRunner as o, defineFlow as p, extractJsonObject as r, flowRunsBaseDir as s, decision as t, action as u };
|
|
2540
|
+
|
|
2541
|
+
//# sourceMappingURL=flows-Bxlp6H8u.js.map
|