一句话:提出蜕变测试框架,用11种变异算子评估RAG系统在语料演化下的一致性,检出被现有指标漏掉的故障。
检索增强生成(RAG)系统依赖会随时间演化的外部文档语料,但现有评估方法(如 RAGAS)仅在静态快照上判定正确性,难以发现常规更新、事实变化或噪声注入所引发的故障。本文提出一个蜕变测试框架,用于评估 RAG 系统在语料演化下的一致性。作者形式化了故障分类体系与 11 种变异算子,在 pre-chunk(检索索引)与 post-chunk(检索上下文)两个层次上系统性地扰动系统,并以蜕变预言判定违例。在五个数据集、超过 2.8 万个变异体上的实证评估显示,蜕变违例率为 4.9%–10.2%;与真值对比的元评估中,该蜕变预言的 F1 达到 0.927–1.000,而最好的 RAGAS 指标仅为 0.570。最后,论文给出了通过检索重配置、生成器升级与基于 LLM 的重排序来缓解这些故障的可操作建议。
Retrieval-Augmented Generation (RAG)-based LLM systems rely on external document corpora that can evolve and change over time. However, current evaluation methodologies (e.g., RAGAS) assess correctness against static snapshots, failing to detect faults when routine updates, factual changes, or noise alter the underlying data. We introduce a metamorphic testing framework that evaluates the consistency of RAG systems under corpus evolution. We formalise a fault taxonomy and 11 mutation operators that systematically perturb the system at both the pre-chunk (retrieval index) and post-chunk (retrieved context) levels. An empirical evaluation across five datasets and over 28k mutants reveals metamorphic violation rates of 4.9-10.2%. In a meta-evaluation against ground truth, our metamorphic oracle achieves F1 scores of 0.927-1.000, while the best RAGAS metric reaches only 0.570. Finally, we provide actionable insights into mitigating these faults through retrieval re-configuration, generator upgrades, and LLM-based reranking.