Skip to main content
QUICK REVIEW

[Paper Review] AutoRAG: Automated Framework for optimization of Retrieval Augmented Generation Pipeline

Dongkyu Kim, Byoungwook Kim|arXiv (Cornell University)|Oct 28, 2024
Power Systems and TechnologiesEngineering3 citations
TL;DR

AutoRAG is an automated framework that optimizes Retrieval-Augmented Generation (RAG) pipelines by systematically searching for the best combination of RAG modules—such as query expansion, retrieval, reranking, and passage augmentation—using a greedy, metric-driven approach. It achieves state-of-the-art performance on the ARAGOG dataset, with hybrid retrieval (RRF) and flag-embedding reranking outperforming other configurations.

ABSTRACT

Using LLMs (Large Language Models) in conjunction with external documents has made RAG (Retrieval-Augmented Generation) an essential technology. Numerous techniques and modules for RAG are being researched, but their performance can vary across different datasets. Finding RAG modules that perform well on specific datasets is challenging. In this paper, we propose the AutoRAG framework, which automatically identifies suitable RAG modules for a given dataset. AutoRAG explores and approximates the optimal combination of RAG modules for the dataset. Additionally, we share the results of optimizing a dataset using AutoRAG. All experimental results and data are publicly available and can be accessed through our GitHub repository https://github.com/Marker-Inc-Korea/AutoRAG_ARAGOG_Paper .

Motivation & Objective

  • To address the challenge of manually selecting optimal RAG modules for specific datasets, which often leads to suboptimal performance.
  • To automate the exploration and selection of RAG components—query expansion, retrieval, reranking, and passage augmentation—across multiple pipeline stages.
  • To improve RAG system performance and scalability by emulating AutoML practices in a retrieval-augmented generation context.
  • To enable reproducible, data-driven RAG pipeline optimization using retrieval metrics like RAGAS.
  • To release a publicly available framework that supports future evaluation and optimization of diverse RAG techniques across multiple datasets.

Proposed method

  • AutoRAG employs a greedy search strategy to evaluate and select the optimal combination of RAG modules across five pipeline nodes: query expansion, retrieval, passage augmentation, reranking, and prompt creation.
  • It uses RAGAS as the primary evaluation metric to measure context precision and answer relevance, enabling automated comparison of pipeline configurations.
  • For query expansion, it evaluates two methods: query decomposition (using LLMs to split multi-hop questions) and HyDE (hypothetical document embedding generation).
  • For retrieval, it compares BM25 (sparse), VectorDB (dense), and hybrid methods (e.g., RRF and CC fusion) using different normalization strategies.
  • It evaluates multiple reranking techniques, including ColBERT, UPR, Sentence Transformers, and a flag-embedding-based reranker, to identify the most effective ranking strategy.
  • The framework systematically tests combinations of modules and selects the configuration with the highest RAGAS score, aiming for near-optimal performance without exhaustive search.
Figure 1: Structural diagram showing the overall structure of AutoRAG.
Figure 1: Structural diagram showing the overall structure of AutoRAG.

Experimental results

Research questions

  • RQ1Which combination of RAG modules yields the highest retrieval and generation performance on a given dataset?
  • RQ2How do different query expansion techniques—query decomposition and HyDE—impact retrieval accuracy in multi-hop question-answering scenarios?
  • RQ3What is the relative performance of sparse (BM25), dense (VectorDB), and hybrid retrieval methods in contextually grounded question answering?
  • RQ4Does reranking consistently improve RAG pipeline performance, or can it degrade results depending on the dataset and model choice?
  • RQ5How does the choice of passage augmentation strategy (e.g., prev-next) affect retrieval quality and downstream answer generation?

Key findings

  • Hybrid retrieval using RRF fusion achieved the highest performance among retrieval methods, with a RAGAS context precision@10 of 0.712853 on the ARAGOG dataset.
  • The flag-embedding-based reranker outperformed all other reranking methods, achieving the highest RAGAS score, while the Sentence Transformer reranker performed the worst due to its smaller model size and limited domain understanding.
  • The use of the prev-next passage augmenter slightly improved retrieval performance, suggesting that contextual neighboring passages enhance retrieval relevance.
  • Reranking with UPR and ColBERT degraded performance compared to the baseline, indicating that not all reranking methods improve results, especially on complex, multi-passage datasets.
  • The long context reorder strategy slightly reduced performance when used, suggesting it may not be beneficial for all dataset characteristics.
  • AutoRAG successfully identified a high-performing RAG configuration through automated, metric-driven search, demonstrating the feasibility of systematic pipeline optimization.
Figure 2: All RAG techniques used in this paper
Figure 2: All RAG techniques used in this paper

Read this paper

Open the full text in the Nubint reader and ask about any passage as you read.

Read this paper on Nubint

This review was generated by AI from the original paper. Please check the paper before citing it.