denselinkage.core.results.LinkageResult

class denselinkage.core.results.LinkageResult(decisions: tuple[tuple[CandidatePair, MatchDecision], ...], errors: tuple[tuple[CandidatePair, MatchError], ...] = ())[source]

Bases: object

All candidate pairs with their match decisions.

to_frame() pd.DataFrame[source]

One row per decided candidate pair (matches AND non-matches, required for honest precision). Errored pairs are NOT rows here — they live in errors and are counted as LinkageMetrics.n_errors.

Fixed column schema, independent of input id-column names (echoing them would collide on dedupe):

  • left_id, right_id, similarity — always populated.

  • match (bool) — always populated (errors are not rows).

  • confidence (float | None), reason (str | None) — nullable; None when the matcher does not produce them (e.g. ThresholdMatcher).