from __future__ import annotations

from typing import Any


CONFIDENCE_HIGH = "HIGH"
CONFIDENCE_MEDIUM = "MEDIUM"
CONFIDENCE_LOW = "LOW"


def empty_gate_output() -> dict[str, Any]:
    return {
        "must_do": [],
        "should_do": [],
        "red_flags": [],
        "blocking_issues": [],
        "confidence": CONFIDENCE_MEDIUM,
        "references": [],
        "matched_docs": [],
    }


def add_reference(payload: dict[str, Any], path: str, reason: str) -> None:
    payload["references"].append({"path": path, "reason": reason})
