Real-Time Fraud Detection: $2M Saved in Chargebacks
A fintech company's rule-based fraud system was catching less than half of fraudulent transactions. We built ML models that score transactions in under 50ms and brought detection rates above 92%.
The Challenge
What was getting in the way
- 01
The existing rule-based system flagged only 40% of actual fraud. The other 60% slipped through and hit as chargebacks
- 02
False positive rate was 18%, meaning legitimate customers were getting blocked and calling support to complain
- 03
Rules were maintained manually by a team of three analysts. Adding a new rule took weeks of testing and rollout
The Solution
How we solved it
We built a two-stage fraud detection pipeline. Stage one is a lightweight gradient-boosted model that scores every transaction in under 10ms. Transactions above the threshold go to stage two, a deeper neural network that evaluates 140+ features including device fingerprint, velocity patterns, and behavioral anomalies. The whole system runs on AWS Lambda + SageMaker endpoints behind an API Gateway. We trained on 18 months of labeled transaction data (12M+ records) and deployed with a shadow mode that ran alongside the old system for two weeks before going live.
Technologies
What We Built
A look inside the project
The Process
Step-by-step delivery
Data Preparation
Clean and label 18 months of transaction data (12M+ records)
Feature Engineering
Build 140+ features from device, velocity, and behavior signals
Model Training
Train two-stage pipeline: fast scorer + deep fraud analyzer
Shadow Deployment
Run alongside existing system for 2-week validation
Production Launch
Go live with real-time scoring and alerting dashboard
The Results
The numbers
Fraud Detection Rate (up from 40%)
Annual Chargeback Savings
Transaction Scoring Latency