1 Recommendations, recommender systems, and components
Recommender systems shape much of what people see online by selecting and ranking content from large catalogs for specific users or situations. The chapter introduces recommendations as intentional selections rather than simple lists, and shows that modern systems often blend personalized and non-personalized experiences, such as “Recommended for you” and “Popular” carousels. It also emphasizes that recommender systems are not just single models, but production infrastructures that combine multiple signals and techniques to serve relevant content at scale.
The chapter explains that recommender systems are typically built from three main kinds of data: content metadata, behavioral data, and contextual data. Content-based methods use item features to find similar items, collaborative filtering learns from patterns in user interactions, and context-aware methods adapt results based on factors like device, time, or location. Through simple comic-book examples, the text shows how each approach works, how feedback from clicks, purchases, ratings, and other interactions improves future recommendations, and why these systems face challenges such as popularity bias, filter bubbles, cold start, and the need to balance exploration with exploitation.
Finally, the chapter presents recommender systems as multi-stage pipelines rather than monolithic models. A common four-stage architecture retrieves candidate items, filters out ineligible ones, scores the rest with one or more models, and orders the final results using relevance and business rules such as diversity and fairness. This layered design makes large-scale recommendation practical across domains like streaming, e-commerce, search, and even retrieval-augmented generation, while allowing each stage to be improved independently. By the end, the reader gains a foundation for understanding both the mechanics and the broader design principles behind recommender systems.
A typical e-commerce landing page showing two types of recommendations: personalized ("Recommended for you") and non-personalized ("Popular Products"). The same page uses different recommendation strategies simultaneously.
"Popular on Netflix" on my profile, showing action and thriller content aligned with my viewing history.
"Popular on Netflix" on my mother-in-law's profile, showing different content based on her viewing history.
A product detail page showing item-to-item recommendations. The suggestions are based on the current product being viewed, not the user's profile.
Recommender systems can be implemented using different types of data. Most systems use one or more of three distinct categories: content metadata, behavioral data, and contextual data.
The recommender system feedback loop. Users receive recommendations, interact with content (clicks, purchases, views), interactions are logged, this data trains models, and improved models generate better recommendations.
The distribution of items recommended using the uniform recommender after calling it ten thousand times with k=2.
Content-based recommendation architecture. Each item has a representation; user history is tracked; and recommendations are generated by finding items similar to those the user has consumed.
Distribution of content-based recommendations. Unlike the uniform distribution in Figure 1.8, some comics are recommended more frequently because they share tags with many other comics, while others are never recommended.
Comic similarity heatmap, which shows how similar each comic book is, based on the content similarity method (Listing 1.4).
Collaborative filtering architecture. User activity data (clicks, purchases, ratings) is used to train a model that predicts user preferences.
The first five generated users. The first user consumed Asterix, Lucky Luke, and The Smurfs.
depicts a heatmap that shows how often two comics have been consumed by the same user.
The four-stage recommender system architecture. Candidates flow from left to right, being progressively filtered and refined at each stage. Early stages prioritize speed and recall; later stages prioritize precision and ranking quality.
The four-stage pipeline for Netflix's "Popular on Netflix" carousel. Starting with all popular content, the system filters, scores, and orders to create personalized recommendations.
Summary
- A recommender system predicts and ranks content items from a catalog based on what it knows about the user, the current context, and historical user-item interactions. Two fundamental patterns exist: user-to-item (U2I) recommendations, which personalize based on user profiles, and item-to-item (I2I) recommendations, which find related items.
- Three main data types enable different recommendation approaches: content metadata powers content-based recommendations, behavioral data powers collaborative filtering, and contextual data enables context-aware recommendations. User interaction data—both implicit (clicks, purchases) and explicit (ratings, reviews)—flows through a feedback loop to improve recommendations over time.
- Content-based recommenders use item features (tags, categories, descriptions) to find similar items. By measuring similarity between items, these systems can recommend items without requiring data from other users, though they're limited to the explicitly defined features.
- Collaborative filtering learns from all users simultaneously to discover patterns like "users who enjoyed X also enjoyed Y." It can surface unexpected connections but faces challenges such as the cold-start problem (new users/items lack history) and popularity bias (popular items are recommended more often).
- Context-aware systems adapt recommendations based on external factors like time of day, device type, and location. Rather than relying solely on context, these systems typically incorporate contextual features into content-based or collaborative filtering approaches.
- Recommender systems operate in a continuous feedback loop, in which user interactions with recommendations serve as training data for future recommendations. This enables adaptation and personalization but also creates challenges such as popularity bias (popular items receive more exposure), filter bubbles (users are trapped in narrow recommendation spaces), and cold-start problems (new users/items lack interaction history). The feedback loop requires balancing exploration (trying new items) with exploitation (showing proven items).
- A recommender system consists of at least four stages:
- Candidate generation – find all the content that could be recommended
- Filtering – remove items that shouldn't be recommended, like already consumed items
- Scoring – each candidate item is scored according to one or more models
- Ordering – sort the items according to the scores and other business logic
AI Recommender Systems ebook for free