Introduction of Recommendation Systems (Concepts)

Thomas Tam
5 min readSep 21, 2020

--

What is a Recommendation System?

Recommendation System are simple algorithms that is used to recommend items to users based on their user information.

One of the main advantages of a recommendation system is that users are more exposed to many different items that are not usually shown to them. A recommendation system is no different than going to a restaurant and asking the waiter to recommend you dishes you might like to eat. The waiter would then ask you several questions what type of food do you like to eat — “are you adventurous? do you like spicy food?” What the waiter is doing is filtering through the restaurant menu to best cater to what you would like to eat. It is a prediction at best, but the goal of a recommendation system is to find the best accurate prediction for each user.

Why is this important?

It is important for online businesses to help users deal with information overload by providing personalized recommendations for them. These systems are commonly seen in online businesses such as e-commerce stores, media services, and job searches. For example when browsing for picture frames on Amazon, we see recommender systems in action as shown below.

The third recommendation (the dog one) is the exact thing you needed and you ended up purchasing it.
The third recommendation (the dog one) is the exact thing you needed and you ended up purchasing it

This shows how recommendation system can be so powerful. After you browse for one thing, you end up browsing for other items leading to 10 more items in your cart! With more items being purchased, this increases sales and potential customer retention for the service provider.

In this article, we will be focusing on personalized recommendation systems where recommendations are specifically focused on the user characteristics and profile. There are two main types of recommender systems: Content-Based and Collaborative Filtering.

Content Based Filtering

“Show me similar items that I will like”

Content Based recommends item to users based on their preference. If you like Disney movies, the system will recommend you Disney movies. If you like action/comedy movies, you’re going to be recommended action/comedy movies. The algorithm evaluates an user profile, looks at what type of characteristics the user likes, and will recommend similar items with those characteristics.

Advantages & Disadvantages

The advantage of content based is the algorithm does not need any data from other users, and the recommendations are independent to each user. As the algorithm caters only to the interest of each user, it is more computational efficient and is easier to scale to more users.

Disadvantages are items require manual tagging of characteristics. The idea behind content based is items are tagged using specific keywords, understand what the user likes, and then recommend the user items with those keywords. Because it looks at keywords for each item, the service provider would need to tag all their items. This can potentially be a lot of manual work as there are thousands of movies.

Collaborative Filtering

Collaborative Filtering uses a collection of user rating of items, finds relationship between users, and makes recommendations based on the similarities. To find the similarities between users, we use user rating (implicit or explicit) for items as our metric. Users are considered similar if they rate multiple items with similar ratings through something called embeddings. Embeddings are basically hidden characteristics that collaborative filtering can automatically detect based on both items and user ratings.

Advantages and Disadvantages

Unlike content-based filtering, the model does not need manual tagging of items but instead learns automatically through similarities of user and items making it easier to implement. In addition, collaborative filtering trains the model by using a lot of data which in return can provide more accurate results.

Collaborative filtering runs into the problem of data sparsity meaning there is not enough data among users and items to predict anything! If users do not give enough ratings to a new item, there is no way of knowing the embeddings between the users and the item. This applies to new users as well since if there is no data for new users, there is nothing for the model to predict on. In both cases, this is called the “cold-start problem” and with not enough data, can lead to improper recommendations.

How does collaborative filtering work?

Let’s look at how collaborative filtering works through matrix factorization.

In the user-item matrix on the left, it shows five users and their ratings of four different items. Each row is the user, column is an item, and the user rating for an item is between 1–5. There are a lot of missing ratings since it is rare for users to rate all items — this is called a sparse matrix. For an user with empty ratings, the goal is to predict the user rating for each item and recommend the items with the highest ratings.

The main purpose of matrix factorization is to factorize the user-item matrix into separate matrixes — an user matrix and an item matrix by finding the underlying interactions between the user and item.

Let’s look at another example on the left. The user-item matrix (bottom right) is split between the user (left) and items (top). The decomposed user matrix shows the movie genres of what the user likes, and the decomposed item matrix shows the genre of the movie.

These genres are known as latent features as they are not directly observed but instead are indirectly extracted from the interactions between user and item. Latent features can be anything about the movie which include the genre, number of female actresses, how much action, etc.

Once the algorithm figures out the latent features for each decomposed matrix, we can then use matrix multiplication to calculate ratings for each user. The highest rated movies would be recommended to the user.

Sign up to discover human stories that deepen your understanding of the world.

Free

Distraction-free reading. No ads.

Organize your knowledge with lists and highlights.

Tell your story. Find your audience.

Membership

Read member-only stories

Support writers you read most

Earn money for your writing

Listen to audio narrations

Read offline with the Medium app

--

--

No responses yet

Write a response