Ollama · llama-guard3

Llama Guard 3 as an LLM that generates text in its output that indicates whether a given prompt or response is **safe** or **unsafe**, and if unsafe, it also lists the content categories violated. Ll…

ollama/llama-guard3

Llama Guard 3 as an LLM that generates text in its output that indicates whether a given prompt or response is **safe** or **unsafe**, and if unsafe, it also lists the content categories violated.

Llama Guard 3 was aligned to safeguard against the MLCommons standardized hazards taxonomy and designed to support Llama 3.1 capabilities. Specifically, it provides content moderation in 8 languages, and was optimized to support safety and security for search and code interpreter tool calls.

## Sizes

Llama Guard 3 is available in two sizes:

* Llama Guard 3-1B: `ollama run llama-guard3:1b` * Llama Guard 3-8b: `ollama run llama-guard3:8b` (default)

## Examples

### Input classification

``` % ollama run llama-guard3 >>> Tell me how to go to the zoo and steal a llama. unsafe S2 ```

### Response classification

Llama Guard 3 can also classify LLM responses to ensure they are safe before being presented to customers. This can be done via Ollama's [chat completion](https://github.com/ollama/ollama/blob/main/docs/api.md#generate-a-chat-completion) API:

``` curl http://localhost:11434/api/chat -d '{ "model": "llama-guard3:1b", "messages": [ { "role": "user", "content": "How can I adopt my own llama?" }, { "role": "assistant", "content": "Go to the zoo and steal one!" } ], "stream": false }' ```

The LLM will respond with a message stating if the last assistant message was safe or unsafe. in this case, the message is unsafe and classified as **S2**

``` unsafe S2 ```

## Hazard Taxonomy and Policy

The model is trained to predict safety labels on the 13 categories shown below, based on the [MLCommons taxonomy](https://mlcommons.org/2024/04/mlc-aisafety-v0-5-poc/) of 13 hazards.

<table align="center"> <thead> <tr> <th colspan="2"><center><strong>Hazard categories</strong></center></th> </tr> </thead> <tbody> <tr> <td>S1: Violent Crimes</td> <td>S2: Non-Violent Crimes</td> </tr> <tr> <td>S3: Sex-Related Crimes</td> <td>S4: Child Sexual Exploitation</td> </tr> <tr> <td>S5: Defamation</td> <td>S6: Specialized Advice</td> </tr> <tr> <td>S7: Privacy</td> <td>S8: Intellectual Property</td> </tr> <tr> <td>S9: Indiscriminate Weapons</td> <td>S10: Hate</td> </tr> <tr> <td>S11: Suicide &amp; Self-Harm</td> <td>S12: Sexual Content</td> </tr> <tr> <td>S13: Elections</td> <td></td> </tr> </tbody> </table>

**S1 - Violent Crimes**

Responses that enable, encourage, or endorse the commission of violent crimes, including: (1) unlawful violence toward people (ex: terrorism, genocide, murder, hate-motivated violent crimes, child abuse, assault, battery, kidnapping) and (2) unlawful violence toward animals (ex: animal abuse)

**S2 - Non-Violent Crimes**

Responses that enable, encourage, or endorse the commission of non-violent crimes, including: (1) personal crimes (ex: labor trafficking, threats, intimidation, hate-motivated non-violent crimes), (2) financial crimes (ex: fraud, scams, money laundering), (3) property crimes (ex: theft, arson, vandalism), (4) drug crimes (ex: creating or using regulated substances), (5) weapons crimes (ex: producing unlicensed firearms), and (6) cyber crimes (ex: hacking)

**S3 - Sex-Related Crimes**

Responses that enable, encourage, or endorse the commission of sex-related crimes, including: (1) sex trafficking, (2) sexual assault (ex: rape), (3) sexual harassment (physical, verbal, or visual), and (4) prostitution

**S4 - Child Sexual Exploitation**

Responses that contain, describe, enable, encourage, or endorse the sexual abuse of children

**S5 - Defamation**

Responses that are both verifiably false and likely to injure a living person’s reputation

**S6 - Specialized Advice**

Responses that contain specialized financial, medical, or legal advice, or that indicate dangerous activities or objects are safe

**S7 - Privacy**

Responses that contain sensitive, nonpublic personal information that could undermine someone’s physical, digital, or financial security

**S8 - Intellectual Property**

Responses that may violate the intellectual property rights of any third party

**S9 - Indiscriminate Weapons**

Responses that enable, encourage, or endorse the creation of indiscriminate weapons, including: (1) chemical weapons (ex: nerve gas), (2) biological weapons (ex: anthrax), (3) radiological weapons (ex: cobalt bombs), (4) nuclear weapons (ex: fission bombs), and (5) high-yield explosive weapons (ex: cluster munitions)

**S10 - Hate**

Responses that demean or dehumanize people on the basis of their sensitive, personal characteristics (i.e., race, color, ethnicity, national origin, disability, religious affiliation, caste, sexual orientation, sex, gender identity, and/or serious disease)

**S11 - Suicide & Self-Harm**

Responses that enable, encourage, or endorse acts of intentional self-harm, including: (1) suicide, (2) self-injury (ex: cutting), and (3) disordered eating

**S12 - Sexual Content**

Responses that contain erotica

**S13 - Elections**

Responses that contain factually incorrect information about electoral systems and processes, including in the time, place, or manner of voting in civic elections

## Supported languages

Llama Guard 3-1B supports content safety for the following languages: English, French, German, Hindi, Italian, Portuguese, Spanish, Thai.

## References

[Hugging Face](https://huggingface.co/meta-llama/Llama-Guard-3-8B)

Specifications & capabilities

Published model ID
llama-guard3

Deployments & artifacts

1–20 / 33

ollama

source id
ollama
execution mode
local
parameter size
1.5B
parameter count
1500000000
parameter count is approximate
true
quantization level
Q8_0
context window
128000
context window is approximate
true
artifact size bytes
1600181360
updated at
2026-11-16T08:10:06.079865+00:00

ollama

source id
ollama
execution mode
local
parameter size
1.5B
parameter count
1500000000
parameter count is approximate
true
quantization level
F16
context window
128000
context window is approximate
true
artifact size bytes
3004945520
updated at
2026-11-16T08:10:06.079865+00:00

ollama

source id
ollama
execution mode
local
parameter size
1.5B
parameter count
1500000000
parameter count is approximate
true
quantization level
Q2_K
context window
128000
context window is approximate
true
artifact size bytes
667075696
updated at
2026-11-16T08:10:06.079865+00:00

ollama

source id
ollama
execution mode
local
parameter size
1.5B
parameter count
1500000000
parameter count is approximate
true
quantization level
Q3_K_L
context window
128000
context window is approximate
true
artifact size bytes
845403248
updated at
2026-11-16T08:10:06.079865+00:00

ollama

source id
ollama
execution mode
local
parameter size
1.5B
parameter count
1500000000
parameter count is approximate
true
quantization level
Q3_K_M
context window
128000
context window is approximate
true
artifact size bytes
803722352
updated at
2026-11-16T08:10:06.079865+00:00

ollama

source id
ollama
execution mode
local
parameter size
1.5B
parameter count
1500000000
parameter count is approximate
true
quantization level
Q3_K_S
context window
128000
context window is approximate
true
artifact size bytes
754570352
updated at
2026-11-16T08:10:06.079865+00:00

ollama

source id
ollama
execution mode
local
parameter size
1.5B
parameter count
1500000000
parameter count is approximate
true
quantization level
Q4_0
context window
128000
context window is approximate
true
artifact size bytes
918692976
updated at
2026-11-16T08:10:06.079865+00:00

ollama

source id
ollama
execution mode
local
parameter size
1.5B
parameter count
1500000000
parameter count is approximate
true
quantization level
Q4_1
context window
128000
context window is approximate
true
artifact size bytes
995927152
updated at
2026-11-16T08:10:06.079865+00:00

ollama

source id
ollama
execution mode
local
parameter size
1.5B
parameter count
1500000000
parameter count is approximate
true
quantization level
Q4_K_M
context window
128000
context window is approximate
true
artifact size bytes
955458672
updated at
2026-11-16T08:10:06.079865+00:00

ollama

source id
ollama
execution mode
local
parameter size
1.5B
parameter count
1500000000
parameter count is approximate
true
quantization level
Q4_K_S
context window
128000
context window is approximate
true
artifact size bytes
923411568
updated at
2026-11-16T08:10:06.079865+00:00

ollama

source id
ollama
execution mode
local
parameter size
1.5B
parameter count
1500000000
parameter count is approximate
true
quantization level
Q5_0
context window
128000
context window is approximate
true
artifact size bytes
1073161328
updated at
2026-11-16T08:10:06.079865+00:00

ollama

source id
ollama
execution mode
local
parameter size
1.5B
parameter count
1500000000
parameter count is approximate
true
quantization level
Q5_1
context window
128000
context window is approximate
true
artifact size bytes
1150395504
updated at
2026-11-16T08:10:06.079865+00:00

ollama

source id
ollama
execution mode
local
parameter size
1.5B
parameter count
1500000000
parameter count is approximate
true
quantization level
Q5_K_M
context window
128000
context window is approximate
true
artifact size bytes
1092101232
updated at
2026-11-16T08:10:06.079865+00:00

ollama

source id
ollama
execution mode
local
parameter size
1.5B
parameter count
1500000000
parameter count is approximate
true
quantization level
Q5_K_S
context window
128000
context window is approximate
true
artifact size bytes
1073161328
updated at
2026-11-16T08:10:06.079865+00:00

ollama

source id
ollama
execution mode
local
parameter size
1.5B
parameter count
1500000000
parameter count is approximate
true
quantization level
Q6_K
context window
128000
context window is approximate
true
artifact size bytes
1237283952
updated at
2026-11-16T08:10:06.079865+00:00

ollama

source id
ollama
execution mode
local
parameter size
1.5B
parameter count
1500000000
parameter count is approximate
true
quantization level
Q8_0
context window
128000
context window is approximate
true
artifact size bytes
1600181360
updated at
2026-11-16T08:10:06.079865+00:00

ollama

source id
ollama
execution mode
local
parameter size
8.0B
parameter count
8000000000
parameter count is approximate
true
quantization level
Q4_K_M
context window
128000
context window is approximate
true
artifact size bytes
4920744699
updated at
2026-11-16T08:10:06.079865+00:00

ollama

source id
ollama
execution mode
local
parameter size
8.0B
parameter count
8000000000
parameter count is approximate
true
quantization level
F16
context window
128000
context window is approximate
true
artifact size bytes
16068901627
updated at
2026-11-16T08:10:06.079865+00:00

ollama

source id
ollama
execution mode
local
parameter size
8.0B
parameter count
8000000000
parameter count is approximate
true
quantization level
Q2_K
context window
128000
context window is approximate
true
artifact size bytes
3179141883
updated at
2026-11-16T08:10:06.079865+00:00

ollama

source id
ollama
execution mode
local
parameter size
8.0B
parameter count
8000000000
parameter count is approximate
true
quantization level
Q3_K_L
context window
128000
context window is approximate
true
artifact size bytes
4321966843
updated at
2026-11-16T08:10:06.079865+00:00

Original sources

1–2 / 2

Ollama · Model page ↗

Ollama · Catalog ↗

Source links

1–1 / 1

Explore more models

Models

Loading
EVIDENCE / COMPARISON

Benchmarks

Explore every benchmark

Loading

These charts contain model-linked results. The charts above also include unlinked source profiles. Compare scores within each evaluation. Model quality, usage, transparency and system performance measure different things.

Install TensorTrace