Back to learn

How AI finds duplicate expenses

Fingerprints, fuzzy matching, and cross-account reconciliation. How duplicate detection actually works.

Duplicate expenses come from three places: a merchant charging twice by mistake, an employee submitting the same receipt to two different reports, and the same transaction landing on both a bank and a card feed after being reimbursed. Each has a different fingerprint.

Exact fingerprint matching

The first pass hashes each transaction on merchant, amount, date, and currency. Two transactions with the same hash in the same account are almost certainly duplicates. This catches the merchant double-charge case cleanly.

Fuzzy matching

The second pass looks for transactions that are close but not identical. Same merchant, same day, amounts within one cent (a rounding artifact). Or same amount, adjacent days, same last four digits of the card. A similarity score above a threshold triggers a review flag.

Cross-account matching

The third pass matches across accounts. A receipt submitted twice, once from a card feed and once from a manual expense report, is a duplicate even though they came in through different channels. This requires linking receipts to transactions and then checking for multiple links to the same receipt.

The role of AI

Classical hashing catches the easy cases. Fuzzy string matching (edit distance, token overlap) catches most of the medium cases. AI adds value on the hardest case: two transactions that look different (different merchant strings, slightly different amounts because of tax) but refer to the same purchase. A language model can spot the semantic equivalence a fuzzy matcher misses.

False positives are the enemy

A duplicate detector that flags too many innocent transactions gets ignored. A good detector is calibrated: high precision on the exact-fingerprint pass, medium precision on the fuzzy pass with a Review flag rather than an automatic delete. The user makes the final call.

Prevention over detection

The best duplicate detection is a workflow that prevents duplicates in the first place: a card transaction feed as the single source of truth, receipts attached to transactions rather than submitted separately, and enforced unique reference numbers on manual entries. Detection is a safety net, not a primary control.