Data
03 / BI and data analyst· Analytics

A B2B SaaS revenue engine built so it can be graded: five revenue leaks were planted in a simulated business and sealed away, and the warehouse, the anomaly monitor and the churn model had to find them blind.

Year
Oct 2026
Status
Public
Stack
Python, DuckDB, dbt, XGBoost
leaks found
5 of 5, blind
Power BI Revenue page: ARR $20.6M, MRR growth 108.3%, NRR 85.1%, MRR over time, monthly MRR movements, retention and MRR lost by segment
01

Revenue analytics is rarely checked against the truth, because nobody knows the truth. This build plants it: five revenue leaks were written into a simulated business and sealed away before any analysis, so the warehouse, the anomaly monitor and the churn model are graded against an answer key, not judged by how they look.

02

A day-by-day simulation of a B2B SaaS company from October 2024 to September 2026: 1,107 accounts across SMB, Mid-Market and Enterprise, with 13 kinds of dirty data mixed in. dbt on DuckDB builds a Kimball star schema with SCD Type 2 and enforced contracts. A six-detector leak monitor and a churn model (logistic regression, chosen over XGBoost) sit on top, and the Power BI report (Revenue, Cohorts, Accounts, Account) is generated entirely from code.

03

105 dbt nodes build with tests and contracts, and 13 of 13 injected data-problem types are caught (39,161 dirty rows). 14 of 14 deliberate breakages are caught. 69 of 69 Power BI figures match DuckDB, 3,391 of 3,391 text lines are measured to fit, and two runs from scratch give 90 of 90 byte-identical files. GitHub Actions reruns the pipeline and the mutation test on every push.

04

The monitor found 5 of 5 planted leaks on the main run and 19 of 20 across four simulated worlds. False alarms fell from 10 to 3 once the detectors were rebuilt as Poisson, binomial and two-proportion tests, with both versions rerun on three unseen worlds. Tested out of time, the churn model reaches ROC AUC 0.73: the riskiest 10% churn at 2.9x the base rate, and 44% of churns are flagged in the 60 days before, a median 41 days ahead.

05

SEALED ANSWER KEYgrade the analytics, don't just build them
STATISTICAL DETECTORSfalse alarms 10 to 3, checked on unseen worlds
REPORT AS CODETMDL + PBIR, rebuilt byte-identical