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

import typing

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


class ClinicalConcern(UniversalBaseModel):
    """
    Clinical concern for a specific population or condition
    """

    name: typing.Optional[str] = pydantic.Field(default=None)
    """
    Drug name
    """

    severity: typing.Optional[int] = pydantic.Field(default=None)
    """
    Concern severity (1=minor, 5=contraindicated)
    """

    severity_name: typing.Optional[str] = pydantic.Field(default=None)
    """
    Human-readable severity label
    """

    reason: typing.Optional[str] = pydantic.Field(default=None)
    """
    Clinical rationale
    """

    source: typing.Optional[str] = pydantic.Field(default=None)
    """
    Data source
    """

    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
