The WhatsApp Chat Analyzer is a tool built with Streamlit to analyze WhatsApp chat data. The application allows users to upload a WhatsApp chat file and provides various insights, including message statistics, user activity, and sentiment analysis. It supports both English and Hinglish (a mix of Hindi and English) for sentiment analysis.
- User Activity Analysis: Identify the most active users in a chat group or analyze individual user activity.
- Message Statistics: Get counts of total messages, words, media, deleted messages, and shared links.
- Sentiment Analysis: Analyze the sentiment of chat messages, distinguishing between positive, negative, and neutral messages. Smiling and angry emojis are used to represent overall sentiment.
- Word Cloud: Generate a word cloud to visualize the most common words used in the chat.
- Customizable Visuals: Bar charts, pie charts, and word clouds with vibrant colors and detailed labels.
- Python 3.7 or higher
pippackage manager
git clone https://github.com/SahiLmb/whatsapp-chat-analyzer.git
cd whatsapp-chat-analyzerpip install -r requirements.txt-
Prepare Your WhatsApp Chat File: Export your WhatsApp chat history as a
.txtfile. -
Run the Streamlit App:
streamlit run app.py
-
Upload Your Chat File: Use the sidebar in the Streamlit app to upload your WhatsApp chat file.
-
Analyze the Chat: Select the user or group for analysis and click the "Analyze the chat" button. The app will display various statistics and visualizations.
- The app includes a custom sentiment analysis tool that can handle Hinglish (Hindi + English).
- Sentiments are classified as positive, negative, or neutral.
- A pie chart is used to visualize the distribution of sentiments, with a smiling emoji (😊) for positive sentiments and an angry emoji (😡) for negative sentiments.
You can customize the following aspects of the project:
- Hinglish to English Sentiment Mapping: Modify the
hinglish_to_englishdictionary inhelper.pyto include more translations. - Stopwords and Exclusions: Add or remove words that should be excluded from the word cloud and common words list.
- Multi-language Support: Extend sentiment analysis to other languages.
- Advanced Analytics: Incorporate machine learning models for more sophisticated analysis.
- Export Options: Allow users to export the analyzed data and visualizations.
Contributions are welcome! Please fork the repository and create a pull request with your changes.
This project is licensed under the MIT License - see the LICENSE file for details.
For any inquiries, please contact work.bodke@gmail.com.
This README provides a comprehensive overview of the project, guiding users on how to install, use, and contribute to your WhatsApp Chat Analyzer tool. You can adapt it as needed, especially with your personal contact details and repository links.