Your Advanced Command-Line Toolkit for Deep Reddit User Analysis.
Ever wondered what patterns lie hidden in public Reddit activity? RedStalk is a powerful, command-line tool designed for in-depth analysis of Reddit users based on their publicly available posts and comments.
It intelligently scrapes data, allows granular filtering, performs comprehensive statistical analysis, and leverages Google's Gemini AI for qualitative insights. Dive deep into user interests, communication styles, sentiment trends, and more. Perfect for researchers, data analysts, or anyone curious about online community dynamics.
config.json
or command-line flags.Get RedStalk running on your system in a few steps:
1. Prerequisites:
2. Clone the Repository:
git clone https://github.com/sarthak-sidhant/redstalk.git
cd redstalk
3. Set Up Virtual Environment (Recommended):
# Create environment
python -m venv venv
# Activate it
# Windows:
venv\Scripts\activate
# macOS/Linux:
source venv/bin/activate
4. Create `requirements.txt` and Install Dependencies:
Create a file named requirements.txt
in the redstalk
directory and paste the following content inside it:
# Core stuff for scraping and files
requests>=2.25.0
rich>=10.0.0
# Optional: Install only if using these features
# Needed for AI features (--run-analysis, --summarize-stats, --generate-prompt)
google-generativeai>=0.3.0
# Needed for Statistical Analysis (--generate-stats, --compare-user)
vaderSentiment>=3.3.0
pandas>=1.2.0
# nltk is also used for stats (install separately if needed via pip install nltk)
# Optional: Progress bars for AI tokenization
tqdm>=4.60.0
Now, install the dependencies:
pip install -r requirements.txt
(You might also need NLTK data for some stats: run python, then `import nltk; nltk.download('punkt'); nltk.download('vader_lexicon')`)
5. Configuration:
Edit the config.json
file (create one if it doesn't exist). Crucially, set a unique user_agent
including your Reddit username as required by Reddit API terms. Set your Google Gemini API key securely (environment variable GOOGLE_API_KEY
is recommended).
You're ready to start analyzing! Check the full README on GitHub for detailed usage instructions and examples.