cs.LGMar 6, 2026

Safe Transformer: An Explicit Safety Bit For Interpretable And Controllable Alignment

Authors: Jingyuan Feng, Andrew Gambardella, Gouki Minegishi, Takeshi Kojima, Yusuke Iwasawa, Yutaka Matsuo

Organizations: The University of Tokyo.

Abstract

Current safety alignment methods encode safe behavior implicitly within model parameters, creating a fundamental opacity: we cannot easily inspect why a model refuses a request, nor intervene when its safety judgments fail. We propose Safe Transformer, a modular approach that augments pre-trained language models by inserting a discrete information bottleneck containing an explicit safety bit between transformer layers. The safety bit serves as both an interpretable signal of the model's safety classification and a controllable switch: through contrastive training, the model learns disentangled representations where the safety bit governs the behavioral mode - producing helpful responses when s=1s=1 and refusals when s=0s=0 - while additional unsupervised bits uu encode semantic content for generation. Additional unsupervised bits in the information bottleneck allow semantic information to flow through, preserving the model's generation capabilities. This design achieves both interpretability (the safety decision is directly readable) and controllability (the safety bit can be manually overridden), requiring only lightweight fine-tuning without pre-training from scratch. In red-team benchmarks, Safe Transformer achieves near-zero Attack Success Rate, substantially outperforming base models and safety fine-tuning baselines.

Figures & tables

Appendix figures & tables11 assets

Supplementary material from the paper’s appendix.

Appendix

Explore similar work

CardsList
  1. MOSAIC: Composable Safety Alignment with Modular Control Tokens

    Mar 17, 2026Jingyu Peng, Hongyu Chen, Jiancheng Dong +5LLM Safety AlignmentInference-Time Language Model Alignment

  2. Internalizing Safety Understanding in Large Reasoning Models via Verification

    May 9, 2026Yi Zhang, Yuxin Chen, Leheng Sheng +4LLM Safety AlignmentLLM Safety

  3. SafeEvo: Deciphering the Safety Alignment Mechanism and Evolution in Language Models

    Oct 7, 2026Miao Yu, Hao Huang, Lu Yuan +3Refusal Mechanisms in Language ModelsLLM Safety Alignment