Patronus
  • Apache 2.0
  • English and German

Tiger Guard
Content moderation

Labels text SAFE or UNSAFE: abuse, hate, threats and harmful requests in LLM conversations. For prompts, responses and comments, in English and German.

On Hugging Face patronus-studio/tiger-guard-content-moderation

Profile.

Task

Content moderation

Abuse, hate and harmful requests in prompts, responses and user text

Signal

UNSAFE

Parameters
308M parameters
Base
mmBERT-base
Evaluation
Accuracy 88.8% on the 1,500-prompt benchmark (HateCheck, Intuit, Aegis 1.0) with 46 false alarms on 750 harmless prompts; 83.3% of disguised harmful requests caught in the held-out test in English, 75.3% in German.
Formats
ONNX FP32 1.23 GB · FP16 615 MB · INT8 308 MB · INT8 with INT4 embeddings 237 MB · x86 builds 510 MB and 242 MB
Variants and siblings

Tiger Guard Small 141M parameters on mmBERT-small, 106 MB as INT8 with INT4 embeddings. Accuracy 87.6% on the same benchmark with less than half the memory.

License
Apache 2.0
Hugging Face
patronus-studio/tiger-guard-content-moderation

How it works: Tiger Guard.

Tiger Guard

Input

Comment under the post: Shut your stupid mouth, you worthless idiot, nobody here wants you around.

Output

UNSAFE

Application rule: Hold the comment for review

Evaluation.

Model card with protocol

88.8%

Accuracy 88.8% on the 1,500-prompt benchmark (HateCheck, Intuit, Aegis 1.0) with 46 false alarms on 750 harmless prompts; 83.3% of disguised harmful requests caught in the held-out test in English, 75.3% in German.

Install.

Patronus Ark loads the model and runs it on the CPU. The quickstart with Transformers or ONNX Runtime is in the model card.

Patronus Ark · Python
pip install patronus-ark

from patronus_ark import SecurityGateway

scanner = SecurityGateway(
    categories=["injection", "dlp", "pii"], max_level="l2",
)
scanner.warmup()
scanner.enqueue("Text to inspect")
while (event := scanner.consume_next_event(timeout=1.0)) is not None:
    if event["event_type"] == "result":
        r = event["result"]
        print(r["category"], r["class_name"], r["confidence"])
    else:
        break