@nocobase/plugin-ai 2.2.0-alpha.7 → 2.2.0-beta.10
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/client-v2.d.ts +0 -1
- package/dist/ai/docs/nocobase/workflow/development/api.md +77 -259
- package/dist/ai/docs/nocobase/workflow/development/index.md +1 -2
- package/dist/ai/docs/nocobase/workflow/development/node.md +51 -84
- package/dist/ai/docs/nocobase/workflow/development/trigger.md +20 -122
- package/dist/ai/tools/subAgentWebSearch.js +15 -20
- package/dist/client/119.c6bf8c6433167d81.js +10 -0
- package/dist/client/170.d98eacdc00d9d527.js +10 -0
- package/dist/client/228.b4b709f93b86b6b9.js +10 -0
- package/dist/client/280.003b9e9788599244.js +10 -0
- package/dist/client/290.0f7f441d8a94f03c.js +10 -0
- package/dist/client/331.d547c95410476a69.js +10 -0
- package/dist/client/406.15c09d98faa2ccf1.js +10 -0
- package/dist/client/428.5eb4f53ddbb6a3b8.js +10 -0
- package/dist/client/462.d172d0fe91519e35.js +10 -0
- package/dist/client/486.dcac8f3fcec19c33.js +10 -0
- package/dist/client/502.2b4a51e0a8122e52.js +10 -0
- package/dist/client/525.33a9c8ec28be4ec4.js +10 -0
- package/dist/client/559.959c46d0056ccdc8.js +10 -0
- package/dist/client/561.7ec804ef39ec7dcd.js +10 -0
- package/dist/client/580.35ba54ff91b7fe6d.js +10 -0
- package/dist/client/597.b0d64948d74cf6cb.js +10 -0
- package/dist/client/604.89c674f35b52b4ef.js +10 -0
- package/dist/client/614.aa766080f6b99aab.js +10 -0
- package/dist/client/646.2e395a514c511084.js +10 -0
- package/dist/client/687.224e569a99cae4bb.js +10 -0
- package/dist/client/699.57c0a1acb723202a.js +10 -0
- package/dist/client/711.92cd94681fde7e05.js +10 -0
- package/dist/client/758.a9741e81911e53c3.js +10 -0
- package/dist/client/768.5177bff46ae71a5b.js +10 -0
- package/dist/client/792.abb57765453bcbcc.js +10 -0
- package/dist/client/820.f72ef2462b61d812.js +10 -0
- package/dist/client/832.0cf69e3f43c320b2.js +10 -0
- package/dist/client/927.d95c74ebb8fd51c9.js +10 -0
- package/dist/client/admin-settings/AdminSettings.d.ts +10 -0
- package/dist/client/ai-employees/1.x/selector/AIContextCollector.d.ts +4 -1
- package/dist/client/ai-employees/1.x/selector/AISelectorProvider.d.ts +33 -0
- package/dist/client/ai-employees/1.x/selector/BlockSelector.d.ts +14 -0
- package/dist/{client-v2/ai-employees/tools/ChartGeneratorCard.d.ts → client/ai-employees/1.x/selector/withAISelectable.d.ts} +4 -5
- package/dist/client/ai-employees/AIEmployeeListItem.d.ts +14 -0
- package/dist/client/ai-employees/AIEmployeesProvider.d.ts +12 -0
- package/dist/client/ai-employees/AISettingsProvider.d.ts +18 -0
- package/dist/{client-v2 → client}/ai-employees/AddContextButton.d.ts +1 -1
- package/dist/client/ai-employees/ContextAwareTooltip.d.ts +10 -0
- package/dist/client/ai-employees/ProfileCard.d.ts +15 -0
- package/dist/client/ai-employees/admin/AvatarSelect.d.ts +19 -0
- package/dist/client/ai-employees/admin/ChatSettings.d.ts +10 -0
- package/dist/client/ai-employees/admin/DataSourceSettings.d.ts +10 -0
- package/dist/client/ai-employees/admin/Employees.d.ts +10 -0
- package/dist/client/ai-employees/admin/EnableSwitch.d.ts +10 -0
- package/dist/client/ai-employees/admin/InputsFormSettings.d.ts +10 -0
- package/dist/client/ai-employees/admin/KnowledgeBaseSettings.d.ts +10 -0
- package/dist/client/ai-employees/admin/ModelSettings.d.ts +10 -0
- package/dist/client/ai-employees/admin/ProfileSettings.d.ts +12 -0
- package/dist/client/ai-employees/admin/SkillSettings.d.ts +19 -0
- package/dist/client/ai-employees/admin/SystemPrompt.d.ts +10 -0
- package/dist/client/ai-employees/admin/Templates.d.ts +10 -0
- package/dist/client/ai-employees/admin/ToolsSettings.d.ts +17 -0
- package/dist/{client-v2/ai-employees/chatbox/components/MessageContent.d.ts → client/ai-employees/admin/datasource/components/DatasourceSettingDetail.d.ts} +4 -3
- package/dist/client/ai-employees/admin/datasource/components/DatasourceSettingForm.d.ts +10 -0
- package/dist/client/ai-employees/admin/datasource/components/DatasourceSettingGrid.d.ts +10 -0
- package/dist/client/ai-employees/admin/datasource/components/basic/CollectionCascader.d.ts +14 -0
- package/dist/{client-v2/workflow/nodes/employee/components/SkillSettings.d.ts → client/ai-employees/admin/datasource/components/basic/FieldsTransfer.d.ts} +6 -6
- package/dist/client/ai-employees/admin/datasource/components/basic/index.d.ts +10 -0
- package/dist/client/ai-employees/admin/datasource/components/form-steps/CollectionSetting.d.ts +17 -0
- package/dist/client/ai-employees/admin/datasource/components/form-steps/FieldsSetting.d.ts +15 -0
- package/dist/client/ai-employees/admin/datasource/components/form-steps/FilterSetting.d.ts +17 -0
- package/dist/client/ai-employees/admin/datasource/components/form-steps/Preview.d.ts +13 -0
- package/dist/client/ai-employees/admin/datasource/components/form-steps/SortSetting.d.ts +15 -0
- package/dist/client/ai-employees/admin/datasource/components/form-steps/index.d.ts +13 -0
- package/dist/client/ai-employees/admin/datasource/components/index.d.ts +9 -0
- package/dist/client/ai-employees/admin/datasource/context.d.ts +17 -0
- package/dist/client/ai-employees/admin/datasource/flow-models/DatasourceSettingModel.d.ts +15 -0
- package/dist/client/ai-employees/admin/datasource/flow-models/index.d.ts +9 -0
- package/dist/client/ai-employees/admin/datasource/index.d.ts +10 -0
- package/dist/client/ai-employees/admin/hooks.d.ts +39 -0
- package/dist/client/ai-employees/admin/mcp/MCPSettings.d.ts +10 -0
- package/dist/client/ai-employees/admin/mcp/MCPToolsList.d.ts +19 -0
- package/dist/client/ai-employees/admin/mcp/context.d.ts +15 -0
- package/dist/client/ai-employees/admin/mcp/schemas.d.ts +1314 -0
- package/dist/{client-v2 → client}/ai-employees/ai-coding/AICodingButton.d.ts +1 -2
- package/dist/client/ai-employees/ai-coding/CodeHistory.d.ts +10 -0
- package/dist/client/ai-employees/ai-coding/markdown/Code.d.ts +16 -0
- package/dist/{client-v2/ai-employees/tools/ai-coding.d.ts → client/ai-employees/ai-coding/tools/context-tools.d.ts} +1 -3
- package/dist/client/ai-employees/ai-coding/tools/index.d.ts +11 -0
- package/dist/{client-v2/ai-employees/tools → client/ai-employees/ai-coding/ui}/CodeToolCard.d.ts +1 -1
- package/dist/client/ai-employees/avatars.d.ts +9 -0
- package/dist/client/ai-employees/built-in/utils.d.ts +15 -0
- package/dist/client/ai-employees/business-report/tools/index.d.ts +10 -0
- package/dist/{client-v2/ai-employees/tools → client/ai-employees/business-report/ui}/BusinessReportCard.d.ts +2 -2
- package/dist/{client-v2/ai-employees/tools → client/ai-employees/business-report/ui}/BusinessReportModal.d.ts +2 -2
- package/dist/client/ai-employees/business-report/ui/report-utils.d.ts +38 -0
- package/dist/client/ai-employees/chart-generator/tools/index.d.ts +10 -0
- package/dist/client/ai-employees/chart-generator/ui/ECharts.d.ts +13 -0
- package/dist/{client-v2/ai-employees/chatbox/components/ChatBox.d.ts → client/ai-employees/chatbox/AIThinking.d.ts} +2 -2
- package/dist/{client-v2/ai-employees/chatbox/components → client/ai-employees/chatbox}/Actions.d.ts +4 -2
- package/dist/{client-v2/ai-employees/chatbox/components → client/ai-employees/chatbox}/AddLLMModal.d.ts +4 -2
- package/dist/client/ai-employees/chatbox/Attachment.d.ts +14 -0
- package/dist/client/ai-employees/chatbox/AttachmentsHeader.d.ts +10 -0
- package/dist/client/ai-employees/chatbox/ChatBox.d.ts +12 -0
- package/dist/{client-v2/ai-employees/chatbox/components → client/ai-employees/chatbox}/ChatBoxLayout.d.ts +1 -1
- package/dist/{client-v2/ai-employees/chatbox/components → client/ai-employees/chatbox}/ContextItem.d.ts +1 -1
- package/dist/client/ai-employees/chatbox/ContextItemsHeader.d.ts +10 -0
- package/dist/client/ai-employees/chatbox/DebugPanel.d.ts +16 -0
- package/dist/client/ai-employees/chatbox/EditMessageHeader.d.ts +10 -0
- package/dist/client/ai-employees/chatbox/HintMessageHeader.d.ts +10 -0
- package/dist/client/ai-employees/chatbox/MessageRenderer.d.ts +33 -0
- package/dist/client/ai-employees/chatbox/SenderFooter.d.ts +13 -0
- package/dist/client/ai-employees/chatbox/SenderHeader.d.ts +10 -0
- package/dist/client/ai-employees/chatbox/SenderPrefix.d.ts +10 -0
- package/dist/client/ai-employees/chatbox/Upload.d.ts +12 -0
- package/dist/client/ai-employees/chatbox/VirtualList.d.ts +28 -0
- package/dist/client/ai-employees/chatbox/conversations/ConversationsList.d.ts +13 -0
- package/dist/client/ai-employees/chatbox/conversations/WorkflowTasksList.d.ts +13 -0
- package/dist/{client-v2/ai-employees/chatbox/stores/workflow-tasks.d.ts → client/ai-employees/chatbox/conversations/common.d.ts} +4 -21
- package/dist/client/ai-employees/chatbox/conversations/index.d.ts +9 -0
- package/dist/{client-v2/ai-employees/chatbox/components/ToolCard.d.ts → client/ai-employees/chatbox/generative-ui/DefaultToolCard.d.ts} +6 -7
- package/dist/client/ai-employees/chatbox/generative-ui/ToolCard.d.ts +15 -0
- package/dist/{client-v2 → client}/ai-employees/chatbox/hooks/useChat.d.ts +22 -21
- package/dist/client/ai-employees/chatbox/hooks/useChatBoxActions.d.ts +18 -0
- package/dist/{client-v2 → client}/ai-employees/chatbox/hooks/useChatConversationActions.d.ts +2 -2
- package/dist/{client-v2 → client}/ai-employees/chatbox/hooks/useChatMessageActions.d.ts +4 -8
- package/dist/{client-v2 → client}/ai-employees/chatbox/hooks/useToolCallActions.d.ts +1 -1
- package/dist/client/ai-employees/chatbox/hooks/useUploadFiles.d.ts +12 -0
- package/dist/{client-v2 → client}/ai-employees/chatbox/hooks/useWorkflowTasks.d.ts +1 -1
- package/dist/client/ai-employees/chatbox/markdown/Code.d.ts +18 -0
- package/dist/client/ai-employees/chatbox/markdown/ECharts.d.ts +10 -0
- package/dist/client/ai-employees/chatbox/markdown/Form.d.ts +10 -0
- package/dist/{client-v2/ai-employees/chatbox/components/DebugPanel.d.ts → client/ai-employees/chatbox/markdown/Generating.d.ts} +1 -1
- package/dist/client/ai-employees/chatbox/markdown/Markdown.d.ts +13 -0
- package/dist/{client-v2 → client}/ai-employees/chatbox/model.d.ts +2 -9
- package/dist/client/ai-employees/chatbox/roles.d.ts +32 -0
- package/dist/client/ai-employees/chatbox/stores/chat-box.d.ts +9 -0
- package/dist/client/ai-employees/chatbox/stores/chat-conversations.d.ts +9 -0
- package/dist/client/ai-employees/chatbox/stores/chat-messages.d.ts +9 -0
- package/dist/{client-v2 → client}/ai-employees/chatbox/stores/chat-tool-call.d.ts +15 -1
- package/dist/client/ai-employees/chatbox/stores/chat-tools.d.ts +51 -0
- package/dist/{client-v2/ai-employees/data-modeling/setup.d.ts → client/ai-employees/chatbox/stores/create-selectors.d.ts} +8 -5
- package/dist/client/ai-employees/chatbox/stores/workflow-tasks.d.ts +45 -0
- package/dist/{client-v2 → client}/ai-employees/chatbox/utils.d.ts +6 -21
- package/dist/{client-v2/workflow/nodes/employee/components/AIEmployeeSelect.d.ts → client/ai-employees/common/CodeHighlight.d.ts} +6 -5
- package/dist/client/ai-employees/context/classic-pages.d.ts +10 -0
- package/dist/{client-v2 → client}/ai-employees/context/code-editor.d.ts +1 -1
- package/dist/{client-v2 → client}/ai-employees/context/datasource.d.ts +1 -1
- package/dist/{client-v2 → client}/ai-employees/context/flow-models.d.ts +1 -1
- package/dist/client/ai-employees/data-modeling/Table.d.ts +12 -0
- package/dist/client/ai-employees/data-modeling/setup.d.ts +10 -0
- package/dist/client/ai-employees/data-modeling/tools/index.d.ts +10 -0
- package/dist/{client-v2/ai-employees/tools → client/ai-employees}/data-modeling/types.d.ts +4 -27
- package/dist/client/ai-employees/data-modeling/ui/CollectionNode.d.ts +12 -0
- package/dist/{client-v2/ai-employees/tools → client/ai-employees/data-modeling/ui}/DataModelingCard.d.ts +5 -3
- package/dist/{client-v2/ai-employees/tools → client/ai-employees/data-modeling/ui}/DataModelingModal.d.ts +6 -4
- package/dist/{client-v2/ai-employees/tools/data-modeling → client/ai-employees/data-modeling/ui}/Diagram.d.ts +1 -1
- package/dist/{client-v2/ai-employees/tools/data-modeling → client/ai-employees/data-modeling/ui}/Table.d.ts +2 -2
- package/dist/client/ai-employees/data-modeling/ui/useFieldInterfaceOptions.d.ts +14 -0
- package/dist/{client-v2/ai-employees/context/chart-config.d.ts → client/ai-employees/data-visualization/context.d.ts} +1 -1
- package/dist/{client-v2/ai-employees/tools/data-visualization.d.ts → client/ai-employees/data-visualization/tools/index.d.ts} +1 -1
- package/dist/client/ai-employees/datasource/DatasourceList.d.ts +17 -0
- package/dist/{client-v2 → client}/ai-employees/datasource/DatasourceSelector.d.ts +2 -6
- package/dist/client/ai-employees/datasource/index.d.ts +9 -0
- package/dist/client/ai-employees/flow/events/index.d.ts +9 -0
- package/dist/client/ai-employees/flow/index.d.ts +36 -0
- package/dist/client/ai-employees/flow/models/AIEmployeeActionModel.d.ts +18 -0
- package/dist/client/ai-employees/flow/models/AIEmployeeShortcutModel.d.ts +30 -0
- package/dist/{client-v2 → client}/ai-employees/form-filler/tools/index.d.ts +1 -1
- package/dist/client/ai-employees/permissions/Permissions.d.ts +12 -0
- package/dist/client/ai-employees/permissions/PermissionsTab.d.ts +5 -21
- package/dist/client/ai-employees/shortcuts/ShortcutList.d.ts +10 -0
- package/dist/client/ai-employees/shortcuts/useShortcuts.d.ts +13 -0
- package/dist/{client-v2 → client}/ai-employees/stores/ai-selection.d.ts +4 -4
- package/dist/client/ai-employees/stores/context-aware.d.ts +19 -0
- package/dist/{client-v2 → client}/ai-employees/stores/dialog-controller.d.ts +4 -4
- package/dist/client/ai-employees/sub-agents/tools/index.d.ts +10 -0
- package/dist/{client-v2/ai-employees/tools → client/ai-employees/sub-agents/ui}/SubAgentDispatchCard.d.ts +9 -4
- package/dist/client/ai-employees/suggestions/tools/index.d.ts +10 -0
- package/dist/client/ai-employees/suggestions/ui/SuggestionsOptions.d.ts +13 -0
- package/dist/client/ai-employees/types.d.ts +259 -0
- package/dist/client/ai-employees/workflow-tasks/tools/index.d.ts +10 -0
- package/dist/client/ai-employees/workflow-tasks/ui/WorkflowTaskOutputCard.d.ts +11 -0
- package/dist/{client-v2/workflow/nodes/llm/components → client/chat-settings}/Messages.d.ts +2 -2
- package/dist/{client-v2/workflow/nodes/employee/components → client/chat-settings}/StructuredOutput.d.ts +2 -2
- package/dist/{client-v2/workflow/components/WorkflowListCollapse.d.ts → client/components/ListCollapse.d.ts} +4 -4
- package/dist/client/components/skill-settings.d.ts +22 -0
- package/dist/{client-v2 → client}/debug-logger.d.ts +2 -2
- package/dist/client/features/components.d.ts +9 -0
- package/dist/client/features/feature-manager.d.ts +9 -0
- package/dist/client/features/index.d.ts +9 -0
- package/dist/client/features/vector-database-provider.d.ts +9 -0
- package/dist/client/features/vector-store-provider.d.ts +9 -0
- package/dist/client/index.d.ts +20 -15
- package/dist/client/index.js +8 -8
- package/dist/client/llm-providers/anthropic/ModelSettings.d.ts +10 -0
- package/dist/client/llm-providers/anthropic/ProviderSettings.d.ts +10 -0
- package/dist/client/llm-providers/anthropic/index.d.ts +10 -0
- package/dist/client/llm-providers/components/Chat.d.ts +10 -0
- package/dist/client/llm-providers/components/ModelSelect.d.ts +10 -0
- package/dist/client/llm-providers/dashscope/ModelSettings.d.ts +10 -0
- package/dist/client/llm-providers/dashscope/ProviderSettings.d.ts +10 -0
- package/dist/client/llm-providers/dashscope/index.d.ts +10 -0
- package/dist/client/llm-providers/deepseek/ModelSettings.d.ts +10 -0
- package/dist/client/llm-providers/deepseek/index.d.ts +10 -0
- package/dist/client/llm-providers/google-genai/MessageRenderer.d.ts +13 -0
- package/dist/client/llm-providers/google-genai/ModelSettings.d.ts +10 -0
- package/dist/client/llm-providers/google-genai/ProviderSettings.d.ts +10 -0
- package/dist/client/llm-providers/google-genai/index.d.ts +10 -0
- package/dist/client/llm-providers/kimi/ModelSettings.d.ts +10 -0
- package/dist/client/llm-providers/kimi/index.d.ts +10 -0
- package/dist/client/llm-providers/mimo/ModelSettings.d.ts +10 -0
- package/dist/client/llm-providers/mimo/index.d.ts +10 -0
- package/dist/client/llm-providers/mistral/ModelSettings.d.ts +10 -0
- package/dist/{client-v2/workflow/nodes/employee/components/AIEmployeeFieldset.d.ts → client/llm-providers/mistral/index.d.ts} +2 -3
- package/dist/client/llm-providers/ollama/ModelSettings.d.ts +10 -0
- package/dist/client/llm-providers/ollama/ProviderSettings.d.ts +10 -0
- package/dist/client/llm-providers/ollama/index.d.ts +10 -0
- package/dist/client/llm-providers/openai/completions/ModelSettings.d.ts +10 -0
- package/dist/client/llm-providers/openai/completions/index.d.ts +10 -0
- package/dist/client/llm-providers/openai/components/ProviderSettings.d.ts +10 -0
- package/dist/client/llm-providers/openai/responses/ModelSettings.d.ts +10 -0
- package/dist/client/llm-providers/openai/responses/index.d.ts +10 -0
- package/dist/client/llm-providers/orcarouter/ModelSettings.d.ts +10 -0
- package/dist/client/llm-providers/orcarouter/ProviderSettings.d.ts +10 -0
- package/dist/client/llm-providers/orcarouter/index.d.ts +10 -0
- package/dist/client/llm-providers/tongyi/ModelSettings.d.ts +10 -0
- package/dist/client/llm-providers/tongyi/ProviderSettings.d.ts +10 -0
- package/dist/client/llm-providers/tongyi/index.d.ts +10 -0
- package/dist/client/llm-providers/xai/ModelSettings.d.ts +10 -0
- package/dist/client/llm-providers/xai/index.d.ts +10 -0
- package/dist/client/llm-services/LLMServices.d.ts +13 -0
- package/dist/client/llm-services/component/DefaultModelSelect.d.ts +10 -0
- package/dist/client/llm-services/component/EnabledModelsSelect.d.ts +23 -0
- package/dist/client/llm-services/component/LLMTestFlight.d.ts +10 -0
- package/dist/client/llm-services/component/ModelOptionsSettings.d.ts +10 -0
- package/dist/client/llm-services/component/UnifiedModelSettings.d.ts +10 -0
- package/dist/client/llm-services/hooks/useLLMServiceCatalog.d.ts +18 -0
- package/dist/client/llm-services/llm-providers.d.ts +27 -0
- package/dist/client/llm-services/utils.d.ts +35 -0
- package/dist/client/manager/ai-feature-manager.d.ts +9 -0
- package/dist/{client-v2 → client}/manager/ai-manager.d.ts +5 -4
- package/dist/client/repositories/AIConfigRepository.d.ts +60 -0
- package/dist/client/repositories/hooks/useAIConfigRepository.d.ts +10 -0
- package/dist/client/schemas/llms.d.ts +347 -0
- package/dist/client/workflow/nodes/employee/components/AIEmployeeSelect.d.ts +10 -0
- package/dist/client/workflow/nodes/employee/components/assigness.d.ts +11 -0
- package/dist/client/workflow/nodes/employee/components/file-inputs.d.ts +10 -0
- package/dist/client/workflow/nodes/employee/components/message-inputs.d.ts +12 -0
- package/dist/client/workflow/nodes/employee/components/model-options.d.ts +10 -0
- package/dist/client/workflow/nodes/employee/components/structured-output.d.ts +10 -0
- package/dist/client/workflow/nodes/employee/components/users-select.d.ts +15 -0
- package/dist/client/workflow/nodes/employee/components/web-search-options.d.ts +10 -0
- package/dist/client/workflow/nodes/employee/configuration.d.ts +12 -0
- package/dist/client/workflow/nodes/employee/flow-models/feedback.d.ts +14 -0
- package/dist/client/workflow/nodes/employee/flow-models/task.d.ts +13 -0
- package/dist/client/workflow/nodes/employee/index.d.ts +23 -2
- package/dist/client/workflow/nodes/llm/ModelSettings.d.ts +11 -0
- package/dist/client/workflow/nodes/llm/index.d.ts +52 -2
- package/dist/{client-v2 → client}/workflow/triggers/ai-employee/Parameters.d.ts +4 -2
- package/dist/client/workflow/triggers/ai-employee/index.d.ts +83 -2
- package/dist/client-v2/ai-employees/AIEmployeeShortcut.d.ts +2 -9
- package/dist/client-v2/ai-employees/chatbox/hooks/useChatBoxActions.d.ts +2 -3
- package/dist/client-v2/ai-employees/chatbox/stores/chat-box.d.ts +49 -1
- package/dist/client-v2/ai-employees/chatbox/stores/chat-conversations.d.ts +19 -2
- package/dist/client-v2/ai-employees/chatbox/stores/chat-messages.d.ts +46 -1
- package/dist/client-v2/ai-employees/chatbox/stores/create-selectors.d.ts +3 -31
- package/dist/client-v2/ai-employees/types.d.ts +7 -101
- package/dist/client-v2/index.d.ts +8 -9
- package/dist/client-v2/index.js +1 -37
- package/dist/client-v2/repositories/AIConfigRepository.d.ts +23 -3
- package/dist/externalVersion.js +25 -20
- package/dist/locale/en-US.json +1 -42
- package/dist/locale/zh-CN.json +1 -42
- package/dist/node_modules/@langchain/mistralai/package.json +1 -1
- package/dist/node_modules/@langchain/xai/package.json +1 -1
- package/dist/node_modules/fs-extra/package.json +1 -1
- package/dist/node_modules/jsonrepair/package.json +1 -1
- package/dist/node_modules/just-bash/package.json +1 -1
- package/dist/node_modules/nodejs-snowflake/package.json +1 -1
- package/dist/node_modules/openai/package.json +1 -1
- package/dist/node_modules/zod/package.json +1 -1
- package/dist/server/ai-employees/ai-employee.js +1 -7
- package/dist/server/ai-employees/prompts.d.ts +1 -2
- package/dist/server/ai-employees/prompts.js +2 -8
- package/dist/server/llm-providers/dashscope.d.ts +1 -2
- package/dist/server/llm-providers/dashscope.js +1 -16
- package/dist/server/llm-providers/deepseek.d.ts +1 -2
- package/dist/server/llm-providers/deepseek.js +2 -33
- package/dist/server/llm-providers/kimi/provider.d.ts +1 -2
- package/dist/server/llm-providers/kimi/provider.js +2 -22
- package/dist/server/llm-providers/mistral.d.ts +2 -36
- package/dist/server/llm-providers/mistral.js +2 -62
- package/dist/server/llm-providers/openai/completions.d.ts +1 -2
- package/dist/server/llm-providers/openai/completions.js +1 -17
- package/dist/server/llm-providers/openai/responses.d.ts +1 -2
- package/dist/server/llm-providers/openai/responses.js +1 -17
- package/dist/server/llm-providers/provider.d.ts +0 -7
- package/dist/server/llm-providers/provider.js +1 -7
- package/dist/server/manager/ai-manager.d.ts +1 -2
- package/dist/server/manager/ai-manager.js +1 -4
- package/package.json +5 -5
- package/dist/ai/docs/nocobase/interface-builder/blocks/data-blocks/comment.md +0 -107
- package/dist/ai/docs/nocobase/plugins/@nocobase/plugin-block-comment/index.md +0 -14
- package/dist/ai/docs/nocobase/workflow/development/migration.md +0 -319
- package/dist/client/23.65ea8c37cd4b884b.js +0 -10
- package/dist/client/264.cc98933ef65608b6.js +0 -10
- package/dist/client/336.7a8a8853196ad779.js +0 -11
- package/dist/client/372.da38fe350bf841f4.js +0 -10
- package/dist/client/416.92b74ca47e4099c4.js +0 -10
- package/dist/client/446.d63c38d0309fe250.js +0 -10
- package/dist/client/525.203778500aca5d05.js +0 -10
- package/dist/client/663.680bcf6272a8504d.js +0 -10
- package/dist/client/681.399948c18d753667.js +0 -10
- package/dist/client/705.380279da896021fb.js +0 -10
- package/dist/client-v2/23.1bcb6986b40723d8.js +0 -10
- package/dist/client-v2/264.be92ff6a4d2612f1.js +0 -10
- package/dist/client-v2/336.e406470429e0670e.js +0 -11
- package/dist/client-v2/372.d76ea1ceed2be2a4.js +0 -10
- package/dist/client-v2/406.341be51205c674e0.js +0 -10
- package/dist/client-v2/416.0e1c2d9cde43b83d.js +0 -10
- package/dist/client-v2/446.073d450882db29fd.js +0 -10
- package/dist/client-v2/457.d72febb89e88fc00.js +0 -10
- package/dist/client-v2/663.342341f0b2b412d8.js +0 -10
- package/dist/client-v2/681.082f4f1c7b841983.js +0 -10
- package/dist/client-v2/705.1d10027ff8cfdf79.js +0 -10
- package/dist/client-v2/ai-employees/AIEmployeeDropdown.d.ts +0 -18
- package/dist/client-v2/ai-employees/chatbox/components/Attachments.d.ts +0 -27
- package/dist/client-v2/ai-employees/chatbox/components/Markdown.d.ts +0 -25
- package/dist/client-v2/ai-employees/chatbox/components/MessageRenderers.d.ts +0 -39
- package/dist/client-v2/ai-employees/chatbox/components/index.d.ts +0 -13
- package/dist/client-v2/ai-employees/chatbox/hooks/useUploadFiles.d.ts +0 -46
- package/dist/client-v2/ai-employees/chatbox/roles.d.ts +0 -162
- package/dist/client-v2/ai-employees/chatbox/stores/chat-tools.d.ts +0 -30
- package/dist/client-v2/ai-employees/flow/index.d.ts +0 -13
- package/dist/client-v2/ai-employees/tools/SuggestionsOptionsCard.d.ts +0 -16
- package/dist/client-v2/ai-employees/tools/WorkflowTaskOutputCard.d.ts +0 -16
- package/dist/client-v2/ai-employees/tools/business-report-utils.d.ts +0 -45
- package/dist/client-v2/ai-employees/tools/data-modeling/CollectionNode.d.ts +0 -11
- package/dist/client-v2/ai-employees/tools/data-modeling/legacy-template.d.ts +0 -13
- package/dist/client-v2/ai-employees/tools/data-modeling/runtime.d.ts +0 -15
- package/dist/client-v2/ai-employees/tools/data-modeling/useFieldInterfaceOptions.d.ts +0 -151
- package/dist/client-v2/ai-employees/tools/index.d.ts +0 -32
- package/dist/client-v2/components/RemoteSelect.d.ts +0 -43
- package/dist/client-v2/f0053e745af0ad03.svg +0 -50
- package/dist/client-v2/llm-providers/forms.d.ts +0 -44
- package/dist/client-v2/llm-providers/index.d.ts +0 -24
- package/dist/client-v2/llm-services/utils.d.ts +0 -13
- package/dist/client-v2/locale.d.ts +0 -14
- package/dist/client-v2/models/ai-employees/AIEmployeeActionModel.d.ts +0 -33
- package/dist/client-v2/models/ai-employees/AIEmployeeShortcutModel.d.ts +0 -44
- package/dist/client-v2/pages/AdminSettingsPage.d.ts +0 -24
- package/dist/client-v2/pages/DatasourceSettingsPage.d.ts +0 -62
- package/dist/client-v2/pages/EmployeesPage.d.ts +0 -53
- package/dist/client-v2/pages/LLMServicesPage.d.ts +0 -75
- package/dist/client-v2/pages/MCPSettingsPage.d.ts +0 -73
- package/dist/client-v2/pages/drawerWidth.d.ts +0 -10
- package/dist/client-v2/pages/permissions/Permissions.d.ts +0 -67
- package/dist/client-v2/pages/permissions/PermissionsTab.d.ts +0 -12
- package/dist/client-v2/pages/useUnsavedChangesBeforeClose.d.ts +0 -29
- package/dist/client-v2/plugin.d.ts +0 -32
- package/dist/client-v2/workflow/components/FormValueRegistry.d.ts +0 -12
- package/dist/client-v2/workflow/constants.d.ts +0 -26
- package/dist/client-v2/workflow/nodes/employee/components/Assignees.d.ts +0 -11
- package/dist/client-v2/workflow/nodes/employee/components/FeedbackSettings.d.ts +0 -17
- package/dist/client-v2/workflow/nodes/employee/components/FileInputs.d.ts +0 -11
- package/dist/client-v2/workflow/nodes/employee/components/MessageInputs.d.ts +0 -11
- package/dist/client-v2/workflow/nodes/employee/components/ModelOptions.d.ts +0 -17
- package/dist/client-v2/workflow/nodes/employee/components/UserInput.d.ts +0 -18
- package/dist/client-v2/workflow/nodes/employee/components/WebSearchOptions.d.ts +0 -16
- package/dist/client-v2/workflow/nodes/employee/index.d.ts +0 -23
- package/dist/client-v2/workflow/nodes/llm/components/LLMFieldset.d.ts +0 -12
- package/dist/client-v2/workflow/nodes/llm/components/StructuredOutput.d.ts +0 -11
- package/dist/client-v2/workflow/nodes/llm/index.d.ts +0 -30
- package/dist/client-v2/workflow/register.d.ts +0 -10
- package/dist/client-v2/workflow/triggers/ai-employee/AIEmployeeTriggerConfig.d.ts +0 -11
- package/dist/client-v2/workflow/triggers/ai-employee/index.d.ts +0 -25
- package/dist/client-v2/workflow/types.d.ts +0 -128
- /package/dist/{client-v2 → client}/ai-employees/AISelection.d.ts +0 -0
- /package/dist/{client-v2 → client}/ai-employees/AISelectionControl.d.ts +0 -0
- /package/dist/{client-v2 → client}/ai-employees/ai-coding/prompts.d.ts +0 -0
- /package/dist/{client-v2 → client}/ai-employees/ai-coding/setup.d.ts +0 -0
- /package/dist/{client-v2/ai-employees/chatbox/components/AIEmployeeSwitcher.d.ts → client/ai-employees/chatbox/AIEmployeeSwitch.d.ts} +0 -0
- /package/dist/{client-v2/ai-employees/chatbox/components → client/ai-employees/chatbox}/ChatButton.d.ts +0 -0
- /package/dist/{client-v2/ai-employees/chatbox/components → client/ai-employees/chatbox}/Messages.d.ts +0 -0
- /package/dist/{client-v2/ai-employees/chatbox/components → client/ai-employees/chatbox}/ModelSwitcher.d.ts +0 -0
- /package/dist/{client-v2/ai-employees/chatbox/components → client/ai-employees/chatbox}/SearchSwitch.d.ts +0 -0
- /package/dist/{client-v2/ai-employees/chatbox/components → client/ai-employees/chatbox}/Sender.d.ts +0 -0
- /package/dist/{client-v2/ai-employees/chatbox/components → client/ai-employees/chatbox}/UserPrompt.d.ts +0 -0
- /package/dist/{client-v2/ai-employees/chatbox/components → client/ai-employees/chatbox/conversations}/Conversations.d.ts +0 -0
- /package/dist/{client-v2/ai-employees/chatbox/components → client/ai-employees/chatbox/generative-ui}/ToolModal.d.ts +0 -0
- /package/dist/{client-v2 → client}/ai-employees/chatbox/hooks/useChatBoxEffect.d.ts +0 -0
- /package/dist/{client-v2 → client}/ai-employees/chatbox/hooks/useLoadMoreObserver.d.ts +0 -0
- /package/dist/{client-v2/workflow/components/index.d.ts → client/ai-employees/flow/events/ai-context-selection.d.ts} +0 -0
- /package/dist/{client-v2/models/ai-employees → client/ai-employees/flow/models}/AIEmployeeShortcutListModel.d.ts +0 -0
- /package/dist/{client-v2/models/ai-employees → client/ai-employees/flow/models}/index.d.ts +0 -0
- /package/dist/client-v2/ai-employees/{stores → chatbox/stores}/global-store.d.ts +0 -0
|
@@ -1,9 +1,3 @@
|
|
|
1
|
-
---
|
|
2
|
-
title: "Extending Node Types"
|
|
3
|
-
description: "Extending node types: custom node development, node configuration, execution logic, API and lifecycle."
|
|
4
|
-
keywords: "workflow,extending nodes,custom nodes,node development,NocoBase"
|
|
5
|
-
---
|
|
6
|
-
|
|
7
1
|
# Extending Node Types
|
|
8
2
|
|
|
9
3
|
A node's type is essentially an operational instruction. Different instructions represent different operations executed in the workflow.
|
|
@@ -117,7 +111,7 @@ export class AsyncInstruction extends Instruction {
|
|
|
117
111
|
// 2. Explicitly call exit() to flush the task to the database and commit the transaction
|
|
118
112
|
await processor.exit();
|
|
119
113
|
|
|
120
|
-
// 3. Initiate the async operation (transaction is now committed, no longer holding the
|
|
114
|
+
// 3. Initiate the async operation (the transaction is now committed, no longer holding the database connection)
|
|
121
115
|
const jobDone: IJob = { status: JOB_STATUS.PENDING };
|
|
122
116
|
try {
|
|
123
117
|
const result = await someAsyncOperation(node.config);
|
|
@@ -245,78 +239,44 @@ Similar to triggers, the configuration form for an instruction (node type) needs
|
|
|
245
239
|
|
|
246
240
|
All instructions need to be derived from the `Instruction` base class. The related properties and methods are used for configuring and using the node.
|
|
247
241
|
|
|
248
|
-
For example, if we need to provide a configuration interface for the random number string type (`randomString`) node defined on the server-side above, which has a configuration item `digit` representing the number of digits for the random number
|
|
242
|
+
For example, if we need to provide a configuration interface for the random number string type (`randomString`) node defined on the server-side above, which has a configuration item `digit` representing the number of digits for the random number, we would use a number input box in the configuration form to receive user input.
|
|
249
243
|
|
|
250
|
-
```
|
|
251
|
-
import { Instruction } from '@nocobase/
|
|
244
|
+
```tsx pure
|
|
245
|
+
import WorkflowPlugin, { Instruction, VariableOption } from '@nocobase/workflow/client';
|
|
252
246
|
|
|
253
|
-
class
|
|
247
|
+
class MyInstruction extends Instruction {
|
|
254
248
|
title = 'Random number string';
|
|
255
249
|
type = 'randomString';
|
|
256
250
|
group = 'extended';
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
251
|
+
fieldset = {
|
|
252
|
+
'digit': {
|
|
253
|
+
type: 'number',
|
|
254
|
+
title: 'Digit',
|
|
255
|
+
name: 'digit',
|
|
256
|
+
'x-decorator': 'FormItem',
|
|
257
|
+
'x-component': 'InputNumber',
|
|
258
|
+
'x-component-props': {
|
|
259
|
+
min: 1,
|
|
260
|
+
max: 10,
|
|
261
|
+
},
|
|
262
|
+
default: 6,
|
|
263
|
+
},
|
|
264
|
+
};
|
|
265
|
+
useVariables(node, options): VariableOption {
|
|
266
|
+
return {
|
|
267
|
+
value: node.key,
|
|
268
|
+
label: node.title,
|
|
269
|
+
};
|
|
263
270
|
}
|
|
264
271
|
}
|
|
265
|
-
```
|
|
266
|
-
|
|
267
|
-
Here, `FieldsetLoader` is a function that returns `Promise<{ default: ComponentType }>`, implementing lazy loading via dynamic `import()`. The component it points to is a standard React function component that builds the form using antd's `Form.Item`:
|
|
268
|
-
|
|
269
|
-
```tsx
|
|
270
|
-
// components/RandomStringConfig.tsx
|
|
271
|
-
import { Form, InputNumber } from 'antd';
|
|
272
|
-
|
|
273
|
-
export default function RandomStringConfig() {
|
|
274
|
-
return (
|
|
275
|
-
<Form.Item
|
|
276
|
-
name={['config', 'digit']}
|
|
277
|
-
label="Digit"
|
|
278
|
-
initialValue={6}
|
|
279
|
-
rules={[{ required: true }]}
|
|
280
|
-
>
|
|
281
|
-
<InputNumber min={1} max={10} />
|
|
282
|
-
</Form.Item>
|
|
283
|
-
);
|
|
284
|
-
}
|
|
285
|
-
```
|
|
286
|
-
|
|
287
|
-
Note that the form field's `name` uses the nested array format `['config', 'fieldName']`, which is the standard antd Form convention.
|
|
288
|
-
|
|
289
|
-
### Multiple Configuration Interfaces
|
|
290
|
-
|
|
291
|
-
A node can provide multiple configuration interfaces for different scenarios:
|
|
292
|
-
|
|
293
|
-
- `FieldsetLoader` — Node configuration drawer form (most commonly used)
|
|
294
|
-

|
|
295
|
-
|
|
296
|
-
- `PresetFieldsetLoader` — Preset form when creating a node (usually contains only required fields)
|
|
297
|
-

|
|
298
|
-
|
|
299
|
-
- `ComponentLoader` — Custom node rendering on the canvas (used for branch nodes and other cases requiring special rendering)
|
|
300
|
-

|
|
301
|
-
|
|
302
|
-
When a Loader needs to point to a named export (rather than the default export) in a file, use `.then()` to remap:
|
|
303
|
-
|
|
304
|
-
```ts
|
|
305
|
-
FieldsetLoader = () => import('./components/MyNodeConfig').then((m) => ({ default: m.MyFieldset }));
|
|
306
|
-
```
|
|
307
272
|
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
```ts
|
|
313
|
-
import { Plugin } from '@nocobase/client-v2';
|
|
314
|
-
import RandomStringInstruction from './RandomStringInstruction';
|
|
273
|
+
export default class MyPlugin extends Plugin {
|
|
274
|
+
load() {
|
|
275
|
+
// get workflow plugin instance
|
|
276
|
+
const workflowPlugin = this.app.getPlugin<WorkflowPlugin>(WorkflowPlugin);
|
|
315
277
|
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
const workflow = this.app.pm.get('workflow');
|
|
319
|
-
workflow.registerInstruction('randomString', RandomStringInstruction);
|
|
278
|
+
// register instruction
|
|
279
|
+
workflowPlugin.registerInstruction('randomString', MyInstruction);
|
|
320
280
|
}
|
|
321
281
|
}
|
|
322
282
|
```
|
|
@@ -327,7 +287,7 @@ The node type identifier registered on the client-side must be consistent with t
|
|
|
327
287
|
|
|
328
288
|
### Providing Node Results as Variables
|
|
329
289
|
|
|
330
|
-
You may notice the `useVariables` method in the example above. If you need to use the node's result (the `result` part) as a variable for subsequent nodes, you need to implement this method in the
|
|
290
|
+
You may notice the `useVariables` method in the example above. If you need to use the node's result (the `result` part) as a variable for subsequent nodes, you need to implement this method in the inherited instruction class and return an object that conforms to the `VariableOption` type. This object serves as a structural description of the node's execution result, providing variable name mapping for selection and use in subsequent nodes.
|
|
331
291
|
|
|
332
292
|
The `VariableOption` type is defined as follows:
|
|
333
293
|
|
|
@@ -342,7 +302,7 @@ export type VariableOption = {
|
|
|
342
302
|
|
|
343
303
|
The core is the `value` property, which represents the segmented path value of the variable name. `label` is used for display on the interface, and `children` is used to represent a multi-level variable structure, which is used when the node's result is a deeply nested object.
|
|
344
304
|
|
|
345
|
-
A usable variable is represented internally in the system as a path template string separated by `.`, for example, `{{
|
|
305
|
+
A usable variable is represented internally in the system as a path template string separated by `.`, for example, `{{jobsMapByNodeKey.2dw92cdf.abc}}`. Here, `jobsMapByNodeKey` represents the result set of all nodes (internally defined, no need to handle), `2dw92cdf` is the node's `key`, and `abc` is a custom property in the node's result object.
|
|
346
306
|
|
|
347
307
|
Additionally, since a node's result can also be a simple value, when providing node variables, the first level **must** be the description of the node itself:
|
|
348
308
|
|
|
@@ -353,10 +313,14 @@ Additionally, since a node's result can also be a simple value, when providing n
|
|
|
353
313
|
}
|
|
354
314
|
```
|
|
355
315
|
|
|
356
|
-
That is, the first level is the node's `key` and title. For example, in the
|
|
316
|
+
That is, the first level is the node's `key` and title. For example, in the calculation node's [code reference](https://github.com/nocobase/nocobase/blob/main/packages/plugins/%40nocobase/plugin-workflow/src/client/nodes/calculation.tsx#L77), when using the result of the calculation node, the interface options are as follows:
|
|
317
|
+
|
|
318
|
+
|
|
357
319
|
|
|
358
320
|

|
|
359
321
|
|
|
322
|
+
|
|
323
|
+
|
|
360
324
|
When the node's result is a complex object, you can use `children` to continue describing nested properties. For example, a custom instruction might return the following JSON data:
|
|
361
325
|
|
|
362
326
|
```json
|
|
@@ -364,7 +328,7 @@ When the node's result is a complex object, you can use `children` to continue d
|
|
|
364
328
|
"message": "ok",
|
|
365
329
|
"data": {
|
|
366
330
|
"id": 1,
|
|
367
|
-
"name": "test"
|
|
331
|
+
"name": "test",
|
|
368
332
|
}
|
|
369
333
|
}
|
|
370
334
|
```
|
|
@@ -372,7 +336,7 @@ When the node's result is a complex object, you can use `children` to continue d
|
|
|
372
336
|
Then you can return it through the `useVariables` method as follows:
|
|
373
337
|
|
|
374
338
|
```ts
|
|
375
|
-
useVariables(node, options) {
|
|
339
|
+
useVariables(node, options): VariableOption {
|
|
376
340
|
return {
|
|
377
341
|
value: node.key,
|
|
378
342
|
label: node.title,
|
|
@@ -402,8 +366,12 @@ useVariables(node, options) {
|
|
|
402
366
|
|
|
403
367
|
This way, in subsequent nodes, you can use the following interface to select variables from it:
|
|
404
368
|
|
|
369
|
+
|
|
370
|
+
|
|
405
371
|

|
|
406
372
|
|
|
373
|
+
|
|
374
|
+
|
|
407
375
|
:::info{title="Note"}
|
|
408
376
|
When a structure in the result is an array of deeply nested objects, you can also use `children` to describe the path, but it cannot include array indices. This is because in NocoBase workflow's variable handling, the variable path description for an array of objects is automatically flattened into an array of deep values when used, and you cannot access a specific value by its index.
|
|
409
377
|
:::
|
|
@@ -413,6 +381,11 @@ When a structure in the result is an array of deeply nested objects, you can als
|
|
|
413
381
|
By default, any node can be added to a workflow. However, in some cases, a node may not be applicable in certain types of workflows or branches. In such situations, you can configure the node's availability using `isAvailable`:
|
|
414
382
|
|
|
415
383
|
```ts
|
|
384
|
+
// Type definition
|
|
385
|
+
export abstract class Instruction {
|
|
386
|
+
isAvailable?(ctx: NodeAvailableContext): boolean;
|
|
387
|
+
}
|
|
388
|
+
|
|
416
389
|
export type NodeAvailableContext = {
|
|
417
390
|
// Workflow plugin instance
|
|
418
391
|
engine: WorkflowPlugin;
|
|
@@ -420,7 +393,7 @@ export type NodeAvailableContext = {
|
|
|
420
393
|
workflow: object;
|
|
421
394
|
// Upstream node
|
|
422
395
|
upstream: object;
|
|
423
|
-
// Whether it is a branch node (branch
|
|
396
|
+
// Whether it is a branch node (branch number)
|
|
424
397
|
branchIndex: number;
|
|
425
398
|
};
|
|
426
399
|
```
|
|
@@ -430,17 +403,11 @@ The `isAvailable` method returns `true` if the node is available, and `false` if
|
|
|
430
403
|
If there are no special requirements, you do not need to implement the `isAvailable` method, as nodes are available by default. The most common scenario requiring configuration is when a node might be a time-consuming operation and is not suitable for execution in a synchronous workflow. You can use the `isAvailable` method to restrict its use. For example:
|
|
431
404
|
|
|
432
405
|
```ts
|
|
433
|
-
isAvailable({ engine, workflow }) {
|
|
406
|
+
isAvailable({ engine, workflow, upstream, branchIndex }) {
|
|
434
407
|
return !engine.isWorkflowSync(workflow);
|
|
435
408
|
}
|
|
436
409
|
```
|
|
437
410
|
|
|
438
411
|
### Learn More
|
|
439
412
|
|
|
440
|
-
For
|
|
441
|
-
|
|
442
|
-
For the definitions of various parameters for defining node types, see the [Workflow API Reference](./api) section.
|
|
443
|
-
|
|
444
|
-
:::info{title=Note}
|
|
445
|
-
If you were previously using the legacy (v1) client-side code and want to migrate to the new v2 version, refer to the [v1 to v2 Migration Guide](./migration).
|
|
446
|
-
:::
|
|
413
|
+
For the definitions of various parameters for defining node types, see the Workflow API Reference section.
|
|
@@ -1,10 +1,4 @@
|
|
|
1
|
-
|
|
2
|
-
title: "Extending Trigger Types"
|
|
3
|
-
description: "Extending trigger types: custom trigger development, configuration interface, trigger logic, API reference."
|
|
4
|
-
keywords: "workflow,extending triggers,custom triggers,trigger development,NocoBase"
|
|
5
|
-
---
|
|
6
|
-
|
|
7
|
-
# Extending Trigger Types
|
|
1
|
+
# Extend Trigger Types
|
|
8
2
|
|
|
9
3
|
Every workflow must be configured with a specific trigger, which serves as the entry point for starting the process execution.
|
|
10
4
|
|
|
@@ -68,129 +62,39 @@ After the server starts and loads, the `'interval'` type trigger can be added an
|
|
|
68
62
|
|
|
69
63
|
The client-side part mainly provides a configuration interface based on the configuration items required by the trigger type. Each trigger type also needs to register its corresponding type configuration with the Workflow plugin.
|
|
70
64
|
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
### The Simplest Trigger
|
|
74
|
-
|
|
75
|
-
For example, for the interval timer trigger described above, define the interval time configuration item (`interval`) needed in the configuration interface form:
|
|
65
|
+
For example, for the scheduled execution trigger mentioned above, define the required interval time configuration item (`interval`) in the configuration interface form:
|
|
76
66
|
|
|
77
67
|
```ts
|
|
78
|
-
import { Trigger } from '@nocobase/
|
|
68
|
+
import { Trigger } from '@nocobase/workflow/client';
|
|
79
69
|
|
|
80
70
|
class MyTrigger extends Trigger {
|
|
81
71
|
title = 'Interval timer trigger';
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
Here, `FieldsetLoader` is a function that returns `Promise<{ default: ComponentType }>`, implementing lazy loading via dynamic `import()`. The component it points to is a standard React function component:
|
|
94
|
-
|
|
95
|
-
```tsx
|
|
96
|
-
// IntervalConfig.tsx
|
|
97
|
-
import { Form, InputNumber } from 'antd';
|
|
98
|
-
|
|
99
|
-
export default function IntervalConfig() {
|
|
100
|
-
return (
|
|
101
|
-
<Form.Item
|
|
102
|
-
name={['config', 'interval']}
|
|
103
|
-
label="Interval"
|
|
104
|
-
initialValue={60000}
|
|
105
|
-
rules={[{ required: true }]}
|
|
106
|
-
>
|
|
107
|
-
<InputNumber min={1000} />
|
|
108
|
-
</Form.Item>
|
|
109
|
-
);
|
|
72
|
+
// fields of trigger config
|
|
73
|
+
fieldset = {
|
|
74
|
+
interval: {
|
|
75
|
+
type: 'number',
|
|
76
|
+
title: 'Interval',
|
|
77
|
+
name: 'config.interval',
|
|
78
|
+
'x-decorator': 'FormItem',
|
|
79
|
+
'x-component': 'InputNumber',
|
|
80
|
+
default: 60000,
|
|
81
|
+
},
|
|
82
|
+
};
|
|
110
83
|
}
|
|
111
84
|
```
|
|
112
85
|
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
### Multiple Configuration Interfaces
|
|
116
|
-
|
|
117
|
-
A trigger can provide multiple configuration interfaces for different scenarios:
|
|
118
|
-
|
|
119
|
-
- `PresetFieldsetLoader` — Preset form when creating a workflow (usually contains only required fields)
|
|
120
|
-

|
|
121
|
-
|
|
122
|
-
- `FieldsetLoader` — Full trigger configuration form (displayed in the configuration drawer)
|
|
123
|
-

|
|
124
|
-
|
|
125
|
-
- `TriggerFieldsetLoader` — Input form for manual execution
|
|
126
|
-

|
|
127
|
-
|
|
128
|
-
When a Loader needs to point to a named export (rather than the default export) in a file, use `.then()` to remap:
|
|
86
|
+
Then, register this trigger type with the workflow plugin instance within the extended plugin:
|
|
129
87
|
|
|
130
88
|
```ts
|
|
131
|
-
|
|
132
|
-
|
|
89
|
+
import { Plugin } from '@nocobase/client';
|
|
90
|
+
import WorkflowPlugin from '@nocobase/plugin-workflow/client';
|
|
133
91
|
|
|
134
|
-
PresetFieldsetLoader = () =>
|
|
135
|
-
import('./MyTriggerConfig').then((m) => ({ default: m.MyPresetConfig }));
|
|
136
|
-
FieldsetLoader = () => import('./MyTriggerConfig');
|
|
137
|
-
TriggerFieldsetLoader = () => import('./TriggerMyConfig');
|
|
138
|
-
|
|
139
|
-
validate(config) {
|
|
140
|
-
return Boolean(config?.collection && config?.mode);
|
|
141
|
-
}
|
|
142
|
-
|
|
143
|
-
createDefaultConfig() {
|
|
144
|
-
return { mode: 1 };
|
|
145
|
-
}
|
|
146
|
-
}
|
|
147
|
-
```
|
|
148
|
-
|
|
149
|
-
```tsx
|
|
150
|
-
// MyTriggerConfig.tsx
|
|
151
|
-
import { Form, Select } from 'antd';
|
|
152
|
-
import { CollectionCascader } from '@nocobase/plugin-workflow/client-v2';
|
|
153
|
-
|
|
154
|
-
// Preset form for creation (named export)
|
|
155
|
-
export function MyPresetConfig() {
|
|
156
|
-
return (
|
|
157
|
-
<Form.Item name={['config', 'collection']} label="Collection" rules={[{ required: true }]}>
|
|
158
|
-
<CollectionCascader />
|
|
159
|
-
</Form.Item>
|
|
160
|
-
);
|
|
161
|
-
}
|
|
162
|
-
|
|
163
|
-
// Full config form (default export)
|
|
164
|
-
export default function MyTriggerConfig() {
|
|
165
|
-
return (
|
|
166
|
-
<>
|
|
167
|
-
<Form.Item name={['config', 'collection']} label="Collection">
|
|
168
|
-
<CollectionCascader disabled />
|
|
169
|
-
</Form.Item>
|
|
170
|
-
<Form.Item name={['config', 'mode']} label="Mode">
|
|
171
|
-
<Select
|
|
172
|
-
options={[
|
|
173
|
-
{ label: 'Created', value: 1 },
|
|
174
|
-
{ label: 'Updated', value: 2 },
|
|
175
|
-
]}
|
|
176
|
-
/>
|
|
177
|
-
</Form.Item>
|
|
178
|
-
</>
|
|
179
|
-
);
|
|
180
|
-
}
|
|
181
|
-
```
|
|
182
|
-
|
|
183
|
-
### Register the Trigger
|
|
184
|
-
|
|
185
|
-
Register the trigger type with the workflow plugin instance within the extended plugin:
|
|
186
|
-
|
|
187
|
-
```ts
|
|
188
|
-
import { Plugin } from '@nocobase/client-v2';
|
|
189
92
|
import MyTrigger from './MyTrigger';
|
|
190
93
|
|
|
191
94
|
export default class extends Plugin {
|
|
95
|
+
// You can get and modify the app instance here
|
|
192
96
|
async load() {
|
|
193
|
-
const workflow = this.app.pm.get(
|
|
97
|
+
const workflow = this.app.pm.get(WorkflowPlugin) as WorkflowPlugin;
|
|
194
98
|
workflow.registerTrigger('interval', MyTrigger);
|
|
195
99
|
}
|
|
196
100
|
}
|
|
@@ -202,10 +106,4 @@ After that, the new trigger type will be visible in the workflow configuration i
|
|
|
202
106
|
The identifier of the trigger type registered on the client-side must be consistent with the one on the server-side, otherwise it will cause errors.
|
|
203
107
|
:::
|
|
204
108
|
|
|
205
|
-
For
|
|
206
|
-
|
|
207
|
-
For other details on defining trigger types, please refer to the [Workflow API Reference](./api) section.
|
|
208
|
-
|
|
209
|
-
:::info{title=Note}
|
|
210
|
-
If you were previously using the legacy (v1) client-side code and want to migrate to the new v2 version, refer to the [v1 to v2 Migration Guide](./migration).
|
|
211
|
-
:::
|
|
109
|
+
For other details on defining trigger types, please refer to the [Workflow API Reference](./api#pluginregisterTrigger) section.
|
|
@@ -40,12 +40,9 @@ var subAgentWebSearch_default = (0, import_ai.defineTools)({
|
|
|
40
40
|
},
|
|
41
41
|
definition: {
|
|
42
42
|
name: "subAgentWebSearch",
|
|
43
|
-
description: "
|
|
43
|
+
description: "Use the query to search the web and return concise, relevant findings with source links.",
|
|
44
44
|
schema: import_zod.z.object({
|
|
45
|
-
query: import_zod.z.array(
|
|
46
|
-
import_zod.z.string(),
|
|
47
|
-
"A list of clear, specific, non-overlapping web search queries. Include all independent queries needed for this answer in a single tool call so they can run in parallel."
|
|
48
|
-
)
|
|
45
|
+
query: import_zod.z.array(import_zod.z.string(), "A clear and specific web search query describing the information to retrieve.")
|
|
49
46
|
})
|
|
50
47
|
},
|
|
51
48
|
invoke: async (ctx, args, id) => {
|
|
@@ -54,8 +51,7 @@ var subAgentWebSearch_default = (0, import_ai.defineTools)({
|
|
|
54
51
|
const { model } = ((_b = (_a = ctx.action) == null ? void 0 : _a.params) == null ? void 0 : _b.values) ?? {};
|
|
55
52
|
const { provider } = await pluginAI.aiManager.getLLMService({
|
|
56
53
|
...model,
|
|
57
|
-
webSearch: true
|
|
58
|
-
reasoning: { mode: "off" }
|
|
54
|
+
webSearch: true
|
|
59
55
|
});
|
|
60
56
|
if (!((_c = args.query) == null ? void 0 : _c.length)) {
|
|
61
57
|
return {
|
|
@@ -89,20 +85,19 @@ var subAgentWebSearch_default = (0, import_ai.defineTools)({
|
|
|
89
85
|
};
|
|
90
86
|
}
|
|
91
87
|
});
|
|
92
|
-
const WEB_SEARCH_SYSTEM_PROMPT = `You are a web search
|
|
88
|
+
const WEB_SEARCH_SYSTEM_PROMPT = `You are a web search assistant.
|
|
93
89
|
|
|
94
|
-
Your
|
|
90
|
+
Your primary task is to retrieve up-to-date information from the internet based on the user's input query.
|
|
95
91
|
|
|
96
92
|
Requirements:
|
|
97
|
-
1.
|
|
98
|
-
2.
|
|
99
|
-
3.
|
|
100
|
-
4.
|
|
101
|
-
5.
|
|
102
|
-
6.
|
|
103
|
-
7. If results are weak, say exactly what is missing instead of broadening the search yourself.
|
|
93
|
+
1. Actively attempt web retrieval first. Use internet search to find relevant and recent information.
|
|
94
|
+
2. Summarize and synthesize findings clearly and concisely.
|
|
95
|
+
3. Explicitly cite sources for key points whenever possible (for example: website/publication name, article title, and URL if available).
|
|
96
|
+
4. Distinguish confirmed facts from uncertain or incomplete information.
|
|
97
|
+
5. Do not fabricate search results, sources, or real-time data.
|
|
98
|
+
6. If you cannot access reliable real-time information from the internet, clearly and honestly state that real-time retrieval was not possible, then provide the best available general information with that limitation noted.
|
|
104
99
|
|
|
105
|
-
Output
|
|
106
|
-
-
|
|
107
|
-
-
|
|
108
|
-
-
|
|
100
|
+
Output style:
|
|
101
|
+
- Start with a brief direct answer.
|
|
102
|
+
- Then provide a structured summary of findings.
|
|
103
|
+
- End with a "Sources" section listing the origin of the information used.`;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* This file is part of the NocoBase (R) project.
|
|
3
|
+
* Copyright (c) 2020-2024 NocoBase Co., Ltd.
|
|
4
|
+
* Authors: NocoBase Team.
|
|
5
|
+
*
|
|
6
|
+
* This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
|
|
7
|
+
* For more information, please refer to: https://www.nocobase.com/agreement.
|
|
8
|
+
*/
|
|
9
|
+
|
|
10
|
+
"use strict";(self.webpackChunk_nocobase_plugin_ai=self.webpackChunk_nocobase_plugin_ai||[]).push([["119"],{4498:function(e,t,n){n.r(t),n.d(t,{CodeToolCard:function(){return y},buildToolCodeBlock:function(){return g},compactPatchForDisplay:function(){return f},shouldSkipCodeToolCardRender:function(){return p}});var r=n(9155),o=n.n(r),l=n(5475),a=n(4281);function i(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function c(e){return function(e){if(Array.isArray(e))return i(e)}(e)||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e){if(e){if("string"==typeof e)return i(e,void 0);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return i(e,void 0)}}(e)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function u(e,t){return"writeJSCode"===e?"string"==typeof t.code?t.code:void 0:"patchJSCode"===e&&"string"==typeof t.patch?t.patch:void 0}function s(e){var t=function(e){if("string"!=typeof e)return e;var t=e.trim();if(!t)return{};try{return JSON.parse((0,l.m)(t))}catch(e){return}}(e.args);return t&&(void 0===t?"undefined":t&&"u">typeof Symbol&&t.constructor===Symbol?"symbol":typeof t)=="object"?t:null}function p(e,t){if(!g(e.toolCall))return!1;var n,r=s(t.toolCall);if(!r)return!0;var o=u(e.toolCall.name,null!=(n=s(e.toolCall))?n:{}),l=u(t.toolCall.name,r);return!!o&&(!l||l.length<.8*o.length)}function f(e){for(var t,n=e&&null!=(t=e.match(/[^\n]*\n|[^\n]+/g))?t:[],r=[],o=0;o<n.length;){var l=n[o];if(!l.startsWith("@@ ")){r.push(l),o++;continue}r.push(l),o++;for(var a=[];o<n.length&&!n[o].startsWith("@@ ");)a.push(n[o]),o++;r.push.apply(r,c(function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:3,n=e.reduce(function(e,t,n){return(t.startsWith("+")||t.startsWith("-"))&&e.push(n),e},[]);if(!n.length||e.length<=80)return e;var r=new Set,o=!0,l=!1,a=void 0;try{for(var i,u=n[Symbol.iterator]();!(o=(i=u.next()).done);o=!0)for(var s=i.value,p=Math.max(0,s-t);p<=Math.min(e.length-1,s+t);p++)r.add(p)}catch(e){l=!0,a=e}finally{try{o||null==u.return||u.return()}finally{if(l)throw a}}var f=[],g=-1,y=!0,d=!1,m=void 0;try{for(var b,h=c(r).sort(function(e,t){return e-t})[Symbol.iterator]();!(y=(b=h.next()).done);y=!0){var v=b.value;-1!==g&&v>g+1&&f.push(" ...\n"),f.push(e[v]),g=v}}catch(e){d=!0,m=e}finally{try{y||null==h.return||h.return()}finally{if(d)throw m}}return f}(function(e){for(var t=[],n=0;n<e.length;){var r=e[n],o=e[n+1];if((null==r?void 0:r.startsWith("-"))&&(null==o?void 0:o.startsWith("+"))&&!r.startsWith("---")&&!o.startsWith("+++")&&r.slice(1)===o.slice(1)){t.push(" ".concat(r.slice(1))),n+=2;continue}t.push(r),n++}return t}(a))))}return r.join("")}function g(e){var t=s(e);return t?"writeJSCode"===e.name&&"string"==typeof t.code&&t.code?{language:"js",value:t.code}:"patchJSCode"===e.name&&"string"==typeof t.patch&&t.patch?{language:"diff",value:f(t.patch)}:null:null}var y=o().memo(function(e){var t=g(e.toolCall);return t?o().createElement("div",{style:{padding:"4px 12px"}},o().createElement(a.w,{className:"language-".concat(t.language)},t.value)):null},p)},4281:function(e,t,n){n.d(t,{w:function(){return S},Rs:function(){return C},Cy:function(){return P}});var r=n(9155),o=n.n(r),l=n(2059),a=n(7375),i=n(3342),c=n(3079),u=n(8680),s=n(7694),p=n(7546),f=n(7596);function g(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},r=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(n).filter(function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))),r.forEach(function(t){var r;r=n[t],t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r})}return e}function y(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t.push.apply(t,n)}return t})(Object(t)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}),e}function d(e,t){if(null==e)return{};var n,r,o,l={};if("u">typeof Reflect&&Reflect.ownKeys){for(o=0,n=Reflect.ownKeys(Object(e));o<n.length;o++)r=n[o],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(l[r]=e[r]);return l}if(l=function(e,t){if(null==e)return{};var n,r,o={},l=Object.getOwnPropertyNames(e);for(r=0;r<l.length;r++)n=l[r],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n]);return o}(e,t),Object.getOwnPropertySymbols)for(o=0,n=Object.getOwnPropertySymbols(e);o<n.length;o++)r=n[o],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(l[r]=e[r]);return l}var m=(0,i.lazy)(function(){return Promise.all([n.e("428"),n.e("758")]).then(n.bind(n,2733))},"CodeHighlight").CodeHighlight,b=function(e){var t=e.language,n=e.value,r=e.height,l=e.scrollToBottom,a=d(e,["language","value","height","scrollToBottom"]);return o().createElement(m,y(g({},a),{language:t,value:n,height:r,scrollToBottom:l}))},h=function(e){var t=(0,s.useFlowContext)(),n=(0,c.kj)(),r=f.J.use.currentConversation(),i=(0,p.Y)(r),u=e.children,m=e.className,h=(e.node,e.message),O=d(e,["children","className","node","message"]),w=/language-(\w+)/.exec(m||""),E=w?w[1]:"",j=String(u).replace(/<!--[\s\S]*?-->/g,"").replace(/\n$/,""),C=l.App.useApp().message,S=!0;(null==h?void 0:h.type)==="text"&&(S=RegExp("```"+E+"[\\s\\S]*?```","s").test(h.content));var P=i.use.editorRef()[i.use.currentEditorRefUid()];return w?o().createElement(l.Card,{type:"inner",size:"small",title:o().createElement(l.Space,{style:{margin:"0 8px"},size:"middle"},o().createElement(a.CodeOutlined,null),o().createElement("span",null,E)),extra:o().createElement(o().Fragment,null,o().createElement(l.Tooltip,{title:n("Copy")},o().createElement(l.Button,{type:"text",icon:o().createElement(a.CopyOutlined,null),onClick:function(){navigator.clipboard.writeText(j),C.success(n("Copied"))}})),o().createElement(l.Divider,{type:"vertical"}),o().createElement(l.Tooltip,{title:n("Expand")},o().createElement(l.Button,{type:"text",icon:o().createElement(a.ExpandOutlined,null),onClick:function(){t.viewer.dialog({width:"80%",zIndex:6e3,content:o().createElement(v,y(g({},O),{language:E,value:j,height:"75vh"}))})}}))),styles:{header:{padding:0},body:{padding:0}},actions:P?[o().createElement(l.Button,{key:"accept",type:"link",onClick:function(e){e.stopPropagation(),null==P||P.write(j),t.message.info(n("Applied"))},disabled:!S},n("Apply to editor"))]:[]},o().createElement(b,y(g({},O),{language:E,value:j,scrollToBottom:!S}))):o().createElement(l.Typography.Text,y(g({code:!0},O),{className:m}),u)},v=function(e){var t=e.language,n=e.value,r=d(e,["language","value"]),i=(0,s.useFlowViewContext)(),c=i.view.Header,u=o().createElement(l.Button,{type:"text",icon:o().createElement(a.CloseOutlined,null),onClick:function(){i.view.close()}});return o().createElement("div",{style:{borderRadius:8}},o().createElement(c,{title:o().createElement(o().Fragment,null,o().createElement(l.Space,null,u,o().createElement("span",null,t)))}),o().createElement(b,y(g({},r),{language:t,value:n})))};function O(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},r=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(n).filter(function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))),r.forEach(function(t){var r;r=n[t],t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r})}return e}function w(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t.push.apply(t,n)}return t})(Object(t)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}),e}function E(e,t){if(null==e)return{};var n,r,o,l={};if("u">typeof Reflect&&Reflect.ownKeys){for(o=0,n=Reflect.ownKeys(Object(e));o<n.length;o++)r=n[o],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(l[r]=e[r]);return l}if(l=function(e,t){if(null==e)return{};var n,r,o={},l=Object.getOwnPropertyNames(e);for(r=0;r<l.length;r++)n=l[r],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n]);return o}(e,t),Object.getOwnPropertySymbols)for(o=0,n=Object.getOwnPropertySymbols(e);o<n.length;o++)r=n[o],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(l[r]=e[r]);return l}var j=(0,i.lazy)(function(){return Promise.all([n.e("428"),n.e("758")]).then(n.bind(n,2733))},"CodeHighlight").CodeHighlight,C=function(e){var t=e.language,n=e.value,r=E(e,["language","value"]);return o().createElement(j,w(O({},r),{language:t,value:n}))},S=function(e){var t=e.children,n=e.className,r=(e.node,e.message,E(e,["children","className","node","message"])),u=/language-(\w+)/.exec(n||""),s=u?u[1]:"",p=(0,i.useToken)().token,f=(0,c.kj)(),g=String(t).replace(/\n$/,""),y=l.App.useApp().message;return u?o().createElement(l.Card,{size:"small",title:s,styles:{title:{fontSize:p.fontSize,fontWeight:400},body:{width:"100%",fontSize:p.fontSizeSM}},extra:o().createElement(l.Button,{variant:"link",color:"default",size:"small",onClick:function(){navigator.clipboard.writeText(g),y.success(f("Copied"))},icon:o().createElement(a.CopyOutlined,null)})},o().createElement(C,w(O({},r),{language:s,value:g}))):o().createElement(l.Typography.Text,w(O({code:!0},r),{className:n}),t)},P=function(e){var t=e.className,n=/language-(\w+)/.exec(t||""),r=n?n[1]:"",l=f.J.use.currentConversation(),a=(0,p.Y)(l);return a.use.editorRef()[a.use.currentEditorRefUid()]&&(0,u._t)(r)?o().createElement(h,e):o().createElement(S,e)}}}]);
|