ADAgnivesh Das ← All work
BP · Single Customer Identifier · Customer data

From Loyalty Members to Every Customer

Every purchase on a bp forecourt left three separate records behind: a till receipt, a card payment and, sometimes, a loyalty swipe. None of them shared a key, so the business could count baskets, cards or members, but never customers. The Single Customer Identifier linked all three into one view, and said how confident it was in every link.

A note on this write-upAll figures, charts and examples on this page are illustrative. Values, volumes and site details have been altered or replaced with fictitious numbers; no real BP data is shown. Only the headline results are reported outcomes.

The project

One view of every forecourt customer

The goal was simple to say and hard to do: take three transaction systems that were never designed to talk to each other, and join them into one record per customer, across the UK, Germany and Poland. I brought in the raw data, built the common data model, and wrote the matching models that make the links.

The starting point: one purchase, three records

A single visit could show up in the till system (what was bought), the payment system (how it was paid) and the loyalty system (who bought it, but only if they swiped). Each system had its own IDs, its own clocks and its own idea of a transaction.

Three systems, three partial views Illustrative
Illustrative monthly volumes for one market
EPOS (till)What was bought
Records / month
2.4M baskets
Knows
items, value, site
PaymentHow it was paid
Records / month
1.9M card payments
Knows
card token, amount
LoyaltyWho bought it
Records / month
0.7M swipes
Knows
member, points
✕No common key between any of the three systems

Loyalty only ever covered a minority of spend. Everyone who paid by card but never swiped a loyalty card was, in effect, invisible.

The method: narrow, score, link

There was no list of known matches to train against, so this was an unsupervised problem. I narrowed the search first: a till record could only match a payment from the same site, date, country and basket type. Within that small window, I scored each candidate pair on how closely their time, value and quantity agreed, and kept the best one.

Link rate by dataset pair Illustrative
% of in-scope transactions linked
Exact-key matchConfidence-scored match
EPOS ↔ Payment82%
EPOS ↔ Loyalty88%
Payment ↔ Loyalty65%
View data
ItemExact-key matchConfidence-scored matchTotal
EPOS ↔ Payment58%24%82%
EPOS ↔ Loyalty71%17%88%
Payment ↔ Loyalty44%21%65%

Exact keys did most of the work, but the scored matches added roughly a fifth more coverage on every pair. That's the slice a simple join would have thrown away.

How sure is each match?

At a busy site, two or three baskets of a similar value can land in the same minute. So every link carries a confidence score: the similarity of the pair, scaled down by how many other candidates were nearly as close. Only links above a threshold are kept.

Coverage at each confidence threshold Illustrative
% of in-scope transactions retained
40%
50%
60%
70%
80%
90%
Chosen: 0.7
0.50.60.70.80.9
View data
Coverage
0.584.1%
0.5583.8%
0.683.5%
0.6583.0%
0.782.2%
0.7580.4%
0.876.5%
0.8570.3%
0.961.0%
0.9544.2%

Most real matches score very high, so coverage barely moves until the threshold passes 0.7, then falls away fast. That knee is where we set it: strict enough to trust, loose enough to keep almost everything worth keeping.

When two baskets look the same

The dampening step matters most in exactly the cases a join gets wrong. Here, two till records compete for the same card payment:

One payment, two candidate baskets Illustrative
Illustrative transactions
PairSimilarityCompeting withConfidenceDecision
E1 ↔ P10.85none0.85✓ Linked
E2 ↔ P20.94E30.61! Linked, flagged
E3 ↔ P20.52E20.19✕ Rejected

E2 still wins, but its confidence drops from 0.94 to 0.61 because E3 was a plausible rival. Reporting can then treat contested links differently from clean ones, instead of pretending every match is equally certain.

Who we could suddenly see

Once the links were in place, linked transactions rolled up into one record per customer, including the people loyalty data had never captured.

Customers visible, by segment Illustrative
Thousands of customers; amber = newly visible
310k
420k
560k
1,840k
95k
Engaged loyaltySemi-engagedUnengaged loyaltyCard-onlyFleet
View data
ItemValue
Engaged loyalty310k
Semi-engaged420k
Unengaged loyalty560k
Card-only1,840k
Fleet95k

The largest group by far was customers who paid by card but never swiped loyalty. They had been shopping with bp all along; the business just couldn't see them.

What I handed over

The data foundationRaw EPOS, Payment and Loyalty data brought in from each source system, cleaned into one common model per market, with the in-scope population defined for every pair so “unmatchable” never counted as “missed”.
The matching modelsBlocking keys, similarity scoring, dampening and a 0.7 threshold, tuned per market, producing a customer ID that downstream reporting and models could build on.

Results

38%increase in fuel-to-store conversion
3 → 1datasets joined into one customer view
3markets on one model: UK, Germany, Poland
CLVbp's lifetime-value model was built on SCI

Why this mattered

A customer key, built once and used everywhere

Matching three datasets was never the point. The point was being able to ask customer questions at all: who shops with us, who crosses from the pump to the store, who is drifting away. The cross-shopping insight behind the 38% conversion lift came straight from this view, and the Customer Lifetime Value model that followed was built on top of it.

3source systems linked
4blocking keys narrow every search
0.7confidence threshold for a link
1customer ID for reporting and models
Agnivesh Das · Portfolio · LinkedIn · Technical deep dive Illustrative example; figures and details altered.