"""Auto-generated from LOOM_CONTRACT.md by contract_compiler.py vv1.1.0"""

from pydantic import BaseModel, Field
from datetime import datetime
from typing import List, Dict, Optional, Any

class ContradictionReceipt(BaseModel):
    """CRIF contradiction detection."""

    # Standard receipt fields
    receipt_id: str
    receipt_type: str = "crif.contradiction.v1"
    loomdip: str = "pending"
    signature: str = "unsigned"
    valid_time: datetime = Field(default_factory=datetime.utcnow)
    tier: str = "SIGNED"

    # Contradiction-specific fields
    events: List[str]  # Event IDs that contradict
    time_delta: float  # Seconds between events
    classification: str  # "C" (contradiction), "R", "I", or "F"
    routed_to: str  # "guardian", "circuit_breaker", "data_team", or "orchestrator"
    semantic_meaning: str  # "dedupe", "sync_delay", "split_brain", or "security"
