Thanks to visit codestin.com
Credit goes to Github.com

Skip to content

Find high-quality leads from Reddit creator communities with AI-powered sentiment analysis and lead scoring

Notifications You must be signed in to change notification settings

maslinedwin/reddit_feedback

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

70 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

Reddit Feedback AI

A sophisticated Reddit feedback analysis tool with AI-powered insights, featuring a modern dark glassmorphism UI with liquid design elements.

Reddit Feedback AI Python Next.js

🌟 Features

Core Functionality

  • Reddit Scraping: Automated data collection from subreddits with resumable scraping
  • RAG System: Advanced semantic search with persistent embeddings
  • AI Chat Interface: Real-time streaming responses powered by GPT-3.5
  • Smart Indexing: Incremental embedding updates for new data

UI/UX Enhancements

  • Dark Glassmorphism Design: Modern glass effects with backdrop blur
  • Liquid Animations: Smooth, organic animations throughout
  • Real-time Streaming: Live AI responses with typing indicators
  • Responsive Layout: Fully adaptive design for all screen sizes

πŸš€ Quick Start

Prerequisites

  • Python 3.8+
  • Node.js 18+
  • Reddit API credentials
  • OpenAI API key

Backend Setup

  1. Navigate to backend directory:
cd backend
  1. Install dependencies:
pip install -r requirements.txt
  1. Create .env file:
REDDIT_CLIENT_ID=your_reddit_client_id
REDDIT_CLIENT_SECRET=your_reddit_client_secret
REDDIT_USER_AGENT=your_app_name
  1. Start the backend:
uvicorn main:app --reload --port 8000

Frontend Setup

  1. Navigate to frontend directory:
cd frontend
  1. Install dependencies:
npm install
  1. Create .env.local file:
OPENAI_API_KEY=your_openai_api_key
NEXT_PUBLIC_BACKEND_URL=http://127.0.0.1:8000
  1. Start the frontend:
npm run dev

πŸ“Š Usage

Scraping Reddit Data

curl -X POST http://localhost:8000/bulk_scrape/patreon

Querying the System

Simply type your question in the chat interface:

  • "What are the common complaints about Patreon?"
  • "What features do users want most?"
  • "How do creators feel about monetization?"

πŸ—οΈ Architecture

Backend Components

  • FastAPI: High-performance API framework
  • PRAW: Reddit API wrapper for data collection
  • SentenceTransformers: State-of-the-art embeddings
  • RAG Manager: Custom embedding persistence system

Frontend Stack

  • Next.js 15: React framework with App Router
  • Vercel AI SDK: Streaming AI responses
  • Tailwind CSS: Utility-first styling
  • React Markdown: Rich text rendering

🎨 Design System

Color Palette

  • Background: #0a0a0a (Deep black)
  • Glass: rgba(255, 255, 255, 0.05-0.1)
  • Accent: Blue to purple gradient
  • Text: High contrast whites and grays

Effects

  • Backdrop blur for glass panels
  • Smooth animations with cubic bezier
  • Glow effects on interactive elements
  • Liquid morphing animations

πŸ”§ API Endpoints

Backend API

  • POST /bulk_scrape/{subreddit} - Scrape subreddit data
  • POST /query - Query the RAG system
  • GET /rag/stats - Get indexing statistics
  • POST /rag/refresh - Manually refresh embeddings
  • GET /health - Health check

πŸ“ˆ Performance Optimizations

  • Embedding Persistence: Cached embeddings for instant queries
  • Incremental Updates: Only process new data
  • Streaming Responses: Real-time AI output
  • Optimized Animations: GPU-accelerated CSS transforms

πŸ› Troubleshooting

Common Issues

  1. Streaming not working: Ensure CORS is enabled and using fetch API
  2. No embeddings found: Run scraper first to collect data
  3. Slow responses: Check if embeddings are persisted properly

Debug Commands

# Check backend health
curl http://localhost:8000/health

# View RAG statistics
curl http://localhost:8000/rag/stats

# Refresh embeddings
curl -X POST http://localhost:8000/rag/refresh

🀝 Contributing

Contributions are welcome! Please feel free to submit a Pull Request.

πŸ“„ License

This project is licensed under the MIT License.


Built with ❀️ using modern web technologies and AI

About

Find high-quality leads from Reddit creator communities with AI-powered sentiment analysis and lead scoring

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published