Lune

ICLR2024Top-tier venue

Safety-Tuned LLaMAs: Lessons From Improving the Safety of Large Language Models that Follow Instructions

Federico Bianchi, Mirac Suzgun, Giuseppe Attanasio, Paul Röttger, Dan Jurafsky, Tatsunori Hashimoto, James Zou

Abstract

Training large language models to follow instructions makes them perform better on a wide range of tasks and generally become more helpful. However, a perfectly helpful model will follow even the most malicious instructions and readily generate harmful content. In this paper, we raise concerns over the safety of models that only emphasize helpfulness, not harmlessness, in their instruction-tuning. We show that several popular instruction-tuned models are highly unsafe. Moreover, we show that adding just 3% safety examples (a few hundred demonstrations) when fine-tuning a model like LLaMA can substantially improve its safety. Our safety-tuning does not make models significantly less capable or helpful as measured by standard benchmarks. However, we do find exaggerated safety behaviours, where too much safety-tuning makes models refuse perfectly safe prompts if they superficially resemble unsafe ones. As a whole, our results illustrate trade-offs in training LLMs to be helpful and training them to be safe.

Ask Lune

Know this paper in minutes, not an afternoon.

Lune can read every page of it and the top-tier papers that cite it, and gives you its claims, its evidence and its limits, each one cited to the paper it comes from. No skimming, no AI slop.

135 top-tier papers have cited it since. Know what they found before your reviewers do.

Questions to start from

Lune can draw on

the full paper · the top-tier papers that cite it · related work

Get the answer

Free to start. No credit card required.

Lineage

  • GPT-4 Is Too Smart To Be Safe: Stealthy Chat with LLMs via Cipher cites RealToxicityPrompts: Evaluating Neural Toxic Degeneration in Language Models
  • GPT-4 Is Too Smart To Be Safe: Stealthy Chat with LLMs via Cipher cites Training language models to follow instructions with human feedback
  • QLoRA: Efficient Finetuning of Quantized LLMs cites LoRA: Low-Rank Adaptation of Large Language Models
  • QLoRA: Efficient Finetuning of Quantized LLMs cites Training language models to follow instructions with human feedback
  • In-context Vectors: Making In Context Learning More Effective and Controllable Through Latent Space Steering cites LoRA: Low-Rank Adaptation of Large Language Models
  • In-context Vectors: Making In Context Learning More Effective and Controllable Through Latent Space Steering cites RealToxicityPrompts: Evaluating Neural Toxic Degeneration in Language Models
  • Safe LoRA: The Silver Lining of Reducing Safety Risks when Finetuning Large Language Models cites GPT-4 Is Too Smart To Be Safe: Stealthy Chat with LLMs via Cipher
  • Safe LoRA: The Silver Lining of Reducing Safety Risks when Finetuning Large Language Models cites LoRA: Low-Rank Adaptation of Large Language Models
  • Safe LoRA: The Silver Lining of Reducing Safety Risks when Finetuning Large Language Models cites Fine-tuning Aligned Language Models Compromises Safety, Even When Users Do Not Intend To!
  • Safe LoRA: The Silver Lining of Reducing Safety Risks when Finetuning Large Language Models cites Training language models to follow instructions with human feedback
  • Fine-tuning Aligned Language Models Compromises Safety, Even When Users Do Not Intend To! cites RealToxicityPrompts: Evaluating Neural Toxic Degeneration in Language Models
  • Fine-tuning Aligned Language Models Compromises Safety, Even When Users Do Not Intend To! cites Training language models to follow instructions with human feedback
  • WildTeaming at Scale: From In-the-Wild Jailbreaks to (Adversarially) Safer Language Models cites GPT-4 Is Too Smart To Be Safe: Stealthy Chat with LLMs via Cipher
  • WildTeaming at Scale: From In-the-Wild Jailbreaks to (Adversarially) Safer Language Models cites Fine-tuning Aligned Language Models Compromises Safety, Even When Users Do Not Intend To!
  • Training language models to follow instructions with human feedback cites RealToxicityPrompts: Evaluating Neural Toxic Degeneration in Language Models
Builds onCited byLeft to right by year; the more cited, the higher.

Cited by top-tier papers135

  1. Fine-tuning Aligned Language Models Compromises Safety, Even When Users Do Not Intend To!Xiangyu Qi, Yi Zeng, Tinghao Xie, Pin-Yu Chen et al.ICLR 2024 · 1,104 citations
  2. GPT-4 Is Too Smart To Be Safe: Stealthy Chat with LLMs via CipherYouliang Yuan, Wenxiang Jiao, Wenxuan Wang, Jen-tse Huang et al.ICLR 2024 · 441 citations
  3. WildTeaming at Scale: From In-the-Wild Jailbreaks to (Adversarially) Safer Language ModelsLiwei Jiang, Kavel Rao, Seungju Han, Allyson Ettinger et al.NeurIPS 2024 · 247 citations
  4. In-context Vectors: Making In Context Learning More Effective and Controllable Through Latent Space SteeringSheng Liu, Haotian Ye, Lei Xing, James Y. ZouICML 2024 · 244 citations
  5. Safe LoRA: The Silver Lining of Reducing Safety Risks when Finetuning Large Language ModelsChia-Yi Hsu, Yu-Lin Tsai, Chih-Hsun Lin, Pin-Yu Chen et al.NeurIPS 2024 · 165 citations

Builds on11

  1. Training language models to follow instructions with human feedbackLong Ouyang, Jeffrey Wu, Xu Jiang, Diogo Almeida et al.NeurIPS 2022 · 24,707 citations
  2. LoRA: Low-Rank Adaptation of Large Language ModelsEdward J. Hu, Yelong Shen, Phillip Wallis, Zeyuan Allen-Zhu et al.ICLR 2022 · 18,833 citations
  3. QLoRA: Efficient Finetuning of Quantized LLMsTim Dettmers, Artidoro Pagnoni, Ari Holtzman, Luke ZettlemoyerNeurIPS 2023 · 5,863 citations
  4. PIQA: Reasoning about Physical Commonsense in Natural LanguageYonatan Bisk, Rowan Zellers, Ronan Le Bras, Jianfeng Gao et al.AAAI 2020 · 2,916 citations
  5. RealToxicityPrompts: Evaluating Neural Toxic Degeneration in Language ModelsSamuel Gehman, Suchin Gururangan, Maarten Sap, Yejin Choi et al.EMNLP Findings 2020 · 692 citations

Related papers

  1. ToolSafety: A Comprehensive Dataset for Enhancing Safety in LLM-Based Agent Tool InvocationsYuejin Xie, Youliang Yuan, Wenxuan Wang, Fan Mo et al.EMNLP 2025 · 7 citations
  2. Revealing the Inherent Instructability of Pre-Trained Language ModelsSeokhyun An, Minji Kim, Hyounghun KimEMNLP Findings 2025 · 1 citation
  3. Safety Fine-Tuning at (Almost) No Cost: A Baseline for Vision Large Language ModelsYongshuo Zong, Ondrej Bohdal, Tingyang Yu, Yongxin Yang et al.ICML 2024 · 140 citations
  4. From Representational Harms to Quality-of-Service Harms: A Case Study on Llama 2 Safety SafeguardsKhaoula Chehbouni, Megha Roshan, Emmanuel Ma, Futian Andrew Wei et al.ACL Findings 2024 · 7 citations
  5. The Heterogeneous Safety Impacts of Benign Multilingual Fine-TuningWill Hawkins, Kai Rawal, Jonathan Rystrøm, Stratis Tsirtsis et al.ICML 2026
Dusk over the sea between two cliffs drawn in fine vertical lines