Przeglądaj źródła

fix: agent thought replaced by response text (#20571)

tags/1.4.2
Joel 5 miesięcy temu
rodzic
commit
744159a079
No account linked to committer's email address
1 zmienionych plików z 2 dodań i 1 usunięć
  1. 2
    1
      web/app/components/base/chat/chat/hooks.ts

+ 2
- 1
web/app/components/base/chat/chat/hooks.ts Wyświetl plik

@@ -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'

Ładowanie…
Anuluj
Zapisz