UnlearningSoup: Is Repeated Tuning Necessary for Large Language Model Unlearning?
Organizations: Division of Computing and Mathematical Sciences, MBZUAI · RIKEN Center for Advanced Intelligence Project · TMLR Group, Department of Computer Science, Hong Kong Baptist University · Torr Vision Group, Department of Engineering Science, University of Oxford
Abstract
Large language models trained on vast corpora inherently risk memorizing harmful content that may later re-emerge in their outputs. To mitigate this issue, existing unlearning methods typically rely on training-based parameter updates, such as gradient ascent and its variants, to delete targeted content while preserving other knowledge. However, balancing the competing goals of forgetting and retention makes hyperparameter choices for these methods particularly difficult, often requiring repeated tuning to obtain a strong model that still leaves substantial room for improvement and transfers poorly across models and datasets. To address this challenge, we investigate whether unlearning runs exhibit exploitable structure in weight space, and observe that models from different runs still lie in a shared evaluation-performance basin. This suggests that stronger models may be recovered through an unlearning-tailored soup strategy, reducing the need for repeated tuning for further improvement or new settings. Motivated by this, we propose UnlearningSoup, a unified framework that provides two strategies: EfficientSoup uses binary-search-based interpolation to quickly discover a well-performing model in the early stage, where repeated tuning would otherwise make strong model selection costly. PerformanceSoup uses reweighted souping to efficiently unlock the remaining performance potential in the later stage, where repeated tuning becomes increasingly inefficient. Extensive experiments across diverse datasets and models show that UnlearningSoup delivers 2.4x to 3.3x efficiency gains in hyperparameter selection, while consistently improving performance across settings.
Figures & tables
| Method | LLaMA-3.2-1B | LLaMA-3.2-3B | Qwen2.5-1.5B | Qwen2.5-3B | ||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| T | EAM | ESM | T | EAM | ESM | T | EAM | ESM | T | EAM | ESM | |
| GradDiff | 10.45 | 18.00 | 18.70 | 23.79 | ||||||||
| NPO | 20.48 | 2.67 | 0.05 | 31.20 | 3.65 | 0.11 | 31.15 | 3.41 | 0.10 | 37.42 | 4.42 | 0.14 |
| WGA | 10.66 | 19.75 | 19.05 | 24.2 | ||||||||
| Method | LLaMA-3.2-1B | LLaMA-3.2-3B | LLaMA-3.1-8B | ||||||
|---|---|---|---|---|---|---|---|---|---|
| SBQ | LBQ | GPU-Hours | SBQ | LBQ | GPU-Hours | SBQ | LBQ | GPU-Hours | |
| Original | 5.216 | 5.049 | - | 5.574 | 6.253 | - | 5.272 | 6.144 | - |
| GradDiff | 6.118 | 0.230 | 1.269 | 5.635 | 0.049 | 2.172 | 6.230 | 0.385 | 4.774 |
| +EfSoup | 7.355 ( ) | 1.021 ( ) | 0.400 ( ) | 7.776 ( ) | 2.150 ( ) | 0.675 ( ) | 7.187 ( ) | 2.145 ( ) | 1.464 ( ) |
| NPO | 5.722 | 4.452 | 2.439 | 6.190 | 4.372 | 3.712 | 6.621 | 1.006 | 8.408 |
| +EfSoup | 7.083 ( ) | 5.272 ( ) | 0.734 ( ) | 7.294 ( ) | 5.349 ( ) | 1.115 ( ) | 6.817 ( ) | 1.630 ( ) | 2.502 ( ) |
| Strategy | SBQ | |
|---|---|---|
| Uniform Wortsman et al. (2022) | 80.05 | 5.982 |
| Uniform&Greedy Wortsman et al. (2022) | 46.69 | 6.952 |
| Reweighted&Greedy | 42.58 | 7.108 |
| Method | LLaMA-3.2-1B | LLaMA-3.2-3B | LLaMA-3.1-8B | ||||||
|---|---|---|---|---|---|---|---|---|---|
| SBQ | LBQ | GPU-Hours | SBQ | LBQ | GPU-Hours | SBQ | LBQ | GPU-Hours | |
| Original | 5.216 | 5.049 | - | 5.574 | 6.253 | - | 5.272 | 6.144 | - |
| GradDiff | 6.118 | 0.230 | 1.269 | 5.635 | 0.049 | 2.172 | 6.230 | 0.385 | 4.774 |
| +PeSoup | 7.485 ( ) | 1.204 ( ) | 1.274 ( ) | 7.454 ( ) | 0.516 ( ) | 2.185 ( ) | 7.251 ( ) | 1.574 ( ) | 4.819 ( ) |
| NPO | 5.722 | 4.452 | 2.439 | 6.190 | 4.372 | 3.712 | 6.621 | 1.006 | 8.408 |
| +PeSoup | 6.920 ( ) | 5.361 ( ) | 2.445 ( ) | 7.083 ( ) | 5.003 ( ) | 3.725 ( ) | 6.931 ( ) | 1.671 ( ) | 8.452 ( ) |
| Method | WMDP | MUSE-Books | MUSE-News | ||||||
|---|---|---|---|---|---|---|---|---|---|
| Forget Acc. | MMLU Acc. | GPU-Hours | MemQ | UtilPres | GPU-Hours | MemQ | UtilPres | GPU-Hours | |
| Original | 0.528 | 0.585 | - | 81.589 | 67.010 | - | 60.654 | 54.310 | - |
| GradDiff | 0.270 | 0.444 | 6.724 | 0.000 | 28.598 | 9.861 | 22.615 | 28.341 | 8.042 |
| +EfSoup | 0.260 ( ) | 0.493 ( ) | 2.491 ( ) | 0.000 ( N/A ) | 34.482 ( ) | 3.843 ( ) | 22.354 ( ) | 34.321 ( ) | 3.237 ( ) |
| +PeSoup | 0.269 ( ) | 0.462 ( ) | 7.036 ( ) | 0.000 ( N/A ) | 31.450 ( ) | 10.556 ( ) | 22.596 ( ) | 30.333 ( ) | 8.737 ( ) |
| NPO | 0.286 | 0.501 | 7.554 | 11.713 | 37.362 | 12.984 | 29.429 | 34.787 | 10.301 |
| Model | SBQ | |
|---|---|---|
| Seed=1, 42 | 25.19 | 7.776 |
| Lr=1e-5, 5e-6 | 28.44 | 7.691 |
| 24.90 | 7.779 | |
| Search Depth | SBQ | |
| Depth=2 | 46.34 | 7.144 |
| Depth=3 | 29.03 | 7.654 |
Appendix figures & tables19 assets
Supplementary material from the paper’s appendix.
Appendix
| Strategy | Statistic-Based Quality (SBQ) | ||||||||
|---|---|---|---|---|---|---|---|---|---|
| Prob. | ROUGE-L | ES Unlearn | Truth Ratio | EQ | Model Utility | ES Retain | RQ | SBQ | |
| GradDiff | 0.0000 | 0.0000 | 0.0000 | 0.4390 | 8.3637 | 0.4946 | 0.3477 | 4.0835 | 6.5813 |
| +Uniform | 0.0000 | 0.0000 | 0.0028 | 0.4395 | 8.3559 | 0.4968 | 0.3721 | 4.2553 | 6.6306 |
| +Uniform Greedy | 0.0000 | 0.0000 | 0.0028 | 0.4558 | 8.2636 | 0.4971 | 0.4565 | 4.7597 | 6.7432 |
| +Reweighted Greedy | 0.0000 | 0.0025 | 0.0028 | 0.4666 | 8.1967 | 0.5179 | 0.6094 | 5.5995 | 7.0193 |
| NPO | 0.1460 | 0.3977 | 0.0869 | 0.6080 | 6.1751 | 0.4965 | 0.3415 | 4.0467 | 5.2205 |
| Method | LLaMA-3.2-1B | LLaMA-3.2-3B | LLaMA-3.1-8B | ||||||
|---|---|---|---|---|---|---|---|---|---|
| SBQ | LBQ | GPU-Hours | SBQ | LBQ | GPU-Hours | SBQ | LBQ | GPU-Hours | |
| Original | 5.216 | 5.326 | - | 5.574 | 6.478 | - | 5.272 | 5.825 | - |
| GradDiff | 5.695 | 0.152 | 0.704 | 6.251 | 0.260 | 1.194 | 6.792 | 0.136 | 2.598 |
| +EfSoup | 7.351 ( ) | 0.164 ( ) | 0.237 ( ) | 7.670 ( ) | 0.450 ( ) | 0.392 ( ) | 7.319 ( ) | 0.087 ( ) | 0.838 ( ) |
| NPO | 4.977 | 6.052 | 1.335 | 5.294 | 4.616 | 1.972 | 7.056 | 1.000 | 4.341 |
| +EfSoup | 7.185 ( ) | 6.320 ( ) | 0.417 ( ) | 7.343 ( ) | 5.949 ( ) | 0.614 ( ) | 7.665 ( ) | 4.298 ( ) | 1.336 ( ) |
| Method | LLaMA-3.2-1B | LLaMA-3.2-3B | LLaMA-3.1-8B | ||||||
|---|---|---|---|---|---|---|---|---|---|
| SBQ | LBQ | GPU-Hours | SBQ | LBQ | GPU-Hours | SBQ | LBQ | GPU-Hours | |
| Original | 5.216 | 5.326 | - | 5.574 | 6.478 | - | 5.272 | 5.825 | - |
| GradDiff | 5.695 | 0.152 | 0.704 | 5.635 | 0.049 | 1.194 | 6.792 | 0.136 | 2.598 |
| +PeSoup | 7.349 ( ) | 1.869 ( ) | 0.710 ( ) | 7.454 ( ) | 0.516 ( ) | 1.207 ( ) | 7.236 ( ) | 0.240 ( ) | 2.643 ( ) |
| NPO | 4.977 | 6.052 | 1.335 | 6.190 | 4.372 | 1.972 | 7.056 | 1.000 | 4.341 |
| +PeSoup | 7.309 ( ) | 6.187 ( ) | 1.341 ( ) | 7.083 ( ) | 5.003 ( ) | 1.984 ( ) | 7.554 ( ) | 3.614 ( ) | 4.386 ( ) |
| Attack | Tuning-Based | +EfficientSoup | +PerformanceSoup | ||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Prob. | ROUGE-L | ES Unlearn | Truth Ratio | EQ | Prob. | ROUGE-L | ES Unlearn | Truth Ratio | EQ | Prob. | ROUGE-L | ES Unlearn | Truth Ratio | EQ | |
| GradDiff | |||||||||||||||
| Original | 0.0306 | 0.2838 | 0.0785 | 0.4350 | 7.5713 | 0.0468 | 0.0452 | 0.0191 | 0.2844 | 8.8627 | 0.0000 | 0.1492 | 0.0000 | 0.3726 | 8.3870 |
| Cross-lingual | 0.0623 | 0.2786 | 0.0331 | 0.4911 | 7.3370 | 0.0814 | 0.0465 | 0.0191 | 0.2956 | 8.7403 | 0.0000 | 0.1399 | 0.0000 | 0.3975 | 8.2949 |
| Jailbreaking | 0.0349 | 0.2849 | 0.0334 | 0.4806 | 7.4149 | 0.0815 | 0.0717 | 0.0193 | 0.2868 | 8.7191 | 0.0001 | 0.1815 | 0.0049 | 0.3846 | 8.2445 |
| Relearn | 0.1660 | 0.4058 | 0.2500 | 0.5573 | 6.1784 | 0.1703 | 0.1789 | 0.2037 | 0.5318 | 6.8790 | 0.1503 | 0.2585 | 0.2064 | 0.5323 | 6.7527 |
| Method | W/o Relearning Attacks | W/ Relearning Attacks | ||
|---|---|---|---|---|
| VerbMem | KnowMem | VerbMem | KnowMem | |
| GradDiff | 0.0000 | 0.0000 | 36.4200 | 43.0300 |
| +EfSoup | 0.0000 | 0.0000 | 36.2335 | 41.0889 |
| +PeSoup | 0.0000 | 0.0000 | 36.8505 | 42.0792 |
| NPO | 10.4016 | 12.8913 | 68.5800 | 46.0600 |
| +EfSoup | 7.5604 | 13.6783 | 66.8434 | 47.1971 |
| Strategy | Statistic-Based Quality (SBQ) | |||||||||
|---|---|---|---|---|---|---|---|---|---|---|
| Prob. | ROUGE-L | ES Unlearn | Truth Ratio | EQ | Model Utility | ES Retain | RQ | SBQ | ||
| GradDiff | 0.0000 | 0.0085 | 0.0000 | 0.4936 | 8.0266 | 0.4637 | 0.2016 | 2.8102 | 0.7984 | 6.0135 |
| Uniform | 0.0000 | 0.0094 | 0.0000 | 0.5003 | 7.9829 | 0.4701 | 0.1995 | 2.8013 | 0.8005 | 5.9822 |
| Uniform&Greedy | 0.0000 | 0.0080 | 0.0000 | 0.4284 | 8.4080 | 0.4879 | 0.5331 | 5.0952 | 0.4669 | 6.9518 |
| Reweight&Greedy (PeSoup) | 0.0000 | 0.0078 | 0.0000 | 0.4031 | 8.5413 | 0.4922 | 0.5742 | 5.3002 | 0.4258 | 7.1079 |
| Strategy | Statistic-Based Quality (SBQ) | |||||||||
|---|---|---|---|---|---|---|---|---|---|---|
| Prob. | ROUGE-L | ES Unlearn | Truth Ratio | EQ | Model Utility | ES Retain | RQ | SBQ | ||
| GradDiff | 0.0306 | 0.2838 | 0.0785 | 0.4350 | 7.5713 | 0.4763 | 0.1682 | 2.4866 | 0.8355 | 5.6351 |
| Seed=1,42 | 0.0468 | 0.0452 | 0.0191 | 0.2844 | 8.8627 | 0.5758 | 0.7488 | 6.5098 | 0.2519 | 7.7758 |
| Lr=1e-5,5e-6 | 0.0366 | 0.0583 | 0.0036 | 0.2979 | 8.8343 | 0.5699 | 0.7156 | 6.3447 | 0.2844 | 7.6909 |
| lambda=1,0.5 | 0.0360 | 0.0505 | 0.0122 | 0.2884 | 8.8727 | 0.5734 | 0.7513 | 6.5043 | 0.2490 | 7.7792 |
| depth=2 | 0.0596 | 0.0739 | 0.0387 | 0.3350 | 8.5338 | 0.5434 | 0.5382 | 5.4080 | 0.4634 | 7.1440 |
| Strategy | Statistic-Based Quality (SBQ) | ||||||||
|---|---|---|---|---|---|---|---|---|---|
| Prob. | ROUGE-L | ES Unlearn | Truth Ratio | EQ | Model Utility | ES Retain | RQ | SBQ | |
| GradDiff | 0.0000 | 0.0126 | 0.0000 | 0.4645 | 8.1964 | 0.4326 | 0.3012 | 3.5514 | 6.3164 |
| +EfSoup | 0.0000 | 0.0089 | 0.0000 | 0.4218 | 8.4415 | 0.5453 | 0.5857 | 5.6480 | 7.1819 |
| +PeSoup | 0.0000 | 0.0089 | 0.0000 | 0.3940 | 8.5855 | 0.5017 | 0.6203 | 5.5470 | 7.2277 |
| +EfSoup | 0.0000 | 0.0089 | 0.0000 | 0.4218 | 8.4415 | 0.5453 | 0.5857 | 5.6480 | 7.1819 |
| +PeSoup | 0.0000 | 0.0113 | 0.0000 | 0.4115 | 8.4911 | 0.5132 | 0.6087 | 5.5691 | 7.1803 |
| Method | LLaMA-3.2-1B | LLaMA-3.2-3B | LLaMA-3.1-8B | Qwen2.5-1.5B | Qwen2.5-3B | Qwen2.5-7B |
|---|---|---|---|---|---|---|
| GradDiff | 91.840 | 151.550 | 314.370 | 154.770 | 197.470 | 334.880 |
| +EfSoup | 44.930 ( ) | 68.850 ( ) | 125.030 ( ) | 68.090 ( ) | 87.360 ( ) | 135.160 ( ) |
| +PeSoup | 107.860 ( ) | 173.450 ( ) | 344.550 ( ) | 175.230 ( ) | 223.990 ( ) | 368.720 ( ) |
| NPO | 162.050 | 243.950 | 532.350 | 241.920 | 292.880 | 592.200 |
| +EfSoup | 64.990 ( ) | 95.250 ( ) | 187.310 ( ) | 92.990 ( ) | 114.620 ( ) | 208.680 ( ) |
| +PeSoup | 178.070 ( ) | 265.850 ( ) | 562.530 ( ) | 262.380 ( ) | 319.400 ( ) | 626.040 ( ) |
| Method | WMDP | MUSE-Books | MUSE-News | |||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Cyber Acc. | Bio Acc. | Forget Acc. | MMLU Acc. | VerbMem | KnowMem | MemQ | UtilPres | VerbMem | KnowMem | MemQ | UtilPres | |
| Original | 0.3924 | 0.6354 | 0.5281 | 0.5853 | 99.5600 | 58.3200 | 81.5887 | 67.0100 | 58.2900 | 62.9300 | 60.6544 | 54.3100 |
| GradDiff | 0.2657 | 0.2739 | 0.2698 | 0.4442 | 0.0000 | 0.0000 | 0.0000 | 28.5984 | 4.0600 | 31.7238 | 22.6151 | 28.3406 |
| +EfSoup | 0.2567 | 0.2635 | 0.2601 | 0.4927 | 0.0000 | 0.0000 | 0.0000 | 34.4819 | 2.0053 | 31.5490 | 22.3535 | 34.3208 |
| +PeSoup | 0.2613 | 0.2772 | 0.2694 | 0.4617 | 0.0000 | 0.0000 | 0.0000 | 31.4498 | 3.8907 | 31.7176 | 22.5958 | 30.3334 |
| NPO | 0.3067 | 0.2647 | 0.2865 | 0.5011 | 10.4016 | 12.8913 | 11.7128 | 37.3619 | 16.4346 | 38.2363 | 29.4288 | 34.7869 |
| Method | Statistic-Based Quality (SBQ) | LaaJ-Based Quality (LBQ) | ||||||||||||
| Prob. | ROUGE-L | ES Unlearn | Truth Ratio | EQ | Model Utility | ES Retain | RQ | SBQ | Fluency | Relevance | Hallucination | Correctness | LQ | |
| LLaMA-3.2-1B, Forget 5 | ||||||||||||||
| Original | 0.9882 | 0.7827 | 0.9735 | 0.6865 | 0.3072 | 0.5891 | 0.9840 | 7.3701 | 5.2160 | 8.6748 | 7.6544 | 8.9612 | 2.5412 | 5.3260 |
| GradDiff | 0.0357 | 0.3478 | 0.0830 | 0.3560 | 7.6722 | 0.4527 | 0.1680 | 2.4509 | 5.6952 | 0.0685 | 0.0880 | 3.7300 | 6.4920 | 0.1516 |
| +EfSoup | 0.0000 | 0.0886 | 0.0000 | 0.3377 | 8.6825 | 0.5282 | 0.6229 | 5.7167 | 7.3507 | 0.0628 | 0.1245 | 3.8410 | 6.7703 | 0.1642 |
| NPO | 0.2218 | 0.2632 | 0.0880 | 0.5570 | 6.6713 | 0.4620 | 0.1483 | 2.2450 | 4.9772 | 8.3434 | 5.6316 | 4.5251 | 7.0138 | 6.0515 |
| Method | Statistic-Based Quality (SBQ) | LaaJ-Based Quality (LBQ) | ||||||||||||
| Prob. | ROUGE-L | ES Unlearn | Truth Ratio | EQ | Model Utility | ES Retain | RQ | SBQ | Fluency | Relevance | Hallucination | Correctness | LQ | |
| Qwen2.5-1.5B, Forget 5 | ||||||||||||||
| Original | 0.9803 | 0.9209 | 0.9536 | 0.4376 | 0.4605 | 0.5332 | 0.9550 | 6.8435 | 4.8500 | 8.7391 | 7.5376 | 9.3561 | 2.4393 | 5.2361 |
| GradDiff | 0.0000 | 0.0000 | 0.0000 | 0.4390 | 8.3637 | 0.4946 | 0.3477 | 6.5813 | 7.5254 | 0.0040 | 0.0040 | 1.1500 | 6.9120 | 0.0080 |
| +EfSoup | 0.0524 | 0.0023 | 0.0371 | 0.4447 | 8.1685 | 0.5403 | 0.6255 | 7.0831 | 7.6451 | 0.0626 | 0.0832 | 3.7650 | 6.4320 | 0.1408 |
| NPO | 0.1460 | 0.3977 | 0.0869 | 0.6080 | 6.1751 | 0.4965 | 0.3415 | 5.2205 | 5.7177 | 8.0583 | 6.1414 | 3.1397 | 7.3711 | 5.3974 |
| Method | Statistic-Based Quality (SBQ) | LaaJ-Based Quality (LBQ) | ||||||||||||
| Prob. | ROUGE-L | ES Unlearn | Truth Ratio | EQ | Model Utility | ES Retain | RQ | SBQ | Fluency | Relevance | Hallucination | Correctness | LQ | |
| LLaMA-3.2-1B, Forget 5 | ||||||||||||||
| Original | 0.9882 | 0.7827 | 0.9735 | 0.6865 | 0.3072 | 0.5891 | 0.9840 | 7.3701 | 5.2160 | 8.6748 | 7.6544 | 8.9612 | 2.5412 | 5.3260 |
| GradDiff | 0.0357 | 0.3478 | 0.0830 | 0.3560 | 7.6722 | 0.4527 | 0.1680 | 2.4509 | 5.6952 | 0.0685 | 0.0880 | 3.7300 | 6.4920 | 0.1516 |
| +PeSoup | 0.0043 | 0.2049 | 0.0094 | 0.3365 | 8.3707 | 0.5688 | 0.6720 | 6.1608 | 7.3493 | 1.2270 | 1.0642 | 4.3031 | 6.5503 | 1.8694 |
| NPO | 0.2218 | 0.2632 | 0.0880 | 0.5570 | 6.6713 | 0.4620 | 0.1483 | 2.2450 | 4.9772 | 8.3434 | 5.6316 | 4.5251 | 7.0138 | 6.0515 |
| Method | Statistic-Based Quality (SBQ) | LaaJ-Based Quality (LBQ) | ||||||||||||
| Prob. | ROUGE-L | ES Unlearn | Truth Ratio | EQ | Model Utility | ES Retain | RQ | SBQ | Fluency | Relevance | Hallucination | Correctness | LQ | |
| Qwen2.5-1.5B, Forget 5 | ||||||||||||||
| Original | 0.9803 | 0.9209 | 0.9536 | 0.4376 | 0.4605 | 0.5332 | 0.9550 | 6.8435 | 4.8500 | 8.7391 | 7.5376 | 9.3561 | 2.4393 | 5.2361 |
| GradDiff | 0.0000 | 0.0000 | 0.0000 | 0.4390 | 8.3637 | 0.4946 | 0.3477 | 4.0835 | 6.5813 | 0.0040 | 0.0040 | 1.1500 | 6.9120 | 0.0080 |
| +PeSoup | 0.0000 | 0.0025 | 0.0028 | 0.4666 | 8.1967 | 0.5179 | 0.6094 | 5.5995 | 7.0193 | 0.0527 | 0.0332 | 2.9183 | 6.7982 | 0.0807 |
| NPO | 0.1460 | 0.3977 | 0.0869 | 0.6080 | 6.1751 | 0.4965 | 0.3415 | 4.0467 | 5.2205 | 8.0583 | 6.1414 | 3.1397 | 7.3711 | 5.3974 |
LLM Unlearning
Large language model unlearning studies how to remove specified knowledge or behaviors while preserving a model’s unrelated capabilities.
See all 190 papers