CoolFace
Apppublic

Zebra668/movie-recommender

sourceHugging Facemitupdated 3mo agoView on Hugging Face
0likes
App README

๐ŸŽฌ CineRec โ€” Movie Recommendation System

S-Class cinematic movie recommender with 3 AI strategies + sentiment analysis.

Tech Stack

LayerTechnology
FrontendHTML + CSS + Vanilla JS โ†’ GitHub Pages
BackendFastAPI + Python โ†’ Hugging Face Spaces
DatabaseSQLite
Movie DataTMDB API
MLTF-IDF + Cosine Similarity + Item-Based CF
SentimentCustom rule-based analyzer

3 Recommendation Strategies

  1. 1.Content-Based โ€” Genre, keywords, cast se similar movies
  2. 2.Collaborative Filtering โ€” User ratings ke pattern se
  3. 3.Hybrid โ€” Dono ka combination (best results)

๐Ÿš€ Deploy Steps

Step 1: Backend โ†’ Hugging Face Spaces

  1. 1.HuggingFace pe new Space banao
  2. 2.SDK: Docker
  3. 3.Name: movie-recommender
  4. 4.Visibility: Public
  1. 1.backend/ folder ki sab files upload karo
  1. 1.Space Settings โ†’ Secrets mein add karo:
   TMDB_API_KEY = f2c65dbd4b13d7dda8b7bb8ae95448b4
  1. 1.Space automatically build ho jaayega
  2. 2.URL milegi: https://YOUR-USERNAME-movie-recommender.hf.space

Step 2: Frontend โ†’ GitHub Pages

  1. 1.GitHub pe new repo banao: movie-recommender-frontend
  1. 1.frontend/ folder ki sab files upload karo
  1. 1.app.js mein line 4 update karo:
javascript
   const API_BASE = "https://YOUR-HF-USERNAME-movie-recommender.hf.space";
  1. 1.GitHub repo Settings โ†’ Pages โ†’ Branch: main โ†’ Save
  1. 1.URL milegi: https://YOUR-GITHUB-USERNAME.github.io/movie-recommender-frontend

Project Structure

backend/
โ”œโ”€โ”€ main.py          โ† FastAPI routes
โ”œโ”€โ”€ recommender.py   โ† 3 ML strategies
โ”œโ”€โ”€ sentiment.py     โ† Review sentiment
โ”œโ”€โ”€ database.py      โ† SQLite
โ”œโ”€โ”€ tmdb.py          โ† TMDB API helper
โ”œโ”€โ”€ requirements.txt
โ””โ”€โ”€ Dockerfile

frontend/
โ”œโ”€โ”€ index.html       โ† Home page
โ”œโ”€โ”€ movie.html       โ† Movie detail + reviews + recommendations
โ”œโ”€โ”€ style.css        โ† Cinematic dark gold design
โ””โ”€โ”€ app.js           โ† All frontend logic

Features

  • โ€”โœ… Live movie data + posters from TMDB
  • โ€”โœ… 3 recommendation strategies with tab switcher
  • โ€”โœ… Post-watch recommendations banner
  • โ€”โœ… Star rating + text review system
  • โ€”โœ… Automatic sentiment analysis (positive/negative/neutral)
  • โ€”โœ… Sentiment visualization bars
  • โ€”โœ… Movie search with live dropdown
  • โ€”โœ… Genre filter chips
  • โ€”โœ… Hero banner with auto-rotation
  • โ€”โœ… Skeleton loading states
  • โ€”โœ… Responsive design (mobile friendly)
  • โ€”โœ… Watch history tracking
  • โ€”โœ… Personalized recommendations per user