An open API service indexing awesome lists of open source software.

https://github.com/vickshan001/imdb-search-engine-project

NLP-powered IMDb search engine with Flask backend using BM25 and TF-IDF for smart movie retrieval and ranking.
https://github.com/vickshan001/imdb-search-engine-project

bm25 flask imdb information-retrieval movie-search nlp python react search-engine tf-idf

Last synced: 2 months ago
JSON representation

NLP-powered IMDb search engine with Flask backend using BM25 and TF-IDF for smart movie retrieval and ranking.

Awesome Lists containing this project

README

          

# ๐ŸŽฌ IMDb Smart Search Engine

An intelligent NLP-powered search engine that allows users to query and explore IMDb's top 1000 movies using natural language. Built as part of a **group project for the "Information Retrieval" module (2024)**.

---

## ๐Ÿ‘ฅ Group Contribution

This project was developed collaboratively as part of our university coursework.
**The backend** (Flask API, data preprocessing, ranking models) was designed and implemented by **Vickshan Vicknakumaran** and a teammate.
The **frontend** (React-based UI) was handled by other team members.

---

## ๐Ÿ“Œ Project Overview

**IMDb Smart Search Engine** helps users find relevant movies using natural queries like:

> โ€œAction film with Leonardo DiCaprio from the 2000sโ€

Instead of relying on exact title matches, the system ranks results using semantic similarity via **BM25** and **TF-IDF**.

---

## ๐Ÿ“ฑ Features

- ๐Ÿ”Ž Search by title, genre, director, actors, or keywords
- ๐Ÿง  Ranking with **BM25** and **TF-IDF cosine similarity**
- ๐Ÿงน Preprocessing with NLTK (tokenization, stopwords, stemming)
- โšก RESTful API using Flask
- ๐Ÿ”„ CORS enabled for React frontend integration
- ๐Ÿ“ˆ Based on IMDb Top 1000 dataset (CSV)

---

## ๐Ÿ›  Technologies Used

- **Backend**:
- Python, Flask, NLTK
- BM25Okapi (`rank_bm25`)
- Scikit-learn (TF-IDF, cosine similarity)
- Pandas
- Flask-CORS

- **Frontend**:
- React (handled by front-end team members)

## ๐Ÿ’ก How It Works

- User submits a search query via the React frontend
- Flask backend receives the query, preprocesses it with NLTK
- Two models (BM25 & TF-IDF) rank the top matching movies
- Combined and deduplicated results are returned as JSON
- Frontend displays results with movie posters and metadata

---

## ๐Ÿ–ผ๏ธ Screenshots



---

## ๐Ÿ”ฎ Future Improvements

- Use Transformer models (e.g. BERT) for context-aware ranking
- Add user preferences/history for personalized results
- Integrate movie streaming service availability
- Build chatbot-style interface

---

## ๐Ÿ“‚ Example API Call

Returns:

```json
{
"search_results": [
{
"Series_Title": "The Dark Knight",
"Genre": "Action, Crime, Drama",
"Director": "Christopher Nolan",
"Stars": ["Christian Bale", "Heath Ledger", "Aaron Eckhart", "Michael Caine"],
"IMDB_Rating": 9.0,
...
}
]
}

##๐Ÿ“š Module Information
-๐Ÿ“˜ Module: CI6416 โ€“ Information Retrieval
-๐ŸŽ“ Year: 2024
-๐Ÿซ University: Queen Mary, University of London