ChatGPT Tweet Analysis is a web application built with ReactJS and Flask that allows users to analyze the sentiment and topic of ChatGPT-related tweets.
- Analyze the sentiment of a ChatGPT-related tweet
- Determine the topic of a ChatGPT-related tweet
- User-friendly interface with real-time analysis results
- ReactJS: A JavaScript library for building user interfaces
- Flask: A micro web framework for building web applications
- BERTopic: A library for topic modeling using BERT embeddings
- Sentence Transformers: A library for state-of-the-art sentence embeddings
- Transformers: A library for natural language processing using transformer models
- Node.js (version 20.2.0)
- Python (version 3.9.13)
git clone https://github.com/bilbisli/ChatGPTweetTopicSentiment.git
- Create and activate a virtual environment for the Flask app:
cd ChatGPTweetTopicSentiment
py -3.9 -m venv venv
- For macOS and Linux:
source venv/bin/activate
- For Windows:
venv\Scripts\activate
- Install the dependencies for the Flask app:
pip install -r requirements.txt
- Start the Flask app:
python app.py
- In a separate terminal (opened at the root of the project), Install the dependencies for the React app:
cd frontend
npm install
- Start the React server:
npm start
- Access the application in your web browser: http://localhost:3000
The following environment variables can be set or configured in the .env
file:
TWEET_ANALYSIS_API_HOST
: The hostname or IP address of the Tweet Analysis API (default: localhost)TWEET_ANALYSIS_API_PORT
: The port number of the Tweet Analysis API (default: 5000)
- Enter a ChatGPT-related tweet in the provided input field.
- Click the "Analyze" button to analyze the sentiment and topic of the tweet.
- The sentiment (positive, negative, neutral) and topic of the tweet will be displayed below.
- Repeat the process for additional tweets.
ChatGPT_twitter_Demo.mp4
The data used for creating this project is available at: ChatGPT Twitter Dataset
Contributions are welcome! If you find any bugs or have suggestions for improvements, please open an issue or submit a pull request.
This project is licensed under the MIT License.