Skip to content

Latest commit

 

History

257 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

prj_rag

Attacks (and Defenses) on Retrieval Augmented Generation (RAG)

Install

Install phantom package

cd phantom
pip install -e .

Setup

Point to folders where relevant data and results will be saved. Specifically, PHANTOM_DATA_PATH and PHANTOM_RESULTS_PATH should be set in the environment. If API-based models (e.g. OpenAI) will be used for transfer-experiments, please make sure OPENAI_KEY is also defined.

Usage

RAG poisoning attack with Phantom

python rag_poison.py --config configs/test.yaml

Retriever inference attacks

python retriever_inference.py --config 

About

Attacks on Retrieval Augmented Generation

Resources

Stars

2 stars

Watchers

6 watching

Forks

Releases

Packages

Contributors

Languages