cs.LGAug 24, 2026

ST2^2U: Stateful Test-Time Unlearning via Restricted Knowledge Boundary Control

Authors: Xunlei Chen, Qinghui Gong, Ruini Xue, Yaodong Hu, Tian Lan, Wenhong Tian

Organizations: University of Electronic Science and Technology of China · Southwest Jiaotong University

Abstract

Controlling restricted knowledge in large language models is essential for model alignment and safe deployment. Test-time unlearning avoids costly retraining and parameter updates by intervening only during inference. However, existing activation-editing methods apply isolated pointwise corrections, overlooking how autoregressive generation continually reconstructs hidden states from the prompt, cache, and generated prefix. Consequently, later states may return to restricted knowledge regions after a locally successful correction, causing restricted knowledge re-entry. In this work, we propose Stateful Test-Time Unlearning via restricted knowledge boundary control (ST2^2U), which formulates test-time unlearning as trajectory-wide boundary control. ST2^2U first models restricted knowledge boundaries in low-dimensional invertible coordinates while leaving orthogonal non-target components unchanged. During inference, ST2^2U monitors risk along the trajectory, applies minimal boundary corrections with contextual anchoring, and propagates historical correction states across tokens to mitigate knowledge re-entry. This trajectory-wide control enables more persistent forgetting while preserving non-target capabilities and limiting inference overhead. Across three benchmarks and three model families, ST2^2U delivers the strongest overall balance, combining best or second-best retention with competitive forgetting and substantially less restricted-knowledge re-entry than test-time baselines (13.76%-19.84% versus 46.50%-59.10%).

Figures & tables

Explore similar work

CardsList
  1. Test-Time Unlearning via Sparse Autoencoder

    Sep 14, 2026Pingzhi Li, Jinhao Duan, Vaishnav Tadiparthi +6Machine UnlearningLLM Unlearning

  2. Attention Smoothing Is All You Need For Unlearning

    Mar 1, 2026Saleh Zare Zade, Xiangyu Zhou, Sijia Liu +1Machine UnlearningLLM Unlearning

  3. Not Every Change Is Necessary: Recoverable Drift in Large Language Model Unlearning

    Oct 8, 2026Xunlei Chen, Qinghui Gong, Jingkun Xue +3Machine UnlearningLLM Unlearning