mirror of
https://github.com/wassname/openrouter-python-sdk-retry-errors.git
synced 2026-08-01 12:40:23 +08:00
50 lines
1.3 KiB
Python
50 lines
1.3 KiB
Python
"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT."""
|
|
|
|
from __future__ import annotations
|
|
from enum import Enum
|
|
from openrouter.types import BaseModel
|
|
from typing import Optional
|
|
from typing_extensions import NotRequired, TypedDict
|
|
|
|
|
|
class ChatCompletionContentPartImageType(str, Enum):
|
|
IMAGE_URL = "image_url"
|
|
|
|
|
|
class Detail(str, Enum):
|
|
r"""Image detail level for vision models"""
|
|
|
|
AUTO = "auto"
|
|
LOW = "low"
|
|
HIGH = "high"
|
|
|
|
|
|
class ChatCompletionContentPartImageImageURLTypedDict(TypedDict):
|
|
url: str
|
|
r"""URL of the image (data: URLs supported)"""
|
|
detail: NotRequired[Detail]
|
|
r"""Image detail level for vision models"""
|
|
|
|
|
|
class ChatCompletionContentPartImageImageURL(BaseModel):
|
|
url: str
|
|
r"""URL of the image (data: URLs supported)"""
|
|
|
|
detail: Optional[Detail] = None
|
|
r"""Image detail level for vision models"""
|
|
|
|
|
|
class ChatCompletionContentPartImageTypedDict(TypedDict):
|
|
r"""Image content part for vision models"""
|
|
|
|
type: ChatCompletionContentPartImageType
|
|
image_url: ChatCompletionContentPartImageImageURLTypedDict
|
|
|
|
|
|
class ChatCompletionContentPartImage(BaseModel):
|
|
r"""Image content part for vision models"""
|
|
|
|
type: ChatCompletionContentPartImageType
|
|
|
|
image_url: ChatCompletionContentPartImageImageURL
|