An imbalanced binary classification system over market transaction data. This file documents the full workflow: the data challenge, the pipeline, model benchmarking, error analysis, interpretation, and a live inference interface.
Detect fraudulent transactions while minimizing missed fraud and unnecessary false alarms.
Fraud detection is an imbalanced classification problem: fraudulent transactions represent a very small fraction of all activity. The objective is therefore not to maximize accuracy — a model that labels everything legitimate would already score above 99%.
The real objective is to control the balance between two error types, and to justify where that balance was set.
Held-out test split, threshold fixed at 0.50 for comparability. Ranked on PR-AUC — the metric that stays informative when the positive class is rare.
The decision threshold is a design choice, not a default. Move it and watch the confusion matrix and every downstream metric respond.
Mean absolute SHAP value per feature across the test set — what drives the model globally, before looking at any single transaction.
Adjust the transaction characteristics. The scored probability and its local attribution update live, then are compared against the operating threshold set in section 06.