ML & Data Science
AnalysisFrom Notebook to Production · Analysis98% Accurate and Useless: Six Imbalance Fixes, Measured on a 2% Positive Class
Six models on one 2% positive dataset: the baseline caught 1 of 59 positives, class weights caught 45 at 6% precision, and a balanced random forest predicted zero positives despite the best AUC. Threshold tuning was the only fix that raised F1.
Ibrahim Denis Fofanah·Nov 12, 2026·11 min
ExplainerFrom Notebook to Production · ExplainerScaling Gave SVM 8 Points and Trees Nothing. I Ran Four Models Raw and Scaled.
SVM went from 88.8% to 97.2% accuracy with one preprocessing line. Random forest moved zero. Logistic regression stopped warning and converged in 20 iterations instead of 1,000.
Ibrahim Denis Fofanah·Nov 7, 2026·10 min
AnalysisModel Evaluation · AnalysisSame Model, Ten Seeds, a 3.5-Point Swing: Why One Split Is Not a Result
Same data, same code, ten split seeds. Logistic regression ranged from 95.8% to 99.3%, and the "winning" model flipped on two seeds. A single split is not a result.
Ibrahim Denis Fofanah·Nov 2, 2026·8 min
- Deep DiveJudging Research · ML & Data Science
Frontier Models Can Spot a Broken Experiment. They Still Pick It One Time in Five
Tampered ML gave 22 frontier models 1,858 pairs of near-identical experiment proposals, one sound and one with a single planted flaw. The best model was right in both orders 77.9% of the time. Order swaps, added detail, and conventional practice flipped the rest.
Ibrahim Denis Fofanah·Oct 30, 2026·11 min
- Deep DiveFrom Notebook to Production · Deep Dive
79% Accurate, Give or Take 8 Points: What a Bootstrap Interval Says About Your Test Score
One logistic model scored on test sets of 100, 400, and 1,600 rows. The 95% bootstrap interval shrank from 17 points wide to 4 as the test set grew, and 20 fresh test sets of 400 rows landed anywhere from 73.8% to 82.3%. Report the interval with the score.
Ibrahim Denis Fofanah·Oct 29, 2026·8 min
ExplainerFrom Notebook to Production · ExplainerDrift Is Three Different Failures, and One Metric Cannot See Them All
One logistic model, four test scenarios: a mean shift that broke accuracy but not AUC, added noise that hurt both, and a flipped rule that PSI could not see at all. The table, the code, and the monitoring checklist.
Ibrahim Denis Fofanah·Oct 24, 2026·9 min
TutorialFrom Notebook to Production · ML & Data ScienceFive Leaks That Inflate Your AUC: I Measured Each One
Five controlled experiments, one per leak: honest AUC vs leaky AUC on the same data-generating process. Target leakage bought +0.16, pre-split feature selection +0.26, repeat groups +0.15.
Ibrahim Denis Fofanah·Oct 19, 2026·11 min
ExplainerFrom Notebook to Production · ExplainerYour 0.85 Meant 0.98: A 20,000-Row Calibration Test That Caught a Top Model Misstating Its Own Odds
On 20,000 rows, a random forest with AUC 0.972 had a calibration error of 0.082. Sigmoid calibration cut it to 0.004. Gaussian naive Bayes fell from 0.050 to 0.012 with isotonic calibration, and AUC moved by at most 0.001.
Ibrahim Denis Fofanah·Oct 14, 2026·10 min
Policy BriefRegulation in Force · Policy BriefThe EU AI Act Is Already Enforcing. The Deadline Everyone Watched Was the One That Moved.
The enforcement machinery is running: chatbot disclosure, synthetic-content marking, GPAI documentation demands, and a US state banning algorithmic grocery pricing.
Ibrahim Denis Fofanah·Oct 8, 2026·12 min
Deep DiveML & Data Science · Deep DiveGradient Boosting Still Rules Tabular Data. The Foundation Models Are Gaining Ground.
Four years after a 45-dataset benchmark crowned gradient-boosted trees on tabular data, tabular foundation models (TabPFN, LimiX-2, NVIDIA's Kumo Tabular) are topping leaderboards. What the 2022 verdict got right, where it no longer holds, and how to choose your next tabular model.
Ibrahim Denis Fofanah·Oct 5, 2026·13 min
Benchmark WatchBenchmark Watch · ML & Data Sciencepandas vs Polars vs DuckDB on 3.5 Million Taxi Rides. DuckDB Won Every Query, and the Timings Were the Least Interesting Part.
I ran pandas, Polars, and DuckDB through the same 3.5M-row NYC taxi CSV on a 7GB box. DuckDB won every query and used half the memory of pandas, but the most useful finding was a CSV parsing gotcha, not a timing.
Ibrahim Denis Fofanah·Sep 29, 2026·6 min
TutorialData Engineering · ReliabilityYour Retry Worked. That Is How You Got Two Rows.
Retries fix transient failures, but they can also duplicate payments, records, and side effects. Here is how idempotency keys, unique constraints, and atomic writes make retries safe.
Ibrahim Denis Fofanah·Sep 25, 2026·8 min