Churn Prediction with scikit-learn: Scored on Customers You Can't See

<p>Deccan Wave Fibre, a broadband provider in Pune, Nashik and Kolhapur, loses about one customer in five at renewal. Its retention team can only phone a few customers each month. Your job is to decide who they call.</p><p>You get your own copy of the company's data: three months of renewals with the outcome, and April's renewals without it. You build the model yourself, lesson by lesson. Then you give the same job to your AI assistant (ChatGPT, Claude, Gemini or Copilot) and check what it gives back. Bartman runs your script in a sealed sandbox and scores your predictions against what April's customers actually did. Neither you, your AI nor the sandbox ever sees those outcomes.</p><ul><li>Clean a real-world export: repeated rows, a hand-typed label, rupee amounts as text, and why accuracy is the wrong score.</li><li>Screen features with single-column AUCs and catch <strong>leakage</strong>: a column that records the outcome instead of predicting it.</li><li>Build features that exist on prediction day: one-hot encoding, units in text, blanks filled from the training data only.</li><li>Fit a logistic regression in a scikit-learn pipeline, cross-validate it, and submit probabilities, not labels.</li><li>Compare it with gradient boosting on the same folds, then build the month's call list and a lift chart.</li></ul><p>Every learner gets different data, so answers can't be copied. Each check explains what went wrong without giving the answer away, and the classic mistakes (filling blanks from the test file, a leaky feature, a constant guess) are recognised and named.</p>

Tools: Python, pandas, scikit-learn, Logistic Regression, Gradient Boosting, Cross-Validation, ROC AUC, Data Leakage, matplotlib, AI Assistants for Python