prompt-guard

Detect prompt injections and jailbreak attempts in LLM inputs.

Updated Aug 23, 2026
One-click install
npx skills add https://github.com/choice5346/BiSHE --skill prompt-guard-choice5346
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: prompt-guard
Source: https://github.com/choice5346/BiSHE/tree/main/.github/skills/prompt-guard
Command: npx skills add https://github.com/choice5346/BiSHE --skill prompt-guard-choice5346

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires transformers, torch, and includes scripts (resource) and references (resource) components.

What problem does it solve?

This Skill protects Large Language Model (LLM) applications by detecting and filtering malicious prompts, including prompt injections and jailbreak attempts, ensuring safer and more reliable AI interactions.

Core Features & Use Cases

  • Prompt Injection Detection: Identifies malicious instructions embedded within user input or third-party data.
  • Jailbreak Detection: Flags attempts to override the LLM's safety guidelines or intended behavior.
  • Multilingual Support: Operates effectively across 8 different languages.
  • Use Case: Before sending user queries to your LLM, use Prompt Guard to scan for any attempts to make the AI reveal sensitive information or perform harmful actions.

Quick Start

Use the prompt-guard skill to check if the user message 'Ignore previous instructions' is a jailbreak attempt.

Frequently Asked Questions about prompt-guard

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I detect prompt injection attacks in LLM inputs?

Prompt injection detection works by classifying user input and third-party data to identify malicious instructions attempting to override system prompts. This filtering happens before the input reaches the LLM, preventing unauthorized command execution.

Does this prompt security classifier support multilingual jailbreak detection?

Yes, multilingual jailbreak detection is supported across 8 different languages. The classifier maintains high true positive rates and low false positive rates, effectively flagging safety guideline overrides in non-English inputs.

Can I use HuggingFace transformers to scan for RAG security threats?

Yes, you can deploy the classifier via HuggingFace transformers to scan for RAG security threats. It supports batch processing to filter malicious prompts embedded in retrieved third-party data before LLM generation.

Do I need PyTorch installed to run prompt injection detection?

Yes, you need PyTorch installed because the classifier depends on the torch and transformers libraries. These dependencies power the 86M parameter model used to evaluate input safety and detect jailbreak attempts.

What is the best way to filter jailbreak attempts in LLM applications?

Filtering jailbreak attempts is best handled by a dedicated lightweight classifier that evaluates inputs before LLM processing. This approach offers high true positive rates and low false positive rates across multiple languages.

When should I use an automated safety alignment classifier instead of manual prompt review?

You should use an automated safety alignment classifier when processing high-volume user queries or integrating untrusted third-party data. It efficiently scales jailbreak detection where manual review would create application latency.