跳到正文
arXiv:cs.LG· Xin Chen, Gil Kur, Alexander Shevchenko, Andreas Krause·· 7 小时前AI 评分44

局部稀疏性实现无监督 LLM 安全检测

Local Sparsity Enables Unsupervised LLM Safety Detection

AI 导读

研究者提出基于局部稀疏性的 SAE 异常检测框架,无需不安全训练数据即可在部署时检测 LLM 安全问题。该方法在多种架构和数据集上验证,仅用 1-2% 的 SAE 神经元完成计算;当允许使用 1% 的分布外数据校准时,达到接近最优的性能。论文已被 NeurIPS2026 接收。

正文

View PDF HTML (experimental)

Abstract:Deployment-time safety methods for large language models (LLMs) are predominantly supervised and assume access to unsafe training data. Nevertheless, new attacks and harm categories regularly arise, not captured by models trained in such a supervised fashion. An alternative approach is to view this problem through the lens of anomaly detection, namely, to rely solely on modeling safe data and flagging out-of-distribution inputs. However, LLM activations lie in a high-dimensional space, raising concerns about whether anomaly detection is statistically feasible. We show that, under the linear representation hypothesis (LRH), there may indeed be hope. In the LRH concept space, which is typically recovered via a sparse autoencoder (SAE), nearby points share a small common active support. Using this local sparsity insight, we propose a framework for locally masked SAE-based anomaly detection, supported by theoretical justifications. We validate it on various architectures and datasets, including both capability-testing datasets and safety-specific datasets. Finally, when we allow algorithms to use 1% out-of-distribution data for calibration, locally sparse methods achieve near-optimal performance, demonstrating their ability to capture meaningful safety information while using only 1-2% of SAE neurons for computation.
Comments: Published at NeurIPS2026
Subjects: Machine Learning (cs.LG); Artificial Intelligence (cs.AI)
Cite as: arXiv:2609.20129 [cs.LG]
  (or arXiv:2609.20129v2 [cs.LG] for this version)
  https://doi.org/10.48550/arXiv.2609.20129

arXiv-issued DOI via DataCite

Submission history

From: Xin Chen [view email]
[v1] Thu, 17 Sep 2026 12:23:04 UTC (461 KB)
[v2] Mon, 5 Oct 2026 18:05:40 UTC (455 KB)

来源:arXiv:cs.LG · arxiv.org