RAG Reliability Hub

Reliability for retrieval & grounding: recall, precision, citations

This hub focuses on reliability of retrieval and grounding: recall/precision, chunking, hybrid retrieval, reranking, source attribution, and eval for RAG. For teams using RAG who can't trust it yet.

Common "can't trust RAG" symptoms

Retrieval miss: key documents never surface for the query
Poor grounding: answers not supported by retrieved context
Wrong or missing citations: source attribution fails
RAG returns irrelevant documents but answer still wrong
Embedding drift: quality degrades over time without notice
Retrieval failure modes

Low recall / low precision (and how to fix them)

When RAG retrieval fails, the answer is wrong downstream. Diagnose the dominant failure mode first.

1

Low recall

Relevant docs exist but never surface. Query-doc mismatch, embedding gap, or corpus coverage holes.

Fix: Improve query expansion, hybrid search (BM25 + vector), chunking strategy, or embedding model.

2

Low precision

Top-k is noisy; irrelevant chunks crowd out good ones. Model gets confused by weak context.

Fix: Reranking, stricter retrieval filters, better chunk boundaries, or smaller top-k with higher quality.

3

Wrong doc rank

Right doc retrieved but ranked too low. Reranker or scoring function mis-calibrated.

Fix: Tune reranker, adjust score fusion (RRF, weighted), or add relevance feedback.

4

Stale / missing corpus

Knowledge base outdated or missing key sources. New docs not indexed; deletions not reflected.

Fix: Freshness pipeline, incremental indexing, coverage audits, and change detection.

5

Query drift

User query rewritten or expanded in a way that loses intent. Query understanding fails.

Fix: Query rewrite rules, intent-aware retrieval, or A/B test retrieval with/without expansion.

6

Embedding drift

Embedding model or corpus changes; semantic space shifts. Old evals no longer match production.

Fix: Monitor embedding drift, periodic re-eval, and versioned embedding pipelines.

Chunking + indexing patterns

How you chunk and index shapes retrieval quality

Chunk size, overlap, and boundaries affect retrieval precision and recall. Choose the right pattern for your corpus.

1

Fixed-size chunks

Simple token-based splitting. Fast but can break semantic units. Overlap helps.

Tradeoff: Easy to implement; may split mid-sentence or mid-concept.
2

Semantic / sentence boundaries

Split on sentences or paragraphs. Better coherence; variable chunk sizes.

Tradeoff: More context-aware; requires careful overlap for continuity.
3

Document-aware chunking

Respect document structure (headers, sections). Preserves hierarchy.

Tradeoff: Best for structured docs; more complex indexing.
4

Parent-child / hierarchical

Small chunks for retrieval; parent chunks for context. Best of both.

Tradeoff: Higher retrieval precision; more storage and retrieval logic.
Hybrid retrieval + reranking

Trade-offs: recall vs precision vs latency

BM25 + vector fusion improves recall. Reranking improves precision. Best reranker for RAG latency tradeoff: smaller top-k → faster; larger top-k → more recall.

BM25 + vector fusion

Hybrid search combines lexical (BM25) and semantic (vector). RRF or weighted fusion.

Tradeoff: Better recall on diverse queries; tuning fusion weights matters.

Reranking models

Cross-encoder or LLM reranker for top-k. Higher precision but adds latency.

Tradeoff: Best reranker for RAG latency tradeoff: smaller top-k → faster rerank; larger top-k → more recall.

Two-stage retrieval

Stage 1: broad recall (e.g. vector top-50). Stage 2: rerank to top-5.

Tradeoff: Balances latency and quality; stage 2 is the bottleneck.
Grounding + citations

Source attribution and context grounding

Citations for RAG must be accurate and verifiable. Reduce RAG hallucinations by enforcing grounding and attribution.

Source attribution

Map each claim to specific retrieved chunks. Citation-to-claim verification.

Groundedness checks

Detect when answers go beyond context. Ungrounded rate as a core metric.

Citation format

Structured output: [1], [2] or inline links. Parsing and validation downstream.

Refusal when uncertain

Model should abstain when context is insufficient. Reduces confident wrong answers.

RAG eval datasets

Golden set from logs (and how to build it)

RAG evaluation requires a representative test set. Build it from production logs, failures, and known-good examples.

What to include in your RAG eval dataset

  • 1Golden set from production logs (sampled failures + successes)
  • 2Synthetic queries from FAQ, support tickets, or user sessions
  • 3Human-labeled relevance (query → doc pairs) for retrieval eval
  • 4End-to-end task success (can the model answer correctly with this context?)
  • 5Regression suite: known-good and known-bad examples
Drift detection + maintenance

RAG quality degrades over time — catch it early

Embedding drift, corpus drift, and query distribution drift. Monitor and maintain with a cadence.

Embedding drift

Embedding model or corpus changes; similarity distribution shifts. Monitor embedding consistency over time.

Corpus drift

New docs added, old removed. Coverage and freshness need periodic audits.

Query distribution drift

User queries change over time. Eval set should reflect production traffic.

Maintenance cadence

Re-eval weekly or monthly; re-index on schema or model changes; version embeddings.

Maintenance cadence

Re-eval weekly or monthly; re-index on schema or model changes; version embeddings. Embedding drift is silent until you measure it.

Guides

Practical guides

Stop guessing. Use these diagnostics to classify retrieval failures, choose a chunking strategy, and fix the right thing.

Need a RAG audit or retrieval improvement?

If your RAG retrieval is missing key docs, grounding is weak, or citations are wrong, we can diagnose and fix retrieval quality, chunking, and evaluation.