As large language models (LLMs) are applied across diverse domains, the ability to selectively unlearn specific information is becoming increasingly essential. For instance, LLMs are expected to selectively provide confidential information to authorized internal users, such as employees or trusted partners, while withholding it from external users, including the general public and unauthorized entities. Therefore, we propose a novel method termed ``in-context knowledge unlearning'', which enables the model to selectively forget information in test-time based on the query context. Our method fine-tunes pre-trained LLMs to enable prompt unlearning of target knowledge within the context, while preserving unrelated information. Experiments on TOFU, AGE and RWKU datasets using Llama2-7B/13B and Mistral-7B models demonstrate that our method achieves up to 95% forget accuracy while retaining 80% of unrelated knowledge, significantly outperforming baselines in both in-domain and out-of-domain scenarios. Further investigation of the model's internal behavior revealed that while fine-tuned LLMs generate correct predictions in the middle layers and preserve them up to the final layer. However, the decision to forget is made only at the last layer, i.e. ``LLMs pretend to forget''. Our findings offer valuable insight into the improvement of the robustness of the unlearning mechanisms in LLMs, laying a foundation for future research in the field.
Improving LLM Unlearning Robustness via Random Perturbations
Japan Advanced Institute of Science and Technology(日本科学技术先进研究院);VNU University of Engineering and Technology(越南工程与技术大学);Monash University(莫纳什大学);RIKEN(日本研究机构)
GUARD: Generation-time LLM Unlearning via Adaptive Restriction and Detection
The Hong Kong University of Science and Technology (Guangzhou)(香港科学与技术大学(广州));UC Santa Cruz(加州大学圣克鲁兹分校);UIUC(伊利诺伊大学香槟分校);Southeast University(东南大学);BIAI, ZJUT(脑科学与类脑智能研究院,浙江大学);D5Data.ai
Selective Forgetting: Advancing Machine Unlearning Techniques and Evaluation in Language Models
Harbin Institute of Technology(哈尔滨工业大学);Huawei Noah’s Ark Lab(华为诺亚方舟实验室);Unlimidata Ltd(Unlimidata有限公司);The Chinese University of Hong Kong(香港中文大学);University of Calabria(卡拉布里亚大学)
Institute of Automation, Chinese Academy of Sciences(中国科学院自动化研究所);University of Chinese Academy of Sciences(中国科学院大学);The Hong Kong University of Science and Technology (Guangzhou)(香港科技大学(广州))
Attention Smoothing Is All You Need For Unlearning
Department of Computer Science, Wayne State University(韦恩州立大学计算机科学系);Department of Computer Science and Engineering, Michigan State University(密歇根州立大学计算机科学与工程系);Institute for AI and Data Science, Wayne State University(韦恩州立大学人工智能与数据科学研究所)
Forgetting-MarI: LLM Unlearning via Marginal Information Regularization
Department of Mathematics, University of California Davis, USA(加州大学戴维斯分校数学系);SLAC National Accelerator Laboratory, Stanford University, USA(斯坦福大学SLAC国家加速器实验室);Department of Computer Science, University of California Davis, USA(加州大学戴维斯分校计算机科学系)
Unlearning Isn't Deletion: Investigating Reversibility of Machine Unlearning in LLMs
The Hong Kong Polytechnic University(香港理工大学);Carnegie Mellon University(卡内基梅隆大学);University of California, Santa Cruz(加州大学圣克ruz分校);Huawei Technologies(华为技术有限公司);Research Centre for Privacy and Security Technologies in Future Smart Systems, PolyU(未来智能系统中的隐私与安全技术研究中心,PolyU)