1 / 21

Personalization @ Scale Challenges and Practical Techniques

Personalization @ Scale Challenges and Practical Techniques. Hagay Lupesko Engineering Manager, Facebook AI. Facebook’s Mission: Bring the World Closer Together. Bringing the world closer together by connecting people to what they care about. Personalization @ FB.

rniles
Download Presentation

Personalization @ Scale Challenges and Practical Techniques

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Personalization @ ScaleChallenges and Practical Techniques Hagay Lupesko Engineering Manager, Facebook AI

  2. Facebook’s Mission:Bring the World Closer Together

  3. Bringing the world closer together by connecting people to what they care about Personalization @ FB

  4. Personalization @ Facebook Marketplace Groups IG Explore Feed

  5. Facebook’sScale

  6. Personalization @ Scale – Practical Techniques System Design Candidate Generation Learning from Sparse Data Agenda Keeping Models Fresh

  7. Personalization @ Scale – System Design (1/2) Recommender System User ID Time of day Device attributes … User User Query User Ranked Items FeatureStore Items Store

  8. Personalization @ Scale – System Design (2/2) Recommender System ItemStore FeatureStore ImpressionLog Ranking Model CustomBusiness Logic Retrieval AKA Candidate Generator User User Query User Ranked Items

  9. Personalization @ Scale – Practical Techniques System Design Candidate Generation Learning from Sparse Data Agenda Keeping Models Fresh

  10. Personalization @ Scale – Retrieval (1/3) Challenge: Identifying O(102) items out of O(106), fast! Practical Approach: Multi-stage ranking with a candidate generator Candidate generator: • Does NOT optimize for accurate rank (this comes later on) • Usually latency bound

  11. Personalization @ Scale – Retrieval (2/3) Embeddings: mapping high dimensionality feature space into low dimensionality vector. “King” -> [0.392, …, 0.173] VideoID311 -> [0.112, …, 0.298] PostID1907 -> [0.819, …, 0.197] Two-Tower Neural Net: embedding for recommender systems. Similarity Embedding Embedding Query Tower Item Tower Query Features Item Features

  12. Personalization @ Scale – Retrieval (3/3) KNN Offline IndexingPopulate all item embeddings into a KNN index for fast lookup. Online Items LookupLookup item candidates using KNN for query embeddings. KNN Service Lookup Query Tower Item Store Item Tower KNN Service Index Recurring Offline Update Query Features

  13. Personalization @ Scale – Practical Techniques System Design Candidate Generation Learning from Sparse Data Agenda Keeping Models Fresh

  14. Personalization @ Scale – Data Sparsity (1/3) Challenge: How to learn from categorical/sparse features?How to combine it with continuous/dense features?

  15. Personalization @ Scale – Sparse Data (2/3) Dense Features Categorical (AKA Sparse) Features … … PostIDs Liked: […] VideoIDs Watched: […] LangID: 16 Time of Day: 5.2 30D Post Clicks: 121 Age: 40 … Normalize Embedding Table Lookup: ID to Dense Vector ? Normalize Normalize ? ? … Dense Vector[0.604, 0.157, 0.184, …] Pool Pool Pairwise Dot Product Feed into Neural Net Dense Vector[0.121, 0.750, 0.579, …] Feed into Neural Net

  16. Personalization @ Scale – Sparse Data (3/3) Prediction Combining together into a single neural network Open sourced by Facebook as DLRM - PyTorch implementation Embedding tables are memory bound Training at production scale requires model parallelism Top MLP Feature Interactions Bottom MLP Embedding Tables Dense Features Sparse Features

  17. Personalization @ Scale – Practical Techniques System Design Candidate Generation Learning from Sparse Data Agenda Keeping Models Fresh

  18. Personalization @ Scale – Model Freshness (1/2) Challenges: Items are added, removed, updated every minute Users are onboarding and changing every minute Data distributions are constantly changing! How can personalization models keep up? How can compute usage stay efficient?

  19. Personalization @ Scale – Model Freshness (2/2) • Train as user interaction data is captured • Deploy updated model every few hours or less • Use when data distributions change rapidly and model is critical • Fine tune the previous baseline due to limited time and data windows. • Train on offline data in repeat • Deploy updated model every few days or weeks • Make it the default practice for your models! • Train from scratch or fine tune a baseline – based on cost/benefit. Online Training Recurring Training

  20. Personalization @ Scale – Practical Techniques Recap

  21. Personalization @ ScaleChallenges and Practical Techniques Hagay Lupesko Engineering Manager, Facebook AI We Are Hiring for Facebook AI Reach Out! Thank You!

More Related