Read original ↗
newsReddit r/MachineLearningTrust 52 · CommunityPublished 4d agoLive · 4d ago

Open-sourcing a two-stage prompt-injection detector (regex gate + quantised DeBERTa-v3 ONNX), trained partly on real attacks from a game I ran [P]

I built a prompt-injection detector for LLM inputs and I've open-sourced the whole thing - code, weights, and the dataset. The design is two stages. A regex layer (around 430 patterns, plus a decode-then-scan step for base64/ROT13/leetspeak) settles the easy majority of traffic in under a millisecond. Anything ambiguous falls through to a fine-tuned DeBERTa-v3-large, exported to ONNX and quantised to INT8, with a 4-class head (benign / direct / jailbreak

Why these links exist

Every edge carries a method, confidence, and the source snippet that justified it — so bad links are debuggable.

Covers

Related across the graph