mirror of
https://github.com/wassname/openrouter-python-sdk-retry-errors.git
synced 2026-07-29 11:23:49 +08:00
59 lines
1.5 KiB
Python
59 lines
1.5 KiB
Python
"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT."""
|
|
|
|
from __future__ import annotations
|
|
from openrouter.types import BaseModel
|
|
from typing import Literal, Optional
|
|
from typing_extensions import NotRequired, TypedDict
|
|
|
|
|
|
class ChatStreamToolCallFunctionTypedDict(TypedDict):
|
|
r"""Function call details"""
|
|
|
|
arguments: NotRequired[str]
|
|
r"""Function arguments as JSON string"""
|
|
name: NotRequired[str]
|
|
r"""Function name"""
|
|
|
|
|
|
class ChatStreamToolCallFunction(BaseModel):
|
|
r"""Function call details"""
|
|
|
|
arguments: Optional[str] = None
|
|
r"""Function arguments as JSON string"""
|
|
|
|
name: Optional[str] = None
|
|
r"""Function name"""
|
|
|
|
|
|
ChatStreamToolCallType = Literal["function",]
|
|
r"""Tool call type"""
|
|
|
|
|
|
class ChatStreamToolCallTypedDict(TypedDict):
|
|
r"""Tool call delta for streaming responses"""
|
|
|
|
index: int
|
|
r"""Tool call index in the array"""
|
|
function: NotRequired[ChatStreamToolCallFunctionTypedDict]
|
|
r"""Function call details"""
|
|
id: NotRequired[str]
|
|
r"""Tool call identifier"""
|
|
type: NotRequired[ChatStreamToolCallType]
|
|
r"""Tool call type"""
|
|
|
|
|
|
class ChatStreamToolCall(BaseModel):
|
|
r"""Tool call delta for streaming responses"""
|
|
|
|
index: int
|
|
r"""Tool call index in the array"""
|
|
|
|
function: Optional[ChatStreamToolCallFunction] = None
|
|
r"""Function call details"""
|
|
|
|
id: Optional[str] = None
|
|
r"""Tool call identifier"""
|
|
|
|
type: Optional[ChatStreamToolCallType] = None
|
|
r"""Tool call type"""
|