Use Contextual Bandits to Explore New Content in Explore
Last updated: November 29, 2026
Quick Overview
Explain how you would use a contextual bandit to decide when Instagram Explore should show uncertain new content instead of a known safe choice, and how you would pick and evaluate the exploration strategy.
Meta
November 29, 20260
0
0 solved
Explain how you would use a contextual bandit to decide when Instagram Explore should show uncertain new content instead of a known safe choice, and how you would pick and evaluate the exploration strategy.
Exploration is a recurring theme in Meta recommendation interviews because ranking models only learn about what they show. The interviewer checks understanding of epsilon-greedy, UCB, and Thompson sampling, plus how they fit a deep ranking stack.
What the Interviewer Expects
- Frame the problem: context, arms, reward, and why it is a bandit rather than full RL
- Compare epsilon-greedy, UCB, and Thompson sampling
- Explain how to get uncertainty estimates from a neural ranker
- Log propensities so the data is reusable for off-policy evaluation
- Define how to measure regret or the cost of exploration
Key Topics to Cover
How to Approach This
- Understand the bias-variance trade-off. High training accuracy but low test accuracy signals overfitting.
- Choose evaluation metrics carefully based on the problem. Accuracy alone is often insufficient.
- Feature engineering is often more impactful than model selection.
- Know when to use tree-based models (tabular data) vs neural networks (unstructured data).
- Handle class imbalance with SMOTE, class weights, or appropriate loss functions.
Possible Follow-up Questions
- How do you get posterior samples from a model with millions of parameters?
- How would you set the exploration rate and decay it?
- What changes if the reward is delayed, such as a follow days later?
Sharpen Your Skills on Codemia
Practice similar problems with our interactive workspace, get AI feedback, and track your progress.
Explore ML Interview PrepSample Answer
Clarify
Context: user features and session state. Arms: candidate items for one slot (or a small set of slots). Reward: a short-horizon signal such as watch past 50% or a like. It is a contextual bandit becau...
Approach
Start from the existing ranker's predicted reward , add an uncertainty estimate, and use it to choose which items get exploration. Keep the exploration slice small and log the probabili...