SHIELD: Classifier-Guided Prompting for Robust and Safer LVLMs
Juan Ren, Mark Dras, Usman Naseem
TL;DR
SHIELD addresses the safety vulnerabilities of Large Vision-Language Models (LVLMs) by introducing a classifier-guided, preprocessing framework that links fine-grained safety categories to explicit actions (Block, Reframe, Forward) and category-specific prompts. It is model-agnostic and does not require retraining, enabling seamless deployment across diverse LVLMs. The approach combines a 45-category taxonomy with Do/Don’t instructions and priority-based policy decisions, producing a composed prompt that steers the model toward safe and useful responses. Through extensive experiments on five datasets and five LVLMs, SHIELD consistently reduces jailbreak and non-following rates while preserving utility, with ablations highlighting the importance of specialized prompts and explicit actions and showing robustness to classifier choice. The work demonstrates a practical safety patch for LVLMs, particularly beneficial for under-aligned models and edge deployments, and suggests avenues for expanding rule coverage and integrating with output-time safeguards.
Abstract
Large Vision-Language Models (LVLMs) unlock powerful multimodal reasoning but also expand the attack surface, particularly through adversarial inputs that conceal harmful goals in benign prompts. We propose SHIELD, a lightweight, model-agnostic preprocessing framework that couples fine-grained safety classification with category-specific guidance and explicit actions (Block, Reframe, Forward). Unlike binary moderators, SHIELD composes tailored safety prompts that enforce nuanced refusals or safe redirection without retraining. Across five benchmarks and five representative LVLMs, SHIELD consistently lowers jailbreak and non-following rates while preserving utility. Our method is plug-and-play, incurs negligible overhead, and is easily extendable to new attack types -- serving as a practical safety patch for both weakly and strongly aligned LVLMs.
