Safety Arithmetic: A Framework for Test-time Safety Alignment of Language Models by Steering Parameters and Activations
Rima Hazra, Sayan Layek, Somnath Banerjee, Soujanya Poria

TL;DR
Safety Arithmetic is a training-free framework that improves large language model safety by steering parameters and activations, effectively reducing harmful outputs while maintaining utility across various model types.
Contribution
It introduces a novel, training-free safety alignment method applicable to multiple LLMs, addressing dynamic user intentions and complex safety objectives.
Findings
Significantly enhances safety measures in LLMs
Reduces over-safety and harmful content generation
Maintains model utility and performance
Abstract
Ensuring the safe alignment of large language models (LLMs) with human values is critical as they become integral to applications like translation and question answering. Current alignment methods struggle with dynamic user intentions and complex objectives, making models vulnerable to generating harmful content. We propose Safety Arithmetic, a training-free framework enhancing LLM safety across different scenarios: Base models, Supervised fine-tuned models (SFT), and Edited models. Safety Arithmetic involves Harm Direction Removal to avoid harmful content and Safety Alignment to promote safe responses. Additionally, we present NoIntentEdit, a dataset highlighting edit instances that could compromise model safety if used unintentionally. Our experiments show that Safety Arithmetic significantly improves safety measures, reduces over-safety, and maintains model utility, outperforming…
Peer Reviews
No public reviews on file for this paper yet. If you reviewed it on a platform where reviews are public (OpenReview, ICLR, NeurIPS, ICML), you can paste yours below so the community can read it here.
Code & Models
Videos
Taxonomy
TopicsSoftware Reliability and Analysis Research · Safety Systems Engineering in Autonomy · Risk and Safety Analysis
MethodsBalanced Selection
