Skip to content

SLAE: Sparse Locality-Aware Editing for Safety-Aligned MLLMs

Jiaqing Li, Shide Zhou, Tianlong Yu, Kailong Wang

cs.CR

Abstract

Multimodal large language models (MLLMs) gain powerful visual perception, but the additional modality also expands their attack surface. Recent studies reveal a particularly severe failure: a model that rejects an explicitly harmful request may comply when a benign query is paired with harmful visual content. This discrepancy suggests that text-centered safeguards do not reliably transfer to visually grounded harm. However, its internal cause remains poorly understood, and existing defenses provide limited targeted control. We trace this failure to sparse MLP neurons and find that the neurons responsible for visually grounded safety overlap only weakly with those supporting text-triggered refusal. Motivated by this observation, we propose Sparse Locality-Aware Editing for Safety-Aligned MLLMs (SLAE), a neuron-to-column editing method that strengthens visual safety while preserving benign capabilities. For each attack case, SLAE contrasts neuron contributions to unsafe compliance and safe refusal, retains the top-k neurons, and identifies cross-case importance by recurrence frequency rather than absolute attribution magnitude. Neurons repeatedly important for benign visual grounding are excluded from editing. SLAE then learns sparse offsets for the down-projection columns corresponding to the retained neurons and merges them into the original weights. Experiments on representative MLLMs show that SLAE substantially improves resistance to visually concealed harmful requests while maintaining benign question answering and general utility.

Create a lesson