🛰️ Daily AI Frontier
‹ back to 2026-10-28

Heads of Security: Learned Attention Gates Improve Prompt Injection Robustness

arXiv cs.LG LLMs & Foundation Models Igor Shilov, Xiaoxue Yang, Alexander Panfilov, Evgenii Kortukov, Matthieu Meeus, Peter Romov, Wojciech Samek, Jonas Geiping, Yves-Alexandre de Montjoye 2026-10-27
Representative image for Heads of Security: Learned Attention Gates Improve Prompt Injection Robustness

TL;DR - Heads of Security uses learned per-head attention gates to separate trusted instructions from untrusted data, improving prompt-injection resistance while preserving model utility.

  • HoS lets models reason over untrusted content without obeying injected instructions.
  • RL-Hammer achieved only 10% attack success against HoS, versus 97% on GPT-OSS-20B and 85% on SecAlign.
  • An enhanced white-box attack required 3Ă— more FLOPs to reach the same attack success rate against HoS.
  • HoS retained base-model benchmark utility and matched SecAlign on static agentic attacks, while ASIDE struggled with tool use.

view merged work →