Sentiview is an interactive web application that analyzes the sentiment of YouTube video comments in real-time using BERT-based NLP models. Just enter a video URL, and Sentiview will fetch comments, detect language, and classify sentiment (Positive, Negative, Neutral) — all in a clean Streamlit dashboard.
- 🔍 Real-time comment extraction from any YouTube video
- 🌍 Language detection for multilingual comments
- 🤖 Sentiment classification using fine-tuned BERT
- 📈 Performance metrics: Accuracy, F1-Score, Confusion Matrix
- 🧠 Evaluation on 18,000+ labeled YouTube comments
Tested on the YoutubeCommentsDataSet.csv (first 100 samples):
📊 Classification Report: precision recall f1-score support
- ✅ Accuracy: 90.00%
- ✅ Macro F1 Score: 0.9029
- ✅ Weighted F1 Score: 0.9032
- Frontend: Streamlit
- Backend: Python, HuggingFace Transformers, pandas
- Model: BERT
- APIs: YouTube Data API v3
- NLP Tools:
langdetect,transformers,nltk
- Enter a YouTube video URL in the app
- Fetch top N comments using the YouTube Data API
- Detect language (skip if not supported)
- Run BERT sentiment classification
- Display key metrics and most positive/negative comments
git clone https://github.com/your-username/sentiview.git
cd sentiview
pip install -r requirements.txtThen, add your YouTube API Key in config.py:
API_KEY = "YOUR_YOUTUBE_API_KEY"streamlit run app.py├── app.py # Streamlit dashboard interface
├── fetch_comments.py # YouTube comment fetcher
├── detect_language.py # Language detection utility
├── utils.py # Helper functions incl. BERT pipeline
├── evaluate.py # Model evaluation script
├── YoutubeCommentsDataSet.csv # Sample labeled dataset
├── requirements.txt # All dependencies
└── README.md
- Name: YoutubeCommentsDataSet.csv
- Size: ~18,000 labeled YouTube comments
- Sentiment Labels: Positive, Neutral, Negative
- Source: Kaggle - YouTube Comments Sentiment