TL;DR
This paper introduces a comprehensive framework for auditing machine unlearning in Large Language Models (LLMs), addressing the critical need to verify if sensitive data is truly removed. They propose a novel activation perturbation-based auditing method, ActPert, which offers a new perspective on evaluating unlearning efficacy beyond traditional prompt-based approaches.
What Problem Does This Paper Address?
Large Language Models (LLMs) are trained on massive datasets, often scraped from the internet, which can inadvertently include sensitive or copyrighted information. Regulations like GDPR grant individuals the right to request the removal of their data. Machine unlearning aims to remove specific knowledge from trained models without the costly process of retraining from scratch. However, evaluating the effectiveness and robustness of these unlearning algorithms is challenging due to the complex and generative nature of LLMs. Existing methods for auditing unlearning are often insufficient, and it's unclear if knowledge is truly erased or just made harder to access.
Methods
The authors propose a two-pronged approach to auditing machine unlearning:
- A Comprehensive Auditing Framework: This framework includes:
- 3 Benchmark Datasets: WHP (Harry Potter knowledge), TOFU (fictitious authors), and RWKU (real-world public figures).
- 6 Unlearning Algorithms: Gradient Ascent (GA), Gradient Difference (GD), Knowledge Distillation (KD), Rejection Tuning (RT), Direct Preference Optimization (DPO), and Negative Preference Optimization (NPO).
- 5 Prompt-Based Auditing Methods: Including Absolutely Obedient Agent (AOA), In-Context Learning (ICL), MASK, GCG, and SoftGCG.
- Activation Perturbation-based Auditing (ActPert): This novel auditing technique probes residual knowledge by:
- Injecting random noise into the token embeddings of a query related to the unlearning target.
- Computing the difference in intermediate layer activations between the original and perturbed inputs.
- These perturbations are then reintroduced into the model during inference to assess if residual knowledge still influences the output. This method aims to reveal forgotten information by making the model less sensitive to the specific sensitive content.
Datasets
The paper utilizes three benchmark datasets for evaluating unlearning:
- WHP (Who's Harry Potter?): Focuses on unlearning specific factual knowledge about the Harry Potter universe. The dataset was generated using GPT-4.
- TOFU (Task of Fictitious Unlearning): Uses autobiographies of fictitious authors created with GPT-4. The model is unlearned on a small percentage of this data.
- RWKU (Real-World Knowledge Unlearning): Targets real-world knowledge by unlearning facts about public figures. This benchmark uses biographical texts and Q&A pairs.
Key Insights and Ideas
- Unlearning is Harder Than It Looks: Even after applying unlearning algorithms, residual knowledge often remains accessible, as evidenced by the gap between unlearned baselines and audited models.
- Prompt-Based Auditing is Useful, But Not Perfect: Methods like AOA and ICL can effectively expose remaining knowledge, but they might not generalize well to all unlearning strategies or datasets.
- Activation Perturbation Offers a New Angle: ActPert provides a complementary auditing approach that doesn't rely solely on carefully crafted prompts, offering a potentially more robust way to detect subtle traces of forgotten information.
- Preference-Based Unlearning is More Robust: Algorithms like DPO and NPO, which steer model preferences, tend to be more resilient to auditing compared to refusal-based methods.
- Model Architecture Matters: Some architectures, like Phi-3, appear more resistant to unlearning and auditing than others, like LLaMA.
Key Results
- ActPert Shows Promise: The proposed ActPert method demonstrates competitive performance, sometimes surpassing baselines, especially when combined with certain unlearning algorithms like GA and NPO.
- Auditability Varies: On RWKU, DPO and GA showed stronger unlearning than NPO, but RT's performance degraded significantly when audited.
- Dataset Size Impacts Unlearning: Larger unlearning datasets generally improved the effectiveness of GA and DPO on RWKU.
- TOFU is More Effectively Unlearned: Unlearning on the synthetic TOFU dataset was more effective than on RWKU, likely due to the direct availability of ground-truth knowledge.
- Sampling Reveals Persistent Knowledge: Even with sampling-based evaluation, maximum ROUGE scores often remained high, indicating that knowledge acquired during pre-training is difficult to fully remove, especially when the original data is inaccessible.
Limitations and Future Work
- Pretraining Knowledge is Stubborn: The paper highlights that removing knowledge gained during the pretraining stage remains a significant challenge.
- Preference-Based Unlearning Limitations: While effective, preference-based methods are most successful when queries directly target the forgotten information. They struggle with inverse or paraphrased queries.
- Model-Dependent Resilience: The study suggests that model architecture plays a role in unlearning resistance, indicating a need for architecture-specific unlearning strategies.
- Future Directions: The authors suggest further research into auditing methods beyond prompt-based approaches and exploring how to more effectively remove knowledge acquired during the pretraining phase. The complete auditing framework and ActPert algorithm are planned to be open-sourced.
Summary updated