Research map / Adversarial robustness and security / Attacks on text and graphs
Defending against Indirect Prompt Injection by Instruction Detection
Tongyu Wen, Chenglong Wang, Xiyuan Yang, Haoyu Tang, Yueqi Xie, Lingjuan Lyu, Zhicheng Dou, Fangzhao Wu
Renmin University of China · Peking University Shenzhen Graduate School · Wuhan University · University of Science and Technology of China · Hong Kong University of Science and Technology · Sony
Read the paperPlace an idea next to itCheck your own paper ↗
AI-extracted. The measured effects below were read by AI from the paper's full text (no summary yet). Numbers and claims can be wrong or missing context, so check the paper before you cite or build on it.
Measured effects reported in the paper
| What was changed | Where | Measured | Effect |
|---|---|---|---|
| use InstructDetector (hidden states + gradients) instead of fine-tuned LLM detector | Llama-3.1-8B-Instruct · News+BIPIA (OOD) | detection accuracy: 91.70% -> 96.90% | Improved |
| add in-context few-shot examples to zero-shot LLM detection | LLM detector · Wiki+LaMini (ID) | detection accuracy: 56.35% -> 59.80% | No clear effect |
| filter external data with InstructDetector | GPT-4o · BIPIA | attack success rate: 39.68% -> 0.13% | Improved |
| filter external data with InstructDetector | Vicuna-7B · BIPIA | attack success rate: 24.06% -> 0.03% | Improved |
| add InstructDetector vs adversarial training | Vicuna-7B · BIPIA | attack success rate: 0.52% -> 0.03% | Improved |
| use gradients in addition to hidden states (ablation) | InstructDetector · News+LaMini (OOD) | detection accuracy: 97.25% -> 98.35% | Improved |
| use hidden states in addition to gradients (ablation) | InstructDetector · News+BIPIA (OOD) | detection accuracy: 96.20% -> 96.90% | Improved |
| use base model instead of instruct model (ablation) | Llama-3.1-8B · News+BIPIA (OOD) | detection accuracy: 96.90% -> 68.55% | Hurt |
| use intermediate layers features rather than deeper layers (ablation) | InstructDetector · four dataset combinations | detection accuracy | Improved |
| scale model size from 1B to 14B (ablation) | InstructDetector · News+BIPIA (OOD) | detection accuracy: 92.55% -> 98.15% | Improved |
| train with only 50 samples (ablation) | InstructDetector · ID and OOD | detection accuracy: > 95% | No clear effect |
| test on Thai instead of English (trained on English only) | InstructDetector · News+BIPIA (OOD) | detection accuracy: 96.90% -> 92.05% | Hurt |
Open problems in LLM jailbreak and prompt injection defense
Which defenses against jailbreaks and prompt injection hold up, and what do they cost in usefulness?
- Adaptive attacks are not ruled out. · 8 papers state it
- Attack success does not carry over between target models. · 7 papers state it
- Strong attacks still need white-box access. · 6 papers state it
Closest papers by meaning
- Beyond Over-Refusal: Defending Indirect Prompt Injection via Latent Instruction Manifolds (EMNLP 2026 · similarity 0.92)
- Robustness via Referencing: Defending against Prompt Injection Attacks by Referencing the Executed Instruction (ACL 2026 · similarity 0.91)
- Defense Against Prompt Injection Attack by Leveraging Attack Techniques (ACL 2025 · similarity 0.91)
- Can Indirect Prompt Injection Attacks Be Detected and Removed? (ACL 2025 · similarity 0.91)
- Evaluating the Instruction-Following Robustness of Large Language Models to Prompt Injection (EMNLP 2024 · similarity 0.90)
- Instructional Segment Embedding: Improving LLM Safety with Instruction Hierarchy (ICLR 2025 · similarity 0.88)
Writing a paper in this area? scime draft is a free LaTeX editor with AI included, real-time co-authors and a check of your references and venue rules before you submit. It also imports OpenAI Prism projects.