LiveIndependent · Fintech ML2026

Sanad سند

Real-time card fraud detection on Kafka · live dashboard of a real run

95% vs 40%fraud caught vs rules, same alert volume
01The problem

Why it exists

Every card transaction streams through Kafka, gets point-in-time features from a stateful engine, and is approved, sent for review or declined in milliseconds, with reasons an analyst can read. A drift monitor watches the traffic; when it shifts, a challenger model is retrained and has to beat the champion before it is promoted.

02The system

What I built

Card transactionsKafka, keyed by card
Featurespoint-in-time, shared
LightGBM scoreSHAP reasons
Alert budgetanalyst queue
Drift + retrainchampion / challenger
  1. A Kafka pipeline keyed by card, with an idempotent producer and at-least-once processing
  2. 25 point-in-time features (velocity, device sharing, impossible travel, spend vs habit) from one engine shared by training and serving, with a parity test
  3. LightGBM with SHAP reasons in plain language, and thresholds set by the analyst team's alert budget
  4. PSI drift monitoring and champion/challenger retraining, plus a dashboard to explore budgets and the analyst queue
03The result

What it achieved

On 15 unseen live days: 92.5% of fraud and 95% of fraud value caught at a 0.56% alert rate; 95% vs 40% recall against a legacy rules engine at equal alert volume. End-to-end p99 of 43 ms at 3,000 tx/s, 18.9k tx/s throughput. Drift-triggered retraining cut false alerts by 43% at the same recall.

Stack

PythonApache KafkaLightGBMSHAPDrift monitoringMLOpsGitHub Actions

Timeline

2026

My role

ML + data engineering