Can we defend RAG systems from corpus poisoning without retraining?
Explores whether retrieval-time defenses can catch and block poisoned documents before they reach the generator, without expensive retraining cycles. Matters because corpus updates outpace model retraining in production RAG systems.
RAG poisoning attacks insert malicious documents into the retrieval corpus so they get pulled in for matching queries and steer generation toward attacker-preferred outputs. Existing defenses typically require retraining the retriever or the generator, which is expensive and slow to deploy. RAGPart and RAGMask propose two lightweight defenses that operate at retrieval time without modifying the generation model.
RAGPart exploits a structural property of dense retrievers: they learn discriminative patterns from how the training data is partitioned, which means malicious documents inserted into one partition have predictably limited influence on retrieval from queries that match a different partition. By configuring partitions deliberately, the system bounds how far any single poisoned document can propagate. RAGMask takes a different angle: it masks tokens in candidate documents and watches for abnormal similarity shifts. Genuine documents are robust to token masking — their similarity scores degrade smoothly — while poisoned documents that rely on specific trigger tokens show sudden similarity collapse, which serves as a detection signal.
The architectural significance is that defense need not be coupled to training. Both methods sit at the retrieval layer and treat the generator as an untrusted black box that must be protected from upstream corruption. This separation matters operationally because retrieval corpora update faster than retrievers can be retrained, so defenses that require retraining are always behind the threat. The threat surface is real and severe — How vulnerable is GraphRAG to tiny text manipulations? shows even minimal corpus modifications can devastate accuracy in graph-structured RAG.
Inquiring lines that read this note 64
This note is a source for these research framings, grouped by the broader line of inquiry each explores. Scan the bold lines of inquiry; follow any specific question forward.
Is model misalignment inherent to base models or induced by alignment procedures?- Why does even 0.1 percent poisoned training data persist through alignment?
- Does pretraining poisoning at scale persist through instruction alignment?
- How severely do minimal corpus modifications damage RAG accuracy in practice?
- Why does bidirectional RAG amplify the risk of corpus poisoning attacks?
- What makes prerequisite filtering more reliable than semantic similarity matching?
- Can factually wrong generated documents still improve retrieval accuracy?
- Why do RAG systems fail when demo queries work correctly?
- How does MaxSim reranking differ from structural verification at the token level?
- Does retrieval quality depend more on access structure or write gating?
- Can retrieval augmented generation systems defend against corpus poisoning without retraining?
- What makes dense retrievers vulnerable to partition-based poisoning exploitation?
- What makes evidence selection vulnerable to adversarial poisoning attacks?
- What makes semantic attacks harder to defend against than algorithmic ones?
- How does semantic framing differ from content injection attacks?
- Can existing web security defenses protect agents from content manipulation?
- What attack surface opens when content becomes readable but deliberately misleading?
- Why do standard safety filters miss advertisement embedding attacks?
- Can defenses tuned against appended attacks stop prepended payloads?
- What injection vectors threaten Kubernetes data-processing pipelines in production?
- What attacks work entirely within text without changing data flow?
- What defenses do text-to-text injection attacks still need?
- How do token-masking patterns distinguish genuine documents from poisoned ones?
- Can false positives from input filtering be reduced without sacrificing defense?
- What detection rate is needed to make evidence-injection attacks impractical at scale?
- Can shared package repositories partition state to protect honeytokens?
- How do entailment checks prevent synthetic data from degrading retrieval corpora?
- How do retrieval failures enable generation of fabricated scholarly constructs?
- Can RAG systems game user preferences by adding irrelevant citations?
- What prevents scholarly infrastructure from filtering out ghost-authored records automatically?
- How do mirror sites and shadow libraries perpetuate retracted papers?
- How do access controls and anonymization fit into RAG retrieval pipelines?
- How can RAG systems integrate with existing enterprise authentication and security protocols?
- Can an undefended pipeline claim safety when a filter blocks attacks?
- Where else in the vault are recovery and rollback mechanisms already specified?
- How does graph structure amplify poisoning compared to flat document retrieval?
- Can compact extractors outperform large models in RAG pipelines?
- Can knowledge poisoning attacks succeed with less than 0.05 percent modified text?
- How does keyword priming enable language models to spread poisoned information?
- Can consistency training defend against adversarial text injection attacks?
- Why are expensive rankers more resilient to adversarial content than cheap ones?
- Can ecosystem-level standards reduce trap detection burden?
- Do cross-dimension attacks compound beyond single-dimension poisoning effects?
- How do workflow-inspecting defenses fail when contamination enters at planning time?
- Does semantic similarity monitoring face the same paraphrase failures in SafeFlow as in chain-of-thought monitors?
- How should memory poisoning success be scored at the validator stage?
- How do backdoored open-source checkpoints enable covert advertising at scale?
- What economic incentives make advertisement embedding attacks persistently viable?
- Can provenance tracking prevent synthetic content from polluting the corpus?
- Can machine-readable crawler intent declarations solve attribution problems?
- Can detection mechanisms like diff review catch corruption better than deletion?
- How do paper mills reuse images across batches to evade detection?
Related concepts in this collection 3
This note in its neighbourhood — explore the map, then jump to a related concept in the list below.
Click a node to walk · click center to open · click Open in graph to see this note in the full knowledge graph
-
How vulnerable is GraphRAG to tiny text manipulations?
GraphRAG converts raw text into knowledge graphs for question answering. This explores whether adversaries can degrade accuracy with minimal edits to source documents, and what makes the system susceptible.
extends: documents the threat severity that motivates these defenses; together they form an attack/defense pair on the same retrieval corpus surface
-
Can RAG systems safely learn from their own generated answers?
Explores whether retrieval-augmented generation can feed its outputs back into the corpus without corrupting knowledge with hallucinations. The core problem: how to prevent feedback loops from compounding errors.
extends: bidirectional RAG opens a write surface that magnifies the poisoning attack vector; partition-aware retrieval and token-masking detection are exactly the kind of upstream defenses such systems will need
-
Can one compromised agent corrupt an entire multi-agent network?
Explores whether a single biased agent can spread behavioral corruption through ordinary messages to downstream agents without any direct adversarial access. Matters because it reveals a previously unknown vulnerability in how multi-agent systems communicate.
extends: same lesson — defense at the message/retrieval layer beats trying to harden the generator; both attacks slip through ordinary content channels
Related papers in this collection 8
Papers most semantically related to this note, ranked by cosine similarity in the embedding space.
- Ranking Free RAG: Replacing Re-ranking with Selection in RAG for Sensitive Domains
- Retrieval-augmented reasoning with lean language models
- BM25 Wins at Scale: A Scaling Study of Retrieval-Augmented Generation Paradigms
- CLaRa: Bridging Retrieval and Generation with Continuous Latent Reasoning
- You Don't Need Pre-built Graphs for RAG: Retrieval Augmented Generation with Adaptive Reasoning Structures
- A Hybrid RAG System with Comprehensive Enhancement on Complex Reasoning
- Searching for Best Practices in Retrieval-Augmented Generation
- Chain-of-Retrieval Augmented Generation
Original note title
RAG corpus poisoning has lightweight defenses without retraining — partition-aware retrieval and token-masking similarity shifts catch attacks the generator never sees