|
A comprehensive sentiment analysis application built with advanced NLP techniques and deployed on Streamlit Cloud. |
|
- π Live Demo
- β¨ Features
- π€ Machine Learning Pipeline
- π Performance Metrics
- π οΈ Technology Stack
- π¦ Installation & Setup
- π Deployment on Streamlit Cloud
- π Project Structure
- πΈ Screenshots
- π€ Contributing
- π Model Performance Details
- π Known Issues
- π Acknowledgments
- π Contact
- Real-time sentiment prediction
- Confidence scores with probability breakdown
- Interactive visualizations
- Text preprocessing insights
- Analyze multiple texts simultaneously
- Batch results with summary statistics
- Export functionality
- Historical analysis trends
- Confidence distribution charts
- Performance metrics
- Data insights
- Complete analysis history
- Timestamp tracking
- Pattern recognition
- Text normalization and cleaning
- Stopword removal
- Lemmatization
- N-gram feature extraction
- TF-IDF Vectorization: Advanced term frequency analysis
- Count Vectorization: Bag-of-words representation
- N-grams: Unigrams and bigrams for context
- Multiple algorithms tested:
- Naive Bayes
- Logistic Regression
- Random Forest
- Support Vector Machine
- Hyperparameter optimization
- Cross-validation for robust performance
| Model | Accuracy | Precision | Recall | F1-Score |
|---|---|---|---|---|
| Best Model | 70%+ | 0.85+ | 0.80+ | 0.80+ |
- Frontend: Streamlit
- Backend: Python 3.9+
- ML Libraries: scikit-learn, NLTK
- Visualization: Plotly, Matplotlib, Seaborn
- Deployment: Streamlit Cloud
- Version Control: Git & GitHub
- Python 3.9 or higher
- Git
-
Push to GitHub
git add . git commit -m "Initial commit" git push origin main
-
Deploy on Streamlit Cloud
- Visit share.streamlit.io
- Connect your GitHub repository
- Select your repository and branch
- Set main file path:
app.py - Click "Deploy!"
-
Automatic Updates
- Any push to your GitHub repository will automatically update your deployed app
sentiment-analysis-dashboard/
β
βββ app.py # Main Streamlit application
βββ sentiment_analysis_model.pkl # Trained ML model
βββ requirements.txt # Python dependencies
βββ README.md # Project documentation
βββ preprocessing.py # Data preprocessing scripts
βββ model_training.py # Model training pipeline
β
βββ data/ # Data directory
β βββ raw/ # Raw datasets
β βββ processed/ # Cleaned datasets
β
βββ notebooks/ # Jupyter notebooks
β βββ EDA.ipynb # Exploratory Data Analysis
β βββ preprocessing.ipynb # Data preprocessing
β βββ modeling.ipynb # Model development
β
βββ assets/ # Static assets
βββ screenshots/ # App screenshots
βββ demo/ # Demo files
Contributions are welcome! Please feel free to submit a Pull Request.
- Fork the repository
- Create your feature branch:
git checkout -b feature/AmazingFeature - Commit your changes:
git commit -m 'Add AmazingFeature' - Push to the branch:
git push origin feature/AmazingFeature - Open a Pull Request
- Dataset Size: [(1440 Records, 5 Fields)]
- Features: Preprocessed text data
- Labels: Positive, Negative, Neutral
"It's a very bad product, highly dissatisfied.. Specifically the colour is too whitish and unreal display.. Won't recommend to buy, instead go for M31.. It hangs as well within less than a month of purchase."
- Predicted Sentiment: Negative
- Confidence: 79.5%
- Top Keywords: bad, product, highly, dissatisfied, specifically, colour
Classification Report:
precision recall f1-score support
Negative 0.75 0.75 0.75 102
Neutral 0.25 0.30 0.30 40
Positive 0.81 0.77 0.80 146
accuracy 0.72 288
macro avg 0.61 0.61 0.60 288
weighted avg 0.71 0.70 0.71 288
- Large text inputs (>10,000 characters) may take longer to process
- NLTK downloads required on first run
- NLTK for natural language processing tools
- scikit-learn for machine learning algorithms
- Streamlit for the amazing web framework
- Plotly for interactive visualizations
Your Name - sathwikyalagala@gmail.com
Project Link: https://github.com/SathwikPatel12/SentimentAnalysis-Streamlit
Live Demo: https://sentimentanalysis-app-ctenkjk48urxzuudzft2pk.streamlit.app/
β Star this repository if you found it helpful! β



