Skip to content

Repository files navigation

DocuAI 🧠

An AI-powered multi-tenant document analysis platform. Upload .txt files and analyze them using Google Gemini AI across multiple analysis types — all scoped to your organization.

🔗 Live Demo: multi-tenant-document-analysis.vercel.app


✨ Features

  • Multi-tenant architecture — each user belongs to an organization; documents and analysis are fully isolated per org
  • Organization-gated access — users must create or join an organization before analyzing documents
  • AI-powered analysis via Google Gemini across 5 label types:
    • 📝 Summary — concise overview of the document
    • ❓ Q&A — question and answer extraction
    • 🏷️ Entities — named entity recognition (people, places, orgs)
    • 📤 Extract — key data and information extraction
    • 💬 Sentiment — tone and sentiment analysis
  • Authentication — sign up / sign in via Clerk
  • File upload — .txt file support with cloud storage via Vercel Blob

🛠 Tech Stack

Layer Technology
Framework Next.js (App Router)
Auth Clerk
Database Neon (PostgreSQL)
ORM Prisma
AI Google Gemini
Storage Vercel Blob
Styling Tailwind CSS + shadcn/ui
Deployment Vercel

⚙️ Getting Started

Prerequisites

Installation

git clone https://github.com/AbdelAli-none/multi-tenant-document-analysis.git
cd multi-tenant-document-analysis
npm install

Environment Variables

Create a .env.local file in the root directory:

# Database
DATABASE_URL=

# Clerk Auth
NEXT_PUBLIC_CLERK_PUBLISHABLE_KEY=
CLERK_SECRET_KEY=
NEXT_PUBLIC_CLERK_SIGN_IN_URL=/sign-in
NEXT_PUBLIC_CLERK_SIGN_UP_URL=/sign-up
NEXT_PUBLIC_CLERK_AFTER_SIGN_IN_URL=/dashboard
NEXT_PUBLIC_CLERK_AFTER_SIGN_UP_URL=/dashboard

# Google Gemini AI
GEMINI_API_KEY=

# Vercel Blob
BLOB_READ_WRITE_TOKEN=

Database Setup

npx prisma generate
npx prisma db push

Run Locally

npm run dev

Open http://localhost:3000

📄 License

MIT

About

Multi-tenant app

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages