Docs/KB RAG chatbot with citations
The chat widget on every page of devdudejeremy.com — and the build itself, documented.
The pitch
A prospect lands on devdudejeremy.com, asks the assistant a question, and the assistant answers with citations to actual case studies. The build is the proof.
Stack
- Next.js 16 (App Router), replies streamed as they are written
- Supabase Postgres + pgvector (vector index + full-text search)
- Anthropic Claude Sonnet 5.5 (prompt-cached) with native citations answers questions, qualifies leads and books calls; Claude Haiku 5.5 writes the follow-up question chips
- Voyage embeddings and reranking
- Hybrid retrieval (vector + full-text) merged via Reciprocal Rank Fusion, then reranked
- Upstash Redis for rate limits + query cache
How groundedness is enforced
The retrieved pages reach the model as search results, and every claim in an answer carries a citation back to one of them. The eval harness has Claude judge every answer against the passages it cites; faithfulness, correct refusals, retrieval recall and response time each have a floor the build must meet. See live metrics.
Measured, not promised
- Answers that stuck to the pages
- 100.0%
- Off-topic questions declined
- 100.0%
- First word on screen, 95th percentile
- 2.7 s
- Cost per 1,000 questions
- $11.68
- Sources cited per answer, on the measured set
- 2.7
- Voice replies
- on
video avatar: available, ≈ $0.35/min
measured Nov 17, 2026 on 21 questions
Try it
Embed on your own site
<script src="https://docs-rag.devdudejeremy.com/embed.js" data-corpus="portfolio" defer></script>