Yapbot
A full-stack AI document chat app with vector retrieval and streaming, citation-style answers.
- Status
- Active
- Date
- October 2023
- Category
- Applications
Summary
A full-stack AI document chat application that lets authenticated users upload PDFs, retrieve context with vector search, and receive streaming, citation-style answers in real time.
Description
Yapbot is a web application for conversational Q&A over user-uploaded PDF documents. It solves the problem of manually searching long files by turning documents into semantic chunks and retrieving the most relevant passages per question.
Architecture
- PDF ingestion
- Vector retrieval
- Streaming AI chat
- Document management
- Subscription billing
Technology
- TypeScript
- Next.js
- Drizzle ORM
- Clerk
- Groq SDK
- PostgreSQL
- AWS S3
- Stripe
Features
- Authenticated multi-PDF chat workspace with Clerk-based user sessions, per-user chat ownership checks, and persistent chat history retrieval.
- PDF ingestion pipeline with S3 upload/download, server-side text extraction via pdf-parse, semantic chunking, and document-level storage for reuse.
- Vector retrieval layer using Hugging Face embeddings + PostgreSQL vector columns, with top-K similarity search to fetch relevant chunks per query.
- Streaming AI chat API powered by Groq, combining prior conversation context and retrieved document passages to generate grounded responses in real time.
- Document management experience with chat-scoped file attachment, sidebar chat navigation, and cascade-safe deletion of chats, documents, and messages.
- Subscription and billing foundation with Stripe Checkout, Billing Portal routing, webhook-driven subscription state sync, and Pro-plan period tracking.
- Abuse and reliability controls including Upstash Redis sliding-window rate limiting, request payload validation, and API-level unauthorized access handling.
Links
Images
Machine-readable: /projects.json · /llms.txt · /llms-full.txt