An entity resolution pipeline turns inconsistent customer records into links to canonical entities while controlling the risk of false matches. This guide presents a repeatable workflow for normalization, candidate generation, field-level scoring, blocking, confidence thresholds, human review, and audit logging, plus a monitoring routine for detecting match-quality drift.
Overview
Customer information rarely arrives in one consistent format. A CRM may contain Maria de la Cruz, a billing export may use Maria D. Cruz, and a support system may omit the middle name entirely. Addresses can change, phone numbers may include different country codes, and email fields can contain capitalization or whitespace differences. Entity resolution, also called record linkage or entity matching, is the process of deciding which records refer to the same real-world customer.
The goal is not to make every pair of records look similar. It is to link a source record to a canonical customer only when the available evidence is strong enough. A safe pipeline therefore separates three decisions:
- Match: the evidence supports linking the record to one canonical entity.
- Review: the evidence is ambiguous and should be checked by a person or a controlled downstream process.
- Do not match: the evidence is insufficient or conflicts with known identity data.
Keeping these outcomes separate is more important than choosing a sophisticated similarity algorithm. A fuzzy score can identify useful candidates, but it should not be treated as proof of identity. For background on preparing labeled examples, see the guide to building a gold-standard dataset for entity resolution.
What to track
1. Define the canonical entity and source keys
Start with a stable canonical customer identifier. Record which source systems contribute data, which fields are authoritative, and whether a source identifier is unique only within that system. Store the original source values alongside normalized values so that every match can be explained later.
A useful match table typically includes the source system, source record ID, canonical entity ID, decision status, overall score, field-level scores, model or ruleset version, processing timestamp, and reviewer information when applicable. Do not overwrite the source record merely to make it fit the canonical format.
2. Build a normalization pipeline
Normalization should remove representational differences without erasing information that helps distinguish people. Common steps include trimming whitespace, normalizing Unicode, applying consistent case handling, standardizing phone-number formatting, parsing email addresses, and splitting addresses into components when the data supports it.
Keep field-specific rules rather than applying one global transformation. Names may need punctuation and honorific handling; addresses may need unit parsing; phone numbers may require a country assumption; emails should generally be treated as structured identifiers rather than ordinary prose. Preserve both raw and normalized values, and record which transformation version produced each normalized value.
Be cautious with transliteration, phonetic matching, and aggressive removal of accents. These techniques can improve recall in some datasets but can also collapse distinct names. Language-aware candidate generation is often safer than applying one phonetic rule to every market. The guide to multilingual entity matching covers this issue in more detail.
3. Generate candidates with blocking
Comparing every incoming record with every canonical customer is expensive and produces many irrelevant similarities. Blocking narrows the comparison set using relatively inexpensive keys. Examples include a normalized email domain plus local-part prefix, phone suffix, postal code, country and surname initial, or a shared token from an address.
Use more than one blocking strategy when no single field is reliable. The union of candidates from several blocks can improve recall, while the later scoring stage decides whether any candidate is credible. Track how many candidates each block produces. A block that returns almost the entire customer table is not providing useful protection against unnecessary comparisons.
4. Score fields separately
Calculate similarity for each relevant field before combining the results. Depending on the data, useful measures may include exact comparison, normalized edit distance such as Levenshtein distance, Jaro-Winkler for some name variations, token or trigram similarity for addresses, and numeric or structural checks for phone numbers. A single fuzzy score hides too much information for operational review.
Use field weights based on observed reliability, not intuition alone. An exact, verified email may carry more weight than a similar name, while an address can be useful supporting evidence but may be shared by multiple people. Also include conflict rules. For example, a very similar name should not automatically overcome a clear conflict in a trusted customer identifier.
A simple initial scoring model can be expressed as:
overall_score = name_weight × name_score + email_weight × email_score + phone_weight × phone_score + address_weight × address_score
This formula is only a starting point. Add missing-field handling, field reliability indicators, source-specific weights, and explicit penalties for contradictory evidence. Store the individual components so reviewers can understand why a record was linked.
5. Set thresholds for match, review, and rejection
Use labeled positive and negative examples to tune thresholds. A practical template is:
- Automatic match: score at or above the high-confidence threshold, with no blocking conflict and at least one sufficiently reliable supporting field.
- Human review: score between the review lower bound and the automatic-match threshold, or any case involving conflicting high-value fields.
- No match: score below the review lower bound or failing a required identity rule.
Do not select thresholds solely because they produce a convenient review volume. Sample decisions from each band and measure false matches, missed matches, and unresolved records. The cost of a false merge may be much higher than the cost of sending an uncertain record to review, especially when customer histories, permissions, financial activity, or support cases are involved.
6. Add human review and audit logging
Reviewers need the evidence, not just a score. Show the raw and normalized values, field-level similarities, candidate alternatives, source provenance, and the rule or model version used. Capture the reviewer decision and, where practical, a reason code such as matching phone, conflicting address, shared household, or insufficient evidence.
Audit logs should be append-only or otherwise protected from silent alteration. Include input identifiers, candidate IDs, scores, thresholds, decision outcome, timestamps, and pipeline version. This record supports debugging, rollback, quality analysis, and explanations to internal stakeholders without requiring the pipeline to be rerun.
Cadence and checkpoints
Entity matching quality changes when source systems, customer behavior, or data-entry practices change. Establish a monthly or quarterly checkpoint, depending on record volume and business risk. At each checkpoint, review:
- Match, review, and no-match rates by source system.
- False-match and missed-match findings from sampled decisions.
- Records with small score margins between the top two candidates.
- New or rising normalization failures, such as malformed phones or shifted address formats.
- Candidate counts by blocking rule and the share of records with no candidates.
- Manual-review volume, turnaround time, and disagreement rates between reviewers.
- Changes in field completeness and the frequency of conflicting values.
Run these checks separately by source, geography, language, and customer segment when those dimensions affect formatting or data quality. Aggregate metrics can hide a failing source whose records are being matched using rules designed for another system.
Before onboarding a new source, create a small representative sample and label likely matches, non-matches, and ambiguous cases. Test normalization and blocking first, then tune scoring. Keep the previous ruleset available so that results can be compared rather than judged in isolation.
How to interpret changes
A higher automatic-match rate is not automatically an improvement. It may mean normalization became better, but it may also indicate thresholds were lowered or a broad blocking rule is generating misleading candidates. Read match rates alongside sampled precision, unresolved volume, score distributions, and review outcomes.
A sudden increase in no-match records often points to a source-format change, a missing field, a country-code issue, or an overly restrictive blocking rule. A sudden increase in review decisions can indicate legitimate ambiguity, but it can also result from a parser regression or a new source with different conventions.
Watch the margin between the best and second-best candidate. A high top score with an even higher-quality alternative close behind is less safe than a slightly lower score with a clear margin. Treat candidate ambiguity as a first-class signal and route it to review when the consequences of a wrong link are significant.
When duplicates are eventually merged, separate the matching decision from survivorship. Entity resolution determines which records refer to the same entity; survivorship determines which values become canonical. Preserve merge history and provide a rollback path. The workflow in safe customer record deduplication provides a useful operational model.
Privacy should be part of the design. Limit access to personal fields, avoid copying sensitive values into unrestricted logs, encrypt data according to your environment's requirements, and retain only the fields and history needed for the stated operational purpose. Use masked values in review interfaces where full values are not necessary.
When to revisit
Revisit the pipeline on a regular monthly or quarterly cadence and immediately after a meaningful data change. Triggers include a new CRM or billing source, a migration between vendors, a change in address or phone formatting, expansion into a new language or country, a noticeable shift in review volume, or evidence of incorrect merges.
Use this practical checklist for each review:
- Sample recent automatic matches, reviews, and rejected records.
- Compare precision and recall against the last approved baseline or labeled test set.
- Inspect field completeness, normalization failures, and top-two candidate margins.
- Check blocking coverage and identify sources with unusually large candidate sets.
- Review threshold changes using the same labeled examples where possible.
- Confirm that audit records, reviewer reasons, and ruleset versions are being stored.
- Document whether to keep, revise, or roll back the current pipeline version.
Maintain a versioned threshold-tuning template with the date, source scope, sample size, field weights, blocking rules, automatic-match threshold, review boundary, observed false-match rate, observed missed-match rate, and reviewer notes. This turns entity matching from a one-time cleanup task into a measurable data-quality process. For smaller exports, a repeatable comparison workflow such as matching two CSV files can help validate changes before they reach production. If PostgreSQL is part of the stack, trigram indexes can support candidate retrieval, but retrieval speed should be evaluated alongside match quality; see the guide to PostgreSQL fuzzy search with pg_trgm.