mirror of
https://github.com/BerriAI/litellm.git
synced 2025-04-27 11:43:54 +00:00
fix(utils.py): fix streaming to not return usage dict
Fixes https://github.com/BerriAI/litellm/issues/3237
This commit is contained in:
parent
facc5f65aa
commit
b10f03706d
24 changed files with 107 additions and 83 deletions
|
@ -223,7 +223,7 @@ class OpenAITextCompletionConfig:
|
|||
model_response_object.choices = choice_list
|
||||
|
||||
if "usage" in response_object:
|
||||
model_response_object.usage = response_object["usage"]
|
||||
setattr(model_response_object, "usage", response_object["usage"])
|
||||
|
||||
if "id" in response_object:
|
||||
model_response_object.id = response_object["id"]
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue