mirror of
https://github.com/ChatGPTNextWeb/ChatGPT-Next-Web.git
synced 2025-05-20 04:30:17 +09:00
parse topic from reasoning model outputs
This commit is contained in:
parent
c0826d2275
commit
a899e9aceb
@ -714,6 +714,12 @@ export const useChatStore = createPersistStore(
|
|||||||
},
|
},
|
||||||
onFinish(message, responseRes) {
|
onFinish(message, responseRes) {
|
||||||
if (responseRes?.status === 200) {
|
if (responseRes?.status === 200) {
|
||||||
|
// deal with <think> and </think> tags
|
||||||
|
if (message.startsWith("<think>")) {
|
||||||
|
message = message
|
||||||
|
.slice(message.indexOf("</think>") + 8)
|
||||||
|
.trim();
|
||||||
|
}
|
||||||
get().updateTargetSession(
|
get().updateTargetSession(
|
||||||
session,
|
session,
|
||||||
(session) =>
|
(session) =>
|
||||||
|
Loading…
Reference in New Issue
Block a user