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

import typing

import pydantic
import typing_extensions
from ..core.pydantic_utilities import IS_PYDANTIC_V2
from ..core.serialization import FieldMetadata
from ..core.unchecked_base_model import UncheckedBaseModel


class ClassifyOptimizerOptions(UncheckedBaseModel):
    agent_type: typing_extensions.Annotated[typing.Literal["CLASSIFY_OPTIMIZER"], FieldMetadata(alias="agentType")] = (
        pydantic.Field(alias="agentType", default="CLASSIFY_OPTIMIZER")
    )
    """
    Type of optimizer agent
    """

    accuracy_threshold: typing_extensions.Annotated[
        typing.Optional[float], FieldMetadata(alias="accuracyThreshold")
    ] = pydantic.Field(alias="accuracyThreshold", default=None)
    """
    Target accuracy threshold (0-1)
    """

    max_batch_runs: typing_extensions.Annotated[typing.Optional[float], FieldMetadata(alias="maxBatchRuns")] = (
        pydantic.Field(alias="maxBatchRuns", default=None)
    )
    """
    Maximum number of batch iterations
    """

    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
