RAG Without the Lag: Enabling "What-If" Analysis for Retrieval-Augmented Generation Pipelines

Best Paper
Human-LLM CollaborationPrototyping & User TestingSoftware Engineers & DevelopersAI/ML Researchers & EngineersHCI Researchers

Paper Title

RAG Without the Lag: Enabling 'What-If' Analysis for Retrieval-Augmented Generation Pipelines

Publication Info

  • Topic area: Development and debugging of Retrieval-Augmented Generation (RAG) pipelines for AI systems.
  • Keywords: RAG pipelines, debugging tools, retrieval-augmented generation, large language models, interactive interfaces, query rewriting, retrieval optimization, chunking, iterative development, evaluation frameworks.

Background and Problem

  • Problem / challenge: RAG pipelines are difficult to debug due to the intertwined nature of retrieval and generation components, which complicates error isolation and optimization. Iteration cycles are slow, as changes to parameters often require re-indexing documents, taking hours.
  • Significance: RAG pipelines are widely adopted for AI assistants that integrate external knowledge, but their development remains challenging, limiting their reliability and scalability in production environments.
  • Motivation and related work: Prior work has explored debugging interfaces for software, ML, and LLM systems, as well as visualization tools for RAG pipelines. However, existing tools fail to support rapid experimentation across retrieval and generation components or systematic evaluation during development.

Solution

  • Proposed approach: raggy, a developer tool combining a Python library of composable RAG primitives with an interactive debugging interface for real-time experimentation and visualization.
  • Novelty:
    1. A low-latency “what-if” analysis framework enabling dynamic parameter adjustments without re-indexing.
    2. Specialized debugging visualizations tailored to retrieval and LLM components, highlighting failure modes.
    3. Persistent test suite functionality for building representative queries and evaluating pipeline evolution.
  • Procedure and key techniques:
    • Developers write RAG pipelines using raggy primitives in Python.
    • When executed, the system launches an interactive interface with cells for Query, Retriever, LLM, and Answer components.
    • Pre-computed vector indexes and program state checkpoints enable rapid parameter adjustments and pipeline re-execution.
    • Users can inspect retrieved chunks, edit prompts, modify outputs, and save answers for systematic evaluation.

Results

  • Concrete findings:
    • On average, 71.3% of retrieval parameter changes made by participants would have required time-consuming re-indexing in traditional workflows.
    • Participants valued raggy’s ability to reduce iteration time, with retrieval adjustments taking seconds instead of hours.
  • Advantage over baselines: raggy eliminates latency from re-indexing and provides interactive debugging capabilities not available in existing RAG development tools.
  • Experiments / evaluation:
    • A user study with 12 experienced RAG developers tasked with improving a hospital documentation question-answering pipeline.
    • Participants iteratively debugged retrieval and generation components, explored diverse pipeline configurations, and saved answers for evaluation.
    • Observations revealed consistent debugging patterns, including prioritizing retrieval validation and iterative sensemaking loops.
  • Limitations and future work:
    • Limited study duration (1 hour) does not capture full complexity of production RAG development.
    • Need for better provenance tracking, systematic evaluation across multiple traces, and support for larger document corpora.
    • Future tools could integrate notebook-inspired features, support preprocessing tasks, and accommodate custom retrieval methods.

Summary

raggy addresses key challenges in RAG pipeline development by enabling rapid experimentation, interactive debugging, and systematic evaluation. Its Python-based primitives and browser interface allow developers to dynamically adjust parameters, visualize retrieval and generation outputs, and save answers for longitudinal testing. A user study demonstrated its effectiveness in reducing iteration time and supporting diverse debugging strategies. Future work could expand raggy’s capabilities to better support large-scale production environments and more systematic evaluation workflows.

Quick Actions

Share

Share this page

ios_share

https://hci.top/en/papers/chi/221901/2026

AdRecommended

Learn AI Coding at CodeNow

open_in_newOpen DOI Link
DOI: https://doi.org/10.1145/3772318.3790874
At a Glance

Paper Snapshot

fact_check
dataset
Source
CHI
calendar_month
Year
2026
emoji_events
Award
Best Paper
group
Authors
4 authors
sell
Subtopics
Human-LLM Collaboration, Prototyping & User Testing
work
Professions
Software Engineers & Developers, AI/ML Researchers & Engineers, HCI Researchers
article
Content Status
Full text indexed
hub
Related Papers
10 related papers