Built and deployed an NLP-powered movie recommendation engine using content-based filtering, processing 4,800+ movies and generating real-time recommendations through a Flask REST API integrated with OMDB.
CineMatch is an NLP-powered content-based movie recommendation system that recommends movies based on their content rather than user watch history. By analyzing movie overviews, genres, keywords, cast members, and directors, the system identifies similar movies and provides highly relevant recommendations.
The recommendation engine leverages Natural Language Processing (NLP), Bag-of-Words vectorization, and Cosine Similarity to process over 4,800 movies and generate recommendations in real time through a Flask-powered web application.
๐ Live Demo: https://recommendation-system-1-gjc3.onrender.com
- ๐ฅ Content-Based Movie Recommendation Engine
- ๐ง NLP-Powered Similarity Analysis
- โก Instant Top-5 Movie Recommendations
- ๐ผ๏ธ Real-Time Movie Poster Retrieval using OMDB API
- ๐ Responsive Cinematic User Interface
- ๐ Flask REST API Backend
- โ๏ธ Render Deployment
- ๐ฑ Mobile-Friendly Design
The TMDB 5000 Movies Dataset was cleaned and transformed by extracting key features:
- Movie Title
- Overview
- Genres
- Keywords
- Top 3 Cast Members
- Director
These features were merged into a unified metadata field called tags, representing each movie's content profile.
- Converted text to lowercase
- Removed inconsistencies across metadata
Implemented using NLTK's Porter Stemmer.
Example:
acting, actor, acted โ act
This reduces redundant vocabulary and improves feature representation.
Implemented using Scikit-Learn's CountVectorizer.
from sklearn.feature_extraction.text import CountVectorizer
cv = CountVectorizer(
max_features=5000,
stop_words='english'
)Each movie is transformed into a vector in a 5000-dimensional feature space.
The recommendation engine measures similarity using cosine similarity.
Cosine Similarity = (A ยท B) / (||A|| ร ||B||)
Interpretation:
- 1.0 โ Highly Similar
- 0.0 โ Completely Different
The system generates a similarity matrix of approximately:
4806 ร 4806
allowing fast retrieval of the most similar movies.
| Metric | Value |
|---|---|
| Movies Processed | 4,806 |
| Vocabulary Size | 5,000 Features |
| Similarity Matrix | 4,806 ร 4,806 |
| Recommendation Type | Content-Based Filtering |
| Average Response Time | < 1 Second |
- Python
- Pandas
- NumPy
- Scikit-Learn
- NLTK
- Flask
- Gunicorn
- Requests
- HTML5
- CSS3
- JavaScript
- Tailwind CSS
- Render
- GitHub
- Git LFS
POST /api/recommend{
"movie": "Avatar"
}{
"recommendations": [
{
"title": "John Carter",
"poster": "poster_url"
},
{
"title": "Guardians of the Galaxy",
"poster": "poster_url"
}
]
}Movie-Recommendation-System/
โ
โโโ app.py
โโโ movie_dict.pkl
โโโ similarity.pkl
โโโ requirements.txt
โโโ Procfile
โโโ runtime.txt
โ
โโโ templates/
โ โโโ index.html
โ
โโโ Movie REcommendation System.ipynb
โ
โ
โโโ README.md
TMDB 5000 Movies Dataset
Source:
https://www.kaggle.com/datasets/tmdb/tmdb-movie-metadata
The dataset contains:
- Movie Metadata
- Genres
- Keywords
- Cast Information
- Crew Information
- Movie Overviews
git clone https://github.com/YOUR_USERNAME/Movie-Recommendation-System.git
cd Movie-Recommendation-Systempython -m venv venvvenv\Scripts\activatesource venv/bin/activatepip install -r requirements.txtCreate a .env file:
OMDB_API_KEYGet a free API key from:
https://www.omdbapi.com/apikey.aspx
python app.pyVisit:
(https://recommendation-system-1-gjc3.onrender.com)
The application is deployed on Render using:
- Flask
- Gunicorn
- GitHub Integration
Start Command:
gunicorn app:app- Hybrid Recommendation System
- Collaborative Filtering Integration
- User Authentication
- Personalized Recommendations
- Watchlist Functionality
- Movie Trailer Integration
- Sentiment Analysis of Reviews
- Genre-Based Filtering
- Recommendation Explanation Engine
Shrisha
Computer Science Engineering Student Ajay Kumar Garg Engineering College (AKGEC)
- GitHub: https://github.com/shrisha337-beep
- LinkedIn: www.linkedin.com/in/shri04
This project is licensed under the MIT License.

