Skip to content

Integrated LangChain for advanced PDF text extraction, EdgeStore for cloud file management, and Clerk authentication for secure user access with role-based permissions. Architected end-to-end data pipeline including PDF processing, AI-driven summarization with custom prompts, and PostgreSQL database persistence using Neon serverless infrastructure.

Notifications You must be signed in to change notification settings

sdinesh-webdev/AI-PDF-Summarizer

Repository files navigation

🤖 AI PDF Summarizer - Intelligent Document Analysis Platform

Next.js React TypeScript AI

H-1

Transform complex PDF documents into clear, actionable insights in seconds with advanced AI-powered summarization.

🎯 Overview

An enterprise-grade SaaS platform that leverages Google Gemini AI and LangChain to automatically extract, analyze, and summarize PDF documents. Built with modern web technologies and designed for scalability, security, and exceptional user experience.

✨ Key Features

🚀 Core Functionality

  • AI-Powered Summarization: Google Gemini 2.0 Flash for intelligent content analysis
  • Advanced PDF Processing: LangChain integration for accurate text extraction
  • Real-time Progress Tracking: Live upload and processing status updates
  • Drag & Drop Interface: Intuitive file upload with validation
  • Cloud Storage: Secure file management with EdgeStore
  • Structured Summaries: Professional formatting with main topics, key points, and takeaways

🔐 Security & Authentication

  • Clerk authentication with social login support
  • Role-based access control
  • Secure file storage with encrypted URLs
  • User session management

💾 Data Management

  • PostgreSQL database with Neon serverless
  • Efficient document storage and retrieval
  • User-specific summary history
  • Scalable data architecture

🎨 User Experience

  • Brutalist UI design with Tailwind CSS
  • Responsive across all devices
  • Toast notifications for user feedback
  • Animated gradient backgrounds
  • Professional typography with custom fonts

🛠️ Tech Stack

Frontend

  • Framework: Next.js 15.2 (App Router)
  • UI Library: React 19.0
  • Language: TypeScript 5.0
  • Styling: Tailwind CSS 4.0
  • Components: Radix UI, Lucide Icons
  • Animations: Motion, TW Animate CSS

Backend & AI

  • AI Model: Google Gemini AI 2.0 Flash
  • PDF Processing: LangChain Community
  • Authentication: Clerk
  • File Storage: EdgeStore
  • Database: PostgreSQL (Neon Serverless)

Development Tools

  • Build Tool: Turbopack
  • Linting: ESLint
  • Type Checking: TypeScript
  • Package Manager: npm/yarn/pnpm

📦 Installation

Prerequisites

  • Node.js 20.x or higher
  • npm/yarn/pnpm package manager
  • PostgreSQL database (Neon account)
  • Clerk account
  • EdgeStore account
  • Google Gemini API key

Environment Variables

Create a .env.local file with:

# Clerk Authentication
NEXT_PUBLIC_CLERK_PUBLISHABLE_KEY=your_clerk_key
CLERK_SECRET_KEY=your_clerk_secret

# Database
DATABASE_URL=your_neon_database_url

# AI
GEMINI_API_KEY=your_gemini_api_key

# EdgeStore
EDGE_STORE_ACCESS_KEY=your_edgestore_key
EDGE_STORE_SECRET_KEY=your_edgestore_secret

# Clone repository
git clone https://github.com/yourusername/ai-pdf-summarizer.git
cd ai-pdf-summarizer

# Install dependencies
npm install

# Run development server
npm run dev

# Build for production
npm run build

# Start production server
npm start

├── app/
│   ├── (logged-in)/        # Protected routes
│   ├── api/                # API endpoints
│   ├── sign-in/            # Authentication pages
│   └── sign-up/
├── components/
│   ├── common/             # Shared components
│   ├── ui/                 # UI primitives
│   └── upload/             # Upload-related components
├── lib/
│   ├── db.ts              # Database connection
│   ├── edgestore.ts       # File storage
│   ├── geminiai.ts        # AI integration
│   └── langchain.ts       # PDF processing
└── actions/               # Server actions

About

Integrated LangChain for advanced PDF text extraction, EdgeStore for cloud file management, and Clerk authentication for secure user access with role-based permissions. Architected end-to-end data pipeline including PDF processing, AI-driven summarization with custom prompts, and PostgreSQL database persistence using Neon serverless infrastructure.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published