Citation-grounded RAG
Answers you can verify, line by line.
A retrieval-augmented question-answering engine where every claim is grounded in a specific source passage — with inline, checkable citations and an abstain path when the corpus doesn't support an answer. Built for high-stakes text, where a confident wrong answer is worse than no answer.
The demo corpus is the U.S. founding documents — the Constitution, the Bill of Rights, and the Federalist Papers (public domain) — so every answer is externally checkable.
- · Hybrid retrieval: BM25 + dense embeddings, fused with Reciprocal Rank Fusion
- · Native, verifiable citations (cited span + source, not made-up [1]s)
- · Streams the answer and abstains instead of guessing when evidence is missing
- · An eval harness scores retrieval (recall@k, MRR) and answer faithfulness
Runs offline on the bundled corpus with no API key. Add an ANTHROPIC_API_KEY (answers) and OPENAI_API_KEY (dense retrieval) for the full hybrid pipeline.