Skip to content

Commit

Permalink
Fixing logic
Browse files Browse the repository at this point in the history
  • Loading branch information
Konstantin Krestnikov authored and Konstantin Krestnikov committed Mar 6, 2024
1 parent bb0d87b commit 44d8165
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions src/gigachat/models/chat_completion_chunk.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from typing import List, Optional
from typing import List

from gigachat.models.choices_chunk import ChoicesChunk
from gigachat.pydantic_v1 import BaseModel, Field
Expand All @@ -13,5 +13,5 @@ class ChatCompletionChunk(BaseModel):
"""Дата и время создания ответа в формате Unix time"""
model: str
"""Название модели, которая вернула ответ"""
object_: object = Optional[Field(default=None, alias="object")]
object_: str = Field(alias="object")
"""Название вызываемого метода"""
2 changes: 1 addition & 1 deletion src/gigachat/models/messages_chunk.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ class MessagesChunk(BaseModel):

role: Optional[MessagesRole] = None
"""Роль автора сообщения"""
content: Optional[str] = None
content: str
"""Текст сообщения"""
function_call: Optional[FunctionCall] = None
"""Вызов функции"""

0 comments on commit 44d8165

Please sign in to comment.