sleeepeer/PoisonedRAG

[USENIX Security 2025] PoisonedRAG: Knowledge Corruption Attacks to Retrieval-Augmented Generation of Large Language Models

55
/ 100
Established

Implements both black-box (LM-targeted) and white-box (HotFlip) poisoning attacks on retrieval corpora, targeting popular RAG retriever-LLM pairs including Contriever with GPT-3.5/4, PaLM 2, and LLaMA. Evaluates attacks across BEIR benchmark datasets (NQ, HotpotQA, MS-MARCO) with configurable hyperparameters for adversarial document generation and ranking manipulation. Integrates with Hugging Face model APIs and supports local model deployment via FastChat for reproducible adversarial evaluation.

242 stars.

No Package No Dependents
Maintenance 10 / 25
Adoption 10 / 25
Maturity 16 / 25
Community 19 / 25

How are scores calculated?

Stars

242

Forks

38

Language

Python

License

MIT

Last pushed

Jan 27, 2026

Commits (30d)

0

Get this data via API

curl "https://pt-edge.onrender.com/api/v1/quality/rag/sleeepeer/PoisonedRAG"

Open to everyone — 100 requests/day, no key needed. Get a free key for 1,000/day.