license: apache-2.0
task_categories:
- text-classification
tags: - prompt-injection
- safety
- security
size_categories: - 100K<n<1M
SafeGuard Prompt Injection Dataset (Clean v2.0)
A curated dataset of 108,789 samples for training prompt injection detection classifiers.
Cleaned of benchmark contamination (10,121 samples from ToxiGen, Do-Not-Answer, JailbreakBench removed) and augmented with 2,493 targeted synthetic samples covering novel attack types.
Splits
| Split | Samples | Benign | Injection | Injection % |
|---|---|---|---|---|
| Train | 97,950 | 78,682 | 19,268 | 19.7% |
| Validation | 5,414 | 4,397 | 1,017 | 18.8% |
| Test | 5,425 | 4,353 | 1,072 | 19.8% |
| Total | 108,789 | 87,432 | 21,357 | 19.6% |
Sources
- Alpaca — general instruction data (benign)
- OpenAssistant — conversation data (benign)
- Dolly — instruction data (benign)
- Synthetic — template-based injection attacks
- Synthetic Clean — targeted replacements for known model weaknesses
Usage
from datasets import load_dataset
dataset = load_dataset("jcanode/safeguard-prompt-injection")
Associated Model
jcanode/safeguard-ministral3-3b — 99.08% accuracy fine-tuned classifier