mirror of
https://github.com/open-webui/open-webui.git
synced 2025-04-12 05:49:05 +02:00
Merge pull request #9010 from Shadowfita/patch-1
fix: Include empty delta object on openai_chat_chunk_message_template per OpenAI API documentation
This commit is contained in:
commit
8c7e52e5a1
@ -149,6 +149,7 @@ def openai_chat_chunk_message_template(
|
||||
template["choices"][0]["delta"] = {"content": message}
|
||||
else:
|
||||
template["choices"][0]["finish_reason"] = "stop"
|
||||
template["choices"][0]["delta"] = {}
|
||||
|
||||
if usage:
|
||||
template["usage"] = usage
|
||||
|
Loading…
x
Reference in New Issue
Block a user