From 48567fd468a782392f5340504e779d026324a454 Mon Sep 17 00:00:00 2001 From: Debanjum Date: Sun, 17 Nov 2024 16:29:18 -0800 Subject: [PATCH] Do not erase partial message when generation stopped via button on web app Previously, we'd replace the generated message with an error message when message generation stopped via stop button on chat page of web app. So the partially generated message (which could be useful) gets lost. This change just stops generation, while keeping the generated response so any useful information from the partially generated message can be retrieved. --- src/interface/web/app/chat/page.tsx | 1 - 1 file changed, 1 deletion(-) diff --git a/src/interface/web/app/chat/page.tsx b/src/interface/web/app/chat/page.tsx index 56c53d1b..5a391b4d 100644 --- a/src/interface/web/app/chat/page.tsx +++ b/src/interface/web/app/chat/page.tsx @@ -303,7 +303,6 @@ export default function Chat() { const currentMessage = messages.find((message) => !message.completed); if (!currentMessage) return; - currentMessage.rawResponse = `I've stopped processing this message. If you'd like to continue, please send another message.`; currentMessage.completed = true; setMessages([...messages]); setQueryToProcess("");