Documentation / Under the hood

How a pair is scored

Blocking, comparators, weights, vetoes, thresholds.

  1. Prepare: each record's attributes are read once (paths, normalisation: lower case, no accents, no punctuation).
  2. Block: keys are computed; records sharing a key become candidate pairs. Blocks larger than the maximum are skipped and logged.
  3. Deterministic rules: a pair with the same identifier matches without a score.
  4. Compare: for each attribute with values on both sides a similarity from 0 to 1. A missing value on either side is neutral (the attribute is left out).
  5. Score = Σ(weight × sim − penalty × (1 − sim)) ÷ Σ(weight) over the compared attributes. Fewer compared attributes than Minimum attributes compared: not trusted.
  6. Vetoes cap the score if an attribute disagrees.
  7. Linkage: Patient.link / Linkage resources merge automatically; seealso adds the configured boost.
  8. Outcome: ≥ automatic threshold → auto merge; between → possible; below → dropped.
ExampleWorked example

Attributes: family (w 3, p 1.5) sim 1.0; given (w 2, p 1) sim 0.9; birth (w 3, p 2) sim 1.0; gender (w 1, p 1) sim 1.
Score = (3·1 + 2·0.9 + 3·1 + 1·1 − penalties 0.1) ÷ 9 = 0.97 ⇒ above 0.92, automatic merge.
If the birth date were different (sim 0): (3 + 1.8 + 0 + 1 − 2 − 0.2) ÷ 9 = 0.40 and a veto caps it at 0.6.