eve 0.72.1 → 0.74.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 +44 -0
- package/dist/src/_virtual/_rolldown/runtime.js +1 -1
- package/dist/src/channel/agent-description.d.ts +49 -9
- package/dist/src/channel/agent-description.js +1 -1
- package/dist/src/channel/invoke-tool.d.ts +26 -4
- package/dist/src/channel/invoke-tool.js +1 -1
- package/dist/src/channel/principal-identity.d.ts +9 -0
- package/dist/src/channel/principal-identity.js +1 -0
- package/dist/src/channel/prompt-queue.d.ts +31 -0
- package/dist/src/channel/prompt-queue.js +1 -0
- package/dist/src/channel/routes.d.ts +19 -4
- package/dist/src/channel/schedule.d.ts +20 -6
- package/dist/src/channel/schedule.js +1 -1
- package/dist/src/channel/skill-files.d.ts +114 -0
- package/dist/src/channel/skill-files.js +1 -0
- package/dist/src/channel/types.d.ts +4 -0
- package/dist/src/chunks/{use-eve-agent-C1GYGCtb.js → use-eve-agent-DOOXadF0.js} +13 -3
- package/dist/src/chunks/{use-eve-agent-hZJ7CB8t.js → use-eve-agent-mP0M7SrL.js} +13 -3
- package/dist/src/cli/commands/agent-instructions.js +1 -1
- package/dist/src/cli/commands/extension-init.js +1 -1
- package/dist/src/cli/commands/init-agent-workspace.js +1 -1
- package/dist/src/cli/commands/init-project.js +1 -1
- package/dist/src/cli/commands/init.js +1 -1
- package/dist/src/cli/dev/diagnostic-dump.js +1 -1
- package/dist/src/cli/dev/tui/blocks.d.ts +6 -0
- package/dist/src/cli/dev/tui/blocks.js +2 -2
- package/dist/src/cli/dev/tui/markdown.d.ts +5 -0
- package/dist/src/cli/dev/tui/markdown.js +2 -2
- package/dist/src/cli/dev/tui/stream-format.js +2 -2
- package/dist/src/cli/dev/tui/transcript-parts.d.ts +4 -1
- package/dist/src/cli/dev/tui/transcript-parts.js +2 -2
- package/dist/src/cli/dev/tui/transcript.js +1 -1
- package/dist/src/client/message-reducer.js +1 -1
- package/dist/src/compiled/.vendor-stamp.json +9 -8
- package/dist/src/compiled/@eve/catalog/index.js +1 -1
- package/dist/src/compiled/@modelcontextprotocol/server/index.d.ts +68 -7
- package/dist/src/compiled/@vercel/schedules/index.d.ts +158 -0
- package/dist/src/compiled/@vercel/schedules/index.js +17 -0
- package/dist/src/compiled/@workflow/core/capabilities.d.ts +33 -6
- package/dist/src/compiled/@workflow/core/flushable-stream.d.ts +2 -0
- package/dist/src/compiled/@workflow/core/index.d.ts +1 -0
- package/dist/src/compiled/@workflow/core/index.js +2 -2
- package/dist/src/compiled/@workflow/core/private.js +1 -1
- package/dist/src/compiled/@workflow/core/runtime/helpers.d.ts +6 -0
- package/dist/src/compiled/@workflow/core/runtime/helpers.js +1 -1
- package/dist/src/compiled/@workflow/core/runtime.js +3 -3
- package/dist/src/compiled/@workflow/core/serialization/codec.d.ts +8 -8
- package/dist/src/compiled/@workflow/core/serialization/compression.d.ts +13 -5
- package/dist/src/compiled/@workflow/core/serialization.d.ts +9 -9
- package/dist/src/compiled/@workflow/core/serialization.js +1 -1
- package/dist/src/compiled/@workflow/core/symbols.d.ts +2 -0
- package/dist/src/compiled/@workflow/core/telemetry/semantic-conventions.d.ts +2 -2
- package/dist/src/compiled/@workflow/core/version.d.ts +1 -1
- package/dist/src/compiled/@workflow/core/workflow/index.d.ts +1 -0
- package/dist/src/compiled/@workflow/core/workflow.js +1 -1
- package/dist/src/compiled/@workflow/errors/index.js +1 -1
- package/dist/src/compiled/@workflow/world/events.d.ts +11 -0
- package/dist/src/compiled/@workflow/world/hooks.d.ts +2 -0
- package/dist/src/compiled/@workflow/world/interfaces.d.ts +6 -0
- package/dist/src/compiled/@workflow/world-local/index.js +3 -3
- package/dist/src/compiled/@workflow/world-vercel/index.js +13 -13
- package/dist/src/compiled/_chunks/workflow/{attribute-changes-VaTKT4K8.js → attribute-changes-CSqvJx6j.js} +2 -2
- package/dist/src/compiled/_chunks/workflow/{dist-B7NC1c9-.js → dist-DmXynLVH.js} +1 -1
- package/dist/src/compiled/_chunks/workflow/dist-T5NnW-0k.js +3 -0
- package/dist/src/compiled/_chunks/workflow/helpers-BXCuoPUb.js +1 -0
- package/dist/src/compiled/_chunks/workflow/private-Dlf90Zvn.js +1 -0
- package/dist/src/compiled/_chunks/workflow/resume-hook-CvENCrxc.js +1 -0
- package/dist/src/compiled/_chunks/workflow/{run-DYKeqbob.js → run-8pLWuR2U.js} +6 -6
- package/dist/src/compiled/_chunks/workflow/serialization-vDozzDhh.js +16 -0
- package/dist/src/compiled/_chunks/workflow/sleep-BMqbraZM.js +1 -0
- package/dist/src/compiled/_chunks/workflow/wait-until-A344L2AG.js +1 -0
- package/dist/src/compiled/shadcn-registry/index.js +3408 -35163
- package/dist/src/compiler/artifacts.js +1 -1
- package/dist/src/compiler/compile-agent.js +1 -1
- package/dist/src/compiler/development-extensions.js +1 -1
- package/dist/src/compiler/extension-compatibility.d.ts +18 -18
- package/dist/src/compiler/extension-compatibility.js +1 -1
- package/dist/src/compiler/load-binding-namespace.d.ts +5 -0
- package/dist/src/compiler/load-binding-namespace.js +1 -1
- package/dist/src/compiler/manifest.d.ts +39 -0
- package/dist/src/compiler/manifest.js +1 -1
- package/dist/src/compiler/memory-wrapper-candidates.d.ts +2 -0
- package/dist/src/compiler/memory-wrapper-candidates.js +1 -0
- package/dist/src/compiler/module-lifecycle.d.ts +1 -1
- package/dist/src/compiler/module-lifecycle.js +1 -1
- package/dist/src/compiler/module-map.js +1 -1
- package/dist/src/compiler/normalize-agent-config.js +1 -1
- package/dist/src/compiler/normalize-manifest.js +1 -1
- package/dist/src/compiler/normalize-schedule-collection.d.ts +3 -0
- package/dist/src/compiler/normalize-schedule-collection.js +1 -0
- package/dist/src/compiler/normalize-schedule.d.ts +2 -2
- package/dist/src/compiler/normalize-schedule.js +1 -1
- package/dist/src/compiler/resolve-workspace-subagent.js +1 -1
- package/dist/src/compiler/schedule-collection-wrapper-candidates.d.ts +2 -0
- package/dist/src/compiler/schedule-collection-wrapper-candidates.js +1 -0
- package/dist/src/compiler/validate-artifact.js +1 -1
- package/dist/src/context/build-callback-context.js +1 -1
- package/dist/src/context/dynamic-resolve-context.js +1 -1
- package/dist/src/context/key-names.d.ts +1 -0
- package/dist/src/context/key-names.js +1 -1
- package/dist/src/context/keys.d.ts +2 -0
- package/dist/src/context/keys.js +1 -1
- package/dist/src/context/providers/session.js +1 -1
- package/dist/src/context/schedule-collection-tools.d.ts +9 -0
- package/dist/src/context/schedule-collection-tools.js +1 -0
- package/dist/src/context/session-context.d.ts +4 -1
- package/dist/src/context/session-schedule.d.ts +9 -0
- package/dist/src/context/session-schedule.js +1 -0
- package/dist/src/context/turn-principals.d.ts +12 -0
- package/dist/src/context/turn-principals.js +1 -0
- package/dist/src/dynamic/definition.d.ts +1 -0
- package/dist/src/evals/cli/eval-client.js +1 -1
- package/dist/src/evals/cli/eval.js +1 -1
- package/dist/src/execution/agent-sessions/context.d.ts +2 -0
- package/dist/src/execution/agent-sessions/context.js +1 -1
- package/dist/src/execution/agent-sessions/steps.js +1 -1
- package/dist/src/execution/cancelled-model-call-batch.js +1 -1
- package/dist/src/execution/dynamic-workflow/tool.js +1 -1
- package/dist/src/execution/invoke-tool.d.ts +6 -2
- package/dist/src/execution/invoke-tool.js +1 -1
- package/dist/src/execution/legacy-session/turn-workflow.js +1 -1
- package/dist/src/execution/node-step.d.ts +1 -0
- package/dist/src/execution/node-step.js +1 -1
- package/dist/src/execution/publish-session-events.js +1 -1
- package/dist/src/execution/runtime-context.js +1 -1
- package/dist/src/execution/sandbox/bindings/just-bash.js +1 -1
- package/dist/src/execution/sandbox/bindings/vercel-errors.d.ts +11 -0
- package/dist/src/execution/sandbox/bindings/vercel-errors.js +2 -1
- package/dist/src/execution/sandbox/bindings/vercel-tool-sessions.d.ts +7 -0
- package/dist/src/execution/sandbox/bindings/vercel-tool-sessions.js +1 -0
- package/dist/src/execution/sandbox/bindings/vercel.js +1 -1
- package/dist/src/execution/sandbox/development-lazy-prewarm.js +1 -1
- package/dist/src/execution/sandbox/ensure.d.ts +14 -1
- package/dist/src/execution/sandbox/ensure.js +1 -1
- package/dist/src/execution/sandbox/prewarm.js +1 -1
- package/dist/src/execution/session/active-turn.d.ts +2 -1
- package/dist/src/execution/session/active-turn.js +1 -1
- package/dist/src/execution/session/entry.d.ts +10 -1
- package/dist/src/execution/session/entry.js +1 -1
- package/dist/src/execution/session/program.d.ts +4 -0
- package/dist/src/execution/session/program.js +1 -1
- package/dist/src/execution/session/timeout-control.d.ts +1 -2
- package/dist/src/execution/session/timeout-control.js +1 -1
- package/dist/src/execution/session/turn-control.d.ts +7 -0
- package/dist/src/execution/session/turn-control.js +1 -0
- package/dist/src/execution/session/turn-step.js +1 -1
- package/dist/src/execution/session/turn.d.ts +2 -0
- package/dist/src/execution/session/turn.js +1 -1
- package/dist/src/execution/session-inbox/protocol.js +1 -1
- package/dist/src/execution/settle-cancelled-turn-step.js +1 -1
- package/dist/src/execution/tool-session/id.d.ts +22 -0
- package/dist/src/execution/tool-session/id.js +1 -0
- package/dist/src/execution/tool-session/sandbox.d.ts +22 -0
- package/dist/src/execution/tool-session/sandbox.js +1 -0
- package/dist/src/execution/tools/agent-router-workflow.js +1 -1
- package/dist/src/execution/tools/connection-tools.js +1 -1
- package/dist/src/framework/sources/modules/schedule-collection-wrapper.d.ts +2 -0
- package/dist/src/framework/sources/modules/schedule-collection-wrapper.js +1 -0
- package/dist/src/framework/sources/registry.d.ts +1 -0
- package/dist/src/framework/sources/registry.js +1 -1
- package/dist/src/harness/compaction/step.js +1 -1
- package/dist/src/harness/emission.d.ts +1 -0
- package/dist/src/harness/emission.js +1 -1
- package/dist/src/harness/hitl/approvals.d.ts +1 -1
- package/dist/src/harness/hitl/approvals.js +1 -1
- package/dist/src/harness/hitl/delivery.d.ts +9 -2
- package/dist/src/harness/hitl/delivery.js +1 -1
- package/dist/src/harness/hitl/intake.js +1 -1
- package/dist/src/harness/model-call/call.d.ts +5 -0
- package/dist/src/harness/model-call/call.js +1 -1
- package/dist/src/harness/model-call/usage.js +1 -1
- package/dist/src/harness/open-input-request.d.ts +8 -0
- package/dist/src/harness/open-input-request.js +1 -0
- package/dist/src/harness/session-machine/current.js +1 -1
- package/dist/src/harness/session-machine/transitions.d.ts +13 -0
- package/dist/src/harness/session-machine/transitions.js +1 -1
- package/dist/src/harness/stream-actions.d.ts +6 -1
- package/dist/src/harness/stream-actions.js +1 -1
- package/dist/src/harness/tool-loop.js +1 -1
- package/dist/src/harness/tools.js +1 -1
- package/dist/src/harness/types.d.ts +2 -0
- package/dist/src/instrumentation/ai-sdk-hook-bridge.js +1 -1
- package/dist/src/instrumentation/lifecycle.d.ts +1 -0
- package/dist/src/internal/application/cache-metadata.js +1 -1
- package/dist/src/internal/application/compiled-artifacts.js +1 -1
- package/dist/src/internal/application/package.js +1 -1
- package/dist/src/internal/application/paths.js +1 -1
- package/dist/src/internal/application/runtime-compiled-artifacts-source.js +1 -1
- package/dist/src/internal/authored-definition/connection.js +1 -1
- package/dist/src/internal/authored-definition/schedule-collection.d.ts +2 -0
- package/dist/src/internal/authored-definition/schedule-collection.js +1 -0
- package/dist/src/internal/authored-definition/schema-backed.js +1 -1
- package/dist/src/internal/authored-module-loader.d.ts +7 -0
- 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.js +1 -1
- package/dist/src/internal/authored-runtime-modules.d.ts +1 -0
- package/dist/src/internal/authored-runtime-modules.js +1 -1
- package/dist/src/internal/invocation/metadata.js +1 -1
- package/dist/src/internal/mcp/forwarded-principal-header.d.ts +31 -0
- package/dist/src/internal/mcp/forwarded-principal-header.js +1 -0
- package/dist/src/internal/mcp/published-tools.d.ts +9 -2
- package/dist/src/internal/mcp/published-tools.js +1 -1
- package/dist/src/internal/mcp/skills.d.ts +57 -0
- package/dist/src/internal/mcp/skills.js +1 -0
- package/dist/src/internal/mcp/streamable-http-server.d.ts +38 -6
- package/dist/src/internal/mcp/streamable-http-server.js +1 -1
- package/dist/src/internal/nitro/dev-runtime-artifacts.js +1 -1
- package/dist/src/internal/nitro/development-generation.js +1 -1
- package/dist/src/internal/nitro/host/artifacts-config.js +1 -1
- package/dist/src/internal/nitro/host/build-application.js +1 -1
- package/dist/src/internal/nitro/host/build-extension.js +1 -1
- package/dist/src/internal/nitro/host/build-vercel-agent-summary.js +1 -1
- package/dist/src/internal/nitro/host/configure-nitro-routes.js +2 -2
- package/dist/src/internal/nitro/host/create-application-nitro.js +1 -1
- package/dist/src/internal/nitro/host/dev-authored-source-watcher.js +1 -1
- package/dist/src/internal/nitro/host/dev-runner.js +1 -1
- package/dist/src/internal/nitro/host/extension-capability-requirements.js +1 -1
- package/dist/src/internal/nitro/host/local-tracing-runtime-plugin.js +1 -1
- package/dist/src/internal/nitro/host/skill-server-assets.d.ts +29 -0
- package/dist/src/internal/nitro/host/skill-server-assets.js +1 -0
- package/dist/src/internal/nitro/host/start-production-server.js +1 -1
- package/dist/src/internal/nitro/host/vercel-build-output-config.d.ts +12 -0
- package/dist/src/internal/nitro/host/vercel-build-output-config.js +1 -1
- package/dist/src/internal/nitro/host/workspace-extensions.js +1 -1
- package/dist/src/internal/nitro/routes/channel-dispatch.js +1 -1
- package/dist/src/internal/nitro/routes/channel-route-context.d.ts +4 -0
- package/dist/src/internal/nitro/routes/channel-route-context.js +1 -1
- package/dist/src/internal/nitro/routes/schedule-collection-consumer.d.ts +3 -0
- package/dist/src/internal/nitro/routes/schedule-collection-consumer.js +1 -0
- package/dist/src/internal/schedules/consumer-route.d.ts +17 -0
- package/dist/src/internal/schedules/consumer-route.js +1 -0
- package/dist/src/internal/schedules/verify-delivery.d.ts +25 -0
- package/dist/src/internal/schedules/verify-delivery.js +1 -0
- package/dist/src/internal/vercel/build-agent-workspace.js +1 -1
- package/dist/src/internal/workflow/development-world-client.js +1 -1
- package/dist/src/internal/workflow/validate-world.js +1 -1
- package/dist/src/internal/workflow/vercel-world-defaults.js +1 -1
- package/dist/src/internal/workflow-bundle/builder-support.js +1 -1
- package/dist/src/internal/workflow-bundle/builder.js +1 -1
- package/dist/src/internal/workflow-bundle/workflow-builders.js +1 -1
- package/dist/src/node_modules/.pnpm/@vercel_cli-config@0.2.0/node_modules/@vercel/cli-config/dist/cli-config.js +1 -0
- package/dist/src/node_modules/.pnpm/@vercel_cli-config@0.2.0/node_modules/@vercel/cli-config/dist/cred-storage.js +1 -0
- package/dist/src/node_modules/.pnpm/@vercel_cli-config@0.2.0/node_modules/@vercel/cli-config/dist/index.js +1 -0
- package/dist/src/node_modules/.pnpm/@vercel_cli-config@0.2.0/node_modules/@vercel/cli-config/dist/schema.js +1 -0
- package/dist/src/node_modules/.pnpm/@vercel_cli-config@0.2.0/node_modules/@vercel/cli-config/dist/schema.zod.js +1 -0
- package/dist/src/node_modules/.pnpm/@vercel_cli-config@0.2.0/node_modules/@vercel/cli-config/dist/types.js +1 -0
- package/dist/src/node_modules/.pnpm/@vercel_cli-exec@1.0.0/node_modules/@vercel/cli-exec/dist/envpath.js +1 -0
- package/dist/src/node_modules/.pnpm/@vercel_cli-exec@1.0.0/node_modules/@vercel/cli-exec/dist/errors.js +2 -0
- package/dist/src/node_modules/.pnpm/@vercel_cli-exec@1.0.0/node_modules/@vercel/cli-exec/dist/errutils.js +1 -0
- package/dist/src/node_modules/.pnpm/@vercel_cli-exec@1.0.0/node_modules/@vercel/cli-exec/dist/exec.js +1 -0
- package/dist/src/node_modules/.pnpm/@vercel_cli-exec@1.0.0/node_modules/@vercel/cli-exec/dist/fsutils.js +1 -0
- package/dist/src/node_modules/.pnpm/@vercel_cli-exec@1.0.0/node_modules/@vercel/cli-exec/dist/index.js +1 -0
- package/dist/src/node_modules/.pnpm/@vercel_cli-exec@1.0.0/node_modules/@vercel/cli-exec/dist/lookup.js +1 -0
- package/dist/src/node_modules/.pnpm/@vercel_cli-exec@1.0.0/node_modules/@vercel/cli-exec/dist/safety.js +1 -0
- package/dist/src/node_modules/.pnpm/@vercel_oidc@3.8.0/node_modules/@vercel/oidc/dist/auth-errors.js +1 -0
- package/dist/src/node_modules/.pnpm/@vercel_oidc@3.8.0/node_modules/@vercel/oidc/dist/exchange-vercel-oidc-token.js +1 -0
- package/dist/src/node_modules/.pnpm/@vercel_oidc@3.8.0/node_modules/@vercel/oidc/dist/get-context.js +1 -0
- package/dist/src/node_modules/.pnpm/@vercel_oidc@3.8.0/node_modules/@vercel/oidc/dist/get-vercel-oidc-token-sync.js +1 -0
- package/dist/src/node_modules/.pnpm/@vercel_oidc@3.8.0/node_modules/@vercel/oidc/dist/get-vercel-oidc-token-with-refresh.js +2 -0
- package/dist/src/node_modules/.pnpm/@vercel_oidc@3.8.0/node_modules/@vercel/oidc/dist/index.js +1 -0
- package/dist/src/node_modules/.pnpm/@vercel_oidc@3.8.0/node_modules/@vercel/oidc/dist/oauth.js +1 -0
- package/dist/src/node_modules/.pnpm/@vercel_oidc@3.8.0/node_modules/@vercel/oidc/dist/token-error.js +1 -0
- package/dist/src/node_modules/.pnpm/@vercel_oidc@3.8.0/node_modules/@vercel/oidc/dist/token-io.js +1 -0
- package/dist/src/node_modules/.pnpm/@vercel_oidc@3.8.0/node_modules/@vercel/oidc/dist/token-util.js +2 -0
- package/dist/src/node_modules/.pnpm/@vercel_oidc@3.8.0/node_modules/@vercel/oidc/dist/token.js +1 -0
- package/dist/src/node_modules/.pnpm/@vercel_oidc@3.8.0/node_modules/@vercel/oidc/dist/verify-vercel-oidc-token.js +1 -0
- package/dist/src/node_modules/.pnpm/@vercel_oidc@3.8.0/node_modules/@vercel/oidc/dist/version.js +1 -0
- package/dist/src/node_modules/.pnpm/@vercel_queue@0.5.1_@opentelemetry_api@1.9.1/node_modules/@vercel/queue/dist/index.js +36 -0
- package/dist/src/node_modules/.pnpm/balanced-match@4.0.4/node_modules/balanced-match/dist/esm/index.js +1 -0
- package/dist/src/node_modules/.pnpm/brace-expansion@5.0.12/node_modules/brace-expansion/dist/esm/index.js +1 -0
- package/dist/src/node_modules/.pnpm/cross-spawn@7.0.6/node_modules/cross-spawn/index.js +1 -0
- package/dist/src/node_modules/.pnpm/cross-spawn@7.0.6/node_modules/cross-spawn/lib/enoent.js +1 -0
- package/dist/src/node_modules/.pnpm/cross-spawn@7.0.6/node_modules/cross-spawn/lib/parse.js +1 -0
- package/dist/src/node_modules/.pnpm/cross-spawn@7.0.6/node_modules/cross-spawn/lib/util/escape.js +1 -0
- package/dist/src/node_modules/.pnpm/cross-spawn@7.0.6/node_modules/cross-spawn/lib/util/readShebang.js +1 -0
- package/dist/src/node_modules/.pnpm/cross-spawn@7.0.6/node_modules/cross-spawn/lib/util/resolveCommand.js +1 -0
- package/dist/src/node_modules/.pnpm/execa@5.1.1/node_modules/execa/index.js +1 -0
- package/dist/src/node_modules/.pnpm/execa@5.1.1/node_modules/execa/lib/command.js +1 -0
- package/dist/src/node_modules/.pnpm/execa@5.1.1/node_modules/execa/lib/error.js +2 -0
- package/dist/src/node_modules/.pnpm/execa@5.1.1/node_modules/execa/lib/kill.js +1 -0
- package/dist/src/node_modules/.pnpm/execa@5.1.1/node_modules/execa/lib/promise.js +1 -0
- package/dist/src/node_modules/.pnpm/execa@5.1.1/node_modules/execa/lib/stdio.js +1 -0
- package/dist/src/node_modules/.pnpm/execa@5.1.1/node_modules/execa/lib/stream.js +1 -0
- package/dist/src/node_modules/.pnpm/get-stream@6.0.1/node_modules/get-stream/buffer-stream.js +1 -0
- package/dist/src/node_modules/.pnpm/get-stream@6.0.1/node_modules/get-stream/index.js +1 -0
- package/dist/src/node_modules/.pnpm/human-signals@2.1.0/node_modules/human-signals/build/src/core.js +1 -0
- package/dist/src/node_modules/.pnpm/human-signals@2.1.0/node_modules/human-signals/build/src/main.js +1 -0
- package/dist/src/node_modules/.pnpm/human-signals@2.1.0/node_modules/human-signals/build/src/realtime.js +1 -0
- package/dist/src/node_modules/.pnpm/human-signals@2.1.0/node_modules/human-signals/build/src/signals.js +1 -0
- package/dist/src/node_modules/.pnpm/is-stream@2.0.1/node_modules/is-stream/index.js +1 -0
- package/dist/src/node_modules/.pnpm/isexe@2.0.0/node_modules/isexe/index.js +1 -0
- package/dist/src/node_modules/.pnpm/isexe@2.0.0/node_modules/isexe/mode.js +1 -0
- package/dist/src/node_modules/.pnpm/isexe@2.0.0/node_modules/isexe/windows.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/index.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwe/compact/decrypt.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwe/compact/encrypt.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwe/flattened/decrypt.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwe/flattened/encrypt.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwe/general/decrypt.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwe/general/encrypt.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwk/embedded.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwk/thumbprint.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwks/local.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwks/remote.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jws/compact/sign.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jws/compact/verify.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jws/flattened/sign.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jws/flattened/verify.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jws/general/sign.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jws/general/verify.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwt/decrypt.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwt/encrypt.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwt/produce.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwt/sign.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwt/unsecured.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwt/verify.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/key/export.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/key/generate_key_pair.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/key/generate_secret.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/key/import.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/aesgcmkw.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/buffer_utils.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/cek.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/check_iv_length.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/check_key_type.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/check_p2s.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/crypto_key.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/decrypt_key_management.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/encrypt_key_management.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/epoch.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/invalid_key_input.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/is_disjoint.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/is_jwk.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/is_object.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/iv.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/jwt_claims_set.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/private_symbols.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/secs.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/validate_algorithms.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/validate_crit.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/aeskw.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/asn1.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/base64url.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/cbc_tag.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/check_cek_length.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/check_key_length.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/ciphers.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/decrypt.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/digest.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/dsa_digest.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/ecdhes.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/encrypt.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/fetch_jwks.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/generate.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/get_named_curve.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/get_sign_verify_key.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/hmac_digest.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/is_key_like.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/is_key_object.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/jwk_to_key.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/key_to_jwk.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/node_key.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/normalize_key.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/pbes2kw.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/random.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/rsaes.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/runtime.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/sign.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/timing_safe_equal.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/verify.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/webcrypto.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/util/base64url.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/util/decode_jwt.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/util/decode_protected_header.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/util/errors.js +1 -0
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/util/runtime.js +1 -0
- package/dist/src/node_modules/.pnpm/merge-stream@2.0.0/node_modules/merge-stream/index.js +1 -0
- package/dist/src/node_modules/.pnpm/mimic-fn@2.1.0/node_modules/mimic-fn/index.js +1 -0
- package/dist/src/node_modules/.pnpm/minimatch@10.2.6/node_modules/minimatch/dist/esm/assert-valid-pattern.js +1 -0
- package/dist/src/node_modules/.pnpm/minimatch@10.2.6/node_modules/minimatch/dist/esm/ast.js +1 -0
- package/dist/src/node_modules/.pnpm/minimatch@10.2.6/node_modules/minimatch/dist/esm/brace-expressions.js +1 -0
- package/dist/src/node_modules/.pnpm/minimatch@10.2.6/node_modules/minimatch/dist/esm/escape.js +1 -0
- package/dist/src/node_modules/.pnpm/minimatch@10.2.6/node_modules/minimatch/dist/esm/index.js +1 -0
- package/dist/src/node_modules/.pnpm/minimatch@10.2.6/node_modules/minimatch/dist/esm/unescape.js +1 -0
- package/dist/src/node_modules/.pnpm/mixpart@0.0.6/node_modules/mixpart/dist/index.js +7 -0
- package/dist/src/node_modules/.pnpm/npm-run-path@4.0.1/node_modules/npm-run-path/index.js +1 -0
- package/dist/src/node_modules/.pnpm/onetime@5.1.2/node_modules/onetime/index.js +1 -0
- package/dist/src/node_modules/.pnpm/os-paths@4.4.0/node_modules/os-paths/src/lib/index.js +1 -0
- package/dist/src/node_modules/.pnpm/path-key@3.1.1/node_modules/path-key/index.js +1 -0
- package/dist/src/node_modules/.pnpm/picocolors@1.1.1/node_modules/picocolors/picocolors.js +1 -0
- package/dist/src/node_modules/.pnpm/shebang-command@2.0.0/node_modules/shebang-command/index.js +1 -0
- package/dist/src/node_modules/.pnpm/shebang-regex@3.0.0/node_modules/shebang-regex/index.js +1 -0
- package/dist/src/node_modules/.pnpm/signal-exit@3.0.7/node_modules/signal-exit/index.js +1 -0
- package/dist/src/node_modules/.pnpm/signal-exit@3.0.7/node_modules/signal-exit/signals.js +1 -0
- package/dist/src/node_modules/.pnpm/strip-final-newline@2.0.0/node_modules/strip-final-newline/index.js +2 -0
- package/dist/src/node_modules/.pnpm/which@2.0.2/node_modules/which/which.js +1 -0
- package/dist/src/node_modules/.pnpm/xdg-app-paths@5.5.1/node_modules/xdg-app-paths/src/lib/index.js +1 -0
- package/dist/src/node_modules/.pnpm/xdg-portable@7.3.0/node_modules/xdg-portable/src/lib/index.js +1 -0
- package/dist/src/public/channels/chat-sdk/authorization.js +1 -1
- package/dist/src/public/channels/chat-sdk/chatSdkChannel.d.ts +7 -1
- package/dist/src/public/channels/chat-sdk/chatSdkChannel.js +2 -2
- package/dist/src/public/channels/discord/defaults.d.ts +8 -7
- package/dist/src/public/channels/discord/discordChannel.d.ts +21 -1
- package/dist/src/public/channels/discord/discordChannel.js +1 -1
- package/dist/src/public/channels/discord/index.d.ts +1 -1
- package/dist/src/public/channels/github/defaults.js +3 -3
- package/dist/src/public/channels/github/githubChannel.d.ts +4 -1
- package/dist/src/public/channels/github/state.d.ts +2 -1
- package/dist/src/public/channels/index.d.ts +1 -1
- package/dist/src/public/channels/linear/defaults.js +1 -1
- package/dist/src/public/channels/linear/linearChannel.d.ts +4 -1
- package/dist/src/public/channels/mcp.d.ts +26 -5
- package/dist/src/public/channels/mcp.js +1 -1
- package/dist/src/public/channels/slack/index.d.ts +1 -0
- package/dist/src/public/channels/slack/index.js +1 -1
- package/dist/src/public/channels/slack/interactions.js +1 -1
- package/dist/src/public/channels/slack/slackChannel.d.ts +6 -0
- package/dist/src/public/channels/twilio/defaults.js +2 -4
- package/dist/src/public/channels/twilio/twilioChannel.d.ts +4 -1
- package/dist/src/public/definitions/channel.d.ts +1 -1
- package/dist/src/public/definitions/connections/mcp.d.ts +11 -0
- package/dist/src/public/experimental/schedules/client.d.ts +7 -0
- package/dist/src/public/experimental/schedules/client.js +1 -0
- package/dist/src/public/experimental/schedules/index.d.ts +5 -0
- package/dist/src/public/experimental/schedules/index.js +1 -0
- package/dist/src/public/experimental/schedules/testing.d.ts +2 -0
- package/dist/src/public/experimental/schedules/testing.js +1 -0
- package/dist/src/public/experimental/schedules/vercel.d.ts +2 -0
- package/dist/src/public/experimental/schedules/vercel.js +1 -0
- package/dist/src/public/memory/scope.js +1 -1
- package/dist/src/public/schedules/provider-types.d.ts +16 -0
- package/dist/src/public/schedules/provider-types.js +1 -0
- package/dist/src/public/schedules/providers/in-memory.d.ts +5 -0
- package/dist/src/public/schedules/providers/in-memory.js +1 -0
- package/dist/src/public/schedules/providers/vercel.d.ts +10 -0
- package/dist/src/public/schedules/providers/vercel.js +1 -0
- package/dist/src/public/schedules/scope.d.ts +2 -0
- package/dist/src/public/schedules/scope.js +1 -0
- package/dist/src/public/schedules/subscription.d.ts +259 -0
- package/dist/src/public/schedules/subscription.js +1 -0
- package/dist/src/public/schedules/testing.d.ts +1 -0
- package/dist/src/public/schedules/testing.js +1 -0
- package/dist/src/public/sveltekit/dev-server.js +1 -1
- package/dist/src/runtime/cache-key.js +1 -1
- package/dist/src/runtime/connections/mcp-client.js +1 -1
- package/dist/src/runtime/loaders/compile-metadata.js +1 -1
- package/dist/src/runtime/loaders/manifest.js +1 -1
- package/dist/src/runtime/loaders/module-map.js +1 -1
- package/dist/src/runtime/resolve-connection.js +1 -1
- package/dist/src/runtime/sandbox/prepared-artifacts.js +1 -1
- package/dist/src/runtime/schedules/collection-client.d.ts +20 -0
- package/dist/src/runtime/schedules/collection-client.js +1 -0
- package/dist/src/runtime/schedules/dispatch-occurrence.d.ts +12 -0
- package/dist/src/runtime/schedules/dispatch-occurrence.js +1 -0
- package/dist/src/runtime/schedules/load-collection.d.ts +14 -0
- package/dist/src/runtime/schedules/load-collection.js +1 -0
- package/dist/src/runtime/schedules/payload.d.ts +24 -0
- package/dist/src/runtime/schedules/payload.js +1 -0
- package/dist/src/runtime/schedules/provider-types.d.ts +1 -0
- package/dist/src/runtime/schedules/provider-types.js +1 -0
- package/dist/src/runtime/schedules/queue-namespace.d.ts +2 -0
- package/dist/src/runtime/schedules/queue-namespace.js +1 -0
- package/dist/src/runtime/schedules/record.d.ts +4 -0
- package/dist/src/runtime/schedules/record.js +1 -0
- package/dist/src/runtime/schedules/validation.d.ts +6 -0
- package/dist/src/runtime/schedules/validation.js +1 -0
- 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/runtime-session.d.ts +10 -0
- package/dist/src/runtime/sessions/runtime-session.js +1 -1
- package/dist/src/runtime/types.d.ts +2 -0
- package/dist/src/self-modification/config.d.ts +4 -63
- package/dist/src/self-modification/config.js +1 -1
- package/dist/src/self-modification/credentials.d.ts +1 -1
- package/dist/src/self-modification/deployed-sandbox.d.ts +14 -0
- package/dist/src/self-modification/deployed-sandbox.js +1 -0
- package/dist/src/self-modification/extension/config-schema.d.ts +2 -17
- package/dist/src/self-modification/extension/config-schema.js +1 -1
- package/dist/src/self-modification/extension/local-only.d.ts +1 -1
- package/dist/src/self-modification/extension/local-only.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 +3 -35
- package/dist/src/self-modification/extension/subagents/agent/tools/registry_add.d.ts +3 -31
- package/dist/src/self-modification/extension/subagents/agent/tools/registry_add.js +1 -1
- package/dist/src/self-modification/git-workspace.d.ts +1 -2
- package/dist/src/self-modification/git-workspace.js +1 -1
- package/dist/src/self-modification/github-publisher.d.ts +1 -1
- package/dist/src/self-modification/mode.d.ts +4 -4
- package/dist/src/self-modification/mode.js +1 -1
- package/dist/src/self-modification/proposal.js +1 -1
- package/dist/src/self-modification/remote/config-schema.d.ts +20 -0
- package/dist/src/self-modification/remote/config-schema.js +1 -0
- package/dist/src/self-modification/remote/config.d.ts +66 -0
- package/dist/src/self-modification/remote/config.js +1 -0
- package/dist/src/self-modification/remote/extension.d.ts +5 -0
- package/dist/src/self-modification/remote/extension.js +1 -0
- package/dist/src/self-modification/remote/production-registry-add.js +1 -0
- package/dist/src/self-modification/remote/subagents/agent/agent.d.ts +4 -0
- package/dist/src/self-modification/remote/subagents/agent/agent.js +1 -0
- package/dist/src/self-modification/remote/subagents/agent/instructions.d.ts +2 -0
- package/dist/src/self-modification/remote/subagents/agent/instructions.js +5 -0
- package/dist/src/self-modification/remote/subagents/agent/sandbox.d.ts +2 -0
- package/dist/src/self-modification/remote/subagents/agent/sandbox.js +1 -0
- package/dist/src/self-modification/remote/subagents/agent/tools/edit_file.d.ts +1 -0
- package/dist/src/self-modification/remote/subagents/agent/tools/edit_file.js +1 -0
- package/dist/src/self-modification/remote/subagents/agent/tools/publish.js +1 -0
- package/dist/src/self-modification/remote/subagents/agent/tools/registry_add.d.ts +32 -0
- package/dist/src/self-modification/remote/subagents/agent/tools/registry_add.js +1 -0
- package/dist/src/self-modification/remote/subagents/agent/tools/search_models.d.ts +1 -0
- package/dist/src/self-modification/remote/subagents/agent/tools/search_models.js +1 -0
- package/dist/src/self-modification/remote/subagents/agent/tools/search_registry.d.ts +1 -0
- package/dist/src/self-modification/remote/subagents/agent/tools/search_registry.js +1 -0
- package/dist/src/self-modification/sandbox.d.ts +1 -6
- package/dist/src/self-modification/sandbox.js +1 -1
- package/dist/src/self-modification/scaffold.js +1 -1
- package/dist/src/self-modification/setup.d.ts +6 -0
- package/dist/src/self-modification/setup.js +46 -48
- package/dist/src/self-modification/subagent-guidance.d.ts +15 -0
- package/dist/src/self-modification/subagent-guidance.js +29 -0
- package/dist/src/services/dev-client/request-headers.js +1 -1
- package/dist/src/setup/flows/model-source-change.js +1 -1
- package/dist/src/setup/integrations/self-modification/setup.js +1 -1
- package/dist/src/setup/project-resolution.js +1 -1
- package/dist/src/setup/scaffold/create/project.js +1 -1
- package/dist/src/setup/verified-remote-client.d.ts +3 -0
- package/dist/src/setup/verified-remote-client.js +1 -1
- package/dist/src/shared/framework-eve-server.js +1 -1
- package/dist/src/shared/principal-scope.d.ts +2 -0
- package/dist/src/shared/principal-scope.js +1 -0
- package/dist/src/shared/schedule-collection-definition.d.ts +11 -0
- package/dist/src/shared/schedule-collection-definition.js +1 -0
- package/dist/src/shared/schedule-collection-tools.d.ts +1 -0
- package/dist/src/shared/schedule-collection-tools.js +1 -0
- package/dist/src/subagents/hitl-proxy.js +1 -1
- package/dist/src/subagents/tool.d.ts +1 -0
- 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/framework/agent.js +1 -1
- package/dist/src/tools/provided/ask-question-workflow.js +1 -1
- package/dist/src/tools/provided/read-file.js +1 -1
- package/dist/src/tools/provided/sleep-workflow.js +1 -1
- package/dist/src/tracing/agent-otel-content.d.ts +2 -0
- package/dist/src/tracing/agent-otel-content.js +2 -2
- package/dist/src/tracing/agent-otel-provider.js +1 -1
- package/dist/src/tracing/invoke-tool-span.d.ts +1 -0
- package/dist/src/vue/index.js +1 -1
- package/dist/src/vue/use-eve-agent.js +1 -1
- package/docs/channels/chat-sdk.mdx +27 -0
- package/docs/channels/custom.mdx +5 -2
- package/docs/channels/discord.mdx +22 -0
- package/docs/channels/mcp.mdx +102 -4
- package/docs/channels/slack.mdx +1 -1
- package/docs/connections/mcp.mdx +19 -0
- package/docs/evals/targets.mdx +5 -1
- package/docs/guides/self-modification.md +50 -3
- package/docs/tools/human-in-the-loop.md +14 -2
- package/docs/tools/workflows.mdx +6 -4
- package/docs/tutorial/guard-the-spend.mdx +1 -1
- package/package.json +46 -8
- package/dist/src/compiled/@workflow/core/runtime/vm-serde-bundle.generated.d.ts +0 -14
- package/dist/src/compiled/_chunks/workflow/dist-CaNNONeg.js +0 -3
- package/dist/src/compiled/_chunks/workflow/global-DKbOgrts.js +0 -1
- package/dist/src/compiled/_chunks/workflow/helpers-CP9TjeO8.js +0 -1
- package/dist/src/compiled/_chunks/workflow/logger-oqfblE3p.js +0 -14
- package/dist/src/compiled/_chunks/workflow/resume-hook-yq-NAdBu.js +0 -1
- package/dist/src/compiled/_chunks/workflow/serialization-APSKphN5.js +0 -3
- package/dist/src/compiled/_chunks/workflow/sleep-Ba8SExMt.js +0 -1
- package/dist/src/compiled/_chunks/workflow/wait-until-Dc9s3yyP.js +0 -1
- package/dist/src/self-modification/extension/production-registry-add.js +0 -1
- package/dist/src/self-modification/extension/subagents/agent/tools/publish.js +0 -1
- /package/dist/src/self-modification/{extension → remote}/production-registry-add.d.ts +0 -0
- /package/dist/src/self-modification/{extension → remote}/subagents/agent/tools/publish.d.ts +0 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
import{createHash}from"node:crypto";import{mkdir,writeFile}from"node:fs/promises";import{resolveInstalledPackageInfo}from"#internal/application/package.js";import{
|
|
1
|
+
import{createHash}from"node:crypto";import{mkdir,writeFile}from"node:fs/promises";import{join,relative,resolve}from"node:path";import{resolveInstalledPackageInfo}from"#internal/application/package.js";import{normalizeLogicalPath}from"#discover/filesystem.js";import{ROOT_COMPILED_AGENT_NODE_ID}from"#compiler/manifest.js";import{projectDiscoverDiagnostic,summarizeCompilerDiagnostics}from"#compiler/diagnostics.js";import{createCompiledModuleMapSource}from"#compiler/module-map.js";import{compileAgentManifest}from"#compiler/normalize-manifest.js";import{materializeWorkspaceResources}from"#compiler/workspace-resources.js";import{createSandboxPreparedArtifactsManifest}from"#shared/sandbox-prepared-artifacts.js";const COMPILE_METADATA_KIND=`eve-compile-metadata`,COMPILE_METADATA_VERSION=6;function resolveCompilerArtifactPaths(e){return resolveCompilerArtifactPathsAt(e,join(resolve(e),`.eve`))}function resolveCompilerArtifactPathsAt(e,t){let n=resolve(e),r=resolve(t),i=join(r,`discovery`),a=join(r,`compile`);return{appRoot:n,compiledManifestPath:join(a,`compiled-agent-manifest.json`),compileDirectoryPath:a,compileMetadataPath:join(a,`compile-metadata.json`),diagnosticsPath:join(i,`diagnostics.json`),discoveryManifestPath:join(i,`agent-discovery-manifest.json`),discoveryDirectoryPath:i,moduleMapPath:join(a,`module-map.mjs`),sandboxPreparedArtifactsPath:join(a,`sandbox-prepared-artifacts.json`)}}function createCompilerDiagnosticsArtifact(e){return{diagnostics:[...e],kind:`eve-compiler-diagnostics`,summary:summarizeCompilerDiagnostics(e),version:2}}function createCompileMetadata(e){let t=resolveInstalledPackageInfo(),n=createContentHash(e.compiledManifestJson),r=createContentHash(e.discoveryManifestJson),i=createContentHash(e.diagnosticsArtifactJson),a=createContentHash(e.moduleMapSource);return{compile:{manifest:{path:toArtifactRelativePath(e.appRoot,e.paths.compiledManifestPath),sha256:n},moduleMap:{path:toArtifactRelativePath(e.appRoot,e.paths.moduleMapPath),sha256:a}},discovery:{diagnostics:{path:toArtifactRelativePath(e.appRoot,e.paths.diagnosticsPath),sha256:i},manifest:{path:toArtifactRelativePath(e.appRoot,e.paths.discoveryManifestPath),sha256:r},sourceGraphHash:createContentHash(`${n}:${r}:${i}:${a}`),summary:e.diagnosticsSummary},generator:{name:t.name,version:t.version},kind:COMPILE_METADATA_KIND,status:e.diagnosticsSummary.errors>0?`failed`:`ready`,version:6}}async function writeCompilerArtifacts(e){let t=resolveCompilerArtifactPathsAt(e.appRoot,e.artifactLocations.writeRoot),n=resolveCompilerArtifactPathsAt(e.appRoot,e.artifactLocations.publishedRoot),r=e.diagnostics.map(e=>projectDiscoverDiagnostic(e,ROOT_COMPILED_AGENT_NODE_ID)),i=await materializeWorkspaceResources({compileDirectoryPath:t.compileDirectoryPath,manifest:await compileAgentManifest(e.manifest,{developmentExtensions:e.developmentExtensions,diagnostics:r})}),a=createCompilerDiagnosticsArtifact(r),o=serializeArtifactJson(i),s=serializeArtifactJson(e.manifest),c=serializeArtifactJson(a),l=createCompiledModuleMapSource({manifest:i,moduleMapPath:n.moduleMapPath}),u=createCompileMetadata({appRoot:e.appRoot,compiledManifestJson:o,diagnosticsArtifactJson:c,diagnosticsSummary:a.summary,discoveryManifestJson:s,moduleMapSource:l,paths:n}),d=serializeArtifactJson(u),f=serializeArtifactJson(createSandboxPreparedArtifactsManifest([]));return await mkdir(t.discoveryDirectoryPath,{recursive:!0}),await mkdir(t.compileDirectoryPath,{recursive:!0}),await Promise.all([writeFile(t.compiledManifestPath,o),writeFile(t.diagnosticsPath,c),writeFile(t.discoveryManifestPath,s),writeFile(t.moduleMapPath,l),writeFile(t.compileMetadataPath,d),writeFile(t.sandboxPreparedArtifactsPath,f)]),{compiledManifest:i,diagnosticsArtifact:a,metadata:u,moduleMapSource:l,paths:t}}function createContentHash(e){return createHash(`sha256`).update(e).digest(`hex`)}function serializeArtifactJson(e){return`${JSON.stringify(e,null,2)}\n`}function toArtifactRelativePath(e,t){return normalizeLogicalPath(relative(resolve(e),t))}export{COMPILE_METADATA_KIND,COMPILE_METADATA_VERSION,createCompileMetadata,resolveCompilerArtifactPaths,writeCompilerArtifacts};
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import{resolveDiscoveryProject}from"#discover/project.js";import{
|
|
1
|
+
import{join}from"node:path";import{resolveDiscoveryProject}from"#discover/project.js";import{summarizeCompilerDiagnostics}from"#compiler/diagnostics.js";import{discoverAgent}from"#discover/discover-agent.js";import{createDiskProjectSource}from"#discover/project-source.js";import{writeCompilerArtifacts}from"#compiler/artifacts.js";var CompileAgentError=class CompileAgentError extends Error{result;constructor(e,t){super(t),this.name=`CompileAgentError`,this.result=e}static fromDurableArtifacts(e){let[t,...n]=formatCompileAgentErrorLines(e.diagnostics);return new CompileAgentError(e,[t,`Diagnostics artifact: ${e.paths.diagnosticsPath}`,...n].join(`
|
|
2
2
|
`))}static fromTransientArtifacts(e){return new CompileAgentError(e,formatCompileAgentErrorLines(e.diagnostics).join(`
|
|
3
3
|
`))}};async function compileAgent(e={}){let t=await discoverAgentForCompilation(e),n=join(t.project.appRoot,`.eve`);return finishAgentCompilation(await writeAgentCompilation(t,{publishedRoot:n,writeRoot:n}),CompileAgentError.fromDurableArtifacts)}async function compileAgentInWorkspace(e){return finishAgentCompilation(await writeAgentCompilation(await discoverAgentForCompilation({developmentExtensions:e.developmentExtensions,startPath:e.startPath}),e.artifactLocations),CompileAgentError.fromTransientArtifacts)}async function discoverAgentForCompilation(e){let t=e.source??createDiskProjectSource(),n=await resolveDiscoveryProject(e.startPath,{source:t}),r=await discoverAgent({...n,source:t});return{developmentExtensions:e.developmentExtensions,diagnostics:r.diagnostics,manifest:r.manifest,project:n}}async function writeAgentCompilation(e,t){let n=await writeCompilerArtifacts({appRoot:e.project.appRoot,artifactLocations:t,diagnostics:e.diagnostics,developmentExtensions:e.developmentExtensions,manifest:e.manifest});return{diagnostics:n.diagnosticsArtifact.diagnostics,manifest:n.compiledManifest,metadata:n.metadata,paths:n.paths,project:e.project}}function finishAgentCompilation(e,t){if(e.diagnostics.some(e=>e.severity===`error`))throw t(e);return reportDiscoverWarnings(e.diagnostics),e}function reportDiscoverWarnings(e){let t=e.filter(e=>e.severity===`warning`);if(t.length!==0)for(let e of t)console.warn(`Warning [${e.code}]: ${e.message}\n source: ${formatDiagnosticSources(e)}`)}function formatCompileAgentErrorLines(e){let t=summarizeCompilerDiagnostics(e),n=[`Discovery failed with ${t.errors} error(s) and ${t.warnings} warning(s).`];if(e.length===0)return n;n.push(`Discovery diagnostics:`);for(let t of e)n.push(`- ${formatDiagnosticSeverity(t.severity)}: ${t.message}`),n.push(` source: ${formatDiagnosticSources(t)}`);return n}function formatDiagnosticSources(e){return e.sources.map(e=>e.sourcePath??e.logicalPath??e.sourceId??e.nodeId).join(`, `)}function formatDiagnosticSeverity(e){return e===`error`?`Error`:`Warning`}export{CompileAgentError,compileAgent,compileAgentInWorkspace};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{resolvePackageSourceDirectoryPath,resolvePackageSourceFilePath}from"#internal/application/package.js";import{projectDiscoverDiagnostic}from"#compiler/diagnostics.js";import{createAgentSourceRegistry,createProgrammaticModuleCandidates}from"#compiler/source-graph.js";import{createBundledExtensionMount}from"#compiler/bundled-extension.js";import{discoverBundledExtension}from"#discover/bundled-extension.js";import{mountRefNamespace}from"#discover/extensions.js";const SELF_MODIFICATION_CONFIG={local:{enabled:!0}},DEVELOPMENT_EXTENSION_IDS=[`self-modification`];let bundledExtensionById,developmentSourceRegistry;function getBundledExtensionById(){return bundledExtensionById===void 0&&(bundledExtensionById=new Map([{namespace:`self-modification`,importSpecifier:`eve/self-modification`,entryPath:resolvePackageSourceFilePath(`src/self-modification/extension/extension.ts`),config:SELF_MODIFICATION_CONFIG,sourceDirectory:resolvePackageSourceDirectoryPath(`src/self-modification/extension`)}].map(createBundledExtensionMount).map(e=>[e.namespace,e]))),bundledExtensionById}function getDevelopmentExtensionSourceRegistry(){return developmentSourceRegistry??=createAgentSourceRegistry([],{extensionDeclarations:[...getBundledExtensionById().values()].map(e=>e.declaration)}),developmentSourceRegistry}const DEFAULT_DEVELOPMENT_EXTENSION_IDS=DEVELOPMENT_EXTENSION_IDS,NO_DEVELOPMENT_EXTENSION_IDS=[];function defaultDevelopmentExtensions(){return{enabled:DEFAULT_DEVELOPMENT_EXTENSION_IDS}}function noDevelopmentExtensions(){return{enabled:NO_DEVELOPMENT_EXTENSION_IDS}}async function prepareDevelopmentExtensions(e){let t=new Set([...e.manifest.extensions.map(e=>mountRefNamespace(e.logicalPath)),...e.manifest.resolvedExtensions.map(e=>e.namespace)]),n=new Map,r=e.selection.enabled.length===0?void 0:getBundledExtensionById();for(let i of new Set(e.selection.enabled)){let e=r?.get(i);if(e===void 0)throw Error(`Unknown development extension "${i}".`);let a=n.get(e.namespace);if(a!==void 0&&a!==e)throw Error(`Development extensions use namespace "${e.namespace}" more than once.`);t.has(e.namespace)||(t.add(e.namespace),n.set(e.namespace,e))}let i=[...e.manifest.resolvedExtensions],a=[];for(let t of n.values()){let n=await discoverBundledExtension({mount:t});e.diagnostics.push(...n.diagnostics.map(t=>projectDiscoverDiagnostic(t,e.nodeId))),i.push(n.mount),a.push(...createProgrammaticModuleCandidates({layer:`framework-default`,nodeId:e.nodeId,owner:{feature:t.declaration.id,kind:`framework`},registration:{applyTo:`root`,source:t.declaration}}).map(e=>({...e,backing:{...e.backing,mountId:`extensions/${t.namespace}`}})))}return{candidates:a,manifest:{...e.manifest,resolvedExtensions:i}}}export{defaultDevelopmentExtensions,getDevelopmentExtensionSourceRegistry,noDevelopmentExtensions,prepareDevelopmentExtensions};
|
|
1
|
+
import{resolvePackageSourceDirectoryPath,resolvePackageSourceFilePath}from"#internal/application/package.js";import{projectDiscoverDiagnostic}from"#compiler/diagnostics.js";import{createAgentSourceRegistry,createProgrammaticModuleCandidates}from"#compiler/source-graph.js";import{createBundledExtensionMount}from"#compiler/bundled-extension.js";import{discoverBundledExtension}from"#discover/bundled-extension.js";import{mountRefNamespace}from"#discover/extensions.js";const SELF_MODIFICATION_CONFIG={local:{enabled:!0}},DEVELOPMENT_EXTENSION_IDS=[`self-modification`];let bundledExtensionById,developmentSourceRegistry;function getBundledExtensionById(){return bundledExtensionById===void 0&&(bundledExtensionById=new Map([{namespace:`self-modification`,importSpecifier:`eve/self-modification/local`,entryPath:resolvePackageSourceFilePath(`src/self-modification/extension/extension.ts`),config:SELF_MODIFICATION_CONFIG,sourceDirectory:resolvePackageSourceDirectoryPath(`src/self-modification/extension`)}].map(createBundledExtensionMount).map(e=>[e.namespace,e]))),bundledExtensionById}function getDevelopmentExtensionSourceRegistry(){return developmentSourceRegistry??=createAgentSourceRegistry([],{extensionDeclarations:[...getBundledExtensionById().values()].map(e=>e.declaration)}),developmentSourceRegistry}const DEFAULT_DEVELOPMENT_EXTENSION_IDS=DEVELOPMENT_EXTENSION_IDS,NO_DEVELOPMENT_EXTENSION_IDS=[];function defaultDevelopmentExtensions(){return{enabled:DEFAULT_DEVELOPMENT_EXTENSION_IDS}}function noDevelopmentExtensions(){return{enabled:NO_DEVELOPMENT_EXTENSION_IDS}}async function prepareDevelopmentExtensions(e){let t=new Set([...e.manifest.extensions.map(e=>mountRefNamespace(e.logicalPath)),...e.manifest.resolvedExtensions.map(e=>e.namespace)]),n=new Map,r=e.selection.enabled.length===0?void 0:getBundledExtensionById();for(let i of new Set(e.selection.enabled)){let e=r?.get(i);if(e===void 0)throw Error(`Unknown development extension "${i}".`);let a=n.get(e.namespace);if(a!==void 0&&a!==e)throw Error(`Development extensions use namespace "${e.namespace}" more than once.`);t.has(e.namespace)||(t.add(e.namespace),n.set(e.namespace,e))}let i=[...e.manifest.resolvedExtensions],a=[];for(let t of n.values()){let n=await discoverBundledExtension({mount:t});e.diagnostics.push(...n.diagnostics.map(t=>projectDiscoverDiagnostic(t,e.nodeId))),i.push(n.mount),a.push(...createProgrammaticModuleCandidates({layer:`framework-default`,nodeId:e.nodeId,owner:{feature:t.declaration.id,kind:`framework`},registration:{applyTo:`root`,source:t.declaration}}).map(e=>({...e,backing:{...e.backing,mountId:`extensions/${t.namespace}`}})))}return{candidates:a,manifest:{...e.manifest,resolvedExtensions:i}}}export{defaultDevelopmentExtensions,getDevelopmentExtensionSourceRegistry,noDevelopmentExtensions,prepareDevelopmentExtensions};
|
|
@@ -11,8 +11,8 @@ declare const EXTENSION_CAPABILITY_CONTRACTS: {
|
|
|
11
11
|
readonly dropped: {};
|
|
12
12
|
};
|
|
13
13
|
readonly tool: {
|
|
14
|
-
readonly current:
|
|
15
|
-
readonly supported: readonly [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 29, 30, 31, 32, 34, 35, 76];
|
|
14
|
+
readonly current: 78;
|
|
15
|
+
readonly supported: readonly [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 29, 30, 31, 32, 34, 35, 76, 77, 78];
|
|
16
16
|
readonly dropped: {
|
|
17
17
|
readonly 14: "TaskExec.delegated was removed; migrate to workflow-backed background tools";
|
|
18
18
|
readonly 15: "TaskExec replaces stageEffect with send";
|
|
@@ -73,8 +73,8 @@ declare const EXTENSION_CAPABILITY_CONTRACTS: {
|
|
|
73
73
|
};
|
|
74
74
|
};
|
|
75
75
|
readonly dynamicTool: {
|
|
76
|
-
readonly current:
|
|
77
|
-
readonly supported: readonly [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 22, 31, 32, 33, 52, 54, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 72];
|
|
76
|
+
readonly current: 73;
|
|
77
|
+
readonly supported: readonly [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 22, 31, 32, 33, 52, 54, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 72, 73];
|
|
78
78
|
readonly dropped: {
|
|
79
79
|
readonly 21: "Message and reasoning append events now expose deltas instead of cumulative snapshots.";
|
|
80
80
|
readonly 23: "TaskExec.delegated was removed; migrate to workflow-backed background tools";
|
|
@@ -113,8 +113,8 @@ declare const EXTENSION_CAPABILITY_CONTRACTS: {
|
|
|
113
113
|
};
|
|
114
114
|
};
|
|
115
115
|
readonly channel: {
|
|
116
|
-
readonly current:
|
|
117
|
-
readonly supported: readonly [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 13, 14, 15, 16, 17, 18, 29, 31, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48];
|
|
116
|
+
readonly current: 52;
|
|
117
|
+
readonly supported: readonly [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 13, 14, 15, 16, 17, 18, 29, 31, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52];
|
|
118
118
|
readonly dropped: {
|
|
119
119
|
readonly 12: "Message and reasoning append events now expose deltas instead of cumulative snapshots.";
|
|
120
120
|
readonly 19: "Continuation rekey was removed; channel extensions must use additive continuation.alias instead.";
|
|
@@ -144,8 +144,8 @@ declare const EXTENSION_CAPABILITY_CONTRACTS: {
|
|
|
144
144
|
};
|
|
145
145
|
};
|
|
146
146
|
readonly subagent: {
|
|
147
|
-
readonly current:
|
|
148
|
-
readonly supported: readonly [3, 4, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 19, 23, 24, 25, 26, 27, 28, 29, 30];
|
|
147
|
+
readonly current: 31;
|
|
148
|
+
readonly supported: readonly [3, 4, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 19, 23, 24, 25, 26, 27, 28, 29, 30, 31];
|
|
149
149
|
readonly dropped: {
|
|
150
150
|
readonly 1: "Persistent subagent sessions are now the default and the experimental opt-in was removed";
|
|
151
151
|
readonly 2: "Persistent subagent sessions are now the default and the experimental opt-in was removed";
|
|
@@ -158,8 +158,8 @@ declare const EXTENSION_CAPABILITY_CONTRACTS: {
|
|
|
158
158
|
};
|
|
159
159
|
};
|
|
160
160
|
readonly connection: {
|
|
161
|
-
readonly current:
|
|
162
|
-
readonly supported: readonly [1, 2, 3, 4, 5, 6, 7, 8, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 24, 26, 32, 33, 34, 35, 36, 37, 38, 39];
|
|
161
|
+
readonly current: 41;
|
|
162
|
+
readonly supported: readonly [1, 2, 3, 4, 5, 6, 7, 8, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 24, 26, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41];
|
|
163
163
|
readonly dropped: {
|
|
164
164
|
readonly 9: "Dynamic connection resolvers no longer receive conversation or channel continuation data";
|
|
165
165
|
readonly 10: "Message and reasoning append events now expose deltas instead of cumulative snapshots.";
|
|
@@ -173,8 +173,8 @@ declare const EXTENSION_CAPABILITY_CONTRACTS: {
|
|
|
173
173
|
};
|
|
174
174
|
};
|
|
175
175
|
readonly hook: {
|
|
176
|
-
readonly current:
|
|
177
|
-
readonly supported: readonly [20, 21, 22, 23, 25, 27, 31, 32, 33, 34, 35, 36, 37, 38];
|
|
176
|
+
readonly current: 39;
|
|
177
|
+
readonly supported: readonly [20, 21, 22, 23, 25, 27, 31, 32, 33, 34, 35, 36, 37, 38, 39];
|
|
178
178
|
readonly dropped: {
|
|
179
179
|
readonly 1: "Model identity moved from session.started runtime metadata to step.started call attribution.";
|
|
180
180
|
readonly 2: "Model identity moved from session.started runtime metadata to step.started call attribution.";
|
|
@@ -208,8 +208,8 @@ declare const EXTENSION_CAPABILITY_CONTRACTS: {
|
|
|
208
208
|
readonly dropped: {};
|
|
209
209
|
};
|
|
210
210
|
readonly dynamicSkill: {
|
|
211
|
-
readonly current:
|
|
212
|
-
readonly supported: readonly [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 14, 15, 16, 17, 18, 19, 20, 21, 25, 26, 27, 28, 29, 30, 31, 32];
|
|
211
|
+
readonly current: 33;
|
|
212
|
+
readonly supported: readonly [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 14, 15, 16, 17, 18, 19, 20, 21, 25, 26, 27, 28, 29, 30, 31, 32, 33];
|
|
213
213
|
readonly dropped: {
|
|
214
214
|
readonly 13: "Message and reasoning append events now expose deltas instead of cumulative snapshots.";
|
|
215
215
|
readonly 22: "Run mode was removed; sessions always park and ConversationContext no longer carries mode.";
|
|
@@ -223,8 +223,8 @@ declare const EXTENSION_CAPABILITY_CONTRACTS: {
|
|
|
223
223
|
readonly dropped: {};
|
|
224
224
|
};
|
|
225
225
|
readonly dynamicInstructions: {
|
|
226
|
-
readonly current:
|
|
227
|
-
readonly supported: readonly [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 15, 16, 17, 18, 19, 20, 21, 22, 26, 27, 28, 29, 30, 31, 32, 33];
|
|
226
|
+
readonly current: 34;
|
|
227
|
+
readonly supported: readonly [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 15, 16, 17, 18, 19, 20, 21, 22, 26, 27, 28, 29, 30, 31, 32, 33, 34];
|
|
228
228
|
readonly dropped: {
|
|
229
229
|
readonly 14: "Message and reasoning append events now expose deltas instead of cumulative snapshots.";
|
|
230
230
|
readonly 23: "Run mode was removed; sessions always park and ConversationContext no longer carries mode.";
|
|
@@ -238,8 +238,8 @@ declare const EXTENSION_CAPABILITY_CONTRACTS: {
|
|
|
238
238
|
readonly dropped: {};
|
|
239
239
|
};
|
|
240
240
|
readonly state: {
|
|
241
|
-
readonly current:
|
|
242
|
-
readonly supported: readonly [1, 2, 3, 4, 5, 7, 9];
|
|
241
|
+
readonly current: 10;
|
|
242
|
+
readonly supported: readonly [1, 2, 3, 4, 5, 7, 9, 10];
|
|
243
243
|
readonly dropped: {
|
|
244
244
|
readonly 6: "Sandbox sessions no longer expose core identity and mutable networking is provider-specific.";
|
|
245
245
|
readonly 8: "SandboxSession no longer exposes setNetworkPolicy; pass the configured environment to ctx.getSandbox(environment) to access network policy capabilities";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{readFile,writeFile}from"node:fs/promises";import{z}from"#compiled/zod/index.js";import{join}from"node:path";import{formatValidationError}from"#runtime/validation.js";const EXTENSION_COMPATIBILITY_MANIFEST_KIND=`eve-extension`,EXTENSION_COMPATIBILITY_MANIFEST_FORMAT_VERSION=2,EXTENSION_COMPATIBILITY_MANIFEST_FILENAME=`_manifest.json`,EXTENSION_CAPABILITY_CONTRACTS={extension:{current:1,supported:[1],dropped:{}},tool:{current:76,supported:[1,2,3,4,5,6,7,8,9,10,11,12,13,29,30,31,32,34,35,76],dropped:{14:`TaskExec.delegated was removed; migrate to workflow-backed background tools`,15:`TaskExec replaces stageEffect with send`,16:`TaskExec.delegated was removed; migrate to workflow-backed background tools`,17:`TaskExec.delegated was removed; migrate to workflow-backed background tools`,18:`TaskExec.delegated was removed; migrate to workflow-backed background tools`,19:`TaskExec.delegated was removed; migrate to workflow-backed background tools`,20:`TaskExec.delegated was removed; migrate to workflow-backed background tools`,21:`TaskExec.delegated was removed; migrate to workflow-backed background tools`,22:`TaskExec.delegated was removed; migrate to workflow-backed background tools`,23:`TaskExec.delegated was removed; migrate to workflow-backed background tools`,24:`TaskExec.delegated was removed; migrate to workflow-backed background tools`,25:`TaskExec.delegated was removed; migrate to workflow-backed background tools`,26:`Background tools now use task yield descriptors`,27:`TaskExec.delegated was removed; migrate to workflow-backed background tools`,28:`Background defineTool and TaskExec were removed; use defineWorkflowTool for durable background work.`,33:`ctx.agent now accepts the subagent name as its first argument, derives invocation identity internally, and infers structured output types`,36:`experimental_workflow and eve/tools/workflow were removed; migrate to the workflow factory from eve/tools/workflow`,37:`experimental_workflow and eve/tools/workflow were removed; migrate to the workflow factory from eve/tools/workflow`,38:`experimental_workflow and eve/tools/workflow were removed; migrate to the workflow factory from eve/tools/workflow`,39:`experimental_workflow and eve/tools/workflow were removed; migrate to the workflow factory from eve/tools/workflow`,40:`runWorkflowProgram was made internal; use the workflow factory from eve/tools/workflow`,41:`workflow no longer accepts agents and its options argument is optional; use workflow() or workflow({ maxSubagents })`,42:`Legacy session history migration was removed; user-role messages require current provenance kinds.`,43:`Legacy session history migration was removed; user-role messages require current provenance kinds.`,44:`Background defineTool and TaskExec were removed; use defineWorkflowTool for durable background work.`,45:`Background defineTool and TaskExec were removed; use defineWorkflowTool for durable background work.`,46:`Background defineTool and TaskExec were removed; use defineWorkflowTool for durable background work.`,47:`eve/experimental/evaluate was removed; import decide from eve/ai`,48:`eve/experimental/evaluate was removed; import decide from eve/ai`,49:`Background defineTool and TaskExec were removed; use defineWorkflowTool for durable background work.`,50:`Background defineTool and TaskExec were removed; use defineWorkflowTool for durable background work.`,51:`Background defineTool and TaskExec were removed; use defineWorkflowTool for durable background work.`,52:`Background defineTool and TaskExec were removed; use defineWorkflowTool for durable background work.`,53:`Sandbox sessions no longer expose core identity and mutable networking is provider-specific.`,54:`eve/ai evaluate was renamed to decide and AI SDK evaluation models became decision models; import decide from eve/ai`,55:`eve/ai evaluate was renamed to decide and AI SDK evaluation models became decision models; import decide from eve/ai`,56:`SandboxSession no longer exposes setNetworkPolicy; pass the configured environment to ctx.getSandbox(environment) to access network policy capabilities`,57:`agentRouter() no longer accepts a model-facing outputSchema; structured subagent output is requested only through ctx.agent().`,58:`Workflow tools no longer accept execution or return background task receipts; every call blocks until it settles.`,59:`Workflow tools no longer accept execution or return background task receipts, and every call blocks until it settles. ctx.ask() no longer accepts dismissible and reports a withdrawn request as cancelled, workflow tool contexts carry interruptSignal, and ctx.agent(name) returns a session handle whose send() delivers a message and whose result() resolves the turn; ctx.agent(name, { message, agentId }) and AgentInput were removed. A ctx.ask() question parks the open turn with turn.waiting instead of ending it.`,60:`Workflow tools define exactly one of execute(input, ctx), task(input, ctx), or serve(receive, ctx): a task() call returns a receipt and runs as a task, a serve() call reaches a resumable task through receive() and its model input gains taskId, and stream events gained task.started and task.settled. Agent tools are serve() tools with taskId in place of agentId, and the subagent.* stream events were removed. ctx.interruptSignal and WorkflowTaskContext were removed: a steering message aborts the abortSignal of an execute call the turn waits on.`,61:`Approval response policies now run for Cancel as well as Approve; a policy written for Approve only could reject every Cancel.`,62:`Approval response policies now run for Cancel as well as Approve; a policy written for Approve only could reject every Cancel.`,63:`eve/ai evaluate was renamed to decide and AI SDK evaluation models became decision models; import decide from eve/ai`,64:`eve/ai evaluate was renamed to decide and AI SDK evaluation models became decision models; import decide from eve/ai`,65:`eve/ai evaluate was renamed to decide and AI SDK evaluation models became decision models; import decide from eve/ai`,66:`eve/ai evaluate was renamed to decide and AI SDK evaluation models became decision models; import decide from eve/ai`,67:`eve/ai evaluate was renamed to decide and AI SDK evaluation models became decision models; import decide from eve/ai`,68:`eve/ai evaluate was renamed to decide and AI SDK evaluation models became decision models; import decide from eve/ai`,69:`eve/ai evaluate was renamed to decide and AI SDK evaluation models became decision models; import decide from eve/ai`,70:`eve/ai evaluate was renamed to decide and AI SDK evaluation models became decision models; import decide from eve/ai`,71:`eve/ai evaluate was renamed to decide and AI SDK evaluation models became decision models; import decide from eve/ai`,72:`eve/ai evaluate was renamed to decide and AI SDK evaluation models became decision models; import decide from eve/ai`,73:`eve/ai evaluate was renamed to decide and AI SDK evaluation models became decision models; import decide from eve/ai`,74:`eve/ai evaluate was renamed to decide and AI SDK evaluation models became decision models; import decide from eve/ai`,75:`eve/ai evaluate was renamed to decide and AI SDK evaluation models became decision models; import decide from eve/ai`}},dynamicTool:{current:72,supported:[1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,22,31,32,33,52,54,60,61,62,63,64,65,66,67,68,69,70,72],dropped:{21:`Message and reasoning append events now expose deltas instead of cumulative snapshots.`,23:`TaskExec.delegated was removed; migrate to workflow-backed background tools`,24:`TaskExec.delegated was removed; migrate to workflow-backed background tools`,25:`TaskExec.delegated was removed; migrate to workflow-backed background tools`,26:`Background tools now use task yield descriptors`,27:`TaskExec.delegated was removed; migrate to workflow-backed background tools`,28:`Background dynamic tools were removed; use a static defineWorkflowTool for durable background work.`,29:`Background dynamic tools were removed; use a static defineWorkflowTool for durable background work.`,30:`Background dynamic tools were removed; use a static defineWorkflowTool for durable background work.`,34:`Legacy session history migration was removed; user-role messages require current provenance kinds.`,35:`workflowMaxSubagents was removed with experimental_workflow; configure generated-program limits with the workflow factory`,36:`workflowMaxSubagents was removed with experimental_workflow; configure generated-program limits with the workflow factory`,37:`workflowMaxSubagents was removed with experimental_workflow; configure generated-program limits with the workflow factory`,38:`workflowMaxSubagents was removed with experimental_workflow; configure generated-program limits with the workflow factory`,39:`Legacy session history migration was removed; user-role messages require current provenance kinds.`,40:`Legacy session history migration was removed; user-role messages require current provenance kinds.`,41:`Background dynamic tools were removed; use a static defineWorkflowTool for durable background work.`,42:`autoModel and eve/experimental/evaluate were removed; import auto from eve/models`,43:`autoModel and eve/experimental/evaluate were removed; import auto from eve/models`,44:`autoModel and eve/experimental/evaluate were removed; import auto from eve/models`,45:`autoModel and eve/experimental/evaluate were removed; import auto from eve/models`,46:`autoModel and eve/experimental/evaluate were removed; import auto from eve/models`,47:`autoModel and eve/experimental/evaluate were removed; import auto from eve/models`,48:`Background dynamic tools were removed; use a static defineWorkflowTool for durable background work.`,49:`Background dynamic tools were removed; use a static defineWorkflowTool for durable background work.`,50:`Background dynamic tools were removed; use a static defineWorkflowTool for durable background work.`,51:`Sandbox sessions no longer expose core identity and mutable networking is provider-specific.`,53:`SandboxSession no longer exposes setNetworkPolicy; pass the configured environment to ctx.getSandbox(environment) to access network policy capabilities`,55:`Run mode was removed; sessions always park and ConversationContext no longer carries mode.`,56:`Background task execution was removed: subagent results no longer carry backgroundTask and message.completed always carries text. input.resolved reports outcome "cancelled" when a workflow tool withdraws a ctx.ask() request, and stream events gained agent.started, published when a workflow run opens a ctx.agent session, and turn.waiting, which parks the open turn instead of emitting turn.completed and session.waiting.`,57:`Stream events gained task.started and task.settled, and input.requested, authorization events, and agent.started carry the taskId of the task they come from. The subagent.called, subagent.completed, subagent.started, and subagent.event stream events were removed; agent calls report task.started, task.settled, and agent.started.`,58:`Approval response policies now run for Cancel as well as Approve; a policy written for Approve only could reject every Cancel.`,59:`Approval response policies now run for Cancel as well as Approve; a policy written for Approve only could reject every Cancel.`,71:`AI SDK evaluation models became decision models; auto() accepts decision models only`}},channel:{current:48,supported:[1,2,3,4,5,6,7,8,9,10,11,13,14,15,16,17,18,29,31,36,37,38,39,40,41,42,43,44,45,46,47,48],dropped:{12:`Message and reasoning append events now expose deltas instead of cumulative snapshots.`,19:`Continuation rekey was removed; channel extensions must use additive continuation.alias instead.`,20:`Continuation rekey was removed; channel extensions must use additive continuation.alias instead.`,21:`Continuation rekey was removed; channel extensions must use additive continuation.alias instead.`,22:`Continuation rekey was removed; channel extensions must use additive continuation.alias instead.`,23:`Task views no longer expose executor bindings; background work is owned by workflow runs.`,24:`Task views no longer expose executor bindings; background work is owned by workflow runs.`,25:`Task views no longer expose executor bindings; background work is owned by workflow runs.`,26:`Task views no longer expose executor bindings; background work is owned by workflow runs.`,27:`Sandbox sessions no longer expose core identity and mutable networking is provider-specific.`,28:`Sandbox sessions no longer expose core identity and mutable networking is provider-specific.`,30:`SandboxSession no longer exposes setNetworkPolicy; pass the configured environment to ctx.getSandbox(environment) to access network policy capabilities`,32:`Run mode and caller-supplied output schemas were removed from channel operations; sessions always park, and send options, audience inputs, and ConversationContext no longer carry mode, while from().send() and from().respond() no longer accept outputSchema.`,33:`Background task delivery was removed: sends no longer accept taskDeliveryPolicy and message.completed always carries text.`,34:`Background task delivery was removed: sends no longer accept taskDeliveryPolicy and message.completed always carries text. input.resolved reports outcome "cancelled" when a workflow tool withdraws a ctx.ask() request, and stream events gained agent.started, published when a workflow run opens a ctx.agent session, and turn.waiting, which parks the open turn instead of emitting turn.completed and session.waiting.`,35:`Stream events gained task.started and task.settled, and input.requested, authorization events, and agent.started carry the taskId of the task they come from. The subagent.called, subagent.completed, subagent.started, and subagent.event stream events were removed; agent calls report task.started, task.settled, and agent.started.`}},schedule:{current:27,supported:[1,2,3,4,6,7,8,9,10,11,12,13,14,15,18,19,20,21,22,23,24,25,26,27],dropped:{5:`Message and reasoning append events now expose deltas instead of cumulative snapshots.`,16:`Background task delivery was removed: sends no longer accept taskDeliveryPolicy and message.completed always carries text. input.resolved reports outcome "cancelled" when a workflow tool withdraws a ctx.ask() request, and stream events gained agent.started, published when a workflow run opens a ctx.agent session, and turn.waiting, which parks the open turn instead of emitting turn.completed and session.waiting.`,17:`Stream events gained task.started and task.settled, and input.requested, authorization events, and agent.started carry the taskId of the task they come from. The subagent.called, subagent.completed, subagent.started, and subagent.event stream events were removed; agent calls report task.started, task.settled, and agent.started.`}},subagent:{current:30,supported:[3,4,6,7,8,9,10,11,12,13,14,15,16,19,23,24,25,26,27,28,29,30],dropped:{1:`Persistent subagent sessions are now the default and the experimental opt-in was removed`,2:`Persistent subagent sessions are now the default and the experimental opt-in was removed`,5:`Message and reasoning append events now expose deltas instead of cumulative snapshots.`,17:`Removed experimental.instrumentationProviders; instrumentation is now always enabled for root agents.`,18:`Removed experimental.instrumentationProviders; instrumentation is now always enabled for root agents.`,20:`Run mode was removed and agent definitions no longer declare outputSchema; sessions always park, ConversationContext no longer carries mode, and structured output is requested per turn.`,21:`Background task execution was removed: subagent results no longer carry backgroundTask, message.completed always carries text, and experimental.tasks is gone. input.resolved reports outcome "cancelled" when a workflow tool withdraws a ctx.ask() request, and stream events gained agent.started, published when a workflow run opens a ctx.agent session, and turn.waiting, which parks the open turn instead of emitting turn.completed and session.waiting.`,22:`Stream events gained task.started and task.settled, and input.requested, authorization events, and agent.started carry the taskId of the task they come from. The subagent.called, subagent.completed, subagent.started, and subagent.event stream events were removed; agent calls report task.started, task.settled, and agent.started.`}},connection:{current:39,supported:[1,2,3,4,5,6,7,8,11,12,13,14,15,16,17,18,19,20,21,22,24,26,32,33,34,35,36,37,38,39],dropped:{9:`Dynamic connection resolvers no longer receive conversation or channel continuation data`,10:`Message and reasoning append events now expose deltas instead of cumulative snapshots.`,23:`Sandbox sessions no longer expose core identity and mutable networking is provider-specific.`,25:`SandboxSession no longer exposes setNetworkPolicy; pass the configured environment to ctx.getSandbox(environment) to access network policy capabilities`,27:`Run mode was removed; sessions always park and ConversationContext no longer carries mode.`,28:`Background task execution was removed: subagent results no longer carry backgroundTask and message.completed always carries text. input.resolved reports outcome "cancelled" when a workflow tool withdraws a ctx.ask() request, and stream events gained agent.started, published when a workflow run opens a ctx.agent session, and turn.waiting, which parks the open turn instead of emitting turn.completed and session.waiting.`,29:`Stream events gained task.started and task.settled, and input.requested, authorization events, and agent.started carry the taskId of the task they come from. The subagent.called, subagent.completed, subagent.started, and subagent.event stream events were removed; agent calls report task.started, task.settled, and agent.started.`,30:`Approval response policies now run for Cancel as well as Approve; a policy written for Approve only could reject every Cancel.`,31:`Approval response policies now run for Cancel as well as Approve; a policy written for Approve only could reject every Cancel.`}},hook:{current:38,supported:[20,21,22,23,25,27,31,32,33,34,35,36,37,38],dropped:{1:`Model identity moved from session.started runtime metadata to step.started call attribution.`,2:`Model identity moved from session.started runtime metadata to step.started call attribution.`,3:`Model identity moved from session.started runtime metadata to step.started call attribution.`,4:`Model identity moved from session.started runtime metadata to step.started call attribution.`,5:`Model identity moved from session.started runtime metadata to step.started call attribution.`,6:`Model identity moved from session.started runtime metadata to step.started call attribution.`,7:`Model identity moved from session.started runtime metadata to step.started call attribution.`,8:`Model identity moved from session.started runtime metadata to step.started call attribution.`,9:`Model identity moved from session.started runtime metadata to step.started call attribution.`,10:`The subagent.called, subagent.completed, subagent.started, and subagent.event hook events were removed; subscribe to task.started, task.settled, and agent.started.`,11:`The subagent.called, subagent.completed, subagent.started, and subagent.event hook events were removed; subscribe to task.started, task.settled, and agent.started.`,12:`The subagent.called, subagent.completed, subagent.started, and subagent.event hook events were removed; subscribe to task.started, task.settled, and agent.started.`,13:`The subagent.called, subagent.completed, subagent.started, and subagent.event hook events were removed; subscribe to task.started, task.settled, and agent.started.`,14:`The subagent.called, subagent.completed, subagent.started, and subagent.event hook events were removed; subscribe to task.started, task.settled, and agent.started.`,15:`The subagent.called, subagent.completed, subagent.started, and subagent.event hook events were removed; subscribe to task.started, task.settled, and agent.started.`,16:`Message and reasoning append events now expose deltas instead of cumulative snapshots.`,17:`The subagent.called, subagent.completed, subagent.started, and subagent.event hook events were removed; subscribe to task.started, task.settled, and agent.started.`,18:`The subagent.called, subagent.completed, subagent.started, and subagent.event hook events were removed; subscribe to task.started, task.settled, and agent.started.`,19:`The subagent.called, subagent.completed, subagent.started, and subagent.event hook events were removed; subscribe to task.started, task.settled, and agent.started.`,24:`Sandbox sessions no longer expose core identity and mutable networking is provider-specific.`,26:`SandboxSession no longer exposes setNetworkPolicy; pass the configured environment to ctx.getSandbox(environment) to access network policy capabilities`,28:`Background task execution was removed: subagent results no longer carry backgroundTask and message.completed always carries text.`,29:`Background task execution was removed: subagent results no longer carry backgroundTask and message.completed always carries text. input.resolved reports outcome "cancelled" when a workflow tool withdraws a ctx.ask() request, and stream events gained agent.started, published when a workflow run opens a ctx.agent session, and turn.waiting, which parks the open turn instead of emitting turn.completed and session.waiting.`,30:`Stream events gained task.started and task.settled, and input.requested, authorization events, and agent.started carry the taskId of the task they come from. The subagent.called, subagent.completed, subagent.started, and subagent.event hook events were removed; subscribe to task.started, task.settled, and agent.started.`}},skill:{current:2,supported:[1,2],dropped:{}},dynamicSkill:{current:32,supported:[1,2,3,4,5,6,7,8,9,10,11,12,14,15,16,17,18,19,20,21,25,26,27,28,29,30,31,32],dropped:{13:`Message and reasoning append events now expose deltas instead of cumulative snapshots.`,22:`Run mode was removed; sessions always park and ConversationContext no longer carries mode.`,23:`Background task execution was removed: subagent results no longer carry backgroundTask and message.completed always carries text. input.resolved reports outcome "cancelled" when a workflow tool withdraws a ctx.ask() request, and stream events gained agent.started, published when a workflow run opens a ctx.agent session, and turn.waiting, which parks the open turn instead of emitting turn.completed and session.waiting.`,24:`Stream events gained task.started and task.settled, and input.requested, authorization events, and agent.started carry the taskId of the task they come from. The subagent.called, subagent.completed, subagent.started, and subagent.event stream events were removed; agent calls report task.started, task.settled, and agent.started.`}},instructions:{current:2,supported:[1,2],dropped:{}},dynamicInstructions:{current:33,supported:[1,2,3,4,5,6,7,8,9,10,11,12,13,15,16,17,18,19,20,21,22,26,27,28,29,30,31,32,33],dropped:{14:`Message and reasoning append events now expose deltas instead of cumulative snapshots.`,23:`Run mode was removed; sessions always park and ConversationContext no longer carries mode.`,24:`Background task execution was removed: subagent results no longer carry backgroundTask and message.completed always carries text. input.resolved reports outcome "cancelled" when a workflow tool withdraws a ctx.ask() request, and stream events gained agent.started, published when a workflow run opens a ctx.agent session, and turn.waiting, which parks the open turn instead of emitting turn.completed and session.waiting.`,25:`Stream events gained task.started and task.settled, and input.requested, authorization events, and agent.started carry the taskId of the task they come from. The subagent.called, subagent.completed, subagent.started, and subagent.event stream events were removed; agent calls report task.started, task.settled, and agent.started.`}},config:{current:1,supported:[1],dropped:{}},state:{current:9,supported:[1,2,3,4,5,7,9],dropped:{6:`Sandbox sessions no longer expose core identity and mutable networking is provider-specific.`,8:`SandboxSession no longer exposes setNetworkPolicy; pass the configured environment to ctx.getSandbox(environment) to access network policy capabilities`}}},EXTENSION_CAPABILITY_VERSIONS=Object.fromEntries(Object.entries(EXTENSION_CAPABILITY_CONTRACTS).map(([e,t])=>[e,t.current])),EXTENSION_CAPABILITY_SUPPORT=Object.keys(EXTENSION_CAPABILITY_CONTRACTS).reduce((e,t)=>(e[t]=EXTENSION_CAPABILITY_CONTRACTS[t].supported,e),{}),extensionCompatibilityManifestV1Schema=z.object({kind:z.literal(EXTENSION_COMPATIBILITY_MANIFEST_KIND),formatVersion:z.literal(1),builtWithEve:z.string().min(1),requires:z.record(z.string(),z.number().int().positive())}).strict(),extensionCompatibilityManifestV2Schema=extensionCompatibilityManifestV1Schema.extend({formatVersion:z.literal(2),build:z.object({externalDependencies:z.array(z.string().min(1)).readonly()}).strict().optional()}),extensionCompatibilityManifestSchema=z.union([extensionCompatibilityManifestV1Schema,extensionCompatibilityManifestV2Schema]);function serializeExtensionCompatibilityManifest(e){return`${JSON.stringify(e,null,2)}\n`}function parseExtensionCompatibilityManifest(e,t){let n;try{n=JSON.parse(e)}catch(e){throw Error(`Extension compatibility manifest "${t}" is not valid JSON: ${e instanceof Error?e.message:String(e)}`)}let r=extensionCompatibilityManifestSchema.safeParse(n);if(!r.success)throw Error(`Extension compatibility manifest "${t}" is invalid. ${formatValidationError(r.error)}`);return r.data}async function readExtensionCompatibilityManifest(e){return parseExtensionCompatibilityManifest(await readFile(e,`utf8`),e)}async function writeExtensionCompatibilityManifest(e,t){await writeFile(join(e,EXTENSION_COMPATIBILITY_MANIFEST_FILENAME),serializeExtensionCompatibilityManifest(t),`utf8`)}function findUnsupportedExtensionCapabilities(e,t=EXTENSION_CAPABILITY_SUPPORT){return Object.entries(e.requires).flatMap(([e,n])=>{let r=Object.hasOwn(t,e)?t[e]??[]:[];return r.includes(n)?[]:[{capability:e,requiredVersion:n,supportedVersions:r}]}).sort((e,t)=>e.capability.localeCompare(t.capability))}export{EXTENSION_CAPABILITY_SUPPORT,EXTENSION_CAPABILITY_VERSIONS,EXTENSION_COMPATIBILITY_MANIFEST_FILENAME,EXTENSION_COMPATIBILITY_MANIFEST_FORMAT_VERSION,EXTENSION_COMPATIBILITY_MANIFEST_KIND,findUnsupportedExtensionCapabilities,parseExtensionCompatibilityManifest,readExtensionCompatibilityManifest,serializeExtensionCompatibilityManifest,writeExtensionCompatibilityManifest};
|
|
1
|
+
import{readFile,writeFile}from"node:fs/promises";import{z}from"#compiled/zod/index.js";import{join}from"node:path";import{formatValidationError}from"#runtime/validation.js";const EXTENSION_COMPATIBILITY_MANIFEST_KIND=`eve-extension`,EXTENSION_COMPATIBILITY_MANIFEST_FORMAT_VERSION=2,EXTENSION_COMPATIBILITY_MANIFEST_FILENAME=`_manifest.json`,EXTENSION_CAPABILITY_CONTRACTS={extension:{current:1,supported:[1],dropped:{}},tool:{current:78,supported:[1,2,3,4,5,6,7,8,9,10,11,12,13,29,30,31,32,34,35,76,77,78],dropped:{14:`TaskExec.delegated was removed; migrate to workflow-backed background tools`,15:`TaskExec replaces stageEffect with send`,16:`TaskExec.delegated was removed; migrate to workflow-backed background tools`,17:`TaskExec.delegated was removed; migrate to workflow-backed background tools`,18:`TaskExec.delegated was removed; migrate to workflow-backed background tools`,19:`TaskExec.delegated was removed; migrate to workflow-backed background tools`,20:`TaskExec.delegated was removed; migrate to workflow-backed background tools`,21:`TaskExec.delegated was removed; migrate to workflow-backed background tools`,22:`TaskExec.delegated was removed; migrate to workflow-backed background tools`,23:`TaskExec.delegated was removed; migrate to workflow-backed background tools`,24:`TaskExec.delegated was removed; migrate to workflow-backed background tools`,25:`TaskExec.delegated was removed; migrate to workflow-backed background tools`,26:`Background tools now use task yield descriptors`,27:`TaskExec.delegated was removed; migrate to workflow-backed background tools`,28:`Background defineTool and TaskExec were removed; use defineWorkflowTool for durable background work.`,33:`ctx.agent now accepts the subagent name as its first argument, derives invocation identity internally, and infers structured output types`,36:`experimental_workflow and eve/tools/workflow were removed; migrate to the workflow factory from eve/tools/workflow`,37:`experimental_workflow and eve/tools/workflow were removed; migrate to the workflow factory from eve/tools/workflow`,38:`experimental_workflow and eve/tools/workflow were removed; migrate to the workflow factory from eve/tools/workflow`,39:`experimental_workflow and eve/tools/workflow were removed; migrate to the workflow factory from eve/tools/workflow`,40:`runWorkflowProgram was made internal; use the workflow factory from eve/tools/workflow`,41:`workflow no longer accepts agents and its options argument is optional; use workflow() or workflow({ maxSubagents })`,42:`Legacy session history migration was removed; user-role messages require current provenance kinds.`,43:`Legacy session history migration was removed; user-role messages require current provenance kinds.`,44:`Background defineTool and TaskExec were removed; use defineWorkflowTool for durable background work.`,45:`Background defineTool and TaskExec were removed; use defineWorkflowTool for durable background work.`,46:`Background defineTool and TaskExec were removed; use defineWorkflowTool for durable background work.`,47:`eve/experimental/evaluate was removed; import decide from eve/ai`,48:`eve/experimental/evaluate was removed; import decide from eve/ai`,49:`Background defineTool and TaskExec were removed; use defineWorkflowTool for durable background work.`,50:`Background defineTool and TaskExec were removed; use defineWorkflowTool for durable background work.`,51:`Background defineTool and TaskExec were removed; use defineWorkflowTool for durable background work.`,52:`Background defineTool and TaskExec were removed; use defineWorkflowTool for durable background work.`,53:`Sandbox sessions no longer expose core identity and mutable networking is provider-specific.`,54:`eve/ai evaluate was renamed to decide and AI SDK evaluation models became decision models; import decide from eve/ai`,55:`eve/ai evaluate was renamed to decide and AI SDK evaluation models became decision models; import decide from eve/ai`,56:`SandboxSession no longer exposes setNetworkPolicy; pass the configured environment to ctx.getSandbox(environment) to access network policy capabilities`,57:`agentRouter() no longer accepts a model-facing outputSchema; structured subagent output is requested only through ctx.agent().`,58:`Workflow tools no longer accept execution or return background task receipts; every call blocks until it settles.`,59:`Workflow tools no longer accept execution or return background task receipts, and every call blocks until it settles. ctx.ask() no longer accepts dismissible and reports a withdrawn request as cancelled, workflow tool contexts carry interruptSignal, and ctx.agent(name) returns a session handle whose send() delivers a message and whose result() resolves the turn; ctx.agent(name, { message, agentId }) and AgentInput were removed. A ctx.ask() question parks the open turn with turn.waiting instead of ending it.`,60:`Workflow tools define exactly one of execute(input, ctx), task(input, ctx), or serve(receive, ctx): a task() call returns a receipt and runs as a task, a serve() call reaches a resumable task through receive() and its model input gains taskId, and stream events gained task.started and task.settled. Agent tools are serve() tools with taskId in place of agentId, and the subagent.* stream events were removed. ctx.interruptSignal and WorkflowTaskContext were removed: a steering message aborts the abortSignal of an execute call the turn waits on.`,61:`Approval response policies now run for Cancel as well as Approve; a policy written for Approve only could reject every Cancel.`,62:`Approval response policies now run for Cancel as well as Approve; a policy written for Approve only could reject every Cancel.`,63:`eve/ai evaluate was renamed to decide and AI SDK evaluation models became decision models; import decide from eve/ai`,64:`eve/ai evaluate was renamed to decide and AI SDK evaluation models became decision models; import decide from eve/ai`,65:`eve/ai evaluate was renamed to decide and AI SDK evaluation models became decision models; import decide from eve/ai`,66:`eve/ai evaluate was renamed to decide and AI SDK evaluation models became decision models; import decide from eve/ai`,67:`eve/ai evaluate was renamed to decide and AI SDK evaluation models became decision models; import decide from eve/ai`,68:`eve/ai evaluate was renamed to decide and AI SDK evaluation models became decision models; import decide from eve/ai`,69:`eve/ai evaluate was renamed to decide and AI SDK evaluation models became decision models; import decide from eve/ai`,70:`eve/ai evaluate was renamed to decide and AI SDK evaluation models became decision models; import decide from eve/ai`,71:`eve/ai evaluate was renamed to decide and AI SDK evaluation models became decision models; import decide from eve/ai`,72:`eve/ai evaluate was renamed to decide and AI SDK evaluation models became decision models; import decide from eve/ai`,73:`eve/ai evaluate was renamed to decide and AI SDK evaluation models became decision models; import decide from eve/ai`,74:`eve/ai evaluate was renamed to decide and AI SDK evaluation models became decision models; import decide from eve/ai`,75:`eve/ai evaluate was renamed to decide and AI SDK evaluation models became decision models; import decide from eve/ai`}},dynamicTool:{current:73,supported:[1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,22,31,32,33,52,54,60,61,62,63,64,65,66,67,68,69,70,72,73],dropped:{21:`Message and reasoning append events now expose deltas instead of cumulative snapshots.`,23:`TaskExec.delegated was removed; migrate to workflow-backed background tools`,24:`TaskExec.delegated was removed; migrate to workflow-backed background tools`,25:`TaskExec.delegated was removed; migrate to workflow-backed background tools`,26:`Background tools now use task yield descriptors`,27:`TaskExec.delegated was removed; migrate to workflow-backed background tools`,28:`Background dynamic tools were removed; use a static defineWorkflowTool for durable background work.`,29:`Background dynamic tools were removed; use a static defineWorkflowTool for durable background work.`,30:`Background dynamic tools were removed; use a static defineWorkflowTool for durable background work.`,34:`Legacy session history migration was removed; user-role messages require current provenance kinds.`,35:`workflowMaxSubagents was removed with experimental_workflow; configure generated-program limits with the workflow factory`,36:`workflowMaxSubagents was removed with experimental_workflow; configure generated-program limits with the workflow factory`,37:`workflowMaxSubagents was removed with experimental_workflow; configure generated-program limits with the workflow factory`,38:`workflowMaxSubagents was removed with experimental_workflow; configure generated-program limits with the workflow factory`,39:`Legacy session history migration was removed; user-role messages require current provenance kinds.`,40:`Legacy session history migration was removed; user-role messages require current provenance kinds.`,41:`Background dynamic tools were removed; use a static defineWorkflowTool for durable background work.`,42:`autoModel and eve/experimental/evaluate were removed; import auto from eve/models`,43:`autoModel and eve/experimental/evaluate were removed; import auto from eve/models`,44:`autoModel and eve/experimental/evaluate were removed; import auto from eve/models`,45:`autoModel and eve/experimental/evaluate were removed; import auto from eve/models`,46:`autoModel and eve/experimental/evaluate were removed; import auto from eve/models`,47:`autoModel and eve/experimental/evaluate were removed; import auto from eve/models`,48:`Background dynamic tools were removed; use a static defineWorkflowTool for durable background work.`,49:`Background dynamic tools were removed; use a static defineWorkflowTool for durable background work.`,50:`Background dynamic tools were removed; use a static defineWorkflowTool for durable background work.`,51:`Sandbox sessions no longer expose core identity and mutable networking is provider-specific.`,53:`SandboxSession no longer exposes setNetworkPolicy; pass the configured environment to ctx.getSandbox(environment) to access network policy capabilities`,55:`Run mode was removed; sessions always park and ConversationContext no longer carries mode.`,56:`Background task execution was removed: subagent results no longer carry backgroundTask and message.completed always carries text. input.resolved reports outcome "cancelled" when a workflow tool withdraws a ctx.ask() request, and stream events gained agent.started, published when a workflow run opens a ctx.agent session, and turn.waiting, which parks the open turn instead of emitting turn.completed and session.waiting.`,57:`Stream events gained task.started and task.settled, and input.requested, authorization events, and agent.started carry the taskId of the task they come from. The subagent.called, subagent.completed, subagent.started, and subagent.event stream events were removed; agent calls report task.started, task.settled, and agent.started.`,58:`Approval response policies now run for Cancel as well as Approve; a policy written for Approve only could reject every Cancel.`,59:`Approval response policies now run for Cancel as well as Approve; a policy written for Approve only could reject every Cancel.`,71:`AI SDK evaluation models became decision models; auto() accepts decision models only`}},channel:{current:52,supported:[1,2,3,4,5,6,7,8,9,10,11,13,14,15,16,17,18,29,31,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52],dropped:{12:`Message and reasoning append events now expose deltas instead of cumulative snapshots.`,19:`Continuation rekey was removed; channel extensions must use additive continuation.alias instead.`,20:`Continuation rekey was removed; channel extensions must use additive continuation.alias instead.`,21:`Continuation rekey was removed; channel extensions must use additive continuation.alias instead.`,22:`Continuation rekey was removed; channel extensions must use additive continuation.alias instead.`,23:`Task views no longer expose executor bindings; background work is owned by workflow runs.`,24:`Task views no longer expose executor bindings; background work is owned by workflow runs.`,25:`Task views no longer expose executor bindings; background work is owned by workflow runs.`,26:`Task views no longer expose executor bindings; background work is owned by workflow runs.`,27:`Sandbox sessions no longer expose core identity and mutable networking is provider-specific.`,28:`Sandbox sessions no longer expose core identity and mutable networking is provider-specific.`,30:`SandboxSession no longer exposes setNetworkPolicy; pass the configured environment to ctx.getSandbox(environment) to access network policy capabilities`,32:`Run mode and caller-supplied output schemas were removed from channel operations; sessions always park, and send options, audience inputs, and ConversationContext no longer carry mode, while from().send() and from().respond() no longer accept outputSchema.`,33:`Background task delivery was removed: sends no longer accept taskDeliveryPolicy and message.completed always carries text.`,34:`Background task delivery was removed: sends no longer accept taskDeliveryPolicy and message.completed always carries text. input.resolved reports outcome "cancelled" when a workflow tool withdraws a ctx.ask() request, and stream events gained agent.started, published when a workflow run opens a ctx.agent session, and turn.waiting, which parks the open turn instead of emitting turn.completed and session.waiting.`,35:`Stream events gained task.started and task.settled, and input.requested, authorization events, and agent.started carry the taskId of the task they come from. The subagent.called, subagent.completed, subagent.started, and subagent.event stream events were removed; agent calls report task.started, task.settled, and agent.started.`}},schedule:{current:27,supported:[1,2,3,4,6,7,8,9,10,11,12,13,14,15,18,19,20,21,22,23,24,25,26,27],dropped:{5:`Message and reasoning append events now expose deltas instead of cumulative snapshots.`,16:`Background task delivery was removed: sends no longer accept taskDeliveryPolicy and message.completed always carries text. input.resolved reports outcome "cancelled" when a workflow tool withdraws a ctx.ask() request, and stream events gained agent.started, published when a workflow run opens a ctx.agent session, and turn.waiting, which parks the open turn instead of emitting turn.completed and session.waiting.`,17:`Stream events gained task.started and task.settled, and input.requested, authorization events, and agent.started carry the taskId of the task they come from. The subagent.called, subagent.completed, subagent.started, and subagent.event stream events were removed; agent calls report task.started, task.settled, and agent.started.`}},subagent:{current:31,supported:[3,4,6,7,8,9,10,11,12,13,14,15,16,19,23,24,25,26,27,28,29,30,31],dropped:{1:`Persistent subagent sessions are now the default and the experimental opt-in was removed`,2:`Persistent subagent sessions are now the default and the experimental opt-in was removed`,5:`Message and reasoning append events now expose deltas instead of cumulative snapshots.`,17:`Removed experimental.instrumentationProviders; instrumentation is now always enabled for root agents.`,18:`Removed experimental.instrumentationProviders; instrumentation is now always enabled for root agents.`,20:`Run mode was removed and agent definitions no longer declare outputSchema; sessions always park, ConversationContext no longer carries mode, and structured output is requested per turn.`,21:`Background task execution was removed: subagent results no longer carry backgroundTask, message.completed always carries text, and experimental.tasks is gone. input.resolved reports outcome "cancelled" when a workflow tool withdraws a ctx.ask() request, and stream events gained agent.started, published when a workflow run opens a ctx.agent session, and turn.waiting, which parks the open turn instead of emitting turn.completed and session.waiting.`,22:`Stream events gained task.started and task.settled, and input.requested, authorization events, and agent.started carry the taskId of the task they come from. The subagent.called, subagent.completed, subagent.started, and subagent.event stream events were removed; agent calls report task.started, task.settled, and agent.started.`}},connection:{current:41,supported:[1,2,3,4,5,6,7,8,11,12,13,14,15,16,17,18,19,20,21,22,24,26,32,33,34,35,36,37,38,39,40,41],dropped:{9:`Dynamic connection resolvers no longer receive conversation or channel continuation data`,10:`Message and reasoning append events now expose deltas instead of cumulative snapshots.`,23:`Sandbox sessions no longer expose core identity and mutable networking is provider-specific.`,25:`SandboxSession no longer exposes setNetworkPolicy; pass the configured environment to ctx.getSandbox(environment) to access network policy capabilities`,27:`Run mode was removed; sessions always park and ConversationContext no longer carries mode.`,28:`Background task execution was removed: subagent results no longer carry backgroundTask and message.completed always carries text. input.resolved reports outcome "cancelled" when a workflow tool withdraws a ctx.ask() request, and stream events gained agent.started, published when a workflow run opens a ctx.agent session, and turn.waiting, which parks the open turn instead of emitting turn.completed and session.waiting.`,29:`Stream events gained task.started and task.settled, and input.requested, authorization events, and agent.started carry the taskId of the task they come from. The subagent.called, subagent.completed, subagent.started, and subagent.event stream events were removed; agent calls report task.started, task.settled, and agent.started.`,30:`Approval response policies now run for Cancel as well as Approve; a policy written for Approve only could reject every Cancel.`,31:`Approval response policies now run for Cancel as well as Approve; a policy written for Approve only could reject every Cancel.`}},hook:{current:39,supported:[20,21,22,23,25,27,31,32,33,34,35,36,37,38,39],dropped:{1:`Model identity moved from session.started runtime metadata to step.started call attribution.`,2:`Model identity moved from session.started runtime metadata to step.started call attribution.`,3:`Model identity moved from session.started runtime metadata to step.started call attribution.`,4:`Model identity moved from session.started runtime metadata to step.started call attribution.`,5:`Model identity moved from session.started runtime metadata to step.started call attribution.`,6:`Model identity moved from session.started runtime metadata to step.started call attribution.`,7:`Model identity moved from session.started runtime metadata to step.started call attribution.`,8:`Model identity moved from session.started runtime metadata to step.started call attribution.`,9:`Model identity moved from session.started runtime metadata to step.started call attribution.`,10:`The subagent.called, subagent.completed, subagent.started, and subagent.event hook events were removed; subscribe to task.started, task.settled, and agent.started.`,11:`The subagent.called, subagent.completed, subagent.started, and subagent.event hook events were removed; subscribe to task.started, task.settled, and agent.started.`,12:`The subagent.called, subagent.completed, subagent.started, and subagent.event hook events were removed; subscribe to task.started, task.settled, and agent.started.`,13:`The subagent.called, subagent.completed, subagent.started, and subagent.event hook events were removed; subscribe to task.started, task.settled, and agent.started.`,14:`The subagent.called, subagent.completed, subagent.started, and subagent.event hook events were removed; subscribe to task.started, task.settled, and agent.started.`,15:`The subagent.called, subagent.completed, subagent.started, and subagent.event hook events were removed; subscribe to task.started, task.settled, and agent.started.`,16:`Message and reasoning append events now expose deltas instead of cumulative snapshots.`,17:`The subagent.called, subagent.completed, subagent.started, and subagent.event hook events were removed; subscribe to task.started, task.settled, and agent.started.`,18:`The subagent.called, subagent.completed, subagent.started, and subagent.event hook events were removed; subscribe to task.started, task.settled, and agent.started.`,19:`The subagent.called, subagent.completed, subagent.started, and subagent.event hook events were removed; subscribe to task.started, task.settled, and agent.started.`,24:`Sandbox sessions no longer expose core identity and mutable networking is provider-specific.`,26:`SandboxSession no longer exposes setNetworkPolicy; pass the configured environment to ctx.getSandbox(environment) to access network policy capabilities`,28:`Background task execution was removed: subagent results no longer carry backgroundTask and message.completed always carries text.`,29:`Background task execution was removed: subagent results no longer carry backgroundTask and message.completed always carries text. input.resolved reports outcome "cancelled" when a workflow tool withdraws a ctx.ask() request, and stream events gained agent.started, published when a workflow run opens a ctx.agent session, and turn.waiting, which parks the open turn instead of emitting turn.completed and session.waiting.`,30:`Stream events gained task.started and task.settled, and input.requested, authorization events, and agent.started carry the taskId of the task they come from. The subagent.called, subagent.completed, subagent.started, and subagent.event hook events were removed; subscribe to task.started, task.settled, and agent.started.`}},skill:{current:2,supported:[1,2],dropped:{}},dynamicSkill:{current:33,supported:[1,2,3,4,5,6,7,8,9,10,11,12,14,15,16,17,18,19,20,21,25,26,27,28,29,30,31,32,33],dropped:{13:`Message and reasoning append events now expose deltas instead of cumulative snapshots.`,22:`Run mode was removed; sessions always park and ConversationContext no longer carries mode.`,23:`Background task execution was removed: subagent results no longer carry backgroundTask and message.completed always carries text. input.resolved reports outcome "cancelled" when a workflow tool withdraws a ctx.ask() request, and stream events gained agent.started, published when a workflow run opens a ctx.agent session, and turn.waiting, which parks the open turn instead of emitting turn.completed and session.waiting.`,24:`Stream events gained task.started and task.settled, and input.requested, authorization events, and agent.started carry the taskId of the task they come from. The subagent.called, subagent.completed, subagent.started, and subagent.event stream events were removed; agent calls report task.started, task.settled, and agent.started.`}},instructions:{current:2,supported:[1,2],dropped:{}},dynamicInstructions:{current:34,supported:[1,2,3,4,5,6,7,8,9,10,11,12,13,15,16,17,18,19,20,21,22,26,27,28,29,30,31,32,33,34],dropped:{14:`Message and reasoning append events now expose deltas instead of cumulative snapshots.`,23:`Run mode was removed; sessions always park and ConversationContext no longer carries mode.`,24:`Background task execution was removed: subagent results no longer carry backgroundTask and message.completed always carries text. input.resolved reports outcome "cancelled" when a workflow tool withdraws a ctx.ask() request, and stream events gained agent.started, published when a workflow run opens a ctx.agent session, and turn.waiting, which parks the open turn instead of emitting turn.completed and session.waiting.`,25:`Stream events gained task.started and task.settled, and input.requested, authorization events, and agent.started carry the taskId of the task they come from. The subagent.called, subagent.completed, subagent.started, and subagent.event stream events were removed; agent calls report task.started, task.settled, and agent.started.`}},config:{current:1,supported:[1],dropped:{}},state:{current:10,supported:[1,2,3,4,5,7,9,10],dropped:{6:`Sandbox sessions no longer expose core identity and mutable networking is provider-specific.`,8:`SandboxSession no longer exposes setNetworkPolicy; pass the configured environment to ctx.getSandbox(environment) to access network policy capabilities`}}},EXTENSION_CAPABILITY_VERSIONS=Object.fromEntries(Object.entries(EXTENSION_CAPABILITY_CONTRACTS).map(([e,t])=>[e,t.current])),EXTENSION_CAPABILITY_SUPPORT=Object.keys(EXTENSION_CAPABILITY_CONTRACTS).reduce((e,t)=>(e[t]=EXTENSION_CAPABILITY_CONTRACTS[t].supported,e),{}),extensionCompatibilityManifestV1Schema=z.object({kind:z.literal(EXTENSION_COMPATIBILITY_MANIFEST_KIND),formatVersion:z.literal(1),builtWithEve:z.string().min(1),requires:z.record(z.string(),z.number().int().positive())}).strict(),extensionCompatibilityManifestV2Schema=extensionCompatibilityManifestV1Schema.extend({formatVersion:z.literal(2),build:z.object({externalDependencies:z.array(z.string().min(1)).readonly()}).strict().optional()}),extensionCompatibilityManifestSchema=z.union([extensionCompatibilityManifestV1Schema,extensionCompatibilityManifestV2Schema]);function serializeExtensionCompatibilityManifest(e){return`${JSON.stringify(e,null,2)}\n`}function parseExtensionCompatibilityManifest(e,t){let n;try{n=JSON.parse(e)}catch(e){throw Error(`Extension compatibility manifest "${t}" is not valid JSON: ${e instanceof Error?e.message:String(e)}`)}let r=extensionCompatibilityManifestSchema.safeParse(n);if(!r.success)throw Error(`Extension compatibility manifest "${t}" is invalid. ${formatValidationError(r.error)}`);return r.data}async function readExtensionCompatibilityManifest(e){return parseExtensionCompatibilityManifest(await readFile(e,`utf8`),e)}async function writeExtensionCompatibilityManifest(e,t){await writeFile(join(e,EXTENSION_COMPATIBILITY_MANIFEST_FILENAME),serializeExtensionCompatibilityManifest(t),`utf8`)}function findUnsupportedExtensionCapabilities(e,t=EXTENSION_CAPABILITY_SUPPORT){return Object.entries(e.requires).flatMap(([e,n])=>{let r=Object.hasOwn(t,e)?t[e]??[]:[];return r.includes(n)?[]:[{capability:e,requiredVersion:n,supportedVersions:r}]}).sort((e,t)=>e.capability.localeCompare(t.capability))}export{EXTENSION_CAPABILITY_SUPPORT,EXTENSION_CAPABILITY_VERSIONS,EXTENSION_COMPATIBILITY_MANIFEST_FILENAME,EXTENSION_COMPATIBILITY_MANIFEST_FORMAT_VERSION,EXTENSION_COMPATIBILITY_MANIFEST_KIND,findUnsupportedExtensionCapabilities,parseExtensionCompatibilityManifest,readExtensionCompatibilityManifest,serializeExtensionCompatibilityManifest,writeExtensionCompatibilityManifest};
|
|
@@ -7,6 +7,11 @@ export interface ExtensionCompileMount {
|
|
|
7
7
|
}
|
|
8
8
|
/** Loads one node's selected bindings with dependency ordering and per-phase caching. */
|
|
9
9
|
export declare function createCompiledBindingNamespaceLoader(input: {
|
|
10
|
+
/**
|
|
11
|
+
* Selected app root; application modules stamp Workflow ids relative to it. Required so
|
|
12
|
+
* no caller silently falls back to the package root, which differs in workspace members.
|
|
13
|
+
*/
|
|
14
|
+
readonly appRoot: string | undefined;
|
|
10
15
|
readonly bindings?: Readonly<Record<string, AgentModuleBinding>>;
|
|
11
16
|
readonly mounts?: ReadonlyMap<string, ExtensionCompileMount>;
|
|
12
17
|
readonly evaluationId?: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{loadProgrammaticModuleNamespace,memoizeModuleNamespaceFactories}from"#compiler/source-graph.js";import{loadAuthoredModuleNamespace}from"#internal/authored-module-loader.js";function ancestorMountEntries(e,t){return[...e.values()].filter(e=>e.entry!==void 0&&t.startsWith(`${e.mountId}/`)).sort((e,t)=>e.mountId.length-t.mountId.length).map(e=>({...e.entry,mountId:e.mountId}))}function createCompiledBindingNamespaceLoader(e){if(e.bindings===void 0&&e.resolveBinding===void 0)throw Error(`Compiled binding namespace loader requires a binding source.`);let t=new Map,load=(n,r=new Set)=>{if(r.has(n))throw Error(`Compiled binding dependency cycle includes "${n}".`);let i=t.get(n);if(i!==void 0)return i;let a=e.resolveBinding?.(n)??e.bindings?.[n];if(a===void 0)throw Error(`Compiled binding dependency "${n}" is missing.`);e.onLoad?.(n);let o=new Set(r).add(n),s=e.mountSourceId?.(a),c=(async()=>(s!==void 0&&s!==n&&await load(s,o),await loadCompiledBindingNamespace({binding:a,loadDependency:e=>load(e,o),registries:e.registries,mounts:e.mounts,evaluationId:e.evaluationId})))().then(memoizeModuleNamespaceFactories);return t.set(n,c),c};return load}async function loadCompiledBindingNamespace(e){if(e.binding.backing.kind===`filesystem`){let t=e.binding.owner.kind===`extension`?e.binding.owner.mountId:void 0,n=t===void 0?void 0:e.mounts?.get(t);if(t!==void 0&&e.mounts!==void 0&&n===void 0)throw Error(`Missing mount "${t}" for extension contribution.`);let r=t===void 0?void 0:{mountId:t,evaluationId:e.evaluationId,entry:n?.entry,ancestors:e.mounts===void 0?void 0:ancestorMountEntries(e.mounts,t)};return await loadAuthoredModuleNamespace(e.binding.backing.sourcePath,{externalDependencies:e.binding.backing.externalDependencies,extension:r})}let t=Object.fromEntries(await Promise.all(Object.entries(e.binding.backing.dependencies??{}).map(async([t,n])=>[t,await e.loadDependency(n)])));return await loadProgrammaticModuleNamespace({backing:e.binding.backing,dependencyNamespaces:t,registries:e.registries})}function resolveExtensionBindingMountId(e){return e.owner.kind===`extension`?e.owner.mountId:void 0}export{createCompiledBindingNamespaceLoader,resolveExtensionBindingMountId};
|
|
1
|
+
import{loadProgrammaticModuleNamespace,memoizeModuleNamespaceFactories}from"#compiler/source-graph.js";import{loadAuthoredModuleNamespace}from"#internal/authored-module-loader.js";function ancestorMountEntries(e,t){return[...e.values()].filter(e=>e.entry!==void 0&&t.startsWith(`${e.mountId}/`)).sort((e,t)=>e.mountId.length-t.mountId.length).map(e=>({...e.entry,mountId:e.mountId}))}function createCompiledBindingNamespaceLoader(e){if(e.bindings===void 0&&e.resolveBinding===void 0)throw Error(`Compiled binding namespace loader requires a binding source.`);let t=new Map,load=(n,r=new Set)=>{if(r.has(n))throw Error(`Compiled binding dependency cycle includes "${n}".`);let i=t.get(n);if(i!==void 0)return i;let a=e.resolveBinding?.(n)??e.bindings?.[n];if(a===void 0)throw Error(`Compiled binding dependency "${n}" is missing.`);e.onLoad?.(n);let o=new Set(r).add(n),s=e.mountSourceId?.(a),c=(async()=>(s!==void 0&&s!==n&&await load(s,o),await loadCompiledBindingNamespace({appRoot:e.appRoot,binding:a,loadDependency:e=>load(e,o),registries:e.registries,mounts:e.mounts,evaluationId:e.evaluationId})))().then(memoizeModuleNamespaceFactories);return t.set(n,c),c};return load}async function loadCompiledBindingNamespace(e){if(e.binding.backing.kind===`filesystem`){let t=e.binding.owner.kind===`extension`?e.binding.owner.mountId:void 0,n=t===void 0?void 0:e.mounts?.get(t);if(t!==void 0&&e.mounts!==void 0&&n===void 0)throw Error(`Missing mount "${t}" for extension contribution.`);let r=t===void 0?void 0:{mountId:t,evaluationId:e.evaluationId,entry:n?.entry,ancestors:e.mounts===void 0?void 0:ancestorMountEntries(e.mounts,t)};return await loadAuthoredModuleNamespace(e.binding.backing.sourcePath,{appRoot:e.binding.owner.kind===`application`?e.appRoot:void 0,externalDependencies:e.binding.backing.externalDependencies,extension:r})}let t=Object.fromEntries(await Promise.all(Object.entries(e.binding.backing.dependencies??{}).map(async([t,n])=>[t,await e.loadDependency(n)])));return await loadProgrammaticModuleNamespace({backing:e.binding.backing,dependencyNamespaces:t,registries:e.registries})}function resolveExtensionBindingMountId(e){return e.owner.kind===`extension`?e.owner.mountId:void 0}export{createCompiledBindingNamespaceLoader,resolveExtensionBindingMountId};
|
|
@@ -134,6 +134,7 @@ export type CompiledSkillDefinition = NamedSkillDefinition & ((Omit<MarkdownSour
|
|
|
134
134
|
* Normalized authored schedule preserved in the compiled manifest.
|
|
135
135
|
*/
|
|
136
136
|
export type CompiledScheduleDefinition = z.infer<typeof compiledScheduleDefinitionSchema>;
|
|
137
|
+
export type CompiledScheduleCollectionDefinition = z.infer<typeof compiledScheduleCollectionDefinitionSchema>;
|
|
137
138
|
/**
|
|
138
139
|
* Normalized authored sandbox metadata preserved in the compiled manifest.
|
|
139
140
|
*/
|
|
@@ -283,6 +284,15 @@ declare const compiledScheduleDefinitionSchema: z.ZodDiscriminatedUnion<[z.ZodOb
|
|
|
283
284
|
sourceId: z.ZodString;
|
|
284
285
|
sourceKind: z.ZodLiteral<"module">;
|
|
285
286
|
}, z.core.$strict>], "sourceKind">;
|
|
287
|
+
declare const compiledScheduleCollectionDefinitionSchema: z.ZodObject<{
|
|
288
|
+
description: z.ZodOptional<z.ZodString>;
|
|
289
|
+
logicalPath: z.ZodString;
|
|
290
|
+
name: z.ZodString;
|
|
291
|
+
providerKind: z.ZodString;
|
|
292
|
+
sourceId: z.ZodString;
|
|
293
|
+
sourceKind: z.ZodLiteral<"module">;
|
|
294
|
+
tools: z.ZodOptional<z.ZodBoolean>;
|
|
295
|
+
}, z.core.$strict>;
|
|
286
296
|
declare const compiledSandboxDefinitionSchema: z.ZodObject<{
|
|
287
297
|
providerName: z.ZodOptional<z.ZodString>;
|
|
288
298
|
environmentExportName: z.ZodOptional<z.ZodString>;
|
|
@@ -405,6 +415,15 @@ declare const compiledAgentResourcesSchema: z.ZodObject<{
|
|
|
405
415
|
sourceId: z.ZodString;
|
|
406
416
|
sourceKind: z.ZodLiteral<"module">;
|
|
407
417
|
}, z.core.$strict>], "sourceKind">>;
|
|
418
|
+
scheduleCollections: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
419
|
+
description: z.ZodOptional<z.ZodString>;
|
|
420
|
+
logicalPath: z.ZodString;
|
|
421
|
+
name: z.ZodString;
|
|
422
|
+
providerKind: z.ZodString;
|
|
423
|
+
sourceId: z.ZodString;
|
|
424
|
+
sourceKind: z.ZodLiteral<"module">;
|
|
425
|
+
tools: z.ZodOptional<z.ZodBoolean>;
|
|
426
|
+
}, z.core.$strict>>>;
|
|
408
427
|
remoteAgents: z.ZodArray<z.ZodType<Readonly<ModuleSourceRef & Node & {
|
|
409
428
|
description: string;
|
|
410
429
|
backing: {
|
|
@@ -539,6 +558,15 @@ declare const compiledAgentNodeManifestSchema: z.ZodObject<{
|
|
|
539
558
|
sourceId: z.ZodString;
|
|
540
559
|
sourceKind: z.ZodLiteral<"module">;
|
|
541
560
|
}, z.core.$strict>], "sourceKind">>;
|
|
561
|
+
scheduleCollections: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
562
|
+
description: z.ZodOptional<z.ZodString>;
|
|
563
|
+
logicalPath: z.ZodString;
|
|
564
|
+
name: z.ZodString;
|
|
565
|
+
providerKind: z.ZodString;
|
|
566
|
+
sourceId: z.ZodString;
|
|
567
|
+
sourceKind: z.ZodLiteral<"module">;
|
|
568
|
+
tools: z.ZodOptional<z.ZodBoolean>;
|
|
569
|
+
}, z.core.$strict>>>;
|
|
542
570
|
remoteAgents: z.ZodArray<z.ZodType<Readonly<ModuleSourceRef & Node & {
|
|
543
571
|
description: string;
|
|
544
572
|
backing: {
|
|
@@ -736,6 +764,15 @@ export declare const compiledAgentManifestSchema: z.ZodObject<{
|
|
|
736
764
|
sourceId: z.ZodString;
|
|
737
765
|
sourceKind: z.ZodLiteral<"module">;
|
|
738
766
|
}, z.core.$strict>], "sourceKind">>;
|
|
767
|
+
scheduleCollections: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
768
|
+
description: z.ZodOptional<z.ZodString>;
|
|
769
|
+
logicalPath: z.ZodString;
|
|
770
|
+
name: z.ZodString;
|
|
771
|
+
providerKind: z.ZodString;
|
|
772
|
+
sourceId: z.ZodString;
|
|
773
|
+
sourceKind: z.ZodLiteral<"module">;
|
|
774
|
+
tools: z.ZodOptional<z.ZodBoolean>;
|
|
775
|
+
}, z.core.$strict>>>;
|
|
739
776
|
skills: z.ZodReadonly<z.ZodArray<z.ZodType<CompiledSkillDefinition, unknown, z.core.$ZodTypeInternals<CompiledSkillDefinition, unknown>>>>;
|
|
740
777
|
subagents: z.ZodArray<z.ZodType<CompiledSubagentNode, unknown, z.core.$ZodTypeInternals<CompiledSubagentNode, unknown>>>;
|
|
741
778
|
instructions: z.ZodDefault<z.ZodReadonly<z.ZodArray<z.ZodType<CompiledInstructionsDefinition, unknown, z.core.$ZodTypeInternals<CompiledInstructionsDefinition, unknown>>>>>;
|
|
@@ -784,6 +821,7 @@ export interface CreateCompiledAgentResourcesInput {
|
|
|
784
821
|
readonly sandbox: CompiledSandboxDefinition;
|
|
785
822
|
readonly sandboxWorkspaces?: readonly CompiledSandboxWorkspace[];
|
|
786
823
|
readonly schedules?: readonly CompiledScheduleDefinition[];
|
|
824
|
+
readonly scheduleCollections?: readonly CompiledScheduleCollectionDefinition[];
|
|
787
825
|
readonly skills?: readonly CompiledSkillDefinition[];
|
|
788
826
|
readonly instructions?: readonly CompiledInstructionsDefinition[];
|
|
789
827
|
readonly tools?: readonly CompiledToolDefinition[];
|
|
@@ -833,6 +871,7 @@ export declare function createCompiledAgentManifest(input: {
|
|
|
833
871
|
readonly sandbox: CompiledSandboxDefinition;
|
|
834
872
|
readonly sandboxWorkspaces?: readonly CompiledSandboxWorkspace[];
|
|
835
873
|
readonly schedules?: readonly CompiledScheduleDefinition[];
|
|
874
|
+
readonly scheduleCollections?: readonly CompiledScheduleCollectionDefinition[];
|
|
836
875
|
readonly skills?: readonly CompiledSkillDefinition[];
|
|
837
876
|
readonly subagents?: readonly CompiledSubagentNode[];
|
|
838
877
|
readonly instructions?: readonly CompiledInstructionsDefinition[];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{z}from"#compiled/zod/index.js";import{mountIdSchema}from"#shared/extension-mount.js";import{discoverDiagnosticsSummarySchema}from"#discover/diagnostics.js";import{compiledRemoteAgentNodeSchema}from"#compiler/remote-agent-node.js";import{jsonObjectSchema}from"#shared/json-schemas.js";import{AGENT_WORKFLOW_RETENTION_VALUES}from"#shared/agent-definition.js";import{validateCompiledAgentManifest,validateCompiledAgentResources}from"#compiler/validate-artifact.js";const COMPILED_AGENT_MANIFEST_KIND=`eve-agent-compiled-manifest`,ROOT_COMPILED_AGENT_NODE_ID=`__root__`,COMPILED_AGENT_MANIFEST_VERSION=54,agentSourceOwnerSchema=z.discriminatedUnion(`kind`,[z.object({kind:z.literal(`application`)}).strict(),z.object({feature:z.string().min(1),kind:z.literal(`framework`)}).strict(),z.object({kind:z.literal(`extension`),mountId:mountIdSchema,namespace:z.string().min(1),packageName:z.string().min(1)}).strict()]),moduleSourceRefSchema=z.object({exportName:z.string().optional(),sourceKind:z.literal(`module`),logicalPath:z.string(),sourceId:z.string()}).strict(),filesystemModuleBackingSchema=z.object({externalDependencies:z.array(z.string()).readonly(),extensionScope:z.object({namespace:z.string(),sourceRoot:z.string()}).strict().optional(),mountId:z.string().optional(),kind:z.literal(`filesystem`),sourcePath:z.string()}).strict(),programmaticModuleBackingSchema=z.object({dependencies:z.record(z.string(),z.string()).readonly().optional(),kind:z.literal(`programmatic`),mountId:z.string().optional(),moduleId:z.string(),parameters:jsonObjectSchema.optional(),registryId:z.string(),revision:z.string(),semanticRevision:z.string().optional()}).strict(),resourceSourceBackingSchema=z.object({kind:z.literal(`resource`),sourcePath:z.string()}).strict(),agentModuleBackingSchema=z.discriminatedUnion(`kind`,[filesystemModuleBackingSchema,programmaticModuleBackingSchema]),compiledModuleBindingSchema=z.object({backing:agentModuleBackingSchema,logicalPath:z.string(),owner:agentSourceOwnerSchema,usage:z.object({compile:z.boolean(),runtimeEntry:z.boolean()}).strict()}).strict(),agentSourceDescriptorSchema=z.object({backing:z.discriminatedUnion(`kind`,[filesystemModuleBackingSchema,programmaticModuleBackingSchema,resourceSourceBackingSchema]),form:z.enum([`derived`,`direct`]),layer:z.enum([`framework-default`,`extension-package`,`extension-override`,`application`]),logicalPath:z.string(),owner:agentSourceOwnerSchema,sourceId:z.string()}).strict(),agentSourceCompositionSchema=z.object({entries:z.array(z.discriminatedUnion(`kind`,[z.object({kind:z.literal(`shadowed`),source:agentSourceDescriptorSchema,winnerSourceId:z.string()}).strict(),z.object({kind:z.literal(`disabled`),source:agentSourceDescriptorSchema}).strict()])).readonly()}).strict(),compiledDynamicModelDefinitionSchema=z.object({eventNames:z.array(z.string()).readonly(),exportName:z.string().optional(),sourceKind:z.literal(`module`),logicalPath:z.string(),sourceId:z.string()}).strict(),channelMethodSchema=z.union([z.literal(`GET`),z.literal(`HEAD`),z.literal(`POST`),z.literal(`PUT`),z.literal(`PATCH`),z.literal(`DELETE`),z.literal(`OPTIONS`),z.literal(`WEBSOCKET`)]),compiledChannelCorsSchema=z.object({origin:z.union([z.literal(`*`),z.literal(`null`),z.array(z.string())]).optional(),methods:z.union([z.literal(`*`),z.array(z.string())]).optional(),allowHeaders:z.union([z.literal(`*`),z.array(z.string())]).optional(),exposeHeaders:z.union([z.literal(`*`),z.array(z.string())]).optional(),credentials:z.boolean().optional(),maxAge:z.union([z.string(),z.literal(!1)]).optional(),preflight:z.object({statusCode:z.number().int().min(100).max(599).optional()}).strict().optional()}).strict(),compiledVercelConnectMetadataSchema=z.object({connector:z.string(),requirement:z.object({method:z.string().optional(),reference:z.string(),service:z.string(),subjectTypes:z.array(z.enum([`app`,`user`])).readonly()}).strict().optional()}).strict(),compiledChannelDefinitionSchema=z.object({kind:z.literal(`channel`),name:z.string(),logicalPath:z.string(),method:channelMethodSchema,urlPath:z.string(),sourceId:z.string(),sourceKind:z.literal(`module`),exportName:z.string().optional(),adapterKind:z.string().optional(),cors:compiledChannelCorsSchema.optional(),manifest:jsonObjectSchema.optional(),vercelConnect:compiledVercelConnectMetadataSchema.optional()}).strict(),compiledChannelPreflightDefinitionSchema=z.object({cors:compiledChannelCorsSchema,method:z.literal(`OPTIONS`),sourceIds:z.array(z.string()).readonly(),urlPath:z.string()}).strict(),compiledShadowedChannelRouteSchema=z.object({method:channelMethodSchema,source:agentSourceDescriptorSchema,urlPath:z.string(),winnerSourceId:z.string()}).strict(),compiledChannelRoutePlanSchema=z.object({effective:z.array(compiledChannelDefinitionSchema).readonly(),preflight:z.array(compiledChannelPreflightDefinitionSchema).readonly(),shadowed:z.array(compiledShadowedChannelRouteSchema).readonly()}).strict(),modelRoutingSchema=z.union([z.object({kind:z.literal(`gateway`),target:z.string(),byok:z.string().optional()}).strict(),z.object({kind:z.literal(`external`),provider:z.string()}).strict()]),compiledRuntimeModelReferenceSchema=z.object({contextWindowTokens:z.number().int().positive().optional(),id:z.string(),maxOutputTokens:z.number().int().positive().optional(),source:moduleSourceRefSchema.optional(),providerOptions:z.record(z.string(),jsonObjectSchema).optional(),routing:modelRoutingSchema}).strict(),compiledAgentBuildDefinitionSchema=z.object({externalDependencies:z.array(z.string()).optional()}).strict(),compiledAgentWorkflowWorldDefinitionSchema=z.string(),compiledAgentWorkflowDefinitionSchema=z.object({modelCallsPerStep:z.number().int().positive().optional(),retention:z.literal(AGENT_WORKFLOW_RETENTION_VALUES).optional(),world:compiledAgentWorkflowWorldDefinitionSchema.optional()}).strict(),compiledAgentCompactionDefinitionSchema=z.object({model:compiledRuntimeModelReferenceSchema.optional(),thresholdPercent:z.number().finite().min(0).max(1).optional()}).strict(),sessionTokenLimitSchema=z.union([z.number().int().positive(),z.literal(!1)]),sessionTokenCostLimitSchema=z.union([z.number().finite().positive(),z.literal(!1)]),sessionTimeoutSchema=z.union([z.number().int().positive(),z.literal(!1)]),compiledAgentLimitsDefinitionSchema=z.object({maxInputTokensPerSession:sessionTokenLimitSchema.optional(),maxOutputTokensPerSession:sessionTokenLimitSchema.optional(),maxTokenCostUsdPerSession:sessionTokenCostLimitSchema.optional(),sessionTimeoutMs:sessionTimeoutSchema.optional()}).strict(),compiledAgentConfigBaseFields={build:compiledAgentBuildDefinitionSchema.optional(),compaction:compiledAgentCompactionDefinitionSchema.optional(),defaultTools:z.boolean().optional(),description:z.string().optional(),experimental:z.object({workflow:compiledAgentWorkflowDefinitionSchema.optional()}).strict().optional(),name:z.string(),reasoning:z.enum([`provider-default`,`none`,`minimal`,`low`,`medium`,`high`,`xhigh`]).optional(),source:moduleSourceRefSchema,tool:z.boolean().optional(),limits:compiledAgentLimitsDefinitionSchema.optional()},compiledAgentConfigSchema=z.union([z.object({...compiledAgentConfigBaseFields,model:compiledRuntimeModelReferenceSchema}).strict(),z.object({...compiledAgentConfigBaseFields,dynamicModel:compiledDynamicModelDefinitionSchema}).strict()]),compiledInstructionsBaseFields={content:z.string(),name:z.string(),logicalPath:z.string(),role:z.enum([`system`,`user`]),sourceId:z.string()},compiledInstructionsSchema=z.discriminatedUnion(`sourceKind`,[z.object({...compiledInstructionsBaseFields,owner:agentSourceOwnerSchema,sourceKind:z.literal(`markdown`)}).strict(),z.object({...compiledInstructionsBaseFields,sourceKind:z.literal(`module`)}).strict()]),compiledSkillBaseFields={name:z.string(),description:z.string(),license:z.string().optional(),markdown:z.string(),metadata:z.record(z.string(),z.string()).optional(),sourceId:z.string(),logicalPath:z.string()},compiledSkillSourceSchema=z.discriminatedUnion(`sourceKind`,[z.object({...compiledSkillBaseFields,owner:agentSourceOwnerSchema,sourceKind:z.literal(`markdown`)}).strict(),z.object({...compiledSkillBaseFields,sourceKind:z.literal(`module`),exportName:z.string().optional()}).strict(),z.object({...compiledSkillBaseFields,owner:agentSourceOwnerSchema,sourceKind:z.literal(`skill-package`),skillId:z.string(),skillFilePath:z.string(),rootPath:z.string(),assetsPath:z.string().optional(),referencesPath:z.string().optional(),scriptsPath:z.string().optional()}).strict()]),compiledScheduleBaseFields={cron:z.string(),hasRun:z.boolean(),name:z.string(),logicalPath:z.string(),markdown:z.string().optional(),sourceId:z.string()},compiledScheduleDefinitionSchema=z.discriminatedUnion(`sourceKind`,[z.object({...compiledScheduleBaseFields,owner:agentSourceOwnerSchema,sourceKind:z.literal(`markdown`)}).strict(),z.object({...compiledScheduleBaseFields,sourceKind:z.literal(`module`)}).strict()]),compiledSandboxDefinitionSchema=z.object({providerName:z.string().optional(),environmentExportName:z.string().optional(),inheritsParent:z.boolean().optional(),exportName:z.string().optional(),logicalPath:z.string(),revisionHash:z.string(),sourceId:z.string(),sourceKind:z.literal(`module`)}).strict(),compiledSandboxWorkspaceSchema=z.object({logicalPath:z.string(),rootEntries:z.array(z.string()).readonly(),sourceId:z.string(),sourcePath:z.string()}).strict(),compiledWorkspaceResourceRootSchema=z.object({contentHash:z.string().optional(),logicalPath:z.string(),rootEntries:z.array(z.string()).readonly()}).strict(),compiledConnectionDefinitionSchema=z.object({connectionName:z.string(),description:z.string(),exportName:z.string().optional(),logicalPath:z.string(),protocol:z.enum([`mcp`,`openapi`]).default(`mcp`),sourceId:z.string(),sourceKind:z.literal(`module`),url:z.string(),vercelConnect:compiledVercelConnectMetadataSchema.optional()}).strict(),compiledDynamicConnectionDefinitionSchema=z.object({eventNames:z.array(z.string()).readonly(),exportName:z.string().optional(),extensionNamespace:z.string().optional(),logicalPath:z.string(),slug:z.string(),sourceId:z.string(),sourceKind:z.literal(`module`)}).strict(),compiledToolBehaviorSchema=z.object({availability:z.array(z.literal(`root-session`)).readonly(),handling:z.discriminatedUnion(`kind`,[z.object({action:z.literal(`self-agent`),kind:z.literal(`dispatch`)}).strict(),z.object({kind:z.literal(`provider-tool`),provider:z.enum([`exa`,`parallel`,`browserbase`])}).strict(),z.object({entryPoint:z.enum([`execute`,`task`,`serve`]),kind:z.literal(`workflow-tool`),workflowId:z.string()}).strict()]).optional(),presentation:z.literal(`load-skill`).optional(),shape:z.object({suspend:z.enum([`none`,`workflow`])}).strict().optional()}).strict(),compiledToolDefinitionSchema=z.object({availableInSubagents:z.boolean().optional(),behavior:compiledToolBehaviorSchema.optional(),description:z.string(),exportName:z.string().optional(),hasExecute:z.boolean(),hasModelOutputProjection:z.boolean(),inputSchema:jsonObjectSchema.nullable(),logicalPath:z.string(),modelInputSchema:jsonObjectSchema.optional(),name:z.string(),outputSchema:jsonObjectSchema.optional(),requiresApproval:z.boolean(),sourceId:z.string(),sourceKind:z.literal(`module`),workflowProgram:z.object({maxSubagents:z.number().int().positive()}).strict().optional()}).strict(),compiledDynamicToolDefinitionSchema=z.object({eventNames:z.array(z.string()).readonly(),exportName:z.string().optional(),extensionNamespace:z.string().optional(),logicalPath:z.string(),rebindMissingCallbacks:z.boolean().optional(),slug:z.string(),sourceId:z.string(),sourceKind:z.literal(`module`)}).strict(),compiledMemoryDefinitionSchema=z.object({description:z.string().optional(),exportName:z.string().optional(),logicalPath:z.string(),slot:z.string(),sourceId:z.string(),sourceKind:z.literal(`module`),visibility:z.enum([`scope`,`session`])}).strict(),compiledDynamicSkillDefinitionSchema=z.object({eventNames:z.array(z.string()).readonly(),exportName:z.string().optional(),extensionNamespace:z.string().optional(),logicalPath:z.string(),slug:z.string(),sourceId:z.string(),sourceKind:z.literal(`module`)}).strict(),compiledDynamicInstructionsDefinitionSchema=z.object({eventNames:z.array(z.string()).readonly(),exportName:z.string().optional(),logicalPath:z.string(),slug:z.string(),sourceId:z.string(),sourceKind:z.literal(`module`)}).strict(),compiledHookDefinitionSchema=z.object({eventNames:z.array(z.string()).readonly(),exportName:z.string().optional(),logicalPath:z.string(),slug:z.string(),sourceId:z.string(),sourceKind:z.literal(`module`)}).strict(),compiledExtensionMountSchema=z.object({externalDependencies:z.array(z.string()).readonly(),namespace:z.string(),packageName:z.string(),specifier:z.string(),mountId:mountIdSchema,sourceRoot:z.string(),mountSourceId:z.string(),mountSourcePath:z.string(),mountLogicalPath:z.string(),programmaticImport:z.object({specifier:z.string(),entryPath:z.string(),config:jsonObjectSchema}).strict().optional()}).strict(),compiledAgentResourceFields={agentRoot:z.string(),appRoot:z.string(),bindings:z.record(z.string(),compiledModuleBindingSchema),channelRoutes:compiledChannelRoutePlanSchema,connections:z.array(compiledConnectionDefinitionSchema),dynamicConnections:z.array(compiledDynamicConnectionDefinitionSchema).default([]),diagnosticsSummary:discoverDiagnosticsSummarySchema,sourceComposition:agentSourceCompositionSchema,dynamicInstructions:z.array(compiledDynamicInstructionsDefinitionSchema).default([]),dynamicSkills:z.array(compiledDynamicSkillDefinitionSchema).default([]),dynamicTools:z.array(compiledDynamicToolDefinitionSchema).default([]),extensionMounts:z.array(compiledExtensionMountSchema).default([]),hooks:z.array(compiledHookDefinitionSchema),memories:z.array(compiledMemoryDefinitionSchema).default([]),sandbox:compiledSandboxDefinitionSchema,sandboxWorkspaces:z.array(compiledSandboxWorkspaceSchema),schedules:z.array(compiledScheduleDefinitionSchema),remoteAgents:z.array(compiledRemoteAgentNodeSchema),skills:z.array(compiledSkillSourceSchema).readonly(),instructions:z.array(compiledInstructionsSchema).readonly().default([]),tools:z.array(compiledToolDefinitionSchema),workspaceResourceRoot:compiledWorkspaceResourceRootSchema},compiledAgentResourcesSchema=z.object(compiledAgentResourceFields).strict(),compiledAgentNodeManifestSchema=z.object({...compiledAgentResourceFields,config:compiledAgentConfigSchema}).strict(),compiledSubagentNodeBaseFields={backing:resourceSourceBackingSchema,entryPath:z.string(),logicalPath:z.string(),name:z.string(),nodeId:z.string(),owner:agentSourceOwnerSchema,parentNodeId:z.string(),rootPath:z.string(),sourceId:z.string(),sourceKind:z.literal(`module`),exportName:z.string().optional()},compiledDynamicSubagentDefinitionSchema=z.object({build:compiledAgentBuildDefinitionSchema.optional(),eventNames:z.array(z.string()).readonly(),exportName:z.string().optional(),logicalPath:z.string(),sourceId:z.string(),sourceKind:z.literal(`module`)}).strict(),compiledSubagentNodeSchema=z.union([z.object({...compiledSubagentNodeBaseFields,agent:compiledAgentNodeManifestSchema,description:z.string()}).strict(),z.object({...compiledSubagentNodeBaseFields,agent:compiledAgentResourcesSchema,configResolver:compiledDynamicSubagentDefinitionSchema}).strict()]),compiledAgentManifestSchema=z.object({agentRoot:z.string(),appRoot:z.string(),bindings:z.record(z.string(),compiledModuleBindingSchema),extensionMounts:z.array(compiledExtensionMountSchema).default([]),channelRoutes:compiledChannelRoutePlanSchema,config:compiledAgentConfigSchema,connections:z.array(compiledConnectionDefinitionSchema),dynamicConnections:z.array(compiledDynamicConnectionDefinitionSchema).default([]),diagnosticsSummary:discoverDiagnosticsSummarySchema,sourceComposition:agentSourceCompositionSchema,dynamicInstructions:z.array(compiledDynamicInstructionsDefinitionSchema).default([]),dynamicSkills:z.array(compiledDynamicSkillDefinitionSchema).default([]),dynamicTools:z.array(compiledDynamicToolDefinitionSchema).default([]),hooks:z.array(compiledHookDefinitionSchema),memories:z.array(compiledMemoryDefinitionSchema).default([]),kind:z.literal(COMPILED_AGENT_MANIFEST_KIND),remoteAgents:z.array(compiledRemoteAgentNodeSchema),sandbox:compiledSandboxDefinitionSchema,sandboxWorkspaces:z.array(compiledSandboxWorkspaceSchema),schedules:z.array(compiledScheduleDefinitionSchema),skills:z.array(compiledSkillSourceSchema).readonly(),subagents:z.array(compiledSubagentNodeSchema),instructions:z.array(compiledInstructionsSchema).readonly().default([]),tools:z.array(compiledToolDefinitionSchema),version:z.literal(54),workspaceResourceRoot:compiledWorkspaceResourceRootSchema}).strict();function createCompiledAgentResources(e){return{agentRoot:e.agentRoot,appRoot:e.appRoot,bindings:{...e.bindings},channelRoutes:{effective:[...e.channelRoutes.effective],preflight:[...e.channelRoutes.preflight],shadowed:[...e.channelRoutes.shadowed]},connections:[...e.connections??[]],dynamicConnections:[...e.dynamicConnections??[]],diagnosticsSummary:e.diagnosticsSummary??{errors:0,warnings:0},sourceComposition:{entries:[...e.sourceComposition.entries]},dynamicInstructions:[...e.dynamicInstructions??[]],dynamicSkills:[...e.dynamicSkills??[]],dynamicTools:[...e.dynamicTools??[]],extensionMounts:[...e.extensionMounts??[]],hooks:[...e.hooks??[]],memories:[...e.memories??[]],instructions:[...e.instructions??[]],remoteAgents:[...e.remoteAgents??[]],sandbox:e.sandbox,sandboxWorkspaces:[...e.sandboxWorkspaces??[]],schedules:[...e.schedules??[]],skills:[...e.skills??[]],tools:[...e.tools??[]],workspaceResourceRoot:e.workspaceResourceRoot??{logicalPath:``,rootEntries:deriveResourceRootEntries({sandboxWorkspaces:e.sandboxWorkspaces,skills:e.skills})}}}function createCompiledAgentNodeManifest(e){let t={...createCompiledAgentResources(e),config:cloneCompiledAgentDefinition(e.config)};return validateCompiledAgentResources(t,{allowUnknownResourceWinners:!0}),t}function cloneCompiledAgentDefinition(e){let t={build:e.build===void 0?void 0:{externalDependencies:e.build.externalDependencies===void 0?void 0:[...e.build.externalDependencies]},compaction:{model:e.compaction?.model===void 0?void 0:cloneCompiledRuntimeModelReference(e.compaction.model),thresholdPercent:e.compaction?.thresholdPercent},defaultTools:e.defaultTools,description:e.description,experimental:e.experimental===void 0?void 0:{workflow:e.experimental.workflow===void 0?void 0:{modelCallsPerStep:e.experimental.workflow.modelCallsPerStep,retention:e.experimental.workflow.retention,world:e.experimental.workflow.world}},name:e.name,reasoning:e.reasoning,limits:e.limits===void 0?void 0:{maxInputTokensPerSession:e.limits.maxInputTokensPerSession,maxOutputTokensPerSession:e.limits.maxOutputTokensPerSession,maxTokenCostUsdPerSession:e.limits.maxTokenCostUsdPerSession,sessionTimeoutMs:e.limits.sessionTimeoutMs},source:{...e.source},tool:e.tool};return e.dynamicModel===void 0?{...t,model:cloneCompiledRuntimeModelReference(e.model)}:{...t,dynamicModel:{...e.dynamicModel}}}function deriveResourceRootEntries(e){let t=new Set;for(let n of e.sandboxWorkspaces??[])for(let e of n.rootEntries)t.add(e);return[...t].sort((e,t)=>e.localeCompare(t))}function createCompiledSubagentNodeId(e,t){return e===`__root__`?t:`${e}::${t}`}function createCompiledAgentManifest(e){let t={...createCompiledAgentNodeManifest(e),kind:COMPILED_AGENT_MANIFEST_KIND,extensionMounts:[...e.extensionMounts??[]],subagents:[...e.subagents??[]],version:54};return validateCompiledAgentManifest(t),t}function cloneCompiledRuntimeModelReference(e){let t={id:e.id,routing:cloneModelRouting(e.routing)};return e.contextWindowTokens!==void 0&&(t.contextWindowTokens=e.contextWindowTokens),e.maxOutputTokens!==void 0&&(t.maxOutputTokens=e.maxOutputTokens),e.providerOptions!==void 0&&(t.providerOptions={...e.providerOptions}),e.source!==void 0&&(t.source={...e.source}),t}function cloneModelRouting(e){return e.kind===`external`?{kind:`external`,provider:e.provider}:e.byok===void 0?{kind:`gateway`,target:e.target}:{kind:`gateway`,target:e.target,byok:e.byok}}export{COMPILED_AGENT_MANIFEST_KIND,COMPILED_AGENT_MANIFEST_VERSION,ROOT_COMPILED_AGENT_NODE_ID,compiledAgentManifestSchema,createCompiledAgentManifest,createCompiledAgentNodeManifest,createCompiledAgentResources,createCompiledSubagentNodeId,deriveResourceRootEntries};
|
|
1
|
+
import{z}from"#compiled/zod/index.js";import{mountIdSchema}from"#shared/extension-mount.js";import{discoverDiagnosticsSummarySchema}from"#discover/diagnostics.js";import{compiledRemoteAgentNodeSchema}from"#compiler/remote-agent-node.js";import{jsonObjectSchema}from"#shared/json-schemas.js";import{AGENT_WORKFLOW_RETENTION_VALUES}from"#shared/agent-definition.js";import{validateCompiledAgentManifest,validateCompiledAgentResources}from"#compiler/validate-artifact.js";const COMPILED_AGENT_MANIFEST_KIND=`eve-agent-compiled-manifest`,ROOT_COMPILED_AGENT_NODE_ID=`__root__`,COMPILED_AGENT_MANIFEST_VERSION=54,agentSourceOwnerSchema=z.discriminatedUnion(`kind`,[z.object({kind:z.literal(`application`)}).strict(),z.object({feature:z.string().min(1),kind:z.literal(`framework`)}).strict(),z.object({kind:z.literal(`extension`),mountId:mountIdSchema,namespace:z.string().min(1),packageName:z.string().min(1)}).strict()]),moduleSourceRefSchema=z.object({exportName:z.string().optional(),sourceKind:z.literal(`module`),logicalPath:z.string(),sourceId:z.string()}).strict(),filesystemModuleBackingSchema=z.object({externalDependencies:z.array(z.string()).readonly(),extensionScope:z.object({namespace:z.string(),sourceRoot:z.string()}).strict().optional(),mountId:z.string().optional(),kind:z.literal(`filesystem`),sourcePath:z.string()}).strict(),programmaticModuleBackingSchema=z.object({dependencies:z.record(z.string(),z.string()).readonly().optional(),kind:z.literal(`programmatic`),mountId:z.string().optional(),moduleId:z.string(),parameters:jsonObjectSchema.optional(),registryId:z.string(),revision:z.string(),semanticRevision:z.string().optional()}).strict(),resourceSourceBackingSchema=z.object({kind:z.literal(`resource`),sourcePath:z.string()}).strict(),agentModuleBackingSchema=z.discriminatedUnion(`kind`,[filesystemModuleBackingSchema,programmaticModuleBackingSchema]),compiledModuleBindingSchema=z.object({backing:agentModuleBackingSchema,logicalPath:z.string(),owner:agentSourceOwnerSchema,usage:z.object({compile:z.boolean(),runtimeEntry:z.boolean()}).strict()}).strict(),agentSourceDescriptorSchema=z.object({backing:z.discriminatedUnion(`kind`,[filesystemModuleBackingSchema,programmaticModuleBackingSchema,resourceSourceBackingSchema]),form:z.enum([`derived`,`direct`]),layer:z.enum([`framework-default`,`extension-package`,`extension-override`,`application`]),logicalPath:z.string(),owner:agentSourceOwnerSchema,sourceId:z.string()}).strict(),agentSourceCompositionSchema=z.object({entries:z.array(z.discriminatedUnion(`kind`,[z.object({kind:z.literal(`shadowed`),source:agentSourceDescriptorSchema,winnerSourceId:z.string()}).strict(),z.object({kind:z.literal(`disabled`),source:agentSourceDescriptorSchema}).strict()])).readonly()}).strict(),compiledDynamicModelDefinitionSchema=z.object({eventNames:z.array(z.string()).readonly(),exportName:z.string().optional(),sourceKind:z.literal(`module`),logicalPath:z.string(),sourceId:z.string()}).strict(),channelMethodSchema=z.union([z.literal(`GET`),z.literal(`HEAD`),z.literal(`POST`),z.literal(`PUT`),z.literal(`PATCH`),z.literal(`DELETE`),z.literal(`OPTIONS`),z.literal(`WEBSOCKET`)]),compiledChannelCorsSchema=z.object({origin:z.union([z.literal(`*`),z.literal(`null`),z.array(z.string())]).optional(),methods:z.union([z.literal(`*`),z.array(z.string())]).optional(),allowHeaders:z.union([z.literal(`*`),z.array(z.string())]).optional(),exposeHeaders:z.union([z.literal(`*`),z.array(z.string())]).optional(),credentials:z.boolean().optional(),maxAge:z.union([z.string(),z.literal(!1)]).optional(),preflight:z.object({statusCode:z.number().int().min(100).max(599).optional()}).strict().optional()}).strict(),compiledVercelConnectMetadataSchema=z.object({connector:z.string(),requirement:z.object({method:z.string().optional(),reference:z.string(),service:z.string(),subjectTypes:z.array(z.enum([`app`,`user`])).readonly()}).strict().optional()}).strict(),compiledChannelDefinitionSchema=z.object({kind:z.literal(`channel`),name:z.string(),logicalPath:z.string(),method:channelMethodSchema,urlPath:z.string(),sourceId:z.string(),sourceKind:z.literal(`module`),exportName:z.string().optional(),adapterKind:z.string().optional(),cors:compiledChannelCorsSchema.optional(),manifest:jsonObjectSchema.optional(),vercelConnect:compiledVercelConnectMetadataSchema.optional()}).strict(),compiledChannelPreflightDefinitionSchema=z.object({cors:compiledChannelCorsSchema,method:z.literal(`OPTIONS`),sourceIds:z.array(z.string()).readonly(),urlPath:z.string()}).strict(),compiledShadowedChannelRouteSchema=z.object({method:channelMethodSchema,source:agentSourceDescriptorSchema,urlPath:z.string(),winnerSourceId:z.string()}).strict(),compiledChannelRoutePlanSchema=z.object({effective:z.array(compiledChannelDefinitionSchema).readonly(),preflight:z.array(compiledChannelPreflightDefinitionSchema).readonly(),shadowed:z.array(compiledShadowedChannelRouteSchema).readonly()}).strict(),modelRoutingSchema=z.union([z.object({kind:z.literal(`gateway`),target:z.string(),byok:z.string().optional()}).strict(),z.object({kind:z.literal(`external`),provider:z.string()}).strict()]),compiledRuntimeModelReferenceSchema=z.object({contextWindowTokens:z.number().int().positive().optional(),id:z.string(),maxOutputTokens:z.number().int().positive().optional(),source:moduleSourceRefSchema.optional(),providerOptions:z.record(z.string(),jsonObjectSchema).optional(),routing:modelRoutingSchema}).strict(),compiledAgentBuildDefinitionSchema=z.object({externalDependencies:z.array(z.string()).optional()}).strict(),compiledAgentWorkflowWorldDefinitionSchema=z.string(),compiledAgentWorkflowDefinitionSchema=z.object({modelCallsPerStep:z.number().int().positive().optional(),retention:z.literal(AGENT_WORKFLOW_RETENTION_VALUES).optional(),world:compiledAgentWorkflowWorldDefinitionSchema.optional()}).strict(),compiledAgentCompactionDefinitionSchema=z.object({model:compiledRuntimeModelReferenceSchema.optional(),thresholdPercent:z.number().finite().min(0).max(1).optional()}).strict(),sessionTokenLimitSchema=z.union([z.number().int().positive(),z.literal(!1)]),sessionTokenCostLimitSchema=z.union([z.number().finite().positive(),z.literal(!1)]),sessionTimeoutSchema=z.union([z.number().int().positive(),z.literal(!1)]),compiledAgentLimitsDefinitionSchema=z.object({maxInputTokensPerSession:sessionTokenLimitSchema.optional(),maxOutputTokensPerSession:sessionTokenLimitSchema.optional(),maxTokenCostUsdPerSession:sessionTokenCostLimitSchema.optional(),sessionTimeoutMs:sessionTimeoutSchema.optional()}).strict(),compiledAgentConfigBaseFields={build:compiledAgentBuildDefinitionSchema.optional(),compaction:compiledAgentCompactionDefinitionSchema.optional(),defaultTools:z.boolean().optional(),description:z.string().optional(),experimental:z.object({workflow:compiledAgentWorkflowDefinitionSchema.optional()}).strict().optional(),name:z.string(),reasoning:z.enum([`provider-default`,`none`,`minimal`,`low`,`medium`,`high`,`xhigh`]).optional(),source:moduleSourceRefSchema,tool:z.boolean().optional(),limits:compiledAgentLimitsDefinitionSchema.optional()},compiledAgentConfigSchema=z.union([z.object({...compiledAgentConfigBaseFields,model:compiledRuntimeModelReferenceSchema}).strict(),z.object({...compiledAgentConfigBaseFields,dynamicModel:compiledDynamicModelDefinitionSchema}).strict()]),compiledInstructionsBaseFields={content:z.string(),name:z.string(),logicalPath:z.string(),role:z.enum([`system`,`user`]),sourceId:z.string()},compiledInstructionsSchema=z.discriminatedUnion(`sourceKind`,[z.object({...compiledInstructionsBaseFields,owner:agentSourceOwnerSchema,sourceKind:z.literal(`markdown`)}).strict(),z.object({...compiledInstructionsBaseFields,sourceKind:z.literal(`module`)}).strict()]),compiledSkillBaseFields={name:z.string(),description:z.string(),license:z.string().optional(),markdown:z.string(),metadata:z.record(z.string(),z.string()).optional(),sourceId:z.string(),logicalPath:z.string()},compiledSkillSourceSchema=z.discriminatedUnion(`sourceKind`,[z.object({...compiledSkillBaseFields,owner:agentSourceOwnerSchema,sourceKind:z.literal(`markdown`)}).strict(),z.object({...compiledSkillBaseFields,sourceKind:z.literal(`module`),exportName:z.string().optional()}).strict(),z.object({...compiledSkillBaseFields,owner:agentSourceOwnerSchema,sourceKind:z.literal(`skill-package`),skillId:z.string(),skillFilePath:z.string(),rootPath:z.string(),assetsPath:z.string().optional(),referencesPath:z.string().optional(),scriptsPath:z.string().optional()}).strict()]),compiledScheduleBaseFields={cron:z.string(),hasRun:z.boolean(),name:z.string(),logicalPath:z.string(),markdown:z.string().optional(),sourceId:z.string()},compiledScheduleDefinitionSchema=z.discriminatedUnion(`sourceKind`,[z.object({...compiledScheduleBaseFields,owner:agentSourceOwnerSchema,sourceKind:z.literal(`markdown`)}).strict(),z.object({...compiledScheduleBaseFields,sourceKind:z.literal(`module`)}).strict()]),compiledScheduleCollectionDefinitionSchema=z.object({description:z.string().optional(),logicalPath:z.string(),name:z.string(),providerKind:z.string(),sourceId:z.string(),sourceKind:z.literal(`module`),tools:z.boolean().optional()}).strict(),compiledSandboxDefinitionSchema=z.object({providerName:z.string().optional(),environmentExportName:z.string().optional(),inheritsParent:z.boolean().optional(),exportName:z.string().optional(),logicalPath:z.string(),revisionHash:z.string(),sourceId:z.string(),sourceKind:z.literal(`module`)}).strict(),compiledSandboxWorkspaceSchema=z.object({logicalPath:z.string(),rootEntries:z.array(z.string()).readonly(),sourceId:z.string(),sourcePath:z.string()}).strict(),compiledWorkspaceResourceRootSchema=z.object({contentHash:z.string().optional(),logicalPath:z.string(),rootEntries:z.array(z.string()).readonly()}).strict(),compiledConnectionDefinitionSchema=z.object({connectionName:z.string(),description:z.string(),exportName:z.string().optional(),logicalPath:z.string(),protocol:z.enum([`mcp`,`openapi`]).default(`mcp`),sourceId:z.string(),sourceKind:z.literal(`module`),url:z.string(),vercelConnect:compiledVercelConnectMetadataSchema.optional()}).strict(),compiledDynamicConnectionDefinitionSchema=z.object({eventNames:z.array(z.string()).readonly(),exportName:z.string().optional(),extensionNamespace:z.string().optional(),logicalPath:z.string(),slug:z.string(),sourceId:z.string(),sourceKind:z.literal(`module`)}).strict(),compiledToolBehaviorSchema=z.object({availability:z.array(z.literal(`root-session`)).readonly(),handling:z.discriminatedUnion(`kind`,[z.object({action:z.literal(`self-agent`),kind:z.literal(`dispatch`)}).strict(),z.object({kind:z.literal(`provider-tool`),provider:z.enum([`exa`,`parallel`,`browserbase`])}).strict(),z.object({entryPoint:z.enum([`execute`,`task`,`serve`]),kind:z.literal(`workflow-tool`),workflowId:z.string()}).strict()]).optional(),presentation:z.literal(`load-skill`).optional(),shape:z.object({suspend:z.enum([`none`,`workflow`])}).strict().optional()}).strict(),compiledToolDefinitionSchema=z.object({availableInSubagents:z.boolean().optional(),behavior:compiledToolBehaviorSchema.optional(),description:z.string(),exportName:z.string().optional(),hasExecute:z.boolean(),hasModelOutputProjection:z.boolean(),inputSchema:jsonObjectSchema.nullable(),logicalPath:z.string(),modelInputSchema:jsonObjectSchema.optional(),name:z.string(),outputSchema:jsonObjectSchema.optional(),requiresApproval:z.boolean(),sourceId:z.string(),sourceKind:z.literal(`module`),workflowProgram:z.object({maxSubagents:z.number().int().positive()}).strict().optional()}).strict(),compiledDynamicToolDefinitionSchema=z.object({eventNames:z.array(z.string()).readonly(),exportName:z.string().optional(),extensionNamespace:z.string().optional(),logicalPath:z.string(),rebindMissingCallbacks:z.boolean().optional(),slug:z.string(),sourceId:z.string(),sourceKind:z.literal(`module`)}).strict(),compiledMemoryDefinitionSchema=z.object({description:z.string().optional(),exportName:z.string().optional(),logicalPath:z.string(),slot:z.string(),sourceId:z.string(),sourceKind:z.literal(`module`),visibility:z.enum([`scope`,`session`])}).strict(),compiledDynamicSkillDefinitionSchema=z.object({eventNames:z.array(z.string()).readonly(),exportName:z.string().optional(),extensionNamespace:z.string().optional(),logicalPath:z.string(),slug:z.string(),sourceId:z.string(),sourceKind:z.literal(`module`)}).strict(),compiledDynamicInstructionsDefinitionSchema=z.object({eventNames:z.array(z.string()).readonly(),exportName:z.string().optional(),logicalPath:z.string(),slug:z.string(),sourceId:z.string(),sourceKind:z.literal(`module`)}).strict(),compiledHookDefinitionSchema=z.object({eventNames:z.array(z.string()).readonly(),exportName:z.string().optional(),logicalPath:z.string(),slug:z.string(),sourceId:z.string(),sourceKind:z.literal(`module`)}).strict(),compiledExtensionMountSchema=z.object({externalDependencies:z.array(z.string()).readonly(),namespace:z.string(),packageName:z.string(),specifier:z.string(),mountId:mountIdSchema,sourceRoot:z.string(),mountSourceId:z.string(),mountSourcePath:z.string(),mountLogicalPath:z.string(),programmaticImport:z.object({specifier:z.string(),entryPath:z.string(),config:jsonObjectSchema}).strict().optional()}).strict(),compiledAgentResourceFields={agentRoot:z.string(),appRoot:z.string(),bindings:z.record(z.string(),compiledModuleBindingSchema),channelRoutes:compiledChannelRoutePlanSchema,connections:z.array(compiledConnectionDefinitionSchema),dynamicConnections:z.array(compiledDynamicConnectionDefinitionSchema).default([]),diagnosticsSummary:discoverDiagnosticsSummarySchema,sourceComposition:agentSourceCompositionSchema,dynamicInstructions:z.array(compiledDynamicInstructionsDefinitionSchema).default([]),dynamicSkills:z.array(compiledDynamicSkillDefinitionSchema).default([]),dynamicTools:z.array(compiledDynamicToolDefinitionSchema).default([]),extensionMounts:z.array(compiledExtensionMountSchema).default([]),hooks:z.array(compiledHookDefinitionSchema),memories:z.array(compiledMemoryDefinitionSchema).default([]),sandbox:compiledSandboxDefinitionSchema,sandboxWorkspaces:z.array(compiledSandboxWorkspaceSchema),schedules:z.array(compiledScheduleDefinitionSchema),scheduleCollections:z.array(compiledScheduleCollectionDefinitionSchema).default([]),remoteAgents:z.array(compiledRemoteAgentNodeSchema),skills:z.array(compiledSkillSourceSchema).readonly(),instructions:z.array(compiledInstructionsSchema).readonly().default([]),tools:z.array(compiledToolDefinitionSchema),workspaceResourceRoot:compiledWorkspaceResourceRootSchema},compiledAgentResourcesSchema=z.object(compiledAgentResourceFields).strict(),compiledAgentNodeManifestSchema=z.object({...compiledAgentResourceFields,config:compiledAgentConfigSchema}).strict(),compiledSubagentNodeBaseFields={backing:resourceSourceBackingSchema,entryPath:z.string(),logicalPath:z.string(),name:z.string(),nodeId:z.string(),owner:agentSourceOwnerSchema,parentNodeId:z.string(),rootPath:z.string(),sourceId:z.string(),sourceKind:z.literal(`module`),exportName:z.string().optional()},compiledDynamicSubagentDefinitionSchema=z.object({build:compiledAgentBuildDefinitionSchema.optional(),eventNames:z.array(z.string()).readonly(),exportName:z.string().optional(),logicalPath:z.string(),sourceId:z.string(),sourceKind:z.literal(`module`)}).strict(),compiledSubagentNodeSchema=z.union([z.object({...compiledSubagentNodeBaseFields,agent:compiledAgentNodeManifestSchema,description:z.string()}).strict(),z.object({...compiledSubagentNodeBaseFields,agent:compiledAgentResourcesSchema,configResolver:compiledDynamicSubagentDefinitionSchema}).strict()]),compiledAgentManifestSchema=z.object({agentRoot:z.string(),appRoot:z.string(),bindings:z.record(z.string(),compiledModuleBindingSchema),extensionMounts:z.array(compiledExtensionMountSchema).default([]),channelRoutes:compiledChannelRoutePlanSchema,config:compiledAgentConfigSchema,connections:z.array(compiledConnectionDefinitionSchema),dynamicConnections:z.array(compiledDynamicConnectionDefinitionSchema).default([]),diagnosticsSummary:discoverDiagnosticsSummarySchema,sourceComposition:agentSourceCompositionSchema,dynamicInstructions:z.array(compiledDynamicInstructionsDefinitionSchema).default([]),dynamicSkills:z.array(compiledDynamicSkillDefinitionSchema).default([]),dynamicTools:z.array(compiledDynamicToolDefinitionSchema).default([]),hooks:z.array(compiledHookDefinitionSchema),memories:z.array(compiledMemoryDefinitionSchema).default([]),kind:z.literal(COMPILED_AGENT_MANIFEST_KIND),remoteAgents:z.array(compiledRemoteAgentNodeSchema),sandbox:compiledSandboxDefinitionSchema,sandboxWorkspaces:z.array(compiledSandboxWorkspaceSchema),schedules:z.array(compiledScheduleDefinitionSchema),scheduleCollections:z.array(compiledScheduleCollectionDefinitionSchema).default([]),skills:z.array(compiledSkillSourceSchema).readonly(),subagents:z.array(compiledSubagentNodeSchema),instructions:z.array(compiledInstructionsSchema).readonly().default([]),tools:z.array(compiledToolDefinitionSchema),version:z.literal(54),workspaceResourceRoot:compiledWorkspaceResourceRootSchema}).strict();function createCompiledAgentResources(e){return{agentRoot:e.agentRoot,appRoot:e.appRoot,bindings:{...e.bindings},channelRoutes:{effective:[...e.channelRoutes.effective],preflight:[...e.channelRoutes.preflight],shadowed:[...e.channelRoutes.shadowed]},connections:[...e.connections??[]],dynamicConnections:[...e.dynamicConnections??[]],diagnosticsSummary:e.diagnosticsSummary??{errors:0,warnings:0},sourceComposition:{entries:[...e.sourceComposition.entries]},dynamicInstructions:[...e.dynamicInstructions??[]],dynamicSkills:[...e.dynamicSkills??[]],dynamicTools:[...e.dynamicTools??[]],extensionMounts:[...e.extensionMounts??[]],hooks:[...e.hooks??[]],memories:[...e.memories??[]],instructions:[...e.instructions??[]],remoteAgents:[...e.remoteAgents??[]],sandbox:e.sandbox,sandboxWorkspaces:[...e.sandboxWorkspaces??[]],schedules:[...e.schedules??[]],scheduleCollections:[...e.scheduleCollections??[]],skills:[...e.skills??[]],tools:[...e.tools??[]],workspaceResourceRoot:e.workspaceResourceRoot??{logicalPath:``,rootEntries:deriveResourceRootEntries({sandboxWorkspaces:e.sandboxWorkspaces,skills:e.skills})}}}function createCompiledAgentNodeManifest(e){let t={...createCompiledAgentResources(e),config:cloneCompiledAgentDefinition(e.config)};return validateCompiledAgentResources(t,{allowUnknownResourceWinners:!0}),t}function cloneCompiledAgentDefinition(e){let t={build:e.build===void 0?void 0:{externalDependencies:e.build.externalDependencies===void 0?void 0:[...e.build.externalDependencies]},compaction:{model:e.compaction?.model===void 0?void 0:cloneCompiledRuntimeModelReference(e.compaction.model),thresholdPercent:e.compaction?.thresholdPercent},defaultTools:e.defaultTools,description:e.description,experimental:e.experimental===void 0?void 0:{workflow:e.experimental.workflow===void 0?void 0:{modelCallsPerStep:e.experimental.workflow.modelCallsPerStep,retention:e.experimental.workflow.retention,world:e.experimental.workflow.world}},name:e.name,reasoning:e.reasoning,limits:e.limits===void 0?void 0:{maxInputTokensPerSession:e.limits.maxInputTokensPerSession,maxOutputTokensPerSession:e.limits.maxOutputTokensPerSession,maxTokenCostUsdPerSession:e.limits.maxTokenCostUsdPerSession,sessionTimeoutMs:e.limits.sessionTimeoutMs},source:{...e.source},tool:e.tool};return e.dynamicModel===void 0?{...t,model:cloneCompiledRuntimeModelReference(e.model)}:{...t,dynamicModel:{...e.dynamicModel}}}function deriveResourceRootEntries(e){let t=new Set;for(let n of e.sandboxWorkspaces??[])for(let e of n.rootEntries)t.add(e);return[...t].sort((e,t)=>e.localeCompare(t))}function createCompiledSubagentNodeId(e,t){return e===`__root__`?t:`${e}::${t}`}function createCompiledAgentManifest(e){let t={...createCompiledAgentNodeManifest(e),kind:COMPILED_AGENT_MANIFEST_KIND,extensionMounts:[...e.extensionMounts??[]],subagents:[...e.subagents??[]],version:54};return validateCompiledAgentManifest(t),t}function cloneCompiledRuntimeModelReference(e){let t={id:e.id,routing:cloneModelRouting(e.routing)};return e.contextWindowTokens!==void 0&&(t.contextWindowTokens=e.contextWindowTokens),e.maxOutputTokens!==void 0&&(t.maxOutputTokens=e.maxOutputTokens),e.providerOptions!==void 0&&(t.providerOptions={...e.providerOptions}),e.source!==void 0&&(t.source={...e.source}),t}function cloneModelRouting(e){return e.kind===`external`?{kind:`external`,provider:e.provider}:e.byok===void 0?{kind:`gateway`,target:e.target}:{kind:`gateway`,target:e.target,byok:e.byok}}export{COMPILED_AGENT_MANIFEST_KIND,COMPILED_AGENT_MANIFEST_VERSION,ROOT_COMPILED_AGENT_NODE_ID,compiledAgentManifestSchema,createCompiledAgentManifest,createCompiledAgentNodeManifest,createCompiledAgentResources,createCompiledSubagentNodeId,deriveResourceRootEntries};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{canonicalSourceSlot,instantiateProgrammaticTemplate}from"#compiler/source-graph.js";import{deriveMemorySlot}from"#compiler/normalize-memory.js";import{memoryWrapperTemplate}from"#framework/sources/registry.js";function createMemoryWrapperCandidates(e){return e.filter(e=>e.backing.kind!==`resource`&&(canonicalSourceSlot(e.logicalPath)===`memory`||canonicalSourceSlot(e.logicalPath).startsWith(`memory/`))).map(e=>{let t=deriveMemorySlot(e.logicalPath);return instantiateProgrammaticTemplate({anchor:e,dependencies:{memory:e},logicalPath:`tools/${t}.ts`,owner:{feature:`memory`,kind:`framework`},parameters:{memoryExportName:e.exportName??`default`,memoryLogicalPath:e.logicalPath,slot:t},template:memoryWrapperTemplate})})}export{createMemoryWrapperCandidates};
|
|
@@ -5,7 +5,7 @@ import { createCompiledBindingNamespaceLoader, type CompiledBindingNamespaceLoad
|
|
|
5
5
|
export declare class NodeModuleEvaluationContext {
|
|
6
6
|
#private;
|
|
7
7
|
readonly loadNamespace: CompiledBindingNamespaceLoader;
|
|
8
|
-
constructor(registries: readonly AgentSourceRegistry[], mountSourceId?: (binding: AgentModuleBinding) => string | undefined, mounts?: Parameters<typeof createCompiledBindingNamespaceLoader>[0]["mounts"], evaluationId?: string);
|
|
8
|
+
constructor(registries: readonly AgentSourceRegistry[], mountSourceId?: (binding: AgentModuleBinding) => string | undefined, mounts?: Parameters<typeof createCompiledBindingNamespaceLoader>[0]["mounts"], evaluationId?: string, appRoot?: string);
|
|
9
9
|
setBindings(bindings: Readonly<Record<string, AgentModuleBinding>>): void;
|
|
10
10
|
requireRuntimeEntry(sourceId: string): void;
|
|
11
11
|
finalizeBindings(): Record<string, CompiledModuleBinding>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{createCompiledBindingNamespaceLoader}from"#compiler/load-binding-namespace.js";var NodeModuleEvaluationContext=class{#e={};#t=new NodeModuleLifecycle;loadNamespace;constructor(e,t,n,r){this.loadNamespace=createCompiledBindingNamespaceLoader({mountSourceId:t,mounts:n,evaluationId:r,onLoad:e=>this.#t.recordCompileLoad(e),registries:e,resolveBinding:e=>this.#e[e]})}setBindings(e){this.#e=e}requireRuntimeEntry(e){this.#t.requireRuntimeEntry(e)}finalizeBindings(){return this.#t.finalize(this.#e)}};function markConfigRuntimeEntries(e,t){let n=[e.dynamicModel,e.model?.source,e.compaction?.model?.source];for(let e of n)e!==void 0&&t.requireRuntimeEntry(e.sourceId)}var NodeModuleLifecycle=class{#e=new Set;#t=new Set;recordCompileLoad(e){this.#e.add(e)}requireRuntimeEntry(e){this.#t.add(e)}finalize(e){let t=collectRuntimeEntryClosure(e,this.#t),n={};for(let[r,i]of Object.entries(e)){let e={compile:this.#e.has(r),runtimeEntry:t.has(r)};if(!e.compile&&!e.runtimeEntry)throw Error(`Selected module binding "${r}" has no compile or runtime usage.`);n[r]=Object.freeze({...i,usage:Object.freeze(e)})}return n}};function collectRuntimeEntryClosure(e,t){let n=new Set,r=new Set,visit=t=>{if(n.has(t))return;if(r.has(t))throw Error(`Compiled module dependency cycle includes "${t}".`);let i=e[t];if(i===void 0)throw Error(`Runtime module entry "${t}" has no selected binding.`);if(r.add(t),i.backing.kind===`programmatic`)for(let e of Object.values(i.backing.dependencies??{}))visit(e);r.delete(t),n.add(t)};for(let e of t)visit(e);return n}export{NodeModuleEvaluationContext,markConfigRuntimeEntries};
|
|
1
|
+
import{createCompiledBindingNamespaceLoader}from"#compiler/load-binding-namespace.js";var NodeModuleEvaluationContext=class{#e={};#t=new NodeModuleLifecycle;loadNamespace;constructor(e,t,n,r,i){this.loadNamespace=createCompiledBindingNamespaceLoader({appRoot:i,mountSourceId:t,mounts:n,evaluationId:r,onLoad:e=>this.#t.recordCompileLoad(e),registries:e,resolveBinding:e=>this.#e[e]})}setBindings(e){this.#e=e}requireRuntimeEntry(e){this.#t.requireRuntimeEntry(e)}finalizeBindings(){return this.#t.finalize(this.#e)}};function markConfigRuntimeEntries(e,t){let n=[e.dynamicModel,e.model?.source,e.compaction?.model?.source];for(let e of n)e!==void 0&&t.requireRuntimeEntry(e.sourceId)}var NodeModuleLifecycle=class{#e=new Set;#t=new Set;recordCompileLoad(e){this.#e.add(e)}requireRuntimeEntry(e){this.#t.add(e)}finalize(e){let t=collectRuntimeEntryClosure(e,this.#t),n={};for(let[r,i]of Object.entries(e)){let e={compile:this.#e.has(r),runtimeEntry:t.has(r)};if(!e.compile&&!e.runtimeEntry)throw Error(`Selected module binding "${r}" has no compile or runtime usage.`);n[r]=Object.freeze({...i,usage:Object.freeze(e)})}return n}};function collectRuntimeEntryClosure(e,t){let n=new Set,r=new Set,visit=t=>{if(n.has(t))return;if(r.has(t))throw Error(`Compiled module dependency cycle includes "${t}".`);let i=e[t];if(i===void 0)throw Error(`Runtime module entry "${t}" has no selected binding.`);if(r.add(t),i.backing.kind===`programmatic`)for(let e of Object.values(i.backing.dependencies??{}))visit(e);r.delete(t),n.add(t)};for(let e of t)visit(e);return n}export{NodeModuleEvaluationContext,markConfigRuntimeEntries};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import{z}from"#compiled/zod/index.js";import{ROOT_COMPILED_AGENT_NODE_ID}from"#compiler/manifest.js";import"#compiler/source-graph.js";import{createCompiledBindingNamespaceLoader,resolveExtensionBindingMountId}from"#compiler/load-binding-namespace.js";import{bindingMountId}from"#compiler/extension-mount-bindings.js";import{normalizeEsmImportSpecifier}from"#internal/application/import-specifier.js";const compiledModuleNodeScopeSchema=z.object({modules:z.record(z.string(),z.object({}).passthrough())}).strict(),compiledModuleMapSchema=z.object({nodes:z.record(z.string(),compiledModuleNodeScopeSchema)}).strict();function createCompiledModuleMapSource(e){let t=dirnameFilesystemPath(e.moduleMapPath),n=e.importSpecifierStyle??`relative`,r=0,i=!1,a=collectBoundNodeScopes(e.manifest).map(e=>{let a=new Map(e.mounts.map(e=>[e.mountSourceId,e])),o=new Map(e.mounts.map(e=>[e.mountId,e.mountSourceId])),s=new Map(e.modules.map(e=>[e.sourceId,`module_${r++}`]));return{modules:orderBoundModules(e.modules,e=>o.get(bindingMountId(e)??``)).map(({binding:e,sourceId:r})=>{let o=s.get(r);if(e.backing.kind===`filesystem`){let i=createImportSpecifier({fromDirectory:t,importSpecifierStyle:n,targetPath:e.backing.sourcePath})+(bindingMountId(e)===void 0?``:`?eve-mount=${encodeURIComponent(bindingMountId(e))}`),s=bindingMountId(e)!==void 0&&!a.has(r);return{bindingName:o,importSpecifier:s?void 0:i,initializer:`memoizeModuleNamespaceFactories(${s?`await import(${JSON.stringify(i)})`:`imported_${o}`})`,sourceId:r}}let c=a.get(r);if(c?.programmaticImport!==void 0){let e=`${c.programmaticImport.specifier}?eve-mount=${encodeURIComponent(c.mountId)}`;return{bindingName:o,initializer:`memoizeModuleNamespaceFactories({ default: (await import(${JSON.stringify(e)})).default(${JSON.stringify(c.programmaticImport.config)}) })`,sourceId:r}}return i=!0,{bindingName:o,initializer:`await loadProgrammaticModule(${JSON.stringify(e.backing)}, ${renderProgrammaticDependencies(e.backing.dependencies,s)})`,sourceId:r}}),nodeId:e.nodeId}}),o=a.flatMap(e=>e.modules),s=o.flatMap(e=>e.importSpecifier===void 0?[]:[`import * as imported_${e.bindingName} from ${JSON.stringify(e.importSpecifier)};`]),c=o.flatMap(e=>e.initializer===void 0?[]:[`const ${e.bindingName} = ${e.initializer};`]);return[`// Generated by eve. Do not edit by hand.`,...i||o.length>0?[`import { loadFrameworkProgrammaticModule as loadProgrammaticModule, memoizeModuleNamespaceFactories } from ${JSON.stringify(normalizeEsmImportSpecifier(e.programmaticLoaderImportSpecifier??`eve/internal/programmatic-source-loader`))};`]:[],...s,...i||o.length>0?[``]:[],...c,...c.length>0?[``]:[],`export const moduleMap = ${renderModuleMap(a)};`,``,`export default moduleMap;`,``].join(`
|
|
2
|
-
`)}async function createProgrammaticCompiledModuleMap(e,t){let n={};for(let r of collectBoundNodeScopes(e)){let
|
|
2
|
+
`)}async function createProgrammaticCompiledModuleMap(e,t){let n={};for(let r of collectBoundNodeScopes(e)){let i={},a=Object.fromEntries(r.modules.map(({binding:e,sourceId:t})=>[t,e])),o=new Map(r.mounts.map(e=>[e.mountId,e.mountSourceId])),s=createCompiledBindingNamespaceLoader({appRoot:e.appRoot,bindings:a,registries:t,mountSourceId:e=>o.get(bindingMountId(e)??``)});for(let{sourceId:e}of r.modules)i[e]=await s(e);n[r.nodeId]={modules:i}}return{nodes:n}}function collectRuntimeModuleBindingsForManifest(e){let t=new Map(Object.entries(e.bindings).filter(([,e])=>e.usage.runtimeEntry));for(let n of e.remoteAgents)if(n.binding.usage.runtimeEntry){if(t.has(n.sourceId))throw Error(`Remote agent binding "${n.sourceId}" collides with a node binding.`);t.set(n.sourceId,n.binding)}return orderBoundModules([...t].sort(([e],[t])=>e.localeCompare(t)).map(([e,t])=>({binding:t,sourceId:e})))}function orderBoundModules(e,t){let n=new Map(e.map(e=>[e.sourceId,e])),r=[],i=new Set,a=new Set,visit=e=>{if(a.has(e.sourceId))return;if(i.has(e.sourceId))throw Error(`Compiled module dependency cycle includes "${e.sourceId}".`);i.add(e.sourceId);let o=t?.(e.binding);if(o!==void 0&&o!==e.sourceId){let e=n.get(o);e!==void 0&&visit(e)}if(e.binding.backing.kind===`programmatic`)for(let t of Object.values(e.binding.backing.dependencies??{})){let r=n.get(t);if(r===void 0)throw Error(`Programmatic binding "${e.sourceId}" depends on missing binding "${t}".`);visit(r)}i.delete(e.sourceId),a.add(e.sourceId),r.push(e)};for(let t of e)visit(t);return r}function renderProgrammaticDependencies(e,t){let n=Object.entries(e??{});return n.length===0?`Object.freeze({})`:`Object.freeze({ ${n.map(([e,n])=>`${JSON.stringify(e)}: ${t.get(n)}`).join(`, `)} })`}function collectBoundNodeScopes(e){return[{modules:collectRuntimeModuleBindingsForManifest(e),mounts:e.extensionMounts,nodeId:ROOT_COMPILED_AGENT_NODE_ID},...[...e.subagents].sort((e,t)=>e.nodeId.localeCompare(t.nodeId)).map(e=>({modules:collectRuntimeModuleBindingsForManifest(e.agent),mounts:e.agent.extensionMounts,nodeId:e.nodeId}))]}function renderModuleMap(e){return renderFrozenObject([{key:`nodes`,value:renderFrozenObject(e.map(e=>({key:e.nodeId,value:renderFrozenObject([{key:`modules`,value:renderFrozenObject(e.modules.map(e=>({key:e.sourceId,value:e.bindingName})))}],3)})))}],0)}function renderFrozenObject(e,t=1){if(e.length===0)return`Object.freeze({})`;let n=` `.repeat(t),r=` `.repeat(t+1);return[`Object.freeze({`,e.map(e=>`${r}${JSON.stringify(e.key)}: ${e.value.replaceAll(`
|
|
3
3
|
`,`\n${r}`)}`).join(`,
|
|
4
4
|
`),`${n}})`].join(`
|
|
5
5
|
`)}function createImportSpecifier(e){if(e.importSpecifierStyle===`absolute`)return normalizeEsmImportSpecifier(normalizeFilesystemPath(e.targetPath));let t=relativeFilesystemPath(e.fromDirectory,e.targetPath);return t.startsWith(`.`)?t:`./${t}`}function dirnameFilesystemPath(e){let t=splitFilesystemPath(e);return t.segments.length===0?t.root.length===0?`.`:t.root:createFilesystemPath(t.root,t.segments.slice(0,-1))}function relativeFilesystemPath(e,t){let n=splitFilesystemPath(e),r=splitFilesystemPath(t);if(n.root!==r.root)return normalizeFilesystemPath(t);let i=0;for(;i<n.segments.length&&i<r.segments.length&&n.segments[i]===r.segments[i];)i+=1;return[...Array.from({length:n.segments.length-i},()=>`..`),...r.segments.slice(i)].join(`/`)||`.`}function normalizeFilesystemPath(e){let t=splitFilesystemPath(e);return createFilesystemPath(t.root,t.segments)}function splitFilesystemPath(e){let t=e.replaceAll(`\\`,`/`),n=``,r=t,i=t.match(/^[A-Za-z]:/);i===null?t.startsWith(`/`)&&(n=`/`,r=t.slice(1)):(n=i[0],r=t.slice(n.length),r.startsWith(`/`)&&(n+=`/`,r=r.slice(1)));let a=[];for(let e of r.split(`/`))e.length!==0&&e!==`.`&&(e===`..`?a.length>0&&a.at(-1)!==`..`?a.pop():n.length===0&&a.push(e):a.push(e));return{root:n,segments:a}}function createFilesystemPath(e,t){return e===`/`?t.length===0?`/`:`/${t.join(`/`)}`:e.endsWith(`/`)?t.length===0?e:`${e}${t.join(`/`)}`:e.length>0?t.length===0?e:`${e}/${t.join(`/`)}`:t.length===0?`.`:t.join(`/`)}export{collectRuntimeModuleBindingsForManifest,compiledModuleMapSchema,createCompiledModuleMapSource,createProgrammaticCompiledModuleMap,resolveExtensionBindingMountId};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{isAbsolute,relative,resolve}from"node:path";import{normalizeLogicalPath}from"#discover/filesystem.js";import{toErrorMessage}from"#shared/errors.js";import{parseJsonObject}from"#shared/json.js";import{isDynamicModelDefinition}from"#shared/agent-definition.js";import{createCompiledBindingNamespaceLoader}from"#compiler/load-binding-namespace.js";import{normalizeAgentDefinition}from"#internal/authored-definition/core.js";import{formatLanguageModelGatewayId}from"#internal/runtime-model.js";import{classifyModelRouting}from"#internal/classify-model-routing.js";import{isChatGptModelRouting}from"#shared/chatgpt-model.js";import{loadModuleBackedDefinition}from"#compiler/normalize-helpers.js";async function compileAgentConfig(e,t,n){let r=n.source,i=formatAgentConfigModulePath(e,r,n.binding),a=normalizeAgentDefinition(Object.hasOwn(n,`definition`)?n.definition:await loadModuleBackedDefinition({binding:n.binding,displayPath:i,kind:`agent config`,loadNamespace:createCompiledBindingNamespaceLoader({bindings:{[r.sourceId]:n.binding},registries:t.registries}),source:r}),`Expected the agent config export "${r.exportName??`default`}" from "${i}" to match the public eve shape.`),o=isDynamicModelDefinition(a.model)?a.model:void 0,s=o===void 0?await normalizeAuthoredModelReference({modelCatalog:t.modelCatalog,purpose:`the primary compaction trigger model`,contextWindowTokens:a.modelContextWindowTokens,providerOptions:a.modelOptions?.providerOptions,source:r,sourcePath:i,value:a.model}):void 0,c={},l={compaction:c,name:e.agentId,source:{...r}};a.defaultTools!==void 0&&(l.defaultTools=a.defaultTools),a.description!==void 0&&(l.description=a.description);let u;o!==void 0&&(u={eventNames:Object.keys(o.events),exportName:r.exportName,sourceKind:`module`,logicalPath:r.logicalPath,sourceId:r.sourceId});let d=normalizeExperimentalDefinition(a.experimental);if(d!==void 0&&(l.experimental=d),a.build!==void 0&&(l.build={externalDependencies:a.build.externalDependencies===void 0?void 0:[...a.build.externalDependencies]}),a.reasoning!==void 0&&(l.reasoning=a.reasoning),a.tool!==void 0&&(l.tool=a.tool),a.limits!==void 0&&(l.limits={maxInputTokensPerSession:a.limits.maxInputTokensPerSession,maxOutputTokensPerSession:a.limits.maxOutputTokensPerSession,maxTokenCostUsdPerSession:a.limits.maxTokenCostUsdPerSession,sessionTimeoutMs:a.limits.sessionTimeoutMs}),a.compaction?.model!==void 0&&(c.model=await normalizeAuthoredModelReference({modelCatalog:t.modelCatalog,purpose:`the compaction summary model`,contextWindowTokens:a.compaction.modelContextWindowTokens,providerOptions:a.modelOptions?.providerOptions,source:r,sourcePath:i,value:a.compaction.model})),a.compaction?.thresholdPercent!==void 0&&(c.thresholdPercent=a.compaction.thresholdPercent),u!==void 0)return{...l,dynamicModel:u};if(s===void 0)throw Error(`Expected a static agent model to compile to a concrete model reference.`);return{...l,model:s}}function normalizeExperimentalDefinition(e){if(e===void 0)return;let t={};return e.workflow!==void 0&&(t.workflow={modelCallsPerStep:e.workflow.modelCallsPerStep,retention:e.workflow.retention,world:e.workflow.world}),t}async function normalizeAuthoredModelReference(e){if(typeof e.value==`string`)return await withCompiledRuntimeModelLimits({id:formatLanguageModelGatewayId(e.value),providerOptions:parseProviderOptionsRecord(e.providerOptions),routing:classifyModelRouting(e.value,e.providerOptions)},e);let t=e.source;if(t===void 0)throw Error(`Expected ${e.purpose} to provide a valid AI SDK language model reference.`);let n=e.value,r=n.specificationVersion;if(r!==`v2`&&r!==`v3`&&r!==`v4`||typeof n.provider!=`string`||typeof n.modelId!=`string`||typeof n.doGenerate!=`function`||typeof n.doStream!=`function`)throw Error(`Expected the authored agent config export "${t.exportName??`default`}" from "${e.sourcePath??t.logicalPath}" to provide a valid AI SDK language model.`);let i={id:formatLanguageModelGatewayId(n),source:{exportName:t.exportName,sourceKind:`module`,logicalPath:t.logicalPath,sourceId:t.sourceId},providerOptions:parseProviderOptionsRecord(e.providerOptions),routing:classifyModelRouting(n,e.providerOptions)};if(e.contextWindowTokens===void 0){if(isChatGptModelRouting(i.routing))return{...i,contextWindowTokens:2e5};try{let t=await e.modelCatalog.getByProviderModelId(n.provider,n.modelId);if(t)return{...i,id:t.slug,contextWindowTokens:t.limits.contextWindowTokens,maxOutputTokens:t.limits.maxOutputTokens}}catch{}}return await withCompiledRuntimeModelLimits(i,e)}function formatAgentConfigModulePath(e,t,n){return n.backing.kind===`programmatic`?t.logicalPath:normalizeLogicalPath(relative(resolveTopLevelAgentRoot(e),n.backing.sourcePath))}function resolveTopLevelAgentRoot(e){let t=resolve(e.appRoot),n=resolve(t,`agent`);return isPathInsideOrEqual(n,resolve(e.agentRoot))?n:t}function isPathInsideOrEqual(e,t){let n=relative(e,t);return n===``||!n.startsWith(`..`)&&!isAbsolute(n)}async function withCompiledRuntimeModelLimits(e,t){if(t.contextWindowTokens!==void 0)return{...e,contextWindowTokens:t.contextWindowTokens};let n;try{n=await t.modelCatalog.getModelLimits(e.id)}catch(n){throw Error(`Failed to load AI Gateway model metadata for ${t.purpose} "${e.id}". ${toErrorMessage(n)}`)}if(n===null)throw Error(`Cannot compile agent compaction because ${t.purpose} "${e.id}" does not have known AI Gateway context window metadata.`);return{...e,contextWindowTokens:n.contextWindowTokens,maxOutputTokens:n.maxOutputTokens}}function parseProviderOptionsRecord(e){if(e===void 0)return;let t={};for(let[n,r]of Object.entries(e))t[n]=parseJsonObject(r);return t}export{compileAgentConfig};
|
|
1
|
+
import{isAbsolute,relative,resolve}from"node:path";import{normalizeLogicalPath}from"#discover/filesystem.js";import{toErrorMessage}from"#shared/errors.js";import{parseJsonObject}from"#shared/json.js";import{isDynamicModelDefinition}from"#shared/agent-definition.js";import{createCompiledBindingNamespaceLoader}from"#compiler/load-binding-namespace.js";import{normalizeAgentDefinition}from"#internal/authored-definition/core.js";import{formatLanguageModelGatewayId}from"#internal/runtime-model.js";import{classifyModelRouting}from"#internal/classify-model-routing.js";import{isChatGptModelRouting}from"#shared/chatgpt-model.js";import{loadModuleBackedDefinition}from"#compiler/normalize-helpers.js";async function compileAgentConfig(e,t,n){let r=n.source,i=formatAgentConfigModulePath(e,r,n.binding),a=normalizeAgentDefinition(Object.hasOwn(n,`definition`)?n.definition:await loadModuleBackedDefinition({binding:n.binding,displayPath:i,kind:`agent config`,loadNamespace:createCompiledBindingNamespaceLoader({appRoot:e.appRoot,bindings:{[r.sourceId]:n.binding},registries:t.registries}),source:r}),`Expected the agent config export "${r.exportName??`default`}" from "${i}" to match the public eve shape.`),o=isDynamicModelDefinition(a.model)?a.model:void 0,s=o===void 0?await normalizeAuthoredModelReference({modelCatalog:t.modelCatalog,purpose:`the primary compaction trigger model`,contextWindowTokens:a.modelContextWindowTokens,providerOptions:a.modelOptions?.providerOptions,source:r,sourcePath:i,value:a.model}):void 0,c={},l={compaction:c,name:e.agentId,source:{...r}};a.defaultTools!==void 0&&(l.defaultTools=a.defaultTools),a.description!==void 0&&(l.description=a.description);let u;o!==void 0&&(u={eventNames:Object.keys(o.events),exportName:r.exportName,sourceKind:`module`,logicalPath:r.logicalPath,sourceId:r.sourceId});let d=normalizeExperimentalDefinition(a.experimental);if(d!==void 0&&(l.experimental=d),a.build!==void 0&&(l.build={externalDependencies:a.build.externalDependencies===void 0?void 0:[...a.build.externalDependencies]}),a.reasoning!==void 0&&(l.reasoning=a.reasoning),a.tool!==void 0&&(l.tool=a.tool),a.limits!==void 0&&(l.limits={maxInputTokensPerSession:a.limits.maxInputTokensPerSession,maxOutputTokensPerSession:a.limits.maxOutputTokensPerSession,maxTokenCostUsdPerSession:a.limits.maxTokenCostUsdPerSession,sessionTimeoutMs:a.limits.sessionTimeoutMs}),a.compaction?.model!==void 0&&(c.model=await normalizeAuthoredModelReference({modelCatalog:t.modelCatalog,purpose:`the compaction summary model`,contextWindowTokens:a.compaction.modelContextWindowTokens,providerOptions:a.modelOptions?.providerOptions,source:r,sourcePath:i,value:a.compaction.model})),a.compaction?.thresholdPercent!==void 0&&(c.thresholdPercent=a.compaction.thresholdPercent),u!==void 0)return{...l,dynamicModel:u};if(s===void 0)throw Error(`Expected a static agent model to compile to a concrete model reference.`);return{...l,model:s}}function normalizeExperimentalDefinition(e){if(e===void 0)return;let t={};return e.workflow!==void 0&&(t.workflow={modelCallsPerStep:e.workflow.modelCallsPerStep,retention:e.workflow.retention,world:e.workflow.world}),t}async function normalizeAuthoredModelReference(e){if(typeof e.value==`string`)return await withCompiledRuntimeModelLimits({id:formatLanguageModelGatewayId(e.value),providerOptions:parseProviderOptionsRecord(e.providerOptions),routing:classifyModelRouting(e.value,e.providerOptions)},e);let t=e.source;if(t===void 0)throw Error(`Expected ${e.purpose} to provide a valid AI SDK language model reference.`);let n=e.value,r=n.specificationVersion;if(r!==`v2`&&r!==`v3`&&r!==`v4`||typeof n.provider!=`string`||typeof n.modelId!=`string`||typeof n.doGenerate!=`function`||typeof n.doStream!=`function`)throw Error(`Expected the authored agent config export "${t.exportName??`default`}" from "${e.sourcePath??t.logicalPath}" to provide a valid AI SDK language model.`);let i={id:formatLanguageModelGatewayId(n),source:{exportName:t.exportName,sourceKind:`module`,logicalPath:t.logicalPath,sourceId:t.sourceId},providerOptions:parseProviderOptionsRecord(e.providerOptions),routing:classifyModelRouting(n,e.providerOptions)};if(e.contextWindowTokens===void 0){if(isChatGptModelRouting(i.routing))return{...i,contextWindowTokens:2e5};try{let t=await e.modelCatalog.getByProviderModelId(n.provider,n.modelId);if(t)return{...i,id:t.slug,contextWindowTokens:t.limits.contextWindowTokens,maxOutputTokens:t.limits.maxOutputTokens}}catch{}}return await withCompiledRuntimeModelLimits(i,e)}function formatAgentConfigModulePath(e,t,n){return n.backing.kind===`programmatic`?t.logicalPath:normalizeLogicalPath(relative(resolveTopLevelAgentRoot(e),n.backing.sourcePath))}function resolveTopLevelAgentRoot(e){let t=resolve(e.appRoot),n=resolve(t,`agent`);return isPathInsideOrEqual(n,resolve(e.agentRoot))?n:t}function isPathInsideOrEqual(e,t){let n=relative(e,t);return n===``||!n.startsWith(`..`)&&!isAbsolute(n)}async function withCompiledRuntimeModelLimits(e,t){if(t.contextWindowTokens!==void 0)return{...e,contextWindowTokens:t.contextWindowTokens};let n;try{n=await t.modelCatalog.getModelLimits(e.id)}catch(n){throw Error(`Failed to load AI Gateway model metadata for ${t.purpose} "${e.id}". ${toErrorMessage(n)}`)}if(n===null)throw Error(`Cannot compile agent compaction because ${t.purpose} "${e.id}" does not have known AI Gateway context window metadata.`);return{...e,contextWindowTokens:n.contextWindowTokens,maxOutputTokens:n.maxOutputTokens}}function parseProviderOptionsRecord(e){if(e===void 0)return;let t={};for(let[n,r]of Object.entries(e))t[n]=parseJsonObject(r);return t}export{compileAgentConfig};
|