@xopcai/xopc 0.0.231 → 0.0.233
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -0
- package/README.zh-CN.md +1 -0
- package/dist/browser-ext/manifest.json +1 -1
- package/dist/extensions/feishu/src/schema/config-schema.d.ts +3 -3
- package/dist/extensions/telegram/src/config-schema.d.ts +4 -4
- package/dist/extensions/telegram/xopc.extension.json +1 -1
- package/dist/extensions/weixin/src/config-schema.d.ts +3 -3
- package/dist/gateway/static/root/assets/{activity-store-M0nAY5XB.js → activity-store-DQ5L3PTi.js} +1 -1
- package/dist/gateway/static/root/assets/agent-avatar-dicebear-Bps8fvBp.js +1 -0
- package/dist/gateway/static/root/assets/agent-defaults-settings-panel-JrK80PvP.js +1 -0
- package/dist/gateway/static/root/assets/agents-CJYEnz94.js +1 -0
- package/dist/gateway/static/root/assets/api-DE6tZKG0.js +1 -0
- package/dist/gateway/static/root/assets/{app-management-settings-panel-DP7YVRPn.js → app-management-settings-panel-BryzDVod.js} +1 -1
- package/dist/gateway/static/root/assets/{appearance-settings-CVQ5n7y6.js → appearance-settings-BoweLBDm.js} +1 -1
- package/dist/gateway/static/root/assets/apps-page-Bt8_sWtU.js +1 -0
- package/dist/gateway/static/root/assets/{archive-plugin-7_DXaMTP.js → archive-plugin-DyujzZNu.js} +1 -1
- package/dist/gateway/static/root/assets/{attachment-load-mmr_mHRr.js → attachment-load-DmXGUWve.js} +1 -1
- package/dist/gateway/static/root/assets/attachment-preview-renderer-BDTD8YUe.js +12 -0
- package/dist/gateway/static/root/assets/{automations-page-DfY-T6Ga.js → automations-page-DrTVSK7o.js} +1 -1
- package/dist/gateway/static/root/assets/automations-workspace-86UTesz3.js +6 -0
- package/dist/gateway/static/root/assets/{binary-plugins-CO9QMEh2.js → binary-plugins-mFyeC74W.js} +2 -2
- package/dist/gateway/static/root/assets/{block-editor-CE14CVOy.js → block-editor-D5yMFrgH.js} +4 -4
- package/dist/gateway/static/root/assets/browser-settings-page-DfMU7yXv.js +8 -0
- package/dist/gateway/static/root/assets/browser-workflow-inputs-B6rLBtua.js +1 -0
- package/dist/gateway/static/root/assets/{browser-workflows-page-1wgXyoSO.js → browser-workflows-page-C74sg50f.js} +2 -2
- package/dist/gateway/static/root/assets/capabilities-settings-panel-lsHRuBlX.js +7 -0
- package/dist/gateway/static/root/assets/channels-settings-CxR_clkO.js +1 -0
- package/dist/gateway/static/root/assets/{channel-recipient-api-C5ABr73b.js → channels-status-swr-DowVNjNw.js} +1 -1
- package/dist/gateway/static/root/assets/{chat-terminal-dock-CdRW6Euc.js → chat-terminal-dock-BO6_BgjE.js} +2 -2
- package/dist/gateway/static/root/assets/{code-editor-dFzqyDXS.js → code-editor-D4_k-6QN.js} +1 -1
- package/dist/gateway/static/root/assets/connectors-page-CpNLyKB4.js +2 -0
- package/dist/gateway/static/root/assets/cron-expression-CYMXfk4M.js +2 -0
- package/dist/gateway/static/root/assets/date-picker-DIM_OkQP.js +1 -0
- package/dist/gateway/static/root/assets/dependency-picker-Cp8I6rsL.js +1 -0
- package/dist/gateway/static/root/assets/{desktop-pet-settings-MmOR4A3u.js → desktop-pet-settings-NjPiz3M_.js} +1 -1
- package/dist/gateway/static/root/assets/{desktop-pet-CMO-J3cG.js → desktop-pet-wzSzZ6S8.js} +1 -1
- package/dist/gateway/static/root/assets/dist-DqPZM2MH2.js +1 -0
- package/dist/gateway/static/root/assets/{extension-debug-page-DdH0dG2_.js → extension-debug-page-CoMl13ET.js} +1 -1
- package/dist/gateway/static/root/assets/{extension-page-Clg-KktN.js → extension-page-CXc1Lc8x.js} +1 -1
- package/dist/gateway/static/root/assets/extension-settings-page-CfEWpgjl.js +1 -0
- package/dist/gateway/static/root/assets/{gateway-config-api-DEHnF4Wm.js → gateway-config-api-yH4KAEkK.js} +1 -1
- package/dist/gateway/static/root/assets/gateway-config-swr-YyZJKvFf.js +1 -0
- package/dist/gateway/static/root/assets/{gateway-settings-DKkEXXj9.js → gateway-settings-BmjJIiKh.js} +1 -1
- package/dist/gateway/static/root/assets/{gateway-startup-retry-B_zrtccP.js → gateway-startup-retry-Dnrl91pU.js} +1 -1
- package/dist/gateway/static/root/assets/heartbeat-settings-DGq9q4b6.js +1 -0
- package/dist/gateway/static/root/assets/home-page-Dj4B1wb3.js +1 -0
- package/dist/gateway/static/root/assets/html-workspace-editor-C3DKAkMc.js +1 -0
- package/dist/gateway/static/root/assets/{image-generation-api-YKP2me5Z.js → image-generation-api-BNzAAw4Y.js} +1 -1
- package/dist/gateway/static/root/assets/index-BGf-TiZj.js +70 -0
- package/dist/gateway/static/root/assets/index-BTUuTnc9.css +2 -0
- package/dist/gateway/static/root/assets/{keyboard-shortcuts-settings-BvpEeHnm.js → keyboard-shortcuts-settings-CfNV1ysF.js} +1 -1
- package/dist/gateway/static/root/assets/local-app-workbench-page-IJg75WaN.js +2 -0
- package/dist/gateway/static/root/assets/{local-apps-page-Bzvn99eH.js → local-apps-page-MPd4Fl_l.js} +1 -1
- package/dist/gateway/static/root/assets/locale-store-D_dq_0LV.js +1 -0
- package/dist/gateway/static/root/assets/logs-page-NsfoazgK.js +2 -0
- package/dist/gateway/static/root/assets/management-settings-DeIjN4e0.js +1 -0
- package/dist/gateway/static/root/assets/markdown-editor-nDLmA_LF.js +2 -0
- package/dist/gateway/static/root/assets/markdown-split-BUAVv6Gu.js +1 -0
- package/dist/gateway/static/root/assets/markdown-view-CPkBOY3h.js +201 -0
- package/dist/gateway/static/root/assets/{media-plugins-D8I7OGnT.js → media-plugins-DFsVnOY-.js} +1 -1
- package/dist/gateway/static/root/assets/messages-D4qOHT4D.js +3 -0
- package/dist/gateway/static/root/assets/mobile-device-api-D9JevyCE.js +1 -0
- package/dist/gateway/static/root/assets/models-hub-cache-C5y2gzMU.js +1 -0
- package/dist/gateway/static/root/assets/{notes-api-EpgG-OQc.js → notes-api-BWSfTP1w.js} +1 -1
- package/dist/gateway/static/root/assets/{notes-page-CCvjGMhN.js → notes-page-CV8UJj7g.js} +1 -1
- package/dist/gateway/static/root/assets/notes-workbench-DrjMVgEI.js +4 -0
- package/dist/gateway/static/root/assets/{oauth-api-BwNLwbI8.js → oauth-api-DnanEBsf.js} +1 -1
- package/dist/gateway/static/root/assets/popover-select-3E24E65N.js +1 -0
- package/dist/gateway/static/root/assets/{product-open-page-MmMswmOU.js → product-open-page-zNg1KOy2.js} +1 -1
- package/dist/gateway/static/root/assets/project-detail-page-tfcGYL-O.js +1 -0
- package/dist/gateway/static/root/assets/projects-page-BkjnXLdJ.js +1 -0
- package/dist/gateway/static/root/assets/{registry-api-BFZrVYfy.js → registry-api-BeVzfRvs.js} +1 -1
- package/dist/gateway/static/root/assets/remote-access-hub-BXn-3n2d.js +1 -0
- package/dist/gateway/static/root/assets/{runtime-tools-settings-panel-Dx6o7sLu.js → runtime-tools-settings-panel-BxoioSvT.js} +2 -2
- package/dist/gateway/static/root/assets/{schema-form-Cdd9c4vt.js → schema-form-vzbmscrE.js} +1 -1
- package/dist/gateway/static/root/assets/sessions-page-MLNjrOkw.js +1 -0
- package/dist/gateway/static/root/assets/settings-advanced-gate-ByNLBY2q.js +1 -0
- package/dist/gateway/static/root/assets/{settings-form-section-D0YxMnhm.js → settings-form-section-x9k7MWD3.js} +1 -1
- package/dist/gateway/static/root/assets/settings-loading-skeleton-BLFOD9h9.js +1 -0
- package/dist/gateway/static/root/assets/settings-page-CwgTooar.js +1 -0
- package/dist/gateway/static/root/assets/settings-shell-layer-context-DCp6ykjQ.js +1 -0
- package/dist/gateway/static/root/assets/setup-status-panel-bnueBZg8.js +1 -0
- package/dist/gateway/static/root/assets/{share-preview-page-DiqBn-oE.js → share-preview-page-COTrPAd-.js} +1 -1
- package/dist/gateway/static/root/assets/shares-settings-D-v_psqL.js +1 -0
- package/dist/gateway/static/root/assets/skill-reload-api-DJICr4wh.js +1 -0
- package/dist/gateway/static/root/assets/{skills-page-CZwhWiRl.js → skills-page-D9wM6_Jn.js} +1 -1
- package/dist/gateway/static/root/assets/{skills-page.utils-kBGr8opZ.js → skills-page.utils-PtlQLM5a.js} +1 -1
- package/dist/gateway/static/root/assets/{system-settings-panel-CPBs6lWi.js → system-settings-panel-BR74mNEK.js} +1 -1
- package/dist/gateway/static/root/assets/task-detail-page-B-rmeE8t.js +1 -0
- package/dist/gateway/static/root/assets/{theme-store-Qgvo0Ga7.js → theme-store-Bud54q9e.js} +1 -1
- package/dist/gateway/static/root/assets/{use-autosave-C4YcEiP9.js → use-autosave-DH47MH7s.js} +1 -1
- package/dist/gateway/static/root/assets/user-context-page-B6eyxxOT.js +1 -0
- package/dist/gateway/static/root/assets/{vendor-codemirror-DRr7hFaD.js → vendor-codemirror--gTq3YAI.js} +16 -16
- package/dist/gateway/static/root/assets/voice-api-key-field-B59GaqRa.js +1 -0
- package/dist/gateway/static/root/assets/voice-config-api-C0ahrZ0e.js +1 -0
- package/dist/gateway/static/root/assets/{work-discovery-overlay-CKIdPEen.js → work-discovery-overlay-DTn4RCcx.js} +1 -1
- package/dist/gateway/static/root/assets/{workflow-run-setup-panel-BK44Vm5W.js → workflow-run-setup-panel-yDFoEX06.js} +2 -2
- package/dist/gateway/static/root/assets/workflows-page-BOwSbfWm.js +5 -0
- package/dist/gateway/static/root/index.html +16 -16
- package/dist/package.js +1 -1
- package/dist/packages/endpoint-tools-protocol/src/index.js +162 -2
- package/dist/packages/gateway-contract/src/product-delivery.js +6 -2
- package/dist/packages/gateway-contract/src/turn-outcome.js +77 -1
- package/dist/src/agent/agent-manager.d.ts +1 -2
- package/dist/src/agent/agent-manager.js +29 -44
- package/dist/src/agent/background-review/run-background-review.js +10 -15
- package/dist/src/agent/capabilities/definitions.d.ts +1 -1
- package/dist/src/agent/capabilities/definitions.js +2 -1
- package/dist/src/agent/embedded/run-for-session.js +1 -1
- package/dist/src/agent/external-tools/endpoint-provider.js +5 -1
- package/dist/src/agent/external-tools/mcp-provider.js +3 -13
- package/dist/src/agent/image/generation/runtime.js +1 -1
- package/dist/src/agent/image/tool-model-config.js +13 -14
- package/dist/src/agent/mcp/bundle-mcp-policy.d.ts +0 -9
- package/dist/src/agent/mcp/bundle-mcp-policy.js +1 -13
- package/dist/src/agent/mcp/bundle-mcp-runtime.js +1 -1
- package/dist/src/agent/mcp/index.js +2 -2
- package/dist/src/agent/media-generation/runtime-shared.d.ts +1 -1
- package/dist/src/agent/media-generation/runtime-shared.js +1 -1
- package/dist/src/agent/memory/create-memory-manager.js +1 -1
- package/dist/src/agent/memory/manager.d.ts +1 -1
- package/dist/src/{agent-runtime/memory-runtime.d.ts → agent/memory/runtime.d.ts} +1 -1
- package/dist/src/{agent-runtime/memory-runtime.js → agent/memory/runtime.js} +2 -3
- package/dist/src/agent/orchestration/agent-orchestrator.d.ts +0 -3
- package/dist/src/agent/orchestration/agent-orchestrator.js +1 -3
- package/dist/src/agent/orchestration/run-agent-turn-with-timeout.js +2 -2
- package/dist/src/agent/prompt/sections/tooling.js +5 -0
- package/dist/src/agent/service.js +0 -1
- package/dist/src/agent/starter-agents.js +1 -8
- package/dist/src/agent/tools/create-share-tool.js +2 -1
- package/dist/src/agent/tools/exec-command.js +2 -1
- package/dist/src/agent/tools/executor.d.ts +1 -1
- package/dist/src/agent/tools/factory.js +2 -0
- package/dist/src/agent/tools/index.d.ts +1 -0
- package/dist/src/agent/tools/index.js +2 -1
- package/dist/src/agent/tools/publish-artifacts.d.ts +2 -0
- package/dist/src/agent/tools/publish-artifacts.js +82 -0
- package/dist/src/agent/tools/send-media.js +2 -1
- package/dist/src/agent/tools/workflow-tool.js +1 -5
- package/dist/src/agent-config/index.d.ts +2 -0
- package/dist/src/agent-config/index.js +11 -0
- package/dist/src/agent-config/resolver.d.ts +11 -0
- package/dist/src/agent-config/resolver.js +113 -0
- package/dist/src/agent-config/schema.d.ts +491 -0
- package/dist/src/agent-config/schema.js +172 -0
- package/dist/src/chat-commands/builtins/config.js +2 -2
- package/dist/src/chat-commands/builtins/review.js +1 -1
- package/dist/src/chat-commands/config-paths.js +1 -1
- package/dist/src/cli/command-catalog.js +4 -0
- package/dist/src/cli/command-loaders.js +1 -0
- package/dist/src/cli/command-manifest.js +4 -0
- package/dist/src/cli/commands/agents.js +2 -1
- package/dist/src/cli/commands/auth.js +1 -1
- package/dist/src/cli/commands/config.js +1 -1
- package/dist/src/cli/commands/doctor/checks/database-schema.js +1 -1
- package/dist/src/cli/commands/doctor/checks/provider-auth.js +12 -4
- package/dist/src/cli/commands/image.js +3 -4
- package/dist/src/cli/commands/models.js +9 -3
- package/dist/src/cli/commands/onboard/model.js +13 -12
- package/dist/src/cli/commands/onboard.js +1 -1
- package/dist/src/cli/commands/providers.js +1 -1
- package/dist/src/cli/commands/support.d.ts +1 -0
- package/dist/src/cli/commands/support.js +51 -0
- package/dist/src/cli/commands/tunnel.js +3 -18
- package/dist/src/cli/utils/init-workspace-core.d.ts +1 -1
- package/dist/src/cli/utils/init-workspace-core.js +1 -1
- package/dist/src/commands/agents.config.d.ts +1 -3
- package/dist/src/commands/agents.config.js +9 -26
- package/dist/src/config/agent-model-intents.d.ts +10 -0
- package/dist/src/config/agent-model-intents.js +39 -0
- package/dist/src/config/agent-profile.d.ts +7 -9
- package/dist/src/config/agent-profile.js +30 -28
- package/dist/src/config/default-model.d.ts +1 -11
- package/dist/src/config/default-model.js +3 -11
- package/dist/src/config/index.js +3 -3
- package/dist/src/config/integration.d.ts +1 -1
- package/dist/src/config/reload.js +1 -1
- package/dist/src/config/rules.js +3 -3
- package/dist/src/config/schema.d.ts +187 -452
- package/dist/src/config/schema.js +53 -131
- package/dist/src/endpoint-tools/binding-service.d.ts +22 -0
- package/dist/src/endpoint-tools/binding-service.js +45 -0
- package/dist/src/endpoint-tools/index.d.ts +1 -0
- package/dist/src/endpoint-tools/index.js +2 -1
- package/dist/src/endpoint-tools/invocation-service.d.ts +1 -0
- package/dist/src/endpoint-tools/invocation-service.js +8 -0
- package/dist/src/endpoint-tools/policy.d.ts +4 -1
- package/dist/src/endpoint-tools/policy.js +68 -5
- package/dist/src/endpoint-tools/registry.js +1 -1
- package/dist/src/endpoint-tools/runtime.d.ts +2 -0
- package/dist/src/endpoint-tools/runtime.js +8 -0
- package/dist/src/extensions/activation-context.js +7 -11
- package/dist/src/files/file-service.js +14 -5
- package/dist/src/gateway/agent-builtin-tools.d.ts +250 -6
- package/dist/src/gateway/agent-builtin-tools.js +284 -46
- package/dist/src/gateway/agents-admin.d.ts +20 -62
- package/dist/src/gateway/agents-admin.js +36 -228
- package/dist/src/gateway/chat-stream/turn-outcome-collector.js +41 -6
- package/dist/src/gateway/device-routes.d.ts +3 -0
- package/dist/src/gateway/device-routes.js +47 -0
- package/dist/src/gateway/global-defaults-admin.d.ts +6 -20
- package/dist/src/gateway/global-defaults-admin.js +20 -120
- package/dist/src/gateway/heartbeat/service.js +1 -1
- package/dist/src/gateway/hono/app.js +4 -2
- package/dist/src/gateway/hono/lib/config-payload.d.ts +54 -137
- package/dist/src/gateway/hono/lib/config-payload.js +2 -4
- package/dist/src/gateway/hono/middleware/auth.js +36 -3
- package/dist/src/gateway/hono/middleware/scopes.d.ts +2 -12
- package/dist/src/gateway/hono/middleware/scopes.js +9 -18
- package/dist/src/gateway/hono/routes/agents.js +64 -100
- package/dist/src/gateway/hono/routes/connectors.js +1 -1
- package/dist/src/gateway/hono/routes/device-push.d.ts +2 -0
- package/dist/src/gateway/hono/routes/{mobile.js → device-push.js} +40 -18
- package/dist/src/gateway/hono/routes/devices.d.ts +4 -0
- package/dist/src/gateway/hono/routes/devices.js +214 -0
- package/dist/src/gateway/hono/routes/endpoint-tools.js +68 -1
- package/dist/src/gateway/hono/routes/files.js +12 -1
- package/dist/src/gateway/hono/routes/global-defaults.js +5 -9
- package/dist/src/gateway/hono/routes/index.js +4 -2
- package/dist/src/gateway/hono/routes/lazy-bundles.js +12 -20
- package/dist/src/gateway/hono/routes/media.js +46 -2
- package/dist/src/gateway/hono/routes/models.js +2 -2
- package/dist/src/gateway/hono/routes/realtime.js +8 -1
- package/dist/src/gateway/hono/routes/status.js +9 -16
- package/dist/src/gateway/hono/routes/support.d.ts +3 -0
- package/dist/src/gateway/hono/routes/support.js +28 -0
- package/dist/src/gateway/hono/routes/tunnel.d.ts +0 -2
- package/dist/src/gateway/hono/routes/tunnel.js +10 -199
- package/dist/src/gateway/hono/routes/you.js +24 -0
- package/dist/src/gateway/image-generation-setup.d.ts +2 -2
- package/dist/src/gateway/image-generation-setup.js +8 -7
- package/dist/src/gateway/public-url.d.ts +1 -1
- package/dist/src/gateway/security/gateway-principal.d.ts +11 -0
- package/dist/src/gateway/security/gateway-principal.js +12 -0
- package/dist/src/gateway/security/gateway-scopes.d.ts +7 -0
- package/dist/src/gateway/security/gateway-scopes.js +66 -0
- package/dist/src/gateway/security/index.d.ts +2 -1
- package/dist/src/gateway/security/index.js +3 -2
- package/dist/src/gateway/service.js +7 -7
- package/dist/src/gateway/xopc-cloud-capability-setup.js +19 -21
- package/dist/src/heartbeat/index.js +1 -1
- package/dist/src/media/store.js +9 -0
- package/dist/src/migrations/index.d.ts +0 -1
- package/dist/src/migrations/index.js +1 -2
- package/dist/src/migrations/runner.js +1 -2
- package/dist/src/notifications/device-store.d.ts +1 -1
- package/dist/src/notifications/device-store.js +11 -11
- package/dist/src/notifications/store.js +3 -3
- package/dist/src/providers/index.js +1 -1
- package/dist/src/providers/model-reference-auditor.js +14 -9
- package/dist/src/realtime/runtime.d.ts +2 -0
- package/dist/src/realtime/runtime.js +27 -3
- package/dist/src/realtime/tickets.d.ts +6 -1
- package/dist/src/realtime/tickets.js +2 -1
- package/dist/src/remote-access/exposure-manager.js +3 -3
- package/dist/src/share/share-url.js +2 -2
- package/dist/src/storage/sqlite/device-access-repository.d.ts +54 -0
- package/dist/src/storage/sqlite/device-access-repository.js +194 -0
- package/dist/src/storage/sqlite/device-pairing-repository.d.ts +22 -0
- package/dist/src/storage/sqlite/device-pairing-repository.js +86 -0
- package/dist/src/storage/sqlite/endpoint-session-binding-repository.d.ts +8 -0
- package/dist/src/storage/sqlite/endpoint-session-binding-repository.js +32 -0
- package/dist/src/storage/sqlite/gateway-identity-repository.d.ts +10 -0
- package/dist/src/storage/sqlite/gateway-identity-repository.js +50 -0
- package/dist/src/storage/sqlite/index.d.ts +4 -0
- package/dist/src/storage/sqlite/index.js +5 -1
- package/dist/src/storage/sqlite/migrations/138_device_access.sql +96 -0
- package/dist/src/storage/sqlite/migrations/139_turn_outcome_artifact_backfill.sql +231 -0
- package/dist/src/storage/sqlite/migrations/140_endpoint_session_bindings.sql +8 -0
- package/dist/src/storage/sqlite/migrations/runner.d.ts +1 -1
- package/dist/src/storage/sqlite/migrations/runner.js +3 -3
- package/dist/src/storage/sqlite/migrations/runner.ts +1 -1
- package/dist/src/storage/sqlite/schema.js +1 -1
- package/dist/src/support/build-support-investigation-prompt.d.ts +2 -0
- package/dist/src/support/build-support-investigation-prompt.js +29 -0
- package/dist/src/support/collect-support-report.d.ts +16 -0
- package/dist/src/support/collect-support-report.js +216 -0
- package/dist/src/support/redact-support-report.d.ts +16 -0
- package/dist/src/support/redact-support-report.js +89 -0
- package/dist/src/support/types.d.ts +76 -0
- package/dist/src/support/types.js +18 -0
- package/dist/src/tunnel/consent.d.ts +1 -1
- package/dist/src/tunnel/consent.js +1 -1
- package/dist/src/tunnel/gateway-lifecycle.js +1 -1
- package/dist/src/tunnel/index.d.ts +1 -4
- package/dist/src/tunnel/index.js +3 -5
- package/dist/src/tunnel/tunnel-audit.d.ts +1 -1
- package/dist/src/tunnel/tunnel-config.js +1 -1
- package/dist/src/tunnel/tunnel-service.d.ts +2 -3
- package/dist/src/tunnel/tunnel-service.js +1 -20
- package/dist/src/tunnel/tunnel-types.d.ts +0 -6
- package/dist/src/user-context/user-avatar.d.ts +17 -0
- package/dist/src/user-context/user-avatar.js +116 -0
- package/dist/src/workflows/draft/workflow-draft-service.js +2 -2
- package/dist/src/workflows/service/workflow-run-service.js +3 -3
- package/package.json +4 -4
- package/dist/gateway/static/root/assets/agent-avatar-dicebear-CBqUnlvL.js +0 -1
- package/dist/gateway/static/root/assets/agents-7YO6znTT.js +0 -68
- package/dist/gateway/static/root/assets/api-BywYxpaS.js +0 -1
- package/dist/gateway/static/root/assets/apps-page-DSCia0DT.js +0 -1
- package/dist/gateway/static/root/assets/attachment-preview-renderer-Cmo-5BP5.js +0 -11
- package/dist/gateway/static/root/assets/automations-workspace-BpvD54D6.js +0 -6
- package/dist/gateway/static/root/assets/browser-settings-page-CeESA4Oj.js +0 -8
- package/dist/gateway/static/root/assets/browser-workflow-inputs-8NC2qDRF.js +0 -1
- package/dist/gateway/static/root/assets/capabilities-settings-panel-B_OXTojB.js +0 -7
- package/dist/gateway/static/root/assets/capability-presets-api-o0y9WgAI.js +0 -1
- package/dist/gateway/static/root/assets/capability-presets-settings-panel-D5nZecxV.js +0 -3
- package/dist/gateway/static/root/assets/channels-settings-BzmnWx6X.js +0 -1
- package/dist/gateway/static/root/assets/channels-status-swr-38FsOnR0.js +0 -1
- package/dist/gateway/static/root/assets/connectors-page-DX6OkwFQ.js +0 -2
- package/dist/gateway/static/root/assets/cron-expression-DYSMZsms.js +0 -2
- package/dist/gateway/static/root/assets/date-picker-DGCfX4tK.js +0 -1
- package/dist/gateway/static/root/assets/dependency-picker-DHDa4ht1.js +0 -1
- package/dist/gateway/static/root/assets/directory-picker-path-field-B9qoxDcn.js +0 -1
- package/dist/gateway/static/root/assets/dist-J_ySZvz0.js +0 -1
- package/dist/gateway/static/root/assets/extension-settings-page-eP3fJ2M6.js +0 -1
- package/dist/gateway/static/root/assets/file-code-corner-byQA1VfD.js +0 -1
- package/dist/gateway/static/root/assets/gateway-config-swr-BWGjnmDl.js +0 -1
- package/dist/gateway/static/root/assets/heartbeat-settings-DlBPNubY.js +0 -1
- package/dist/gateway/static/root/assets/home-page-BnOrLRfs.js +0 -1
- package/dist/gateway/static/root/assets/html-workspace-editor-bXK5tq64.js +0 -1
- package/dist/gateway/static/root/assets/index-0xQO5B_Q.js +0 -70
- package/dist/gateway/static/root/assets/index-CCyIdGuQ.css +0 -2
- package/dist/gateway/static/root/assets/local-app-workbench-page-Ch1rdUo8.js +0 -2
- package/dist/gateway/static/root/assets/locale-store-CXhjfe4q.js +0 -1
- package/dist/gateway/static/root/assets/logs-page-zxx2ExlY.js +0 -2
- package/dist/gateway/static/root/assets/management-settings-BQaeyOYm.js +0 -1
- package/dist/gateway/static/root/assets/markdown-editor-TWGaF7Xa.js +0 -2
- package/dist/gateway/static/root/assets/markdown-split-D9tmIiEm.js +0 -1
- package/dist/gateway/static/root/assets/markdown-view-RxNHwlNo.js +0 -201
- package/dist/gateway/static/root/assets/messages-BMdD0LWk.js +0 -3
- package/dist/gateway/static/root/assets/models-hub-cache-0RjEwafI.js +0 -1
- package/dist/gateway/static/root/assets/notes-workbench-9cgh77VH.js +0 -4
- package/dist/gateway/static/root/assets/popover-select-CccGri5Y.js +0 -1
- package/dist/gateway/static/root/assets/project-detail-page-hf6pmH4p.js +0 -1
- package/dist/gateway/static/root/assets/projects-page-By2U-Wdh.js +0 -1
- package/dist/gateway/static/root/assets/remote-access-hub-CUcpp7CQ.js +0 -1
- package/dist/gateway/static/root/assets/sessions-page-ByI82xS1.js +0 -1
- package/dist/gateway/static/root/assets/settings-advanced-gate-BCoI5IJ8.js +0 -1
- package/dist/gateway/static/root/assets/settings-loading-skeleton-y53gEKsF.js +0 -1
- package/dist/gateway/static/root/assets/settings-page-BoE_tToG.js +0 -1
- package/dist/gateway/static/root/assets/setup-status-panel-BQmyb5KC.js +0 -1
- package/dist/gateway/static/root/assets/shares-settings-Bf3VpZ-R.js +0 -1
- package/dist/gateway/static/root/assets/skill-reload-api-CXHlbuGS.js +0 -1
- package/dist/gateway/static/root/assets/task-detail-page-Bo0KSZ2v.js +0 -1
- package/dist/gateway/static/root/assets/typed-models-lib-q5-Vfqd8.js +0 -1
- package/dist/gateway/static/root/assets/user-context-page-Cnj7gMX2.js +0 -1
- package/dist/gateway/static/root/assets/voice-api-key-field-BML8zCwZ.js +0 -1
- package/dist/gateway/static/root/assets/workflows-page-CB98MTwG.js +0 -5
- package/dist/src/agent-manifest/index.d.ts +0 -5
- package/dist/src/agent-manifest/index.js +0 -10
- package/dist/src/agent-manifest/preset-chain.d.ts +0 -10
- package/dist/src/agent-manifest/preset-chain.js +0 -30
- package/dist/src/agent-manifest/prompt.d.ts +0 -2
- package/dist/src/agent-manifest/prompt.js +0 -49
- package/dist/src/agent-manifest/resolver.d.ts +0 -32
- package/dist/src/agent-manifest/resolver.js +0 -114
- package/dist/src/agent-manifest/schema.d.ts +0 -695
- package/dist/src/agent-manifest/schema.js +0 -226
- package/dist/src/agent-manifest/validator.d.ts +0 -25
- package/dist/src/agent-manifest/validator.js +0 -74
- package/dist/src/agent-runtime/boundary-guard.d.ts +0 -12
- package/dist/src/agent-runtime/boundary-guard.js +0 -21
- package/dist/src/agent-runtime/index.d.ts +0 -7
- package/dist/src/agent-runtime/index.js +0 -8
- package/dist/src/agent-runtime/model-router.d.ts +0 -11
- package/dist/src/agent-runtime/model-router.js +0 -14
- package/dist/src/agent-runtime/run-trace.d.ts +0 -27
- package/dist/src/agent-runtime/run-trace.js +0 -51
- package/dist/src/agent-runtime/runtime-profile.d.ts +0 -26
- package/dist/src/agent-runtime/runtime-profile.js +0 -42
- package/dist/src/agent-runtime/tool-registry.d.ts +0 -28
- package/dist/src/agent-runtime/tool-registry.js +0 -50
- package/dist/src/agent-runtime/workflow-runtime.d.ts +0 -31
- package/dist/src/agent-runtime/workflow-runtime.js +0 -32
- package/dist/src/config/agent-typed-models.d.ts +0 -13
- package/dist/src/config/agent-typed-models.js +0 -48
- package/dist/src/gateway/capability-presets-admin.d.ts +0 -88
- package/dist/src/gateway/capability-presets-admin.js +0 -303
- package/dist/src/gateway/hono/lib/agent-model.d.ts +0 -35
- package/dist/src/gateway/hono/lib/agent-model.js +0 -97
- package/dist/src/gateway/hono/routes/capability-presets.d.ts +0 -3
- package/dist/src/gateway/hono/routes/capability-presets.js +0 -187
- package/dist/src/gateway/hono/routes/mobile.d.ts +0 -3
- package/dist/src/gateway/security/operator-scopes.d.ts +0 -37
- package/dist/src/gateway/security/operator-scopes.js +0 -147
- package/dist/src/migrations/config/default-capability-preset.d.ts +0 -10
- package/dist/src/migrations/config/default-capability-preset.js +0 -133
- package/dist/src/tunnel/enable-lan-pairing.d.ts +0 -8
- package/dist/src/tunnel/enable-lan-pairing.js +0 -41
- package/dist/src/tunnel/pair-context.d.ts +0 -36
- package/dist/src/tunnel/pair-context.js +0 -77
- package/dist/src/tunnel/pair-url.d.ts +0 -43
- package/dist/src/tunnel/pair-url.js +0 -117
- package/dist/src/tunnel/pairing-rate-limit.d.ts +0 -12
- package/dist/src/tunnel/pairing-rate-limit.js +0 -28
- package/dist/src/tunnel/pairing.d.ts +0 -21
- package/dist/src/tunnel/pairing.js +0 -103
- package/dist/src/tunnel/tunnel-qr.d.ts +0 -9
- package/dist/src/tunnel/tunnel-qr.js +0 -29
|
@@ -1,226 +0,0 @@
|
|
|
1
|
-
import { __esmMin } from "../../_virtual/_rolldown/runtime.js";
|
|
2
|
-
import { z } from "zod";
|
|
3
|
-
//#region src/agent-manifest/schema.ts
|
|
4
|
-
var IdSchema, LockPathSchema, DEFAULT_CAPABILITY_PRESET_ID, ManifestModelRoleSchema, AgentToolModelSchema, ModelPolicySchema, ModelPolicyPatchSchema, ToolModeSchema, ToolScopeSchema, ToolPolicySchema, ToolPolicySetSchema, ToolPolicySetPatchSchema, SkillPolicySchema, SkillPolicyPatchSchema, WorkflowPolicySchema, WorkflowPolicyPatchSchema, BoundaryPolicySchema, BoundaryPolicyPatchSchema, WorkspacePolicySchema, RuntimePolicySchema, PromptPolicySchema, AgentIdentitySchema, AgentResponsibilitiesSchema, AgentManifestSchema, AgentConfigEntrySchema, CapabilityPresetSchema;
|
|
5
|
-
var init_schema = __esmMin((() => {
|
|
6
|
-
IdSchema = z.string().regex(/^[a-z][a-z0-9_-]{0,63}$/);
|
|
7
|
-
LockPathSchema = z.string().regex(/^(models|tools|skills|workflows|boundaries|runtime)(?:\.[^.\s]+)*$/, "lock path must target a capability policy field");
|
|
8
|
-
DEFAULT_CAPABILITY_PRESET_ID = "default";
|
|
9
|
-
ManifestModelRoleSchema = z.object({
|
|
10
|
-
model: z.string().min(1),
|
|
11
|
-
fallbacks: z.array(z.string().min(1)).optional(),
|
|
12
|
-
description: z.string().max(500).optional()
|
|
13
|
-
}).strict().superRefine((entry, ctx) => {
|
|
14
|
-
const validateRef = (ref) => {
|
|
15
|
-
const trimmed = ref.trim();
|
|
16
|
-
const idx = trimmed.indexOf("/");
|
|
17
|
-
return idx > 0 && idx < trimmed.length - 1;
|
|
18
|
-
};
|
|
19
|
-
if (!validateRef(entry.model)) ctx.addIssue({
|
|
20
|
-
code: "custom",
|
|
21
|
-
message: `model must be provider/model format (got '${entry.model}')`,
|
|
22
|
-
path: ["model"]
|
|
23
|
-
});
|
|
24
|
-
for (const [index, fallback] of (entry.fallbacks ?? []).entries()) if (!validateRef(fallback)) ctx.addIssue({
|
|
25
|
-
code: "custom",
|
|
26
|
-
message: `fallback must be provider/model format (got '${fallback}')`,
|
|
27
|
-
path: ["fallbacks", index]
|
|
28
|
-
});
|
|
29
|
-
});
|
|
30
|
-
AgentToolModelSchema = z.object({
|
|
31
|
-
primary: z.string().min(1),
|
|
32
|
-
fallbacks: z.array(z.string().min(1)).optional(),
|
|
33
|
-
timeoutMs: z.number().int().positive().optional(),
|
|
34
|
-
autoProviderFallback: z.boolean().optional()
|
|
35
|
-
}).strict().superRefine((entry, ctx) => {
|
|
36
|
-
const validateRef = (ref) => {
|
|
37
|
-
const trimmed = ref.trim();
|
|
38
|
-
const idx = trimmed.indexOf("/");
|
|
39
|
-
return idx > 0 && idx < trimmed.length - 1;
|
|
40
|
-
};
|
|
41
|
-
if (!validateRef(entry.primary)) ctx.addIssue({
|
|
42
|
-
code: "custom",
|
|
43
|
-
message: `primary must be provider/model format (got '${entry.primary}')`,
|
|
44
|
-
path: ["primary"]
|
|
45
|
-
});
|
|
46
|
-
for (const [index, fallback] of (entry.fallbacks ?? []).entries()) if (!validateRef(fallback)) ctx.addIssue({
|
|
47
|
-
code: "custom",
|
|
48
|
-
message: `fallback must be provider/model format (got '${fallback}')`,
|
|
49
|
-
path: ["fallbacks", index]
|
|
50
|
-
});
|
|
51
|
-
});
|
|
52
|
-
ModelPolicySchema = z.object({
|
|
53
|
-
defaultRole: IdSchema,
|
|
54
|
-
roles: z.record(IdSchema, ManifestModelRoleSchema).default({}),
|
|
55
|
-
imageModel: AgentToolModelSchema.optional(),
|
|
56
|
-
imageGenerationModel: AgentToolModelSchema.optional(),
|
|
57
|
-
policy: z.object({
|
|
58
|
-
allowFallbacks: z.boolean().optional(),
|
|
59
|
-
maxCostTier: z.enum([
|
|
60
|
-
"low",
|
|
61
|
-
"medium",
|
|
62
|
-
"high"
|
|
63
|
-
]).optional()
|
|
64
|
-
}).strict().optional()
|
|
65
|
-
}).strict();
|
|
66
|
-
ModelPolicyPatchSchema = z.object({
|
|
67
|
-
defaultRole: IdSchema.optional(),
|
|
68
|
-
roles: z.record(IdSchema, ManifestModelRoleSchema).optional(),
|
|
69
|
-
imageModel: AgentToolModelSchema.optional(),
|
|
70
|
-
imageGenerationModel: AgentToolModelSchema.optional(),
|
|
71
|
-
policy: z.object({
|
|
72
|
-
allowFallbacks: z.boolean().optional(),
|
|
73
|
-
maxCostTier: z.enum([
|
|
74
|
-
"low",
|
|
75
|
-
"medium",
|
|
76
|
-
"high"
|
|
77
|
-
]).optional()
|
|
78
|
-
}).strict().optional()
|
|
79
|
-
}).strict();
|
|
80
|
-
ToolModeSchema = z.enum([
|
|
81
|
-
"allow",
|
|
82
|
-
"confirm",
|
|
83
|
-
"deny"
|
|
84
|
-
]);
|
|
85
|
-
ToolScopeSchema = z.enum([
|
|
86
|
-
"readonly",
|
|
87
|
-
"workspace",
|
|
88
|
-
"unrestricted"
|
|
89
|
-
]);
|
|
90
|
-
ToolPolicySchema = z.object({
|
|
91
|
-
mode: ToolModeSchema,
|
|
92
|
-
scope: ToolScopeSchema.optional(),
|
|
93
|
-
limits: z.object({
|
|
94
|
-
maxCallsPerTurn: z.number().int().positive().optional(),
|
|
95
|
-
timeoutMs: z.number().int().positive().optional()
|
|
96
|
-
}).strict().optional()
|
|
97
|
-
}).strict();
|
|
98
|
-
ToolPolicySetSchema = z.object({
|
|
99
|
-
builtin: z.record(z.string().min(1), ToolPolicySchema).default({}),
|
|
100
|
-
mcp: z.object({
|
|
101
|
-
servers: z.record(z.string().min(1), ToolPolicySchema).optional(),
|
|
102
|
-
tools: z.record(z.string().min(1), ToolPolicySchema).optional()
|
|
103
|
-
}).strict().optional()
|
|
104
|
-
}).strict().default({ builtin: {} });
|
|
105
|
-
ToolPolicySetPatchSchema = z.object({
|
|
106
|
-
builtin: z.record(z.string().min(1), ToolPolicySchema).optional(),
|
|
107
|
-
mcp: z.object({
|
|
108
|
-
servers: z.record(z.string().min(1), ToolPolicySchema).optional(),
|
|
109
|
-
tools: z.record(z.string().min(1), ToolPolicySchema).optional()
|
|
110
|
-
}).strict().optional()
|
|
111
|
-
}).strict();
|
|
112
|
-
SkillPolicySchema = z.object({
|
|
113
|
-
mode: z.enum([
|
|
114
|
-
"all",
|
|
115
|
-
"allowlist",
|
|
116
|
-
"denylist",
|
|
117
|
-
"off"
|
|
118
|
-
]).default("all"),
|
|
119
|
-
allow: z.array(z.string().min(1)).optional(),
|
|
120
|
-
deny: z.array(z.string().min(1)).optional()
|
|
121
|
-
}).strict().default({ mode: "all" });
|
|
122
|
-
SkillPolicyPatchSchema = z.object({
|
|
123
|
-
mode: z.enum([
|
|
124
|
-
"all",
|
|
125
|
-
"allowlist",
|
|
126
|
-
"denylist",
|
|
127
|
-
"off"
|
|
128
|
-
]),
|
|
129
|
-
allow: z.array(z.string().min(1)).optional(),
|
|
130
|
-
deny: z.array(z.string().min(1)).optional()
|
|
131
|
-
}).strict();
|
|
132
|
-
WorkflowPolicySchema = z.object({
|
|
133
|
-
default: z.string().min(1).optional(),
|
|
134
|
-
allowed: z.array(z.string().min(1)).optional(),
|
|
135
|
-
suggested: z.array(z.object({
|
|
136
|
-
intent: z.string().min(1),
|
|
137
|
-
workflow: z.string().min(1)
|
|
138
|
-
}).strict()).optional()
|
|
139
|
-
}).strict().default({});
|
|
140
|
-
WorkflowPolicyPatchSchema = WorkflowPolicySchema.removeDefault();
|
|
141
|
-
BoundaryPolicySchema = z.object({
|
|
142
|
-
requiresConfirmation: z.array(z.string().min(1)).default([]),
|
|
143
|
-
forbidden: z.array(z.string().min(1)).default([]),
|
|
144
|
-
escalation: z.array(z.string().min(1)).default([])
|
|
145
|
-
}).strict().default({
|
|
146
|
-
requiresConfirmation: [],
|
|
147
|
-
forbidden: [],
|
|
148
|
-
escalation: []
|
|
149
|
-
});
|
|
150
|
-
BoundaryPolicyPatchSchema = z.object({
|
|
151
|
-
requiresConfirmation: z.array(z.string().min(1)).optional(),
|
|
152
|
-
forbidden: z.array(z.string().min(1)).optional(),
|
|
153
|
-
escalation: z.array(z.string().min(1)).optional()
|
|
154
|
-
}).strict();
|
|
155
|
-
WorkspacePolicySchema = z.object({ root: z.string().min(1) }).strict();
|
|
156
|
-
RuntimePolicySchema = z.object({
|
|
157
|
-
maxTurns: z.number().int().positive().optional(),
|
|
158
|
-
timeoutMs: z.number().int().positive().optional(),
|
|
159
|
-
maxToolFailuresPerTurn: z.number().int().positive().optional(),
|
|
160
|
-
promptCache: z.object({
|
|
161
|
-
mode: z.enum(["off", "auto"]).default("auto"),
|
|
162
|
-
lifetime: z.enum(["short", "long"]).default("short")
|
|
163
|
-
}).strict().optional()
|
|
164
|
-
}).strict().optional();
|
|
165
|
-
PromptPolicySchema = z.object({ customInstructions: z.string().optional() }).strict().optional();
|
|
166
|
-
AgentIdentitySchema = z.object({
|
|
167
|
-
name: z.string().min(1),
|
|
168
|
-
description: z.string().optional(),
|
|
169
|
-
role: z.string().min(1),
|
|
170
|
-
language: z.string().min(1).default("en"),
|
|
171
|
-
tone: z.string().min(1).default("direct"),
|
|
172
|
-
avatar: z.string().optional()
|
|
173
|
-
}).strict();
|
|
174
|
-
AgentResponsibilitiesSchema = z.object({
|
|
175
|
-
primary: z.array(z.string().min(1)).min(1),
|
|
176
|
-
secondary: z.array(z.string().min(1)).optional(),
|
|
177
|
-
outOfScope: z.array(z.string().min(1)).optional()
|
|
178
|
-
}).strict();
|
|
179
|
-
AgentManifestSchema = z.object({
|
|
180
|
-
id: IdSchema,
|
|
181
|
-
enabled: z.boolean().default(true),
|
|
182
|
-
extends: z.array(IdSchema).optional(),
|
|
183
|
-
identity: AgentIdentitySchema,
|
|
184
|
-
responsibilities: AgentResponsibilitiesSchema,
|
|
185
|
-
workspace: WorkspacePolicySchema,
|
|
186
|
-
models: ModelPolicySchema,
|
|
187
|
-
tools: ToolPolicySetSchema,
|
|
188
|
-
skills: SkillPolicySchema,
|
|
189
|
-
workflows: WorkflowPolicySchema,
|
|
190
|
-
boundaries: BoundaryPolicySchema,
|
|
191
|
-
runtime: RuntimePolicySchema,
|
|
192
|
-
prompt: PromptPolicySchema
|
|
193
|
-
}).strict();
|
|
194
|
-
AgentConfigEntrySchema = z.object({
|
|
195
|
-
id: IdSchema,
|
|
196
|
-
enabled: z.boolean().default(true),
|
|
197
|
-
extends: z.array(IdSchema).optional(),
|
|
198
|
-
identity: AgentIdentitySchema,
|
|
199
|
-
responsibilities: AgentResponsibilitiesSchema,
|
|
200
|
-
workspace: WorkspacePolicySchema,
|
|
201
|
-
models: ModelPolicyPatchSchema.optional(),
|
|
202
|
-
tools: ToolPolicySetPatchSchema.optional(),
|
|
203
|
-
skills: SkillPolicyPatchSchema.optional(),
|
|
204
|
-
workflows: WorkflowPolicyPatchSchema.optional(),
|
|
205
|
-
boundaries: BoundaryPolicyPatchSchema.optional(),
|
|
206
|
-
runtime: RuntimePolicySchema,
|
|
207
|
-
prompt: PromptPolicySchema
|
|
208
|
-
}).strict();
|
|
209
|
-
CapabilityPresetSchema = z.object({
|
|
210
|
-
id: IdSchema,
|
|
211
|
-
name: z.string().min(1),
|
|
212
|
-
description: z.string().optional(),
|
|
213
|
-
version: z.number().int().positive().default(1),
|
|
214
|
-
extends: z.array(IdSchema).optional(),
|
|
215
|
-
models: ModelPolicyPatchSchema.optional(),
|
|
216
|
-
tools: ToolPolicySetPatchSchema.optional(),
|
|
217
|
-
skills: SkillPolicyPatchSchema.optional(),
|
|
218
|
-
workflows: WorkflowPolicyPatchSchema.optional(),
|
|
219
|
-
boundaries: BoundaryPolicyPatchSchema.optional(),
|
|
220
|
-
runtime: RuntimePolicySchema,
|
|
221
|
-
locks: z.array(LockPathSchema).optional()
|
|
222
|
-
}).strict();
|
|
223
|
-
}));
|
|
224
|
-
//#endregion
|
|
225
|
-
init_schema();
|
|
226
|
-
export { AgentConfigEntrySchema, AgentIdentitySchema, AgentManifestSchema, AgentResponsibilitiesSchema, AgentToolModelSchema, BoundaryPolicyPatchSchema, BoundaryPolicySchema, CapabilityPresetSchema, DEFAULT_CAPABILITY_PRESET_ID, ManifestModelRoleSchema, ModelPolicyPatchSchema, ModelPolicySchema, PromptPolicySchema, RuntimePolicySchema, SkillPolicyPatchSchema, SkillPolicySchema, ToolModeSchema, ToolPolicySchema, ToolPolicySetPatchSchema, ToolPolicySetSchema, ToolScopeSchema, WorkflowPolicyPatchSchema, WorkflowPolicySchema, WorkspacePolicySchema, init_schema };
|
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
import type { AgentConfigEntry, CapabilityPreset, EffectiveAgentManifest } from './schema.js';
|
|
2
|
-
export type ManifestIssueSeverity = 'error' | 'warning';
|
|
3
|
-
export interface ManifestIssue {
|
|
4
|
-
severity: ManifestIssueSeverity;
|
|
5
|
-
path: string;
|
|
6
|
-
message: string;
|
|
7
|
-
}
|
|
8
|
-
export interface ManifestCatalogs {
|
|
9
|
-
tools?: Iterable<string>;
|
|
10
|
-
skills?: Iterable<string>;
|
|
11
|
-
workflows?: Iterable<string>;
|
|
12
|
-
mcpServers?: Iterable<string>;
|
|
13
|
-
}
|
|
14
|
-
export interface ValidateManifestParams {
|
|
15
|
-
agent: AgentConfigEntry;
|
|
16
|
-
presets?: Record<string, CapabilityPreset>;
|
|
17
|
-
defaultPresetId?: string;
|
|
18
|
-
catalogs?: ManifestCatalogs;
|
|
19
|
-
}
|
|
20
|
-
export interface ValidateManifestResult {
|
|
21
|
-
ok: boolean;
|
|
22
|
-
manifest?: EffectiveAgentManifest;
|
|
23
|
-
issues: ManifestIssue[];
|
|
24
|
-
}
|
|
25
|
-
export declare function validateAgentManifest(params: ValidateManifestParams): ValidateManifestResult;
|
|
@@ -1,74 +0,0 @@
|
|
|
1
|
-
import { resolveEffectiveAgentManifest } from "./resolver.js";
|
|
2
|
-
//#region src/agent-manifest/validator.ts
|
|
3
|
-
function toSet(values) {
|
|
4
|
-
if (!values) return void 0;
|
|
5
|
-
return new Set([...values].map((value) => value.toLowerCase()));
|
|
6
|
-
}
|
|
7
|
-
function hasValue(set, value) {
|
|
8
|
-
return set === void 0 || set.has(value.toLowerCase());
|
|
9
|
-
}
|
|
10
|
-
function addIssue(issues, severity, path, message) {
|
|
11
|
-
issues.push({
|
|
12
|
-
severity,
|
|
13
|
-
path,
|
|
14
|
-
message
|
|
15
|
-
});
|
|
16
|
-
}
|
|
17
|
-
function validateModels(manifest, issues) {
|
|
18
|
-
if (!manifest.models.roles[manifest.models.defaultRole]) addIssue(issues, "error", "models.defaultRole", `defaultRole "${manifest.models.defaultRole}" does not exist in models.roles`);
|
|
19
|
-
}
|
|
20
|
-
function validateTools(manifest, issues, catalogs) {
|
|
21
|
-
const tools = toSet(catalogs.tools);
|
|
22
|
-
for (const [name, policy] of Object.entries(manifest.tools.builtin)) {
|
|
23
|
-
if (!hasValue(tools, name)) addIssue(issues, "error", `tools.builtin.${name}`, `tool "${name}" is not in the tool catalog`);
|
|
24
|
-
if (policy.mode === "allow" && policy.scope === "unrestricted") addIssue(issues, "warning", `tools.builtin.${name}.scope`, `tool "${name}" is unrestricted; consider using confirm or a narrower scope`);
|
|
25
|
-
}
|
|
26
|
-
const mcpServers = toSet(catalogs.mcpServers);
|
|
27
|
-
for (const serverName of Object.keys(manifest.tools.mcp?.servers ?? {})) if (!hasValue(mcpServers, serverName)) addIssue(issues, "error", `tools.mcp.servers.${serverName}`, `MCP server "${serverName}" is not configured`);
|
|
28
|
-
}
|
|
29
|
-
function validateSkills(manifest, issues, catalogs) {
|
|
30
|
-
const skills = toSet(catalogs.skills);
|
|
31
|
-
for (const name of manifest.skills.allow ?? []) if (!hasValue(skills, name)) addIssue(issues, "error", `skills.allow`, `skill "${name}" is not installed`);
|
|
32
|
-
for (const name of manifest.skills.deny ?? []) if (!hasValue(skills, name)) addIssue(issues, "warning", `skills.deny`, `skill "${name}" is not installed`);
|
|
33
|
-
if (manifest.skills.mode === "allowlist" && (manifest.skills.allow?.length ?? 0) === 0) addIssue(issues, "warning", "skills.allow", "allowlist mode has no allowed skills");
|
|
34
|
-
}
|
|
35
|
-
function validateWorkflows(manifest, issues, catalogs) {
|
|
36
|
-
const workflows = toSet(catalogs.workflows);
|
|
37
|
-
const check = (path, value) => {
|
|
38
|
-
if (value && !hasValue(workflows, value)) addIssue(issues, "error", path, `workflow "${value}" is not in the workflow catalog`);
|
|
39
|
-
};
|
|
40
|
-
check("workflows.default", manifest.workflows.default);
|
|
41
|
-
for (const [index, value] of (manifest.workflows.allowed ?? []).entries()) check(`workflows.allowed.${index}`, value);
|
|
42
|
-
for (const [index, entry] of (manifest.workflows.suggested ?? []).entries()) check(`workflows.suggested.${index}.workflow`, entry.workflow);
|
|
43
|
-
}
|
|
44
|
-
function validateAgentManifest(params) {
|
|
45
|
-
const issues = [];
|
|
46
|
-
let manifest;
|
|
47
|
-
try {
|
|
48
|
-
manifest = resolveEffectiveAgentManifest({
|
|
49
|
-
agent: params.agent,
|
|
50
|
-
presets: params.presets,
|
|
51
|
-
defaultPresetId: params.defaultPresetId
|
|
52
|
-
}).manifest;
|
|
53
|
-
} catch (error) {
|
|
54
|
-
return {
|
|
55
|
-
ok: false,
|
|
56
|
-
issues: [{
|
|
57
|
-
severity: "error",
|
|
58
|
-
path: "manifest",
|
|
59
|
-
message: error instanceof Error ? error.message : String(error)
|
|
60
|
-
}]
|
|
61
|
-
};
|
|
62
|
-
}
|
|
63
|
-
validateModels(manifest, issues);
|
|
64
|
-
validateTools(manifest, issues, params.catalogs ?? {});
|
|
65
|
-
validateSkills(manifest, issues, params.catalogs ?? {});
|
|
66
|
-
validateWorkflows(manifest, issues, params.catalogs ?? {});
|
|
67
|
-
return {
|
|
68
|
-
ok: issues.every((issue) => issue.severity !== "error"),
|
|
69
|
-
manifest,
|
|
70
|
-
issues
|
|
71
|
-
};
|
|
72
|
-
}
|
|
73
|
-
//#endregion
|
|
74
|
-
export { validateAgentManifest };
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
import type { EffectiveAgentManifest } from '../agent-manifest/schema.js';
|
|
2
|
-
export type BoundaryDecision = 'allow' | 'confirm' | 'deny' | 'escalate';
|
|
3
|
-
export interface BoundaryCheckParams {
|
|
4
|
-
manifest: EffectiveAgentManifest;
|
|
5
|
-
action: string;
|
|
6
|
-
detail?: string;
|
|
7
|
-
}
|
|
8
|
-
export interface BoundaryCheckResult {
|
|
9
|
-
decision: BoundaryDecision;
|
|
10
|
-
matchedRule?: string;
|
|
11
|
-
}
|
|
12
|
-
export declare function checkBoundary(params: BoundaryCheckParams): BoundaryCheckResult;
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
//#region src/agent-runtime/boundary-guard.ts
|
|
2
|
-
function matchesRule(action, detail, rule) {
|
|
3
|
-
return `${action}\n${detail ?? ""}`.toLowerCase().includes(rule.toLowerCase());
|
|
4
|
-
}
|
|
5
|
-
function checkBoundary(params) {
|
|
6
|
-
for (const rule of params.manifest.boundaries.forbidden) if (matchesRule(params.action, params.detail, rule)) return {
|
|
7
|
-
decision: "deny",
|
|
8
|
-
matchedRule: rule
|
|
9
|
-
};
|
|
10
|
-
for (const rule of params.manifest.boundaries.escalation) if (matchesRule(params.action, params.detail, rule)) return {
|
|
11
|
-
decision: "escalate",
|
|
12
|
-
matchedRule: rule
|
|
13
|
-
};
|
|
14
|
-
for (const rule of params.manifest.boundaries.requiresConfirmation) if (matchesRule(params.action, params.detail, rule)) return {
|
|
15
|
-
decision: "confirm",
|
|
16
|
-
matchedRule: rule
|
|
17
|
-
};
|
|
18
|
-
return { decision: "allow" };
|
|
19
|
-
}
|
|
20
|
-
//#endregion
|
|
21
|
-
export { checkBoundary };
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import { buildMemoryRuntime } from "./memory-runtime.js";
|
|
2
|
-
import { checkBoundary } from "./boundary-guard.js";
|
|
3
|
-
import { resolveModelRole } from "./model-router.js";
|
|
4
|
-
import { buildRuntimeToolRegistry } from "./tool-registry.js";
|
|
5
|
-
import { resolveWorkflow, validateWorkflowForRuntime } from "./workflow-runtime.js";
|
|
6
|
-
import { buildAgentRuntimeProfile } from "./runtime-profile.js";
|
|
7
|
-
import { appendAgentRunEvent, createAgentRunTrace, finishAgentRunTrace, hashEffectiveManifest } from "./run-trace.js";
|
|
8
|
-
export { appendAgentRunEvent, buildAgentRuntimeProfile, buildMemoryRuntime, buildRuntimeToolRegistry, checkBoundary, createAgentRunTrace, finishAgentRunTrace, hashEffectiveManifest, resolveModelRole, resolveWorkflow, validateWorkflowForRuntime };
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import type { EffectiveAgentManifest } from '../agent-manifest/schema.js';
|
|
2
|
-
export interface ResolveModelRoleParams {
|
|
3
|
-
manifest: EffectiveAgentManifest;
|
|
4
|
-
role?: string;
|
|
5
|
-
}
|
|
6
|
-
export interface ResolvedModelRole {
|
|
7
|
-
role: string;
|
|
8
|
-
model: string;
|
|
9
|
-
description?: string;
|
|
10
|
-
}
|
|
11
|
-
export declare function resolveModelRole(params: ResolveModelRoleParams): ResolvedModelRole;
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
//#region src/agent-runtime/model-router.ts
|
|
2
|
-
function resolveModelRole(params) {
|
|
3
|
-
const requested = params.role?.trim() || params.manifest.models.defaultRole;
|
|
4
|
-
const role = params.manifest.models.roles[requested] ? requested : params.manifest.models.defaultRole;
|
|
5
|
-
const entry = params.manifest.models.roles[role];
|
|
6
|
-
if (!entry) throw new Error(`Model role "${role}" is not configured`);
|
|
7
|
-
return {
|
|
8
|
-
role,
|
|
9
|
-
model: entry.model,
|
|
10
|
-
...entry.description !== void 0 ? { description: entry.description } : {}
|
|
11
|
-
};
|
|
12
|
-
}
|
|
13
|
-
//#endregion
|
|
14
|
-
export { resolveModelRole };
|
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
import type { EffectiveAgentManifest } from '../agent-manifest/schema.js';
|
|
2
|
-
export type AgentRunStatus = 'running' | 'completed' | 'failed' | 'cancelled';
|
|
3
|
-
export type AgentRunEventType = 'run.started' | 'model.selected' | 'tool.called' | 'memory.read' | 'memory.write.checked' | 'workflow.selected' | 'boundary.checked' | 'run.completed' | 'run.failed';
|
|
4
|
-
export interface AgentRunEvent {
|
|
5
|
-
id: string;
|
|
6
|
-
runId: string;
|
|
7
|
-
type: AgentRunEventType;
|
|
8
|
-
payload: Record<string, unknown>;
|
|
9
|
-
createdAt: string;
|
|
10
|
-
}
|
|
11
|
-
export interface AgentRunTrace {
|
|
12
|
-
id: string;
|
|
13
|
-
agentId: string;
|
|
14
|
-
status: AgentRunStatus;
|
|
15
|
-
effectiveManifestHash: string;
|
|
16
|
-
startedAt: string;
|
|
17
|
-
endedAt?: string;
|
|
18
|
-
events: AgentRunEvent[];
|
|
19
|
-
}
|
|
20
|
-
export declare function hashEffectiveManifest(manifest: EffectiveAgentManifest): string;
|
|
21
|
-
export declare function createAgentRunTrace(params: {
|
|
22
|
-
agentId: string;
|
|
23
|
-
manifest: EffectiveAgentManifest;
|
|
24
|
-
now?: Date;
|
|
25
|
-
}): AgentRunTrace;
|
|
26
|
-
export declare function appendAgentRunEvent(trace: AgentRunTrace, type: AgentRunEventType, payload: Record<string, unknown>, now?: Date): AgentRunTrace;
|
|
27
|
-
export declare function finishAgentRunTrace(trace: AgentRunTrace, status: Exclude<AgentRunStatus, 'running'>, payload?: Record<string, unknown>, now?: Date): AgentRunTrace;
|
|
@@ -1,51 +0,0 @@
|
|
|
1
|
-
import { createHash, randomUUID } from "node:crypto";
|
|
2
|
-
//#region src/agent-runtime/run-trace.ts
|
|
3
|
-
function stableJson(value) {
|
|
4
|
-
if (Array.isArray(value)) return `[${value.map(stableJson).join(",")}]`;
|
|
5
|
-
if (value && typeof value === "object") return `{${Object.entries(value).toSorted(([a], [b]) => a.localeCompare(b)).map(([key, child]) => `${JSON.stringify(key)}:${stableJson(child)}`).join(",")}}`;
|
|
6
|
-
return JSON.stringify(value);
|
|
7
|
-
}
|
|
8
|
-
function hashEffectiveManifest(manifest) {
|
|
9
|
-
return createHash("sha256").update(stableJson(manifest)).digest("hex");
|
|
10
|
-
}
|
|
11
|
-
function createAgentRunTrace(params) {
|
|
12
|
-
const startedAt = (params.now ?? /* @__PURE__ */ new Date()).toISOString();
|
|
13
|
-
const runId = randomUUID();
|
|
14
|
-
return {
|
|
15
|
-
id: runId,
|
|
16
|
-
agentId: params.agentId,
|
|
17
|
-
status: "running",
|
|
18
|
-
effectiveManifestHash: hashEffectiveManifest(params.manifest),
|
|
19
|
-
startedAt,
|
|
20
|
-
events: [{
|
|
21
|
-
id: randomUUID(),
|
|
22
|
-
runId,
|
|
23
|
-
type: "run.started",
|
|
24
|
-
payload: { agentId: params.agentId },
|
|
25
|
-
createdAt: startedAt
|
|
26
|
-
}]
|
|
27
|
-
};
|
|
28
|
-
}
|
|
29
|
-
function appendAgentRunEvent(trace, type, payload, now = /* @__PURE__ */ new Date()) {
|
|
30
|
-
if (trace.status !== "running") throw new Error(`Cannot append event to ${trace.status} run`);
|
|
31
|
-
return {
|
|
32
|
-
...trace,
|
|
33
|
-
events: [...trace.events, {
|
|
34
|
-
id: randomUUID(),
|
|
35
|
-
runId: trace.id,
|
|
36
|
-
type,
|
|
37
|
-
payload,
|
|
38
|
-
createdAt: now.toISOString()
|
|
39
|
-
}]
|
|
40
|
-
};
|
|
41
|
-
}
|
|
42
|
-
function finishAgentRunTrace(trace, status, payload = {}, now = /* @__PURE__ */ new Date()) {
|
|
43
|
-
if (trace.status !== "running") throw new Error(`Cannot finish ${trace.status} run`);
|
|
44
|
-
return {
|
|
45
|
-
...appendAgentRunEvent(trace, status === "failed" ? "run.failed" : "run.completed", payload, now),
|
|
46
|
-
status,
|
|
47
|
-
endedAt: now.toISOString()
|
|
48
|
-
};
|
|
49
|
-
}
|
|
50
|
-
//#endregion
|
|
51
|
-
export { appendAgentRunEvent, createAgentRunTrace, finishAgentRunTrace, hashEffectiveManifest };
|
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
import { type EffectiveAgentManifest } from '../agent-manifest/index.js';
|
|
2
|
-
import { checkBoundary } from './boundary-guard.js';
|
|
3
|
-
import { type MemoryRuntime } from './memory-runtime.js';
|
|
4
|
-
import { resolveModelRole } from './model-router.js';
|
|
5
|
-
import { type RuntimeToolRegistry, type ToolCatalogEntry } from './tool-registry.js';
|
|
6
|
-
import { type WorkflowCatalogEntry, type WorkflowResolution, type WorkflowValidationIssue } from './workflow-runtime.js';
|
|
7
|
-
import type { UserContextConfig } from '../user-context/config.js';
|
|
8
|
-
export interface AgentRuntimeProfile<TTool = unknown> {
|
|
9
|
-
manifest: EffectiveAgentManifest;
|
|
10
|
-
promptSections: {
|
|
11
|
-
capability: string;
|
|
12
|
-
};
|
|
13
|
-
tools: RuntimeToolRegistry<TTool>;
|
|
14
|
-
memory: MemoryRuntime;
|
|
15
|
-
resolveModel: (role?: string) => ReturnType<typeof resolveModelRole>;
|
|
16
|
-
checkBoundary: (action: string, detail?: string) => ReturnType<typeof checkBoundary>;
|
|
17
|
-
resolveWorkflow: (intent?: string) => WorkflowResolution;
|
|
18
|
-
validateWorkflow: (workflow: WorkflowCatalogEntry) => WorkflowValidationIssue[];
|
|
19
|
-
}
|
|
20
|
-
export interface BuildAgentRuntimeProfileParams<TTool = unknown> {
|
|
21
|
-
manifest: EffectiveAgentManifest;
|
|
22
|
-
userContext: UserContextConfig;
|
|
23
|
-
toolCatalog: Iterable<ToolCatalogEntry<TTool>>;
|
|
24
|
-
workflowCatalog?: Iterable<WorkflowCatalogEntry>;
|
|
25
|
-
}
|
|
26
|
-
export declare function buildAgentRuntimeProfile<TTool = unknown>(params: BuildAgentRuntimeProfileParams<TTool>): AgentRuntimeProfile<TTool>;
|
|
@@ -1,42 +0,0 @@
|
|
|
1
|
-
import { buildAgentManifestPromptSection } from "../agent-manifest/prompt.js";
|
|
2
|
-
import "../agent-manifest/index.js";
|
|
3
|
-
import { buildMemoryRuntime } from "./memory-runtime.js";
|
|
4
|
-
import { checkBoundary } from "./boundary-guard.js";
|
|
5
|
-
import { resolveModelRole } from "./model-router.js";
|
|
6
|
-
import { buildRuntimeToolRegistry } from "./tool-registry.js";
|
|
7
|
-
import { resolveWorkflow, validateWorkflowForRuntime } from "./workflow-runtime.js";
|
|
8
|
-
//#region src/agent-runtime/runtime-profile.ts
|
|
9
|
-
function buildAgentRuntimeProfile(params) {
|
|
10
|
-
const workflowCatalog = [...params.workflowCatalog ?? []];
|
|
11
|
-
const tools = buildRuntimeToolRegistry({
|
|
12
|
-
manifest: params.manifest,
|
|
13
|
-
catalog: params.toolCatalog
|
|
14
|
-
});
|
|
15
|
-
return {
|
|
16
|
-
manifest: params.manifest,
|
|
17
|
-
promptSections: { capability: buildAgentManifestPromptSection(params.manifest) },
|
|
18
|
-
tools,
|
|
19
|
-
memory: buildMemoryRuntime(params.userContext),
|
|
20
|
-
resolveModel: (role) => resolveModelRole({
|
|
21
|
-
manifest: params.manifest,
|
|
22
|
-
role
|
|
23
|
-
}),
|
|
24
|
-
checkBoundary: (action, detail) => checkBoundary({
|
|
25
|
-
manifest: params.manifest,
|
|
26
|
-
action,
|
|
27
|
-
detail
|
|
28
|
-
}),
|
|
29
|
-
resolveWorkflow: (intent) => resolveWorkflow({
|
|
30
|
-
manifest: params.manifest,
|
|
31
|
-
catalog: workflowCatalog,
|
|
32
|
-
intent
|
|
33
|
-
}),
|
|
34
|
-
validateWorkflow: (workflow) => validateWorkflowForRuntime({
|
|
35
|
-
manifest: params.manifest,
|
|
36
|
-
workflow,
|
|
37
|
-
tools
|
|
38
|
-
})
|
|
39
|
-
};
|
|
40
|
-
}
|
|
41
|
-
//#endregion
|
|
42
|
-
export { buildAgentRuntimeProfile };
|
|
@@ -1,28 +0,0 @@
|
|
|
1
|
-
import type { EffectiveAgentManifest, ToolPolicy } from '../agent-manifest/schema.js';
|
|
2
|
-
export interface ToolCatalogEntry<TTool = unknown> {
|
|
3
|
-
name: string;
|
|
4
|
-
category: 'file' | 'web' | 'code' | 'memory' | 'communication' | 'automation' | 'mcp' | 'other';
|
|
5
|
-
risk: 'low' | 'medium' | 'high';
|
|
6
|
-
supportsConfirm: boolean;
|
|
7
|
-
supportsDryRun?: boolean;
|
|
8
|
-
scopes?: Array<'readonly' | 'workspace' | 'unrestricted'>;
|
|
9
|
-
tool: TTool;
|
|
10
|
-
}
|
|
11
|
-
export interface RuntimeToolEntry<TTool = unknown> {
|
|
12
|
-
name: string;
|
|
13
|
-
policy: ToolPolicy;
|
|
14
|
-
catalog: ToolCatalogEntry<TTool>;
|
|
15
|
-
requiresConfirmation: boolean;
|
|
16
|
-
tool: TTool;
|
|
17
|
-
}
|
|
18
|
-
export interface BuildRuntimeToolRegistryParams<TTool = unknown> {
|
|
19
|
-
manifest: EffectiveAgentManifest;
|
|
20
|
-
catalog: Iterable<ToolCatalogEntry<TTool>>;
|
|
21
|
-
}
|
|
22
|
-
export interface RuntimeToolRegistry<TTool = unknown> {
|
|
23
|
-
tools: RuntimeToolEntry<TTool>[];
|
|
24
|
-
denied: string[];
|
|
25
|
-
missing: string[];
|
|
26
|
-
warnings: string[];
|
|
27
|
-
}
|
|
28
|
-
export declare function buildRuntimeToolRegistry<TTool = unknown>(params: BuildRuntimeToolRegistryParams<TTool>): RuntimeToolRegistry<TTool>;
|
|
@@ -1,50 +0,0 @@
|
|
|
1
|
-
//#region src/agent-runtime/tool-registry.ts
|
|
2
|
-
function scopeSupported(entry, policy) {
|
|
3
|
-
if (!policy.scope) return true;
|
|
4
|
-
return !entry.scopes || entry.scopes.includes(policy.scope);
|
|
5
|
-
}
|
|
6
|
-
function buildRuntimeToolRegistry(params) {
|
|
7
|
-
const byName = new Map([...params.catalog].map((entry) => [entry.name, entry]));
|
|
8
|
-
const tools = [];
|
|
9
|
-
const denied = [];
|
|
10
|
-
const missing = [];
|
|
11
|
-
const warnings = [];
|
|
12
|
-
for (const [name, policy] of Object.entries(params.manifest.tools.builtin)) {
|
|
13
|
-
if (policy.mode === "deny") {
|
|
14
|
-
denied.push(name);
|
|
15
|
-
continue;
|
|
16
|
-
}
|
|
17
|
-
const entry = byName.get(name);
|
|
18
|
-
if (!entry) {
|
|
19
|
-
missing.push(name);
|
|
20
|
-
continue;
|
|
21
|
-
}
|
|
22
|
-
if (policy.mode === "confirm" && !entry.supportsConfirm) {
|
|
23
|
-
warnings.push(`tool "${name}" requires confirmation but does not support a confirm wrapper`);
|
|
24
|
-
continue;
|
|
25
|
-
}
|
|
26
|
-
if (!scopeSupported(entry, policy)) {
|
|
27
|
-
warnings.push(`tool "${name}" does not support scope "${policy.scope}"`);
|
|
28
|
-
continue;
|
|
29
|
-
}
|
|
30
|
-
tools.push({
|
|
31
|
-
name,
|
|
32
|
-
policy,
|
|
33
|
-
catalog: entry,
|
|
34
|
-
requiresConfirmation: policy.mode === "confirm",
|
|
35
|
-
tool: entry.tool
|
|
36
|
-
});
|
|
37
|
-
}
|
|
38
|
-
tools.sort((a, b) => a.name.localeCompare(b.name));
|
|
39
|
-
denied.sort();
|
|
40
|
-
missing.sort();
|
|
41
|
-
warnings.sort();
|
|
42
|
-
return {
|
|
43
|
-
tools,
|
|
44
|
-
denied,
|
|
45
|
-
missing,
|
|
46
|
-
warnings
|
|
47
|
-
};
|
|
48
|
-
}
|
|
49
|
-
//#endregion
|
|
50
|
-
export { buildRuntimeToolRegistry };
|
|
@@ -1,31 +0,0 @@
|
|
|
1
|
-
import type { EffectiveAgentManifest } from '../agent-manifest/schema.js';
|
|
2
|
-
import type { RuntimeToolRegistry } from './tool-registry.js';
|
|
3
|
-
export interface WorkflowPhaseDefinition {
|
|
4
|
-
id: string;
|
|
5
|
-
modelRole?: string;
|
|
6
|
-
requiredTools?: string[];
|
|
7
|
-
}
|
|
8
|
-
export interface WorkflowCatalogEntry {
|
|
9
|
-
id: string;
|
|
10
|
-
description?: string;
|
|
11
|
-
phases: WorkflowPhaseDefinition[];
|
|
12
|
-
}
|
|
13
|
-
export interface ResolveWorkflowParams {
|
|
14
|
-
manifest: EffectiveAgentManifest;
|
|
15
|
-
catalog: Iterable<WorkflowCatalogEntry>;
|
|
16
|
-
intent?: string;
|
|
17
|
-
}
|
|
18
|
-
export interface WorkflowResolution {
|
|
19
|
-
workflow?: WorkflowCatalogEntry;
|
|
20
|
-
reason: string;
|
|
21
|
-
}
|
|
22
|
-
export interface WorkflowValidationIssue {
|
|
23
|
-
path: string;
|
|
24
|
-
message: string;
|
|
25
|
-
}
|
|
26
|
-
export declare function resolveWorkflow(params: ResolveWorkflowParams): WorkflowResolution;
|
|
27
|
-
export declare function validateWorkflowForRuntime(params: {
|
|
28
|
-
manifest: EffectiveAgentManifest;
|
|
29
|
-
workflow: WorkflowCatalogEntry;
|
|
30
|
-
tools: RuntimeToolRegistry;
|
|
31
|
-
}): WorkflowValidationIssue[];
|