mirror of https://github.com/langgenius/dify.git
fix: agent thought replaced by response text (#20571)
This commit is contained in:
parent
d6b30efe2c
commit
744159a079
|
|
@ -366,8 +366,9 @@ export const useChat = (
|
|||
if (!newResponseItem)
|
||||
return
|
||||
|
||||
const isUseAgentThought = newResponseItem.agent_thoughts?.length > 0
|
||||
updateChatTreeNode(responseItem.id, {
|
||||
content: newResponseItem.answer,
|
||||
content: isUseAgentThought ? '' : newResponseItem.answer,
|
||||
log: [
|
||||
...newResponseItem.message,
|
||||
...(newResponseItem.message[newResponseItem.message.length - 1].role !== 'assistant'
|
||||
|
|
|
|||
Loading…
Reference in New Issue