Keep poisoned context out of your model
Retrieval-augmented generation draws from documents, databases, and the web. Every chunk can be an attack surface. Repellox scans each retrieved chunk for embedded instructions before it enters your model's context window.
The RAG attack surface is wider than assumed
Document poisoning
A knowledge-base PDF hides an instruction in white-on-white text or a comment field. Once retrieved into context, the model treats it as a system directive.
Web retrieval injection
A web page read by your agent contains instructions meant to redirect behavior. Without inspection, the model cannot tell retrieved instructions from a system directive.
Database record injection
Customer records, support tickets, or CRM entries contain crafted text that overrides the system prompt when pulled into context. Common in customer-facing workflows with write access.
Email and message injection
Pipelines ingesting email or Slack are especially exposed. One injected message can redirect an agent assistant to act for an attacker in every later response.
Inspect each chunk, not only the query
Most security tools inspect the user query. Repellox inspects content entering context, where RAG injection risk actually resides. Each retrieved chunk passes through the classifier before entering the model prompt.
If a chunk is flagged, Repellox returns a sanitized version or excludes it from context according to policy. The original source is logged for audit review.
Read the RAG integration guideLink to any retriever
Repellox works at the retriever layer, before chunks reach the prompt. Supports LlamaIndex, LangChain, Haystack, and custom vector store pipelines through one middleware call at retriever output.
Start Protecting Your RAG Pipelinefrom repellox import RAGInspector
inspector = RAGInspector(client=repellox.Client())
# Wrap your retriever output
raw_chunks = vector_store.retrieve(query, top_k=5)
safe_chunks = inspector.scan_chunks(
raw_chunks,
policy="sanitize"
)
# safe_chunks contains only clean content
response = llm.generate(query, context=safe_chunks)
Secure your RAG pipeline in minutes
Free plan: 5,000 monthly inspections. Works with your existing vector store.