Problem
A bank receives online application forms and must decide whether the applicant is already a customer. The forms have no input validation, so names, passport numbers and phones come with typos, swapped fields and outdated values. With millions of forms and customers the number of pairs is about for 10 million against 10 million, and exact string rules miss real matches. Marketplaces face the same task with products from different sellers.
Example from the article: VTB matched about 700 thousand forms against 1,350,000 customers in one month of data.
Solution in brief
Turn each record into a vector so that the same entity lands close together, then match in two stages: approximate nearest-neighbor search for candidates, and a classifier with a probability threshold for the final decision. Train the encoder on hard negatives taken from the nearest neighbors. For products, Ozon builds one embedding per product from images, titles and attributes by predicting the narrowest product category.
Questions this case answers
- How to link records of the same entity across two large sets when the fields are noisy, there is no shared identifier and all-pairs comparison is infeasible
- How to compress several modalities of an object into one vector when the only supervision is a noisy category hierarchy
- How to find out whether a person who filled in an online form is already a customer when names, passports and phones contain typos?
- How to match tens of millions of records against tens of millions without comparing every pair?
Tools and methods
- TF-IDF on character n-grams and BPE tokens — sparse vectors of each form and customer field
- DSSM encoders with cosine embedding loss — compress vectors to 128 dimensions
- Hard negative mining — 50 nearest neighbors per form as negatives
- NMSLIB, Annoy, FAISS, HNSW — approximate nearest-neighbor search instead of exact KNN
- Gradient boosting classifier — final ranking of candidate pairs
- ArcFace with ResNet34 and two ruBERT-tiny — Ozon's product embedding trained on category prediction
Google or a one-time email code. No password.