veryfront 0.1.149 → 0.1.150
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/esm/cli/commands/dev/command.js +3 -3
- package/esm/cli/commands/workflow/command-help.js +1 -1
- package/esm/cli/commands/workflow/command.js +2 -2
- package/esm/cli/shared/config.d.ts.map +1 -1
- package/esm/cli/shared/config.js +1 -3
- package/esm/deno.d.ts +5 -11
- package/esm/deno.js +16 -16
- package/esm/src/agent/chat-handler.js +1 -1
- package/esm/src/agent/composition/composition.d.ts +1 -1
- package/esm/src/agent/composition/composition.d.ts.map +1 -1
- package/esm/src/agent/composition/composition.js +2 -2
- package/esm/src/agent/{ai-defaults.d.ts → defaults.d.ts} +1 -1
- package/esm/src/agent/defaults.d.ts.map +1 -0
- package/esm/src/agent/factory.js +1 -1
- package/esm/src/agent/react/index.d.ts +1 -1
- package/esm/src/agent/react/index.d.ts.map +1 -1
- package/esm/src/agent/react/use-chat/browser-inference/browser-engine.d.ts +5 -6
- package/esm/src/agent/react/use-chat/browser-inference/browser-engine.d.ts.map +1 -1
- package/esm/src/agent/react/use-chat/browser-inference/browser-engine.js +1 -1
- package/esm/src/agent/react/use-chat/index.d.ts +2 -1
- package/esm/src/agent/react/use-chat/index.d.ts.map +1 -1
- package/esm/src/agent/react/use-chat/stream-protocol.d.ts +2 -0
- package/esm/src/agent/react/use-chat/stream-protocol.d.ts.map +1 -0
- package/esm/src/agent/react/use-chat/stream-protocol.js +1 -0
- package/esm/src/agent/react/use-chat/streaming/parts-builder.d.ts +2 -2
- package/esm/src/agent/react/use-chat/streaming/parts-builder.d.ts.map +1 -1
- package/esm/src/agent/react/use-chat/streaming/types.d.ts +4 -4
- package/esm/src/agent/react/use-chat/streaming/types.d.ts.map +1 -1
- package/esm/src/agent/react/use-chat/types.d.ts +7 -55
- package/esm/src/agent/react/use-chat/types.d.ts.map +1 -1
- package/esm/src/agent/react/use-chat/use-chat.d.ts +4 -4
- package/esm/src/agent/react/use-chat/use-chat.d.ts.map +1 -1
- package/esm/src/agent/react/use-chat/use-chat.js +2 -2
- package/esm/src/agent/react/use-chat/utils.d.ts +2 -2
- package/esm/src/agent/react/use-chat/utils.d.ts.map +1 -1
- package/esm/src/agent/runtime/{ai-stream-handler.d.ts → chat-stream-handler.d.ts} +13 -13
- package/esm/src/agent/runtime/chat-stream-handler.d.ts.map +1 -0
- package/esm/src/agent/runtime/{ai-stream-handler.js → chat-stream-handler.js} +91 -89
- package/esm/src/agent/runtime/constants.js +1 -1
- package/esm/src/agent/runtime/index.d.ts +7 -5
- package/esm/src/agent/runtime/index.d.ts.map +1 -1
- package/esm/src/agent/runtime/index.js +67 -30
- package/esm/src/agent/runtime/model-message-converter.d.ts +7 -7
- package/esm/src/agent/runtime/model-message-converter.d.ts.map +1 -1
- package/esm/src/agent/runtime/model-message-converter.js +8 -6
- package/esm/src/agent/runtime/model-runtime-types.d.ts +44 -0
- package/esm/src/agent/runtime/model-runtime-types.d.ts.map +1 -0
- package/esm/src/agent/runtime/model-runtime-types.js +8 -0
- package/esm/src/agent/runtime/model-tool-converter.d.ts +9 -9
- package/esm/src/agent/runtime/model-tool-converter.d.ts.map +1 -1
- package/esm/src/agent/runtime/model-tool-converter.js +10 -22
- package/esm/src/agent/runtime/provider-native-tools.d.ts +3 -0
- package/esm/src/agent/runtime/provider-native-tools.d.ts.map +1 -0
- package/esm/src/agent/runtime/provider-native-tools.js +56 -0
- package/esm/src/agent/runtime/repair-tool-call.d.ts +2 -2
- package/esm/src/agent/runtime/repair-tool-call.d.ts.map +1 -1
- package/esm/src/agent/runtime/repair-tool-call.js +3 -3
- package/esm/src/agent/runtime/runtime-tool-builder.d.ts +48 -0
- package/esm/src/agent/runtime/runtime-tool-builder.d.ts.map +1 -0
- package/esm/src/agent/runtime/runtime-tool-builder.js +28 -0
- package/esm/src/agent/runtime/runtime-tool-errors.d.ts +16 -0
- package/esm/src/agent/runtime/runtime-tool-errors.d.ts.map +1 -0
- package/esm/src/agent/runtime/runtime-tool-errors.js +28 -0
- package/esm/src/agent/runtime/runtime-tool-types.d.ts +104 -0
- package/esm/src/agent/runtime/runtime-tool-types.d.ts.map +1 -0
- package/esm/src/agent/runtime/runtime-tool-types.js +7 -0
- package/esm/src/chat/index.d.ts +9 -9
- package/esm/src/chat/index.d.ts.map +1 -1
- package/esm/src/chat/index.js +7 -7
- package/esm/src/chat/protocol.d.ts +156 -0
- package/esm/src/chat/protocol.d.ts.map +1 -0
- package/esm/src/chat/protocol.js +7 -0
- package/esm/src/discovery/import-rewriter.d.ts.map +1 -1
- package/esm/src/discovery/import-rewriter.js +1 -14
- package/esm/src/discovery/index.d.ts +1 -1
- package/esm/src/discovery/index.d.ts.map +1 -1
- package/esm/src/discovery/index.js +2 -2
- package/esm/src/discovery/provider-config-validator.d.ts +14 -0
- package/esm/src/discovery/provider-config-validator.d.ts.map +1 -0
- package/esm/src/discovery/{config-validator.js → provider-config-validator.js} +4 -4
- package/esm/src/discovery/transpiler.d.ts.map +1 -1
- package/esm/src/discovery/transpiler.js +0 -3
- package/esm/src/embedding/embedding.d.ts.map +1 -1
- package/esm/src/embedding/embedding.js +1 -1
- package/esm/src/embedding/index.d.ts +3 -3
- package/esm/src/embedding/index.d.ts.map +1 -1
- package/esm/src/embedding/index.js +3 -3
- package/esm/src/embedding/rag-store.d.ts.map +1 -1
- package/esm/src/embedding/rag-store.js +1 -1
- package/esm/src/embedding/resolve.d.ts +5 -7
- package/esm/src/embedding/resolve.d.ts.map +1 -1
- package/esm/src/embedding/resolve.js +6 -9
- package/esm/src/embedding/vector-store.d.ts.map +1 -1
- package/esm/src/embedding/vector-store.js +1 -1
- package/esm/src/embedding/veryfront-cloud/provider.d.ts +2 -2
- package/esm/src/embedding/veryfront-cloud/provider.d.ts.map +1 -1
- package/esm/src/embedding/veryfront-cloud/provider.js +5 -6
- package/esm/src/markdown/index.d.ts +1 -1
- package/esm/src/markdown/index.d.ts.map +1 -1
- package/esm/src/markdown/index.js +1 -1
- package/esm/src/modules/import-map/default-import-map.js +2 -2
- package/esm/src/prompt/registry.d.ts +1 -1
- package/esm/src/prompt/registry.d.ts.map +1 -1
- package/esm/src/prompt/registry.js +2 -2
- package/esm/src/provider/index.d.ts +7 -8
- package/esm/src/provider/index.d.ts.map +1 -1
- package/esm/src/provider/index.js +6 -8
- package/esm/src/provider/local/embedding-runtime-adapter.d.ts +19 -0
- package/esm/src/provider/local/embedding-runtime-adapter.d.ts.map +1 -0
- package/esm/src/provider/local/{local-embedding-adapter.js → embedding-runtime-adapter.js} +5 -5
- package/esm/src/provider/local/model-runtime-adapter.d.ts +18 -0
- package/esm/src/provider/local/model-runtime-adapter.d.ts.map +1 -0
- package/esm/src/provider/local/{ai-sdk-adapter.js → model-runtime-adapter.js} +10 -12
- package/esm/src/provider/model-registry.d.ts +11 -12
- package/esm/src/provider/model-registry.d.ts.map +1 -1
- package/esm/src/provider/model-registry.js +17 -20
- package/esm/src/provider/runtime-inspection.d.ts +6 -0
- package/esm/src/provider/runtime-inspection.d.ts.map +1 -0
- package/esm/src/provider/runtime-inspection.js +19 -0
- package/esm/src/provider/runtime-loader.d.ts +27 -0
- package/esm/src/provider/runtime-loader.d.ts.map +1 -0
- package/esm/src/provider/runtime-loader.js +1307 -0
- package/esm/src/provider/types.d.ts +35 -0
- package/esm/src/provider/types.d.ts.map +1 -0
- package/esm/src/provider/types.js +1 -0
- package/esm/src/provider/veryfront-cloud/provider.d.ts +2 -2
- package/esm/src/provider/veryfront-cloud/provider.d.ts.map +1 -1
- package/esm/src/provider/veryfront-cloud/provider.js +7 -9
- package/esm/src/provider/veryfront-cloud/shared.d.ts +1 -1
- package/esm/src/provider/veryfront-cloud/shared.js +1 -1
- package/esm/src/react/components/chat/agent-card.d.ts.map +1 -0
- package/esm/src/react/components/chat/chat/components/animations.d.ts.map +1 -0
- package/esm/src/react/components/chat/chat/components/attachment-pill.d.ts.map +1 -0
- package/esm/src/react/components/chat/chat/components/branch-picker.d.ts.map +1 -0
- package/esm/src/react/components/chat/chat/components/code-block.d.ts.map +1 -0
- package/esm/src/react/components/chat/chat/components/drop-zone.d.ts.map +1 -0
- package/esm/src/react/components/chat/chat/components/empty-state.d.ts.map +1 -0
- package/esm/src/react/components/chat/chat/components/inference-badge.d.ts.map +1 -0
- package/esm/src/react/components/{ai → chat}/chat/components/inference-badge.js +1 -1
- package/esm/src/react/components/chat/chat/components/inline-citation.d.ts.map +1 -0
- package/esm/src/react/components/chat/chat/components/message-actions.d.ts.map +1 -0
- package/esm/src/react/components/chat/chat/components/message-edit-form.d.ts.map +1 -0
- package/esm/src/react/components/chat/chat/components/message-feedback.d.ts.map +1 -0
- package/esm/src/react/components/chat/chat/components/quick-actions.d.ts.map +1 -0
- package/esm/src/react/components/chat/chat/components/reasoning.d.ts.map +1 -0
- package/esm/src/react/components/chat/chat/components/sidebar.d.ts.map +1 -0
- package/esm/src/react/components/{ai → chat}/chat/components/skill-badge.d.ts +3 -3
- package/esm/src/react/components/chat/chat/components/skill-badge.d.ts.map +1 -0
- package/esm/src/react/components/{ai → chat}/chat/components/skill-badge.js +1 -1
- package/esm/src/react/components/chat/chat/components/sources.d.ts.map +1 -0
- package/esm/src/react/components/chat/chat/components/step-indicator.d.ts.map +1 -0
- package/esm/src/react/components/chat/chat/components/tab-switcher.d.ts.map +1 -0
- package/esm/src/react/components/{ai → chat}/chat/components/tool-ui.d.ts +3 -3
- package/esm/src/react/components/chat/chat/components/tool-ui.d.ts.map +1 -0
- package/esm/src/react/components/{ai → chat}/chat/components/tool-ui.js +1 -1
- package/esm/src/react/components/chat/chat/components/upgrade-cta.d.ts.map +1 -0
- package/esm/src/react/components/chat/chat/components/uploads-panel.d.ts.map +1 -0
- package/esm/src/react/components/{ai → chat}/chat/composition/api.d.ts +1 -1
- package/esm/src/react/components/chat/chat/composition/api.d.ts.map +1 -0
- package/esm/src/react/components/{ai → chat}/chat/composition/api.js +1 -1
- package/esm/src/react/components/{ai → chat}/chat/composition/chat-composer.d.ts +3 -3
- package/esm/src/react/components/chat/chat/composition/chat-composer.d.ts.map +1 -0
- package/esm/src/react/components/{ai → chat}/chat/composition/chat-composer.js +1 -1
- package/esm/src/react/components/{ai → chat}/chat/composition/chat-empty.d.ts +1 -1
- package/esm/src/react/components/chat/chat/composition/chat-empty.d.ts.map +1 -0
- package/esm/src/react/components/{ai → chat}/chat/composition/chat-empty.js +1 -1
- package/esm/src/react/components/{ai → chat}/chat/composition/chat-if.d.ts +1 -1
- package/esm/src/react/components/chat/chat/composition/chat-if.d.ts.map +1 -0
- package/esm/src/react/components/{ai → chat}/chat/composition/chat-if.js +1 -1
- package/esm/src/react/components/{ai → chat}/chat/composition/chat-message-list.d.ts +5 -5
- package/esm/src/react/components/chat/chat/composition/chat-message-list.d.ts.map +1 -0
- package/esm/src/react/components/{ai → chat}/chat/composition/chat-message-list.js +2 -2
- package/esm/src/react/components/{ai → chat}/chat/composition/chat-root.d.ts +3 -3
- package/esm/src/react/components/chat/chat/composition/chat-root.d.ts.map +1 -0
- package/esm/src/react/components/{ai → chat}/chat/composition/chat-root.js +1 -1
- package/esm/src/react/components/{ai → chat}/chat/composition/error-banner.d.ts +1 -1
- package/esm/src/react/components/chat/chat/composition/error-banner.d.ts.map +1 -0
- package/esm/src/react/components/{ai → chat}/chat/composition/error-banner.js +1 -1
- package/esm/src/react/components/{ai → chat}/chat/composition/message.d.ts +4 -4
- package/esm/src/react/components/chat/chat/composition/message.d.ts.map +1 -0
- package/esm/src/react/components/{ai → chat}/chat/composition/message.js +1 -1
- package/esm/src/react/components/{ai → chat}/chat/composition/model-avatar.d.ts +1 -1
- package/esm/src/react/components/chat/chat/composition/model-avatar.d.ts.map +1 -0
- package/esm/src/react/components/{ai → chat}/chat/composition/model-avatar.js +1 -1
- package/esm/src/react/components/{ai → chat}/chat/contexts/chat-context.d.ts +3 -3
- package/esm/src/react/components/chat/chat/contexts/chat-context.d.ts.map +1 -0
- package/esm/src/react/components/{ai → chat}/chat/contexts/chat-context.js +1 -1
- package/esm/src/react/components/{ai → chat}/chat/contexts/composer-context.d.ts +1 -1
- package/esm/src/react/components/chat/chat/contexts/composer-context.d.ts.map +1 -0
- package/esm/src/react/components/{ai → chat}/chat/contexts/composer-context.js +1 -1
- package/esm/src/react/components/{ai → chat}/chat/contexts/index.d.ts +1 -1
- package/esm/src/react/components/chat/chat/contexts/index.d.ts.map +1 -0
- package/esm/src/react/components/{ai → chat}/chat/contexts/index.js +1 -1
- package/esm/src/react/components/{ai → chat}/chat/contexts/message-context.d.ts +3 -3
- package/esm/src/react/components/chat/chat/contexts/message-context.d.ts.map +1 -0
- package/esm/src/react/components/{ai → chat}/chat/contexts/message-context.js +1 -1
- package/esm/src/react/components/{ai → chat}/chat/contexts/thread-list-context.d.ts +1 -1
- package/esm/src/react/components/chat/chat/contexts/thread-list-context.d.ts.map +1 -0
- package/esm/src/react/components/{ai → chat}/chat/contexts/thread-list-context.js +1 -1
- package/esm/src/react/components/{ai → chat}/chat/hooks/use-threads.d.ts +2 -2
- package/esm/src/react/components/chat/chat/hooks/use-threads.d.ts.map +1 -0
- package/esm/src/react/components/{ai → chat}/chat/index.d.ts +5 -5
- package/esm/src/react/components/chat/chat/index.d.ts.map +1 -0
- package/esm/src/react/components/{ai → chat}/chat/index.js +1 -1
- package/esm/src/react/components/chat/chat/utils/export.d.ts +10 -0
- package/esm/src/react/components/chat/chat/utils/export.d.ts.map +1 -0
- package/esm/src/react/components/{ai → chat}/chat/utils/export.js +1 -1
- package/esm/src/react/components/{ai → chat}/chat/utils/message-parts.d.ts +10 -10
- package/esm/src/react/components/chat/chat/utils/message-parts.d.ts.map +1 -0
- package/esm/src/react/components/{ai → chat}/chat/utils/message-parts.js +2 -2
- package/esm/src/react/components/chat/chat-with-sidebar.d.ts.map +1 -0
- package/esm/src/react/components/{ai → chat}/chat.d.ts +1 -1
- package/esm/src/react/components/chat/chat.d.ts.map +1 -0
- package/esm/src/react/components/{ai → chat}/chat.js +1 -1
- package/esm/src/react/components/chat/csp-nonce.d.ts.map +1 -0
- package/esm/src/react/components/{ai → chat}/error-boundary.d.ts +6 -6
- package/esm/src/react/components/chat/error-boundary.d.ts.map +1 -0
- package/esm/src/react/components/{ai → chat}/error-boundary.js +5 -5
- package/esm/src/react/components/{ai → chat}/icons/index.d.ts +1 -1
- package/esm/src/react/components/chat/icons/index.d.ts.map +1 -0
- package/esm/src/react/components/{ai → chat}/icons/index.js +1 -1
- package/esm/src/react/components/chat/markdown.d.ts.map +1 -0
- package/esm/src/react/components/{ai → chat}/message.d.ts +8 -8
- package/esm/src/react/components/chat/message.d.ts.map +1 -0
- package/esm/src/react/components/chat/model-selector.d.ts.map +1 -0
- package/esm/src/react/components/chat/theme.d.ts.map +1 -0
- package/esm/src/react/primitives/message-list.d.ts +2 -2
- package/esm/src/react/primitives/message-list.d.ts.map +1 -1
- package/esm/src/react/primitives/tool-primitives.d.ts +3 -3
- package/esm/src/react/primitives/tool-primitives.d.ts.map +1 -1
- package/esm/src/{ai/registry-manager.d.ts → registry/project-scoped-registry-manager.d.ts} +5 -4
- package/esm/src/registry/project-scoped-registry-manager.d.ts.map +1 -0
- package/esm/src/{ai/registry-manager.js → registry/project-scoped-registry-manager.js} +5 -4
- package/esm/src/{ai/registry-facade.d.ts → registry/scoped-registry-facade.d.ts} +2 -2
- package/esm/src/registry/scoped-registry-facade.d.ts.map +1 -0
- package/esm/src/rendering/script-page-handling.d.ts.map +1 -1
- package/esm/src/rendering/script-page-handling.js +0 -2
- package/esm/src/resource/registry.d.ts +1 -1
- package/esm/src/resource/registry.d.ts.map +1 -1
- package/esm/src/resource/registry.js +2 -2
- package/esm/src/routing/api/module-loader/loader.js +3 -19
- package/esm/src/runtime/runtime-bridge.d.ts +82 -0
- package/esm/src/runtime/runtime-bridge.d.ts.map +1 -0
- package/esm/src/runtime/runtime-bridge.js +367 -0
- package/esm/src/server/dev-server/file-watch-setup.d.ts +4 -4
- package/esm/src/server/dev-server/file-watch-setup.d.ts.map +1 -1
- package/esm/src/server/dev-server/file-watch-setup.js +14 -14
- package/esm/src/server/dev-server/server.d.ts +2 -2
- package/esm/src/server/dev-server/server.d.ts.map +1 -1
- package/esm/src/server/dev-server/server.js +20 -18
- package/esm/src/server/dev-ui/manifest.d.ts +1 -1
- package/esm/src/server/dev-ui/manifest.js +2 -2
- package/esm/src/server/handlers/dev/framework-candidates.generated.d.ts.map +1 -1
- package/esm/src/server/handlers/dev/framework-candidates.generated.js +58 -61
- package/esm/src/server/handlers/request/api/api-handler-wrapper.js +1 -1
- package/esm/src/server/handlers/request/api/project-discovery.d.ts +1 -1
- package/esm/src/server/handlers/request/api/project-discovery.d.ts.map +1 -1
- package/esm/src/server/handlers/request/api/project-discovery.js +12 -10
- package/esm/src/server/production-server.js +2 -2
- package/esm/src/server/services/rsc/endpoints/rsc-bundles.generated.d.ts.map +1 -1
- package/esm/src/server/services/rsc/endpoints/rsc-bundles.generated.js +2 -2
- package/esm/src/skill/registry.d.ts +1 -1
- package/esm/src/skill/registry.d.ts.map +1 -1
- package/esm/src/skill/registry.js +2 -2
- package/esm/src/tool/registry.d.ts +1 -1
- package/esm/src/tool/registry.d.ts.map +1 -1
- package/esm/src/tool/registry.js +2 -2
- package/esm/src/transforms/npm-import-rewrites.d.ts +1 -1
- package/esm/src/transforms/npm-import-rewrites.d.ts.map +1 -1
- package/esm/src/transforms/npm-import-rewrites.js +5 -13
- package/esm/src/utils/constants/server.d.ts +4 -4
- package/esm/src/utils/constants/server.d.ts.map +1 -1
- package/esm/src/utils/constants/server.js +4 -4
- package/esm/src/utils/id.js +1 -1
- package/esm/src/utils/version-constant.d.ts +1 -1
- package/esm/src/utils/version-constant.js +1 -1
- package/esm/src/workflow/discovery/workflow-discovery.d.ts +3 -3
- package/esm/src/workflow/discovery/workflow-discovery.d.ts.map +1 -1
- package/esm/src/workflow/discovery/workflow-discovery.js +3 -3
- package/esm/src/workflow/registry.d.ts +1 -1
- package/esm/src/workflow/registry.d.ts.map +1 -1
- package/esm/src/workflow/registry.js +2 -2
- package/package.json +4 -5
- package/src/cli/commands/dev/command.ts +3 -3
- package/src/cli/commands/workflow/command-help.ts +1 -1
- package/src/cli/commands/workflow/command.ts +2 -2
- package/src/cli/shared/config.ts +1 -3
- package/src/deno.js +16 -16
- package/src/src/agent/chat-handler.ts +1 -1
- package/src/src/agent/composition/composition.ts +2 -2
- package/src/src/agent/factory.ts +1 -1
- package/src/src/agent/react/index.ts +11 -9
- package/src/src/agent/react/use-chat/browser-inference/browser-engine.ts +9 -10
- package/src/src/agent/react/use-chat/index.ts +10 -9
- package/src/src/agent/react/use-chat/stream-protocol.ts +1 -0
- package/src/src/agent/react/use-chat/streaming/handler.ts +17 -17
- package/src/src/agent/react/use-chat/streaming/parts-builder.ts +5 -5
- package/src/src/agent/react/use-chat/streaming/types.ts +4 -4
- package/src/src/agent/react/use-chat/types.ts +27 -73
- package/src/src/agent/react/use-chat/use-chat.ts +13 -13
- package/src/src/agent/react/use-chat/utils.ts +2 -2
- package/src/src/agent/runtime/{ai-stream-handler.ts → chat-stream-handler.ts} +100 -96
- package/src/src/agent/runtime/constants.ts +1 -1
- package/src/src/agent/runtime/index.ts +88 -40
- package/src/src/agent/runtime/model-message-converter.ts +22 -33
- package/src/src/agent/runtime/model-runtime-types.ts +55 -0
- package/src/src/agent/runtime/model-tool-converter.ts +29 -26
- package/src/src/agent/runtime/provider-native-tools.ts +61 -0
- package/src/src/agent/runtime/repair-tool-call.ts +6 -9
- package/src/src/agent/runtime/runtime-tool-builder.ts +82 -0
- package/src/src/agent/runtime/runtime-tool-errors.ts +46 -0
- package/src/src/agent/runtime/runtime-tool-types.ts +114 -0
- package/src/src/chat/index.ts +22 -20
- package/src/src/chat/protocol.ts +210 -0
- package/src/src/discovery/import-rewriter.ts +1 -14
- package/src/src/discovery/index.ts +2 -2
- package/src/src/discovery/{config-validator.ts → provider-config-validator.ts} +4 -4
- package/src/src/discovery/transpiler.ts +0 -3
- package/src/src/embedding/embedding.ts +1 -1
- package/src/src/embedding/index.ts +3 -3
- package/src/src/embedding/rag-store.ts +1 -1
- package/src/src/embedding/resolve.ts +15 -12
- package/src/src/embedding/vector-store.ts +1 -1
- package/src/src/embedding/veryfront-cloud/provider.ts +10 -8
- package/src/src/markdown/index.ts +1 -1
- package/src/src/modules/import-map/default-import-map.ts +2 -2
- package/src/src/prompt/registry.ts +2 -2
- package/src/src/provider/index.ts +7 -8
- package/src/src/provider/local/{local-embedding-adapter.ts → embedding-runtime-adapter.ts} +8 -8
- package/src/src/provider/local/{ai-sdk-adapter.ts → model-runtime-adapter.ts} +13 -16
- package/src/src/provider/model-registry.ts +31 -26
- package/src/src/provider/runtime-inspection.ts +25 -0
- package/src/src/provider/runtime-loader.ts +1854 -0
- package/src/src/provider/types.ts +38 -0
- package/src/src/provider/veryfront-cloud/provider.ts +13 -11
- package/src/src/provider/veryfront-cloud/shared.ts +1 -1
- package/src/src/react/components/{ai → chat}/chat/components/inference-badge.tsx +1 -1
- package/src/src/react/components/{ai → chat}/chat/components/skill-badge.tsx +3 -3
- package/src/src/react/components/{ai → chat}/chat/components/tool-ui.tsx +3 -3
- package/src/src/react/components/{ai → chat}/chat/composition/api.tsx +1 -1
- package/src/src/react/components/{ai → chat}/chat/composition/chat-composer.tsx +3 -3
- package/src/src/react/components/{ai → chat}/chat/composition/chat-empty.tsx +1 -1
- package/src/src/react/components/{ai → chat}/chat/composition/chat-if.tsx +1 -1
- package/src/src/react/components/{ai → chat}/chat/composition/chat-message-list.tsx +11 -11
- package/src/src/react/components/{ai → chat}/chat/composition/chat-root.tsx +3 -3
- package/src/src/react/components/{ai → chat}/chat/composition/error-banner.tsx +1 -1
- package/src/src/react/components/{ai → chat}/chat/composition/message.tsx +9 -4
- package/src/src/react/components/{ai → chat}/chat/composition/model-avatar.tsx +1 -1
- package/src/src/react/components/{ai → chat}/chat/contexts/chat-context.tsx +3 -3
- package/src/src/react/components/{ai → chat}/chat/contexts/composer-context.tsx +1 -1
- package/src/src/react/components/{ai → chat}/chat/contexts/index.ts +1 -1
- package/src/src/react/components/{ai → chat}/chat/contexts/message-context.tsx +3 -3
- package/src/src/react/components/{ai → chat}/chat/contexts/thread-list-context.tsx +1 -1
- package/src/src/react/components/{ai → chat}/chat/hooks/use-threads.ts +2 -2
- package/src/src/react/components/{ai → chat}/chat/index.tsx +7 -7
- package/src/src/react/components/{ai → chat}/chat/utils/export.ts +4 -4
- package/src/src/react/components/{ai → chat}/chat/utils/message-parts.ts +13 -13
- package/src/src/react/components/{ai → chat}/chat.tsx +1 -1
- package/src/src/react/components/{ai → chat}/error-boundary.tsx +11 -11
- package/src/src/react/components/{ai → chat}/icons/index.ts +1 -1
- package/src/src/react/components/{ai → chat}/message.tsx +11 -11
- package/src/src/react/primitives/message-list.tsx +2 -2
- package/src/src/react/primitives/tool-primitives.tsx +4 -4
- package/src/src/{ai/registry-manager.ts → registry/project-scoped-registry-manager.ts} +5 -4
- package/src/src/{ai/registry-facade.ts → registry/scoped-registry-facade.ts} +1 -1
- package/src/src/rendering/script-page-handling.ts +0 -2
- package/src/src/resource/registry.ts +2 -2
- package/src/src/routing/api/module-loader/loader.ts +3 -19
- package/src/src/runtime/runtime-bridge.ts +608 -0
- package/src/src/server/dev-server/file-watch-setup.ts +14 -14
- package/src/src/server/dev-server/server.ts +20 -18
- package/src/src/server/dev-ui/manifest.js +2 -2
- package/src/src/server/handlers/dev/framework-candidates.generated.ts +58 -61
- package/src/src/server/handlers/request/api/api-handler-wrapper.ts +1 -1
- package/src/src/server/handlers/request/api/project-discovery.ts +12 -10
- package/src/src/server/production-server.ts +2 -2
- package/src/src/server/services/rsc/endpoints/rsc-bundles.generated.ts +2 -2
- package/src/src/skill/registry.ts +2 -2
- package/src/src/tool/registry.ts +2 -2
- package/src/src/transforms/npm-import-rewrites.ts +5 -13
- package/src/src/utils/constants/server.ts +4 -4
- package/src/src/utils/id.ts +1 -1
- package/src/src/utils/version-constant.ts +1 -1
- package/src/src/workflow/discovery/workflow-discovery.ts +4 -4
- package/src/src/workflow/registry.ts +2 -2
- package/esm/src/agent/ai-defaults.d.ts.map +0 -1
- package/esm/src/agent/runtime/ai-stream-handler.d.ts.map +0 -1
- package/esm/src/ai/registry-facade.d.ts.map +0 -1
- package/esm/src/ai/registry-manager.d.ts.map +0 -1
- package/esm/src/discovery/config-validator.d.ts +0 -14
- package/esm/src/discovery/config-validator.d.ts.map +0 -1
- package/esm/src/provider/local/ai-sdk-adapter.d.ts +0 -19
- package/esm/src/provider/local/ai-sdk-adapter.d.ts.map +0 -1
- package/esm/src/provider/local/local-embedding-adapter.d.ts +0 -19
- package/esm/src/provider/local/local-embedding-adapter.d.ts.map +0 -1
- package/esm/src/react/components/ai/agent-card.d.ts.map +0 -1
- package/esm/src/react/components/ai/chat/components/animations.d.ts.map +0 -1
- package/esm/src/react/components/ai/chat/components/attachment-pill.d.ts.map +0 -1
- package/esm/src/react/components/ai/chat/components/branch-picker.d.ts.map +0 -1
- package/esm/src/react/components/ai/chat/components/code-block.d.ts.map +0 -1
- package/esm/src/react/components/ai/chat/components/drop-zone.d.ts.map +0 -1
- package/esm/src/react/components/ai/chat/components/empty-state.d.ts.map +0 -1
- package/esm/src/react/components/ai/chat/components/inference-badge.d.ts.map +0 -1
- package/esm/src/react/components/ai/chat/components/inline-citation.d.ts.map +0 -1
- package/esm/src/react/components/ai/chat/components/message-actions.d.ts.map +0 -1
- package/esm/src/react/components/ai/chat/components/message-edit-form.d.ts.map +0 -1
- package/esm/src/react/components/ai/chat/components/message-feedback.d.ts.map +0 -1
- package/esm/src/react/components/ai/chat/components/quick-actions.d.ts.map +0 -1
- package/esm/src/react/components/ai/chat/components/reasoning.d.ts.map +0 -1
- package/esm/src/react/components/ai/chat/components/sidebar.d.ts.map +0 -1
- package/esm/src/react/components/ai/chat/components/skill-badge.d.ts.map +0 -1
- package/esm/src/react/components/ai/chat/components/sources.d.ts.map +0 -1
- package/esm/src/react/components/ai/chat/components/step-indicator.d.ts.map +0 -1
- package/esm/src/react/components/ai/chat/components/tab-switcher.d.ts.map +0 -1
- package/esm/src/react/components/ai/chat/components/tool-ui.d.ts.map +0 -1
- package/esm/src/react/components/ai/chat/components/upgrade-cta.d.ts.map +0 -1
- package/esm/src/react/components/ai/chat/components/uploads-panel.d.ts.map +0 -1
- package/esm/src/react/components/ai/chat/composition/api.d.ts.map +0 -1
- package/esm/src/react/components/ai/chat/composition/chat-composer.d.ts.map +0 -1
- package/esm/src/react/components/ai/chat/composition/chat-empty.d.ts.map +0 -1
- package/esm/src/react/components/ai/chat/composition/chat-if.d.ts.map +0 -1
- package/esm/src/react/components/ai/chat/composition/chat-message-list.d.ts.map +0 -1
- package/esm/src/react/components/ai/chat/composition/chat-root.d.ts.map +0 -1
- package/esm/src/react/components/ai/chat/composition/error-banner.d.ts.map +0 -1
- package/esm/src/react/components/ai/chat/composition/message.d.ts.map +0 -1
- package/esm/src/react/components/ai/chat/composition/model-avatar.d.ts.map +0 -1
- package/esm/src/react/components/ai/chat/contexts/chat-context.d.ts.map +0 -1
- package/esm/src/react/components/ai/chat/contexts/composer-context.d.ts.map +0 -1
- package/esm/src/react/components/ai/chat/contexts/index.d.ts.map +0 -1
- package/esm/src/react/components/ai/chat/contexts/message-context.d.ts.map +0 -1
- package/esm/src/react/components/ai/chat/contexts/thread-list-context.d.ts.map +0 -1
- package/esm/src/react/components/ai/chat/hooks/use-threads.d.ts.map +0 -1
- package/esm/src/react/components/ai/chat/index.d.ts.map +0 -1
- package/esm/src/react/components/ai/chat/utils/export.d.ts +0 -10
- package/esm/src/react/components/ai/chat/utils/export.d.ts.map +0 -1
- package/esm/src/react/components/ai/chat/utils/message-parts.d.ts.map +0 -1
- package/esm/src/react/components/ai/chat-with-sidebar.d.ts.map +0 -1
- package/esm/src/react/components/ai/chat.d.ts.map +0 -1
- package/esm/src/react/components/ai/csp-nonce.d.ts.map +0 -1
- package/esm/src/react/components/ai/error-boundary.d.ts.map +0 -1
- package/esm/src/react/components/ai/icons/index.d.ts.map +0 -1
- package/esm/src/react/components/ai/markdown.d.ts.map +0 -1
- package/esm/src/react/components/ai/message.d.ts.map +0 -1
- package/esm/src/react/components/ai/model-selector.d.ts.map +0 -1
- package/esm/src/react/components/ai/theme.d.ts.map +0 -1
- /package/esm/src/agent/{ai-defaults.js → defaults.js} +0 -0
- /package/esm/src/react/components/{ai → chat}/agent-card.d.ts +0 -0
- /package/esm/src/react/components/{ai → chat}/agent-card.js +0 -0
- /package/esm/src/react/components/{ai → chat}/chat/components/animations.d.ts +0 -0
- /package/esm/src/react/components/{ai → chat}/chat/components/animations.js +0 -0
- /package/esm/src/react/components/{ai → chat}/chat/components/attachment-pill.d.ts +0 -0
- /package/esm/src/react/components/{ai → chat}/chat/components/attachment-pill.js +0 -0
- /package/esm/src/react/components/{ai → chat}/chat/components/branch-picker.d.ts +0 -0
- /package/esm/src/react/components/{ai → chat}/chat/components/branch-picker.js +0 -0
- /package/esm/src/react/components/{ai → chat}/chat/components/code-block.d.ts +0 -0
- /package/esm/src/react/components/{ai → chat}/chat/components/code-block.js +0 -0
- /package/esm/src/react/components/{ai → chat}/chat/components/drop-zone.d.ts +0 -0
- /package/esm/src/react/components/{ai → chat}/chat/components/drop-zone.js +0 -0
- /package/esm/src/react/components/{ai → chat}/chat/components/empty-state.d.ts +0 -0
- /package/esm/src/react/components/{ai → chat}/chat/components/empty-state.js +0 -0
- /package/esm/src/react/components/{ai → chat}/chat/components/inference-badge.d.ts +0 -0
- /package/esm/src/react/components/{ai → chat}/chat/components/inline-citation.d.ts +0 -0
- /package/esm/src/react/components/{ai → chat}/chat/components/inline-citation.js +0 -0
- /package/esm/src/react/components/{ai → chat}/chat/components/message-actions.d.ts +0 -0
- /package/esm/src/react/components/{ai → chat}/chat/components/message-actions.js +0 -0
- /package/esm/src/react/components/{ai → chat}/chat/components/message-edit-form.d.ts +0 -0
- /package/esm/src/react/components/{ai → chat}/chat/components/message-edit-form.js +0 -0
- /package/esm/src/react/components/{ai → chat}/chat/components/message-feedback.d.ts +0 -0
- /package/esm/src/react/components/{ai → chat}/chat/components/message-feedback.js +0 -0
- /package/esm/src/react/components/{ai → chat}/chat/components/quick-actions.d.ts +0 -0
- /package/esm/src/react/components/{ai → chat}/chat/components/quick-actions.js +0 -0
- /package/esm/src/react/components/{ai → chat}/chat/components/reasoning.d.ts +0 -0
- /package/esm/src/react/components/{ai → chat}/chat/components/reasoning.js +0 -0
- /package/esm/src/react/components/{ai → chat}/chat/components/sidebar.d.ts +0 -0
- /package/esm/src/react/components/{ai → chat}/chat/components/sidebar.js +0 -0
- /package/esm/src/react/components/{ai → chat}/chat/components/sources.d.ts +0 -0
- /package/esm/src/react/components/{ai → chat}/chat/components/sources.js +0 -0
- /package/esm/src/react/components/{ai → chat}/chat/components/step-indicator.d.ts +0 -0
- /package/esm/src/react/components/{ai → chat}/chat/components/step-indicator.js +0 -0
- /package/esm/src/react/components/{ai → chat}/chat/components/tab-switcher.d.ts +0 -0
- /package/esm/src/react/components/{ai → chat}/chat/components/tab-switcher.js +0 -0
- /package/esm/src/react/components/{ai → chat}/chat/components/upgrade-cta.d.ts +0 -0
- /package/esm/src/react/components/{ai → chat}/chat/components/upgrade-cta.js +0 -0
- /package/esm/src/react/components/{ai → chat}/chat/components/uploads-panel.d.ts +0 -0
- /package/esm/src/react/components/{ai → chat}/chat/components/uploads-panel.js +0 -0
- /package/esm/src/react/components/{ai → chat}/chat/hooks/use-threads.js +0 -0
- /package/esm/src/react/components/{ai → chat}/chat-with-sidebar.d.ts +0 -0
- /package/esm/src/react/components/{ai → chat}/chat-with-sidebar.js +0 -0
- /package/esm/src/react/components/{ai → chat}/csp-nonce.d.ts +0 -0
- /package/esm/src/react/components/{ai → chat}/csp-nonce.js +0 -0
- /package/esm/src/react/components/{ai → chat}/markdown.d.ts +0 -0
- /package/esm/src/react/components/{ai → chat}/markdown.js +0 -0
- /package/esm/src/react/components/{ai → chat}/message.js +0 -0
- /package/esm/src/react/components/{ai → chat}/model-selector.d.ts +0 -0
- /package/esm/src/react/components/{ai → chat}/model-selector.js +0 -0
- /package/esm/src/react/components/{ai → chat}/theme.d.ts +0 -0
- /package/esm/src/react/components/{ai → chat}/theme.js +0 -0
- /package/esm/src/{ai/registry-facade.js → registry/scoped-registry-facade.js} +0 -0
- /package/src/src/agent/{ai-defaults.ts → defaults.ts} +0 -0
- /package/src/src/react/components/{ai → chat}/agent-card.tsx +0 -0
- /package/src/src/react/components/{ai → chat}/chat/components/animations.tsx +0 -0
- /package/src/src/react/components/{ai → chat}/chat/components/attachment-pill.tsx +0 -0
- /package/src/src/react/components/{ai → chat}/chat/components/branch-picker.tsx +0 -0
- /package/src/src/react/components/{ai → chat}/chat/components/code-block.tsx +0 -0
- /package/src/src/react/components/{ai → chat}/chat/components/drop-zone.tsx +0 -0
- /package/src/src/react/components/{ai → chat}/chat/components/empty-state.tsx +0 -0
- /package/src/src/react/components/{ai → chat}/chat/components/inline-citation.tsx +0 -0
- /package/src/src/react/components/{ai → chat}/chat/components/message-actions.tsx +0 -0
- /package/src/src/react/components/{ai → chat}/chat/components/message-edit-form.tsx +0 -0
- /package/src/src/react/components/{ai → chat}/chat/components/message-feedback.tsx +0 -0
- /package/src/src/react/components/{ai → chat}/chat/components/quick-actions.tsx +0 -0
- /package/src/src/react/components/{ai → chat}/chat/components/reasoning.tsx +0 -0
- /package/src/src/react/components/{ai → chat}/chat/components/sidebar.tsx +0 -0
- /package/src/src/react/components/{ai → chat}/chat/components/sources.tsx +0 -0
- /package/src/src/react/components/{ai → chat}/chat/components/step-indicator.tsx +0 -0
- /package/src/src/react/components/{ai → chat}/chat/components/tab-switcher.tsx +0 -0
- /package/src/src/react/components/{ai → chat}/chat/components/upgrade-cta.tsx +0 -0
- /package/src/src/react/components/{ai → chat}/chat/components/uploads-panel.tsx +0 -0
- /package/src/src/react/components/{ai → chat}/chat-with-sidebar.tsx +0 -0
- /package/src/src/react/components/{ai → chat}/csp-nonce.ts +0 -0
- /package/src/src/react/components/{ai → chat}/markdown.tsx +0 -0
- /package/src/src/react/components/{ai → chat}/model-selector.tsx +0 -0
- /package/src/src/react/components/{ai → chat}/theme.ts +0 -0
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
type ErrorWithName = {
|
|
2
|
+
name: string;
|
|
3
|
+
};
|
|
4
|
+
type InvalidToolInputErrorShape = ErrorWithName & {
|
|
5
|
+
toolInput: unknown;
|
|
6
|
+
toolName: string;
|
|
7
|
+
};
|
|
8
|
+
export declare function isInvalidToolInputError(error: unknown): error is InvalidToolInputErrorShape;
|
|
9
|
+
export declare function isNoSuchToolError(error: unknown): boolean;
|
|
10
|
+
export declare function createInvalidToolInputErrorForTest(options: {
|
|
11
|
+
cause: Error;
|
|
12
|
+
toolInput: string;
|
|
13
|
+
toolName: string;
|
|
14
|
+
}): unknown;
|
|
15
|
+
export {};
|
|
16
|
+
//# sourceMappingURL=runtime-tool-errors.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"runtime-tool-errors.d.ts","sourceRoot":"","sources":["../../../../src/src/agent/runtime/runtime-tool-errors.ts"],"names":[],"mappings":"AAGA,KAAK,aAAa,GAAG;IACnB,IAAI,EAAE,MAAM,CAAC;CACd,CAAC;AAEF,KAAK,0BAA0B,GAAG,aAAa,GAAG;IAChD,SAAS,EAAE,OAAO,CAAC;IACnB,QAAQ,EAAE,MAAM,CAAC;CAClB,CAAC;AASF,wBAAgB,uBAAuB,CAAC,KAAK,EAAE,OAAO,GAAG,KAAK,IAAI,0BAA0B,CAK3F;AAED,wBAAgB,iBAAiB,CAAC,KAAK,EAAE,OAAO,GAAG,OAAO,CAIzD;AAED,wBAAgB,kCAAkC,CAAC,OAAO,EAAE;IAC1D,KAAK,EAAE,KAAK,CAAC;IACb,SAAS,EAAE,MAAM,CAAC;IAClB,QAAQ,EAAE,MAAM,CAAC;CAClB,GAAG,OAAO,CASV"}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
const INVALID_TOOL_INPUT_ERROR_NAME = "AI_InvalidToolInputError";
|
|
2
|
+
const NO_SUCH_TOOL_ERROR_NAME = "AI_NoSuchToolError";
|
|
3
|
+
function isErrorWithName(error, expectedName) {
|
|
4
|
+
return !!error &&
|
|
5
|
+
typeof error === "object" &&
|
|
6
|
+
"name" in error &&
|
|
7
|
+
error.name === expectedName;
|
|
8
|
+
}
|
|
9
|
+
export function isInvalidToolInputError(error) {
|
|
10
|
+
return isErrorWithName(error, INVALID_TOOL_INPUT_ERROR_NAME) &&
|
|
11
|
+
"toolName" in error &&
|
|
12
|
+
typeof error.toolName === "string" &&
|
|
13
|
+
"toolInput" in error;
|
|
14
|
+
}
|
|
15
|
+
export function isNoSuchToolError(error) {
|
|
16
|
+
return isErrorWithName(error, NO_SUCH_TOOL_ERROR_NAME) &&
|
|
17
|
+
"toolName" in error &&
|
|
18
|
+
typeof error.toolName === "string";
|
|
19
|
+
}
|
|
20
|
+
export function createInvalidToolInputErrorForTest(options) {
|
|
21
|
+
const error = new Error(`Invalid input for tool ${options.toolName}: ${options.cause.message}`);
|
|
22
|
+
error.name = INVALID_TOOL_INPUT_ERROR_NAME;
|
|
23
|
+
return Object.assign(error, {
|
|
24
|
+
cause: options.cause,
|
|
25
|
+
toolInput: options.toolInput,
|
|
26
|
+
toolName: options.toolName,
|
|
27
|
+
});
|
|
28
|
+
}
|
|
@@ -0,0 +1,104 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Runtime Tool Types
|
|
3
|
+
*
|
|
4
|
+
* Framework-owned types for the current tool-calling and streaming runtime
|
|
5
|
+
* boundary. These cover only the shapes the framework consumes today.
|
|
6
|
+
*/
|
|
7
|
+
import type { ModelRuntimeMessage } from "./model-runtime-types.js";
|
|
8
|
+
export type RuntimeToolSet = Record<string, unknown>;
|
|
9
|
+
export interface RuntimeGenerateToolCall {
|
|
10
|
+
toolCallId: string;
|
|
11
|
+
toolName: string;
|
|
12
|
+
input: unknown;
|
|
13
|
+
}
|
|
14
|
+
export interface RuntimeGenerateToolResult {
|
|
15
|
+
toolCallId: string;
|
|
16
|
+
toolName: string;
|
|
17
|
+
result: unknown;
|
|
18
|
+
isError?: boolean;
|
|
19
|
+
}
|
|
20
|
+
export interface RuntimeGenerateUsage {
|
|
21
|
+
inputTokens?: number;
|
|
22
|
+
outputTokens?: number;
|
|
23
|
+
totalTokens?: number;
|
|
24
|
+
}
|
|
25
|
+
export interface RuntimeGenerateTextResult {
|
|
26
|
+
text: string;
|
|
27
|
+
toolCalls?: RuntimeGenerateToolCall[];
|
|
28
|
+
toolResults?: RuntimeGenerateToolResult[];
|
|
29
|
+
usage?: RuntimeGenerateUsage;
|
|
30
|
+
finishReason?: string | null;
|
|
31
|
+
}
|
|
32
|
+
export interface RuntimeRepairToolCall {
|
|
33
|
+
type: "tool-call";
|
|
34
|
+
toolCallId: string;
|
|
35
|
+
toolName: string;
|
|
36
|
+
input: unknown;
|
|
37
|
+
providerExecuted?: boolean;
|
|
38
|
+
}
|
|
39
|
+
export interface RuntimeToolCallRepairContext {
|
|
40
|
+
error: unknown;
|
|
41
|
+
inputSchema: (...args: unknown[]) => unknown;
|
|
42
|
+
messages: ModelRuntimeMessage[];
|
|
43
|
+
system?: string;
|
|
44
|
+
toolCall: RuntimeRepairToolCall;
|
|
45
|
+
tools: RuntimeToolSet;
|
|
46
|
+
}
|
|
47
|
+
export type RuntimeToolCallRepairFunction = (context: RuntimeToolCallRepairContext) => Promise<RuntimeRepairToolCall | null> | RuntimeRepairToolCall | null;
|
|
48
|
+
export type RuntimeStreamPart = {
|
|
49
|
+
type: "text-delta";
|
|
50
|
+
text: string;
|
|
51
|
+
} | {
|
|
52
|
+
type: "tool-input-start";
|
|
53
|
+
id: string;
|
|
54
|
+
toolName: string;
|
|
55
|
+
providerExecuted?: boolean;
|
|
56
|
+
dynamic?: boolean;
|
|
57
|
+
} | {
|
|
58
|
+
type: "tool-input-delta";
|
|
59
|
+
id: string;
|
|
60
|
+
delta: string;
|
|
61
|
+
} | {
|
|
62
|
+
type: "tool-call";
|
|
63
|
+
toolCallId: string;
|
|
64
|
+
toolName: string;
|
|
65
|
+
input: unknown;
|
|
66
|
+
providerExecuted?: boolean;
|
|
67
|
+
dynamic?: boolean;
|
|
68
|
+
} | {
|
|
69
|
+
type: "tool-result";
|
|
70
|
+
toolCallId: string;
|
|
71
|
+
toolName: string;
|
|
72
|
+
output?: unknown;
|
|
73
|
+
error?: unknown;
|
|
74
|
+
input?: unknown;
|
|
75
|
+
providerExecuted?: boolean;
|
|
76
|
+
dynamic?: boolean;
|
|
77
|
+
preliminary?: boolean;
|
|
78
|
+
isError?: boolean;
|
|
79
|
+
} | {
|
|
80
|
+
type: "tool-error";
|
|
81
|
+
toolCallId: string;
|
|
82
|
+
toolName: string;
|
|
83
|
+
error?: unknown;
|
|
84
|
+
input?: unknown;
|
|
85
|
+
providerExecuted?: boolean;
|
|
86
|
+
dynamic?: boolean;
|
|
87
|
+
preliminary?: boolean;
|
|
88
|
+
isError?: boolean;
|
|
89
|
+
} | {
|
|
90
|
+
type: "finish";
|
|
91
|
+
finishReason?: string | null;
|
|
92
|
+
totalUsage?: {
|
|
93
|
+
inputTokens?: number;
|
|
94
|
+
outputTokens?: number;
|
|
95
|
+
} | null;
|
|
96
|
+
} | {
|
|
97
|
+
type: "error";
|
|
98
|
+
error: unknown;
|
|
99
|
+
};
|
|
100
|
+
export interface RuntimeStreamResult {
|
|
101
|
+
fullStream: AsyncIterable<unknown>;
|
|
102
|
+
textStream: AsyncIterable<string>;
|
|
103
|
+
}
|
|
104
|
+
//# sourceMappingURL=runtime-tool-types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"runtime-tool-types.d.ts","sourceRoot":"","sources":["../../../../src/src/agent/runtime/runtime-tool-types.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,0BAA0B,CAAC;AAEpE,MAAM,MAAM,cAAc,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;AAErD,MAAM,WAAW,uBAAuB;IAC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B,OAAO,CAAC,EAAE,OAAO,CAAC;CACnB,GACC;IACA,IAAI,EAAE,QAAQ,CAAC;IACf,YAAY,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAC7B,UAAU,CAAC,EAAE;QACX,WAAW,CAAC,EAAE,MAAM,CAAC;QACrB,YAAY,CAAC,EAAE,MAAM,CAAC;KACvB,GAAG,IAAI,CAAC;CACV,GACC;IAAE,IAAI,EAAE,OAAO,CAAC;IAAC,KAAK,EAAE,OAAO,CAAA;CAAE,CAAC;AAEtC,MAAM,WAAW,mBAAmB;IAClC,UAAU,EAAE,aAAa,CAAC,OAAO,CAAC,CAAC;IACnC,UAAU,EAAE,aAAa,CAAC,MAAM,CAAC,CAAC;CACnC"}
|
package/esm/src/chat/index.d.ts
CHANGED
|
@@ -48,15 +48,15 @@
|
|
|
48
48
|
* ```
|
|
49
49
|
*/
|
|
50
50
|
import "../../_dnt.polyfills.js";
|
|
51
|
-
export { Chat, ChatComponents, type ChatProps } from "../react/components/
|
|
52
|
-
export { ChatComposer, type ChatComposerProps, ChatEmpty, type ChatEmptyProps, ChatIf, type ChatIfProps, ChatMessageList, type ChatMessageListProps, ChatRoot, type ChatRootProps, ErrorBanner, type ErrorBannerProps, Message, type MessageRootProps, ModelAvatar, type ModelAvatarProps, } from "../react/components/
|
|
53
|
-
export { ChatContextProvider, type ChatContextValue, ComposerContextProvider, type ComposerContextValue, MessageContextProvider, type MessageContextValue, ThreadListContextProvider, type ThreadListContextValue, useChatContext, useChatContextOptional, useComposerContext, useComposerContextOptional, useMessageContext, useMessageContextOptional, useThreadListContext, useThreadListContextOptional, } from "../react/components/
|
|
54
|
-
export { type AttachmentInfo, AttachmentPill, type AttachmentPillProps, BranchPicker, type BranchPickerProps, ChatSidebar, type ChatSidebarProps, type ChatTab, ChatWithSidebar, type ChatWithSidebarAttachmentConfig, type ChatWithSidebarChatController, type ChatWithSidebarFeatureConfig, type ChatWithSidebarGroupedProps, type ChatWithSidebarMessageConfig, type ChatWithSidebarModelConfig, type ChatWithSidebarProps, type ChatWithSidebarQuickActionsConfig, type ChatWithSidebarSidebarConfig, type ChatWithSidebarTabsConfig, type ChatWithSidebarVoiceConfig, type CodeBlockProps, ConversationEmptyState, type ConversationEmptyStateProps, ConversationScrollButton, type ConversationScrollButtonProps, downloadMarkdown, DropZoneOverlay, type DropZoneOverlayProps, exportAsMarkdown, extractSourcesFromParts, FadeIn, type FeedbackValue, getTextContent, groupPartsInOrder, InferenceBadge, type InferenceBadgeProps, InlineCitation, type InlineCitationProps, isReasoningPart, isSkillToolPart, isToolPart, Loader, MessageActions, type MessageActionsProps, MessageEditForm, type MessageEditFormProps, MessageFeedback, type MessageFeedbackProps, type ModelOption, ModelSelector, type ModelSelectorProps, type PartGroup, type QuickAction, QuickActions, type QuickActionsProps, ReasoningCard, RichCodeBlock, Shimmer, SkillBadge, type SkillBadgeProps, type Source, Sources, type SourcesProps, StepIndicator, type StepIndicatorProps, Suggestion, type SuggestionProps, Suggestions, type SuggestionsProps, TabSwitcher, type TabSwitcherProps, type Thread, ToolCallCard, ToolStatusBadge, UpgradeCTA, type UpgradeCTAProps, type UploadedFile, UploadsPanel, type UploadsPanelProps, useThreads, type UseThreadsOptions, type UseThreadsResult, } from "../react/components/
|
|
55
|
-
export { Message as StandaloneMessage, type MessageProps, StreamingMessage, type StreamingMessageProps, } from "../react/components/
|
|
56
|
-
export { AgentCard, type AgentCardProps } from "../react/components/
|
|
57
|
-
export {
|
|
58
|
-
export type { AgentTheme, ChatTheme } from "../react/components/
|
|
59
|
-
export { type BranchInfo, type BrowserInferenceStatus, type
|
|
51
|
+
export { Chat, ChatComponents, type ChatProps } from "../react/components/chat/chat.js";
|
|
52
|
+
export { ChatComposer, type ChatComposerProps, ChatEmpty, type ChatEmptyProps, ChatIf, type ChatIfProps, ChatMessageList, type ChatMessageListProps, ChatRoot, type ChatRootProps, ErrorBanner, type ErrorBannerProps, Message, type MessageRootProps, ModelAvatar, type ModelAvatarProps, } from "../react/components/chat/chat.js";
|
|
53
|
+
export { ChatContextProvider, type ChatContextValue, ComposerContextProvider, type ComposerContextValue, MessageContextProvider, type MessageContextValue, ThreadListContextProvider, type ThreadListContextValue, useChatContext, useChatContextOptional, useComposerContext, useComposerContextOptional, useMessageContext, useMessageContextOptional, useThreadListContext, useThreadListContextOptional, } from "../react/components/chat/chat.js";
|
|
54
|
+
export { type AttachmentInfo, AttachmentPill, type AttachmentPillProps, BranchPicker, type BranchPickerProps, ChatSidebar, type ChatSidebarProps, type ChatTab, ChatWithSidebar, type ChatWithSidebarAttachmentConfig, type ChatWithSidebarChatController, type ChatWithSidebarFeatureConfig, type ChatWithSidebarGroupedProps, type ChatWithSidebarMessageConfig, type ChatWithSidebarModelConfig, type ChatWithSidebarProps, type ChatWithSidebarQuickActionsConfig, type ChatWithSidebarSidebarConfig, type ChatWithSidebarTabsConfig, type ChatWithSidebarVoiceConfig, type CodeBlockProps, ConversationEmptyState, type ConversationEmptyStateProps, ConversationScrollButton, type ConversationScrollButtonProps, downloadMarkdown, DropZoneOverlay, type DropZoneOverlayProps, exportAsMarkdown, extractSourcesFromParts, FadeIn, type FeedbackValue, getTextContent, groupPartsInOrder, InferenceBadge, type InferenceBadgeProps, InlineCitation, type InlineCitationProps, isReasoningPart, isSkillToolPart, isToolPart, Loader, MessageActions, type MessageActionsProps, MessageEditForm, type MessageEditFormProps, MessageFeedback, type MessageFeedbackProps, type ModelOption, ModelSelector, type ModelSelectorProps, type PartGroup, type QuickAction, QuickActions, type QuickActionsProps, ReasoningCard, RichCodeBlock, Shimmer, SkillBadge, type SkillBadgeProps, type Source, Sources, type SourcesProps, StepIndicator, type StepIndicatorProps, Suggestion, type SuggestionProps, Suggestions, type SuggestionsProps, TabSwitcher, type TabSwitcherProps, type Thread, ToolCallCard, ToolStatusBadge, UpgradeCTA, type UpgradeCTAProps, type UploadedFile, UploadsPanel, type UploadsPanelProps, useThreads, type UseThreadsOptions, type UseThreadsResult, } from "../react/components/chat/chat.js";
|
|
55
|
+
export { Message as StandaloneMessage, type MessageProps, StreamingMessage, type StreamingMessageProps, } from "../react/components/chat/message.js";
|
|
56
|
+
export { AgentCard, type AgentCardProps } from "../react/components/chat/agent-card.js";
|
|
57
|
+
export { ChatErrorBoundary, type ChatErrorBoundaryProps, useChatErrorHandler, } from "../react/components/chat/error-boundary.js";
|
|
58
|
+
export type { AgentTheme, ChatTheme } from "../react/components/chat/theme.js";
|
|
59
|
+
export { type BranchInfo, type BrowserInferenceStatus, type ChatDynamicToolPart, type ChatFinishReason, type ChatMessage, type ChatMessagePart, type ChatReasoningPart, type ChatStepPart, type ChatStreamEvent, type ChatTextPart, type ChatToolPart, type ChatToolResultPart, type ChatToolState, type InferenceMode, type OnToolCallArg, type ToolOutput, useChat, type UseChatOptions, type UseChatResult, } from "../agent/react/use-chat/index.js";
|
|
60
60
|
export { useAgent, type UseAgentOptions, type UseAgentResult, } from "../agent/react/use-agent.js";
|
|
61
61
|
export { useCompletion, type UseCompletionOptions, type UseCompletionResult, } from "../agent/react/use-completion.js";
|
|
62
62
|
export { useStreaming, type UseStreamingOptions, type UseStreamingResult, } from "../agent/react/use-streaming.js";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/src/chat/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAgDG;AACH,OAAO,yBAAyB,CAAC;AAGjC,OAAO,EAAE,IAAI,EAAE,cAAc,EAAE,KAAK,SAAS,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/src/chat/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAgDG;AACH,OAAO,yBAAyB,CAAC;AAGjC,OAAO,EAAE,IAAI,EAAE,cAAc,EAAE,KAAK,SAAS,EAAE,MAAM,kCAAkC,CAAC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ACjB,KAAK,YAAY,EACjB,KAAK,kBAAkB,EACvB,KAAK,aAAa,EAClB,KAAK,aAAa,EAClB,KAAK,aAAa,EAClB,KAAK,UAAU,EACf,OAAO,EACP,KAAK,cAAc,EACnB,KAAK,aAAa,GACnB,MAAM,kCAAkC,CAAC;AAE1C,OAAO,EACL,QAAQ,EACR,KAAK,eAAe,EACpB,KAAK,cAAc,GACpB,MAAM,6BAA6B,CAAC;AAErC,OAAO,EACL,aAAa,EACb,KAAK,oBAAoB,EACzB,KAAK,mBAAmB,GACzB,MAAM,kCAAkC,CAAC;AAE1C,OAAO,EACL,YAAY,EACZ,KAAK,mBAAmB,EACxB,KAAK,kBAAkB,GACxB,MAAM,iCAAiC,CAAC;AAEzC,OAAO,EACL,aAAa,EACb,KAAK,oBAAoB,EACzB,KAAK,mBAAmB,GACzB,MAAM,mCAAmC,CAAC"}
|
package/esm/src/chat/index.js
CHANGED
|
@@ -48,13 +48,13 @@
|
|
|
48
48
|
* ```
|
|
49
49
|
*/
|
|
50
50
|
import "../../_dnt.polyfills.js";
|
|
51
|
-
export { Chat, ChatComponents } from "../react/components/
|
|
52
|
-
export { ChatComposer, ChatEmpty, ChatIf, ChatMessageList, ChatRoot, ErrorBanner, Message, ModelAvatar, } from "../react/components/
|
|
53
|
-
export { ChatContextProvider, ComposerContextProvider, MessageContextProvider, ThreadListContextProvider, useChatContext, useChatContextOptional, useComposerContext, useComposerContextOptional, useMessageContext, useMessageContextOptional, useThreadListContext, useThreadListContextOptional, } from "../react/components/
|
|
54
|
-
export { AttachmentPill, BranchPicker, ChatSidebar, ChatWithSidebar, ConversationEmptyState, ConversationScrollButton, downloadMarkdown, DropZoneOverlay, exportAsMarkdown, extractSourcesFromParts, FadeIn, getTextContent, groupPartsInOrder, InferenceBadge, InlineCitation, isReasoningPart, isSkillToolPart, isToolPart, Loader, MessageActions, MessageEditForm, MessageFeedback, ModelSelector, QuickActions, ReasoningCard, RichCodeBlock, Shimmer, SkillBadge, Sources, StepIndicator, Suggestion, Suggestions, TabSwitcher, ToolCallCard, ToolStatusBadge, UpgradeCTA, UploadsPanel, useThreads, } from "../react/components/
|
|
55
|
-
export { Message as StandaloneMessage, StreamingMessage, } from "../react/components/
|
|
56
|
-
export { AgentCard } from "../react/components/
|
|
57
|
-
export {
|
|
51
|
+
export { Chat, ChatComponents } from "../react/components/chat/chat.js";
|
|
52
|
+
export { ChatComposer, ChatEmpty, ChatIf, ChatMessageList, ChatRoot, ErrorBanner, Message, ModelAvatar, } from "../react/components/chat/chat.js";
|
|
53
|
+
export { ChatContextProvider, ComposerContextProvider, MessageContextProvider, ThreadListContextProvider, useChatContext, useChatContextOptional, useComposerContext, useComposerContextOptional, useMessageContext, useMessageContextOptional, useThreadListContext, useThreadListContextOptional, } from "../react/components/chat/chat.js";
|
|
54
|
+
export { AttachmentPill, BranchPicker, ChatSidebar, ChatWithSidebar, ConversationEmptyState, ConversationScrollButton, downloadMarkdown, DropZoneOverlay, exportAsMarkdown, extractSourcesFromParts, FadeIn, getTextContent, groupPartsInOrder, InferenceBadge, InlineCitation, isReasoningPart, isSkillToolPart, isToolPart, Loader, MessageActions, MessageEditForm, MessageFeedback, ModelSelector, QuickActions, ReasoningCard, RichCodeBlock, Shimmer, SkillBadge, Sources, StepIndicator, Suggestion, Suggestions, TabSwitcher, ToolCallCard, ToolStatusBadge, UpgradeCTA, UploadsPanel, useThreads, } from "../react/components/chat/chat.js";
|
|
55
|
+
export { Message as StandaloneMessage, StreamingMessage, } from "../react/components/chat/message.js";
|
|
56
|
+
export { AgentCard } from "../react/components/chat/agent-card.js";
|
|
57
|
+
export { ChatErrorBoundary, useChatErrorHandler, } from "../react/components/chat/error-boundary.js";
|
|
58
58
|
export { useChat, } from "../agent/react/use-chat/index.js";
|
|
59
59
|
export { useAgent, } from "../agent/react/use-agent.js";
|
|
60
60
|
export { useCompletion, } from "../agent/react/use-completion.js";
|
|
@@ -0,0 +1,156 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Canonical chat message and stream protocol for Veryfront chat surfaces.
|
|
3
|
+
*
|
|
4
|
+
* These types describe the framework-owned message parts and stream events used
|
|
5
|
+
* by AG-UI-aligned chat clients, hooks, and adapters.
|
|
6
|
+
*/
|
|
7
|
+
import "../../_dnt.polyfills.js";
|
|
8
|
+
export type ChatPartState = "streaming" | "done";
|
|
9
|
+
export interface ChatTextPart {
|
|
10
|
+
type: "text";
|
|
11
|
+
text: string;
|
|
12
|
+
state?: ChatPartState;
|
|
13
|
+
}
|
|
14
|
+
export interface ChatReasoningPart {
|
|
15
|
+
type: "reasoning";
|
|
16
|
+
text: string;
|
|
17
|
+
state?: ChatPartState;
|
|
18
|
+
}
|
|
19
|
+
export type ChatToolState = "input-streaming" | "input-available" | "output-streaming" | "output-available" | "output-error";
|
|
20
|
+
export interface ChatToolPart<NAME extends string = string, INPUT = unknown, OUTPUT = unknown> {
|
|
21
|
+
type: `tool-${NAME}`;
|
|
22
|
+
toolCallId: string;
|
|
23
|
+
toolName: NAME;
|
|
24
|
+
state: ChatToolState;
|
|
25
|
+
input?: INPUT;
|
|
26
|
+
output?: OUTPUT;
|
|
27
|
+
errorText?: string;
|
|
28
|
+
}
|
|
29
|
+
export interface ChatToolResultPart<RESULT = unknown> {
|
|
30
|
+
type: "tool-result";
|
|
31
|
+
toolCallId: string;
|
|
32
|
+
toolName: string;
|
|
33
|
+
result: RESULT;
|
|
34
|
+
isError?: boolean;
|
|
35
|
+
}
|
|
36
|
+
export interface ChatDynamicToolPart {
|
|
37
|
+
type: "dynamic-tool";
|
|
38
|
+
toolCallId: string;
|
|
39
|
+
toolName: string;
|
|
40
|
+
state: ChatToolState;
|
|
41
|
+
input?: unknown;
|
|
42
|
+
output?: unknown;
|
|
43
|
+
errorText?: string;
|
|
44
|
+
}
|
|
45
|
+
export interface ChatStepPart {
|
|
46
|
+
type: "step-start" | "step-end";
|
|
47
|
+
stepIndex: number;
|
|
48
|
+
}
|
|
49
|
+
export type ChatMessagePart = ChatTextPart | ChatReasoningPart | ChatToolPart | ChatToolResultPart | ChatDynamicToolPart | ChatStepPart;
|
|
50
|
+
export interface ChatMessage {
|
|
51
|
+
id: string;
|
|
52
|
+
role: "system" | "user" | "assistant";
|
|
53
|
+
parts: ChatMessagePart[];
|
|
54
|
+
metadata?: Record<string, unknown>;
|
|
55
|
+
createdAt?: Date | string;
|
|
56
|
+
}
|
|
57
|
+
export type ChatFinishReason = "stop" | "length" | "tool-calls" | "content-filter" | "error" | "other";
|
|
58
|
+
type ChatStreamEventBase = {
|
|
59
|
+
providerExecuted?: boolean;
|
|
60
|
+
dynamic?: boolean;
|
|
61
|
+
};
|
|
62
|
+
export type ChatStreamEvent = {
|
|
63
|
+
type: "start";
|
|
64
|
+
messageId?: string;
|
|
65
|
+
messageMetadata?: unknown;
|
|
66
|
+
} | {
|
|
67
|
+
type: "message-metadata";
|
|
68
|
+
messageMetadata: unknown;
|
|
69
|
+
} | {
|
|
70
|
+
type: "text-start";
|
|
71
|
+
id: string;
|
|
72
|
+
} | {
|
|
73
|
+
type: "text-delta";
|
|
74
|
+
id: string;
|
|
75
|
+
delta: string;
|
|
76
|
+
} | {
|
|
77
|
+
type: "text-end";
|
|
78
|
+
id: string;
|
|
79
|
+
} | {
|
|
80
|
+
type: "reasoning-start";
|
|
81
|
+
id: string;
|
|
82
|
+
} | {
|
|
83
|
+
type: "reasoning-delta";
|
|
84
|
+
id: string;
|
|
85
|
+
delta: string;
|
|
86
|
+
} | {
|
|
87
|
+
type: "reasoning-end";
|
|
88
|
+
id: string;
|
|
89
|
+
} | ({
|
|
90
|
+
type: "tool-input-start";
|
|
91
|
+
toolCallId: string;
|
|
92
|
+
toolName: string;
|
|
93
|
+
} & ChatStreamEventBase) | ({
|
|
94
|
+
type: "tool-input-delta";
|
|
95
|
+
toolCallId: string;
|
|
96
|
+
inputTextDelta: string;
|
|
97
|
+
} & ChatStreamEventBase) | ({
|
|
98
|
+
type: "tool-input-available";
|
|
99
|
+
toolCallId: string;
|
|
100
|
+
toolName: string;
|
|
101
|
+
input: unknown;
|
|
102
|
+
} & ChatStreamEventBase) | ({
|
|
103
|
+
type: "tool-input-error";
|
|
104
|
+
toolCallId: string;
|
|
105
|
+
toolName: string;
|
|
106
|
+
input: unknown;
|
|
107
|
+
errorText: string;
|
|
108
|
+
} & ChatStreamEventBase) | {
|
|
109
|
+
type: "tool-approval-request";
|
|
110
|
+
approvalId: string;
|
|
111
|
+
toolCallId: string;
|
|
112
|
+
} | ({
|
|
113
|
+
type: "tool-output-available";
|
|
114
|
+
toolCallId: string;
|
|
115
|
+
output: unknown;
|
|
116
|
+
} & ChatStreamEventBase) | {
|
|
117
|
+
type: "tool-output-denied";
|
|
118
|
+
toolCallId: string;
|
|
119
|
+
} | ({
|
|
120
|
+
type: "tool-output-error";
|
|
121
|
+
toolCallId: string;
|
|
122
|
+
errorText: string;
|
|
123
|
+
} & ChatStreamEventBase) | {
|
|
124
|
+
type: "source-url";
|
|
125
|
+
sourceId: string;
|
|
126
|
+
url: string;
|
|
127
|
+
title?: string;
|
|
128
|
+
} | {
|
|
129
|
+
type: "source-document";
|
|
130
|
+
sourceId: string;
|
|
131
|
+
mediaType: string;
|
|
132
|
+
title: string;
|
|
133
|
+
filename?: string;
|
|
134
|
+
} | {
|
|
135
|
+
type: "file";
|
|
136
|
+
url: string;
|
|
137
|
+
mediaType: string;
|
|
138
|
+
filename?: string;
|
|
139
|
+
} | {
|
|
140
|
+
type: "start-step";
|
|
141
|
+
} | {
|
|
142
|
+
type: "finish-step";
|
|
143
|
+
} | {
|
|
144
|
+
type: `data-${string}`;
|
|
145
|
+
data: unknown;
|
|
146
|
+
} | {
|
|
147
|
+
type: "finish";
|
|
148
|
+
finishReason?: ChatFinishReason;
|
|
149
|
+
} | {
|
|
150
|
+
type: "abort";
|
|
151
|
+
} | {
|
|
152
|
+
type: "error";
|
|
153
|
+
errorText: string;
|
|
154
|
+
};
|
|
155
|
+
export {};
|
|
156
|
+
//# sourceMappingURL=protocol.d.ts.map
|
|
@@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CAAC;IACD,IAAI,EAAE,mBAAmB,CAAC;IAC1B,UAAU,EAAE,MAAM,CAAC;IACnB,SAAS,EAAE,MAAM,CAAC;CACnB,GAAG,mBAAmB,CAAC,GACtB;IACA,IAAI,EAAE,YAAY,CAAC;IACnB,QAAQ,EAAE,MAAM,CAAC;IACjB,GAAG,EAAE,MAAM,CAAC;IACZ,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB,GACC;IACA,IAAI,EAAE,iBAAiB,CAAC;IACxB,QAAQ,EAAE,MAAM,CAAC;IACjB,SAAS,EAAE,MAAM,CAAC;IAClB,KAAK,EAAE,MAAM,CAAC;IACd,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB,GACC;IACA,IAAI,EAAE,MAAM,CAAC;IACb,GAAG,EAAE,MAAM,CAAC;IACZ,SAAS,EAAE,MAAM,CAAC;IAClB,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB,GACC;IACA,IAAI,EAAE,YAAY,CAAC;CACpB,GACC;IACA,IAAI,EAAE,aAAa,CAAC;CACrB,GACC;IACA,IAAI,EAAE,QAAQ,MAAM,EAAE,CAAC;IACvB,IAAI,EAAE,OAAO,CAAC;CACf,GACC;IACA,IAAI,EAAE,QAAQ,CAAC;IACf,YAAY,CAAC,EAAE,gBAAgB,CAAC;CACjC,GACC;IACA,IAAI,EAAE,OAAO,CAAC;CACf,GACC;IACA,IAAI,EAAE,OAAO,CAAC;IACd,SAAS,EAAE,MAAM,CAAC;CACnB,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"import-rewriter.d.ts","sourceRoot":"","sources":["../../../src/src/discovery/import-rewriter.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAGH,OAAO,EAAE,gBAAgB,EAAE,MAAM,0BAA0B,CAAC;AAG5D;;;;;GAKG;AACH,wBAAgB,cAAc,CAAC,IAAI,EAAE,MAAM,EAAE,OAAO,EAAE,MAAM,GAAG,MAAM,
|
|
1
|
+
{"version":3,"file":"import-rewriter.d.ts","sourceRoot":"","sources":["../../../src/src/discovery/import-rewriter.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAGH,OAAO,EAAE,gBAAgB,EAAE,MAAM,0BAA0B,CAAC;AAG5D;;;;;GAKG;AACH,wBAAgB,cAAc,CAAC,IAAI,EAAE,MAAM,EAAE,OAAO,EAAE,MAAM,GAAG,MAAM,CAmDpE;AAED;;;;;GAKG;AACH,wBAAsB,uBAAuB,CAC3C,IAAI,EAAE,MAAM,EACZ,UAAU,EAAE,MAAM,EAClB,EAAE,EAAE,UAAU,CAAC,OAAO,gBAAgB,CAAC,EACvC,OAAO,EAAE,MAAM,GACd,OAAO,CAAC,MAAM,CAAC,CA+HjB"}
|
|
@@ -14,11 +14,7 @@ import * as pathHelper from "../platform/compat/path/index.js";
|
|
|
14
14
|
*/
|
|
15
15
|
export function rewriteForDeno(code, fileDir) {
|
|
16
16
|
const npmReplacements = [
|
|
17
|
-
[/from\s+["']ai["']/g, 'from "npm:ai"'],
|
|
18
|
-
[/from\s+["']ai\/([^"']+)["']/g, 'from "npm:ai/$1"'],
|
|
19
|
-
[/from\s+["']@ai-sdk\/([^"']+)["']/g, 'from "npm:@ai-sdk/$1"'],
|
|
20
17
|
[/from\s+["']zod["']/g, 'from "npm:zod"'],
|
|
21
|
-
[/import\s*\(\s*["']ai["']\s*\)/g, 'import("npm:ai")'],
|
|
22
18
|
[/import\s*\(\s*["']zod["']\s*\)/g, 'import("npm:zod")'],
|
|
23
19
|
];
|
|
24
20
|
let transformed = code;
|
|
@@ -104,16 +100,7 @@ export async function rewriteDiscoveryImports(code, projectDir, fs, fileDir) {
|
|
|
104
100
|
.replace(dynamicImportRegex, `import("${resolvedUrl}")`);
|
|
105
101
|
};
|
|
106
102
|
// Rewrite external package imports
|
|
107
|
-
const externalPackages = [
|
|
108
|
-
"zod",
|
|
109
|
-
"ai",
|
|
110
|
-
"@ai-sdk/anthropic",
|
|
111
|
-
"@ai-sdk/openai",
|
|
112
|
-
"@ai-sdk/google",
|
|
113
|
-
"@ai-sdk/mistral",
|
|
114
|
-
"@ai-sdk/provider",
|
|
115
|
-
"@ai-sdk/provider-utils",
|
|
116
|
-
];
|
|
103
|
+
const externalPackages = ["zod"];
|
|
117
104
|
for (const pkg of externalPackages) {
|
|
118
105
|
transformed = await rewritePackageImports(transformed, pkg);
|
|
119
106
|
}
|
|
@@ -12,5 +12,5 @@ export type { DiscoveryConfig, DiscoveryHandler, DiscoveryResult, FileDiscoveryC
|
|
|
12
12
|
export { discoverAll } from "./discovery-engine.js";
|
|
13
13
|
export { clearTrackedAgents, filenameToId, filePathToPattern } from "./discovery-utils.js";
|
|
14
14
|
export { clearTranspileCache } from "./transpiler.js";
|
|
15
|
-
export {
|
|
15
|
+
export { validateProviderConfig, type ValidationResult } from "./provider-config-validator.js";
|
|
16
16
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/src/discovery/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAGH,YAAY,EACV,eAAe,EACf,gBAAgB,EAChB,eAAe,EACf,oBAAoB,GACrB,MAAM,YAAY,CAAC;AAGpB,OAAO,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAC;AAGpD,OAAO,EAAE,kBAAkB,EAAE,YAAY,EAAE,iBAAiB,EAAE,MAAM,sBAAsB,CAAC;AAG3F,OAAO,EAAE,mBAAmB,EAAE,MAAM,iBAAiB,CAAC;AAGtD,OAAO,EAAE,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/src/discovery/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAGH,YAAY,EACV,eAAe,EACf,gBAAgB,EAChB,eAAe,EACf,oBAAoB,GACrB,MAAM,YAAY,CAAC;AAGpB,OAAO,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAC;AAGpD,OAAO,EAAE,kBAAkB,EAAE,YAAY,EAAE,iBAAiB,EAAE,MAAM,sBAAsB,CAAC;AAG3F,OAAO,EAAE,mBAAmB,EAAE,MAAM,iBAAiB,CAAC;AAGtD,OAAO,EAAE,sBAAsB,EAAE,KAAK,gBAAgB,EAAE,MAAM,gCAAgC,CAAC"}
|
|
@@ -14,5 +14,5 @@ export { discoverAll } from "./discovery-engine.js";
|
|
|
14
14
|
export { clearTrackedAgents, filenameToId, filePathToPattern } from "./discovery-utils.js";
|
|
15
15
|
// Re-export transpiler utilities
|
|
16
16
|
export { clearTranspileCache } from "./transpiler.js";
|
|
17
|
-
// Re-export config validation (pure logic — no ANSI colors)
|
|
18
|
-
export {
|
|
17
|
+
// Re-export provider config validation (pure logic — no ANSI colors)
|
|
18
|
+
export { validateProviderConfig } from "./provider-config-validator.js";
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Provider Config Validator
|
|
3
|
+
*
|
|
4
|
+
* Pure validation logic for configured model providers. Returns plain-text
|
|
5
|
+
* messages without ANSI formatting; the CLI caller applies colors when printing.
|
|
6
|
+
*/
|
|
7
|
+
import type { VeryfrontConfig } from "../config/index.js";
|
|
8
|
+
export interface ValidationResult {
|
|
9
|
+
valid: boolean;
|
|
10
|
+
warnings: string[];
|
|
11
|
+
errors: string[];
|
|
12
|
+
}
|
|
13
|
+
export declare function validateProviderConfig(config: VeryfrontConfig): ValidationResult;
|
|
14
|
+
//# sourceMappingURL=provider-config-validator.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"provider-config-validator.d.ts","sourceRoot":"","sources":["../../../src/src/discovery/provider-config-validator.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,oBAAoB,CAAC;AAE1D,MAAM,WAAW,gBAAgB;IAC/B,KAAK,EAAE,OAAO,CAAC;IACf,QAAQ,EAAE,MAAM,EAAE,CAAC;IACnB,MAAM,EAAE,MAAM,EAAE,CAAC;CAClB;AAED,wBAAgB,sBAAsB,CAAC,MAAM,EAAE,eAAe,GAAG,gBAAgB,CAiBhF"}
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
/**
|
|
2
|
-
*
|
|
2
|
+
* Provider Config Validator
|
|
3
3
|
*
|
|
4
|
-
* Pure validation logic for
|
|
5
|
-
* without ANSI formatting
|
|
4
|
+
* Pure validation logic for configured model providers. Returns plain-text
|
|
5
|
+
* messages without ANSI formatting; the CLI caller applies colors when printing.
|
|
6
6
|
*/
|
|
7
|
-
export function
|
|
7
|
+
export function validateProviderConfig(config) {
|
|
8
8
|
const result = { valid: true, warnings: [], errors: [] };
|
|
9
9
|
const providers = config.ai?.providers;
|
|
10
10
|
if (!providers)
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"transpiler.d.ts","sourceRoot":"","sources":["../../../src/src/discovery/transpiler.ts"],"names":[],"mappings":"AAeA,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,YAAY,CAAC;AA8HvD;;GAEG;AACH,wBAAsB,YAAY,CAChC,IAAI,EAAE,MAAM,EACZ,OAAO,EAAE,oBAAoB,GAC5B,OAAO,CAAC,OAAO,CAAC,
|
|
1
|
+
{"version":3,"file":"transpiler.d.ts","sourceRoot":"","sources":["../../../src/src/discovery/transpiler.ts"],"names":[],"mappings":"AAeA,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,YAAY,CAAC;AA8HvD;;GAEG;AACH,wBAAsB,YAAY,CAChC,IAAI,EAAE,MAAM,EACZ,OAAO,EAAE,oBAAoB,GAC5B,OAAO,CAAC,OAAO,CAAC,CAwFlB;AAED;;GAEG;AACH,wBAAgB,mBAAmB,IAAI,IAAI,CAE1C"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"embedding.d.ts","sourceRoot":"","sources":["../../../src/src/embedding/embedding.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"embedding.d.ts","sourceRoot":"","sources":["../../../src/src/embedding/embedding.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,eAAe,EAAE,MAAM,YAAY,CAAC;AAO7D;;;;;;;;;;;;;;;;;;GAkBG;AACH,wBAAgB,SAAS,CAAC,MAAM,EAAE,eAAe,GAAG,SAAS,CAwC5D"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { embed, embedMany } from "ai";
|
|
2
1
|
import { resolveEmbeddingModel } from "./resolve.js";
|
|
3
2
|
import { resolveConfiguredEmbeddingModel } from "./model-resolution.js";
|
|
3
|
+
import { embed, embedMany } from "../runtime/runtime-bridge.js";
|
|
4
4
|
const DEFAULT_BATCH_SIZE = 100;
|
|
5
5
|
/**
|
|
6
6
|
* Creates an embedding facade.
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Embedding — RAG primitives for chunking, embedding, and similarity search.
|
|
3
3
|
*
|
|
4
|
-
* Provides a facade over
|
|
5
|
-
*
|
|
4
|
+
* Provides a facade over the framework's current embedding runtime and
|
|
5
|
+
* LangChain text splitting behind veryfront's own API.
|
|
6
6
|
*
|
|
7
7
|
* @module embedding
|
|
8
8
|
*
|
|
@@ -17,7 +17,7 @@
|
|
|
17
17
|
import "../../_dnt.polyfills.js";
|
|
18
18
|
export { embedding } from "./embedding.js";
|
|
19
19
|
export { chunk } from "./chunk.js";
|
|
20
|
-
export { cosineSimilarity as similarity } from "
|
|
20
|
+
export { cosineSimilarity as similarity } from "../runtime/runtime-bridge.js";
|
|
21
21
|
export { vectorStore } from "./vector-store.js";
|
|
22
22
|
export { ragStore } from "./rag-store.js";
|
|
23
23
|
export { createUploadHandler } from "./upload-handler.js";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/src/embedding/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;GAeG;AACH,OAAO,yBAAyB,CAAC;AAGjC,OAAO,EAAE,SAAS,EAAE,MAAM,gBAAgB,CAAC;AAC3C,OAAO,EAAE,KAAK,EAAE,MAAM,YAAY,CAAC;AACnC,OAAO,EAAE,gBAAgB,IAAI,UAAU,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/src/embedding/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;GAeG;AACH,OAAO,yBAAyB,CAAC;AAGjC,OAAO,EAAE,SAAS,EAAE,MAAM,gBAAgB,CAAC;AAC3C,OAAO,EAAE,KAAK,EAAE,MAAM,YAAY,CAAC;AACnC,OAAO,EAAE,gBAAgB,IAAI,UAAU,EAAE,MAAM,8BAA8B,CAAC;AAC9E,OAAO,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAC;AAChD,OAAO,EAAE,QAAQ,EAAE,MAAM,gBAAgB,CAAC;AAC1C,OAAO,EAAE,mBAAmB,EAAE,MAAM,qBAAqB,CAAC;AAC1D,OAAO,EAAE,UAAU,EAAE,MAAM,oBAAoB,CAAC;AAChD,OAAO,EAAE,UAAU,EAAE,MAAM,wBAAwB,CAAC;AACpD,YAAY,EAAE,iBAAiB,EAAE,gBAAgB,EAAE,MAAM,wBAAwB,CAAC;AAClF,OAAO,EACL,uBAAuB,EACvB,yBAAyB,EACzB,qBAAqB,GACtB,MAAM,cAAc,CAAC;AACtB,YAAY,EACV,YAAY,EACZ,SAAS,EACT,eAAe,EACf,QAAQ,EACR,eAAe,EACf,gBAAgB,EAChB,eAAe,EACf,QAAQ,EACR,eAAe,EACf,cAAc,EACd,YAAY,EACZ,aAAa,EACb,YAAY,EACZ,WAAW,EACX,iBAAiB,GAClB,MAAM,YAAY,CAAC"}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Embedding — RAG primitives for chunking, embedding, and similarity search.
|
|
3
3
|
*
|
|
4
|
-
* Provides a facade over
|
|
5
|
-
*
|
|
4
|
+
* Provides a facade over the framework's current embedding runtime and
|
|
5
|
+
* LangChain text splitting behind veryfront's own API.
|
|
6
6
|
*
|
|
7
7
|
* @module embedding
|
|
8
8
|
*
|
|
@@ -17,7 +17,7 @@
|
|
|
17
17
|
import "../../_dnt.polyfills.js";
|
|
18
18
|
export { embedding } from "./embedding.js";
|
|
19
19
|
export { chunk } from "./chunk.js";
|
|
20
|
-
export { cosineSimilarity as similarity } from "
|
|
20
|
+
export { cosineSimilarity as similarity } from "../runtime/runtime-bridge.js";
|
|
21
21
|
export { vectorStore } from "./vector-store.js";
|
|
22
22
|
export { ragStore } from "./rag-store.js";
|
|
23
23
|
export { createUploadHandler } from "./upload-handler.js";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"rag-store.d.ts","sourceRoot":"","sources":["../../../src/src/embedding/rag-store.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"rag-store.d.ts","sourceRoot":"","sources":["../../../src/src/embedding/rag-store.ts"],"names":[],"mappings":"AAgBA,OAAO,KAAK,EAKV,QAAQ,EAER,cAAc,EAEf,MAAM,YAAY,CAAC;AAuBpB;;;;;;;;;;;;;;;;;;;;;;;GAuBG;AACH,wBAAgB,QAAQ,CAAC,MAAM,EAAE,cAAc,GAAG,QAAQ,CAkCzD"}
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import * as dntShim from "../../_dnt.shims.js";
|
|
2
|
-
import { cosineSimilarity } from "ai";
|
|
3
2
|
import { isNotFoundError, mkdir, readDir, readTextFile, writeTextFile, } from "../platform/compat/fs.js";
|
|
4
3
|
import { dirname, extname, join } from "../platform/compat/path/basic-operations.js";
|
|
5
4
|
import { serverLogger } from "../utils/index.js";
|
|
@@ -9,6 +8,7 @@ import { embedding } from "./embedding.js";
|
|
|
9
8
|
import { chunk } from "./chunk.js";
|
|
10
9
|
import { createVeryfrontCloudRagStore } from "./veryfront-cloud/rag-store.js";
|
|
11
10
|
import { resolveConfiguredEmbeddingModel } from "./model-resolution.js";
|
|
11
|
+
import { cosineSimilarity } from "../runtime/runtime-bridge.js";
|
|
12
12
|
import { INVALID_ARGUMENT } from "../errors/index.js";
|
|
13
13
|
/** Default number of top results returned by similarity search. */
|
|
14
14
|
const DEFAULT_TOP_K = 5;
|