"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.""" from __future__ import annotations from .responseformatjsonobject import ( ResponseFormatJSONObject, ResponseFormatJSONObjectTypedDict, ) from .responsesformattext import ResponsesFormatText, ResponsesFormatTextTypedDict from .responsesformattextjsonschemaconfig import ( ResponsesFormatTextJSONSchemaConfig, ResponsesFormatTextJSONSchemaConfigTypedDict, ) from openrouter.utils import get_discriminator from pydantic import Discriminator, Tag from typing import Union from typing_extensions import Annotated, TypeAliasType ResponseFormatTextConfigTypedDict = TypeAliasType( "ResponseFormatTextConfigTypedDict", Union[ ResponsesFormatTextTypedDict, ResponseFormatJSONObjectTypedDict, ResponsesFormatTextJSONSchemaConfigTypedDict, ], ) r"""Text response format configuration""" ResponseFormatTextConfig = Annotated[ Union[ Annotated[ResponsesFormatText, Tag("text")], Annotated[ResponseFormatJSONObject, Tag("json_object")], Annotated[ResponsesFormatTextJSONSchemaConfig, Tag("json_schema")], ], Discriminator(lambda m: get_discriminator(m, "type", "type")), ] r"""Text response format configuration"""