KatInterview

Targeting a Delivery-Fee Promo with an Uplift Model

Machine LearningModel answer
HardModel answerMachine Learninguplift-modelingcausal-inferenceexperimentation

Last updated

Design an end-to-end uplift system that picks which 20% of users get a free-delivery offer, covering experiments, modeling, evaluation, budgeted selection, fairness, interference and sequential testing.

A delivery marketplace can give a free-delivery offer to only 20% of its eligible customers, and the spend is capped. The goal is to get as many extra orders per dollar as possible, meaning orders that would not have happened without the offer.

For a customer with features x, treat the individual effect as:

uplift(x) = P(order | offer, x) − P(order | no offer, x)

Describe how you would build and validate a system that decides who receives the offer. Address each of the following:

  1. Data collection. How would you run an experiment to generate training data? Cover the randomization unit, how many users to treat, any permanent holdout, and how you track whether people actually saw and used the offer.
  2. Modeling. Which learners would you consider (T-, S-, X-, doubly robust learners, or direct uplift models)? Which features would you use, and how do you avoid leakage?
  3. Offline evaluation. Which metrics (Qini, AUUC, uplift-AUC and others) and which cross-validation scheme would you use?
  4. Decision rule. How do you pick the top-K users under a fixed budget when each user has a cost, or a cost curve across offer levels?
  5. Fairness guardrails. How do you keep targeting reasonable across geographic zones and customer tenure?
  6. Interference and positivity. How do you handle spillovers such as courier capacity limits and surge pricing, and what do you do when some users almost never or always get treated?
  7. Deployment. How would you roll the model out and run a sequential test to confirm the lift without being misled by response saturation?

Give a structured answer with concrete choices, numbers where useful, trade-offs, and common pitfalls.

Hints

Hint 1

Separate the quantity you want (incremental orders, net of who would have ordered anyway) from the quantity that is easy to predict (order probability), and note that cost depends on who redeems, not only on who is offered.

Hint 2

Randomized data with known assignment probabilities lets you use inverse-propensity or doubly robust pseudo-outcomes, and evaluation should be done on randomized data with the same user never appearing in both train and test.

Hint 3

Selection under a budget is a knapsack-style problem: rank by uplift per dollar, use Lagrange multipliers for multiple offer levels or group constraints, and account for noise at the top of the ranking.

Hint 4

Individual-level randomization can misestimate the effect of a deployed policy when treated users change supply for everyone in a zone, so think about randomizing treatment density across zones and time, and about alpha-spending for repeated looks.