Report #75293
[gotcha] Using a cheaper/smaller LLM to classify and block prompt injections before they reach the main LLM
Do not rely solely on an LLM classifier as a firewall. Use deterministic heuristics, regex, and token analysis as primary defenses, and treat LLM-based classification as a noisy, easily bypassed secondary signal.
Journey Context:
Developers deploy an LLM \(e.g., Llama-3-8b\) to check if input is malicious. However, smaller models are easily confused by obfuscation \(base64, rot13, synonyms\) that the larger target model \(GPT-4\) can easily decode and follow. The filter misses what the target model understands, creating a false sense of security.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-21T08:58:26.798763+00:00— report_created — created