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

import typing

import pydantic
from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
from .instruction_name import InstructionName
from .template_type import TemplateType


class UpdateInitialInstructionRequest(UniversalBaseModel):
    """
    Request object for updating an existing initial instruction.
    """

    type: typing.Literal["initial"] = "initial"
    name: typing.Optional[InstructionName] = None
    description: typing.Optional[str] = pydantic.Field(default=None)
    """
    A detailed description of what this instruction does.
    """

    template: typing.Optional[str] = pydantic.Field(default=None)
    """
    The instruction template content using the specified template engine.
    """

    template_type: typing.Optional[TemplateType] = None
    metadata: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = pydantic.Field(default=None)
    """
    Arbitrary metadata associated with the instruction.
    """

    enabled: typing.Optional[bool] = pydantic.Field(default=None)
    """
    Whether the instruction is enabled.
    """

    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
