Chapter 13. Ranking and learning to rank

 

This book is all about learning, and in this chapter, you’ll learn how to rank.

  • You’ll reformulate the recommender problem to a ranking problem.
  • You’ll look at Foursquare’s ranking method and how it uses multiple sources.
  • You’ll go through the different types of Learning to Rank (LTR) algorithms and learn how to distinguish pointwise, pairwise, and listwise comparisons of ranks.
  • You’ll learn about the Bayesian Personalized Ranking (BPR) algorithm, which is a promising algorithm to implement.

Are all these chapters on recommender algorithms starting to look the same? If so, you’re in luck, because now you’re going to start something completely different. Instead of focusing on recommendations as a rating prediction problem, it sometimes makes more sense to look at how the items should be stacked. The catalog item that the user would find most relevant is on top, the second one next, and so on. To define relevancy like this takes away the need to predict ratings. You don’t need to know how favorably users would rate something, only that they’d love it, or at least like it more than everything else that’s available.


Note

Keep in mind that the catalog of content might not contain anything the user would love, but even when that’s the case, you still want to provide a list of the best you can do with what you have.


13.1. Learning to rank an example at Foursquare

13.2. Re-ranking

13.3. What’s learning to rank again?

13.3.1. The three types of LTR algorithms

13.4. Bayesian Personalized Ranking

Task to solve

If you have implicit data

With explicit data sets

The training data set

13.4.1. Ranking with BPR

13.4.2. Math magic (advanced wizardry)

13.4.3. The BPR algorithm

13.4.4. BPR with matrix factorization

13.5. Implementation of BPR

sitemap