eve 0.67.2 → 0.69.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +120 -0
- package/bin/eve.js +15 -0
- package/dist/src/_virtual/_rolldown/runtime.js +1 -1
- package/dist/src/approval/definition.d.ts +19 -5
- package/dist/src/channel/adapter.d.ts +2 -0
- package/dist/src/channel/auth/oidc.js +1 -1
- package/dist/src/channel/channel-address.d.ts +1 -4
- package/dist/src/channel/channel-address.js +1 -1
- package/dist/src/channel/channel-operations.d.ts +4 -11
- package/dist/src/channel/channel-operations.js +1 -1
- package/dist/src/channel/compiled-channel.d.ts +0 -2
- package/dist/src/channel/compiled-channel.js +2 -2
- package/dist/src/channel/cross-channel-receive.d.ts +1 -3
- package/dist/src/channel/cross-channel-receive.js +1 -1
- package/dist/src/channel/forwarded-principal.js +1 -1
- package/dist/src/channel/schedule-auth.d.ts +16 -0
- package/dist/src/channel/schedule-auth.js +1 -1
- package/dist/src/channel/session-callback.js +1 -1
- package/dist/src/channel/session.d.ts +3 -8
- package/dist/src/channel/session.js +1 -1
- package/dist/src/channel/task-card.d.ts +121 -0
- package/dist/src/channel/task-card.js +1 -0
- package/dist/src/channel/types.d.ts +12 -54
- package/dist/src/chunks/{use-eve-agent-DXcE_8Ja.js → use-eve-agent-D_5129A9.js} +295 -205
- package/dist/src/chunks/{use-eve-agent-D4HVZBjn.js → use-eve-agent-Dab2MnT2.js} +295 -205
- package/dist/src/cli/commands/info.d.ts +11 -0
- package/dist/src/cli/commands/info.js +1 -1
- package/dist/src/cli/commands/init-agent-workspace.js +1 -1
- package/dist/src/cli/commands/init.js +1 -1
- package/dist/src/cli/dev/command-options.d.ts +3 -2
- package/dist/src/cli/dev/command.js +1 -1
- package/dist/src/cli/dev/local-server-process.js +1 -1
- package/dist/src/cli/dev/tui/blocks.d.ts +19 -18
- package/dist/src/cli/dev/tui/blocks.js +3 -3
- package/dist/src/cli/dev/tui/command-typeahead.d.ts +3 -6
- package/dist/src/cli/dev/tui/diagnostic-presentation.d.ts +10 -0
- package/dist/src/cli/dev/tui/diagnostic-presentation.js +3 -2
- package/dist/src/cli/dev/tui/prompt-placeholder.d.ts +2 -0
- package/dist/src/cli/dev/tui/prompt-placeholder.js +1 -0
- package/dist/src/cli/dev/tui/rail.d.ts +1 -1
- package/dist/src/cli/dev/tui/runner.d.ts +25 -2
- package/dist/src/cli/dev/tui/runner.js +3 -3
- package/dist/src/cli/dev/tui/status-line.d.ts +4 -2
- package/dist/src/cli/dev/tui/status-line.js +1 -1
- package/dist/src/cli/dev/tui/subagent-pump.d.ts +44 -52
- package/dist/src/cli/dev/tui/subagent-pump.js +1 -1
- package/dist/src/cli/dev/tui/task-activity.d.ts +55 -0
- package/dist/src/cli/dev/tui/task-activity.js +1 -0
- package/dist/src/cli/dev/tui/terminal-renderer.d.ts +13 -30
- package/dist/src/cli/dev/tui/terminal-renderer.js +11 -11
- package/dist/src/cli/dev/tui/theme.d.ts +1 -1
- package/dist/src/cli/dev/tui/theme.js +1 -1
- package/dist/src/cli/dev/tui/tool-block-groups.d.ts +6 -9
- package/dist/src/cli/dev/tui/tool-block-groups.js +1 -1
- package/dist/src/cli/dev/tui/tool-presentation.d.ts +16 -3
- package/dist/src/cli/dev/tui/tool-presentation.js +1 -1
- package/dist/src/cli/dev/tui/traces/trace-conversation.js +3 -1
- package/dist/src/cli/dev/tui/traces/trace-view.js +1 -1
- package/dist/src/cli/dev/tui/tui.js +1 -1
- package/dist/src/cli/dev/tui/types.d.ts +11 -5
- package/dist/src/cli/dev/ui-options.d.ts +2 -2
- package/dist/src/cli/option-parsers.d.ts +3 -1
- package/dist/src/cli/option-parsers.js +1 -1
- package/dist/src/cli/ui/terminal-text.js +1 -1
- package/dist/src/client/agent-info-schema.d.ts +150 -9
- package/dist/src/client/agent-info-schema.js +1 -1
- package/dist/src/client/agent-session.d.ts +28 -0
- package/dist/src/client/agent-session.js +1 -0
- package/dist/src/client/eve-agent-store-helpers.d.ts +1 -1
- package/dist/src/client/eve-agent-store-helpers.js +2 -2
- package/dist/src/client/eve-agent-store.js +1 -1
- package/dist/src/client/index.d.ts +2 -1
- package/dist/src/client/index.js +1 -1
- package/dist/src/client/message-action-parts.js +1 -1
- package/dist/src/client/message-reducer.js +1 -1
- package/dist/src/client/message-task-parts.d.ts +8 -0
- package/dist/src/client/message-task-parts.js +1 -0
- package/dist/src/client/optimistic-message-submissions.js +1 -1
- package/dist/src/client/session-controls.d.ts +0 -1
- package/dist/src/client/session-utils.d.ts +10 -0
- package/dist/src/client/session-utils.js +1 -1
- package/dist/src/client/session.d.ts +8 -16
- package/dist/src/client/session.js +1 -1
- package/dist/src/client/stream-version.js +1 -1
- package/dist/src/client/types.d.ts +2 -4
- package/dist/src/compiled/.vendor-stamp.json +3 -2
- package/dist/src/compiled/@eve/catalog/index.js +1 -1
- package/dist/src/compiled/@photon-ai/chat-adapter-imessage/index.js +55 -55
- package/dist/src/compiled/@vercel/blob/index.js +1 -1
- package/dist/src/compiled/@vercel/connect/LICENSE +202 -0
- package/dist/src/compiled/@vercel/connect/authorization-details.d.ts +11 -0
- package/dist/src/compiled/@vercel/connect/authorization.d.ts +47 -0
- package/dist/src/compiled/@vercel/connect/connector.d.ts +32 -0
- package/dist/src/compiled/@vercel/connect/index.d.ts +5 -0
- package/dist/src/compiled/@vercel/connect/index.js +26 -0
- package/dist/src/compiled/@vercel/connect/installation.d.ts +48 -0
- package/dist/src/compiled/@vercel/connect/token.d.ts +137 -0
- package/dist/src/compiled/@vercel/oidc/index.js +1 -1
- package/dist/src/compiled/@workflow/core/runtime.js +3 -3
- package/dist/src/compiled/@workflow/world-vercel/index.js +1 -1
- package/dist/src/compiler/bundled-extension.d.ts +7 -1
- package/dist/src/compiler/bundled-extension.js +1 -1
- package/dist/src/compiler/default-tool-policy.d.ts +2 -2
- package/dist/src/compiler/default-tool-policy.js +1 -1
- package/dist/src/compiler/development-extensions.js +1 -1
- package/dist/src/compiler/extension-compatibility.d.ts +54 -18
- package/dist/src/compiler/extension-compatibility.js +1 -1
- package/dist/src/compiler/extension-mount-bindings.d.ts +5 -0
- package/dist/src/compiler/extension-mount-bindings.js +1 -0
- package/dist/src/compiler/load-binding-namespace.d.ts +10 -2
- package/dist/src/compiler/load-binding-namespace.js +1 -1
- package/dist/src/compiler/manifest.d.ts +19 -17
- package/dist/src/compiler/manifest.js +1 -1
- package/dist/src/compiler/module-lifecycle.d.ts +2 -2
- package/dist/src/compiler/module-lifecycle.js +1 -1
- package/dist/src/compiler/module-map.d.ts +1 -1
- package/dist/src/compiler/module-map.js +3 -3
- package/dist/src/compiler/normalize-manifest-helpers.d.ts +18 -1
- package/dist/src/compiler/normalize-manifest-helpers.js +1 -1
- package/dist/src/compiler/normalize-manifest-types.d.ts +2 -0
- package/dist/src/compiler/normalize-manifest.js +1 -1
- package/dist/src/compiler/normalize-subagent.js +1 -1
- package/dist/src/compiler/normalize-tool.js +1 -1
- package/dist/src/compiler/project-sources.d.ts +4 -0
- package/dist/src/compiler/project-sources.js +1 -1
- package/dist/src/compiler/remote-agent-node.js +1 -1
- package/dist/src/compiler/source-graph.d.ts +5 -0
- package/dist/src/compiler/source-graph.js +1 -1
- package/dist/src/computer-use/extension/extension.d.ts +2 -0
- package/dist/src/computer-use/extension/extension.js +1 -0
- package/dist/src/computer-use/extension/lib/command-failure.d.ts +7 -0
- package/dist/src/computer-use/extension/lib/command-failure.js +2 -0
- package/dist/src/{extensions/code → computer-use}/extension/lib/computer-use-sandbox.d.ts +8 -0
- package/dist/src/{extensions/code → computer-use}/extension/lib/computer-use-sandbox.js +3 -3
- package/dist/src/{extensions/code → computer-use}/extension/lib/computer-use.d.ts +2 -0
- package/dist/src/{extensions/code → computer-use}/extension/lib/computer-use.js +2 -1
- package/dist/src/computer-use/extension/lib/sandbox.d.ts +1 -0
- package/dist/src/computer-use/extension/lib/sandbox.js +1 -0
- package/dist/src/computer-use/extension/lib/shell.d.ts +1 -0
- package/dist/src/computer-use/extension/lib/shell.js +1 -0
- package/dist/src/computer-use/extension/tools/computer_use.js +1 -0
- package/dist/src/computer-use/tools.d.ts +1 -0
- package/dist/src/computer-use/tools.js +1 -0
- package/dist/src/context/build-dynamic-tools.js +1 -1
- package/dist/src/context/dynamic-subagent-lifecycle.d.ts +5 -0
- package/dist/src/context/dynamic-subagent-lifecycle.js +1 -1
- package/dist/src/context/dynamic-tool-lifecycle.d.ts +1 -1
- package/dist/src/context/dynamic-tool-lifecycle.js +1 -1
- package/dist/src/context/dynamic-tool-metadata.d.ts +1 -1
- package/dist/src/context/hook-lifecycle.d.ts +4 -3
- package/dist/src/context/hook-lifecycle.js +1 -1
- package/dist/src/context/key-names.d.ts +0 -1
- package/dist/src/context/key-names.js +1 -1
- package/dist/src/context/keys.d.ts +8 -14
- package/dist/src/context/keys.js +1 -1
- package/dist/src/context/memory-lifecycle.js +1 -1
- package/dist/src/context/memory-tools.d.ts +0 -1
- package/dist/src/context/provider.d.ts +1 -3
- package/dist/src/context/run-step.d.ts +2 -3
- package/dist/src/context/run-step.js +1 -1
- package/dist/src/context/serialize.js +1 -1
- package/dist/src/discover/bundled-extension.js +1 -1
- package/dist/src/discover/discover-agent.js +1 -1
- package/dist/src/discover/extensions.d.ts +0 -7
- package/dist/src/discover/extensions.js +1 -1
- package/dist/src/discover/manifest.d.ts +4 -0
- package/dist/src/evals/assertions/run.d.ts +4 -3
- package/dist/src/evals/assertions/run.js +1 -1
- package/dist/src/evals/index.d.ts +1 -1
- package/dist/src/evals/match.d.ts +4 -4
- package/dist/src/evals/mock-model.js +1 -1
- package/dist/src/evals/runner/derive-run-facts.d.ts +3 -3
- package/dist/src/evals/runner/derive-run-facts.js +1 -1
- package/dist/src/evals/runner/reporters/assertion-scores.d.ts +19 -0
- package/dist/src/evals/runner/reporters/assertion-scores.js +1 -0
- package/dist/src/evals/runner/reporters/braintrust.js +1 -1
- package/dist/src/evals/runner/reporters/datadog-client.d.ts +123 -0
- package/dist/src/evals/runner/reporters/datadog-client.js +4 -0
- package/dist/src/evals/runner/reporters/datadog.d.ts +9 -98
- package/dist/src/evals/runner/reporters/datadog.js +2 -3
- package/dist/src/evals/session-content.js +1 -1
- package/dist/src/evals/session.d.ts +4 -4
- package/dist/src/evals/session.js +2 -2
- package/dist/src/evals/types.d.ts +18 -15
- package/dist/src/eve-channel/create-request.d.ts +5 -4
- package/dist/src/eve-channel/create-request.js +1 -1
- package/dist/src/eve-channel/index.d.ts +0 -9
- package/dist/src/eve-channel/index.js +1 -1
- package/dist/src/eve-channel/request.d.ts +3 -7
- package/dist/src/eve-channel/request.js +1 -1
- package/dist/src/eve-channel/support.d.ts +15 -5
- package/dist/src/eve-channel/support.js +1 -1
- package/dist/src/eve-channel/turn-policy-request.d.ts +2 -0
- package/dist/src/eve-channel/turn-policy-request.js +1 -0
- package/dist/src/eve-channel/types.d.ts +4 -0
- package/dist/src/execution/agent-sessions/context.d.ts +60 -0
- package/dist/src/execution/agent-sessions/context.js +1 -0
- package/dist/src/{subagents/remote-dispatch.d.ts → execution/agent-sessions/remote.d.ts} +17 -40
- package/dist/src/execution/agent-sessions/remote.js +1 -0
- package/dist/src/execution/agent-sessions/requests.d.ts +20 -0
- package/dist/src/execution/agent-sessions/requests.js +1 -0
- package/dist/src/execution/agent-sessions/session.d.ts +12 -0
- package/dist/src/execution/agent-sessions/session.js +1 -0
- package/dist/src/execution/agent-sessions/steps.d.ts +59 -0
- package/dist/src/execution/agent-sessions/steps.js +1 -0
- package/dist/src/execution/agent-sessions/target.d.ts +45 -0
- package/dist/src/execution/agent-sessions/target.js +1 -0
- package/dist/src/execution/agent-sessions/usage.d.ts +18 -0
- package/dist/src/execution/agent-sessions/usage.js +1 -0
- package/dist/src/execution/authorization-callback-match.d.ts +2 -4
- package/dist/src/execution/authorization-callback-match.js +1 -1
- package/dist/src/execution/cancel-descendant-turns-step.d.ts +1 -5
- package/dist/src/execution/cancel-descendant-turns-step.js +1 -1
- package/dist/src/execution/cancelled-model-call-batch.js +1 -1
- package/dist/src/execution/connection-announcement.d.ts +7 -0
- package/dist/src/execution/connection-announcement.js +4 -0
- package/dist/src/execution/continuation-conflict-step.d.ts +2 -3
- package/dist/src/execution/continuation-conflict-step.js +1 -1
- package/dist/src/execution/coordination-dispatch-shared.d.ts +9 -27
- package/dist/src/execution/coordination-dispatch-shared.js +1 -1
- package/dist/src/execution/coordination-dispatch-step.d.ts +3 -2
- package/dist/src/execution/coordination-dispatch-step.js +1 -1
- package/dist/src/execution/create-session-step.d.ts +0 -1
- package/dist/src/execution/create-session-step.js +1 -1
- package/dist/src/execution/deliver-payloads.js +1 -1
- package/dist/src/execution/durable-session-store.d.ts +0 -1
- package/dist/src/execution/dynamic-connections.js +1 -1
- package/dist/src/execution/dynamic-workflow/program-step.js +1 -1
- package/dist/src/execution/dynamic-workflow/schema.d.ts +1 -3
- package/dist/src/execution/dynamic-workflow/schema.js +1 -1
- package/dist/src/execution/dynamic-workflow/tool.d.ts +1 -1
- package/dist/src/execution/dynamic-workflow/tool.js +1 -1
- package/dist/src/execution/dynamic-workflow/workflow.js +1 -1
- package/dist/src/execution/forward-session-input.d.ts +4 -0
- package/dist/src/execution/forward-session-input.js +1 -0
- package/dist/src/execution/legacy-remote-agent/protocol.d.ts +41 -0
- package/dist/src/execution/legacy-remote-agent/protocol.js +1 -0
- package/dist/src/execution/legacy-session/authorization.js +1 -1
- package/dist/src/execution/legacy-session/completion-step.js +1 -1
- package/dist/src/execution/legacy-session/inbox.js +1 -1
- package/dist/src/execution/legacy-session/input.js +1 -1
- package/dist/src/execution/legacy-session/interrupt-step.js +1 -1
- package/dist/src/execution/model-call-batching.js +1 -1
- package/dist/src/execution/node-step.d.ts +1 -1
- package/dist/src/execution/node-step.js +1 -1
- package/dist/src/execution/proxied-deliver-step.d.ts +9 -6
- package/dist/src/execution/proxied-deliver-step.js +1 -1
- package/dist/src/execution/publish-session-events.d.ts +130 -0
- package/dist/src/execution/publish-session-events.js +1 -0
- package/dist/src/execution/route-child-delivery.d.ts +5 -4
- package/dist/src/execution/route-child-delivery.js +1 -3
- package/dist/src/execution/runtime-context.js +1 -1
- package/dist/src/execution/sandbox/prewarm.js +1 -1
- package/dist/src/execution/session/admission.d.ts +1 -12
- package/dist/src/execution/session/admission.js +1 -1
- package/dist/src/execution/session/entry-input.d.ts +0 -2
- package/dist/src/execution/session/entry.js +1 -1
- package/dist/src/execution/session/finalization.js +1 -1
- package/dist/src/execution/session/handoff-steps.d.ts +13 -2
- package/dist/src/execution/session/handoff-steps.js +1 -1
- package/dist/src/execution/session/handoff.d.ts +17 -3
- package/dist/src/execution/session/handoff.js +1 -1
- package/dist/src/execution/session/input-queue.d.ts +27 -28
- package/dist/src/execution/session/input-queue.js +1 -1
- package/dist/src/execution/session/next-input.d.ts +5 -0
- package/dist/src/execution/session/next-input.js +1 -1
- package/dist/src/execution/session/pending-turn-state.d.ts +2 -0
- package/dist/src/execution/session/pending-turn-state.js +1 -1
- package/dist/src/execution/session/principal.d.ts +14 -0
- package/dist/src/execution/session/principal.js +1 -0
- package/dist/src/execution/session/program.js +1 -1
- package/dist/src/execution/session/route-selected-delivery.js +1 -1
- package/dist/src/execution/session/state-cursor.d.ts +17 -15
- package/dist/src/execution/session/state-cursor.js +1 -1
- package/dist/src/execution/session/state-delta.d.ts +33 -0
- package/dist/src/execution/session/state-delta.js +1 -0
- package/dist/src/execution/session/timeout-steps.js +1 -1
- package/dist/src/execution/session/turn-event-handler.d.ts +27 -0
- package/dist/src/execution/session/turn-event-handler.js +1 -0
- package/dist/src/execution/session/turn-step-result.d.ts +1 -3
- package/dist/src/execution/session/turn-step-result.js +1 -1
- package/dist/src/execution/session/turn-step-types.d.ts +24 -15
- package/dist/src/execution/session/turn-step.d.ts +2 -2
- package/dist/src/execution/session/turn-step.js +1 -1
- package/dist/src/execution/session/turn-waiting-step.d.ts +4 -0
- package/dist/src/execution/session/turn-waiting-step.js +1 -0
- package/dist/src/execution/session/turn.d.ts +33 -2
- package/dist/src/execution/session/turn.js +1 -1
- package/dist/src/execution/session-callback-request.js +1 -1
- package/dist/src/execution/session-event-stream.d.ts +33 -0
- package/dist/src/execution/session-event-stream.js +1 -0
- package/dist/src/execution/session-inbox/inbox.d.ts +2 -0
- package/dist/src/execution/session-inbox/inbox.js +1 -1
- package/dist/src/execution/session-inbox/protocol.js +1 -1
- package/dist/src/execution/session-inbox/release-step.js +1 -1
- package/dist/src/execution/session-inbox/resume.js +1 -1
- package/dist/src/execution/session-workflow-tool-run.d.ts +11 -2
- package/dist/src/execution/session-workflow-tool-run.js +1 -1
- package/dist/src/execution/session.d.ts +0 -1
- package/dist/src/execution/session.js +2 -2
- package/dist/src/execution/settle-cancelled-turn-step.d.ts +21 -9
- package/dist/src/execution/settle-cancelled-turn-step.js +1 -1
- package/dist/src/execution/stable-workflow-names.d.ts +0 -1
- package/dist/src/execution/stable-workflow-names.js +1 -1
- package/dist/src/execution/tasks/calls.d.ts +42 -0
- package/dist/src/execution/tasks/calls.js +1 -0
- package/dist/src/execution/tasks/model-step.d.ts +58 -0
- package/dist/src/execution/tasks/model-step.js +1 -0
- package/dist/src/execution/tasks/render.d.ts +66 -0
- package/dist/src/execution/tasks/render.js +8 -0
- package/dist/src/execution/tasks/session.d.ts +19 -0
- package/dist/src/execution/tasks/session.js +1 -0
- package/dist/src/execution/tasks/start.d.ts +34 -0
- package/dist/src/execution/tasks/start.js +1 -0
- package/dist/src/execution/tasks/steps.d.ts +31 -0
- package/dist/src/execution/tasks/steps.js +1 -0
- package/dist/src/execution/tasks/table.d.ts +192 -0
- package/dist/src/execution/tasks/table.js +1 -0
- package/dist/src/execution/tasks/task-id-input.d.ts +19 -0
- package/dist/src/execution/tasks/task-id-input.js +1 -0
- package/dist/src/execution/tasks/tool-entry-point.d.ts +11 -0
- package/dist/src/execution/tasks/tool-entry-point.js +1 -0
- package/dist/src/execution/tasks/workflow-target.d.ts +2 -0
- package/dist/src/execution/tasks/workflow-target.js +1 -1
- package/dist/src/execution/terminal-session-completion-step.js +1 -1
- package/dist/src/execution/terminal-session-failure-step.js +1 -1
- package/dist/src/execution/terminate-child-sessions-step.d.ts +2 -9
- package/dist/src/execution/terminate-child-sessions-step.js +1 -1
- package/dist/src/execution/tool-auth.js +1 -1
- package/dist/src/execution/tools/agent-router-workflow.d.ts +1 -1
- package/dist/src/execution/tools/agent-router-workflow.js +1 -1
- package/dist/src/execution/tools/agent-router.d.ts +1 -1
- package/dist/src/execution/tools/agent-router.js +1 -1
- package/dist/src/execution/tools/connection-approval.d.ts +25 -0
- package/dist/src/execution/tools/connection-approval.js +1 -0
- package/dist/src/execution/tools/connection-search-rank.d.ts +21 -0
- package/dist/src/execution/tools/connection-search-rank.js +1 -0
- package/dist/src/execution/tools/connection-target.d.ts +13 -0
- package/dist/src/execution/tools/connection-target.js +1 -0
- package/dist/src/execution/tools/connection-tools.d.ts +10 -0
- package/dist/src/execution/tools/connection-tools.js +2 -0
- package/dist/src/execution/tools/load-skill.js +1 -1
- package/dist/src/execution/tools/workflow/answer.d.ts +10 -4
- package/dist/src/execution/tools/workflow/answer.js +1 -1
- package/dist/src/execution/tools/workflow/ask.d.ts +73 -10
- package/dist/src/execution/tools/workflow/ask.js +1 -1
- package/dist/src/execution/tools/workflow/body.d.ts +60 -19
- package/dist/src/execution/tools/workflow/body.js +1 -1
- package/dist/src/execution/tools/workflow/cancel.d.ts +7 -2
- package/dist/src/execution/tools/workflow/cancel.js +1 -1
- package/dist/src/execution/tools/workflow/emit-workflow-tool-run-report-step.d.ts +10 -4
- package/dist/src/execution/tools/workflow/emit-workflow-tool-run-report-step.js +1 -1
- package/dist/src/execution/tools/workflow/{background.d.ts → harness-definition.d.ts} +6 -6
- package/dist/src/execution/tools/workflow/harness-definition.js +1 -0
- package/dist/src/execution/tools/workflow/interrupt.d.ts +6 -0
- package/dist/src/execution/tools/workflow/interrupt.js +1 -0
- package/dist/src/execution/tools/workflow/messages.d.ts +135 -10
- package/dist/src/execution/tools/workflow/messages.js +1 -1
- package/dist/src/execution/tools/workflow/owner-inbox.js +1 -1
- package/dist/src/execution/tools/workflow/owner.d.ts +15 -4
- package/dist/src/execution/tools/workflow/owner.js +1 -1
- package/dist/src/execution/tools/workflow/serve.d.ts +3 -0
- package/dist/src/execution/tools/workflow/serve.js +1 -0
- package/dist/src/execution/tools/workflow/start.d.ts +18 -11
- package/dist/src/execution/tools/workflow/start.js +1 -1
- package/dist/src/execution/tools/workflow/step-execution.js +1 -1
- package/dist/src/execution/tools/workflow/step.js +1 -1
- package/dist/src/execution/tools/workflow/types.d.ts +0 -10
- package/dist/src/execution/tools/workflow/withdraw-step.d.ts +31 -0
- package/dist/src/execution/tools/workflow/withdraw-step.js +1 -0
- package/dist/src/execution/tools/workflow/workflow-owner-blocking.d.ts +3 -5
- package/dist/src/execution/tools/workflow/workflow-owner-blocking.js +1 -1
- package/dist/src/execution/tools/workflow/workflow.d.ts +3 -3
- package/dist/src/execution/tools/workflow/workflow.js +1 -1
- package/dist/src/execution/web-fetch/request.js +1 -1
- package/dist/src/execution/workflow-callback-url.d.ts +0 -5
- package/dist/src/execution/workflow-callback-url.js +1 -1
- package/dist/src/execution/workflow-runtime.d.ts +3 -5
- package/dist/src/execution/workflow-runtime.js +1 -1
- package/dist/src/execution/workflow-webhook-route.js +1 -1
- package/dist/src/extensions/code/extension/lib/connect-authentication.js +1 -1
- package/dist/src/extensions/code/extension/lib/github-shell.js +1 -1
- package/dist/src/extensions/code/extension/lib/prwatch-github.js +1 -1
- package/dist/src/extensions/code/extension/lib/sandbox.d.ts +3 -2
- package/dist/src/extensions/code/extension/lib/sandbox.js +1 -1
- package/dist/src/extensions/code/extension/lib/signed-commit.d.ts +1 -1
- package/dist/src/extensions/code/extension/lib/signed-commit.js +2 -2
- package/dist/src/extensions/code/tools.d.ts +2 -1
- package/dist/src/extensions/code/tools.js +1 -1
- package/dist/src/framework/sources/modules/agent.d.ts +1 -0
- package/dist/src/framework/sources/modules/agent.js +1 -1
- package/dist/src/framework/sources/registry.js +1 -1
- package/dist/src/harness/action-presentation.js +1 -1
- package/dist/src/harness/action-result-helpers.d.ts +1 -0
- package/dist/src/harness/action-result-helpers.js +1 -1
- package/dist/src/harness/advertised-tools.d.ts +1 -1
- package/dist/src/harness/advertised-tools.js +1 -1
- package/dist/src/harness/announcements.d.ts +22 -0
- package/dist/src/harness/announcements.js +1 -0
- package/dist/src/harness/approval-candidates.d.ts +10 -2
- package/dist/src/harness/approval-candidates.js +1 -1
- package/dist/src/harness/approval-delivery-coordinator.d.ts +4 -5
- package/dist/src/harness/approval-delivery-coordinator.js +1 -1
- package/dist/src/harness/approval-recheck.d.ts +7 -0
- package/dist/src/harness/approval-recheck.js +1 -0
- package/dist/src/harness/authorization-event-fields.d.ts +13 -0
- package/dist/src/harness/authorization-event-fields.js +1 -0
- package/dist/src/harness/authorization.d.ts +2 -1
- package/dist/src/harness/authorization.js +1 -1
- package/dist/src/harness/coordination.d.ts +31 -27
- package/dist/src/harness/coordination.js +1 -1
- package/dist/src/harness/current-messages.d.ts +6 -1
- package/dist/src/harness/current-messages.js +1 -1
- package/dist/src/harness/emission.d.ts +7 -1
- package/dist/src/harness/emission.js +1 -1
- package/dist/src/harness/execute-tool.d.ts +4 -15
- package/dist/src/harness/hitl/session-limit-input-requests.d.ts +2 -0
- package/dist/src/harness/hitl/session-limit-input-requests.js +1 -1
- package/dist/src/harness/input-request-resolution.d.ts +5 -2
- package/dist/src/harness/input-request-resolution.js +1 -1
- package/dist/src/harness/input-requests.js +1 -1
- package/dist/src/harness/messages.d.ts +11 -3
- package/dist/src/harness/messages.js +1 -1
- package/dist/src/harness/nested-actions.d.ts +23 -0
- package/dist/src/harness/nested-actions.js +1 -0
- package/dist/src/harness/pending-input-batches.d.ts +8 -6
- package/dist/src/harness/pending-input-batches.js +1 -1
- package/dist/src/harness/provider-tool-history.d.ts +7 -2
- package/dist/src/harness/provider-tool-history.js +1 -1
- package/dist/src/harness/proxy-input-requests.d.ts +41 -36
- package/dist/src/harness/proxy-input-requests.js +1 -1
- package/dist/src/harness/session-limit-enforcement.js +1 -1
- package/dist/src/harness/stale-input-responses.js +1 -1
- package/dist/src/harness/step-hooks.js +1 -1
- package/dist/src/harness/tool-loop.js +2 -2
- package/dist/src/harness/tool-model-output.js +1 -1
- package/dist/src/harness/tool-presentation.js +1 -1
- package/dist/src/harness/tools.d.ts +1 -5
- package/dist/src/harness/tools.js +1 -1
- package/dist/src/harness/turn-tag-state.d.ts +6 -5
- package/dist/src/harness/types.d.ts +7 -15
- package/dist/src/harness/workflow-dispatch.d.ts +30 -0
- package/dist/src/harness/workflow-dispatch.js +1 -0
- package/dist/src/harness/workflow-tool-runs.d.ts +5 -65
- package/dist/src/harness/workflow-tool-runs.js +1 -1
- package/dist/src/instrumentation/ai-sdk-hook-bridge.js +1 -1
- package/dist/src/instrumentation/lifecycle.d.ts +5 -2
- package/dist/src/instrumentation/lifecycle.js +1 -1
- package/dist/src/instrumentation/native-events.d.ts +0 -7
- package/dist/src/instrumentation/native-events.js +1 -1
- package/dist/src/instrumentation/runtime.d.ts +1 -4
- package/dist/src/instrumentation/runtime.js +1 -1
- package/dist/src/instrumentation/state.d.ts +0 -6
- package/dist/src/instrumentation/state.js +1 -1
- package/dist/src/internal/application/package.js +1 -1
- package/dist/src/internal/authored-definition/schema-backed.d.ts +10 -0
- package/dist/src/internal/authored-definition/schema-backed.js +1 -1
- package/dist/src/internal/authored-module-loader.d.ts +12 -6
- package/dist/src/internal/authored-module-loader.js +2 -2
- package/dist/src/internal/authored-module-map-loader.js +1 -1
- package/dist/src/internal/authored-package-boundary.d.ts +3 -0
- package/dist/src/internal/authored-package-boundary.js +1 -1
- package/dist/src/internal/bundler/extension-mount-plugin.d.ts +14 -0
- package/dist/src/internal/bundler/extension-mount-plugin.js +1 -0
- package/dist/src/internal/bundler/extension-scope-plugin.d.ts +8 -11
- package/dist/src/internal/bundler/extension-scope-plugin.js +2 -3
- package/dist/src/internal/invocation/workflow-execution.d.ts +2 -2
- package/dist/src/internal/invocation/workflow-execution.js +1 -1
- package/dist/src/internal/mount-state.d.ts +1 -0
- package/dist/src/internal/mount-state.js +1 -0
- package/dist/src/internal/nitro/dev-runtime-artifacts-retention.d.ts +2 -2
- package/dist/src/internal/nitro/dev-runtime-artifacts-retention.js +1 -1
- package/dist/src/internal/nitro/dev-runtime-artifacts.d.ts +2 -4
- package/dist/src/internal/nitro/dev-runtime-artifacts.js +1 -1
- package/dist/src/internal/nitro/dev-runtime-generation-metadata.d.ts +13 -0
- package/dist/src/internal/nitro/dev-runtime-generation-metadata.js +1 -0
- package/dist/src/internal/nitro/development-generation.d.ts +2 -0
- package/dist/src/internal/nitro/development-generation.js +1 -1
- package/dist/src/internal/nitro/host/build-application.js +1 -1
- package/dist/src/internal/nitro/host/create-application-nitro.js +1 -1
- package/dist/src/internal/nitro/host/dev-authored-rebuild-coordinator.d.ts +1 -0
- package/dist/src/internal/nitro/host/dev-authored-rebuild-coordinator.js +1 -1
- package/dist/src/internal/nitro/host/dev-host-fingerprint.js +1 -1
- package/dist/src/internal/nitro/host/dev-workflow-world-setup.d.ts +1 -0
- package/dist/src/internal/nitro/host/dev-workflow-world-setup.js +1 -1
- package/dist/src/internal/nitro/host/extension-capability-requirements.js +1 -1
- package/dist/src/internal/nitro/host/start-development-server.js +1 -1
- package/dist/src/internal/nitro/host/types.d.ts +2 -0
- package/dist/src/internal/nitro/host/workspace-extensions.js +1 -1
- package/dist/src/internal/nitro/routes/runtime-stack.js +1 -1
- package/dist/src/internal/node-esm-compat-banner.js +1 -1
- package/dist/src/internal/workflow/cancel-expired-development-run.d.ts +2 -0
- package/dist/src/internal/workflow/cancel-expired-development-run.js +1 -0
- package/dist/src/internal/workflow/development-runtime-compatibility.d.ts +12 -0
- package/dist/src/internal/workflow/development-runtime-compatibility.js +1 -0
- package/dist/src/internal/workflow/development-world-client.js +1 -1
- package/dist/src/internal/workflow/development-world-protocol.d.ts +9 -0
- package/dist/src/internal/workflow/development-world-server.d.ts +2 -0
- package/dist/src/internal/workflow/development-world-server.js +1 -1
- package/dist/src/internal/workflow/is-inactive-workflow-run-error.d.ts +2 -0
- package/dist/src/internal/workflow/is-inactive-workflow-run-error.js +1 -0
- package/dist/src/internal/workflow-bundle/authored-workflow-directives.d.ts +4 -3
- package/dist/src/internal/workflow-bundle/authored-workflow-directives.js +1 -1
- package/dist/src/internal/workflow-bundle/builder.js +1 -1
- package/dist/src/internal/workflow-bundle/dynamic-capability-transform-plugin.js +1 -1
- package/dist/src/internal/workflow-bundle/workflow-builders.js +1 -1
- package/dist/src/models/auto.d.ts +6 -0
- package/dist/src/models/auto.js +2 -2
- package/dist/src/protocol/message-version.d.ts +1 -0
- package/dist/src/protocol/message-version.js +1 -1
- package/dist/src/protocol/message.d.ts +126 -67
- package/dist/src/protocol/message.js +2 -2
- package/dist/src/protocol/remote-agent-protocol.d.ts +16 -0
- package/dist/src/protocol/remote-agent-protocol.js +1 -0
- package/dist/src/protocol/routes.d.ts +0 -6
- package/dist/src/protocol/routes.js +1 -1
- package/dist/src/protocol/task-tools.d.ts +21 -0
- package/dist/src/protocol/task-tools.js +1 -0
- package/dist/src/public/channels/auth.js +1 -1
- package/dist/src/public/channels/chat-sdk/chatSdkChannel.d.ts +25 -16
- package/dist/src/public/channels/chat-sdk/chatSdkChannel.js +2 -2
- package/dist/src/public/channels/chat-sdk/index.d.ts +1 -1
- package/dist/src/public/channels/chat-sdk/input-actions.d.ts +8 -0
- package/dist/src/public/channels/chat-sdk/input-actions.js +1 -0
- package/dist/src/public/channels/index.d.ts +1 -1
- package/dist/src/public/channels/linq/linqChannel.js +1 -1
- package/dist/src/public/channels/photon/photonIMessageChannel.js +1 -1
- package/dist/src/public/channels/slack/action-status.d.ts +11 -12
- package/dist/src/public/channels/slack/action-status.js +1 -1
- package/dist/src/public/channels/slack/api.js +1 -1
- package/dist/src/public/channels/slack/attachments.js +1 -1
- package/dist/src/public/channels/slack/auth.d.ts +3 -0
- package/dist/src/public/channels/slack/auth.js +1 -1
- package/dist/src/public/channels/slack/connections.d.ts +6 -6
- package/dist/src/public/channels/slack/connections.js +1 -1
- package/dist/src/public/channels/slack/defaults.d.ts +13 -19
- package/dist/src/public/channels/slack/defaults.js +4 -4
- package/dist/src/public/channels/slack/hitl.d.ts +22 -13
- package/dist/src/public/channels/slack/hitl.js +2 -2
- package/dist/src/public/channels/slack/index.d.ts +4 -3
- package/dist/src/public/channels/slack/index.js +1 -1
- package/dist/src/public/channels/slack/input-response.d.ts +1 -5
- package/dist/src/public/channels/slack/input-response.js +1 -1
- package/dist/src/public/channels/slack/interaction-cards.js +1 -1
- package/dist/src/public/channels/slack/interactions.js +1 -1
- package/dist/src/public/channels/slack/renderers.d.ts +76 -0
- package/dist/src/public/channels/slack/renderers.js +1 -0
- package/dist/src/public/channels/slack/session-operations.d.ts +6 -0
- package/dist/src/public/channels/slack/session-operations.js +1 -1
- package/dist/src/public/channels/slack/slackChannel.d.ts +47 -103
- package/dist/src/public/channels/slack/slackChannel.js +1 -1
- package/dist/src/public/channels/slack/task-card.d.ts +24 -0
- package/dist/src/public/channels/slack/task-card.js +1 -0
- package/dist/src/public/channels/telegram/hitl.d.ts +7 -1
- package/dist/src/public/channels/telegram/hitl.js +2 -1
- package/dist/src/public/channels/telegram/state.js +1 -1
- package/dist/src/public/channels/telegram/telegramChannel.d.ts +5 -0
- package/dist/src/public/channels/telegram/telegramChannel.js +1 -1
- package/dist/src/public/definitions/channel.d.ts +6 -1
- package/dist/src/public/definitions/channel.js +1 -1
- package/dist/src/public/definitions/connections/mcp.d.ts +4 -6
- package/dist/src/public/definitions/connections/openapi.d.ts +7 -8
- package/dist/src/public/definitions/extension.d.ts +2 -2
- package/dist/src/public/definitions/extension.js +1 -1
- package/dist/src/public/definitions/hook.d.ts +16 -4
- package/dist/src/public/definitions/state.d.ts +4 -2
- package/dist/src/public/definitions/state.js +1 -1
- package/dist/src/public/memory/index.d.ts +0 -1
- package/dist/src/public/models/openai/index.d.ts +1 -1
- package/dist/src/public/models/openai/index.js +1 -1
- package/dist/src/public/schedules/index.d.ts +1 -0
- package/dist/src/public/schedules/index.js +1 -1
- package/dist/src/public/server/index.d.ts +28 -0
- package/dist/src/public/server/index.js +1 -0
- package/dist/src/public/tools/index.d.ts +3 -2
- package/dist/src/public/tools/index.js +1 -1
- package/dist/src/public/tools/no-reply.d.ts +1 -0
- package/dist/src/public/tools/no-reply.js +1 -0
- package/dist/src/runtime/agent/bootstrap-model-utils.d.ts +6 -7
- package/dist/src/runtime/agent/bootstrap-model-utils.js +1 -1
- package/dist/src/runtime/agent/bootstrap.d.ts +0 -1
- package/dist/src/runtime/agent/bootstrap.js +1 -1
- package/dist/src/runtime/agent/mock-model-adapter.js +1 -1
- package/dist/src/runtime/agent/mock-model-fixtures.d.ts +1 -1
- package/dist/src/runtime/agent/mock-model-fixtures.js +2 -2
- package/dist/src/runtime/channels/registry.js +1 -1
- package/dist/src/runtime/connections/mcp-client.d.ts +1 -2
- package/dist/src/runtime/connections/openapi-client.js +1 -1
- package/dist/src/runtime/connections/scoped-authorization.d.ts +1 -1
- package/dist/src/runtime/connections/scoped-authorization.js +1 -1
- package/dist/src/runtime/connections/tool-result.d.ts +27 -0
- package/dist/src/runtime/connections/tool-result.js +2 -0
- package/dist/src/runtime/connections/tool-signature.d.ts +14 -0
- package/dist/src/runtime/connections/tool-signature.js +1 -0
- package/dist/src/runtime/local-dev-capability.js +1 -1
- package/dist/src/runtime/prompt/compose.d.ts +1 -3
- package/dist/src/runtime/prompt/compose.js +3 -3
- package/dist/src/runtime/resolve-agent-graph.js +1 -1
- package/dist/src/runtime/resolve-tool.js +1 -1
- package/dist/src/runtime/sessions/compiled-agent-cache.js +1 -1
- package/dist/src/runtime/sessions/runtime-context-keys.js +1 -1
- package/dist/src/runtime/sessions/turn.d.ts +1 -16
- package/dist/src/runtime/subagents/dynamic-remote-agent-config.js +1 -1
- package/dist/src/runtime/subagents/registry.js +1 -1
- package/dist/src/runtime/subagents/workflow-reference.d.ts +6 -3
- package/dist/src/runtime/subagents/workflow-reference.js +1 -1
- package/dist/src/runtime/subagents/workflow.d.ts +12 -6
- package/dist/src/runtime/subagents/workflow.js +1 -1
- package/dist/src/runtime/tools/registry.js +1 -1
- package/dist/src/self-modification/extension/classify-registry-item.d.ts +3 -0
- package/dist/src/self-modification/extension/classify-registry-item.js +1 -1
- package/dist/src/self-modification/extension/subagents/agent/agent.d.ts +1 -1
- package/dist/src/self-modification/extension/subagents/agent/agent.js +1 -1
- package/dist/src/self-modification/extension/subagents/agent/instructions.js +7 -7
- package/dist/src/self-modification/extension/subagents/agent/tools/registry_add.js +1 -1
- package/dist/src/self-modification/extension/subagents/agent/tools/search_registry.d.ts +2 -0
- package/dist/src/self-modification/extension/subagents/agent/tools/search_registry.js +1 -1
- package/dist/src/self-modification/extension/subagents/agent/tools/search_traces.js +1 -1
- package/dist/src/self-modification/scaffold.d.ts +2 -0
- package/dist/src/self-modification/scaffold.js +7 -0
- package/dist/src/self-modification/setup.js +1 -7
- package/dist/src/setup/boxes/model-capabilities.d.ts +2 -2
- package/dist/src/setup/boxes/model-capabilities.js +1 -1
- package/dist/src/setup/boxes/select-model.js +1 -1
- package/dist/src/setup/integrations/shopify/templates.d.ts +1 -1
- package/dist/src/setup/integrations/shopify/templates.js +31 -19
- package/dist/src/setup/integrations/web/setup.d.ts +0 -2
- package/dist/src/setup/integrations/web/setup.js +3 -3
- package/dist/src/setup/scaffold/create/agent-paths.d.ts +5 -0
- package/dist/src/setup/scaffold/create/agent-paths.js +1 -0
- package/dist/src/setup/scaffold/create/instructions-template.d.ts +1 -0
- package/dist/src/setup/scaffold/create/instructions-template.js +8 -0
- package/dist/src/setup/scaffold/create/project.js +3 -10
- package/dist/src/setup/scaffold/create/web-template.d.ts +1 -1
- package/dist/src/setup/scaffold/create/web-template.js +1 -1
- package/dist/src/shared/action-request-name.d.ts +3 -0
- package/dist/src/shared/action-request-name.js +1 -0
- package/dist/src/shared/action-types.d.ts +49 -21
- package/dist/src/shared/action-types.js +1 -1
- package/dist/src/shared/agent-definition.d.ts +0 -7
- package/dist/src/shared/chatgpt-model.d.ts +1 -1
- package/dist/src/shared/chatgpt-model.js +1 -1
- package/dist/src/shared/connection-types.d.ts +2 -3
- package/dist/src/shared/default-agent-model.d.ts +10 -1
- package/dist/src/shared/default-agent-model.js +1 -1
- package/dist/src/shared/extension-mount.d.ts +2 -0
- package/dist/src/shared/extension-mount.js +1 -0
- package/dist/src/shared/format-duration.d.ts +2 -0
- package/dist/src/shared/format-duration.js +1 -0
- package/dist/src/shared/gateway-model-catalog.d.ts +25 -2
- package/dist/src/shared/gateway-model-catalog.js +1 -1
- package/dist/src/shared/input.d.ts +1 -0
- package/dist/src/shared/memory-state.d.ts +1 -0
- package/dist/src/shared/memory-state.js +1 -1
- package/dist/src/shared/model-helper.d.ts +2 -2
- package/dist/src/shared/model-helper.js +1 -1
- package/dist/src/shared/model-summary.d.ts +2 -6
- package/dist/src/shared/model-summary.js +1 -1
- package/dist/src/shared/presentation-text.d.ts +5 -0
- package/dist/src/shared/presentation-text.js +1 -1
- package/dist/src/shared/serialized-observability-state.d.ts +0 -4
- package/dist/src/shared/serialized-observability-state.js +1 -1
- package/dist/src/shared/value-delta.d.ts +39 -0
- package/dist/src/shared/value-delta.js +1 -0
- package/dist/src/subagents/adapter-state.d.ts +0 -2
- package/dist/src/subagents/adapter-state.js +1 -1
- package/dist/src/subagents/adapter.js +1 -1
- package/dist/src/subagents/callback-route.js +1 -1
- package/dist/src/subagents/event-proxy-step.d.ts +16 -29
- package/dist/src/subagents/event-proxy-step.js +1 -1
- package/dist/src/subagents/hitl-proxy.d.ts +35 -17
- package/dist/src/subagents/hitl-proxy.js +1 -1
- package/dist/src/subagents/invocation.d.ts +1 -2
- package/dist/src/subagents/parent-notification.d.ts +2 -1
- package/dist/src/subagents/parent-notification.js +1 -1
- package/dist/src/subagents/token-budget.d.ts +8 -9
- package/dist/src/subagents/token-budget.js +1 -1
- package/dist/src/subagents/tool.d.ts +6 -12
- package/dist/src/subagents/tool.js +1 -1
- package/dist/src/svelte/index.js +1 -1
- package/dist/src/svelte/use-eve-agent.js +1 -1
- package/dist/src/tools/behavior.d.ts +5 -5
- package/dist/src/tools/definition.d.ts +58 -14
- package/dist/src/tools/definition.js +1 -1
- package/dist/src/tools/durable-callbacks.d.ts +1 -1
- package/dist/src/tools/dynamic.d.ts +6 -0
- package/dist/src/tools/framework/agent-contract.d.ts +2 -5
- package/dist/src/tools/framework/agent-contract.js +1 -1
- package/dist/src/tools/framework/agent.d.ts +2 -5
- package/dist/src/tools/framework/agent.js +1 -1
- package/dist/src/tools/framework/connection-tools.d.ts +3 -0
- package/dist/src/tools/framework/connection-tools.js +1 -0
- package/dist/src/tools/provided/agent-router.d.ts +6 -3
- package/dist/src/tools/provided/agent-router.js +1 -1
- package/dist/src/{execution/tools → tools/provided}/ask-question-workflow.d.ts +3 -4
- package/dist/src/tools/provided/ask-question-workflow.js +1 -0
- package/dist/src/tools/provided/ask-question.d.ts +20 -5
- package/dist/src/tools/provided/ask-question.js +2 -1
- package/dist/src/tools/provided/interrupted.d.ts +18 -0
- package/dist/src/tools/provided/interrupted.js +1 -0
- package/dist/src/tools/provided/no-reply.d.ts +19 -0
- package/dist/src/tools/provided/no-reply.js +1 -0
- package/dist/src/tools/provided/sleep-workflow.d.ts +4 -0
- package/dist/src/tools/provided/sleep-workflow.js +1 -0
- package/dist/src/tools/provided/sleep.d.ts +11 -5
- package/dist/src/tools/provided/sleep.js +1 -1
- package/dist/src/tools/provided/task-cancel.d.ts +6 -0
- package/dist/src/tools/provided/task-cancel.js +1 -0
- package/dist/src/tools/provided/task-wait.d.ts +9 -0
- package/dist/src/tools/provided/task-wait.js +1 -0
- package/dist/src/tools/provided/workflow.d.ts +2 -2
- package/dist/src/tools/provided/workflow.js +1 -1
- package/dist/src/tools/schema-emission.d.ts +23 -0
- package/dist/src/tools/schema-emission.js +1 -0
- package/dist/src/tools/schema.d.ts +22 -8
- package/dist/src/tools/schema.js +1 -1
- package/dist/src/tools/workflow-definition.d.ts +187 -85
- package/dist/src/tools/workflow-definition.js +1 -1
- package/dist/src/tools/workflow-entry-point.d.ts +3 -0
- package/dist/src/tools/workflow-entry-point.js +1 -0
- package/dist/src/tracing/agent-action-instrumentation.d.ts +1 -3
- package/dist/src/tracing/agent-action-instrumentation.js +1 -1
- package/dist/src/tracing/agent-invocation-coordinator.d.ts +9 -18
- package/dist/src/tracing/agent-invocation-coordinator.js +1 -1
- package/dist/src/tracing/agent-otel-content.d.ts +0 -2
- package/dist/src/tracing/agent-otel-content.js +3 -3
- package/dist/src/tracing/agent-otel-provider.js +2 -2
- package/dist/src/tracing/agent-otel-runtime-context.d.ts +20 -0
- package/dist/src/tracing/agent-otel-runtime-context.js +1 -1
- package/dist/src/tracing/agent-otel-usage.js +1 -1
- package/dist/src/tracing/agent-span-contract.d.ts +1 -1
- package/dist/src/tracing/agent-span-contract.js +1 -1
- package/dist/src/tracing/agent-span-id-generator.d.ts +0 -1
- package/dist/src/tracing/agent-span-id-generator.js +1 -1
- package/dist/src/tracing/agent-trace-context-codec.d.ts +1 -2
- package/dist/src/tracing/agent-trace-context-codec.js +1 -1
- package/dist/src/tracing/agent-trace-context-store.d.ts +2 -27
- package/dist/src/tracing/agent-trace-context-store.js +1 -1
- package/dist/src/tracing/agent-trace-state.d.ts +1 -19
- package/dist/src/tracing/content-attributes.js +1 -1
- package/dist/src/tracing/install-instrumentation-runtime.js +1 -1
- package/dist/src/vue/index.js +1 -1
- package/dist/src/vue/use-eve-agent.js +1 -1
- package/docs/agent-config.md +36 -13
- package/docs/channels/chat-sdk.mdx +15 -4
- package/docs/channels/custom.mdx +89 -17
- package/docs/channels/eve.mdx +1 -1
- package/docs/channels/mcp.mdx +1 -1
- package/docs/channels/overview.mdx +14 -56
- package/docs/channels/slack.mdx +230 -35
- package/docs/channels/telegram.mdx +2 -0
- package/docs/concepts/built-in-tools.md +36 -28
- package/docs/concepts/context-control.md +2 -2
- package/docs/concepts/execution-model-and-durability.mdx +10 -11
- package/docs/concepts/project-structure.mdx +1 -1
- package/docs/concepts/sessions-runs-and-streaming.md +67 -47
- package/docs/connections/mcp.mdx +4 -4
- package/docs/connections/openapi.mdx +2 -2
- package/docs/connections/overview.mdx +2 -2
- package/docs/evals/assertions.mdx +5 -5
- package/docs/evals/cases.mdx +1 -1
- package/docs/evals/reporters.mdx +6 -4
- package/docs/extensions.md +11 -2
- package/docs/guides/auth-and-route-protection.md +1 -1
- package/docs/guides/client/streaming.mdx +31 -11
- package/docs/guides/deployment/vercel.mdx +1 -1
- package/docs/guides/dev-tui.md +13 -3
- package/docs/guides/dynamic-capabilities.md +15 -10
- package/docs/guides/evaluate.md +29 -2
- package/docs/guides/frontend/overview.mdx +5 -7
- package/docs/guides/hooks.md +48 -12
- package/docs/guides/instrumentation/instrumentation.mdx +2 -0
- package/docs/guides/remote-agents.md +12 -14
- package/docs/guides/self-modification.md +10 -0
- package/docs/install-integrations.mdx +1 -1
- package/docs/instructions.mdx +1 -1
- package/docs/patterns/multi-tenant-approvals.md +1 -1
- package/docs/protocols/ucp.mdx +20 -16
- package/docs/reference/cli.md +96 -22
- package/docs/reference/typescript-api.md +43 -41
- package/docs/schedules.mdx +14 -34
- package/docs/subagents/index.mdx +24 -56
- package/docs/tools/human-in-the-loop.md +50 -13
- package/docs/tools/meta.json +1 -1
- package/docs/tools/overview.mdx +79 -59
- package/docs/tools/tasks-upgrade.md +201 -0
- package/docs/tools/tasks.md +315 -0
- package/docs/tools/workflows.mdx +368 -154
- package/package.json +41 -14
- package/dist/src/channel/activity-renderer.d.ts +0 -21
- package/dist/src/channel/activity-renderer.js +0 -1
- package/dist/src/channel/activity-sink.d.ts +0 -2
- package/dist/src/channel/activity-sink.js +0 -1
- package/dist/src/eve-channel/activity-observer-request.d.ts +0 -7
- package/dist/src/eve-channel/activity-observer-request.js +0 -1
- package/dist/src/eve-channel/delivery-policy-request.d.ts +0 -4
- package/dist/src/eve-channel/delivery-policy-request.js +0 -1
- package/dist/src/execution/activity-cohort.d.ts +0 -20
- package/dist/src/execution/activity-cohort.js +0 -1
- package/dist/src/execution/activity-collector.d.ts +0 -12
- package/dist/src/execution/activity-collector.js +0 -1
- package/dist/src/execution/activity-events.d.ts +0 -8
- package/dist/src/execution/activity-events.js +0 -1
- package/dist/src/execution/activity-route.d.ts +0 -2
- package/dist/src/execution/activity-route.js +0 -1
- package/dist/src/execution/activity-work-id.d.ts +0 -9
- package/dist/src/execution/activity-work-id.js +0 -1
- package/dist/src/execution/activity-work.d.ts +0 -30
- package/dist/src/execution/activity-work.js +0 -1
- package/dist/src/execution/cancel-indexed-session-tasks-step.d.ts +0 -7
- package/dist/src/execution/cancel-indexed-session-tasks-step.js +0 -1
- package/dist/src/execution/dispatch-action-failures.d.ts +0 -8
- package/dist/src/execution/dispatch-action-failures.js +0 -1
- package/dist/src/execution/dispatch-start-operation.d.ts +0 -15
- package/dist/src/execution/dispatch-start-operation.js +0 -1
- package/dist/src/execution/publish-channel-event.d.ts +0 -23
- package/dist/src/execution/publish-channel-event.js +0 -1
- package/dist/src/execution/scheduled-launch-delivery.d.ts +0 -7
- package/dist/src/execution/scheduled-launch-delivery.js +0 -1
- package/dist/src/execution/session/event-sink.d.ts +0 -26
- package/dist/src/execution/session/event-sink.js +0 -1
- package/dist/src/execution/session-activity-projection.d.ts +0 -16
- package/dist/src/execution/session-activity-projection.js +0 -1
- package/dist/src/execution/session-activity-renderer-step.d.ts +0 -15
- package/dist/src/execution/session-activity-renderer-step.js +0 -1
- package/dist/src/execution/session-activity.d.ts +0 -3
- package/dist/src/execution/session-activity.js +0 -1
- package/dist/src/execution/submit-activity.d.ts +0 -7
- package/dist/src/execution/submit-activity.js +0 -1
- package/dist/src/execution/task-event-callback.d.ts +0 -12
- package/dist/src/execution/task-event-callback.js +0 -1
- package/dist/src/execution/task-input-capability.d.ts +0 -4
- package/dist/src/execution/task-input-capability.js +0 -1
- package/dist/src/execution/task-input-response-route.d.ts +0 -2
- package/dist/src/execution/task-input-response-route.js +0 -1
- package/dist/src/execution/tasks/child/notify.d.ts +0 -44
- package/dist/src/execution/tasks/child/notify.js +0 -1
- package/dist/src/execution/tasks/parent/control-shared.d.ts +0 -23
- package/dist/src/execution/tasks/parent/control-shared.js +0 -1
- package/dist/src/execution/tasks/parent/delegate.d.ts +0 -35
- package/dist/src/execution/tasks/parent/delegate.js +0 -1
- package/dist/src/execution/tasks/parent/dispatch.d.ts +0 -22
- package/dist/src/execution/tasks/parent/dispatch.js +0 -1
- package/dist/src/execution/tasks/parent/hitl-proxy-steps.d.ts +0 -27
- package/dist/src/execution/tasks/parent/hitl-proxy-steps.js +0 -1
- package/dist/src/execution/tasks/parent/run-parent.d.ts +0 -58
- package/dist/src/execution/tasks/parent/run-parent.js +0 -1
- package/dist/src/execution/tasks/parent/subagent-task-projection.d.ts +0 -26
- package/dist/src/execution/tasks/parent/subagent-task-projection.js +0 -1
- package/dist/src/execution/tasks/parent/task-cancel.d.ts +0 -12
- package/dist/src/execution/tasks/parent/task-cancel.js +0 -1
- package/dist/src/execution/tasks/parent/tool-execution.d.ts +0 -45
- package/dist/src/execution/tasks/parent/tool-execution.js +0 -1
- package/dist/src/execution/terminal-session-event.d.ts +0 -13
- package/dist/src/execution/terminal-session-event.js +0 -1
- package/dist/src/execution/tools/ask-question-workflow.js +0 -1
- package/dist/src/execution/tools/ask-question.d.ts +0 -19
- package/dist/src/execution/tools/ask-question.js +0 -2
- package/dist/src/execution/tools/connection-search.d.ts +0 -2
- package/dist/src/execution/tools/connection-search.js +0 -2
- package/dist/src/execution/tools/sleep-workflow.d.ts +0 -3
- package/dist/src/execution/tools/sleep-workflow.js +0 -1
- package/dist/src/execution/tools/sleep.d.ts +0 -10
- package/dist/src/execution/tools/sleep.js +0 -1
- package/dist/src/execution/tools/subagent/accept-event-step.d.ts +0 -7
- package/dist/src/execution/tools/subagent/accept-event-step.js +0 -1
- package/dist/src/execution/tools/subagent/emit-event-step.d.ts +0 -12
- package/dist/src/execution/tools/subagent/emit-event-step.js +0 -1
- package/dist/src/execution/tools/subagent/invoke-agent.d.ts +0 -42
- package/dist/src/execution/tools/subagent/invoke-agent.js +0 -1
- package/dist/src/execution/tools/subagent/invoke-preparation.d.ts +0 -44
- package/dist/src/execution/tools/subagent/invoke-preparation.js +0 -1
- package/dist/src/execution/tools/subagent/invoke-step.d.ts +0 -64
- package/dist/src/execution/tools/subagent/invoke-step.js +0 -1
- package/dist/src/execution/tools/subagent/receipt-identity.d.ts +0 -11
- package/dist/src/execution/tools/subagent/receipt-identity.js +0 -1
- package/dist/src/execution/tools/subagent/start.d.ts +0 -51
- package/dist/src/execution/tools/subagent/start.js +0 -1
- package/dist/src/execution/tools/subagent/steer.d.ts +0 -13
- package/dist/src/execution/tools/subagent/steer.js +0 -1
- package/dist/src/execution/tools/subagent/task-agent-requests.d.ts +0 -24
- package/dist/src/execution/tools/subagent/task-agent-requests.js +0 -1
- package/dist/src/execution/tools/subagent/task-cancel.d.ts +0 -10
- package/dist/src/execution/tools/subagent/task-cancel.js +0 -1
- package/dist/src/execution/tools/tasks.d.ts +0 -3
- package/dist/src/execution/tools/tasks.js +0 -1
- package/dist/src/execution/tools/workflow/background.js +0 -1
- package/dist/src/execution/tools/workflow/workflow-owner-background.d.ts +0 -14
- package/dist/src/execution/tools/workflow/workflow-owner-background.js +0 -1
- package/dist/src/extensions/code/extension/tools/computer_use.js +0 -1
- package/dist/src/harness/background-tools.d.ts +0 -45
- package/dist/src/harness/background-tools.js +0 -1
- package/dist/src/instrumentation/background-task-runtime.d.ts +0 -18
- package/dist/src/instrumentation/background-task-runtime.js +0 -1
- package/dist/src/node_modules/.pnpm/@vercel_cli-config@0.3.0/node_modules/@vercel/cli-config/dist/index.js +0 -21
- package/dist/src/node_modules/.pnpm/@vercel_cli-exec@1.0.1/node_modules/@vercel/cli-exec/dist/envpath.js +0 -1
- package/dist/src/node_modules/.pnpm/@vercel_cli-exec@1.0.1/node_modules/@vercel/cli-exec/dist/errors.js +0 -2
- package/dist/src/node_modules/.pnpm/@vercel_cli-exec@1.0.1/node_modules/@vercel/cli-exec/dist/errutils.js +0 -1
- package/dist/src/node_modules/.pnpm/@vercel_cli-exec@1.0.1/node_modules/@vercel/cli-exec/dist/exec.js +0 -1
- package/dist/src/node_modules/.pnpm/@vercel_cli-exec@1.0.1/node_modules/@vercel/cli-exec/dist/fsutils.js +0 -1
- package/dist/src/node_modules/.pnpm/@vercel_cli-exec@1.0.1/node_modules/@vercel/cli-exec/dist/index.js +0 -1
- package/dist/src/node_modules/.pnpm/@vercel_cli-exec@1.0.1/node_modules/@vercel/cli-exec/dist/lookup.js +0 -1
- package/dist/src/node_modules/.pnpm/@vercel_cli-exec@1.0.1/node_modules/@vercel/cli-exec/dist/safety.js +0 -1
- package/dist/src/node_modules/.pnpm/@vercel_connect@2.3.3_@ai-sdk_mcp@2.0.52_zod@4.5.4__@auth_core@0.41.2_@chat-adapter_sla_a37674779346d612fa7d2ca9bd316494/node_modules/@vercel/connect/dist/authorization.js +0 -1
- package/dist/src/node_modules/.pnpm/@vercel_connect@2.3.3_@ai-sdk_mcp@2.0.52_zod@4.5.4__@auth_core@0.41.2_@chat-adapter_sla_a37674779346d612fa7d2ca9bd316494/node_modules/@vercel/connect/dist/connector.js +0 -1
- package/dist/src/node_modules/.pnpm/@vercel_connect@2.3.3_@ai-sdk_mcp@2.0.52_zod@4.5.4__@auth_core@0.41.2_@chat-adapter_sla_a37674779346d612fa7d2ca9bd316494/node_modules/@vercel/connect/dist/index.js +0 -1
- package/dist/src/node_modules/.pnpm/@vercel_connect@2.3.3_@ai-sdk_mcp@2.0.52_zod@4.5.4__@auth_core@0.41.2_@chat-adapter_sla_a37674779346d612fa7d2ca9bd316494/node_modules/@vercel/connect/dist/installation.js +0 -1
- package/dist/src/node_modules/.pnpm/@vercel_connect@2.3.3_@ai-sdk_mcp@2.0.52_zod@4.5.4__@auth_core@0.41.2_@chat-adapter_sla_a37674779346d612fa7d2ca9bd316494/node_modules/@vercel/connect/dist/internal/base-url.js +0 -1
- package/dist/src/node_modules/.pnpm/@vercel_connect@2.3.3_@ai-sdk_mcp@2.0.52_zod@4.5.4__@auth_core@0.41.2_@chat-adapter_sla_a37674779346d612fa7d2ca9bd316494/node_modules/@vercel/connect/dist/internal/default-scopes.js +0 -1
- package/dist/src/node_modules/.pnpm/@vercel_connect@2.3.3_@ai-sdk_mcp@2.0.52_zod@4.5.4__@auth_core@0.41.2_@chat-adapter_sla_a37674779346d612fa7d2ca9bd316494/node_modules/@vercel/connect/dist/internal/env.js +0 -1
- package/dist/src/node_modules/.pnpm/@vercel_connect@2.3.3_@ai-sdk_mcp@2.0.52_zod@4.5.4__@auth_core@0.41.2_@chat-adapter_sla_a37674779346d612fa7d2ca9bd316494/node_modules/@vercel/connect/dist/internal/url-validation.js +0 -1
- package/dist/src/node_modules/.pnpm/@vercel_connect@2.3.3_@ai-sdk_mcp@2.0.52_zod@4.5.4__@auth_core@0.41.2_@chat-adapter_sla_a37674779346d612fa7d2ca9bd316494/node_modules/@vercel/connect/dist/token.js +0 -1
- package/dist/src/node_modules/.pnpm/@vercel_oidc@3.8.9/node_modules/@vercel/oidc/dist/auth-errors.js +0 -1
- package/dist/src/node_modules/.pnpm/@vercel_oidc@3.8.9/node_modules/@vercel/oidc/dist/exchange-vercel-oidc-token.js +0 -1
- package/dist/src/node_modules/.pnpm/@vercel_oidc@3.8.9/node_modules/@vercel/oidc/dist/get-context.js +0 -1
- package/dist/src/node_modules/.pnpm/@vercel_oidc@3.8.9/node_modules/@vercel/oidc/dist/get-vercel-oidc-token-sync.js +0 -1
- package/dist/src/node_modules/.pnpm/@vercel_oidc@3.8.9/node_modules/@vercel/oidc/dist/get-vercel-oidc-token-with-refresh.js +0 -2
- package/dist/src/node_modules/.pnpm/@vercel_oidc@3.8.9/node_modules/@vercel/oidc/dist/index.js +0 -1
- package/dist/src/node_modules/.pnpm/@vercel_oidc@3.8.9/node_modules/@vercel/oidc/dist/oauth.js +0 -1
- package/dist/src/node_modules/.pnpm/@vercel_oidc@3.8.9/node_modules/@vercel/oidc/dist/token-error.js +0 -1
- package/dist/src/node_modules/.pnpm/@vercel_oidc@3.8.9/node_modules/@vercel/oidc/dist/token-io.js +0 -1
- package/dist/src/node_modules/.pnpm/@vercel_oidc@3.8.9/node_modules/@vercel/oidc/dist/token-util.js +0 -2
- package/dist/src/node_modules/.pnpm/@vercel_oidc@3.8.9/node_modules/@vercel/oidc/dist/token.js +0 -1
- package/dist/src/node_modules/.pnpm/@vercel_oidc@3.8.9/node_modules/@vercel/oidc/dist/verify-vercel-oidc-token.js +0 -1
- package/dist/src/node_modules/.pnpm/@vercel_oidc@3.8.9/node_modules/@vercel/oidc/dist/version.js +0 -1
- package/dist/src/node_modules/.pnpm/cross-spawn@7.0.6/node_modules/cross-spawn/index.js +0 -1
- package/dist/src/node_modules/.pnpm/cross-spawn@7.0.6/node_modules/cross-spawn/lib/enoent.js +0 -1
- package/dist/src/node_modules/.pnpm/cross-spawn@7.0.6/node_modules/cross-spawn/lib/parse.js +0 -1
- package/dist/src/node_modules/.pnpm/cross-spawn@7.0.6/node_modules/cross-spawn/lib/util/escape.js +0 -1
- package/dist/src/node_modules/.pnpm/cross-spawn@7.0.6/node_modules/cross-spawn/lib/util/readShebang.js +0 -1
- package/dist/src/node_modules/.pnpm/cross-spawn@7.0.6/node_modules/cross-spawn/lib/util/resolveCommand.js +0 -1
- package/dist/src/node_modules/.pnpm/execa@5.1.1/node_modules/execa/index.js +0 -1
- package/dist/src/node_modules/.pnpm/execa@5.1.1/node_modules/execa/lib/command.js +0 -1
- package/dist/src/node_modules/.pnpm/execa@5.1.1/node_modules/execa/lib/error.js +0 -2
- package/dist/src/node_modules/.pnpm/execa@5.1.1/node_modules/execa/lib/kill.js +0 -1
- package/dist/src/node_modules/.pnpm/execa@5.1.1/node_modules/execa/lib/promise.js +0 -1
- package/dist/src/node_modules/.pnpm/execa@5.1.1/node_modules/execa/lib/stdio.js +0 -1
- package/dist/src/node_modules/.pnpm/execa@5.1.1/node_modules/execa/lib/stream.js +0 -1
- package/dist/src/node_modules/.pnpm/get-stream@6.0.1/node_modules/get-stream/buffer-stream.js +0 -1
- package/dist/src/node_modules/.pnpm/get-stream@6.0.1/node_modules/get-stream/index.js +0 -1
- package/dist/src/node_modules/.pnpm/human-signals@2.1.0/node_modules/human-signals/build/src/core.js +0 -1
- package/dist/src/node_modules/.pnpm/human-signals@2.1.0/node_modules/human-signals/build/src/main.js +0 -1
- package/dist/src/node_modules/.pnpm/human-signals@2.1.0/node_modules/human-signals/build/src/realtime.js +0 -1
- package/dist/src/node_modules/.pnpm/human-signals@2.1.0/node_modules/human-signals/build/src/signals.js +0 -1
- package/dist/src/node_modules/.pnpm/is-stream@2.0.1/node_modules/is-stream/index.js +0 -1
- package/dist/src/node_modules/.pnpm/isexe@2.0.0/node_modules/isexe/index.js +0 -1
- package/dist/src/node_modules/.pnpm/isexe@2.0.0/node_modules/isexe/mode.js +0 -1
- package/dist/src/node_modules/.pnpm/isexe@2.0.0/node_modules/isexe/windows.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/index.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwe/compact/decrypt.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwe/compact/encrypt.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwe/flattened/decrypt.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwe/flattened/encrypt.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwe/general/decrypt.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwe/general/encrypt.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwk/embedded.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwk/thumbprint.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwks/local.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwks/remote.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jws/compact/sign.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jws/compact/verify.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jws/flattened/sign.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jws/flattened/verify.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jws/general/sign.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jws/general/verify.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwt/decrypt.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwt/encrypt.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwt/produce.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwt/sign.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwt/unsecured.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwt/verify.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/key/export.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/key/generate_key_pair.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/key/generate_secret.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/key/import.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/aesgcmkw.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/buffer_utils.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/cek.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/check_iv_length.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/check_key_type.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/check_p2s.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/crypto_key.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/decrypt_key_management.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/encrypt_key_management.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/epoch.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/invalid_key_input.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/is_disjoint.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/is_jwk.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/is_object.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/iv.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/jwt_claims_set.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/private_symbols.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/secs.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/validate_algorithms.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/validate_crit.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/aeskw.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/asn1.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/base64url.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/cbc_tag.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/check_cek_length.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/check_key_length.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/ciphers.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/decrypt.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/digest.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/dsa_digest.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/ecdhes.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/encrypt.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/fetch_jwks.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/generate.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/get_named_curve.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/get_sign_verify_key.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/hmac_digest.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/is_key_like.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/is_key_object.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/jwk_to_key.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/key_to_jwk.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/node_key.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/normalize_key.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/pbes2kw.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/random.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/rsaes.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/runtime.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/sign.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/timing_safe_equal.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/verify.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/webcrypto.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/util/base64url.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/util/decode_jwt.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/util/decode_protected_header.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/util/errors.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/util/runtime.js +0 -1
- package/dist/src/node_modules/.pnpm/merge-stream@2.0.0/node_modules/merge-stream/index.js +0 -1
- package/dist/src/node_modules/.pnpm/mimic-fn@2.1.0/node_modules/mimic-fn/index.js +0 -1
- package/dist/src/node_modules/.pnpm/npm-run-path@4.0.1/node_modules/npm-run-path/index.js +0 -1
- package/dist/src/node_modules/.pnpm/onetime@5.1.2/node_modules/onetime/index.js +0 -1
- package/dist/src/node_modules/.pnpm/path-key@3.1.1/node_modules/path-key/index.js +0 -1
- package/dist/src/node_modules/.pnpm/shebang-command@2.0.0/node_modules/shebang-command/index.js +0 -1
- package/dist/src/node_modules/.pnpm/shebang-regex@3.0.0/node_modules/shebang-regex/index.js +0 -1
- package/dist/src/node_modules/.pnpm/signal-exit@3.0.7/node_modules/signal-exit/index.js +0 -1
- package/dist/src/node_modules/.pnpm/signal-exit@3.0.7/node_modules/signal-exit/signals.js +0 -1
- package/dist/src/node_modules/.pnpm/strip-final-newline@2.0.0/node_modules/strip-final-newline/index.js +0 -2
- package/dist/src/node_modules/.pnpm/which@2.0.2/node_modules/which/which.js +0 -1
- package/dist/src/protocol/activity.d.ts +0 -112
- package/dist/src/protocol/activity.js +0 -1
- package/dist/src/protocol/agent-handle-error.d.ts +0 -13
- package/dist/src/protocol/agent-handle-error.js +0 -1
- package/dist/src/public/channels/slack/activity-plan.d.ts +0 -5
- package/dist/src/public/channels/slack/activity-plan.js +0 -1
- package/dist/src/public/channels/slack/activity.d.ts +0 -63
- package/dist/src/public/channels/slack/activity.js +0 -2
- package/dist/src/public/tools/connection-search.d.ts +0 -1
- package/dist/src/public/tools/connection-search.js +0 -1
- package/dist/src/public/tools/task-cancel.d.ts +0 -1
- package/dist/src/public/tools/task-cancel.js +0 -1
- package/dist/src/runtime/prompt/connections.d.ts +0 -9
- package/dist/src/runtime/prompt/connections.js +0 -2
- package/dist/src/shared/boundary-hook-error.d.ts +0 -4
- package/dist/src/shared/boundary-hook-error.js +0 -1
- package/dist/src/shared/empty-delivery.d.ts +0 -3
- package/dist/src/shared/empty-delivery.js +0 -1
- package/dist/src/subagents/agent-handle-errors.d.ts +0 -25
- package/dist/src/subagents/agent-handle-errors.js +0 -1
- package/dist/src/subagents/callback-step.d.ts +0 -11
- package/dist/src/subagents/callback-step.js +0 -1
- package/dist/src/subagents/continuation-bundle.d.ts +0 -13
- package/dist/src/subagents/continuation-bundle.js +0 -1
- package/dist/src/subagents/handle-dispatch.d.ts +0 -65
- package/dist/src/subagents/handle-dispatch.js +0 -1
- package/dist/src/subagents/handles/operation-id.d.ts +0 -15
- package/dist/src/subagents/handles/operation-id.js +0 -1
- package/dist/src/subagents/handles/prompt.d.ts +0 -52
- package/dist/src/subagents/handles/prompt.js +0 -3
- package/dist/src/subagents/handles/query.d.ts +0 -41
- package/dist/src/subagents/handles/query.js +0 -1
- package/dist/src/subagents/handles/state-key.d.ts +0 -8
- package/dist/src/subagents/handles/state-key.js +0 -1
- package/dist/src/subagents/handles/store.d.ts +0 -217
- package/dist/src/subagents/handles/store.js +0 -1
- package/dist/src/subagents/handles/transitions.d.ts +0 -103
- package/dist/src/subagents/handles/transitions.js +0 -1
- package/dist/src/subagents/remote-dispatch.js +0 -1
- package/dist/src/subagents/start-local.d.ts +0 -29
- package/dist/src/subagents/start-local.js +0 -1
- package/dist/src/subagents/start-remote.d.ts +0 -21
- package/dist/src/subagents/start-remote.js +0 -1
- package/dist/src/tasks/delivery-context.d.ts +0 -32
- package/dist/src/tasks/delivery-context.js +0 -4
- package/dist/src/tasks/delivery-policy.d.ts +0 -14
- package/dist/src/tasks/delivery-policy.js +0 -1
- package/dist/src/tasks/json.d.ts +0 -88
- package/dist/src/tasks/json.js +0 -1
- package/dist/src/tasks/notification.d.ts +0 -10
- package/dist/src/tasks/notification.js +0 -1
- package/dist/src/tasks/task-id.d.ts +0 -31
- package/dist/src/tasks/task-id.js +0 -1
- package/dist/src/tasks/task-inbox-token.d.ts +0 -2
- package/dist/src/tasks/task-inbox-token.js +0 -1
- package/dist/src/tasks/transitions.d.ts +0 -17
- package/dist/src/tasks/transitions.js +0 -1
- package/dist/src/tasks/types.d.ts +0 -136
- package/dist/src/tasks/types.js +0 -1
- package/dist/src/tools/framework/connection-search.d.ts +0 -3
- package/dist/src/tools/framework/connection-search.js +0 -1
- package/dist/src/tools/framework/task-cancel.d.ts +0 -4
- package/dist/src/tools/framework/task-cancel.js +0 -1
- package/dist/src/tools/framework/task-contract.d.ts +0 -19
- package/dist/src/tools/framework/task-contract.js +0 -1
- package/dist/src/tools/native-definition.d.ts +0 -7
- package/dist/src/tools/native-definition.js +0 -1
- package/dist/src/tracing/agent-invocation-terminal.d.ts +0 -18
- package/dist/src/tracing/agent-invocation-terminal.js +0 -1
- /package/dist/src/{extensions/code → computer-use}/extension/lib/computer-use-driver-source.d.ts +0 -0
- /package/dist/src/{extensions/code → computer-use}/extension/lib/computer-use-driver-source.js +0 -0
- /package/dist/src/{extensions/code → computer-use}/extension/tools/computer_use.d.ts +0 -0
- /package/dist/src/execution/{tools/subagent → agent-sessions}/metadata.d.ts +0 -0
- /package/dist/src/execution/{tools/subagent → agent-sessions}/metadata.js +0 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
import{createLogger,logError}from"#internal/logging.js";import{
|
|
1
|
+
import{createLogger,logError}from"#internal/logging.js";import{getPendingCoordinationBatch}from"#harness/coordination.js";import{readDurableSession}from"#execution/durable-session-store.js";import{cancelWorkflowToolRun}from"#execution/tools/workflow/cancel.js";import{getBlockingWorkflowToolRuns}from"#harness/workflow-tool-runs.js";const log=createLogger(`execution.cancel-descendant-turns`);async function cancelDescendantTurnsStep(e){"use step";let t;try{let n=readDurableSession(e.sessionState);t=getBlockingWorkflowToolRuns(n.state,getPendingCoordinationBatch(n.state)?.event.turnId??e.sessionState.emissionState.turnId)}catch(t){logError(log,`failed to read pending descendants during cancellation`,t,{sessionId:e.sessionState.sessionId});return}await Promise.all(t.map(e=>cancelWorkflowToolRun(e.address,{kind:`cancel`,reason:`The turn that called the tool was cancelled.`})))}export{cancelDescendantTurnsStep};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{contextStorage}from"#context/container.js";import{TurnDeliveryIdsKey}from"#context/keys.js";import{
|
|
1
|
+
import{contextStorage}from"#context/container.js";import{TurnDeliveryIdsKey}from"#context/keys.js";import{createDurableSessionState}from"#execution/durable-session-store.js";import{preserveSerializedSessionDynamicModelSelection}from"#context/serialized-dynamic-model-selection.js";import{serializeContext}from"#context/serialize.js";import{preserveCancelledTurnMessage}from"#execution/cancelled-turn-message.js";import{preserveSerializedInstrumentationState}from"#instrumentation/state.js";import{preserveSerializedAgentTraceState}from"#tracing/agent-trace-context-store.js";async function createCancelledModelCallBatchResult(e){let t=serializeContext(e.ctx),n=e.checkpoint?.result.session??e.initialSession,r=e.checkpoint===void 0?await contextStorage.run(e.ctx,()=>preserveCancelledTurnMessage(n,e.stepInput)):n,i={...e.checkpoint?.serializedContext??e.beforeBatchContext,[TurnDeliveryIdsKey.name]:t[TurnDeliveryIdsKey.name]};return{action:`cancelled`,serializedContext:preserveSerializedInstrumentationState(preserveSerializedAgentTraceState(preserveSerializedSessionDynamicModelSelection(i,t),t),t),sessionState:createDurableSessionState({session:r})}}export{createCancelledModelCallBatchResult};
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import type { ContextContainer } from "#context/container.js";
|
|
2
|
+
/**
|
|
3
|
+
* Announces the agent's connections for the current step: a baseline listing
|
|
4
|
+
* the first time, then only what changed. Tool names and signatures stay out
|
|
5
|
+
* of the listing; `connection_search` returns them.
|
|
6
|
+
*/
|
|
7
|
+
export declare function announceConnections(ctx: ContextContainer): void;
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import{ConnectionRegistryKey}from"#context/providers/connection-key.js";import{setPendingAnnouncement}from"#harness/announcements.js";const ANNOUNCEMENT_KEY=`connections`;function announceConnections(e){let t=e.get(ConnectionRegistryKey);if(t===void 0){setPendingAnnouncement(e,ANNOUNCEMENT_KEY,void 0);return}let n=t.getConnections().map(e=>({description:e.description,name:e.connectionName})).sort((e,t)=>e.name.localeCompare(t.name));setPendingAnnouncement(e,ANNOUNCEMENT_KEY,{value:JSON.stringify(n),render:e=>renderConnectionsAnnouncement(parseListing(e),n)})}function renderConnectionsAnnouncement(e,t){if(e===void 0||e.length===0)return t.length===0?void 0:renderListing(t);if(t.length===0)return`Connections changed. No connections are available now; do not call connection_execute.`;let n=new Map(e.map(e=>[e.name,e])),r=new Set(t.map(e=>e.name)),i=t.filter(e=>n.get(e.name)?.description!==e.description),a=e.filter(e=>!r.has(e.name)),o=[`Connections changed.`];i.length>0&&o.push([`Added or updated:`,...i.map(formatEntry)].join(`
|
|
2
|
+
`)),a.length>0&&o.push(`No longer available, do not call: ${a.map(e=>e.name).join(`, `)}`);let s=o.join(`
|
|
3
|
+
`),c=`Connections changed. This list replaces the previous one.\n${renderListing(t)}`;return s.length<c.length?s:c}function renderListing(e){return[`Connections. Find their tools with connection_search and call them with connection_execute.`,...e.map(formatEntry)].join(`
|
|
4
|
+
`)}function formatEntry(e){return e.description.length===0?`- ${e.name}`:`- ${e.name}: ${e.description}`}function parseListing(e){if(e!==void 0)try{let t=JSON.parse(e);return Array.isArray(t)?t:void 0}catch{return}}export{announceConnections};
|
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
import type { SessionCommand } from "#channel/types.js";
|
|
2
|
-
/**
|
|
2
|
+
/** Hands a losing session candidate's command to the session that owns the continuation. */
|
|
3
3
|
export declare function settleContinuationConflictStep(input: {
|
|
4
|
-
readonly
|
|
5
|
-
readonly command?: Extract<SessionCommand, {
|
|
4
|
+
readonly command: Extract<SessionCommand, {
|
|
6
5
|
readonly kind: "send";
|
|
7
6
|
}>;
|
|
8
7
|
readonly continuationToken: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{
|
|
1
|
+
import{resumeSessionInbox}from"#execution/session-inbox/resume.js";async function settleContinuationConflictStep(e){"use step";await resumeSessionInbox(e.continuationToken,e.command)}export{settleContinuationConflictStep};
|
|
@@ -1,39 +1,31 @@
|
|
|
1
1
|
/** Shared owner-side dispatch context preparation. */
|
|
2
|
-
import type { ActivityObserverConfig } from "#channel/types.js";
|
|
3
2
|
import { type ChannelAdapter, type ChannelAdapterContext } from "#channel/adapter.js";
|
|
4
3
|
import { type LocalDevRequestProvenance } from "#context/keys.js";
|
|
5
4
|
import { ContextContainer } from "#context/container.js";
|
|
6
5
|
import { type CompiledBundle } from "#runtime/sessions/runtime-context-keys.js";
|
|
7
|
-
import type {
|
|
8
|
-
import type {
|
|
9
|
-
import type { RuntimeActionResult, RuntimeToolCallActionRequest, RuntimeWorkflowTaskRequest } from "#shared/action-types.js";
|
|
6
|
+
import type { HarnessSession } from "#harness/types.js";
|
|
7
|
+
import type { RuntimeActionResult, RuntimeWorkflowTaskRequest } from "#shared/action-types.js";
|
|
10
8
|
import type { SessionParent } from "#channel/types.js";
|
|
11
9
|
import { type DurableSessionState, readDurableSession } from "#execution/durable-session-store.js";
|
|
12
10
|
import { buildSubagentRunInput } from "#subagents/tool.js";
|
|
13
11
|
import type { WorkflowToolRunOwner } from "#execution/tools/workflow/messages.js";
|
|
12
|
+
import type { DynamicSubagentSelections } from "#execution/agent-sessions/target.js";
|
|
14
13
|
import type { WorkflowAgentMetadata } from "#tools/workflow-definition.js";
|
|
15
|
-
export type DispatchPlanEntry = {
|
|
16
|
-
readonly kind: "task-control";
|
|
17
|
-
readonly action: RuntimeToolCallActionRequest;
|
|
18
|
-
} | {
|
|
19
|
-
readonly kind: "workflow-task";
|
|
20
|
-
readonly task: RuntimeWorkflowTaskRequest;
|
|
21
|
-
};
|
|
22
14
|
/** Input shared by direct and Workflow-originated owner-side dispatch. */
|
|
23
15
|
export interface CoordinationDispatchInput {
|
|
24
|
-
readonly callbackBaseUrl?: string;
|
|
25
16
|
readonly workflowToolRunOwner: WorkflowToolRunOwner;
|
|
26
17
|
readonly sessionWritable: WritableStream<Uint8Array>;
|
|
27
18
|
readonly serializedContext: Record<string, unknown>;
|
|
28
19
|
readonly sessionState: DurableSessionState;
|
|
29
20
|
}
|
|
30
|
-
/** Owner-side results and the updated session. */
|
|
21
|
+
/** Owner-side results and the updated context and session. */
|
|
31
22
|
export interface CoordinationDispatchResult {
|
|
32
23
|
readonly results: readonly RuntimeActionResult[];
|
|
24
|
+
readonly serializedContext: Record<string, unknown>;
|
|
33
25
|
readonly sessionState: DurableSessionState;
|
|
34
26
|
}
|
|
35
27
|
/** Everything preflight produces before either step's dispatch loop runs. */
|
|
36
|
-
export interface PreparedCoordinationDispatch<PlanEntry =
|
|
28
|
+
export interface PreparedCoordinationDispatch<PlanEntry = RuntimeWorkflowTaskRequest> {
|
|
37
29
|
readonly adapter: ChannelAdapter;
|
|
38
30
|
readonly adapterCtx: ChannelAdapterContext;
|
|
39
31
|
readonly auth: Parameters<typeof buildSubagentRunInput>[0]["auth"];
|
|
@@ -41,21 +33,17 @@ export interface PreparedCoordinationDispatch<PlanEntry = DispatchPlanEntry> {
|
|
|
41
33
|
readonly bundle: CompiledBundle;
|
|
42
34
|
readonly capabilities: Parameters<typeof buildSubagentRunInput>[0]["capabilities"];
|
|
43
35
|
readonly channelMetadata: Parameters<typeof buildSubagentRunInput>[0]["channelMetadata"];
|
|
36
|
+
readonly dynamicSubagentSelections: DynamicSubagentSelections;
|
|
44
37
|
readonly inheritedConversation: Parameters<typeof buildSubagentRunInput>[0]["inheritedConversation"];
|
|
45
|
-
/** Number of local children sharing the parent's remaining token quota. */
|
|
46
|
-
readonly fanoutSize: number;
|
|
47
38
|
readonly initiatorAuth: Parameters<typeof buildSubagentRunInput>[0]["initiatorAuth"];
|
|
48
39
|
/** Inherited originating-client metadata for the dev-TUI hint. */
|
|
49
40
|
readonly localDevRequest?: LocalDevRequestProvenance;
|
|
50
41
|
/** Lineage of the session running this dispatch, when it is itself a delegated child. */
|
|
51
42
|
readonly parentSession: SessionParent | undefined;
|
|
52
|
-
readonly activityObserver?: ActivityObserverConfig & {
|
|
53
|
-
readonly workIdentity: ActivityWorkIdentityV1;
|
|
54
|
-
};
|
|
55
43
|
readonly sandboxSessionId: string;
|
|
56
44
|
readonly serializedContext: Record<string, unknown>;
|
|
57
45
|
readonly plan: readonly PlanEntry[];
|
|
58
|
-
readonly session:
|
|
46
|
+
readonly session: HarnessSession;
|
|
59
47
|
readonly sessionState: DurableSessionState;
|
|
60
48
|
readonly workflowAgents: Readonly<Record<string, WorkflowAgentMetadata>>;
|
|
61
49
|
}
|
|
@@ -76,7 +64,6 @@ interface DispatchBatch {
|
|
|
76
64
|
readonly stepIndex: number;
|
|
77
65
|
readonly turnId: string;
|
|
78
66
|
};
|
|
79
|
-
readonly localFanoutSize?: number;
|
|
80
67
|
readonly requests: readonly {
|
|
81
68
|
readonly callId: string;
|
|
82
69
|
}[];
|
|
@@ -85,17 +72,12 @@ export declare function prepareActionDispatch<PlanEntry>(input: {
|
|
|
85
72
|
readonly batch: DispatchBatch;
|
|
86
73
|
readonly ctx: ContextContainer;
|
|
87
74
|
readonly durableSession: Awaited<ReturnType<typeof readDurableSession>>;
|
|
88
|
-
readonly fanoutSize?: number;
|
|
89
75
|
readonly plan: (input: {
|
|
90
76
|
readonly bundle: CompiledBundle;
|
|
91
77
|
readonly ctx: ContextContainer;
|
|
92
78
|
readonly requests: DispatchBatch["requests"];
|
|
93
|
-
readonly session:
|
|
79
|
+
readonly session: HarnessSession;
|
|
94
80
|
}) => readonly PlanEntry[];
|
|
95
|
-
readonly planReusesOwnerSandbox?: (input: {
|
|
96
|
-
readonly bundle: CompiledBundle;
|
|
97
|
-
readonly plan: readonly PlanEntry[];
|
|
98
|
-
}) => boolean;
|
|
99
81
|
readonly serializedContext: Record<string, unknown>;
|
|
100
82
|
}): Promise<Omit<PreparedCoordinationDispatch<PlanEntry>, "sessionState">>;
|
|
101
83
|
export {};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{ConversationContextKey}from"#shared/conversation-context.js";import"#channel/adapter.js";import"#context/container.js";import{
|
|
1
|
+
import{ConversationContextKey}from"#shared/conversation-context.js";import"#channel/adapter.js";import"#context/container.js";import{AuthKey,CapabilitiesKey,ChannelInstrumentationKey,InitiatorAuthKey,LocalDevRequestKey,ParentSessionKey}from"#context/keys.js";import{BundleKey,ChannelKey}from"#runtime/sessions/runtime-context-keys.js";import"#subagents/tool.js";import{assertUniqueCoordinationCallIds,getPendingCoordinationBatch,setPendingCoordinationBatch}from"#harness/coordination.js";import{createDurableSessionState,readDurableSession}from"#execution/durable-session-store.js";import{deserializeContext}from"#context/serialize.js";import{buildAdapterContext}from"#channel/adapter-context.js";import{activeTurnId}from"#harness/active-turn-id.js";import{hydrateDurableSession}from"#execution/session.js";import{resolveEffectiveAgentRuntime}from"#execution/effective-agent-config.js";import{resolveWorkflowAgentMetadata}from"#execution/agent-sessions/metadata.js";import{readDynamicSubagentSelections}from"#context/dynamic-subagent-lifecycle.js";async function prepareCoordinationDispatch(e){let t=readDurableSession(e.sessionState),n=getPendingCoordinationBatch(t.state);if(n===void 0)return;let r=n.tasks;if(r.length===0)return;let i=n.event.turnId||activeTurnId(e.sessionState.emissionState),a=n.event.turnId===i?n.event:{...n.event,turnId:i},o=await deserializeContext(e.serializedContext),s=await prepareActionDispatch({batch:{event:a,requests:r},ctx:o,durableSession:t,plan:()=>r,serializedContext:e.serializedContext});if(a===n.event)return{...s,sessionState:e.sessionState};let c=setPendingCoordinationBatch({...n,event:a,session:s.session});return{...s,session:c,sessionState:createDurableSessionState({session:c})}}async function prepareActionDispatch(e){let{batch:t,durableSession:n}=e;assertUniqueCoordinationCallIds(t.requests);let r=e.ctx,i=r.require(BundleKey),a=resolveEffectiveAgentRuntime(i,r),o=hydrateDurableSession({compactionOverrides:{thresholdPercent:a.thresholdPercent},durable:n,turnAgent:a.turnAgent}),s=r.require(ChannelKey),c=e.plan({bundle:i,ctx:r,requests:t.requests,session:o}),l=resolveActiveSandboxSessionId(s.state,o.sessionId);return{adapter:s,adapterCtx:buildAdapterContext(s,r),auth:r.get(AuthKey)??null,batch:t,bundle:i,capabilities:r.get(CapabilitiesKey),channelMetadata:r.get(ChannelInstrumentationKey),dynamicSubagentSelections:readDynamicSubagentSelections(r),inheritedConversation:r.get(ConversationContextKey),initiatorAuth:r.get(InitiatorAuthKey)??null,localDevRequest:r.get(LocalDevRequestKey),parentSession:r.get(ParentSessionKey),plan:c,sandboxSessionId:l,serializedContext:e.serializedContext,session:o,workflowAgents:resolveWorkflowAgentMetadata(r)}}function resolveActiveSandboxSessionId(e,t){if(typeof e!=`object`||!e)return t;let n=e.sandboxSessionId;return typeof n==`string`&&n.length>0?n:t}export{prepareActionDispatch,prepareCoordinationDispatch};
|
|
@@ -1,7 +1,8 @@
|
|
|
1
|
-
/** Starts workflow-tool runs
|
|
1
|
+
/** Starts workflow-tool runs for pending coordination. */
|
|
2
2
|
import { type CoordinationDispatchInput, type CoordinationDispatchResult } from "#execution/coordination-dispatch-shared.js";
|
|
3
|
+
import { type WithSessionStateDelta } from "#execution/session/state-delta.js";
|
|
3
4
|
type CoordinationDispatchStepInput = CoordinationDispatchInput & {
|
|
4
5
|
readonly action: "park";
|
|
5
6
|
};
|
|
6
|
-
export declare function dispatchCoordinationStep(input: CoordinationDispatchStepInput): Promise<CoordinationDispatchResult
|
|
7
|
+
export declare function dispatchCoordinationStep(input: CoordinationDispatchStepInput): Promise<WithSessionStateDelta<CoordinationDispatchResult>>;
|
|
7
8
|
export {};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{createDurableSessionState}from"#execution/durable-session-store.js";import{
|
|
1
|
+
import{createDurableSessionState}from"#execution/durable-session-store.js";import{prepareCoordinationDispatch}from"#execution/coordination-dispatch-shared.js";import{publishSessionEvents}from"#execution/publish-session-events.js";import{withSessionStateDelta}from"#execution/session/state-delta.js";import{startWorkflowTask}from"#execution/tools/workflow/start.js";import{sendToTask,startTaskRun}from"#execution/tasks/start.js";import{captureAgentSessionContext,resolveStepAgentLimits}from"#execution/agent-sessions/context.js";async function dispatchCoordinationStep(e){"use step";return await withSessionStateDelta(e,dispatchCoordination)}async function dispatchCoordination(e){let t=await prepareCoordinationDispatch({serializedContext:e.serializedContext,sessionState:e.sessionState});if(t===void 0)return{results:[],serializedContext:e.serializedContext,sessionState:e.sessionState};let{batch:n,session:r}=t,i=r,a=[],o=[],s=resolveStepAgentLimits(t);for(let r of t.plan){let c=await dispatchWorkflowCall({agentContext:captureAgentSessionContext(t,r.callId,s),auth:{current:t.auth,initiator:t.initiatorAuth},batchEvent:n.event,owner:e.workflowToolRunOwner,parentSession:t.parentSession,session:i,task:r});i=c.session,c.result!==void 0&&a.push(c.result),c.started!==void 0&&o.push(c.started)}return{results:a,...await publishSessionEvents({serializedContext:e.serializedContext,sessionState:i===r?t.sessionState:createDurableSessionState({session:i}),sessionWritable:e.sessionWritable},o)}}async function dispatchWorkflowCall(e){let{entry:t}=e.task;switch(t.entryPoint){case`execute`:return await startWorkflowTask(e);case`task`:case`serve`:return await startTaskRun({...e,entry:t});case`receive`:return await sendToTask({...e,taskId:t.taskId})}}export{dispatchCoordinationStep};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{
|
|
1
|
+
import{resolveDurableCompiledArtifactsSource}from"#runtime/durable-compiled-artifacts-source.js";import{getCompiledRuntimeAgentBundle}from"#runtime/sessions/compiled-agent-cache.js";import{createDurableSessionState}from"#execution/durable-session-store.js";import{createSession}from"#execution/session.js";import{resolveEffectiveAgentRuntimeFromConfig}from"#execution/effective-agent-config.js";import{resolveInheritedTokenLimit}from"#execution/run-session-limits.js";async function createSessionStep(e){"use step";let t=await getCompiledRuntimeAgentBundle({compiledArtifactsSource:resolveDurableCompiledArtifactsSource(e.compiledArtifactsSource),nodeId:e.nodeId}),n=resolveEffectiveAgentRuntimeFromConfig(t,e.dynamicSubagentAgentConfig),r=createSession({compactionOverrides:{thresholdPercent:n.thresholdPercent},continuationToken:e.continuationToken,limits:{maxInputTokensPerSession:resolveInheritedTokenLimit({configured:n.limits?.maxInputTokensPerSession,inherited:e.inheritedLimits?.maxInputTokensPerSession}),maxOutputTokensPerSession:resolveInheritedTokenLimit({configured:n.limits?.maxOutputTokensPerSession,inherited:e.inheritedLimits?.maxOutputTokensPerSession}),maxTokenCostUsdPerSession:resolveInheritedTokenLimit({configured:n.limits?.maxTokenCostUsdPerSession,inherited:e.inheritedLimits?.maxTokenCostUsdPerSession})},outputSchema:e.outputSchema,rootSessionId:e.rootSessionId,sessionId:e.sessionId,turnAgent:n.turnAgent});return{state:createDurableSessionState({session:r})}}export{createSessionStep};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{coalesceTurnInputs}from"#harness/messages.js";const COALESCED_DELIVER_FIELDS=[`context`,`inputResponses`,`message`,`outputSchema
|
|
1
|
+
import{coalesceTurnInputs}from"#harness/messages.js";const COALESCED_DELIVER_FIELDS=[`context`,`inputResponses`,`message`,`outputSchema`];function coalesceDeliverPayloads(e){if(e.length===0)return{};if(e.length===1)return e[0]??{};let t={},n={};for(let r of e){for(let[e,n]of Object.entries(r))n!==void 0&&(t[e]=n);n=coalesceTurnInputs(n,r)}for(let e of COALESCED_DELIVER_FIELDS)delete t[e];return Object.assign(t,n)}export{coalesceDeliverPayloads};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{createSessionStartedEvent,createTurnStartedEvent}from"#protocol/message.js";import{dispatchDynamicConnectionEvent}from"#context/dynamic-connection-lifecycle.js";function bindDynamicConnections(e,t){let n=t.dynamicConnectionResolvers??[],dispatch=t=>dispatchDynamicConnectionEvent({ctx:e,event:t,resolvers:n});return{dispatch,async rehydrate(e,t,n){e.sessionStarted&&(await dispatch(createSessionStartedEvent({runtime:t})),n!==void 0&&await dispatch(createTurnStartedEvent(n)))}}}export{bindDynamicConnections};
|
|
1
|
+
import{createSessionStartedEvent,createTurnStartedEvent}from"#protocol/message.js";import{dispatchDynamicConnectionEvent}from"#context/dynamic-connection-lifecycle.js";import{announceConnections}from"#execution/connection-announcement.js";function bindDynamicConnections(e,t){let n=t.dynamicConnectionResolvers??[],dispatch=async t=>{await dispatchDynamicConnectionEvent({ctx:e,event:t,resolvers:n}),t.type===`step.started`&&announceConnections(e)};return{dispatch,async rehydrate(e,t,n){e.sessionStarted&&(await dispatch(createSessionStartedEvent({runtime:t})),n!==void 0&&await dispatch(createTurnStartedEvent(n)))}}}export{bindDynamicConnections};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{jsonSchema}from"ai";import{WORKFLOW_PROGRAM_BRIDGE_REQUEST_LIMIT,WORKFLOW_PROGRAM_CALL_INTERRUPT_KIND,parseWorkflowProgramOutput,readWorkflowProgramCallInterrupt}from"#execution/dynamic-workflow/schema.js";import{continueWorkflowSandboxInterrupt,createParkingHostTool,createWorkflowSandboxTool,getWorkflowSandboxPendingInterrupts,unwrapWorkflowSandboxResult}from"#shared/workflow-sandbox.js";const agentBridgeSchema=jsonSchema({additionalProperties:!1,properties:{input:{additionalProperties:!1,properties:{
|
|
1
|
+
import{jsonSchema}from"ai";import{toErrorMessage}from"#shared/errors.js";import{FatalError}from"#compiled/@workflow/core/index.js";import{WORKFLOW_PROGRAM_BRIDGE_REQUEST_LIMIT,WORKFLOW_PROGRAM_CALL_INTERRUPT_KIND,parseWorkflowProgramOutput,readWorkflowProgramCallInterrupt}from"#execution/dynamic-workflow/schema.js";import{continueWorkflowSandboxInterrupt,createParkingHostTool,createWorkflowSandboxTool,getWorkflowSandboxPendingInterrupts,unwrapWorkflowSandboxResult}from"#shared/workflow-sandbox.js";const agentBridgeSchema=jsonSchema({additionalProperties:!1,properties:{input:{additionalProperties:!1,properties:{message:{type:`string`},outputSchema:{type:`object`}},required:[`message`],type:`object`},target:{type:`string`}},required:[`target`,`input`],type:`object`});async function runWorkflowProgramStep(e){"use step";try{return await runWorkflowProgram(e)}catch(e){throw new FatalError(toErrorMessage(e))}}async function runWorkflowProgram(e){let t=buildWorkflowProgramTools(),n=e.program.continuationSecurity,r;if(e.resume===void 0){let i=await createWorkflowSandboxTool({bridgeRequestLimit:WORKFLOW_PROGRAM_BRIDGE_REQUEST_LIMIT,continuationSecurity:n,hostTools:t});if(i.execute===void 0)throw Error(`Workflow program has no sandbox executor.`);r=await i.execute({js:wrapWorkflowProgram(e.program.js)},{toolCallId:e.callId})}else{let i=e.resume.interrupt;r=i;for(let a of e.resume.resolutions){r=await continueWorkflowSandboxInterrupt({bridgeRequestLimit:WORKFLOW_PROGRAM_BRIDGE_REQUEST_LIMIT,continuationSecurity:n,interrupt:i,resolution:a,tools:t});let e=await unwrapWorkflowSandboxResult(r,n);if(e.status===`completed`)break;let o=getWorkflowSandboxPendingInterrupts(e.interrupt)[0];if(o===void 0)throw Error(`Workflow program continuation contains no pending agent call.`);i=o}}let i=await unwrapWorkflowSandboxResult(r,n);if(i.status===`completed`)return{output:parseWorkflowProgramOutput(i.output),status:`completed`};let a=getWorkflowSandboxPendingInterrupts(i.interrupt);if(a.length===0)throw Error(`Workflow program continuation contains no pending agent call.`);for(let e of a)readWorkflowProgramCallInterrupt(e);return{interrupt:a[0],pending:a,status:`interrupted`}}function buildWorkflowProgramTools(){return{agent:createParkingHostTool({description:`Invoke one allowlisted child agent.`,inputSchema:agentBridgeSchema,interrupt:e=>({kind:WORKFLOW_PROGRAM_CALL_INTERRUPT_KIND,task:void 0,toolInput:e,toolName:`agent`})})}}function wrapWorkflowProgram(e){return`return await (async (ctx) => {\n${e}\n})(Object.freeze({\n agent: (target, input) => tools.agent({ target, input }),\n}));`}export{runWorkflowProgramStep};
|
|
@@ -20,9 +20,8 @@ export interface WorkflowProgramInput {
|
|
|
20
20
|
readonly maxSubagents: number;
|
|
21
21
|
}
|
|
22
22
|
export type WorkflowProgramOptions = Pick<WorkflowProgramInput, "maxSubagents">;
|
|
23
|
-
interface WorkflowProgramAgentCall {
|
|
23
|
+
export interface WorkflowProgramAgentCall {
|
|
24
24
|
readonly input: {
|
|
25
|
-
readonly agentId?: string;
|
|
26
25
|
readonly message: string;
|
|
27
26
|
readonly outputSchema?: JsonObject;
|
|
28
27
|
};
|
|
@@ -34,4 +33,3 @@ export declare function readWorkflowProgramCallInterrupt(input: {
|
|
|
34
33
|
}): WorkflowProgramCallInterrupt;
|
|
35
34
|
export declare function readWorkflowProgramAgentCall(value: unknown): WorkflowProgramAgentCall;
|
|
36
35
|
export declare function parseWorkflowProgramOutput(value: unknown): JsonValue;
|
|
37
|
-
export {};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{parseJsonObject,parseJsonValue}from"#shared/json.js";const DEFAULT_WORKFLOW_PROGRAM_MAX_SUBAGENTS=100,MAX_WORKFLOW_PROGRAM_MAX_SUBAGENTS=128,WORKFLOW_PROGRAM_BRIDGE_REQUEST_LIMIT=256,WORKFLOW_PROGRAM_CALL_INTERRUPT_KIND=`eve.workflow-program-agent-call`;function parseWorkflowProgramOptions(e){let t=parseJsonObject(e);if(!isPositiveInteger(t.maxSubagents)||t.maxSubagents>128)throw TypeError(`workflow maxSubagents must be an integer between 1 and 128.`);return{maxSubagents:t.maxSubagents}}function readWorkflowProgramCallInterrupt(e){let t=e.payload;if(t.kind!==`eve.workflow-program-agent-call`||t.toolName!==`agent`)throw Error(`Unsupported workflow program interrupt kind "${String(t.kind)}".`);return{kind:WORKFLOW_PROGRAM_CALL_INTERRUPT_KIND,task:void 0,toolInput:t.toolInput,toolName:`agent`}}function readWorkflowProgramAgentCall(e){let t=parseJsonObject(e);if(typeof t.target!=`string`||t.target.trim()===``)throw TypeError(`Workflow program ctx.agent() requires a non-empty agent name.`);let n=parseJsonObject(t.input);if(typeof n.message!=`string`)throw TypeError(`Workflow program ctx.agent() requires a "message" string.`);
|
|
1
|
+
import{parseJsonObject,parseJsonValue}from"#shared/json.js";const DEFAULT_WORKFLOW_PROGRAM_MAX_SUBAGENTS=100,MAX_WORKFLOW_PROGRAM_MAX_SUBAGENTS=128,WORKFLOW_PROGRAM_BRIDGE_REQUEST_LIMIT=256,WORKFLOW_PROGRAM_CALL_INTERRUPT_KIND=`eve.workflow-program-agent-call`;function parseWorkflowProgramOptions(e){let t=parseJsonObject(e);if(!isPositiveInteger(t.maxSubagents)||t.maxSubagents>128)throw TypeError(`workflow maxSubagents must be an integer between 1 and 128.`);return{maxSubagents:t.maxSubagents}}function readWorkflowProgramCallInterrupt(e){let t=e.payload;if(t.kind!==`eve.workflow-program-agent-call`||t.toolName!==`agent`)throw Error(`Unsupported workflow program interrupt kind "${String(t.kind)}".`);return{kind:WORKFLOW_PROGRAM_CALL_INTERRUPT_KIND,task:void 0,toolInput:t.toolInput,toolName:`agent`}}function readWorkflowProgramAgentCall(e){let t=parseJsonObject(e);if(typeof t.target!=`string`||t.target.trim()===``)throw TypeError(`Workflow program ctx.agent() requires a non-empty agent name.`);let n=parseJsonObject(t.input);if(typeof n.message!=`string`)throw TypeError(`Workflow program ctx.agent() requires a "message" string.`);let r={message:n.message};return n.outputSchema!==void 0&&(r.outputSchema=parseJsonObject(n.outputSchema)),{input:r,target:t.target}}function parseWorkflowProgramOutput(e){return parseJsonValue(e??null)}function isPositiveInteger(e){return typeof e==`number`&&Number.isSafeInteger(e)&&e>0}export{DEFAULT_WORKFLOW_PROGRAM_MAX_SUBAGENTS,MAX_WORKFLOW_PROGRAM_MAX_SUBAGENTS,WORKFLOW_PROGRAM_BRIDGE_REQUEST_LIMIT,WORKFLOW_PROGRAM_CALL_INTERRUPT_KIND,parseWorkflowProgramOptions,parseWorkflowProgramOutput,readWorkflowProgramAgentCall,readWorkflowProgramCallInterrupt};
|
|
@@ -5,4 +5,4 @@ export interface WorkflowProgramToolInput {
|
|
|
5
5
|
readonly maxSubagents?: number;
|
|
6
6
|
}
|
|
7
7
|
/** Static workflow executor used by the provided `workflow` tool. */
|
|
8
|
-
export declare function
|
|
8
|
+
export declare function runWorkflowProgramTask(input: WorkflowProgramToolInput, ctx: WorkflowToolContext): Promise<JsonValue>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{runJsProgram}from"#execution/dynamic-workflow/workflow.js";async function
|
|
1
|
+
import{runJsProgram}from"#execution/dynamic-workflow/workflow.js";async function runWorkflowProgramTask(e,t){"use workflow";return runJsProgram(e.js,t,{maxSubagents:e.maxSubagents??0})}runWorkflowProgramTask.workflowId=`workflow//eve@0.69.0//runWorkflowProgramTask`;export{runWorkflowProgramTask};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{toErrorMessage}from"#shared/errors.js";import{DEFAULT_WORKFLOW_PROGRAM_MAX_SUBAGENTS,MAX_WORKFLOW_PROGRAM_MAX_SUBAGENTS,parseWorkflowProgramOptions,readWorkflowProgramAgentCall,readWorkflowProgramCallInterrupt}from"#execution/dynamic-workflow/schema.js";import{runWorkflowProgramStep}from"#execution/dynamic-workflow/program-step.js";import{createWorkflowProgramContinuationSecurityStep}from"#execution/dynamic-workflow/security-step.js";async function runJsProgram(e,t,n){if(typeof e!=`string`)throw TypeError(`workflow requires a "js" string.`);let r={...parseWorkflowProgramOptions({maxSubagents:n.maxSubagents??DEFAULT_WORKFLOW_PROGRAM_MAX_SUBAGENTS}),continuationSecurity:await createWorkflowProgramContinuationSecurityStep(),js:e},i={callId:t.callId,program:r},a=await runWorkflowProgramStep(i),o=0;for(;a.status===`interrupted`;){t.abortSignal.throwIfAborted();let e=await Promise.all(a.pending.map(async e=>{let n=readWorkflowProgramCallInterrupt(e),i=readWorkflowProgramAgentCall(n.toolInput);if(o++>=r.maxSubagents)return{status:`failed`,error:`WORKFLOW_PROGRAM_SUBAGENT_LIMIT_REACHED: workflow may invoke at most ${String(r.maxSubagents)} agents; "${i.target}" was not called.`};try{return{status:`completed`,output:await t
|
|
1
|
+
import{toErrorMessage}from"#shared/errors.js";import{DEFAULT_WORKFLOW_PROGRAM_MAX_SUBAGENTS,MAX_WORKFLOW_PROGRAM_MAX_SUBAGENTS,parseWorkflowProgramOptions,readWorkflowProgramAgentCall,readWorkflowProgramCallInterrupt}from"#execution/dynamic-workflow/schema.js";import{runWorkflowProgramStep}from"#execution/dynamic-workflow/program-step.js";import{createWorkflowProgramContinuationSecurityStep}from"#execution/dynamic-workflow/security-step.js";async function runJsProgram(e,t,n){if(typeof e!=`string`)throw TypeError(`workflow requires a "js" string.`);let r={...parseWorkflowProgramOptions({maxSubagents:n.maxSubagents??DEFAULT_WORKFLOW_PROGRAM_MAX_SUBAGENTS}),continuationSecurity:await createWorkflowProgramContinuationSecurityStep(),js:e},i={callId:t.callId,program:r},a=await runWorkflowProgramStep(i),o=0;for(;a.status===`interrupted`;){t.abortSignal.throwIfAborted();let e=await Promise.all(a.pending.map(async e=>{let n=readWorkflowProgramCallInterrupt(e),i=readWorkflowProgramAgentCall(n.toolInput);if(o++>=r.maxSubagents)return{status:`failed`,error:`WORKFLOW_PROGRAM_SUBAGENT_LIMIT_REACHED: workflow may invoke at most ${String(r.maxSubagents)} agents; "${i.target}" was not called.`};try{return{status:`completed`,output:await callProgramAgent(t,i)}}catch(e){return t.abortSignal.throwIfAborted(),{status:`failed`,error:toErrorMessage(e)}}}));a=await runWorkflowProgramStep({...i,resume:{interrupt:a.interrupt,resolutions:e}})}return a.output}async function callProgramAgent(e,t){let{message:n,outputSchema:r}=t.input,i=await(await e.agent(t.target).send(n,{outputSchema:r,signal:e.abortSignal})).result();if(i.status===`failed`)throw Error(`Agent "${t.target}" failed to handle the message: ${i.error?.message??`no reason given`}`);return r===void 0?i.message??null:i.data??null}export{MAX_WORKFLOW_PROGRAM_MAX_SUBAGENTS,runJsProgram};
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import type { ContextContainer } from "#context/container.js";
|
|
2
|
+
import type { UnstampedMessageStreamEvent } from "#protocol/message.js";
|
|
3
|
+
/** A remote session sends input to its caller instead of presenting it on its own channel. */
|
|
4
|
+
export declare function forwardSessionInput(ctx: ContextContainer, event: UnstampedMessageStreamEvent, inputSource?: string): Promise<boolean>;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{sessionCommandHookToken}from"#execution/session-inbox/address.js";import{ContinuationTokenKey,LegacyRemoteAgentCallerKey,SessionCallbackKey,SessionIdKey,SessionInboxKey}from"#context/keys.js";import{forwardLegacySessionInput}from"#execution/legacy-remote-agent/protocol.js";import{postSessionCallbackRequest}from"#execution/session-callback-request.js";async function forwardSessionInput(e,t,n){let r=e.get(SessionCallbackKey);if(r===void 0)return!1;let i=e.get(LegacyRemoteAgentCallerKey);if(i!==void 0)return await forwardLegacySessionInput(e,i,t);if(t.type!==`input.requested`&&t.type!==`authorization.required`&&t.type!==`authorization.completed`&&t.type!==`approval.candidate`&&t.type!==`approval.settled`)return!1;let a=t.type===`input.requested`?{callId:r.callId,childContinuationToken:e.get(ContinuationTokenKey)??sessionCommandHookToken(e.require(SessionIdKey)),childSessionId:e.require(SessionIdKey),childSessionInbox:e.get(SessionInboxKey),event:t.data,inputSource:n??`session`,kind:`subagent-input-request`,subagentName:r.subagentName}:{callId:r.callId,childSessionId:e.require(SessionIdKey),event:t,kind:`subagent-authorization-event`,subagentName:r.subagentName},o=await postSessionCallbackRequest({body:a,url:r.url});if(!o.ok)throw Error(`Remote input callback failed with HTTP ${o.status}.`);return!0}export{forwardSessionInput};
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
import type { ContextContainer } from "#context/container.js";
|
|
2
|
+
import type { UnstampedMessageStreamEvent } from "#protocol/message.js";
|
|
3
|
+
import type { RouteContext } from "#public/definitions/channel.js";
|
|
4
|
+
export declare const LEGACY_REMOTE_AGENT_PROTOCOL_VERSION = 1;
|
|
5
|
+
/** A session created by a protocol-1 caller. */
|
|
6
|
+
export interface LegacyRemoteAgentCaller {
|
|
7
|
+
/**
|
|
8
|
+
* The caller's background task; its questions and sign-ins are forwarded
|
|
9
|
+
* only with one. Captured at create: a 0.66–0.68 caller's model-called
|
|
10
|
+
* agents start in a task, and those callers never check it against later turns.
|
|
11
|
+
*/
|
|
12
|
+
readonly taskId?: string;
|
|
13
|
+
}
|
|
14
|
+
/**
|
|
15
|
+
* Removes the `callback.taskId` a protocol-1 caller adds when it delegates
|
|
16
|
+
* from a background task. Current callers don't send it. The task id is
|
|
17
|
+
* returned so the session can name it back to the caller. The caller's
|
|
18
|
+
* `activityObserver` needs no removal: eve ignores that field from any caller.
|
|
19
|
+
*/
|
|
20
|
+
export declare function splitLegacyTaskFields(input: Record<string, unknown>): {
|
|
21
|
+
readonly payload: Record<string, unknown>;
|
|
22
|
+
readonly taskId?: string;
|
|
23
|
+
};
|
|
24
|
+
/**
|
|
25
|
+
* Sends a question, approval, or sign-in to a protocol-1 caller in the
|
|
26
|
+
* `task.*` callback it expects. Returns whether the event was forwarded and
|
|
27
|
+
* must stay off this session's own channel.
|
|
28
|
+
*/
|
|
29
|
+
export declare function forwardLegacySessionInput(ctx: ContextContainer, caller: LegacyRemoteAgentCaller, event: UnstampedMessageStreamEvent): Promise<boolean>;
|
|
30
|
+
/** Route a protocol-1 caller posts its answers to a remote agent's question or approval. */
|
|
31
|
+
export declare const legacyTaskInputRoute: {
|
|
32
|
+
readonly handler: typeof handleLegacyTaskInputRequest;
|
|
33
|
+
readonly path: "/eve/v1/task-input/:token";
|
|
34
|
+
};
|
|
35
|
+
/**
|
|
36
|
+
* Delivers a protocol-1 caller's answers. The token is the capability the
|
|
37
|
+
* caller derived from this session's create-once continuation token, so it
|
|
38
|
+
* authorizes the request on its own, as it did in protocol 1.
|
|
39
|
+
*/
|
|
40
|
+
declare function handleLegacyTaskInputRequest(request: Request, ctx: RouteContext): Promise<Response>;
|
|
41
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{createLogger,logError}from"#internal/logging.js";import{isObject}from"#shared/guards.js";import{isInputResponse}from"#shared/input.js";import{ContinuationTokenKey,SessionCallbackKey,SessionIdKey}from"#context/keys.js";import{EVE_ROUTE_PREFIX}from"#protocol/routes.js";import{resumeSessionInbox}from"#execution/session-inbox/resume.js";import{postSessionCallbackRequest}from"#execution/session-callback-request.js";import{HookNotFoundError}from"#compiled/@workflow/errors/index.js";const log=createLogger(`execution.legacy-remote-agent`),LEGACY_REMOTE_AGENT_PROTOCOL_VERSION=1,TASK_INPUT_TOKEN_RE=/^eve:task-input:([a-f0-9]{32})$/;function splitLegacyTaskFields(e){let{callback:t}=e;if(!isObject(t)||!(`taskId`in t))return{payload:e};let{taskId:n,...r}=t,i={...e,callback:r};return typeof n==`string`&&n.length>0?{payload:i,taskId:n}:{payload:i}}async function forwardLegacySessionInput(e,t,n){let r=e.get(SessionCallbackKey),i=e.get(ContinuationTokenKey);if(t.taskId===void 0||r===void 0||!i)return!1;let a;if(n.type===`input.requested`)a={event:n.data,kind:`task.input-requested`};else if(n.type===`authorization.required`||n.type===`authorization.completed`)a={event:n,kind:`task.authorization`};else return!1;let o=await postSessionCallbackRequest({body:{callId:r.callId,childContinuationToken:i,childSessionId:e.require(SessionIdKey),event:a.event,kind:a.kind,subagentName:r.subagentName,taskId:t.taskId},url:r.url});if(!o.ok)throw Error(`Remote task event callback failed with HTTP ${o.status}.`);return!0}const legacyTaskInputRoute={handler:handleLegacyTaskInputRequest,path:`${EVE_ROUTE_PREFIX}/task-input/:token`};async function handleLegacyTaskInputRequest(e,t){let n=TASK_INPUT_TOKEN_RE.exec(t.params.token??``)?.[1];if(n===void 0)return Response.json({error:`Invalid task input token.`,ok:!1},{status:403});let r;try{r=await e.json()}catch{return Response.json({error:`Invalid JSON body.`,ok:!1},{status:400})}let i=isObject(r)?r.inputResponses:void 0;if(!Array.isArray(i)||i.length===0||!i.every(isInputResponse))return Response.json({error:`Expected a non-empty inputResponses array.`,ok:!1},{status:400});try{await resumeSessionInbox(`eve:eve:op:${n}`,{kind:`send`,payload:{inputResponses:i}})}catch(e){if(HookNotFoundError.is(e))return Response.json({error:`Task input target is not pending.`,ok:!1},{status:404});let t=logError(log,`legacy task input delivery failed`,e);return Response.json({error:`Failed to deliver the task input.`,errorId:t,ok:!1},{status:500})}return Response.json({ok:!0},{status:202})}export{LEGACY_REMOTE_AGENT_PROTOCOL_VERSION,forwardLegacySessionInput,legacyTaskInputRoute,splitLegacyTaskFields};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{encodeLegacyCommand,resolveLegacyInbox}from"./inbox.js";import{isObject}from"#shared/guards.js";import{
|
|
1
|
+
import{encodeLegacyCommand,resolveLegacyInbox}from"./inbox.js";import{isObject}from"#shared/guards.js";import{HookNotFoundError}from"#compiled/@workflow/errors/index.js";import{resumeHook}from"#internal/workflow/runtime.js";async function resumeAuthorizationCallback(e,t){try{await resumeHook(e,t);return}catch(e){if(!HookNotFoundError.is(e))throw e}let n=await resolveLegacyInbox(e);if(n.current)throw Error(`Authorization was interrupted by the session upgrade. Request authorization again.`);let r=await n.hook.metadata;await resumeHook(n.hook.token,encodeLegacyCommand({kind:`deliver`,payloads:t.payloads},isObject(r)?r.sessionInboxWireVersion:void 0))}async function handleExpiredLegacyAuthorization(){return Response.json({ok:!1,error:`This authorization link predates the session upgrade. Request authorization again.`},{status:410})}export{handleExpiredLegacyAuthorization,resumeAuthorizationCallback};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{
|
|
1
|
+
import{HookNotFoundError}from"#compiled/@workflow/errors/index.js";import{resumeHook}from"#internal/workflow/runtime.js";async function completeLegacyDriverStep(e){"use step";let t=e.sessionWritable.getWriter();try{await t.close()}finally{t.releaseLock()}try{await resumeHook(e.completionToken,{kind:`turn-result`,action:{kind:`done`,...e.result,serializedContext:e.serializedContext,sessionState:{...e.sessionState,snapshot:{version:1,session:e.sessionState.snapshot.session}}}})}catch(e){if(!HookNotFoundError.is(e))throw e}}export{completeLegacyDriverStep};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{isObject}from"#shared/guards.js";import{sessionCommandHookToken,sessionInboxHookToken}from"#execution/session-inbox/address.js";import{
|
|
1
|
+
import{isObject}from"#shared/guards.js";import{sessionCommandHookToken,sessionInboxHookToken}from"#execution/session-inbox/address.js";import{HookNotFoundError}from"#compiled/@workflow/errors/index.js";import{getHookByToken,resumeHook}from"#internal/workflow/runtime.js";import{coalesceDeliverPayloads}from"#execution/deliver-payloads.js";var UnsupportedLegacySessionError=class extends Error{constructor(){super(`This session predates eve 0.45 and cannot be continued. Start a new session.`),this.name=`UnsupportedLegacySessionError`}};async function resolveLegacyInbox(e){let t=await getHookByToken(e),n=await t.metadata,r=isObject(n)&&typeof n.sessionId==`string`?n.sessionId:t.runId;try{return{hook:await getHookByToken(sessionInboxHookToken(sessionCommandHookToken(r))),sessionId:r,current:!0}}catch(e){if(!HookNotFoundError.is(e))throw e;return{hook:t,sessionId:r,current:!1}}}async function resumeLegacyInbox(e,t){let n=await resolveLegacyInbox(e),r=t;if(!n.current){let e=await n.hook.metadata;r=encodeLegacyCommand(t,isObject(e)?e.sessionInboxWireVersion:void 0)}return{ownerRunId:(await resumeHook(n.hook.token,r)).runId,sessionId:Promise.resolve(n.sessionId)}}function encodeLegacyCommand(e,t){let n=t;if(typeof n!=`number`||!Number.isInteger(n)||n<1||n>7)throw new UnsupportedLegacySessionError;if(e.kind!==`send`&&e.kind!==`deliver`)return{...e,version:n};let r=e.kind===`send`?[e.payload]:e.payloads,i=e.caller,a=e.kind===`send`?e.delivery===void 0?void 0:[{...e.delivery,payloadIndex:0}]:e.deliveryMetadata;return n<3&&a!==void 0&&(a=a.map(({acceptedDeploymentId:e,...t})=>t)),{auth:e.auth,caller:i,deliveryMetadata:a,kind:`deliver`,payload:coalesceDeliverPayloads(r),payloads:r,requestId:e.requestId,turnPolicy:e.turnPolicy,version:n}}export{UnsupportedLegacySessionError,encodeLegacyCommand,resolveLegacyInbox,resumeLegacyInbox};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{isObject}from"#shared/guards.js";function readLegacyTurnInput(e){if(!isObject(e)||e.version!==1&&e.version!==2)throw Error(`Unsupported legacy turn input version.`);let t=e.stepInput;if(!isObject(t)||typeof e.completionToken!=`string`||!e.completionToken)throw Error(`Invalid legacy turn input.`);let n=isObject(e.initialStep)&&isObject(e.initialStep.result)?e.initialStep.result:void 0,r=
|
|
1
|
+
import{isObject}from"#shared/guards.js";function readLegacyTurnInput(e){if(!isObject(e)||e.version!==1&&e.version!==2)throw Error(`Unsupported legacy turn input version.`);let t=e.stepInput;if(!isObject(t)||typeof e.completionToken!=`string`||!e.completionToken)throw Error(`Invalid legacy turn input.`);let n=isObject(e.initialStep)&&isObject(e.initialStep.result)?e.initialStep.result:void 0,r=n?.sessionState??t.sessionState,i=n?.serializedContext??t.serializedContext;if(!isObject(r)||typeof r.sessionId!=`string`||!r.sessionId||!isObject(i)||t.parentWritable===void 0)throw Error(`Legacy turn input has no session checkpoint or output stream.`);let a=t.input;if(n===void 0&&a!==void 0&&(!isObject(a)||![`deliver`,`clear`,`compact`,`runtime-action-result`].includes(String(a.kind))||a.kind===`deliver`&&!Array.isArray(a.payloads)))throw Error(`Unsupported legacy turn delivery.`);let o=n===void 0&&isObject(a)&&a.kind===`deliver`?a:void 0;return{completionToken:e.completionToken,capabilities:e.capabilities,retention:e.retention,sessionWritable:t.parentWritable,serializedContext:i,sessionState:r,delivery:o,inputCommitted:n!==void 0}}export{readLegacyTurnInput};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{createLogger,logError}from"#internal/logging.js";import{isObject}from"#shared/guards.js";import{walkCauseChain}from"#shared/errors.js";import{
|
|
1
|
+
import{createLogger,logError}from"#internal/logging.js";import{isObject}from"#shared/guards.js";import{walkCauseChain}from"#shared/errors.js";import{EntityConflictError,RunExpiredError,WorkflowRunNotFoundError}from"#compiled/@workflow/errors/index.js";import{cancelRun,getWorld}from"#internal/workflow/runtime.js";import{terminateChildSessionsStep}from"#execution/terminate-child-sessions-step.js";import{settleCancelledTurn}from"#execution/settle-cancelled-turn-step.js";async function interruptLegacySessionStep(e){"use step";let t={...e.sessionState,snapshot:{session:{...e.originalSession,history:e.sessionState.snapshot.session.history}}};try{await terminateChildSessionsStep({sessionState:t})}catch(e){logError(createLogger(`execution.legacy-session`),`could not cooperatively stop legacy children`,e)}let n=await getWorld(),r=e.originalSession.state,i=new Set,a=r?.[`eve.runtime.workflowToolRuns`];if(Array.isArray(a))for(let e of a)isObject(e)&&typeof e.runId==`string`&&i.add(e.runId);let o=r?.[`eve.agent.handles`];if(isObject(o)&&Array.isArray(o.handles))for(let e of o.handles)isObject(e)&&isObject(e.address)&&(e.address.kind===`agent/local`||e.address.kind===`agent/self`)&&typeof e.address.sessionId==`string`&&i.add(e.address.sessionId);let s=r?.[`eve.tasks`];if(isObject(s)&&Array.isArray(s.tasks))for(let e of s.tasks)isObject(e)&&typeof e.taskRunId==`string`&&i.add(e.taskRunId);for(let t of i)if(t&&t!==e.sessionState.sessionId)try{await cancelRun(n,t,{cancelReason:`Session upgraded`})}catch(e){if(![...walkCauseChain(e)].some(e=>EntityConflictError.is(e)||RunExpiredError.is(e)||WorkflowRunNotFoundError.is(e)))throw e}return e.input.inputCommitted||e.sessionState.emissionState.turnId===``?{sessionState:e.sessionState,serializedContext:e.serializedContext}:await settleCancelledTurn({reportUsage:!1,sessionWritable:e.input.sessionWritable,serializedContext:e.serializedContext,sessionState:e.sessionState})}export{interruptLegacySessionStep};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{derivePendingState}from"#execution/session/pending-turn-state.js";async function runModelCallBatch(e){let t=e.initialSession,n=e.initialInput,r=0;for(;;){let i=await e.runStep({firstCall:r===0,session:t,stepInput:n});if(r++,e.steeringSignal?.aborted===!0||i.steered===!0||!shouldRunAnotherModelCall({completedModelCalls:r,modelCallsPerStep:e.modelCallsPerStep,result:i}))return i;t=i.session,n=void 0}}function shouldRunAnotherModelCall(e){if(e.completedModelCalls>=e.modelCallsPerStep||typeof e.result.next!=`function
|
|
1
|
+
import{derivePendingState}from"#execution/session/pending-turn-state.js";async function runModelCallBatch(e){let t=e.initialSession,n=e.initialInput,r=0;for(;;){let i=await e.runStep({firstCall:r===0,session:t,stepInput:n});if(r++,e.steeringSignal?.aborted===!0||i.steered===!0||!shouldRunAnotherModelCall({completedModelCalls:r,modelCallsPerStep:e.modelCallsPerStep,result:i}))return i;t=i.session,n=void 0}}function shouldRunAnotherModelCall(e){if(e.completedModelCalls>=e.modelCallsPerStep||typeof e.result.next!=`function`)return!1;let t=derivePendingState(e.result.session);return!t.hasPendingAuthorization&&!t.hasPendingInputBatch&&(t.pendingCoordinationCallIds?.length??0)===0}export{runModelCallBatch};
|
|
@@ -62,7 +62,7 @@ export declare function buildRuntimeIdentity(node: ResolvedRuntimeAgentNode): Ru
|
|
|
62
62
|
* Resolves unified {@link HarnessToolDefinition}s from the node's registries.
|
|
63
63
|
*
|
|
64
64
|
* For authored tools: copies all lifecycle fields from the resolved definition.
|
|
65
|
-
* Prepared workflow-
|
|
65
|
+
* Prepared workflow-backed tools share the workflow-tool harness path.
|
|
66
66
|
* Tools without `execute` (provider-managed) get entries with schema but no execute.
|
|
67
67
|
*/
|
|
68
68
|
export declare function createNodeHarnessTools(input: {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{createLogger}from"#internal/logging.js";import{resolveInstalledPackageInfo}from"#internal/application/package.js";import{UNSPECIFIED_INPUT_SCHEMA}from"#tools/schema.js";import{createToolExecuteWithAuth}from"#execution/tool-auth.js";import{resolveRuntimeModelReference}from"#runtime/agent/resolve-model.js";import{createPreparedWorkflowToolHarnessDefinition,createWorkflowToolHarnessDefinition}from"#execution/tools/workflow/
|
|
1
|
+
import{createLogger}from"#internal/logging.js";import{resolveInstalledPackageInfo}from"#internal/application/package.js";import{UNSPECIFIED_INPUT_SCHEMA}from"#tools/schema.js";import{createToolExecuteWithAuth}from"#execution/tool-auth.js";import{resolveRuntimeModelReference}from"#runtime/agent/resolve-model.js";import{createPreparedWorkflowToolHarnessDefinition,createWorkflowToolHarnessDefinition}from"#execution/tools/workflow/harness-definition.js";import{LOAD_SKILL_TOOL_NAME}from"#runtime/skills/fragment-context.js";import{dispatchDynamicModelEvent}from"#context/dynamic-model-lifecycle.js";import{preparePersistedStepDynamicToolMetadata}from"#context/dynamic-tool-lifecycle.js";import{createToolLoopHarness}from"#harness/tool-loop.js";import{workflowIdForHandling}from"#runtime/subagents/workflow-reference.js";import{findRegisteredRuntimeTool}from"#runtime/tools/registry.js";import{WEB_SEARCH_TOOL_NAME,resolveWebSearchActivityLabel}from"#harness/provider-tool-schemas.js";const log=createLogger(`execution.node-step`);function createExecutionNodeStep(e){let t=createRuntimeModelResolver(e.modelResolutionScope),n=e.node.turnAgent.dynamicModel===void 0?void 0:createRuntimeDynamicModelEventDispatcher(e.modelResolutionScope,e.node.turnAgent.dynamicModel,e.abortSignal),r=createNodeHarnessTools({node:e.node}),i=e.instrumentation,a=i?.prepareExecution(),o=createToolLoopHarness({steeringSignal:e.steeringSignal,abortSignal:e.abortSignal,capabilities:e.capabilities,clearOnly:e.clearOnly,compactOnly:e.compactOnly,handleEvent:e.handleEvent,historyProjector:e.historyProjector,historyView:e.historyView,instrumentation:a,prepareApprovalTurn:e.prepareApprovalTurn,resolveStepDynamicTools:t=>preparePersistedStepDynamicToolMetadata({...t,resolvers:e.node.agent.dynamicToolResolvers??[]}),dispatchDynamicModelEvent:n,resolveModel:t,runtimeIdentity:buildRuntimeIdentity(e.node),tools:r});return i===void 0?o:async(e,t)=>{try{return await o(e,t)}finally{await i.flush()}}}function buildRuntimeIdentity(e){let t=resolveInstalledPackageInfo(),n={agentId:e.turnAgent.id,agentName:e.agent.config?.name,eveVersion:t.version},r=process.env.VERCEL_GIT_COMMIT_SHA?.trim(),i=process.env.VERCEL_GIT_COMMIT_REF?.trim(),a=process.env.VERCEL_DEPLOYMENT_CREATED_AT?.trim();return r||i||a?{...n,build:{deployedAt:a||void 0,gitBranch:i||void 0,gitSha:r||void 0}}:n}function createRuntimeModelResolver(e){return t=>resolveRuntimeModelReference(t,e)}function createRuntimeDynamicModelEventDispatcher(e,t,n){return r=>dispatchDynamicModelEvent({abortSignal:n,ctx:r.ctx,dynamicModel:t,event:r.event,messages:r.messages,scope:e})}function createNodeHarnessTools(e){let t=new Map;for(let n of e.node.turnAgent.tools){let r=resolveHarnessToolDefinition({node:e.node,tool:n});r!==null&&t.set(n.name,r)}return t}function resolveHarnessToolDefinition(e){let t=findRegisteredRuntimeTool(e.node.toolRegistry,e.tool.name),n=workflowIdForHandling(e.tool.behavior?.handling);return n===void 0?t===null?(log.warn(`declared tool is not registered — omitting from toolset`,{toolName:e.tool.name,nodeId:e.node.nodeId}),null):createRegisteredHarnessToolDefinition({behavior:e.tool.behavior,definition:t.definition,rootOnly:e.tool.rootOnly}):t===null?createPreparedWorkflowToolHarnessDefinition(e.tool):createWorkflowToolHarnessDefinition({executeInput:t.definition.executeInput,definition:createRegisteredHarnessToolDefinition({behavior:e.tool.behavior,definition:t.definition,rootOnly:e.tool.rootOnly}),workflowId:n})}function createRegisteredHarnessToolDefinition(e){let t=e.definition,n=t.execute;return{availableInSubagents:t.availableInSubagents,label:t.label??(t.owner.kind===`framework`&&t.name===WEB_SEARCH_TOOL_NAME?{start:resolveWebSearchActivityLabel}:void 0),approvalKey:t.approvalKey,behavior:e.behavior,description:t.description,endsTurn:t.endsTurn,executeInput:t.executeInput,execute:resolveAuthoredExecute({rawExecute:n,scope:t.name}),frameworkAction:t.owner.kind===`framework`&&t.name===LOAD_SKILL_TOOL_NAME?`load-skill`:void 0,inputSchema:t.inputSchema??UNSPECIFIED_INPUT_SCHEMA,name:t.name,approval:t.approval,outputSchema:t.outputSchema,rootOnly:e.rootOnly,toModelOutput:t.toModelOutput}}function resolveAuthoredExecute(e){let{rawExecute:t,scope:n}=e;return t===void 0?void 0:createToolExecuteWithAuth({execute:t,scope:n})}export{buildRuntimeIdentity,createExecutionNodeStep,createNodeHarnessTools};
|
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
import type { DeliverHookPayload } from "#channel/types.js";
|
|
2
2
|
import { type DurableSessionState } from "#execution/durable-session-store.js";
|
|
3
|
+
import { type SessionStepState } from "#execution/publish-session-events.js";
|
|
4
|
+
import { type WithSessionStateDelta } from "#execution/session/state-delta.js";
|
|
3
5
|
export type RoutedDeliverResult = {
|
|
4
6
|
readonly kind: "cancel-turn";
|
|
5
7
|
readonly serializedContext: Record<string, unknown>;
|
|
@@ -10,10 +12,11 @@ export type RoutedDeliverResult = {
|
|
|
10
12
|
readonly serializedContext: Record<string, unknown>;
|
|
11
13
|
readonly sessionState: DurableSessionState;
|
|
12
14
|
};
|
|
13
|
-
/**
|
|
14
|
-
|
|
15
|
+
/**
|
|
16
|
+
* Splits an envelope and forwards descendant input to the child that asked for
|
|
17
|
+
* it. This session relayed each forwarded request's `input.requested`, so it
|
|
18
|
+
* also relays their `input.resolved` once the answers are on their way down.
|
|
19
|
+
*/
|
|
20
|
+
export declare function routeProxiedDeliverStep(input: SessionStepState & {
|
|
15
21
|
readonly delivery: DeliverHookPayload;
|
|
16
|
-
|
|
17
|
-
readonly serializedContext?: Record<string, unknown>;
|
|
18
|
-
readonly sessionState: DurableSessionState;
|
|
19
|
-
}): Promise<RoutedDeliverResult>;
|
|
22
|
+
}): Promise<WithSessionStateDelta<RoutedDeliverResult>>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{createInputResolvedEvent
|
|
1
|
+
import{createInputResolvedEvent}from"#protocol/message.js";import{BundleKey}from"#runtime/sessions/runtime-context-keys.js";import{resolveRemoteAgentStreamHeaders,respondToRemoteAgentSession}from"#execution/agent-sessions/remote.js";import{readDurableSession,replaceDurableSessionSnapshot}from"#execution/durable-session-store.js";import{deserializeContext}from"#context/serialize.js";import{resumeSessionInbox}from"#execution/session-inbox/resume.js";import{relaySessionEvents}from"#execution/publish-session-events.js";import{withSessionStateDelta}from"#execution/session/state-delta.js";import{retireProxyInputRequests}from"#harness/proxy-input-requests.js";import{coalesceDeliverPayloads}from"#execution/deliver-payloads.js";import{hasDelegatedSessionContext}from"#execution/delegated-session-context.js";import{routeDeliverPayload}from"#subagents/hitl-proxy.js";import{sendWorkflowAskAnswers,toToolInputResponseResponder}from"#execution/tools/workflow/answer.js";async function routeProxiedDeliverStep(e){"use step";return await withSessionStateDelta(e,routeProxiedDeliver)}async function routeProxiedDeliver(e){let t=readDurableSession(e.sessionState),n=e.delivery,r=new Map,i=new Map,a,o=!hasDelegatedSessionContext(e.serializedContext)&&n.caller===void 0,s=new Set;for(let[e,c]of n.payloads.entries()){let l=routeDeliverPayload({allowRoute:e=>!s.has(e),payload:c,resolveMessage:o,state:t.state});a??=l.parentAction,l.forSelf!==void 0&&r.set(e,l.forSelf);for(let[t,r]of l.forChildren.entries()){if(r.workflowAsk!==void 0)for(let{requestId:e}of r.resolved.resolutions)s.add(e);let a=JSON.stringify([r.childContinuationToken,r.childSessionInbox?.sessionId??``,r.remote?.sessionId??``,r.resolved.event.sequence,r.resolved.event.stepIndex,r.resolved.event.turnId,r.inputSource??null]),o=i.get(a)??{workflowAsk:r.workflowAsk,remote:r.remote,childContinuationToken:r.childContinuationToken,childSessionInbox:r.childSessionInbox,event:r.resolved.event,metadata:[],payloads:[],resolutions:new Map},c=o.payloads.length;o.payloads.push(r.payload);for(let e of r.resolved.resolutions)o.resolutions.has(e.requestId)||o.resolutions.set(e.requestId,e);if(l.forSelf===void 0&&t===0)for(let t of n.deliveryMetadata??[])t.payloadIndex===e&&o.metadata.push({...t,payloadIndex:c});i.set(a,o)}}let c=!1,l=[];for(let r of i.values()){if(r.workflowAsk!==void 0){let e=coalesceDeliverPayloads(r.payloads).inputResponses??[];await sendWorkflowAskAnswers(r.workflowAsk,e,toToolInputResponseResponder(n.auth))}else{let t={...n,deliveryMetadata:r.metadata.length===0?void 0:r.metadata,payloads:r.payloads},i=r.remote;if(i!==void 0){let t=await deserializeContext(e.serializedContext),a=await resolveRemoteAgentStreamHeaders({bundle:t.require(BundleKey),name:i.name,resolverId:i.resolverId,url:i.url});await respondToRemoteAgentSession({remote:i,headers:a,auth:n.auth,responses:coalesceDeliverPayloads(r.payloads).inputResponses??[]})}else await resumeSessionInbox(r.childSessionInbox??r.childContinuationToken,t)}r.resolutions.size>0&&l.push(createInputResolvedEvent({resolutions:[...r.resolutions.values()],...r.event})),t=retireProxyInputRequests(t,[...r.resolutions.keys()]),c=!0}let u=await relaySessionEvents({serializedContext:e.serializedContext,sessionState:c?replaceDurableSessionSnapshot({session:t,state:e.sessionState}):e.sessionState,sessionWritable:e.sessionWritable},l);if(a!==void 0)return{...u,...a};let d=[...r].sort(([e],[t])=>e-t),f=d.flatMap(([e],t)=>(n.deliveryMetadata??[]).filter(t=>t.payloadIndex===e).map(e=>({...e,payloadIndex:t}))),p=d.length===0?void 0:{...n,deliveryMetadata:f.length===0?void 0:f,payloads:d.map(([,e])=>e)};return{...u,kind:`continue`,remainder:p}}export{routeProxiedDeliverStep};
|