D2: graded relevance label for a (query, candidate memory) pair — the training/eval substrate for learned per-bank fusion weights.
Each row is one source's grade for one pair. Candidates are keyed on memory_ref,
the stable corpus id (metadata["eval_id"]), NOT the ephemeral memory_units.id UUID,
so a human-graded gold set survives corpus reloads instead of being re-labelled each run.
Cohen's weighted kappa is computed by joining a REFERENCE source (:human or :agent)
against source: :llm on {query_ref, memory_ref} where split == :calibration. The
:test split is the held-out reference set the judge never sees; :train is the bulk
LLM-labelled set D2 ascends against.
Currently, the shipped reference set for both D2 lanes is :agent, not :human —
no person has graded a D2 pair. Pipeline.calibration_report/2 always reports which
reference source it scored against, and refuses to pick silently when both are present.
Summary
Types
Functions
@spec changeset(t(), map()) :: Ecto.Changeset.t()