This is a big question and I underestimated how far they'd want me to go.
Start by clarifying the product goal and constraints (e.g., organic feed, local restaurant discovery, user engagement). Then walk through the end-to-end system: data sources, feature engineering, model architecture, real-time ranking, and evaluation. Emphasize how you balance relevance, freshness, and diversity while addressing cold-start and scalability.
Pro tip: Tie every design choice back to a measurable objective (e.g., CTR, dwell time, or restaurant visits) and explicitly discuss trade-offs like latency vs. model complexity. Show awareness of Meta's scale by mentioning distributed training and serving, and how you'd handle billions of daily impressions.
Define the problem: what does 'relevant' mean? Identify key metrics (e.g., clicks, saves, direction requests) and constraints (latency, scale, privacy). Confirm the feed context and user intent.
List data: user profiles, historical interactions, restaurant attributes (cuisine, location, ratings), contextual signals (time, location, device). Engineer features: user-restaurant affinity, distance, popularity, freshness, and embeddings.
Propose a two-stage architecture: candidate generation (e.g., matrix factorization, two-tower neural network) to retrieve hundreds of candidates, followed by a ranking model (e.g., deep neural network with wide & deep or DLRM) to score and order them.
Describe how to serve predictions with low latency: precompute embeddings, use approximate nearest neighbor search for retrieval, and a lightweight ranking model. Incorporate real-time features (e.g., user's current location) via feature store.
Offline: use historical data with metrics like NDCG, recall@k, and AUC; conduct counterfactual or off-policy evaluation. Online: A/B test with guardrail metrics (CTR, dwell time, diversity) and long-term holdouts to measure retention.
AI-generated suggestions, not part of the candidate's original notes. May be inaccurate — verify before relying on them.