Skip to content

Aryan0412/PDFGPTee

Repository files navigation

AI Q&A System

An AI-driven Q&A system with PDF support, built using Next.js 15, OpenAI, and Clerk, featuring real-time chat, vector search, and modern UI components.


Architecture

IMG_0012

IMG_0013

🚀 Tech Stack

🖥️ Frontend

  • Framework: Next.js 15 (App Router)
  • Language: TypeScript
  • UI Components:
    • Radix UI
    • ShadCN UI
    • Tailwind CSS
  • State Management: React Query
  • Authentication: Clerk
  • External Tools:
    • Vercel AI SDK (for streaming chat generation)

🗄️ Backend

  • Database:
    • NeonDB (for data storage)
    • Pinecone (for vector storage)
  • ORM: Drizzle ORM
  • External Services:
    • OpenAI SDK (for AI responses)
    • AWS S3 (for file storage)
    • Stripe (for payment processing)

📁 Project Structure

PDFGPTee/
├── public/                 
├── src/                     
  ├── app/                     # Main App Router folder
  │   ├── api/                 # Route handlers (server functions)
  │   ├── chat/                # Chat UI page (protected)
  │   ├── sign-in/             # Clerk sign-in page
  │   ├── sign-up/             # Clerk sign-up page
  │   ├── favicon.ico          # App icon
  │   ├── globals.css          # Global styles (Tailwind)
  │   ├── layout.tsx           # Root layout shared by all routes
  │   └── page.tsx             # Landing or home page
  ├── components/              # Reusable React components
  │   ├── ui/                  # UI elements from shadcn or Radix
  │   ├── FileUpload.tsx       # PDF upload component
  │   └── Providers.tsx        # React providers (e.g., Clerk, QueryClient)
  ├── lib/                     # Helpers and configs
  │   └── middleware.ts        # Middleware logic (e.g., auth checks)
├── .env                     # Environment variables
├── components.json          # Autogenerated by shadcn
├── drizzle.config.ts        # Drizzle ORM config
├── eslint.config.mjs        # Linting configuration
├── next-env.d.ts            # TypeScript Next.js env types
├── next.config.ts           # Next.js config file
├── package-lock.json        # Dependency lock file
├── package.json             # Project metadata and scripts
├── postcss.config.mjs       # PostCSS config (used by Tailwind)