This is a movie recommender system that uses your current list of watched movies to recommend other titles you may be interested in. It is currently using content based recommender system.
conda create --no-default-packages -n <env_name>
conda activate <env_name>
conda install python=3.9
pip install -r requirements.txt
Follow the instructions here to generate your own api key:
https://developers.themoviedb.org/3/getting-started/introduction
tmdb_api_key = '<api_key>'
Additional Note: Import category.py in main.py and adjust accordingly if you were to run this locally because this code uses github secrets to add env variable to docker image
uvicorn app.api:app --host localhost --port 8000 --reload --reload-dir .
The list of movies for a user needs to be the tmdb_id for a specific movie. It is made this way to prevent any problems caused by the case of a string (Ex. The Dark Knight != the dark knight).
import requests
import json
payload = {
"user_id": 0,
"movie_list": [76600, 267805, 315162, 436270, 505642, 536554, 587092, 631842, 640146, 646389, 653851, 758009, 785084, 823999, 842544, 842942, 843794, 1058949]
}
response = requests.post(url='http://localhost:8000/predict',json=payload)
output_ = json.loads(response.text)