Fix: Remove duplicate text output from the thought model on the chat page. (#14301)

### What problem does this PR solve?

Fix: Remove duplicate text output from the thought model on the chat
page.

### Type of change

- [x] Bug Fix (non-breaking change which fixes an issue)
This commit is contained in:
balibabu
2026-04-22 23:22:51 +08:00
committed by GitHub
parent 01753b8f31
commit ffa8738a78

View File

@@ -275,7 +275,7 @@ export const useSendMessageWithSse = () => {
if (typeof d !== 'boolean') {
setAnswer((prev) => {
const prevAnswer = prev.answer || '';
const currentAnswer = d.answer || '';
const currentAnswer = d.final ? '' : d.answer || '';
let newAnswer: string;
if (prevAnswer && currentAnswer.startsWith(prevAnswer)) {