Next is a full-stack movie discovery and recommendation platform.
It combines modern web technologies, recommendation systems, and large language models to deliver personalized movie recommendations, conversational search, and intelligent movie discovery experiences.
The project is organized as a monorepo containing two submodules:
frontend/— React + Vite client applicationbackend/— Flask API, recommendation engine, and AI services
- Behavior Sequence Transformer (BST-style) recommender trained on user rating history
- SVD collaborative filtering recommender
- Background recommendation computation with APScheduler
- Personalized recommendation feeds stored per user
Describe a movie in natural language:
“space movie with a black hole”
The backend uses an LLM to extract candidate movies and validates them against TMDB metadata.
An AI-powered movie chatbot capable of:
- Random movie recommendations
- Genre-based recommendations
- Director-based recommendations
- Actor-based recommendations
- Similar-movie recommendations
- Context-aware multi-turn conversations
- Trending, popular, and top-rated movies
- TV show browsing
- Movie details pages
- Cast and trailers
- Similar and recommended titles
- Full-text search
- Firebase authentication
- Email verification and password reset
- Watchlists
- Star ratings
- Activity tracking
| Layer | Technology |
|---|---|
| Frontend | React 18, Vite, Redux Toolkit, MUI |
| Backend | Flask 3.x, Python 3.11 |
| Database/Auth | Firebase Auth + Firestore |
| Recommendation Models | TensorFlow/Keras BST + SVD |
| AI Services | Groq LLM API |
| Movie Data | TMDB API |
./
│
├── frontend/ # React + Vite frontend
├── backend/ # Flask backend + AI services
└── README.md
The frontend is a React-based movie discovery interface that integrates both TMDB APIs and the Flask backend.
- React 18
- Vite 4
- Redux Toolkit
- React Router v6
- MUI v5 + Emotion
- SCSS
- Axios
- Trending / popular / top-rated browsing
- Movie and TV search
- Detailed movie pages
- Watchlists and ratings
- Personalized recommendations
- AI movie finder
- Floating AI chatbot
- Node.js 18+
- Backend server running locally
cd frontend
npm installCreate a .env file:
VITE_APP_TMDB_TOKEN=<your-tmdb-v4-read-access-token>
VITE_FLASK_API_URL=http://127.0.0.1:5000npm run devFrontend runs on:
http://127.0.0.1:5173
The backend powers authentication, recommendation models, AI integrations, and movie-related APIs.
| Module | Responsibility |
|---|---|
user/ |
Authentication, ratings, watchlists, history |
movie_finder/ |
Natural-language movie search |
movie_chatbot/ |
Conversational movie recommendations |
movie_recommender/ |
BST + collaborative filtering |
core/ |
Shared services and utilities |
config/ |
Typed configuration system |
- Python 3.11
- Flask 3.x
- TensorFlow 2.15 / Keras 2.15
- Firebase Admin SDK
- Groq SDK
- TMDB API
- APScheduler
- Python 3.11
- Firebase project
- TMDB API key
- Groq API key
- SMTP email account
cd backend
python -m venv venvActivate virtual environment:
# Windows
venv\Scripts\activate
# Linux / macOS
source venv/bin/activateInstall dependencies:
pip install --upgrade pip
pip install -r requirements.txtCreate the following files inside backend/config/.
{
"SECRET_KEY": "<secret>",
"SECURITY_PASSWORD_SALT": "<salt>",
"JWT_BLACKLIST_TOKEN_CHECKS": ["access", "refresh"],
"JWT_BLACKLIST_ENABLED": true,
"MAIL_SERVER": "smtp.gmail.com",
"MAIL_PORT": 465,
"MAIL_USE_SSL": true,
"MAIL_USE_TLS": false,
"MAIL_USERNAME": "<email>",
"MAIL_PASSWORD": "<password>"
}{
"apiKey": "...",
"authDomain": "<project>.firebaseapp.com",
"databaseURL": "https://<project>.firebaseio.com",
"storageBucket": "<project>.appspot.com"
}{
"api_key": "<groq-api-key>",
"model": "llama-3.3-70b-versatile"
}{
"api_key": "<tmdb-api-key>",
"language": "en"
}Firebase service-account private key downloaded from Firebase Console.
python app.pyBackend runs on:
http://127.0.0.1:5000
The recommendation engine combines two approaches:
A Transformer-based recommendation model trained on user interaction sequences.
Features:
- Sequential recommendation
- Learns user behavior patterns
- Personalized predictions
Matrix-factorization collaborative filtering using user ratings.
Features:
- Learns latent user/movie embeddings
- Captures collaborative preferences
- Complements sequence modeling
Recommendations are periodically recomputed using APScheduler and stored in Firestore.
Uses a Groq-hosted LLM to:
- Parse natural-language descriptions
- Generate candidate movie titles
- Validate matches against TMDB
The chatbot:
- Detects recommendation intent
- Extracts filters
- Maintains conversational memory
- Returns contextual recommendations
Supported intents:
- Random recommendations
- By genre
- By director
- By actor
- Similar to another movie
POST /auth/signup
POST /auth/login
POST /auth/password_reset
GET /movie_recommender/
GET /movie_recommender/content-based
GET /movie_recommender/cf
POST /movie_finder/
POST /chatbot/
POST /ratings
POST /watchlist
GET /watchlist
POST /activity
This project is licensed under the MIT License.