26 Jul Building a Movie Recommendation System Using TigerGraph
Recommendation systems are used in our daily life for a variety of reasons including products, movies, music, news, and books. These recommendations are based on the user’s historical behavior and the behavior of other users having similar tastes. In this video we will build a simple movie recommendation system using TigerGraph’s graph database technology. We use the MovieLens dataset of 20,000,000 movie ratings from about 138,000 users towards about 27,000 movies.
To follow along, download the free TigerGraph Developer Edition. After registration, you will receive an email including download link and installation guide. The installation takes about 15 minutes. You can also download the MovieLens dataset at: https://grouplens.org/datasets/movielens/20m/.
Following the video, you will learn how to build a simple movie recommendation system using TigerGraph’s GraphStudio SDK to:
- Build a graph schema
- Map data to graph and load data
- Explore and visualize graph data
- Write a collaborative filtering algorithm using GSQL language
- Find all movies rated by p, and call the movie set M1.
- Find all people rated at least one movie within M1, and exclude p from the person vertex set, calculate the taste similarity between each person in the set with p (cosine similarity), and retain k1 people with highest similarity, name the person vertex set P2.
- Find all movies rated by at least one person in P2, and not rated by p, calculate the average rating of each movie by the people in P2, select the top k2 movies with highest average rating and recommend to p. Use the average rating as recommending score.
You can learn more detail about collaborative filtering at: https://en.wikipedia.org/wiki/Collaborative_filtering
We use cosine similarity to measure the taste similarity between two persons. Given two people p1 and p2, assume the movies they both rated is set M, then A is the rating from p1 to each movie in M, and B is the rating from p2 to each movie in M, following same element order in M. Their movie rating cosine similarity is:
You can learn more about cosine similarity at https://en.wikipedia.org/wiki/Cosine_similarity
Because of space limitations, we only touch a small portion of the functionalities supported by TigerGraph. If you are interested in learning more about TigerGraph here are some helpful resources to download:
- GSQL White Paper: In this paper we compare GSQL to other prominent graph query languages in use today – Cypher and Gremlin.
- Benchmarking Graph Analytics Systems: TigerGraph, Neo4j and Titan
- Free Trial of TigerGraph’s Enterprise Edition: supports distributed graph storage and computing, online schema change, multiple graphs, user management, HA, backup and restore, and many more enterprise ready features.
- Find a detailed comparison between the Developer Edition and Enterprise Edition here: https://www.tigergraph.com/download/
If you have any questions please contact email@example.com for more information.
 F. Maxwell Harper and Joseph A. Konstan. 2015. The MovieLens Datasets: History and Context. ACM Transactions on Interactive Intelligent Systems (TiiS) 5, 4, Article 19 (December 2015), 19 pages. DOI=<The MovieLens Datasets>