Skip to content

Class 1: General Introduction to Recommender System

Tara-Su edited this page Jul 12, 2020 · 27 revisions

What you should do before the class

  1. Please read this blog post:

"Comprehensive Guide to build a Recommendation Engine from scratch"

  1. Please prepare the answers to the questions in the next session. Please use slides to convey your ideas when answering the questions. you can find the slides template at the home page

High-level introduction to the recommendation engine

Please read the above blog post before the first class. Explain the below concepts:

  • Q1: What is the purpose of the recommendation engine? (5 minutes)
  • Q2: What is content-based filtering? (5 minutes)
  • Q3: What is collaborative filtering? (5 minutes)
  • Q4: Why is popularity important in recommendation engines? (5 minutes)
  • Q5: What is matrix factorization? (5 minutes)
  • Q6: How to use matrix factorization in recommendation engine? (5 minutes)
  • Q7: Why evaluation of recommendation engine is tricky? (5 minutes)
  • Q8: What are the typical evaluation metrics? (10 minutes)

Additional discussion points

  1. Content-based filtering v.s. collaborative filtering
  2. What does normalization mean to collaborative filtering? Is it necessary? Why?
  3. Do you think every input in the distance measurement should have the same weight? If not, how would you weight them differently?
  4. Please come up with a toy example and hand calculates collaborative filtering results.
  5. Please come up with a toy example and hand calculates evaluation metrics.
  6. Code collaborative filtering from scratch. How can you use it for content-based filtering?
  7. How exactly is the below calculated? image
  8. Interesting. This is actually not a very common way of calculating the result. Can you think about why? image
  9. Cold start problem. image

A few more resources

Using different packages: Various Implementations of Collaborative Filtering

Code up a recommender with pandas: How to build a Simple Recommender System in Python

A good series:

How to calculate cosine similarity: Cosine Similarity between 2 Number Lists


Content-based Recommender Excercise

Pay attention to the resources above if you encounter difficulties doing the below tasks.

  1. Convert the pictures below into item characters
  2. Write Calculation of cosine similarity
  3. Use cosine similarity for the recommendation
  4. Evaluate your results and improve your algorithm

image image image image image