Files
openrouter-python-sdk-retry…/src/openrouter/components/formats.py
T
OpenRouter SDK Bot 5ab44f08f0 feat: regenerate SDK with updated OpenAPI spec
Speakeasy regeneration with latest schema changes including
type renames and new server tool models.
2026-03-27 15:18:14 -04:00

39 lines
1.1 KiB
Python

"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT."""
from __future__ import annotations
from .formatjsonobjectconfig import (
FormatJSONObjectConfig,
FormatJSONObjectConfigTypedDict,
)
from .formatjsonschemaconfig import (
FormatJSONSchemaConfig,
FormatJSONSchemaConfigTypedDict,
)
from .formattextconfig import FormatTextConfig, FormatTextConfigTypedDict
from openrouter.utils import get_discriminator
from pydantic import Discriminator, Tag
from typing import Union
from typing_extensions import Annotated, TypeAliasType
FormatsTypedDict = TypeAliasType(
"FormatsTypedDict",
Union[
FormatTextConfigTypedDict,
FormatJSONObjectConfigTypedDict,
FormatJSONSchemaConfigTypedDict,
],
)
r"""Text response format configuration"""
Formats = Annotated[
Union[
Annotated[FormatTextConfig, Tag("text")],
Annotated[FormatJSONObjectConfig, Tag("json_object")],
Annotated[FormatJSONSchemaConfig, Tag("json_schema")],
],
Discriminator(lambda m: get_discriminator(m, "type", "type")),
]
r"""Text response format configuration"""