# 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
from .parse_config_block_options_text_agentic import ParseConfigBlockOptionsTextAgentic


class ParseConfigBlockOptionsText(UncheckedBaseModel):
    """
    Options for text blocks.
    """

    signature_detection_enabled: typing_extensions.Annotated[
        typing.Optional[bool], FieldMetadata(alias="signatureDetectionEnabled")
    ] = pydantic.Field(alias="signatureDetectionEnabled", default=None)
    """
    Whether an additional vision model will be utilized for advanced signature detection. Recommended for most use cases, but should be disabled if signature detection is not necessary and latency is a concern.
    """

    agentic: typing.Optional[ParseConfigBlockOptionsTextAgentic] = pydantic.Field(default=None)
    """
    Options for agentic text processing using VLM-based review and correction.
    """

    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
