only filter </think> for assistant msg
This commit is contained in:
parent
7b3ac17c7b
commit
4395d70d39
1 changed files with 3 additions and 1 deletions
|
@ -693,7 +693,9 @@ function filterThoughtFromMsgs(messages) {
|
|||
return messages.map((msg) => {
|
||||
return {
|
||||
role: msg.role,
|
||||
content: msg.content.split('</think>').at(-1).trim(),
|
||||
content: msg.role === 'assistant'
|
||||
? msg.content.split('</think>').at(-1).trim()
|
||||
: msg.content,
|
||||
};
|
||||
});
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue