Inspiration

  • Sending identical PDFs to every recipient wastes storage and clutters devices.
  • Many people—especially seniors—prefer a concise summary over reading a full document.
  • A single, up-to-date copy in the cloud plus on-demand AI summaries meets both needs.

What it does

  • Lets each user upload up to 5 PDF files per day.
  • Stores one master copy in Supabase Storage and writes metadata to Postgres.
  • Runs an Edge Function that calls an LLM to create a short, plain-language summary.
  • Displays file status and the generated summary in a React dashboard.
  • UI text is localised in English, Arabic, French, and Spanish.

How we built it

Layer Stack
Frontend React + Vite, Tailwind CSS, Lucide-React icons, react-i18next
State / Context AuthProvider, ThemeProvider, SubscriptionProvider
Backend Supabase Postgres (tables: files, summaries, app_config)
Supabase Storage for the original PDFs
Edge Functions Node 20 scripts that invoke the OpenAI API for summarisation
Auth & Plans Supabase Auth plus RevenueCat for free / paid gating

Challenges we ran into

  • Storage trigger missed auth.uid(), so no metadata rows were created after uploads.
  • HTTP 406 on app_config—fixed by adding Accept: application/json to the fetch.
  • Infinite loading spinner from route-level Suspense; solved with an explicit auth guard.
  • “Empty offerings” in RevenueCat until products were activated and linked to the correct bundle.

Accomplishments that we're proud of

  • End-to-end PDF → AI summary flow running on Supabase’s free tier.
  • Subscription screens fully translated into four languages.
  • Secure password-reset flow implemented by parsing the Supabase hash correctly.

What we learned

  • Test storage triggers with real uploads; mocks can hide auth-context issues.
  • API errors like 406 often come down to a missing header.
  • Translation keys grow fast—define a clear naming scheme from day one.

What's next for SecureDocAI – AI-Powered Document Management System

  • Batch upload with email alerts when summaries are ready.
  • Team workspaces to share daily upload quotas.
  • Audit log export for compliance reviews.
  • Summary styles (executive vs. technical) selectable per document.

Built With

  • react
  • supabase
  • tailwind
  • vite
Share this project:

Updates

Submission history