Expand description
Evaluation metrics (DESIGN §14.2). Pure functions comparing extracted assertions against golden-corpus annotations.
Structs§
- Eval
Metrics - Quality metrics computed from an extraction run against golden annotations.
- Extracted
Triple - A triple extracted from the brain, for comparison against golden annotations.
Functions§
- compute_
metrics - Compute metrics by comparing extracted triples against expected triples.
- compute_
metrics_ with_ fabrication - Like
compute_metricsbut with a measured fabrication rate (§17.3, 10.7). The fabricated rate is computed separately bymeasure_fabrication_ratebecause it requires the source text, whichcompute_metricsdoes not take. - measure_
fabrication_ rate - Measure fabricated entity rate (§17.3, F19, 10.7): of the entity surfaces extracted, what fraction do NOT appear verbatim in the source text? This detects hallucinated entities that slipped past validation.