AttackHIGH relevance

GuardRAG: A Post-Retrieval Defense against Poisoning Attacks in Retrieval-Augmented Generation

Linghui Jiao(Southeast University)Kang Wei(Southeast University)Fushuo Huo(Southeast University)Ruijie Zhao(Southeast University)Yiyang Ni(Jiangsu Second Normal University)Jingcai Guo(The Hong Kong Polytechnic University)Yipeng Zhou(Macquarie University)Jun Li(Southeast University)
Published
October 26, 2026
Updated
October 26, 2026

Abstract

Retrieval-Augmented Generation (RAG) enhances the factual grounding of Large Language Models (LLMs) by incorporating external evidence, but also exposes them to corpus poisoning attacks. In particular, coordinated attacks can introduce multiple mutually reinforcing poisoned documents into retrieved contexts, making reliable evidence filtering challenging. To address this problem, we propose GuardRAG, a training-free and plug-and-play post-retrieval defense that exploits the semantic structure of retrieved evidence to identify suspicious document groups. Specifically, GuardRAG first expands the retrieval range and removes near-duplicate candidates, then partitions the retained documents using Hierarchical Agglomerative Clustering (HAC) with a query-adaptive threshold. Finally, it scores and prunes suspicious clusters based on query relevance, cluster size, and semantic compactness. Experiments across three question-answering datasets, multiple poisoning attacks, and six LLMs demonstrate that GuardRAG substantially reduces attack success rates while maintaining answer utility under clean retrieval.

Metadata

Comment
8 figures

Pro Analysis

Full threat analysis, ATLAS technique mapping, compliance impact assessment (ISO 42001, EU AI Act), and actionable recommendations are available with a Pro subscription.

Threat Deep-Dive
ATLAS Mapping
Compliance Reports
Actionable Recommendations
Start 14-Day Free Trial