Spaces:
Sleeping
Sleeping
File size: 1,335 Bytes
7f1e06f ca0535d 7f1e06f ca0535d 7f1e06f ca0535d | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 | ---
title: Twitter Sentiment Analysis
emoji: ⚡
colorFrom: purple
colorTo: blue
sdk: gradio
sdk_version: 4.37.2
app_file: app.py
pinned: false
license: mit
---
# Twitter Sentiment Analysis
This project implements a sentiment analysis model to predict the sentiment (positive or negative) of tweets. An LSTM-based model has been trained on 1.6 million tweets.
## Project Structure
- __01. Data Preparation:__
* `Data Collection`: The dataset consisting 1.6 million tweets has been collected from [here](https://www.kaggle.com/datasets/kazanova/sentiment140).
* `Data Cleaning & Preprocessing`:
- Removed stopwords
- Applied Lemmatization
- Vectorized the lemmatized data utilizing "TextVectorization" from keras
- Saved the Vectorizer for utilizing later in the app
- __02. Model Training:__
* A Bidirectional LSTM model with an embedding layer has been trained on the preprocessed data.
- __03. App Deployment:__
* Developed a web-app with Gradio interface
* Deployed the [App](https://huggingface.co/spaces/mazed/twitter_sentiment_analysis) in HuggingFace Spaces
- `requirements.txt`: Contains the dependencies needed for the project:
- `pandas`
- `tensorflow==2.15.0`
- `nltk`
- `gradio`
Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference |