Skip to content

Official Implementation of "Learning to Refuse: Towards Mitigating Privacy Risks in LLMs"

Notifications You must be signed in to change notification settings

zhliu0106/learning-to-refuse

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

learning-to-refuse

Official Implementation of Learning to Refuse: Towards Mitigating Privacy Risks in LLMs

RETURN: Real-world pErsonal daTa UnleaRNing dataset

RETURN is avaliable in data/RETURN.jsonl. You also can access RETURN directly on Hugging Face.

from datasets import load_dataset

dataset = load_dataset("zhliu/RETURN")

Reproduction

Environment Setup

# Clone the repository
git clone git@github.com:zhliu0106/learning-to-refuse.git
cd learning-to-refuse

# Create and activate conda environment
conda create -n refuse python==3.10
conda activate refuse

# Install dependencies
pip install -r requirements.txt

Data Preprocessing

bash scripts/data_process.sh

Training and Evaluation

bash scripts/run.sh

Note: Due to differences in hardware environments and random seed settings, there might be slight variations in the experimental results.

Citation

@article{liu2024learning,
  title={Learning to refuse: Towards mitigating privacy risks in llms},
  author={Liu, Zhenhua and Zhu, Tong and Tan, Chuanyuan and Chen, Wenliang},
  journal={arXiv preprint arXiv:2407.10058},
  year={2024}
}

About

Official Implementation of "Learning to Refuse: Towards Mitigating Privacy Risks in LLMs"

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published