Skip to content

BhagwatiOracle/BERTVibeAI

Repository files navigation

BERT Sentiment Analyzer Banner

📘 BERT Sentiment Analyser

A production-ready Sentiment Analysis system using a fine-tuned BERT model.


📝 Overview

This project is a Sentiment Analysis Application built using a fine-tuned BERT model on the IMDB movie reviews dataset.

  • The model is trained via the Hugging Face Trainer API (3 epochs)
  • Performs binary sentiment classification (Positive / Negative)
  • Includes an intuitive Gradio UI and Docker deployment

🚀 Features

  • Single Review Analysis - analyse sentiment of single review

  • Batch Review Analysis - analyse sentiment of multiple reviews uploaded in CSV file with review column .

  • Youtube Comment Analysis - fetch the comments of youtube video and analyse it's sentiment.


🖼️ Screenshots

📌 Click to expand UI Screenshots

🔹 Single Review Analysis

🔹 Batch Analysis Output & Word Cloud Visualization

🔹 YouTube Comment Analysis


📂 Project Structure

📦 BERT-Sentiment-Analyzer
│
├── sentiment_analyser.py      # Model class (modular + reusable)
├── LLM_review.py              # LLM-based review analysis module
├── youtube_data.py            # Fetch + preprocess YouTube comments/videos
├── app_interface.py           # Gradio UI
├── requirements.txt           
├── Dockerfile                 
├── .dockerignore              
├── .gitignore                 
├── README.md                  
├── assets/                    # screenshots or icons
└── BERT_Fine_Tuning.ipynb     # fine-tuned BERT model

⚙️ Setup Instructions

1️⃣ Clone the repository

git clone https://github.com/BhagwatiOracle/BERT-Sentiment-Analyser.git

cd BERT-Sentiment-Analyser

2️⃣ Create a virtual environment

python -m venv venv

source venv/bin/activate     # Windows: venv\Scripts\activate

3️⃣ Install dependencies

pip install -r requirements.txt

4️⃣ Create .env file and set up api keys

GROQ_API_KEY = "your_groq_api_key"

YOUTUBE_DATA_API_KEY = "your_youtube_data_api_key"

5️⃣ Run the app

python app_interface.py

🐳 Run With Docker

1️⃣ Build image

docker build -t sentiment-app .

2️⃣ Run container

docker run -p 8000:8000 sentiment-app

3️⃣ Open Browser

http://localhost:8000


⭐ Contributing

Pull requests are welcome! Feel free to open issues for improvements.

About

Sentiment Analysis Application built using a fine-tuned BERT model on the IMDB movie reviews dataset. The model is trained via the Hugging Face Trainer API (3 epochs) and performs binary sentiment classification (Positive / Negative)

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors