Neighborhood-Aware Unlearning for Generative Recommendation
Organizations: BIFOLD & TU Berlin, Germany · University of Amsterdam, The Netherlands
Abstract
Generative recommendation predicts items by autoregressively generating semantic identifiers (SIDs), whose tokens are shared across semantically related items. With this paradigm gaining adoption, the question of how to support unlearning in it has become pressing. If training interactions must later be removed, such as injected spam or interactions with items a user no longer wants, this sharing lets an unlearning update unintentionally affect the predictions for the interactions' neighbors. We show that this effect is locally structured and hidden by global metrics: unlearning can leave recommendation utility on the whole test set nearly unchanged while substantially degrading it on neighborhoods of the forgotten interactions' SIDs. We propose Neighborhood-Aware Unlearning (NAU), which augments interaction-level unlearning with explicit control over the probability mass assigned to the forgotten items' neighborhoods. Across three datasets and four SID tokenizers, NAU restores spam-induced exposure toward the retrained reference while retaining more than 95% of retrained utility, and recovers the neighborhood utility that forget-and-repair unlearning loses at no global cost. We identify local probability redistribution as an important failure mode of unlearning in SID-based generative recommenders and show that explicitly controlling this redistribution can mitigate its effects.
Figures & tables
| Beauty | Sports | Toys | |||||||
| Method | |||||||||
| Retrained | (0.072) | 3.766 0.13 | 100.0 | (0.139) | 2.033 0.07 | 100.0 | (0.073) | 3.465 0.11 | 100.0 |
| Poisoned | 0.902 0.59 | 3.589 0.03 | 95.4 3.32 | 0.168 0.17 | 2.031 0.06 | 100.0 2.96 | 0.221 0.14 | 3.387 0.06 | 97.8 3.29 |
| Baselines | |||||||||
| Finetune | 0.767 0.67 | 3.626 0.04 | 96.4 2.80 | 0.281 0.23 | 2.082 0.04 | 102.5 3.52 | 0.823 0.32 | 3.350 0.06 | 96.8 4.03 |
| Forget only | 0.072 0.04 | 0.086 0.14 | 2.2 3.57 | 0.139 0.21 | 0.014 0.02 | 0.7 1.20 | 0.073 0.06 | 0.012 0.01 | 0.3 0.24 |
| Objective | Whole test set | SID neighborhood | ||||
| Retrained | 0.000 0.00 | 3.766 0.13 | 100.0 | 0.000 0.00 | 2.779 1.63 | 100.0 |
| Poisoned | 0.753 0.79 | 3.571 0.09 | 0 94.8 | 4.780 11.03 | 2.420 1.23 | 0 87.1 |
| only | 0.692 0.77 | 3.659 0.06 | 0 97.2 | 3.633 4.84 | 2.954 1.76 | 106.3 |
| 0.021 0.04 | 3.654 0.07 | 0 97.0 | 0.000 0.00 | 2.419 1.44 | 0 87.0 | |
| ( ) | 0.001 0.00 | 3.648 0.05 | 0 96.9 | 0.000 0.00 | 2.428 1.42 | 0 87.4 |
| Method | (%) | |||||
|---|---|---|---|---|---|---|
| Finetune | 14.424 13.461 | 2.948 0.550 | 0.612 0.299 | 3.510 0.162 | 96.3 5.0 | 0.3 |
| Forget only | 9.419 6.109 | 1.990 1.176 | 1.111 0.684 | 3.516 0.183 | 96.4 5.8 | 0.3 |
| Forget+Repair | 12.606 14.899 | 2.543 0.840 | 0.734 0.337 | 3.522 0.168 | 96.6 5.2 | 0.5 |
| SCIF | 15.981 8.902 | 3.303 0.424 | 0.481 0.379 | 3.682 0.139 | 101.0 4.6 | 33.9 |
| SEIF † | 0.000 0.000 | 0.000 0.000 | 2.823 0.474 | 0.030 0.032 | 0.8 0.9 | 0.3 |
| Kookmin † | 1.818 4.066 | 1.230 0.939 | 1.699 1.180 | 2.788 0.179 | 76.5 5.6 | 0.3 |
| Dataset | SID | Retrained / | |||
|---|---|---|---|---|---|
| Beauty | RQ-KMeans | 12.2 9.4 (1/5) | 2.3 2.3 (2/5) | 93.3 95.5 (5/5) | 16.2 / 2.82 |
| Beauty | LETTER | 15.4 10.1 (3/5) | 4.1 4.4 (3/5) | 89.4 89.7 (4/5) | 15.0 / 6.66 |
| Sports | RQ-KMeans | 27.6 11.1 (5/5) | 1.4 0.5 (5/5) | 91.1 92.4 (3/5) | 29.3 / 1.42 |
| Sports | LETTER | 22.0 12.1 (5/5) | 1.4 0.6 (5/5) | 94.2 95.0 (3/5) | 37.1 / 1.91 |
| Toys | RQ-KMeans | 0 5.0 9.7 (0/5) | 2.3 2.4 (3/5) | 92.1 95.1 (5/5) | 18.1 / 3.51 |
| Toys | LETTER | 14.8 9.7 (3/5) | 3.4 2.9 (5/5) | 90.5 93.5 (5/5) | 0 6.6 / 3.44 |
Appendix figures & tables22 assets
Supplementary material from the paper’s appendix.
Appendix
| Dataset | #Users | #Items | #Interactions | Avg. length |
|---|---|---|---|---|
| Beauty | 22,363 | 12,101 | 198,502 | 8.88 |
| Sports | 35,598 | 18,357 | 296,337 | 8.32 |
| Toys | 19,412 | 11,924 | 167,597 | 8.63 |
| Whole set | SID neighborhood | Combined | |||||
|---|---|---|---|---|---|---|---|
| Sel. | |||||||
| 0.0 | 0.0 | 0.112 | 96.9 | 0.678 | 86.5 | 91.7 | |
| 0.0 | 0.01 | 0.089 | 96.7 | 0.863 | 106.6 | 101.7 | |
| 0.0 | 0.1 | 0.094 | 93.7 | 0.874 | 157.9 | 125.8 | |
| 0.01 | 0.0 | 0.086 | 97.0 | 0.879 | 87.6 | 92.3 | |
| 0.01 | 0.01 | 0.086 | 96.9 | 0.874 | 103.6 | 100.2 | ✓ |
| Validation | Test | ||||||
|---|---|---|---|---|---|---|---|
| Dataset | Method | Configuration | Sel. | ||||
| Beauty | Fanchuan | fanchuan_t0.007 | 0.079 | 11.9 | 0.072 | 12.6 | |
| Beauty | Fanchuan | fanchuan_t0.07 | 0.079 | 32.0 | 0.072 | 32.4 | ✓ |
| Beauty | Forget only | unified_abl_lf0.1_ls0.0_ln0.0_lr0.0 | 0.079 | 2.1 | 0.072 | 1.9 | |
| Beauty | Forget only | unified_abl_lf1.0_ls0.0_ln0.0_lr0.0 | 0.079 | 2.7 | 0.072 | 2.5 | ✓ |
| Beauty | Forget+Repair | unified_abl_lf1.0_ls0.0_ln0.0 | 0.079 | 75.8 | 0.072 | 72.8 | |
| Validation | Test | ||||||
| Dataset | Method | Configuration | Sel. | ||||
| Beauty | SCIF | scif_d0.001 | 24.99 | 99.6 | 15.98 | 101.0 | |
| Beauty | SCIF | scif_d0.01 | 24.99 | 99.6 | 15.98 | 101.0 | ✓ |
| Beauty | SCIF | scif_d0.1 | 26.53 | 99.6 | 15.98 | 100.9 | |
| Beauty | SEIF | seif_std0.006 | 15.50 | 60.4 | 10.06 | 63.9 | |
| Beauty | SEIF | seif_std0.06 | 17.04 | 59.2 | 8.25 | 62.0 | |
| Method | (s) | |
|---|---|---|
| Finetune | 0.5 | 0.99997 |
| Forget only | 0.3 | 0.99998 |
| Forget + Repair | 0.7 | 0.99995 |
| SCIF | 35.3 | 0.99774 |
| SEIF | 0.5 | 0.99997 |
| Kookmin | 0.4 | 0.99998 |
| Target | Variant | (%) | (%) | (%) | (s) |
|---|---|---|---|---|---|
| Unpopular | NAU (gen. sep.) | 0.000 0.000 | 3.600 0.119 | 95.8 6.2 | 3.5 |
| NAU (cos. sep.) | 0.000 0.000 | 3.504 0.092 | 93.2 5.4 | 2.9 | |
| NAU | 0.000 0.000 | 3.596 0.115 | 95.6 6.1 | 3.4 | |
| NAU (grid) | 0.000 0.000 | 3.612 0.106 | 96.1 5.8 | 3.7 | |
| Mid | NAU (gen. sep.) | 0.000 0.000 | 3.654 0.041 | 97.1 2.8 | 3.5 |
| NAU (cos. sep.) | 0.000 0.000 | 3.545 0.053 | 94.2 2.3 | 2.9 |
| Target | Method | (%) | (%) | (%) | (%) | (s) |
|---|---|---|---|---|---|---|
| Unpopular | Baselines | |||||
| Finetune | 0.365 0.362 | 0.361 0.362 | 3.206 0.106 | 98.6 2.4 | 0.9 | |
| Forget only | 0.000 0.000 | 0.004 0.008 | 0.166 0.288 | 5.2 9.1 | 0.4 | |
| Forget + Repair | 0.016 0.036 | 0.020 0.035 | 3.196 0.104 | 98.3 2.6 | 0.8 | |
| SCIF | 0.729 1.081 | 0.725 1.082 | 3.203 0.097 | 98.5 1.2 | 35.2 | |
| SEIF | 0.119 0.190 | 0.115 0.182 | 2.267 0.192 | 69.8 6.6 | 0.5 | |
| Target | Method | (%) | (%) | (%) | (%) | (s) |
|---|---|---|---|---|---|---|
| Unpopular | Baselines | |||||
| Finetune | 0.494 0.690 | 0.494 0.690 | 1.719 0.095 | 106.0 8.9 | 1.3 | |
| Forget only | 0.000 0.000 | 0.000 0.000 | 0.085 0.178 | 6.0 12.7 | 0.4 | |
| Forget + Repair | 0.178 0.395 | 0.178 0.395 | 1.710 0.095 | 105.4 9.0 | 1.0 | |
| SCIF | 0.725 1.004 | 0.725 1.004 | 1.658 0.091 | 102.3 10.5 | 34.9 | |
| SEIF | 0.011 0.015 | 0.011 0.015 | 1.001 0.073 | 61.8 6.8 | 0.7 | |
| Target | Method | (%) | (%) | (%) | (%) | (s) |
|---|---|---|---|---|---|---|
| Unpopular | Baselines | |||||
| Finetune | 0.457 0.295 | 0.453 0.294 | 3.009 0.048 | 98.1 3.6 | 0.9 | |
| Forget only | 0.000 0.000 | 0.004 0.009 | 0.048 0.062 | 1.5 1.9 | 0.4 | |
| Forget + Repair | 0.031 0.043 | 0.033 0.042 | 3.005 0.063 | 97.9 3.7 | 1.3 | |
| SCIF | 0.651 0.577 | 0.647 0.579 | 3.034 0.058 | 98.8 2.9 | 34.2 | |
| SEIF | 0.104 0.091 | 0.100 0.088 | 1.984 0.145 | 64.7 5.9 | 0.5 | |
| Target | Method | (%) | (%) | (%) | (%) | (s) |
|---|---|---|---|---|---|---|
| Unpopular | Baselines | |||||
| Finetune | 0.194 0.142 | 0.193 0.142 | 3.823 0.062 | 101.0 5.3 | 0.9 | |
| Forget only | 0.000 0.000 | 0.001 0.002 | 0.011 0.015 | 0.3 0.4 | 0.4 | |
| Forget + Repair | 0.000 0.000 | 0.001 0.002 | 3.778 0.082 | 99.8 5.8 | 1.3 | |
| SCIF | 0.245 0.183 | 0.244 0.182 | 3.764 0.062 | 99.4 3.8 | 40.0 | |
| SEIF | 0.123 0.157 | 0.123 0.156 | 2.684 0.240 | 70.7 3.3 | 0.6 | |
| Target | Method | (%) | (%) | (%) | (%) | (s) |
|---|---|---|---|---|---|---|
| Unpopular | Baselines | |||||
| Finetune | 0.240 0.231 | 0.167 0.204 | 1.992 0.053 | 105.8 7.0 | 1.3 | |
| Forget only | 0.000 0.000 | 0.078 0.105 | 0.011 0.021 | 0.6 1.1 | 0.3 | |
| Forget + Repair | 0.030 0.066 | 0.097 0.100 | 1.976 0.055 | 104.9 7.2 | 1.0 | |
| SCIF | 0.334 0.352 | 0.256 0.345 | 1.946 0.060 | 103.3 6.4 | 34.8 | |
| SEIF | 0.157 0.210 | 0.079 0.106 | 1.206 0.087 | 64.0 6.3 | 0.8 | |
| Target | Method | (%) | (%) | (%) | (%) | (s) |
|---|---|---|---|---|---|---|
| Unpopular | Baselines | |||||
| Finetune | 0.518 0.398 | 0.501 0.415 | 3.374 0.059 | 94.6 3.3 | 0.5 | |
| Forget only | 0.000 0.000 | 0.018 0.034 | 0.000 0.000 | 0.0 0.0 | 0.3 | |
| Forget + Repair | 0.012 0.013 | 0.026 0.031 | 3.391 0.048 | 95.0 2.6 | 1.2 | |
| SCIF | 0.874 0.741 | 0.856 0.759 | 3.411 0.054 | 95.6 2.8 | 39.1 | |
| SEIF | 0.098 0.087 | 0.109 0.072 | 2.124 0.117 | 59.6 4.4 | 0.6 | |
| Target | Method | (%) | (%) | (%) | (%) | (s) |
|---|---|---|---|---|---|---|
| Unpopular | Baselines | |||||
| Finetune | 1.250 0.936 | 1.250 0.936 | 3.700 0.072 | 102.8 3.3 | 0.5 | |
| Forget only | 0.000 0.000 | 0.000 0.000 | 0.020 0.034 | 0.5 0.9 | 0.4 | |
| Forget + Repair | 0.097 0.129 | 0.097 0.129 | 3.701 0.077 | 102.8 3.2 | 0.7 | |
| SCIF | 1.729 1.660 | 1.729 1.660 | 3.649 0.056 | 101.4 3.0 | 39.9 | |
| SEIF | 0.535 0.714 | 0.535 0.714 | 2.607 0.193 | 72.5 5.6 | 0.5 | |
| Whole test set | ||||
|---|---|---|---|---|
| Objective | ||||
| Retrained | 0.067 0.12 | 0.000 | 3.461 0.11 | 100.0 |
| Poisoned | 0.297 0.23 | 0.230 | 3.377 0.06 | 97.6 |
| only | 0.656 0.57 | 0.589 | 3.348 0.03 | 96.7 |
| 0.159 0.23 | 0.092 | 3.345 0.03 | 96.6 | |
| ( ) | 0.113 0.18 | 0.046 | 3.352 0.03 | 96.8 |
| Objective | Removal and utility | Local effect (nats) | ||||
|---|---|---|---|---|---|---|
| only | 0.986 0.947 | 0.914 | 3.630 0.109 | 96.5 3.7 | 1.69 | 0.21 |
| 0.110 0.211 | 0.108 | 3.622 0.118 | 96.3 4.0 | 4.17 | 0.31 | |
| ( ) | 0.000 0.000 | 0.072 | 3.615 0.105 | 96.1 3.9 | 5.57 | 0.17 |
| ( ) | 0.038 0.118 | 0.103 | 3.615 0.111 | 96.1 3.8 | 3.23 † | 0.37 † |
| NAU ( , ) | 0.010 0.034 | 0.081 | 3.621 0.107 | 96.2 3.8 | 3.39 | 0.34 |
| Target | Loss terms | (%) | (%) | (%) | (%) |
|---|---|---|---|---|---|
| Unpopular | only | 0.184 0.231 | 2.082 0.024 | 102.5 3.8 | +0.85 0.50 |
| 0.000 0.000 | 2.065 0.029 | 101.7 4.0 | – | ||
| ( ) | 0.000 0.000 | 2.059 0.026 | 101.4 3.5 | -0.29 0.61 | |
| ( ) | 0.000 0.000 | 2.069 0.041 | 101.9 4.0 | +0.18 1.14 | |
| NAU ( , ) | 0.000 0.000 | 2.063 0.031 | 101.6 3.3 | -0.11 0.83 | |
| NAU at (over-strong dose, cosine sep) | 0.000 0.000 | 2.007 0.049 | 98.8 3.7 | -2.88 1.75 |
| Target | Loss terms | (%) | (%) | (%) | (%) |
|---|---|---|---|---|---|
| Unpopular | only | 1.092 1.290 | 3.342 0.058 | 96.5 3.8 | -0.35 0.41 |
| 0.240 0.255 | 3.354 0.070 | 96.9 4.0 | – | ||
| ( ) | 0.000 0.000 | 3.337 0.056 | 96.4 3.2 | -0.50 0.99 | |
| ( ) | 0.013 0.030 | 3.349 0.065 | 96.7 3.5 | -0.16 0.45 | |
| NAU ( , ) | 0.000 0.000 | 3.347 0.080 | 96.7 4.6 | -0.18 1.02 | |
| NAU at (over-strong dose, cosine sep) | 0.000 0.000 | 3.282 0.053 | 94.8 3.5 | -2.10 1.29 |
| Method | (%) | |||||
|---|---|---|---|---|---|---|
| Finetune † | 29.651 14.035 | 1.602 0.252 | 0.180 0.126 | 1.894 0.066 | 93.0 6.4 | 0.3 |
| Forget only † | 16.606 12.736 | 0.694 0.327 | 0.727 0.358 | 1.915 0.094 | 94.1 8.6 | 0.3 |
| Forget+Repair † | 30.718 10.996 | 1.475 0.338 | 0.221 0.121 | 1.899 0.071 | 93.2 6.7 | 0.5 |
| SCIF | 32.870 16.770 | 1.707 0.385 | 0.334 0.231 | 2.045 0.086 | 100.5 9.4 | 34.5 |
| SEIF † | 0.000 0.000 | 0.000 0.000 | 1.422 0.197 | 0.003 0.005 | 0.1 0.2 | 0.3 |
| Kookmin † | 31.332 14.574 | 1.408 0.295 | 0.126 0.089 | 1.374 0.094 | 67.4 5.4 | 0.3 |
| Method | (%) | |||||
|---|---|---|---|---|---|---|
| Finetune | 6.538 6.940 | 2.854 0.387 | 0.767 0.463 | 3.118 0.077 | 95.1 2.9 | 0.3 |
| Forget only † | 4.872 4.455 | 1.879 0.513 | 1.634 0.404 | 2.945 0.113 | 89.9 5.3 | 0.3 |
| Forget+Repair † | 6.667 9.129 | 2.363 0.289 | 1.149 0.374 | 3.067 0.074 | 93.6 3.4 | 0.5 |
| SCIF | 11.154 7.045 | 2.911 0.195 | 0.602 0.340 | 3.392 0.070 | 103.5 3.7 | 32.9 |
| SEIF † | 0.000 0.000 | 0.021 0.046 | 3.492 0.266 | 0.031 0.029 | 1.0 0.9 | 0.3 |
| Kookmin † | 8.205 8.338 | 2.809 0.612 | 0.774 0.742 | 2.500 0.161 | 76.3 6.2 | 0.3 |
| Dataset | Tokenizer | Level | Distinct prefixes | Unique (%) | Mean nbrs. | Median | P90 | Singletons (%) |
|---|---|---|---|---|---|---|---|---|
| Beauty | RKMeans | 0 | 256 | 2.1 | 82.90 | 74 | 141 | 0.2 |
| 1 | 6,150 | 50.8 | 3.16 | 1 | 8 | 30.6 | ||
| 2 | 10,483 | 86.6 | 0.50 | 0 | 2 | 78.3 | ||
| 3 (dedup) | 12,101 | 100.0 | 0.00 | 0 | 0 | 100.0 | ||
| RQVAE | 0 | 103 | 0.9 | 171.90 | 151 | 297 | 0.0 | |
| 1 | 6,370 | 52.6 | 3.94 | 1 | 10 | 32.7 |
| target | update restricted to | SH@10 | NDCG@10 | |
|---|---|---|---|---|
| unpopular : attack landed on all seeds | ||||
| all parameters (unrestricted) | 0.00000 0.00000 | 0.03586 0.00112 | 0.954 0.059 | |
| levels 3, 4 frozen | 0.00000 | 0.03666 | 0.974 | |
| levels 1, 2 + backbone | 0.00155 0.00326 | 0.03605 0.00127 | 0.959 0.065 | |
| levels 1, 2, 3 + backbone | 0.00140 0.00292 | 0.03604 0.00130 | 0.959 0.065 | |
| levels 1, 2, codes only | 0.00934 0.01058 | 0.03604 0.00103 | 0.958 0.055 | |
Machine Unlearning
Machine unlearning removes the influence of selected data or concepts from trained models while preserving useful behavior and avoiding full retraining.
See all 349 papers