Skip to main content
PostgreSQL

Customer Churn Pipeline

Self-retraining MLOps pipeline with drift detection that keeps churn predictions fresh automatically.

Customer Churn Pipeline — ProjectsHub
91.5%
Churn Recall
50K+
Users Monitored
Nightly
Drift Checks
4.9★
Client Rating
Overview

What is this project?

An enterprise-grade MLOps pipeline that ingests raw CRM data, applies a feature engineering layer (normalisation, ordinal encoding, interaction terms), trains an XGBoost classifier, and pushes churn probability scores to a PostgreSQL dashboard consumed by the CRM team. Great Expectations validates data quality at each stage; Prefect orchestrates the schedule; MLflow tracks every experiment with full model registry support.

The standout feature is drift detection: Kolmogorov–Smirnov tests run nightly on each feature. When any feature drifts beyond a configurable threshold, Prefect automatically triggers a retraining job with fresh data. In production, the model stayed accurate 3 months beyond the initial training cutoff thanks to this feedback loop — a critical win for a SaaS client with 50K active users.

Process

Build Timeline

Phase 01 Jul 2025
Data Audit & Feature Engineering
Audited 18 months of CRM data, handled 12% missing values, and engineered 35 features including RFM scores and tenure-based interaction terms.
Phase 02 Aug 2025
Model Training & MLflow Tracking
Trained XGBoost with Optuna hyperparameter search over 100 trials, tracked every run in MLflow, and registered the best model with full artifact logging.
Phase 03 Sep 2025
Orchestration & Data Validation
Built Prefect DAG for nightly runs, integrated Great Expectations data quality checks, and set up KS-test drift detection with configurable thresholds.
Phase 04 Oct 2025
Dashboard & Production Rollout
Pushed churn scores to PostgreSQL, built Grafana monitoring boards, and rolled out to production serving 50K users with zero downtime.
Get This Project

What's Included

₹4,999
one-time payment · lifetime access
  • Full pipeline source code (Prefect DAGs + training scripts)
  • Pre-trained XGBoost model + MLflow experiment logs
  • Docker Compose stack (Prefect, MLflow, Grafana, PostgreSQL)
  • Great Expectations data suite configuration
  • 75-minute video walkthrough
  • 45-day email support