Back to courses
Digital Skills beginner

How Recommendation Engines Work

Duration0 hours
Modules7
Get started — free →

Course outline

Module 1 Module 1: Introduction to Recommendation Systems

Introduction to Recommendation Systems

Introduction

Core content I

Core content II

Core content III

Summary

Further learning

Knowledge check

Q1. What is the primary goal of a recommendation system?
  • A. To store large amounts of user data for later analysis
  • B. To suggest items that a user is likely to be interested in ✓
  • C. To automatically rank web pages for search engines
  • D. To detect fraudulent transactions in real time

Why: Recommendation systems predict and suggest items, such as products, movies, or articles, that match a user's likely preferences. Storing data, ranking pages, and fraud detection are different tasks.

Q2. Which approach recommends items based on similarity between items a user has already liked?
  • A. Collaborative filtering
  • B. Content-based filtering ✓
  • C. Random sampling
  • D. Popularity-based ranking

Why: Content-based filtering compares the attributes of items, such as genre or keywords, to find items similar to those a user previously engaged with. Collaborative filtering instead relies on patterns across many users.

Q3. What does collaborative filtering rely on?
  • A. The textual descriptions of items only
  • B. Patterns of behavior and preferences across many users ✓
  • C. Manually written rules by domain experts
  • D. The time of day the recommendation is shown

Why: Collaborative filtering uses the ratings, purchases, or interactions of many users to find users with similar tastes or items that are frequently co-consumed, without needing item content details.

Q4. What is the 'cold start' problem in recommendation systems?
  • A. Servers overheating when processing large datasets
  • B. Difficulty making good recommendations for new users or new items with little interaction data ✓
  • C. Recommendations being shown too late in a user session
  • D. Users refusing to provide any ratings at all

Why: When a new user or item has little or no history, the system lacks the data needed to predict preferences accurately. This is the cold start problem, often addressed with content features or asking users for initial preferences.

Q5. Which of the following is an example of an implicit feedback signal?
  • A. A user writing a written review of a product
  • B. A user giving a 5-star rating to a movie
  • C. A user clicking on a product page or watching a video for a long time ✓
  • D. A user filling out a survey about their interests

Why: Implicit feedback is inferred from user behavior, such as clicks, views, and watch time, rather than from explicit actions like ratings, reviews, or surveys. Implicit signals are abundant but noisier.

Module 2 Module 2: Collaborative Filtering Basics

Collaborative Filtering Basics

Introduction

Core content I

Core content II

Core content III

Summary

Further learning

Knowledge check

Q1. What is the core idea behind collaborative filtering?
  • A. Recommending items based only on the attributes of the item itself
  • B. Recommending items based on patterns of preferences shared among many users ✓
  • C. Recommending items at random to maximize exploration
  • D. Recommending items that are most popular across all time periods

Why: Collaborative filtering uses the collective behavior of users, such as ratings or purchases, to find patterns of similar preferences and recommend items that similar users liked.

Q2. In user-based collaborative filtering, how is a recommendation for a user typically generated?
  • A. By finding items that have the most keywords in common with the user's profile
  • B. By identifying users with similar rating histories and suggesting items they liked that the target user has not yet seen ✓
  • C. By selecting the newest items added to the catalog
  • D. By asking the user to manually select categories

Why: User-based collaborative filtering finds neighbors, users whose past ratings resemble the target user's, and recommends items those neighbors rated highly that the target user hasn't consumed yet.

Q3. What is the 'cold start' problem in collaborative filtering?
  • A. The system runs slowly when the server temperature is high
  • B. The system struggles to make good recommendations for new users or new items that have little or no interaction data ✓
  • C. Users refuse to rate items when they first sign up
  • D. Recommendations become outdated during winter months

Why: Because collaborative filtering relies on historical interactions, new users and new items lack enough data to find meaningful similarities, making accurate recommendations difficult.

Q4. What is a user-item matrix?
  • A. A list of all users sorted alphabetically by name
  • B. A table where rows represent users, columns represent items, and cells contain interactions such as ratings ✓
  • C. A diagram showing the network connections between items only
  • D. A chart of server performance metrics

Why: The user-item matrix organizes interaction data so each row is a user, each column is an item, and each entry records that user's rating or behavior toward that item, which is the foundation for collaborative filtering computations.

Q5. Why are most cells in a typical user-item matrix empty?
  • A. Because users are only allowed to rate a small number of items by design
  • B. Because each user interacts with only a small fraction of the total items, which makes the matrix sparse ✓
  • C. Because empty cells indicate that the item has been deleted
  • D. Because the matrix stores only the first ratings made by each user

Why: Any single user typically engages with only a tiny portion of a large catalog, so most user-item pairs have no recorded interaction, resulting in a sparse matrix that algorithms must handle carefully.

Module 3 Module 3: Content-Based Filtering

Content-Based Filtering

Introduction

Core content I

Core content II

Core content III

Summary

Further learning

Knowledge check

Q1. What is the core idea behind content-based filtering in recommendation systems?
  • A. Recommending items that similar users have liked, regardless of item features
  • B. Recommending items whose features are similar to items a user has previously liked ✓
  • C. Recommending the most popular items across all users
  • D. Randomly selecting items from a catalog to encourage exploration

Why: Content-based filtering builds a profile from the attributes of items a user has engaged with and recommends other items with similar attributes.

Q2. Which of the following is an example of item features used in content-based filtering for a movie recommender?
  • A. The ratings given by other users to the movie
  • B. The number of times the movie was watched globally
  • C. The genre, director, and actors of the movie ✓
  • D. The age and location of the user watching the movie

Why: Content-based filtering relies on intrinsic item attributes such as genre, director, and cast rather than on user-to-user or popularity signals.

Q3. What is a common technique used to represent text item descriptions numerically in content-based filtering?
  • A. Random integer encoding
  • B. TF-IDF vectorization ✓
  • C. Sorting items alphabetically
  • D. Counting the number of users who viewed each item

Why: TF-IDF converts text into weighted numerical vectors, allowing similarity between item descriptions to be computed.

Q4. How is similarity between two items typically measured in a content-based system?
  • A. By comparing their release dates only
  • B. By computing a distance or similarity metric such as cosine similarity between their feature vectors ✓
  • C. By counting how many users rated both items
  • D. By choosing the item with the longest title

Why: Items are represented as feature vectors, and cosine similarity or a similar metric quantifies how alike they are.

Q5. What is a major limitation of content-based filtering?
  • A. It cannot make any recommendations for users with a history
  • B. It tends to over-specialize, recommending items too similar to what the user already knows ✓
  • C. It requires data from millions of other users to function
  • D. It cannot process any item attributes that are numerical

Why: Because it relies only on known item features, content-based filtering can create a filter bubble and struggle to surface diverse or serendipitous recommendations.

Module 4 Module 4: Matrix Factorization Techniques

Matrix Factorization Techniques

Introduction

Core content I

Core content II

Core content III

Summary

Further learning

Knowledge check

Q1. In matrix factorization for recommendation systems, what does the user-item rating matrix typically look like?
  • A. A fully dense matrix with every user rating every item
  • B. A sparse matrix where most entries are missing because users rate only a small fraction of items ✓
  • C. A square symmetric matrix of user-to-user similarities
  • D. A diagonal matrix with ratings only on the main diagonal

Why: Users typically rate only a tiny fraction of available items, so the rating matrix is sparse with many missing entries. Matrix factorization is designed to handle exactly this situation.

Q2. What is the main goal of matrix factorization in a recommender system?
  • A. To sort items alphabetically for faster lookup
  • B. To decompose the rating matrix into lower-dimensional user and item factor matrices that capture latent features ✓
  • C. To compress the database so it uses less storage
  • D. To count how many times each item was viewed

Why: Matrix factorization approximates the rating matrix as the product of two smaller matrices, one for users and one for items, whose shared latent dimensions represent hidden preferences and characteristics.

Q3. In the factorization R ≈ U × Vᵀ, what does the parameter k (number of latent factors) control?
  • A. The number of users in the system
  • B. The number of recommendations shown to each user
  • C. The dimensionality of the latent feature space used to represent users and items ✓
  • D. The learning rate of gradient descent

Why: The value k sets how many latent features each user and item vector has. Larger k captures more nuance but risks overfitting, while smaller k gives a coarser representation.

Q4. Why is regularization commonly added to matrix factorization models?
  • A. To make the ratings sum to one
  • B. To prevent overfitting by penalizing large latent factor values ✓
  • C. To fill in missing ratings with zeros
  • D. To speed up the computation of the rating matrix

Why: With sparse data and many parameters, the model can fit the observed ratings too closely and generalize poorly. Regularization penalizes large factor magnitudes to keep the model simpler and more robust.

Q5. Which method is commonly used to learn the user and item factor matrices in matrix factorization?
  • A. Stochastic gradient descent or alternating least squares minimizing squared error on observed ratings ✓
  • B. Sorting ratings in descending order
  • C. Counting the frequency of each rating value
  • D. Randomly assigning factors without any optimization

Why: Models are typically trained by minimizing the squared error between predicted and observed ratings, using stochastic gradient descent or alternating least squares, often with regularization terms added.

Module 5 Module 5: Handling Cold Start Problems

Handling Cold Start Problems

Introduction

Core content I

Core content II

Core content III

Summary

Further learning

Knowledge check

Q1. What is the cold start problem in recommendation engines?
  • A. The system takes too long to train on large datasets
  • B. The system cannot make reliable recommendations for new users or new items because it lacks interaction data about them ✓
  • C. Servers overheat when many users request recommendations at once
  • D. Users become bored with recommendations after the first session

Why: Collaborative filtering and many other recommendation methods rely on historical interactions. When a new user or item has no interaction history, the system has little or no basis for predicting preferences, which is the cold start problem.

Q2. Which approach helps address the cold start problem for new items by using item attributes?
  • A. Matrix factorization on user ratings
  • B. Content-based filtering ✓
  • C. Random sampling of popular items
  • D. Collaborative filtering using nearest neighbors

Why: Content-based filtering uses item features such as genre, description, or tags to make recommendations. Because it does not require prior ratings for the new item, it can recommend items immediately after they are added to the catalog.

Q3. What is a common strategy for handling new users with no history?
  • A. Ask them to complete onboarding questions about their preferences ✓
  • B. Refuse to show any recommendations until they make ten purchases
  • C. Assign them randomly to an existing user cluster without any input
  • D. Show them the least popular items to learn what they dislike

Why: Onboarding questionnaires or preference selection screens give the system explicit information about a new user's interests, providing an initial signal that can drive recommendations before implicit behavior data accumulates.

Q4. Why are popularity-based recommendations often used as a fallback during cold start?
  • A. Popular items are always the most profitable for the business
  • B. They require no data at all about any user
  • C. Popular items are generally liked by many people, so they offer a reasonably safe starting guess when personal data is missing ✓
  • D. Popularity scores are computed from each user's private history

Why: When nothing is known about a user, recommending items that many people enjoy gives a statistically reasonable chance of relevance. It is a simple, robust default that works until more personalized data becomes available.

Q5. Which of the following is an example of gathering implicit feedback to overcome cold start?
  • A. Asking a user to rate ten movies on a five-star scale
  • B. Tracking how long a new user hovers over or clicks on certain product pages ✓
  • C. Sending a survey asking which genres the user prefers
  • D. Requiring users to create a detailed profile before browsing

Why: Implicit feedback is inferred from behavior such as clicks, dwell time, and views rather than explicitly provided by the user. Observing these actions lets the system learn preferences without asking the user directly.

Module 6 Module 6: Evaluating Recommendation Quality

Evaluating Recommendation Quality

Introduction

Core content I

Core content II

Core content III

Summary

Further learning

Knowledge check

Q1. Which metric measures the proportion of recommended items that the user actually found relevant?
  • A. Recall
  • B. Precision ✓
  • C. Coverage
  • D. Novelty

Why: Precision is the fraction of recommended items that are relevant to the user. Recall instead measures what fraction of all relevant items were recommended, so precision specifically focuses on the accuracy of the recommendations shown.

Q2. What does Recall@K measure in a recommendation system?
  • A. The average rating given to the top K items
  • B. The share of all relevant items that appear in the top K recommendations ✓
  • C. The number of distinct users who received recommendations
  • D. How many of the top K items are new to the user

Why: Recall@K divides the number of relevant items found in the top K recommendations by the total number of relevant items available for that user. It tells you how well the system captures what the user would like.

Q3. Why might a recommendation system with high accuracy still be considered poor by users?
  • A. Accuracy cannot be computed for recommendations
  • B. It may only recommend very popular items the user would have found anyway ✓
  • C. Accuracy always decreases as the number of users grows
  • D. High accuracy requires the system to use explicit ratings only

Why: A system can score well on accuracy by repeatedly suggesting popular, obvious items. This ignores novelty and serendipity, which are important for user satisfaction and discovering new interests.

Q4. What is catalog coverage in the context of evaluating recommenders?
  • A. The percentage of users who clicked on at least one recommendation
  • B. The fraction of all available items that the system recommends to at least one user ✓
  • C. The total number of items stored in the database
  • D. The proportion of recommendations that include images

Why: Catalog coverage measures how much of the item inventory the system ever surfaces. Low coverage means the system concentrates on a small subset of items, which can limit discovery and create popularity bias.

Q5. Why is an offline train/test split used when evaluating a recommender before deployment?
  • A. It guarantees the model will perform the same way online
  • B. It estimates performance using historical interactions without exposing real users to untested models ✓
  • C. It removes the need for any user feedback
  • D. It increases the number of items in the catalog

Why: Offline evaluation holds out part of historical interaction data to simulate how the model would perform, allowing safe and cheap comparison of models. Online A/B testing is still needed later, since offline metrics don't perfectly predict real user behavior.

Module 7 Module 7: Deploying Recommenders at Scale

Deploying Recommenders at Scale

Introduction

Core content I

Core content II

Core content III

Summary

Further learning

Knowledge check

Q1. Why do recommendation systems often precompute candidate lists offline rather than computing every recommendation at request time?
  • A. Offline precomputation removes the need for any user data
  • B. Serving latency budgets are tight, and computing scores for millions of items per request is too slow ✓
  • C. Precomputed lists are always more accurate than real-time scores
  • D. Online systems cannot store any results in memory

Why: Recommendation requests must return within tight latency budgets (often tens of milliseconds). Scoring every item in a large catalog for each request is too expensive, so systems precompute candidate sets or embeddings offline and only rank a small subset online.

Q2. What is the main purpose of a two-stage (retrieval and ranking) architecture in a large-scale recommender?
  • A. To train the model twice on the same data
  • B. To cheaply narrow millions of items to a few hundred candidates, then apply a more expensive model to rank them ✓
  • C. To store user history in two separate databases
  • D. To split traffic evenly between two A/B test variants

Why: Retrieval uses fast approximations (such as approximate nearest neighbor search over embeddings) to produce a manageable candidate set. A heavier ranking model with richer features then orders those candidates, balancing quality against compute cost.

Q3. Why is approximate nearest neighbor (ANN) search commonly used in deployed recommenders?
  • A. It guarantees exact top-k results every time
  • B. It trades a small amount of recall for large speedups when searching high-dimensional embedding spaces ✓
  • C. It eliminates the need for item embeddings
  • D. It only works on categorical features

Why: Exact nearest neighbor search over millions of high-dimensional vectors is too slow for online serving. ANN methods such as HNSW or IVF-based indexes accept slightly lower recall in exchange for sub-millisecond to few-millisecond query times.

Q4. What problem does model staleness cause in a production recommender, and how is it commonly mitigated?
  • A. Models become faster over time; mitigate by adding more layers
  • B. User preferences and item catalogs drift, so predictions degrade; mitigate by retraining or updating models frequently ✓
  • C. Stale models use too much memory; mitigate by deleting user logs
  • D. Staleness only affects offline metrics, so no action is needed

Why: User interests and the item catalog change constantly, especially with new products and trends. Without regular retraining or incremental updates, relevance drops. Teams mitigate this with scheduled retraining, streaming feature updates, and monitoring of online metrics.

Q5. Why do production teams typically validate a new recommendation model with an online A/B test even after it performs well offline?
  • A. Offline metrics such as accuracy on historical data may not reflect real user engagement and business outcomes ✓
  • B. A/B tests are required to train the model
  • C. Offline evaluation is mathematically impossible for recommenders
  • D. A/B tests reduce serving latency

Why: Historical logged data is biased by the previous recommender's choices, and offline metrics may not correlate with clicks, retention, or revenue. Online experiments measure the actual impact on users and the business before a full rollout.

Stay in the loop on this course.

We’ll email you when new modules or related material drops. No spam.

Built with Fragment Language. Sovereign architecture — no third-party trackers.
FragRun.mfgAFImemoryFGOwnership: B-Systems.ee