8000 GitHub - zomdar/khang_repo · GitHub
[go: up one dir, main page]

Skip to content

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Latest commit

 

History

1 Commit

Folders and files

Repository files navigation

PrivAI - Privacy Protection Agent

A comprehensive privacy protection platform that automatically scans, monitors, and cleans up your digital footprint across social media and data brokers.

Features

  • Intelligent Privacy Scanning: NLP-powered detection of sensitive information
  • Automated Social Media Cleanup: Twitter, Facebook, Instagram, LinkedIn integration
  • Data Broker Opt-out: Automated removal requests
  • Privacy Score & Gamification: Track your privacy improvements
  • Real-time Monitoring: Scheduled privacy audits
  • Modern Web Interface: Cutting-edge landing page with glassmorphism design and chat-based interaction

Architecture

privai/
├── backend/           # Python backend with AI agent
├── frontend/          # React web application
├── desktop/           # Electron desktop app
├── shared/           # Shared types and utilities
└── infrastructure/   # Docker, deployment configs

Quick Start

Option 1: Docker (Recommended)

# Clone the repository
git clone <repository-url>
cd privai

# Copy environment file
cp .env.example .env

# Start all services
docker-compose up -d

# Open http://localhost:3000

Option 2: Local Development

# Clone the repository
git clone <repository-url>
cd privai

# Install all dependencies
npm run install:all

# Set up environment
cp .env.example .env
# Edit .env with your API keys

# Start PostgreSQL and Redis locally
# Then start development servers
npm run dev

# Open http://localhost:3000

Architecture Overview

The application is built with a modern microservices architecture:

  • Backend API: FastAPI with async support
  • Privacy Agent: AI-powered decision engine
  • Task Queue: Celery with Redis for background jobs
  • Database: PostgreSQL with SQLAlchemy ORM
  • Frontend: React with TypeScript and Tailwind CSS
  • Real-time Updates: WebSocket support for live monitoring

Key Features

🔍 Intelligent Scanning

  • NLP-powered sensitive data detection
  • Real-time privacy score calculation
  • Multi-platform social media analysis

🤖 Autonomous Agent

  • AI-driven decision making
  • Automated cleanup actions
  • Personalized recommendations

📊 Privacy Dashboard

  • Real-time privacy score tracking
  • Gamification with badges and achievements
  • Historical trend analysis

🔄 Automated Monitoring

  • Scheduled privacy audits
  • Alert system for privacy breaches
  • Continuous improvement suggestions

Tech Stack

  • Backend: Python, FastAPI, SQLAlchemy, Celery
  • Frontend: React 18, TypeScript, Tailwind CSS, Framer Motion, Glassmorphism Design
  • Desktop: Electron
  • Database: PostgreSQL
  • Cache/Queue: Redis
  • AI/ML: spaCy, transformers, OpenAI API
  • Infrastructure: Docker, Docker Compose

API Endpoints

Chat Interface

  • POST /api/v1/chat - Chat with privacy agent
  • POST /api/v1/analyze - Analyze text for privacy risks

Privacy Management

  • GET /api/v1/privacy-score/{user_id} - Get privacy score
  • POST /api/v1/start-monitoring/{user_id} - Start automated monitoring

Social Media Integration

  • POST /api/v1/social/connect - Connect social accounts
  • POST /api/v1/social/cleanup - Clean up social media
  • GET /api/v1/social/status - Get cleanup status

Environment Variables

Key environment variables (see .env.example):

  • DATABASE_URL - PostgreSQL connection string
  • REDIS_URL - Redis connection string
  • SECRET_KEY - JWT signing key
  • OPENAI_API_KEY - OpenAI API key for enhanced AI features
  • Social media API keys (Twitter, Facebook, LinkedIn)

Development

Running Tests

# Backend tests
cd backend && pytest

# Frontend tests  
cd frontend && npm test

# Or run all tests
npm run test

Code Quality

# Linting
npm run lint

# Type checking
cd frontend && npm run type-check
cd backend && mypy .

Deployment

Production Docker

# Build production images
docker-compose -f docker-compose.prod.yml build

# Deploy
docker-compose -f docker-compose.prod.yml up -d

Cloud Deployment

The application is cloud-ready with:

  • Health checks for all services
  • Horizontal scaling support
  • Environment-based configuration
  • Monitoring and logging hooks

Privacy & Security

  • Data Encryption: All sensitive data encrypted at rest
  • API Security: JWT authentication with refresh tokens
  • Privacy by Design: Minimal data collection
  • Open Source: Fully auditable codebase
  • Local First: Can run entirely offline

Contributing

  1. Fork the repository
  2. Create a feature branch: git checkout -b feature/amazing-feature
  3. Commit changes: git commit -m 'Add amazing feature'
  4. Push to branch: git push origin feature/amazing-feature
  5. Open a Pull Request

Roadmap

v1.1 - Enhanced AI

  • GPT-4 integration for smarter recommendations
  • Image analysis for visual privacy risks
  • Voice analysis for audio content

v1.2 - Advanced Integrations

  • Browser extension
  • Mobile app (React Native)
  • Slack/Discord bots

v1.3 - Enterprise Features

  • Team/organization accounts
  • Compliance reporting (GDPR, CCPA)
  • Advanced analytics dashboard

License

MIT License - see LICENSE file for details.

Support

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages

0