mirror of
https://github.com/theroyallab/tabbyAPI.git
synced 2026-04-28 10:11:39 +00:00
API: Add tool_call_id for role = tool
If a message with role = tool is present, the tool_call_id should also be given to the template. Signed-off-by: kingbri <8082010+kingbri1@users.noreply.github.com>
This commit is contained in:
@@ -1,5 +1,4 @@
|
||||
from pydantic import AliasChoices, BaseModel, Field, field_validator
|
||||
from pydantic.json_schema import SkipJsonSchema
|
||||
from time import time
|
||||
from typing import Literal, Union, List, Optional, Dict
|
||||
from uuid import uuid4
|
||||
@@ -32,7 +31,7 @@ class ChatCompletionMessage(BaseModel):
|
||||
role: str = "user"
|
||||
content: Optional[Union[str, List[ChatCompletionMessagePart]]] = None
|
||||
tool_calls: Optional[List[ToolCall]] = None
|
||||
tool_calls_json: SkipJsonSchema[Optional[str]] = None
|
||||
tool_call_id: Optional[str] = None
|
||||
|
||||
|
||||
class ChatCompletionRespChoice(BaseModel):
|
||||
|
||||
Reference in New Issue
Block a user