mlsanityData to 14 Oct 2026

Safety Subspaces are Not Linearly Distinct: A Fine-Tuning Case Study

arXiv 2505.14185 ↗First posted 20 May 2025cs.LG cs.AI cs.CLcited by 6

On the map: LLM alignment / RLHF / preference optimisation → Safety alignment and jailbreak attacks

also in 1 more
Abstract (arXiv)

Large Language Models (LLMs) rely on safety alignment to produce socially acceptable responses. However, this behavior is known to be brittle: further fine-tuning, even on benign or lightly contaminated data, can degrade safety and reintroduce harmful behaviors. A growing body of work suggests that alignment may correspond to identifiable directions in weight space, forming subspaces that could, in principle, be isolated or preserved to defend against misalignment. In this work, we conduct a comprehensive empirical study of this perspective. We examine whether safety-relevant behavior is concentrated in specific linear subspaces, whether it can be separated from general-purpose learning, and whether harmfulness arises from distinguishable patterns in activations. Across both weight and activation spaces, our findings are consistent: subspaces that amplify safe behaviors also amplify useful ones, and prompts with different safety implications activate overlapping representations. Rather than residing in distinct directions, we show that safety is highly entangled with the general learning components of the model. This suggests that subspace-based defenses face fundamental limitations and underscores the need for alternative strategies to preserve safety under continued training. We corroborate these findings with multiple experiments on five open-source LLMs from the Llama and Qwen families. Our code is publicly available at: https://github.com/CERT-Lab/safety-subspaces.

Key facts. Cited by 6 papers in the map (data through 14 Oct 2026). Placed in Safety alignment and jailbreak attacks, one of 10 directions in LLM alignment / RLHF / preference optimisation. Builds on 65 of its 81 references that are in the map. First posted on arXiv 20 May 2025.

Builds on

65 of 81 references.

Closest ancestors · 24

Same direction, newest first

  1. 2025SafeMERGE: Preserving Safety Alignment in Fine-Tuned Large Language Models via Selective Layer-Wise Model Merging21 Mar
  2. 2025Why Safeguarded Ships Run Aground? Aligned Large Language Models' Safety Mechanisms Tend to Be Anchored in The Template Region19 Feb
  3. 2025The Hidden Dimensions of LLM Alignment: A Multi-Dimensional Analysis of Orthogonal Safety Directions13 Feb
  4. 2025Virus: Harmful Fine-tuning Attack for Large Language Models Bypassing Guardrail Moderation29 Jan
  5. 2024NLSR: Neuron-Level Safety Realignment of Large Language Models Against Harmful Fine-Tuning17 Dec
  6. 2024Separate the Wheat from the Chaff: A Post-Hoc Approach to Safety Re-Alignment for Fine-Tuned Language Models15 Dec
  7. 2024Targeted Vaccine: Safety Alignment for Large Language Models against Harmful Fine-Tuning via Layer-wise Perturbation13 Oct
  8. 2024Harmful Fine-tuning Attacks and Defenses for Large Language Models: A Survey26 Sep
  9. 2024Safety Layers in Aligned Large Language Models: The Key to LLM Security30 Aug
  10. 2024Antidote: Post-fine-tuning Safety Alignment for Large Language Models against Harmful Fine-tuning18 Aug
  11. 2024PKU-SafeRLHF: Towards Multi-Level Safety Alignment for LLMs with Human Preference20 Jun
  12. 2024Do as I do (Safely): Mitigating Task-Specific Fine-tuning Risks in Large Language Models12 Jun
12 more
  1. 2024Safety Alignment Should Be Made More Than Just a Few Tokens Deep10 Jun
  2. 2024Lisa: Lazy Safety Alignment for Large Language Models against Harmful Fine-tuning Attack28 May
  3. 2024Navigating the Safety Landscape: Measuring Risks in Finetuning Large Language Models27 May
  4. 2024Robustifying Safety-Aligned Large Language Models through Clean Data Curation24 May
  5. 2024Language Models are Homer Simpson! Safety Re-Alignment of Fine-tuned Language Models through Task Arithmetic19 Feb
  6. 2024Assessing the Brittleness of Safety Alignment via Pruning and Low-Rank Modifications7 Feb
  7. 2023Removing RLHF Protections in GPT-4 via Fine-Tuning9 Nov
  8. 2023LoRA Fine-tuning Efficiently Undoes Safety Training in Llama 2-Chat 70B31 Oct
  9. 2023Fine-tuning Aligned Language Models Compromises Safety, Even When Users Do Not Intend To!5 Oct
  10. 2023Shadow Alignment: The Ease of Subverting Safely-Aligned Language Models4 Oct
  11. 2023Universal and Transferable Adversarial Attacks on Aligned Language Models27 Jul
  12. 2023BeaverTails: Towards Improved Safety Alignment of LLM via a Human-Preference Dataset10 Jul

Other references · 41

  1. 2021Learning Transferable Visual Models From Natural Language Supervisioncited by 33,744
  2. 2019PyTorch: An Imperative Style, High-Performance Deep Learning Librarycited by 20,305
  3. 2023GPT-4 Technical Reportcited by 18,396
  4. 2022Training language models to follow instructions with human feedbackcited by 15,971
  5. 2017Proximal Policy Optimization Algorithmscited by 15,215
  6. 2024The Llama 3 Herd of Modelscited by 14,715
  7. 2023Llama 2: Open Foundation and Fine-Tuned Chat Modelscited by 13,028
  8. 2021Training Verifiers to Solve Math Word Problemscited by 10,109
  9. 2023Direct Preference Optimization: Your Language Model is Secretly a Reward Modelcited by 8,065
  10. 2020Measuring Massive Multitask Language Understandingcited by 7,963
  11. 2021Measuring Mathematical Problem Solving With the MATH Datasetcited by 5,371
  12. 2024Qwen2.5 Technical Reportcited by 4,942
29 more
  1. 2024GPT-4o System Cardcited by 4,588
  2. 2021Finetuned Language Models Are Zero-Shot Learnerscited by 3,780
  3. 2025Gemma 3 Technical Reportcited by 1,824
  4. 2022Editing Models with Task Arithmeticcited by 1,120
  5. 2024Refusal in Language Models Is Mediated by a Single Directioncited by 1,032
  6. 2023MetaMath: Bootstrap Your Own Mathematical Questions for Large Language Modelscited by 735
  7. 2023XSTest: A Test Suite for Identifying Exaggerated Safety Behaviours in Large Language Modelscited by 505
  8. 2022ToxiGen: A Large-Scale Machine-Generated Dataset for Adversarial and Implicit Hate Speech Detectioncited by 422
  9. 2023Safety-Tuned LLaMAs: Lessons From Improving the Safety of Large Language Models that Follow Instructionscited by 387
  10. 2024Programming Refusal with Conditional Activation Steeringcited by 206
  11. 2024Tamper-Resistant Safeguards for Open-Weight LLMscited by 138
  12. 2024Safe LoRA: the Silver Lining of Reducing Safety Risks when Fine-tuning Large Language Modelscited by 125
  13. 2024What is in Your Safe Data? Identifying Benign Data that Breaks Safetycited by 118
  14. 2024Keeping LLMs Aligned After Fine-tuning: The Crucial Role of Prompt Templatescited by 96
  15. 2024Representation Noising: A Defence Mechanism Against Harmful Finetuningcited by 96
  16. 2024Booster: Tackling Harmful Fine-tuning for Large Language Models via Attenuating Harmful Perturbationcited by 92
  17. 2024SEAL: Safety-enhanced Aligned LLM Fine-tuning via Bilevel Data Selectioncited by 64
  18. 2024What Makes and Breaks Safety Fine-tuning? A Mechanistic Studycited by 55
  19. 2025SaLoRA: Safety-Alignment Preserved Low-Rank Adaptationcited by 42
  20. 2024A safety realignment framework via subspace-oriented model fusion for large language modelscited by 41
  21. 2024Safety-Aware Fine-Tuning of Large Language Modelscited by 34
  22. 2024Towards Understanding the Fragility of Multilingual LLMs against Fine-Tuning Attackscited by 33
  23. 2024Mitigating Fine-tuning based Jailbreak Attack with Backdoor Enhanced Safety Alignmentcited by 31
  24. 2024Bi-Factorial Preference Optimization: Balancing Safety-Helpfulness in Language Modelscited by 27
  25. 2023Language Model Unalignment: Parametric Red-Teaming to Expose Hidden Harms and Biasescited by 24
  26. 2024Locking Down the Finetuned LLMs Safetycited by 22
  27. 2025Panacea: Mitigating Harmful Fine-tuning for Large Language Models via Post-fine-tuning Perturbationcited by 20
  28. 2024The effect of fine-tuning on language model toxicitycited by 16
  29. 2025No, of Course I Can! Deeper Fine-Tuning Attacks That Bypass Token-Level Safety Mechanismscited by 6

Built on by

Cited by year (2026 to 14 Oct)

Citing papers per year: 2026: 6.

6 papers.

Similar, not cited

Close in wording, no citation either way

  1. 2025The Blessing and Curse of Dimensionality in Safety Alignment
  2. 2025The Geometry of Harmfulness in LLMs through Subconcept Probing
  3. 2024Towards Understanding Safety Alignment: A Mechanistic Perspective from Safety Neurons
  4. 2025A Guardrail for Safety Preservation: When Safety-Sensitive Subspace Meets Harmful-Resistant Null-Space
  5. 2026Understanding and Preserving Safety in Fine-Tuned LLMs
  6. 2025Interpretable Safety Alignment via SAE-Constructed Low-Rank Subspace Adaptation
  7. 2026DANGERLENS: Probing Dangerous Representations Hidden by Safety Alignment
  8. 2026Preventing Safety Drift in Large Language Models via Coupled Weight and Activation Constraints