Recommender Systems - Introduction

This is the first step in a series of posts that will deal with the topic of “Recommendation Systems”. We will start from scratch, giving the definition of such systems along with examples and we will continue with the description, the pros and the cons of all the known algorithm categories used by recommenders in our days.

At this post we will start with an introduction to this topic while in the following posts we will describe all the different approaches in solving the problem of recommendations.

Introduction

In our days, a lot of people seem to care about recommender systems and we are going to discover that there are significant reasons for this. The most important one is money: such systems for companies like Amazon, Netflix and Spotify drive significant user engagement which then translates to revenue. But beyond the cynical view of things, the truth is that recommender systems deliver actual value to their customers by personalising content for users in scenarios with too many available items.

Before we dive into the technological details, we first need to define what a recommendation system is. According to wikipedia it is a subclass of information filtering system that seeks to predict the “rating” or “preference” that a user would give to an item, but I find this definition too narrow and as I read in an interesting article a better definition would be the following:

“Recommender systems are systems that help users discover items they may like.”

Having defined what a recommender system is and why some of the biggest technological companies invest so much time and money on them, it’s time to classify such systems in categories.

A first classification would be to differentiate recommender systems that are trained on the fly when a new user rates a new item from the systems that are trained one time, creating a model, and then use that model to predict the “ratings” that a user would give to a new item. So, following this path we could say that there are “Online” and “Offline” recommenders, along with a hybrid solution according to which, a better approach would be to have systems that are prepared in an offline way every once in a while but simultaneously having their knowledge increased in an online way every time a user interacts with the system.

A second classification, would be according to the type of data that is used to generate recommendations. Following this path, we have the next three main categories: Knowledge- based algorithms, Context-based algorithms and Collaborative Filtering algorithms. Although, we need to mention that the distinction between approaches is more academic than practical, as it is often a good idea to use hybrids or ensembles to address each method’s limitations. In this paper we are going to use this type of classification as we present the algorithms used in recommender systems.

As we have briefly analysed above, recommenders are used to predict what items users may like. When we say items, we mean what advertisings they may find interesting enough to click on, or what articles they may want to read, or what products they intend to order, or what movie they would like to watch next etc.

Such systems exist already everywhere around us. The newsfeed of Facebook is empowered from recommendation algorithms in order to prioritise the posts that each user may want to see. Yahoo uses this technology for years in order to personalise their front page so as the most related to user articles and ads are displayed first. Netflix and Spotify use such systems in order to understand our taste in music and movies and to be able to recommend us more content that we may like. Amazon uses recommenders to show us first the products that interest us among the thousands of items that are sold in their platform.

Recommender systems are a true data science problem, and as every other problem they need some metrics according to which their effectiveness could be measured. Such metrics could be different from application to application in respect to what the application’s goal is. Some general metrics are the relevance score of an item for a user, the Click-Through Rate (the ratio of users who click on a specific link to the number of total users who view a page), the revenue and the user engagement (eg. time spent on a page).

Recommenders needs a big amount of data in order to be able to provide us with reliable results. The data could be either explicitly specified by the user like a query, a few keywords or some ratings, or implicitly specified like the time the user spent seeing an article, where he clicked, the series of his actions etc. Additionally, the results usually are filtered according to domain specific constraints that indicates which matches are legitimate. Such constraints may be the business rules of a market, the diversity rules or an editorial voice if we talk about the news world.

At this point, we have to bust another myth. People think that there is so much data on the web and that if we could only precess it we would have solved our problem. But this is not true. Data is sparse in web recommender problems and the truth is that we actually lack enough data to learn all we want to learn and as quickly as we would like to learn.

So, how can Machine Learning help data science to solve this issue? It has been observed that there are group behaviours that generalise to individuals and that these behaviours are relatively stable. So, the key point and the solution to recommendations problem is to estimate such groups.

Data

The entry point of each and every recommendation problem is the provided data, the quality of which will lead the system to an accurate result. As we mentioned in the introduction, most of the times we actually lack enough data to learn all we want to learn and as quickly as we would like to learn. But, what kind of data do we need to create accurate recommendations?

Input data can be split into two main categories. The data coming from explicit users’ feedback and the data coming from implicit users’ feedback. A user’s feedback is called explicit when the user have actually told us how much she liked (or disliked) an item. For example, rating a movie with 4 out of 5 stars is an explicit feedback. On the other hand, a user’s feedback is called implicit when the user have not explicitly told us how much she likes an item, but instead we have gathered some other data like what items she clicked on, what pages she visited, what items she ordered in the past, if she re-ordered some of these items at some point later and every other interaction with the system that we can leverage to understand if the user likes an item or not.

Explicit data tend to be more accurate, steady and easier to analyse while implicit data usually needs some business logic rules to be transformed into usable information. For this reason, most of the research that have beed done until today is about recommender systems based on explicit users’ feedback. On the other hand, most of the times in real-world applications systems cannot afford the luxury of explicitly asking customers what they liked or not.

So, the most usual way that companies tend to find their data is through a hybrid method. If for example a restaurant needs a recommender system for their web ordering platform, they may ask their users to rate each item they have ordered in the past but simultaneously they may want to record each click that the user have made while browsing the web page along with the time that the user spent in each of the visited pages, in order to reach to conclusion about the not rated items.

Another concept that we need to analyse regarding the data, is the well-known “Cold Start problem”. This problem concerns the issue that the system cannot draw any inferences for users or items about which it has not yet gathered sufficient information. If for example a new user is registered in a platform, the recommender does not know anything about what he likes or not and thus it cannot recommend anything to him. The same goes for newly introduced items.

Written on February 25, 2018