arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2406.19251cs.CLcs.AI
收藏

AutoRAG-HP:面向检索增强生成的自动在线超参数调优

AutoRAG-HP: Automatic Online Hyper-Parameter Tuning for Retrieval-Augmented Generation

Institute of Automation, Chinese Academy of Sciences(中国科学院自动化研究所);School of Artificial Intelligence, University of Chinese Academy of Sciences(中国科学院大学人工智能学院);Microsoft(微软)

Jia Fu, Xiaoting Qin, Fangkai Yang, Lu Wang, Jue Zhang, Qingwei Lin, Yubo Chen, Dongmei Zhang, Saravan Rajmohan, Qi Zhang

AI总结:

针对检索增强生成系统的超参数优化与在线适应挑战,提出 AutoRAG-HP 框架,将其建模为在线多臂老虎机问题并引入两级分层多臂老虎机方法,在大幅减少 LLM API 调用次数的同时实现高效调优。

摘要:

大型语言模型的最新进展改变了机器学习/人工智能(ML/AI)的开发方式,有必要重新评估自动机器学习(AutoML)原则在检索增强生成(RAG)系统中的适用性。为了应对 RAG 中超参数优化和在线适应的挑战,我们提出了 AutoRAG-HP 框架,该框架将超参数调优建模为在线多臂老虎机(MAB)问题,并引入了一种新颖的两级分层多臂老虎机(Hier-MAB)方法,以高效探索大型搜索空间。我们使用 ALCE-ASQA 和 Natural Questions 数据集,对 top-k 检索文档、提示压缩比和嵌入方法等超参数进行了广泛实验。我们对这三种超参数进行联合优化的评估表明,在搜索空间具有显著梯度的情况下,基于 MAB 的在线学习方法仅需 Grid Search 方法所需的大约 20% 的 LLM API 调用次数,即可实现 Recall@5 $\approx 0.8$。此外,在更具挑战性的优化场景中,所提出的 Hier-MAB 方法优于其他基线方法。代码将在 https://aka.ms/autorag 公开。

英文摘要:

Recent advancements in Large Language Models have transformed ML/AI development, necessitating a reevaluation of AutoML principles for the Retrieval-Augmented Generation (RAG) systems. To address the challenges of hyper-parameter optimization and online adaptation in RAG, we propose the AutoRAG-HP framework, which formulates the hyper-parameter tuning as an online multi-armed bandit (MAB) problem and introduces a novel two-level Hierarchical MAB (Hier-MAB) method for efficient exploration of large search spaces. We conduct extensive experiments on tuning hyper-parameters, such as top-k retrieved documents, prompt compression ratio, and embedding methods, using the ALCE-ASQA and Natural Questions datasets. Our evaluation from jointly optimization all three hyper-parameters demonstrate that MAB-based online learning methods can achieve Recall@5 $\approx 0.8$ for scenarios with prominent gradients in search space, using only $\sim20\%$ of the LLM API calls required by the Grid Search approach. Additionally, the proposed Hier-MAB approach outperforms other baselines in more challenging optimization scenarios. The code will be made available at https://aka.ms/autorag.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑