# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.

from __future__ import annotations

from typing import Dict
from typing_extensions import Literal, Required, TypedDict

from ..._types import SequenceNotStr

__all__ = ["TransformJobCreateParams"]


class TransformJobCreateParams(TypedDict, total=False):
    dataset_id: Required[str]
    """UUID of the seed dataset to transform."""

    detection_method: Required[Literal["gliner", "llm", "heuristics", "gliner+heuristics", "llm+heuristics", "all"]]
    """Entity detection method.

    Use `llm` or compound methods when you need LLM-based detection; supply
    `model_name` in that case.
    """

    name: Required[str]
    """Human-readable name for this transform job."""

    pii_types: Required[SequenceNotStr[str]]
    """List of PII/PHI entity types to detect and mask (e.g.

    ["PERSON", "EMAIL", "PHONE_NUMBER"]).
    """

    evaluation_model: str
    """AI model for automatic PII redaction quality evaluation after the job completes.

    Defaults to `anthropic/claude-sonnet-4-6`.
    """

    mask_config: Dict[str, str]
    """Optional per-entity-type masking strategy, e.g.

    `{"PERSON": "REPLACE", "EMAIL": "REDACT"}`. Defaults to redact all.
    """

    model_name: str
    """LLM model name. Required when `detection_method` includes `llm`."""

    threshold: float
    """Confidence threshold for entity detection (0.0–1.0).

    Lower values detect more entities; higher values reduce false positives.
    """
