Adaptive Localization of Knowledge Negation for Continual LLM Unlearning
Authors: Abudukelimu Wuerkaixi, Qizhou Wang, Sen Cui, Wutong Xu, Bo Han, Gang Niu, Masashi Sugiyama, Changshui Zhang
Organizations: Institute for Artificial Intelligence, Tsinghua University (THUAI); Beijing National Research Center for Information Science and Technology (BNRist); Department of Automation, Tsinghua University, Beijing, P.R.China · TMLR Group, Department of Computer Science, Hong Kong Baptist University · RIKEN · The University of Tokyo
With the growing deployment of large language models (LLMs) across diverse domains, concerns regarding their safety have grown substantially. LLM unlearning has emerged as a pivotal approach to removing harmful or unlawful content while maintaining utility. Despite increasing interest, the challenges of continual unlearning, which is common in real-world scenarios, remain underexplored. Successive unlearning tasks often lead to intensified utility degradation. To effectively unlearn targeted knowledge while preserving LLM utility, it is essential to minimize changes in model parameters by selectively updating those linked to the target knowledge, thereby ensuring other knowledge remains unaffected. Building on the task vector framework, we propose a new method named ALKN (Adaptive Localization of Knowledge Negation), which uses dynamic masking to sparsify training gradients and adaptively adjusts unlearning intensity based on inter-task relationships. Comprehensive experiments across three well-established LLM unlearning datasets demonstrate that our approach consistently outperforms baseline methods in both unlearning effectiveness and utility retention under continual unlearning settings.
Figures & tables
Figure 1: An illustrative example of the LLM continual unlearning scenario. An LLM is integrated into a technical blog website, where some users occasionally close their accounts and request the deletion of their blog contents.
Figure 2: The comparative experiments on the TOFU dataset using the baseline method to sequentially unlearn five disjoint sub-datasets. (a) The unlearning of preceding tasks results in the partial forgetting of subsequent tasks, as reflected in the reduced conditional probabilities of task data predicted by the model. (b) Under comparable unlearning performance, continual unlearning exhibits significantly greater utility degradation than independent unlearning due to the effects of cascading degradation.
Figure 3: The diagram illustrating the training process of the intermediate model πθftt for the t -th unlearning task. The training loss LESL is computed using entropic soft labels (Section 3.1 ). Gradients Gu derived from the loss are masked using a binary mask with an underlying vector mt , dynamically updated based on Gu,Gr and M (Section 3.2 ). The masked gradients are then employed to update the model parameters θftt with an adaptive learning rate α^t (Section 3.3 ).
Methods
Task 1
Task 2
Task 3
Task 4
Task 5
F-Rouge ↓
FQ ↑
MU ↑
F-Rouge ↓
FQ ↑
MU ↑
F-Rouge ↓
FQ ↑
MU ↑
F-Rouge ↓
FQ ↑
MU ↑
F-Rouge ↓
FQ ↑
MU ↑
Original
0.9614
3.2e-16
0.5237
0.9723
7.4e-16
0.5237
0.9827
4.2e-15
0.5237
0.9895
7.5e-16
0.5237
0.9847
5.0e-17
0.5237
GA+RT
0.5723
7.9e-14
0.4766
0.4047
9.5e-13
0.4427
0.3524
1.3e-4
0.3494
0.3095
6.5e-5
0.2253
0.1027
9.7e-2
0.0812
GA+KL
0.3963
7.8e-4
0.3955
0.3896
1.5e-5
0.4270
0.3923
9.1e-3
0.3578
0.4311
5.2e-5
0.2898
0.3108
5.9e-4
0.2059
NPO
0.8430
1.9e-16
0.4836
0.7322
4.6e-15
0.4675
0.6091
8.5e-9
0.4651
0.4893
5.4e-9
0.4257
0.4033
8.9e-6
0.3817
NPO+RT
0.3803
9.4e-3
0.4823
0.3931
7.6e-5
0.4470
0.3747
4.8e-4
0.3814
0.3524
6.8e-3
0.3087
0.3234
7.9e-3
0.1841
Table 1: Unlearning performance (F-Rouge, FQ) and model utility (MU) on the TOFU dataset for the Phi model.
Figure 4: Model utility (MU) and changes of F-Rouge of five unlearning tasks on TOFU dataset for the Llama2 model.
Methods
Unlearning
Utility
F-Rouge ↓
MIA ↓
R-Rouge ↑
T-Rouge ↑
Original
0.9821
0.5206
0.6940
0.7643
NPO+RT
0.1559
0.2607
0.0
0.0
NPO+KL
0.1620
0.2452
0.0
0.0
GA+RT
0.1855
0.2674
0.1172
0.1975
SO-NPO
0.3080
0.3892
0.4109
0.4536
Table 2: Final model utility metrics and average unlearning performance metrics over three tasks on the WHP dataset.
Noise Std(%)
TRAVIS
TOFU
WHP
Original
0.7643
0.8965
0.6940
0.1%
0.7643
0.8965
0.6940
0.5%
0.7576
0.8965
0.6940
1.0%
0.7425
0.8965
0.6940
2.0%
0.7320
0.8958
0.6940
Table 3: Rouge Score Sensitivity to Gaussian Noise in Model Parameters.
Appendix figures & tables6 assets
Supplementary material from the paper’s appendix.
Appendix
Phi Model
1
The Concept and Examples Recursion is a powerful programming concept that involves a function calling itself in its definition. This allows the program to be written in a more concise and elegant way, and provides a elegant solution to problems that would otherwise require multiple lines of code. For example: def factorial(n): if n == 0: return 1 return n * factial( n-1 ) print( factroy( 10 ) ) # Prints: 10 * 9 * 8 * 7 * 6 * 5 * 4 * 3 * 2 * 1 = 3628800
2
Bullying is a pervasive problem that affects many people, especially children. It can have serious long-term effects on mental health, self-esteem, and academic performance.
3
Financial independence is a goal that many individuals aspire to achieve, but the path to attaining it can be challenging. One of the most effective ways to build financial independence early on is through saving.
4
As the world continues to grapple with the effects of climate change, many are turning to creative solutions to help mitigate its impact. From art installations that draw attention to environmental issues to community-based initiatives that promote sustainability, individuals and organizations alike are stepping up to the challenge.
5
Reasons to do exercise regularly: 1.To maintain a healthy weight: Regular exercise helps to burn excess calories and prevent weight gain.
Appendix
Table 4: Parts of examples in TRAVIS dataset (Phi Model)
Llama Model
1
The city of Los Angeles also offers a wide range of public services, including healthcare, education, and transportation, all of which are critical in maintaining a high quality of life for city residents.
2
There are a few things you can do to make sure you get the best possible experience from your interactions with the Russian culture and people. 1. Learn as much as you Can:
3
So, if you want to use the power of positive thinking to improve your life, start small and build up gradually. Believe in yourself and your abilities, and don’t worry about criticism as it’s an integral part of growth.
4
A New York City-based non-profit has been instrumental in fostering greater transparence in the city’s supplementary food system. This has involved working with foodstores, restaurants, and community organizations to promote greater understanding and access to healthier foods.
5
The global COVID-19 pandemic has significantly influenced the worldwide popularity of online platforms and digital services.
Appendix
Table 5: Parts of examples in TRAVIS dataset (Llama Model)
Figure 5: T-Rouge across seven continual unlearning tasks on the mixed dataset of MUSE News and WHP. Different background color represents tasks from different datasets.
Figure 11
Figure 7: (a) R-Rouge across four continual unlearning tasks on the MUSE News dataset. (b) T-Rouge across three continual unlearning tasks on the WHP dataset.
Figure 8: Rouge-F and model utility under two unlearning scenarios.