diff --git a/apps/web/src/features/conversation/components/ConversationView.tsx b/apps/web/src/features/conversation/components/ConversationView.tsx index 7ccea77..d1b2180 100644 --- a/apps/web/src/features/conversation/components/ConversationView.tsx +++ b/apps/web/src/features/conversation/components/ConversationView.tsx @@ -32,6 +32,9 @@ export function ConversationView(props: Props) { const chat = useChat(props.skey, { onTurnStarted: () => stick.pin() }) // While another tab holds the local copy, the banner over the page says why it is waiting. const { info, messages, branch, waiting, running } = chat + // Called apart from `chat`, which changes with every update, so the callbacks every message gets + // stay the same and an unchanged message doesn't render again. + const { regenerate, regenerating, stop } = chat const me = useMe() const { models } = useModels() const actions = useConversationActions(props.skey) @@ -56,8 +59,8 @@ export function ConversationView(props: Props) { const operations: ConversationOperations = { edit: setEditingRkey, quote: (text) => composer.current?.quote(text), - regenerate: chat.regenerate, - stop: chat.stop, + regenerate, + stop, models, storedIn: me.storageMode === 'space' @@ -109,9 +112,9 @@ export function ConversationView(props: Props) {