# generated by datamodel-codegen:
#   filename:  detected_entity.schema.json
#   timestamp: 2026-03-03T01:18:26+00:00

from __future__ import annotations

from typing import Annotated

from pydantic import BaseModel, ConfigDict, Field


class DetectedEntity(BaseModel):
    model_config = ConfigDict(
        extra='forbid',
    )
    type: Annotated[str, Field(description='Canonical internal entity type.')]
    providerType: Annotated[
        str | None, Field(description='Original detector/provider type label.')
    ] = None
    source: Annotated[str | None, Field(description='Detector source identifier.')] = (
        None
    )
    score: float | None = None
    beginOffset: Annotated[int | None, Field(ge=0)] = None
    endOffset: Annotated[int | None, Field(ge=0)] = None
    text: str | None = None
