Skip to page content
SAVRN
Search Plan a project

Open-weight model · Text classification

Llama-Prompt-Guard-2-22M-onnx

by AthithyaSakthivel8 Athithya117/Llama-Prompt-Guard-2-22M-onnx

Llama-Prompt-Guard-2-22M-onnx is an open-weight model for text classification from AthithyaSakthivel8, released under llama4. It has 71M parameters and a 512-token context. At 16-bit it needs about 0.2 GB of GPU memory, which fits on 1x MI300X from $1.85 an hour, at the lowest prices in the SAVRN Index.

This repository provides a ONNX converted and quantized version of meta-llama/Llama-Prompt-Guard-2-22M - Meta LLaMA – Foundation model powering the classifier - Hugging Face Transformers – Model and tokenizer loading - ONNX – Model export and runtime format …

Parameters71M
Context512
Weights640.1 MB
Licensellama4
AccessOpen weights
Monthly Downloads—

Runs On

What it takes to serve Llama-Prompt-Guard-2-22M-onnx (71M parameters): the memory its weights need at each precision, and the cheapest way to rent enough data-center GPUs to hold them.

PrecisionWeightsMemory neededCheapest setupPer hourAlso fits
16-bit 0.1 GB 0.2 GB 1x MI300X (192 GB)
Vultr
$1.85 1x H100 $1.99 · 1x MI325X $2.00
8-bit 0.1 GB 0.1 GB 1x MI300X (192 GB)
Vultr
$1.85 1x H100 $1.99 · 1x MI325X $2.00
4-bit 0.0 GB 0.0 GB 1x MI300X (192 GB)
Vultr
$1.85 1x H100 $1.99 · 1x MI325X $2.00

Memory is the weights at that precision plus 20% for the runtime and a short context; a long context needs more. Prices are the lowest on-demand hourly rates in the SAVRN Index, read Oct 18, 2026.

Llama-Prompt-Guard-2-22M-onnx on every accelerator the SAVRN Index prices, at every precision

Model Card

This repository provides a ONNX converted and quantized version of meta-llama/Llama-Prompt-Guard-2-22M - Meta LLaMA – Foundation model powering the classifier - Hugging Face Transformers – Model and tokenizer loading - ONNX – Model export and runtime format - ONNX Runtime – Efficient inference backend We use jackhhao/jailbreak-classification for the evaluation (train+test) You can find the full source code, CLI tools, and evaluation scripts in the official GitHub repository.

Excerpt from the card by AthithyaSakthivel8, licensed llama4.

Configuration

Architecture
DebertaV2ForSequenceClassification
Context length (tokens)
512
Layers
12
Hidden size
384
Feed-forward size
1,536
Attention heads
6
Vocabulary size
128,100
Stored precision
float32
Model type
deberta-v2

Identity and Version

Repository
Athithya117/Llama-Prompt-Guard-2-22M-onnx
Publisher
AthithyaSakthivel8
Task
Text classification
Modality
Text
Library
Not stated by the source
Parameters
71M parameters
Languages
en, fr, de, hi, it, pt, es, th
Revision
28be611a5e773bcc2bfc2cc7477be06b90302fa5
First published
2026-10-17
Last updated
2026-10-17

Files and Weights

11 files, 648.8 MB in total. The weights are 3 files totalling 640.1 MB in onnx, safetensors.

Weights3 files · 640.1 MB
Configuration2 files · 2.0 KB
Tokenizer2 files · 8.7 MB
Documentation3 files · 10.2 KB
Repository1 file · 1.5 KB
Every file
FileTypeSizeSHA-256
model.onnxWeights284.2 MB c6f4d2ebf59b
model.quant.onnxWeights72.5 MB 38c3f03e30a4
model.safetensorsWeights283.3 MB 5120e30bcd53
config.jsonConfiguration1.0 KB —
special_tokens_map.jsonConfiguration970 B —
LICENSEDocumentation7.6 KB —
NOTICEDocumentation111 B —
README.mdDocumentation2.5 KB —
.gitattributesRepository1.5 KB —
tokenizer.jsonTokenizer8.6 MB —
tokenizer_config.jsonTokenizer1.5 KB —

License and Download

License
llama4
Access
Open weights, no gate
Download size
640.1 MB
Download from AthithyaSakthivel8

Released by AthithyaSakthivel8 through its official repository on Hugging Face.

Built From

  • Derived from meta-llama/Llama-Prompt-Guard-2-22M
  • Quantized from meta-llama/Llama-Prompt-Guard-2-22M

Memory Requirements

PrecisionWeights in memory
As published640.1 MB
16-bit0.1 GB
8-bit0.1 GB
4-bit0.0 GB

Weights only, from the published parameter count; the key-value cache and runtime add to this.

Questions About Llama-Prompt-Guard-2-22M-onnx

How much GPU memory does Llama-Prompt-Guard-2-22M-onnx need?

About 0.2 GB at 16-bit and 0 GB at 4-bit: the weights (71M parameters) plus a working margin. A long context needs more.

What is the cheapest GPU to run Llama-Prompt-Guard-2-22M-onnx on?

At 16-bit, 1x MI300X from $1.85 an hour; at 4-bit, 1x MI300X from $1.85 an hour, at the lowest on-demand prices the SAVRN Index lists.

What license is Llama-Prompt-Guard-2-22M-onnx released under?

llama4, as its publisher declares it. Read the license text before commercial use.

What is Llama-Prompt-Guard-2-22M-onnx's context length?

512 tokens, from the maximum position embeddings in its published configuration.

Similar Models

Model · Text classification

scb-banking77-distilbert-test-3

CK Tsai

This is the model card of a transformers model that has been pushed on the Hub. Users (both direct and downstream) should be made aware of the risks, biases and limitations of the model. Use the code below to get started with the model. Carbon emissions can be estimated using the Machine Learning Impact calculator presented in Lacoste et al. (2019).

Open weights 67M parameters 512 tokens transformers

Model · Text classification

dark-pattern-distilbert

C P M Ashir

This is the model card of a transformers model that has been pushed on the Hub. Users (both direct and downstream) should be made aware of the risks, biases and limitations of the model. Use the code below to get started with the model. Carbon emissions can be estimated using the Machine Learning Impact calculator presented in Lacoste et al. (2019).

Open weights 67M parameters 512 tokens transformers

Model · Text classification

distilbert-base-uncased-finetuned-emotion

Vinay

This model is a fine-tuned version of distilbert-base-uncased on an unknown dataset. It achieves the following results on the evaluation set: The following hyperparameters were used during training: - learningrate: 2e-05 - trainbatchsize: 64 - evalbatchsize: 64 - lrschedulertype: linear - numepochs: 2 - Transformers 5.18.0 - Pytorch 2.11.0+cu130 - Datasets 4.8.5 - Tokenizers 0.23.2

Open weights apache-2.0 67M parameters 512 tokens transformers

Model · Text classification

yelpModel2026Fall

Cetus Wong

This is the model card of a transformers model that has been pushed on the Hub. Users (both direct and downstream) should be made aware of the risks, biases and limitations of the model. Use the code below to get started with the model. Carbon emissions can be estimated using the Machine Learning Impact calculator presented in Lacoste et al. (2019).

Open weights 67M parameters 512 tokens transformers

This model is based on DistilBERT and has been fine-tuned for multilabel classification of Emails and URLs as safe or potentially phishing. - Base Architecture: DistilBERT - Task: Multilabel Classification - Fine-tuning Framework: Hugging Face Trainer API - Training Duration: 3 epochs - Accuracy: 99.58 - F1-score: 99.579 - Precision: 99.583 - Recall: 99.58 The model was trained on a custom dataset of Emails and URLs labeled as legitimate or phishing. The dataset is available at cybersectony/PhishingEmailDetectionv2.0 on the Hugging Face Hub.

Open weights apache-2.0 67M parameters 512 tokens transformers

This model is a fine-tune checkpoint of DistilBERT-base-uncased, fine-tuned on SST-2. This model reaches an accuracy of 91.3 on the dev set (for comparison, Bert bert-base-uncased version reaches an accuracy of 92.7). This model can be used for topic classification. You can use the raw model for either masked language modeling or next sentence prediction, but it's mostly intended to be fine-tuned on a downstream task. See the model hub to look for fine-tuned versions on a task that interests you. The model should not be used to intentionally create hostile or alienating environments for people. In addition, the model was not trained to be factual or true representations of people or events…

Open weights apache-2.0 67M parameters 512 tokens transformers