Update utils.py

fix for #2655
This commit is contained in:
Tasha Upchurch 2024-03-22 23:13:24 -04:00 committed by GitHub
parent 42a7588b04
commit 9201c122e7
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -497,7 +497,7 @@ class ModelResponse(OpenAIObject):
object = "embedding" object = "embedding"
else: else:
object = "chat.completion" object = "chat.completion"
choices = [Choices()] choices = [Choices(*choices)]
if id is None: if id is None:
id = _generate_id() id = _generate_id()
else: else: