Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/erfaniaa/trump-vs-harris-on-reddit
Analyze Reddit comments using NLP to predict the potential winner of the US 2024 election
https://github.com/erfaniaa/trump-vs-harris-on-reddit
natural-language-processing nlp politics reddit
Last synced: about 2 months ago
JSON representation
Analyze Reddit comments using NLP to predict the potential winner of the US 2024 election
- Host: GitHub
- URL: https://github.com/erfaniaa/trump-vs-harris-on-reddit
- Owner: Erfaniaa
- License: gpl-3.0
- Created: 2024-08-06T14:20:37.000Z (5 months ago)
- Default Branch: main
- Last Pushed: 2024-08-18T16:05:18.000Z (4 months ago)
- Last Synced: 2024-10-13T20:41:43.617Z (2 months ago)
- Topics: natural-language-processing, nlp, politics, reddit
- Language: Python
- Homepage:
- Size: 25.4 KB
- Stars: 15
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Trump vs. Harris Based on Reddit Comments
Analyze Reddit comments using NLP to predict the potential winner of the US 2024 election## Description
This GitHub repository contains a project that leverages Python to retrieve and analyze political comments from Reddit. The project is structured into two primary components: data retrieval and sentiment analysis. Using the PRAW library, the project efficiently pulls comments from political discussions on Reddit. These comments are then processed through NLP algorithms—specifically vaderSentiment and TextBlob—to predict whether the commenters are likely to support Donald Trump or Kamala Harris. Currently, the NLP analysis component requires further development and refinement. Contributions aimed at enhancing the NLP techniques or improving the overall accuracy of sentiment predictions are highly encouraged and appreciated.
## Usage
1. Clone the repository.
2. Run `pip3 install -r requirements.txt`.
3. Get your credentials from [Reddit](https://www.reddit.com/prefs/apps) and add them to `credentials.py`.
4. Edit `config.py`.
5. Run `python3 main.py`.