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

from ...core.pydantic_utilities import UniversalBaseModel
import typing
import pydantic
from ...core.pydantic_utilities import IS_PYDANTIC_V2


class PostedCustomVoiceParameters(UniversalBaseModel):
    """
    The specified attributes of a Custom Voice.

    If no parameters are specified then all attributes will be set to their defaults, meaning no modfications will be made to the base voice.
    """

    gender: typing.Optional[int] = pydantic.Field(default=None)
    """
    The vocalization of gender, ranging between masculine and feminine.
    
    The default value is `0`, with a minimum of `-100` (more masculine) and a maximum of `100` (more feminine). A value of `0` leaves this parameter unchanged from the base voice.
    """

    huskiness: typing.Optional[int] = pydantic.Field(default=None)
    """
    The texture of the voice, ranging between bright and husky.
    
    The default value is `0`, with a minimum of `-100` (brighter) and a maximum of `100` (huskier). A value of `0` leaves this parameter unchanged from the base voice.
    """

    nasality: typing.Optional[int] = pydantic.Field(default=None)
    """
    The openness of the voice, ranging between resonant and nasal.
    
    The default value is `0`, with a minimum of `-100` (more resonant) and a maximum of `100` (more nasal). A value of `0` leaves this parameter unchanged from the base voice.
    """

    pitch: typing.Optional[int] = pydantic.Field(default=None)
    """
    The frequency of the voice, ranging between low and high.
    
    The default value is `0`, with a minimum of `-100` (lower) and a maximum of `100` (higher). A value of `0` leaves this parameter unchanged from the base voice.
    """

    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
