mirror of
https://github.com/CherryHQ/cherry-studio.git
synced 2025-12-24 10:40:07 +08:00
fix: enable stream output in assistant settings for chat completion (#7240)
This commit is contained in:
parent
34fcf73a95
commit
629f19be32
@ -187,7 +187,7 @@ const HomeWindow: FC = () => {
|
||||
|
||||
fetchChatCompletion({
|
||||
messages: [userMessage],
|
||||
assistant: { ...assistant, model: quickAssistantModel || getDefaultModel() },
|
||||
assistant: { ...assistant, model: quickAssistantModel || getDefaultModel(), settings: { streamOutput: true } },
|
||||
onChunkReceived: (chunk: Chunk) => {
|
||||
if (chunk.type === ChunkType.TEXT_DELTA) {
|
||||
blockContent += chunk.text
|
||||
|
||||
@ -51,7 +51,7 @@ export const processMessages = async (
|
||||
|
||||
await fetchChatCompletion({
|
||||
messages: [userMessage],
|
||||
assistant,
|
||||
assistant: { ...assistant, settings: { streamOutput: true } },
|
||||
onChunkReceived: (chunk: Chunk) => {
|
||||
switch (chunk.type) {
|
||||
case ChunkType.THINKING_DELTA:
|
||||
|
||||
Loading…
Reference in New Issue
Block a user