KatInterview

Predicting B2B SaaS Contract Churn After Quality Incidents

Machine LearningModel answer
HardModel answerMachine Learningmachine learningchurn predictionfeature engineering

Last updated

Architect an end-to-end machine learning system to estimate customer renewal risk following service instability, covering feature selection, leakage, model tradeoffs, and decision thresholds.

You are an ML Engineer at an enterprise video communication platform. Following a recent product incident involving frequent call drops, executive leadership wants to proactively mitigate enterprise customer churn.

Design an end-to-end machine learning strategy to identify accounts at risk of non-renewal:

  1. Problem Framing & Label Formulation: Define the observation unit, prediction window, label definitions (including partial churn/downgrades), and feature generation windows.
  2. Feature Engineering & Minimal Viable Feature Set: Outline candidate features spanning reliability, support engagement, usage, firmographics, and financial metrics. Construct a minimal viable set of ~8 high-signal features and justify your choices.
  3. Data Leakage & Hygiene: Highlight common sources of data leakage specific to enterprise SaaS churn and explain how to prevent them.
  4. Model Architecture Tradeoffs: Compare regularized logistic regression, gradient-boosted decision trees (GBDTs), and deep learning. Address small sample sizes, interpretability requirements, sparse inputs, and monotonic constraints.
  5. Class Imbalance & Survival Analysis: Discuss techniques for addressing class imbalance while preserving probability calibration. Explain when binary classification is sufficient versus when survival analysis (or hazard modeling) is required due to right-censoring.
  6. Evaluation & Decision Framing: Move beyond AUROC. Explain how to evaluate the model using PR-AUC, calibration metrics (Brier score, reliability diagrams), and temporal backtesting. Outline how to map model probabilities to actionable Customer Success interventions under operational capacity constraints.

Hints

Hint 1

Establish standard volume assumptions first (e.g., total enterprise accounts, baseline churn rate, and intervention capacity) to inform model complexity.

Hint 2

Be precise about snapshot dates. All features must be evaluated strictly point-in-time relative to the cutoff date to eliminate data leakage.

Hint 3

Consider how probability calibration directly impacts financial optimization when evaluating cost-benefit thresholds under CSM team capacity constraints.