mlsanityData to 7 Oct 2026

Spot Risks Before Speaking! Unraveling Safety Attention Heads in Large Vision-Language Models

arXiv 2501.02029 ↗First posted 3 Jan 2025cs.LG cs.AI cs.CRcited by 7

On the map: Multimodal LLMs / vision-language models → MLLM jailbreaks and adversarial robustness

also in 1 more
Abstract (arXiv)

With the integration of an additional modality, large vision-language models (LVLMs) exhibit greater vulnerability to safety risks (e.g., jailbreaking) compared to their language-only predecessors. Although recent studies have devoted considerable effort to the post-hoc alignment of LVLMs, the inner safety mechanisms remain largely unexplored. In this paper, we discover that internal activations of LVLMs during the first token generation can effectively identify malicious prompts across different attacks. This inherent safety perception is governed by sparse attention heads, which we term ``safety heads." Further analysis reveals that these heads act as specialized shields against malicious prompts; ablating them leads to higher attack success rates, while the model's utility remains unaffected. By locating these safety heads and concatenating their activations, we construct a straightforward but powerful malicious prompt detector that integrates seamlessly into the generation process with minimal extra inference overhead. Despite its simple structure of a logistic regression model, the detector surprisingly exhibits strong zero-shot generalization capabilities. Experiments across various prompt-based attacks confirm the effectiveness of leveraging safety heads to protect LVLMs. Code is available at urlhttps://github.com/Ziwei-Zheng/SAHs.

Key facts. Cited by 7 papers in the map (data through 7 Oct 2026). Placed in MLLM jailbreaks and adversarial robustness, one of 16 directions in Multimodal LLMs / vision-language models. Builds on 35 of its 47 references that are in the map. First posted on arXiv 3 Jan 2025.

Builds on

35 of 47 references.

Closest ancestors · 11

Same direction, newest first

  1. 2024MultiTrust: A Comprehensive Benchmark Towards Trustworthy Multimodal Large Language Models11 Jun
  2. 2024JailBreakV: A Benchmark for Assessing the Robustness of MultiModal Large Language Models against Jailbreak Attacks3 Apr
  3. 2024Safety of Multimodal Large Language Models on Images and Texts1 Feb
  4. 2024Red Teaming Visual Language Models23 Jan
  5. 2024MLLM-Protector: Ensuring MLLM's Safety without Hurting Performance5 Jan
  6. 2023MM-SafetyBench: A Benchmark for Safety Evaluation of Multimodal Large Language Models29 Nov
  7. 2023FigStep: Jailbreaking Large Vision-Language Models via Typographic Visual Prompts9 Nov
  8. 2023How Robust is Google's Bard to Adversarial Image Attacks?21 Sep
  9. 2023Jailbreak in pieces: Compositional Adversarial Attacks on Multi-Modal Language Models26 Jul
  10. 2023Abusing Images and Sounds for Indirect Instruction Injection in Multi-Modal LLMs19 Jul
  11. 2023Visual Adversarial Examples Jailbreak Aligned Large Language Models22 Jun

Other references · 24

  1. 2023GPT-4 Technical Reportcited by 18,132
  2. 2024The Llama 3 Herd of Modelscited by 14,192
  3. 2023LLaMA: Open and Efficient Foundation Language Modelscited by 13,958
  4. 2023Llama 2: Open Foundation and Fine-Tuned Chat Modelscited by 12,865
  5. 2023Visual Instruction Tuningcited by 7,792
  6. 2022Flamingo: a Visual Language Model for Few-Shot Learningcited by 4,337
  7. 2023InstructBLIP: Towards General-purpose Vision-Language Models with Instruction Tuningcited by 2,855
  8. 2023Qwen-VL: A Versatile Vision-Language Model for Understanding, Localization, Text Reading, and Beyondcited by 2,179
  9. 2016Understanding intermediate layers using linear classifier probescited by 1,279
  10. 2023MM-Vet: Evaluating Large Multimodal Models for Integrated Capabilitiescited by 1,221
  11. 2019BERT Rediscovers the Classical NLP Pipelinecited by 1,046
  12. 2023ShareGPT4V: Improving Large Multi-Modal Models with Better Captionscited by 1,000
12 more
  1. 2016Bag of Tricks for Efficient Text Classificationcited by 869
  2. 2023The Linear Representation Hypothesis and the Geometry of Large Language Modelscited by 679
  3. 2023MiniGPT-v2: large language model as a unified interface for vision-language multi-task learningcited by 617
  4. 2023mPLUG-Owl2: Revolutionizing Multi-modal Large Language Model with Modality Collaborationcited by 545
  5. 2023Emergent Linear Representations in World Models of Self-Supervised Sequence Modelscited by 313
  6. 2023Image Hijacks: Adversarial Images can Control Generative Models at Runtimecited by 165
  7. 2024Jailbreaking Attack against Multimodal Large Language Modelcited by 128
  8. 2023Mixture of Cluster-conditional LoRA Experts for Vision-language Instruction Tuningcited by 106
  9. 2023How Many Unicorns Are in This Image? A Safety Evaluation Benchmark for Vision LLMscited by 103
  10. 2023DRESS: Instructing Large Vision-Language Models to Align and Interact with Humans via Natural Language Feedbackcited by 99
  11. 2023Jailbreaking GPT-4V via Self-Adversarial Attacks with System Promptscited by 62
  12. 2023Misusing Tools in Large Language Models With Visual Adversarial Examplescited by 40

Built on by

Cited by year (2026 to 7 Oct)

Citing papers per year: 2025: 2; 2026: 5.

7 papers.

Similar, not cited

Close in wording, no citation either way

  1. 2025The Safety Reminder: A Soft Prompt to Reactivate Delayed Safety Awareness in Vision-Language Models
  2. 2025HiddenDetect: Detecting Jailbreak Attacks against Large Vision-Language Models via Monitoring Hidden States
  3. 2025Safety Alignment Should Be Made More Than Just A Few Attention Heads
  4. 2026Seeing No Evil: Blinding Large Vision-Language Models to Safety Instructions via Adversarial Attention Hijacking
  5. 2025Seeing the Threat: Vulnerabilities in Vision-Language Models to Adversarial Attack
  6. 2025A Survey of Safety on Large Vision-Language Models: Attacks, Defenses and Evaluations
  7. 2026Attention Is Where You Attack
  8. 2026Risk Awareness Injection: Calibrating Vision-Language Models for Safety without Compromising Utility