# This file was auto-generated by Fern from our API Definition.

import typing

import pydantic
from ..core.pydantic_utilities import IS_PYDANTIC_V2
from ..core.unchecked_base_model import UncheckedBaseModel
from .google_model import GoogleModel
from .google_version import GoogleVersion


class Google(UncheckedBaseModel):
    type: typing.Literal["google"] = "google"
    version: typing.Optional[GoogleVersion] = pydantic.Field(default=None)
    """
    The Google API used for the request: ai-studio-v1beta for the AI Studio API, or gemini-enterprise-agent-v1 for the Gemini Enterprise Agent (GEA) API. v1beta is accepted as an alias for ai-studio-v1beta. Defaults based on the Deepgram Voice Agent endpoint you connect to.
    """

    model: GoogleModel = pydantic.Field()
    """
    Google model to use
    """

    temperature: typing.Optional[float] = pydantic.Field(default=None)
    """
    Google temperature (0-2)
    """

    if IS_PYDANTIC_V2:
        model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True)  # type: ignore # Pydantic v2
    else:

        class Config:
            frozen = True
            smart_union = True
            extra = pydantic.Extra.allow
