diff --git a/webapp/packages/supersonic-fe/src/pages/Agent/AgentForm.tsx b/webapp/packages/supersonic-fe/src/pages/Agent/AgentForm.tsx index 9115727c5..b7367c6af 100644 --- a/webapp/packages/supersonic-fe/src/pages/Agent/AgentForm.tsx +++ b/webapp/packages/supersonic-fe/src/pages/Agent/AgentForm.tsx @@ -54,6 +54,7 @@ const AgentForm: React.FC = ({ editAgent, onSaveAgent, onCreateToolBtnCli const initData = { ...editAgent, enableSearch: editAgent.enableSearch !== 0, + enableFeedback: editAgent.enableFeedback !== 0, toolConfig: { ...defaultAgentConfig, ...config }, }; @@ -152,12 +153,13 @@ const AgentForm: React.FC = ({ editAgent, onSaveAgent, onCreateToolBtnCli }) as any, examples: examples.map((example) => example.question), enableSearch: values.enableSearch ? 1 : 0, + enableFeedback: values.enableFeedback ? 1 : 0, chatAppConfig: Object.keys(defaultChatAppConfig).reduce((mergeConfig, key) => { return { ...mergeConfig, [key]: { ...defaultChatAppConfig[key], - ...(values.chatAppConfig[key] ? values.chatAppConfig[key] : {}), + ...(values.chatAppConfig?.[key] ? values.chatAppConfig[key] : {}), }, }; }, {}), @@ -188,6 +190,9 @@ const AgentForm: React.FC = ({ editAgent, onSaveAgent, onCreateToolBtnCli + + + {/* { const [dataSource, setDataSource] = useState([]); const [loading, setLoading] = useState(false); const [filters, setFilters] = useState({}); + const [createModalVisible, setCreateModalVisible] = useState(false); const { question, status, llmReviewRet, humanReviewRet } = filters; const [selectedRowKeys, setSelectedRowKeys] = useState([]); @@ -55,7 +57,7 @@ const MemorySection = ({ agentId }: Props) => { ), }, { - title: '大模型解析SQL', + title: '语义S2SQL', dataIndex: 's2sql', width: 220, valueType: 'textarea', @@ -342,6 +344,17 @@ const MemorySection = ({ agentId }: Props) => { + {agentId && ( + + )} + + + + + + ); + }; + return ( + +
{}} + initialValues={{ + status: StatusEnum.PENDING, + }} + > + + + + +