Meta’s Llama Guard 3 Vision reaches 0.938 F1 (0.016 false-positive rate) on multimodal response classification compared to 0.667 F1 (0.243 FPR) for zero-shot GPT-4o, while scoring 0.733 F1 (0.052 FPR) on multimodal prompt classification. Jianfeng Chi, Ujjwal Karn, Hongyuan Zhan, Eric Smith, and colleagues (GenAI at Meta, 2024) show that moderating the text answer conditioned on the prompt image is both dramatically cleaner and far more resistant to image-based attacks than filtering raw prompt inputs alone.

Built on Llama 3.2 11B Vision across the 13 MLCommons hazard categories, the classifier turns visual ambiguity and adversarial perturbations from abstract concerns into concrete architectural trade-offs for multimodal pipelines.

  • Response moderation cuts false positives 15x over GPT-4o: on Meta’s internal benchmark, Llama Guard 3 Vision achieves 0.961 precision, 0.916 recall, 0.938 F1, and 0.016 FPR on responses, versus GPT-4o (0.667 F1, 0.243 FPR) and GPT-4o mini (0.641 F1, 0.313 FPR).
  • Prompt classification suffers from visual ambiguity: precision stays strong (0.891, 0.052 FPR) but recall drops to 0.623 (0.733 F1) because a vague query like "how do I buy this" paired with a multi-object image is hard to judge until the assistant answers.
  • Category F1 stays above 0.69 across all 13 hazards: response F1 peaks on Indiscriminate Weapons (0.995), Defamation (0.967), Elections (0.957), and Sexual Content (0.947), with lower scores on Child Exploitation (0.698) and Specialized Advice (0.764).
  • Response mode resists prompt-side white-box attacks: an 8/255 PGD image perturbation pushes prompt misclassification from 21% to 70% (82% at 128/255), whereas response misclassification climbs only from 6% to 22% (27% at 128/255 and 255/255).
Internal benchmark comparison across MLCommons 13-hazard moderation
Task & ModelPrecision (↑)Recall (↑)F1 (↑)FPR (↓)
Prompt: Llama Guard 3 Vision0.8910.6230.7330.052
Prompt: GPT-4o (zero-shot)0.5440.8430.6610.485
Prompt: GPT-4o mini (zero-shot)0.4880.9430.6430.681
Response: Llama Guard 3 Vision0.9610.9160.9380.016
Response: GPT-4o (zero-shot)0.5790.7880.6670.243
Response: GPT-4o mini (zero-shot)0.5260.8200.6410.313

Source: Chi et al. (2024), Table 1.

How It Works

Meta starts from Llama 3.2 11B Vision and fine-tunes it (8,192 sequence length, learning rate 1e-5, 3,600 steps) on 22,500 prompt-image examples and 40,034 prompt-image-response tuples. Training data combines human-written multimodal prompts, jailbreak-elicited responses from internal Llama models, text-only Llama Guard 3 examples paired with dummy images, and labels from humans or Llama 3.1 405B. Each input image is rescaled into 4 chunks of 560 by 560 pixels, and the model outputs "safe" or "unsafe" followed by the violated category IDs (S1 through S13).

To generalize beyond fixed prompts, training randomly drops non-violated categories and shuffles category indices. The policy also expands S7 (Privacy) for vision: if a user uploads a photo of a real person asking "Who is this?" or "What makes her famous?", any assistant reply attempting to identify the person (whether right or wrong) is labeled unsafe.

Key Findings

  • Response context resolves visual ambiguity: zero-shot GPT-4o and GPT-4o mini suffer 0.485 and 0.681 FPR on prompts (partly because OpenAI’s API sometimes refused classification requests itself, which the benchmark counted as "unsafe"). Llama Guard 3 Vision keeps prompt FPR at 0.052, and improves F1 by +0.205 when scoring responses (0.938 vs. 0.733) because the model output disambiguates the image query.
  • Image attacks crush prompt filters far more easily than response filters: across 100 unsafe image conversations under white-box PGD (100 steps, optimizing pixels for "safe"), an 8/255 L-infinity perturbation breaks prompt classification 70% of the time (up from 21% clean), peaking at 82% for 128/255. Response classification fails 22% at 8/255 and plateaus at 27% even unbounded (255/255), because the classifier relies primarily on the text response.
  • Text GCG suffixes mirror that asymmetry: across 100 unsafe text conversations, appending a NanoGCG suffix to the user prompt breaks prompt classification 72% of the time (vs. 4% clean), but raises response-mode failure only from 16% to 30% unless the adversary can force the underlying assistant itself to emit the adversarial suffix (75%).
White-box bypass rate (% misclassified as safe, lower is better) under PGD and GCG
Evaluated on 100 unsafe image conversations (PGD) and 100 unsafe text conversations (GCG).
PGD Prompt (clean -> 128/255)
21% -> 82%
PGD Response (clean -> 128/255)
6% -> 27%
GCG Prompt (suffix on prompt)
4% -> 72%
GCG Response (suffix on prompt)
16% -> 30%
GCG Response (suffix in answer)
16% -> 75%

Source: Chi et al. (2024), Tables 3 and 4.

Caveats and Builder Takeaway

All accuracy figures (0.733 and 0.938 F1) come from Meta’s internal benchmark rather than a public multimodal test suite, and the authors explicitly advise against using Llama Guard 3 Vision as a standalone image-only or text-only classifier (where Llama Guard 3-8B/1B, ShieldGemma, or WildGuard apply). It is English-optimized, accepts only one image per prompt (rescaled to 4 x 560x560 chunks, making small-text OCR or multi-image threats harder), and lacks live factual retrieval for categories like Defamation (S5), IP (S8), and Elections (S13).

Because open weights allow white-box PGD and GCG attacks (matching the structural fragility of aligned models), deploy Llama Guard 3 Vision as one layer in a stack: run both prompt and response checks, lean on response classification where visual ambiguity is high, add a perplexity filter against GCG suffixes, and benchmark against real-world production traffic before setting block thresholds.