12 configs · 7 metrics · failure taxonomy

RAGBench

A laboratory for evaluating RAG strategies

Compare 3 chunking strategies × 4 retrieval modes across 7 evaluation metrics. Inspect retrieved chunks, measure latency, cost, and identify failure patterns with a built-in taxonomy.

Chunking strategies
3
Retrieval modes
4
Eval metrics
7
Configs tested
12

What RAGBench measures

Everything you need to evaluate a RAG pipeline

RAGBench runs a controlled experiment across all config combinations, collecting metrics that matter for production RAG: relevance, faithfulness, citation accuracy, and cost.

3 Chunking Strategies

Recursive character splitting, semantic chunking via embedding similarity, and parent-child hierarchical chunking. Each strategy produces a different chunk topology for retrieval.

4 Retrieval Modes

Full-text search (BM25/tsvector), dense vector retrieval (Voyage embeddings + pgvector), hybrid RRF fusion, and hybrid with Voyage rerank-2.5-lite re-scoring.

7 Evaluation Metrics

Context Precision, Context Recall, Answer Faithfulness, Answer Relevance, Citation Accuracy, Abstention Rate, and End-to-end Latency. All tracked per config.

Failure Taxonomy

Every query result is classified with failure tags: retrieval miss, hallucination, over-abstention, citation gap, and more. Enables targeted debugging of RAG pipelines.

The pipeline

How RAGBench works

Each query runs through a reproducible pipeline: documents are ingested, chunked with a chosen strategy, embedded, retrieved with a chosen mode, then generated and evaluated.

  1. 01

    Ingest

    Source documents are loaded from the data directory and parsed into a normalized format ready for chunking.

  2. 02

    Chunk

    Each document is split using one of three strategies: recursive (fixed-size with overlap), semantic (embedding-based boundaries), or parent-child (hierarchical).

  3. 03

    Embed

    Chunks are embedded with Voyage AI's voyage-3-lite model and stored in PostgreSQL with pgvector for similarity search.

  4. 04

    Retrieve

    At query time, the selected retrieval mode (FTS, Dense, Hybrid, or Hybrid+Rerank) fetches the top-k most relevant chunks.

  5. 05

    Generate

    Claude claude-sonnet-4-6 receives the retrieved chunks as context and generates an answer with inline citations referencing specific chunks.

  6. 06

    Evaluate

    The answer is scored across 7 metrics using an LLM judge and exact-match rules. Results are stored and compared across all 12 configs.

Start evaluating your RAG pipeline

Run the chat interface to interactively test any chunker + retrieval combination, or view aggregated metrics in the eval dashboard.