Analyse a randomized promotion experiment end to end: check that the randomization held, estimate the coupon's average effect on net margin with CUPED and regression adjustment, estimate who benefits with four meta-learners and a hand-written two-headed neural network, judge them on held-out randomized data, value targeting policies with doubly robust estimates before running them, and hand over a traceable decision memo, an MLflow-registered model and a FastAPI scoring service with a strict input contract. Synthetic data with known true effects lets every method be checked against the truth.
AI & Data Scientist. Advanced.
For data scientists and analysts who already build predictive models and want to measure what a promotion really caused, estimate who benefits and choose who to target with evidence that survives review.
This project assumes you can already build an ordinary predictive model. It teaches the experimentation and causal methods on top. Check the list below honestly: each item is used without explanation later, and each has a short way to fill the gap.
This project answers four questions about Fernhill Market's coupon experiment: did the coupon raise net margin, for whom, how sure are we, and which customers should get it next quarter when the budget covers one in five. The system that answers them has three parts:
Before computing anything, be precise about the question. "Did the coupon work?" can mean several different things, and only one of them is answered by this experiment.
An analysis is only as trustworthy as the table it starts from. Most experiment errors found in practice are not statistical: a join that duplicated customers, a window that included the day before the launch, refunds counted as sales. This lesson builds the analysis table and the checks that stop a broken delivery before anything is estimated.
An effect estimate inherits every flaw of the randomization behind it. A treatment arm that quietly lost a few thousand customers, or a model feature recorded after the coupon was sent, will produce a confident, precise and wrong number. Nothing in the effect estimate itself warns you.
Finance asked one question: did SPRING8 make money? This lesson answers it for the whole population, three ways, and explains why the three answers differ. Along the way it covers the standard error behind every interval in the project, variance reduction with CUPED and regression adjustment, more than one metric at a time, and a guardrail that must not get worse.
The marketing team wants to run another coupon test next quarter, and they want a dashboard that shows the result every morning. Two questions follow. How many customers does the test need to detect an effect worth acting on? And is it safe to look at the result every day and stop as soon as it is significant?
The average effect is 50 pence per customer, but nobody is an average customer. A price-sensitive shopper who was about to place a large order might earn the business several pounds more with the coupon; a loyal customer who would have bought the same basket anyway costs £8.00 and earns nothing extra. If the coupon went only to customers of the first kind, it could be worth far more than 50 pence per customer sent.
Deep learning libraries make a network a few lines of code, and they also hide every step that can go wrong. This lesson's network is written in NumPy: the forward pass, the gradient of the loss for every weight, the optimizer and the stopping rule are all visible and testable. The aim is not to beat the tree learners (it does not, here) but to understand exactly what a training loop does, how to check it is correct, and why a flexible model is not automatically a better effe
A churn model can be scored by comparing its predictions with who actually churned. An effect model cannot: no customer's true effect is observed, so there is no column of right answers to compare with. This lesson shows what can be measured instead, why it must be measured on customers who played no part in building or choosing the model, and how noisy even an honest evaluation is.
Next quarter's budget covers sending SPRING8 to one customer in five. Marketing has its own candidate rules: send it to the top spenders, or to customers who seem to be lapsing. The model offers another. Which one should the business run?
Two questions follow every targeting model into a business review. Marketing asks: "Which kinds of customers is it picking? Can we describe them as segments?" Legal and leadership ask: "Is it treating any group of customers very differently, and should it?" This lesson answers both from the policy stage's results, and shows why the first question's most common answer, k-means clustering, describes customers rather than effects.
Six weeks after the analysis, someone asks: "The model the campaign tool is calling, which data was it trained on, which learner is it, and what threshold does it use?" If the answer depends on someone's memory or a notebook on a laptop, the analysis cannot be audited or repeated. This lesson covers the three pieces that make the answer a lookup: experiment tracking, a model registry, and a scoring service that accepts only the input the model was built for.
Everything so far produces numbers in metrics.json. The people who decide next quarter's campaign will read none of them. They will read one page, and the quality of that page decides whether the analysis changes anything. This lesson covers what the memo says, how it is generated so that it cannot drift from the results, and how to write what the analysis does not know.
This guide runs the whole project in order. Milestones 1 to 6 run the analysis on your computer, one stage at a time, so you can read each stage's results as the matching lesson explains them. Milestones 7 and 8 run the same pipeline in containers, with an MLflow tracking server and the scoring service, and practise a release and a rollback. Cleanup removes everything.
Most failures in this project do not crash anything. The pipeline finishes, the memo is written, the service answers, and a number is wrong: an effect inflated by a broken randomization, a model that looks better because of a leaked feature, a scorer serving a version nobody meant to release. The skill this lesson practises is noticing that a successful run can still be wrong, and finding out why from evidence rather than intuition.
Interviews for data science roles rarely ask you to recite a formula. They ask you to walk through an analysis, defend a choice when a constraint changes, and say what you would check when a number looks wrong. This project gives you a concrete analysis to talk about, with real trade-offs: an exposure log you chose not to use, an estimate you adjusted, a learner you kept although the test fold seemed to prefer another, a feature you refused, and a recommendation that depends
Everything this project creates lives in two places: files under the source folder, and Docker objects labelled with the Compose project name fernhill. Nothing is created in any cloud account, and nothing outside those two places is changed. This page removes both, in an order that never leaves something unremovable, and shows how to confirm nothing is left.
This milestone gets your computer ready and proves the code works on it before any data exists. You start with the source folder and finish with a Python environment in .venv/, a clean lint run and a passing test suite.
This milestone creates the data and decides whether it can be trusted. You start with an empty data/ folder and finish with seven warehouse exports, the oracle of true effects, an analysis table with one row per assigned customer, and a health-check result that says the experiment is safe to analyse.
This milestone answers finance's question, whether the coupon made money on average, and plans the next test. You finish with three estimates of the average effect on net margin, the same for revenue and orders, the unsubscribe guardrail, and the power and peeking simulations.
This milestone estimates each customer's effect five ways and chooses one learner without looking at the test fold. You finish with every learner's estimates for validation and test customers, the chosen learner saved with its encoder, and the targeting threshold.
This milestone opens the test fold once. You finish with the chosen learner's Qini curve, deciles and calibration on customers it has never seen, a comparison with the true effects kept apart as a teaching note, and six targeting policies valued with intervals.
This milestone turns the results into the document the business reads and records the chosen model where a service can find it. You finish with runs/current/memo.md and its seven figures, the teaching note oracle_check.md, and version 1 of fernhill-uplift with the alias champion in the local MLflow store.
This milestone runs the pipeline the way a team would share it. You start with Docker running and ports 5000 and 8080 free, and finish with the image fernhill/uplift:1.0.0, an MLflow tracking server on http://127.0.0.1:5000 holding a full pipeline run, and version 1 of the model registered there.
This milestone puts the model behind an API and practises changing which model it serves. You start with the tracking server and a registered model, and finish with the scoring service on http://127.0.0.1:8080, a passing verification, and the experience of moving the champion alias forward to a new version and back again.
This milestone removes everything the project created. You start with the lab running, or partly running after an interruption, and finish with no fernhill containers, network or volume, ports 5000 and 8080 free, and, if you choose, the image and the local files removed.
Learning Access: INR 199 plus 18% GST. Source Pack: INR 399 plus 18% GST. 90 days of online access. No auto-renewal.
No cloud account or spending is needed: the analysis runs in a Python environment on your own computer and the lab runs as three containers there, using under 3 GB of memory while it runs and about 1.4 GB of disk for its image. GitHub Actions is optional; it is free on public repositories and uses your account's included minutes on private ones. The data is synthetic. This is a learning project, not a hosted environment or a production-readiness guarantee.
Vectametric Project Source Licence (2026-09-27): lawfully obtained source may be copied, modified and deployed for personal learning and interview preparation, including personal portfolio demonstrations with attribution. These permissions continue after online access expires. Do not resell or redistribute the Source Pack or its original source files, unchanged or modified. Commercial or client production use requires separate written permission. Third-party components, such as NumPy, pandas, SciPy, scikit-learn, DuckDB, MLflow, FastAPI and pytest, retain their own licences. See LICENSE.txt and the Project Source Licence section of the site Terms for the full rules.
You can read the project material without deploying it. Running a cloud build requires the accounts, permissions and tools listed in that project's prerequisites. Deployment runs in your environment, not in a hosted Vectametric lab.
Yes. Learning Access includes the online source-file browser and explanations. The Source Pack adds the downloadable reference repository where available. The project's licence governs use of the source.
No. Cloud and CI usage are separate. Read the project's cost notice, set a budget and stop deadline, and follow its destruction and leftover-resource checks.
The project curriculum lists the available scenarios and interview topics. These focus on understanding the architecture and explaining decisions; they are not a promise of particular interview questions or a job.
The project page and checkout show the online access period for your selected plan. Access does not auto-renew. Downloaded source remains subject to its licence; future releases are not automatically included.
Review the Terms and No-Refund Policy before confirming access. All sales are final; Vectametric does not offer refunds.
Vectametric home · Roadmaps · Vecta IT Exams · Vecta Government Exams · Vecta Banking & Finance Exams · Vecta Entrance Exams · About us · Contact · Privacy Policy · Terms and Conditions · No-Refund Policy