Content Based Recommender System recommends movies similar to the movie user likes and analyses the sentiments on the reviews given by the user for that movie.
The details of the movies (title, genre, poster, etc) are fetched using an API by TMDB, https://www.themoviedb.org/documentation/api, and using the IMDB id of the movie in the API.
This project runs on the idea of conversion of Tags into Vector and we grab the 5 Closest vectors from it and show it known as Cosine Similarity.
Check out the live demo: https://movie-recommendation-system-pk.herokuapp.com/
Mathematically, it measures the cosine of the angle between two vectors projected in a multi-dimensional space.
It is a numerical value, ranges between 0 to 1 which helps to determine how much two items are similar or close to each other on a scale of 0 to 1. This similarity score is obtained by measuring the similarity between the text details of both of the items.
- Clone or download this repository to your local machine.
- Install all the libraries mentioned in the requirements.txt file with the command
pip install -r reuirements.txt
- Get your API key from https://www.themoviedb.org/ (Refer the below section on how to get the API key)
- Replace YOUR_API_KEY in the 7th line of
app.py
and hit save. - Open your terminal/command prompt from your project directory and run the file
app.py
by executing the commandpython app.py
- Go to your browser and type
http://127.0.0.1:5000/
in the address bar. - And, there you go!
Create an account in https://www.themoviedb.org/, click on the API
link from the left hand sidebar in your account settings and fill all the details to apply for API key. If you are asked for the website URL, just give "NA" if you don't have one. You will see the API
key in your API sidebar once your request is approved.