mirror of
https://github.com/labring/FastGPT.git
synced 2025-07-22 20:37:48 +00:00
User select node (#2397)
* feat: add user select node (#2300) * feat: add user select node * fix * type * fix * fix * fix * perf: user select code * perf: user select histories * perf: i18n --------- Co-authored-by: heheer <heheer@sealos.io>
This commit is contained in:
@@ -212,6 +212,8 @@ export const iconPaths = {
|
||||
'core/workflow/template/textConcat': () =>
|
||||
import('./icons/core/workflow/template/textConcat.svg'),
|
||||
'core/workflow/template/toolCall': () => import('./icons/core/workflow/template/toolCall.svg'),
|
||||
'core/workflow/template/userSelect': () =>
|
||||
import('./icons/core/workflow/template/userSelect.svg'),
|
||||
'core/workflow/template/variable': () => import('./icons/core/workflow/template/variable.svg'),
|
||||
'core/workflow/template/variableUpdate': () =>
|
||||
import('./icons/core/workflow/template/variableUpdate.svg'),
|
||||
|
@@ -0,0 +1,10 @@
|
||||
<svg viewBox="0 0 32 32" fill="none" xmlns="http://www.w3.org/2000/svg">
|
||||
<rect width="32" height="32" rx="6" fill="url(#paint0_linear_8765_6055)"/>
|
||||
<path fill-rule="evenodd" clip-rule="evenodd" d="M10.6666 7.11108C8.70296 7.11108 7.11108 8.70296 7.11108 10.6666V21.3333C7.11108 23.297 8.70296 24.8889 10.6666 24.8889H21.3333C23.297 24.8889 24.8889 23.297 24.8889 21.3333V10.6666C24.8889 8.70296 23.297 7.11108 21.3333 7.11108H10.6666ZM14.4283 12.586C14.7407 12.2736 14.7407 11.7671 14.4283 11.4547C14.1159 11.1422 13.6094 11.1422 13.2969 11.4547L11.5654 13.1862L10.9314 12.5522C10.619 12.2398 10.1124 12.2398 9.80002 12.5522C9.4876 12.8646 9.4876 13.3712 9.80001 13.6836L10.9973 14.8809C11.1537 15.0372 11.3586 15.1153 11.5636 15.1152C11.7697 15.1163 11.9762 15.0382 12.1335 14.8809L14.4283 12.586ZM22.4342 13.1678C22.4342 13.6096 22.0761 13.9678 21.6342 13.9678H16.8278C16.386 13.9678 16.0278 13.6096 16.0278 13.1678C16.0278 12.7259 16.386 12.3678 16.8278 12.3678L21.6342 12.3678C22.0761 12.3678 22.4342 12.7259 22.4342 13.1678ZM11.8673 21.111C12.7509 21.111 13.4673 20.3946 13.4673 19.511C13.4673 18.6273 12.7509 17.911 11.8673 17.911C10.9836 17.911 10.2673 18.6273 10.2673 19.511C10.2673 20.3946 10.9836 21.111 11.8673 21.111ZM22.4342 19.511C22.4342 19.9528 22.0761 20.311 21.6342 20.311H16.8278C16.386 20.311 16.0278 19.9528 16.0278 19.511C16.0278 19.0691 16.386 18.711 16.8278 18.711H21.6342C22.0761 18.711 22.4342 19.0691 22.4342 19.511Z" fill="white"/>
|
||||
<defs>
|
||||
<linearGradient id="paint0_linear_8765_6055" x1="16" y1="0" x2="4.88889" y2="29.3333" gradientUnits="userSpaceOnUse">
|
||||
<stop stop-color="#3ED9AA"/>
|
||||
<stop offset="1" stop-color="#13C786"/>
|
||||
</linearGradient>
|
||||
</defs>
|
||||
</svg>
|
After Width: | Height: | Size: 1.6 KiB |
@@ -1 +1,4 @@
|
||||
<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg t="1688632968712" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="3386" xmlns:xlink="http://www.w3.org/1999/xlink" ><path d="M507.904 52.224q95.232 0 179.2 36.352t145.92 98.304 98.304 145.408 36.352 178.688-36.352 179.2-98.304 145.92-145.92 98.304-179.2 36.352-178.688-36.352-145.408-98.304-98.304-145.92-36.352-179.2 36.352-178.688 98.304-145.408 145.408-98.304 178.688-36.352zM736.256 573.44q30.72 0 55.296-15.872t24.576-47.616q0-30.72-24.576-45.568t-55.296-14.848l-452.608 0q-30.72 0-56.32 14.848t-25.6 45.568q0 31.744 25.6 47.616t56.32 15.872l452.608 0z" p-id="3387"></path></svg>
|
||||
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 17" >
|
||||
<path d="M5.33342 7.80417C4.99499 7.80417 4.72063 8.07852 4.72063 8.41695C4.72063 8.75538 4.99499 9.02974 5.33342 9.02974H10.6667C11.0052 9.02974 11.2795 8.75538 11.2795 8.41695C11.2795 8.07852 11.0052 7.80417 10.6667 7.80417H5.33342Z" />
|
||||
<path fill-rule="evenodd" clip-rule="evenodd" d="M14.7901 8.41695C14.7901 12.167 11.7501 15.207 8.00008 15.207C4.25007 15.207 1.21008 12.167 1.21008 8.41695C1.21008 4.66694 4.25007 1.62695 8.00008 1.62695C11.7501 1.62695 14.7901 4.66694 14.7901 8.41695ZM13.4567 8.41695C13.4567 11.4306 11.0137 13.8736 8.00008 13.8736C4.98645 13.8736 2.54342 11.4306 2.54342 8.41695C2.54342 5.40332 4.98645 2.96029 8.00008 2.96029C11.0137 2.96029 13.4567 5.40332 13.4567 8.41695Z"/>
|
||||
</svg>
|
Before Width: | Height: | Size: 768 B After Width: | Height: | Size: 778 B |
@@ -17,6 +17,11 @@ export const workflowNodeTemplateList = [
|
||||
label: i18nT('common:core.workflow.template.Search'),
|
||||
list: []
|
||||
},
|
||||
{
|
||||
type: FlowNodeTemplateTypeEnum.interactive,
|
||||
label: i18nT('common:core.workflow.template.Interactive'),
|
||||
list: []
|
||||
},
|
||||
{
|
||||
type: FlowNodeTemplateTypeEnum.multimodal,
|
||||
label: i18nT('common:core.workflow.template.Multimodal'),
|
||||
|
@@ -141,14 +141,20 @@
|
||||
"workflow": {
|
||||
"Input guide": "Input guide",
|
||||
"file_url": "Url",
|
||||
"option1": "Option 1",
|
||||
"option2": "Option 2",
|
||||
"read_files": "Documents parse",
|
||||
"read_files_result": "Document parsing results",
|
||||
"read_files_result_desc": "The original text of the document consists of the file name and the document content. Multiple files are separated by horizontal lines.",
|
||||
"read_files_tip": "Parse all uploaded documents in the conversation and return the corresponding document content",
|
||||
"select_description": "Select description",
|
||||
"select_result": "Select result",
|
||||
"template": {
|
||||
"communication": "Communication"
|
||||
},
|
||||
"user_file_input": "Files url",
|
||||
"user_file_input_desc": "Links to documents and images uploaded by users"
|
||||
"user_file_input_desc": "Links to documents and images uploaded by users",
|
||||
"user_select": "User select",
|
||||
"user_select_tip": "The module can have multiple options that lead to different workflow branches"
|
||||
}
|
||||
}
|
||||
|
@@ -1,6 +1,5 @@
|
||||
{
|
||||
"Delete_all": "Delete all",
|
||||
"delete_all_input_guide_confirm": "Confirm to delete all input guide lexicons",
|
||||
"chat_history": "chat record",
|
||||
"chat_input_guide_lexicon_is_empty": "No vocabulary has been configured yet",
|
||||
"citations": "{{num}} citations",
|
||||
@@ -13,25 +12,27 @@
|
||||
"contextual_preview": "Contextual preview",
|
||||
"csv_input_lexicon_tip": "Only supports CSV batch import, click to download the template",
|
||||
"custom_input_guide_url": "Custom thesaurus address",
|
||||
"delete_all_input_guide_confirm": "Confirm to delete all input guide lexicons",
|
||||
"empty_directory": "There is nothing left to choose from in this directory~",
|
||||
"file_amount_over": "Exceed maximum number of files {{max}}",
|
||||
"in_progress": "in progress",
|
||||
"input_guide": "Input guide",
|
||||
"input_guide_lexicon": "Lexicon",
|
||||
"input_guide_tip": "You can configure some preset questions. When the user enters a question, the relevant question is retrieved from these preset questions for prompt.",
|
||||
"insert_input_guide,_some_data_already_exists": "Duplicate data, automatically filtered, insert: {{len}} data",
|
||||
"is_chatting": "Chatting...please wait for the end",
|
||||
"items": "strip",
|
||||
"module_runtime_and": "module run time and",
|
||||
"multiple_AI_conversations": "Multiple AI conversations",
|
||||
"new_chat": "new conversation",
|
||||
"new_input_guide_lexicon": "New lexicon",
|
||||
"no_workflow_response": "No running data",
|
||||
"plugins_output": "Plugin output",
|
||||
"question_tip": "From left to right, the response order of each module",
|
||||
"rearrangement": "Search results rearranged",
|
||||
"select_file": "Select file",
|
||||
"select_img": "Select images",
|
||||
"stream_output": "stream output",
|
||||
"view_citations": "View citations",
|
||||
"web_site_sync": "Web site synchronization",
|
||||
"file_amount_over": "Exceed maximum number of files {{max}}",
|
||||
"input_guide": "Input guide",
|
||||
"input_guide_lexicon": "Lexicon",
|
||||
"input_guide_tip": "You can configure some preset questions. When the user enters a question, the relevant question is retrieved from these preset questions for prompt.",
|
||||
"insert_input_guide,_some_data_already_exists": "Duplicate data, automatically filtered, insert: {{len}} data",
|
||||
"new_input_guide_lexicon": "New lexicon",
|
||||
"select_file": "Select file",
|
||||
"select_img": "Select images"
|
||||
"web_site_sync": "Web site synchronization"
|
||||
}
|
||||
|
@@ -527,7 +527,8 @@
|
||||
"module tokens": "total tokens",
|
||||
"plugin output": "Plugin output value",
|
||||
"search using reRank": "Result rearrangement",
|
||||
"text output": "text output"
|
||||
"text output": "text output",
|
||||
"user_select_result": "User select result"
|
||||
},
|
||||
"retry": "Regenerate",
|
||||
"tts": {
|
||||
@@ -761,6 +762,7 @@
|
||||
},
|
||||
"module": {
|
||||
"Add question type": "Add question type",
|
||||
"Add_option": "Add option",
|
||||
"Can not connect self": "Cannot connect to self",
|
||||
"Confirm Delete Node": "Confirm delete node?",
|
||||
"Data Type": "Data type",
|
||||
@@ -771,6 +773,7 @@
|
||||
"Default Value": "Default value",
|
||||
"Default value": "Default value",
|
||||
"Default value placeholder": "If not filled, the default return is an empty string",
|
||||
"Diagram": "Diagram",
|
||||
"Edit intro": "Edit description",
|
||||
"Field Description": "Field description",
|
||||
"Field Name": "Field name",
|
||||
@@ -948,7 +951,9 @@
|
||||
"OnRevert version confirm": "Confirm to revert to this version? It will save the configuration of the version being edited and create a new published version for the reverted version.",
|
||||
"histories": "Publishing records"
|
||||
},
|
||||
"run_test": "Test",
|
||||
"template": {
|
||||
"Interactive": "Interactive",
|
||||
"Multimodal": "Multimodal",
|
||||
"Search": "Search"
|
||||
},
|
||||
@@ -1060,6 +1065,7 @@
|
||||
"no_data": "No data",
|
||||
"no_laf_env": "The system is not configured with Laf environment",
|
||||
"not_yet_introduced": "No introduction yet",
|
||||
"option": "Option",
|
||||
"pay": {
|
||||
"amount": "Amount",
|
||||
"balance": "Account balance",
|
||||
|
@@ -29,6 +29,8 @@
|
||||
"Custom outputs": "Custom outputs",
|
||||
"Error": "Error",
|
||||
"Read file result": "Document parsing result preview",
|
||||
"User_select_description": "User select description",
|
||||
"User_select_result": "User select result",
|
||||
"read files": "parsed document"
|
||||
},
|
||||
"template": {
|
||||
|
@@ -143,14 +143,20 @@
|
||||
"workflow": {
|
||||
"Input guide": "填写说明",
|
||||
"file_url": "文档链接",
|
||||
"option1": "选项 1",
|
||||
"option2": "选项 2",
|
||||
"read_files": "文档解析",
|
||||
"read_files_result": "文档解析结果",
|
||||
"read_files_result_desc": "文档原文,由文件名和文档内容组成,多个文件之间通过横线隔开。",
|
||||
"read_files_tip": "解析对话中所有上传的文档,并返回对应文档内容",
|
||||
"select_description": "说明文字",
|
||||
"select_result": "选择的结果",
|
||||
"template": {
|
||||
"communication": "通信"
|
||||
},
|
||||
"user_file_input": "文件链接",
|
||||
"user_file_input_desc": "用户上传的文档和图片链接"
|
||||
"user_file_input_desc": "用户上传的文档和图片链接",
|
||||
"user_select": "用户选择",
|
||||
"user_select_tip": "该模块可配置多个选项,以供对话时选择。不同选项可导向不同工作流支线"
|
||||
}
|
||||
}
|
||||
|
@@ -1,37 +1,38 @@
|
||||
{
|
||||
"Delete_all": "清空词库",
|
||||
"chat_history": "聊天记录",
|
||||
"chat_input_guide_lexicon_is_empty": "还没有配置词库",
|
||||
"citations": "{{num}}条引用",
|
||||
"click_contextual_preview": "点击查看上下文预览",
|
||||
"config_input_guide": "配置输入引导",
|
||||
"config_input_guide_lexicon": "配置词库",
|
||||
"config_input_guide_lexicon_title": "配置词库",
|
||||
"content_empty": "内容为空",
|
||||
"contextual": "{{num}}条上下文",
|
||||
"contextual_preview": "上下文预览 {{num}} 条",
|
||||
"csv_input_lexicon_tip": "仅支持 CSV 批量导入,点击下载模板",
|
||||
"custom_input_guide_url": "自定义词库地址",
|
||||
"delete_all_input_guide_confirm": "确定要清空输入引导词库吗?",
|
||||
"empty_directory": "这个目录已经没东西可选了~",
|
||||
"file_amount_over": "超出最大文件数量 {{max}}",
|
||||
"in_progress": "进行中",
|
||||
"input_guide": "输入引导",
|
||||
"input_guide_lexicon": "词库",
|
||||
"input_guide_tip": "可以配置一些预设的问题。在用户输入问题时,会从这些预设问题中获取相关问题进行提示。",
|
||||
"insert_input_guide,_some_data_already_exists": "有重复数据,已自动过滤,共插入 {{len}} 条数据",
|
||||
"new_input_guide_lexicon": "新词库",
|
||||
"is_chatting": "正在聊天中...请等待结束",
|
||||
"content_empty": "内容为空",
|
||||
"contextual": "{{num}}条上下文",
|
||||
"contextual_preview": "上下文预览 {{num}} 条",
|
||||
"items": "条",
|
||||
"view_citations": "查看引用",
|
||||
"citations": "{{num}}条引用",
|
||||
"click_contextual_preview": "点击查看上下文预览",
|
||||
"multiple_AI_conversations": "多组 AI 对话",
|
||||
"module_runtime_and": "模块运行时间和",
|
||||
"empty_directory": "这个目录已经没东西可选了~",
|
||||
"chat_history": "聊天记录",
|
||||
"stream_output": "流输出",
|
||||
"multiple_AI_conversations": "多组 AI 对话",
|
||||
"new_chat": "新对话",
|
||||
"new_input_guide_lexicon": "新词库",
|
||||
"no_workflow_response": "没有运行数据",
|
||||
"plugins_output": "插件输出",
|
||||
"in_progress": "进行中",
|
||||
"question_tip": "从上到下,为各个模块的响应顺序",
|
||||
"rearrangement": "检索结果重排",
|
||||
"web_site_sync": "Web站点同步",
|
||||
"new_chat": "新对话",
|
||||
"select_file": "选择文件",
|
||||
"select_img": "选择图片"
|
||||
"select_img": "选择图片",
|
||||
"stream_output": "流输出",
|
||||
"view_citations": "查看引用",
|
||||
"web_site_sync": "Web站点同步"
|
||||
}
|
||||
|
@@ -537,7 +537,8 @@
|
||||
"module tokens": "总 tokens",
|
||||
"plugin output": "插件输出值",
|
||||
"search using reRank": "结果重排",
|
||||
"text output": "文本输出"
|
||||
"text output": "文本输出",
|
||||
"user_select_result": "用户选择结果"
|
||||
},
|
||||
"retry": "重新生成",
|
||||
"tts": {
|
||||
@@ -771,6 +772,7 @@
|
||||
},
|
||||
"module": {
|
||||
"Add question type": "添加问题类型",
|
||||
"Add_option": "添加选项",
|
||||
"Can not connect self": "不能连接自身",
|
||||
"Confirm Delete Node": "确认删除该节点?",
|
||||
"Data Type": "数据类型",
|
||||
@@ -781,6 +783,7 @@
|
||||
"Default Value": "默认值",
|
||||
"Default value": "默认值",
|
||||
"Default value placeholder": "不填则默认返回空字符",
|
||||
"Diagram": "示意图",
|
||||
"Edit intro": "编辑描述",
|
||||
"Field Description": "字段描述",
|
||||
"Field Name": "字段名",
|
||||
@@ -958,7 +961,9 @@
|
||||
"OnRevert version confirm": "确认回退至该版本?会为您保存编辑中版本的配置,并为回退版本创建一个新的发布版本。",
|
||||
"histories": "发布记录"
|
||||
},
|
||||
"run_test": "运行",
|
||||
"template": {
|
||||
"Interactive": "交互",
|
||||
"Multimodal": "多模态",
|
||||
"Search": "搜索"
|
||||
},
|
||||
@@ -1070,6 +1075,7 @@
|
||||
"no_data": "暂无数据",
|
||||
"no_laf_env": "系统未配置Laf环境",
|
||||
"not_yet_introduced": "暂无介绍",
|
||||
"option": "选项",
|
||||
"pay": {
|
||||
"amount": "金额",
|
||||
"balance": "账号余额",
|
||||
|
@@ -6,7 +6,9 @@
|
||||
"Reset template confirm": "确认还原代码模板?将会重置所有输入和输出至模板值,请注意保存当前代码。"
|
||||
},
|
||||
"confirm_delete_field_tip": "确认删除该字段?",
|
||||
"create_link_error": "创建链接异常",
|
||||
"custom_input": "自定义输入",
|
||||
"delete_api": "确认删除该API密钥?删除后该密钥立即失效,对应的对话日志不会删除,请确认!",
|
||||
"edit_input": "编辑输入",
|
||||
"field_description": "字段描述",
|
||||
"field_description_placeholder": "描述该输入字段的功能,如果为工具调用参数,则该描述会影响模型生成的质量",
|
||||
@@ -27,6 +29,8 @@
|
||||
"Custom outputs": "自定义输出",
|
||||
"Error": "错误信息",
|
||||
"Read file result": "文档解析结果预览",
|
||||
"User_select_description": "说明文字",
|
||||
"User_select_result": "选择的结果",
|
||||
"read files": "解析的文档"
|
||||
},
|
||||
"template": {
|
||||
@@ -40,8 +44,6 @@
|
||||
"workflow_start": "流程开始"
|
||||
},
|
||||
"tool_input": "工具参数",
|
||||
"variable_picker_tips": "可输入节点名或变量名搜索",
|
||||
"delete_api": "确认删除该API密钥?删除后该密钥立即失效,对应的对话日志不会删除,请确认!",
|
||||
"create_link_error": "创建链接异常",
|
||||
"update_link_error": "更新链接异常"
|
||||
"update_link_error": "更新链接异常",
|
||||
"variable_picker_tips": "可输入节点名或变量名搜索"
|
||||
}
|
||||
|
@@ -34,6 +34,7 @@ const Button = defineStyleConfig({
|
||||
transform: 'scale(0.98)'
|
||||
},
|
||||
_disabled: {
|
||||
transform: 'none !important',
|
||||
_hover: {
|
||||
filter: 'none'
|
||||
}
|
||||
|
Reference in New Issue
Block a user