Global AI chat room · 17 online now Join now
P
MODEL Listed

Prompt-Guard-86M

Prompt Guard 86M is a lightweight, specialized classifier designed to secure LLM pipelines by detecting prompt injections and jailbreak attempts. Unlike general-purpose models, this 86M-parameter model is optimized for low-latency inference, making it an ideal first-pass filter before requests hit your primary generative model. It categorizes inputs into 'safe' or 'unsafe' based on adversarial patterns, allowing developers to implement programmatic guards without sacrificing system performance. It integrates easily into existing middleware or API gateways, providing a critical layer of defense against malicious user inputs that seek to bypass system instructions.

meta-llamatext classification
01 / MODEL CARD

Model card

Prompt Guard 86M is a lightweight, specialized classifier designed to secure LLM pipelines by detecting prompt injections and jailbreak attempts. Unlike general-purpose models, this 86M-parameter model is optimized for low-latency inference, making it an ideal first-pass filter before requests hit your primary generative model. It categorizes inputs into 'safe' or 'unsafe' based on adversarial patterns, allowing developers to implement programmatic guards without sacrificing system performance. It integrates easily into existing middleware or API gateways, providing a critical layer of defense against malicious user inputs that seek to bypass system instructions.

Model typetext classification
Providermeta-llama
Licensellama3.1
02 / FILES & VERSIONS

Model files and versions

Model cardModel description and metadata available in this entry
Listed
Source repositoryhttps://huggingface.co/meta-llama/Prompt-Guard-86M
View model source
Version informationUse the source repository for the latest version
—
03 / DOWNLOAD

Download this model

We recommend using the ModelScope CLI or SDK. Install ModelScope first, then choose a full snapshot, single file, SDK or Git LFS workflow.

This entry points to Hugging Face. The commands use the matching ModelScope repository format; confirm that the repository exists on ModelScope before running them. Model repository: meta-llama/Prompt-Guard-86M
Install ModelScope

Install the CLI and SDK dependency before downloading.

pip install modelscope
Download the full model repository

Download the complete weights, configuration and model card.

modelscope download --model meta-llama/Prompt-Guard-86M
Download one file to a local directory

README.md is used as an example; replace it with another repository file when needed.

modelscope download --model meta-llama/Prompt-Guard-86M README.md --local_dir ./dir
Download with the SDK

Useful in Python projects and automation scripts.

from modelscope import snapshot_download
model_dir = snapshot_download('meta-llama/Prompt-Guard-86M')
Clone with Git

Make sure Git LFS is installed correctly.

git lfs install
git clone https://www.modelscope.cn/meta-llama/Prompt-Guard-86M.git
Clone without downloading LFS blobs

Fetch the repository structure first, then pull large files when needed.

GIT_LFS_SKIP_SMUDGE=1 git clone https://www.modelscope.cn/meta-llama/Prompt-Guard-86M.git
04 / WORKFLOW

How to use

  1. 01
    Step 1

    Read the model card and source information.

  2. 02
    Step 2

    Start with a small, non-sensitive evaluation.

  3. 03
    Step 3

    Review quality, licensing and usage limits.

  4. 04
    Step 4

    Adopt it only after validation.

05 / DISCUSSIONS

Discussions

Use this space to keep checking source information, usage experience and maintenance status.

Open source page
Email