The autonomy tax: defense training breaks LLM agentsThe Autonomy Tax: Defense Training Breaks LLM Agents
The authors state that defense training induces three types of shortcut bias on multi-step agents: SecAlign-Mistral completion rate is only 1.0%, and obfuscation attack bypass rate is 81–86%.
- Defense training is intended to resist prompt injection, but the authors state that on multi-step agents it systematically breaks execution capability, and that single-turn evaluation metrics mask these failures.
- The authors evaluate Llama-3-8B, Llama-3.1-8B, Mistral-7B and three defenses, StruQ, SecAlign and Meta SecAlign, on the AgentDojo 97 tasks and a self-built 350-sample challenge set, and propose three types of diagnostics: Step-1 execution analysis, depth-stratified cascade measurement and trigger-word bias.
- The authors report: 47–77% of benign tasks fail at Step-1 for defended models; SecAlign-Mistral completion rate 1.0%, with 99% of tasks cascading to timeout; obfuscation attack bypass rate 81–86%, benign technical content false-refusal rate 25–71%.
- The authors note that the evaluation covers only Llama-3 (8B), Llama-3.1-8B, Mistral (7B) and three defense configurations (Section 8); the challenge set was manually curated to characterize failure modes rather than to estimate overall defense performance (Appendix A.3.3).
- Threat model
- Indirect prompt injection: the attacker embeds malicious instructions in tool observations (documents, web pages, API responses), attempting to hijack the agent's goals; the victim system is a multi-step LLM agent running under the ReAct framework, and the defender is a model that has undergone defense training (StruQ, SecAlign, Meta SecAlign).
- Evaluated models
- Llama-3-8B-InstructLlama-3.1-8B-InstructMistral-7B-Instruct-v0.3
- Benchmarks
- AgentDojoChallenging Subset(350 样本)
- Metrics
- CRCFRTPRFPRBypass Rate
USC researchers Shawn Li and Yue Zhao propose the concept of an autonomy tax, referring to how defense training to resist prompt injection systematically damages LLM agents' multi-step execution capability while failing to stop complex attacks that evade keywords. The study evaluated Llama-3-8B, Llama-3.1-8B, Mistral-7B and three defenses, StruQ, SecAlign and Meta SecAlign, on AgentDojo's 97 multi-step tasks and a 350-sample challenge set, finding that defense models failed 47–77% of benign tasks at the first step without seeing any external content (baseline 3%), failures cascaded and amplified through retry loops, SecAlign-Mistral's completion rate fell from 50.5% to 1.0% with 99% of tasks cascading into timeouts; obfuscation and social engineering attack bypass rates reached 73–86%, benign content false refusal rates rose from 0% to 25–71%, and the base model's 82.7% attack detection rate fell to 26.7–37.4% after defense training.
Why it was selectedThe paper uses 97 agent tasks and a 350-sample diagnostic set to quantify the capability cost of defense training; teams deploying defense models can use this to check multi-step failures masked by single-turn evaluation.
Paper analysis
What problem does this paper attempt to solve?
The authors state that defense training breaks execution capability on multi-step agents yet fails to stop complex attacks, and that single-turn evaluation obscures this.
Core question: while improving single-turn safety metrics, does defense training systematically break task execution capability in multi-step agent deployments?
- Problem setting: LLM agents perform multi-step reasoning-action-observation loops under the ReAct framework, errors propagate along the trajectory, and observations may contain adversarial content; practitioners deploy defense-trained models to resist prompt injection.
- Existing gaps: the authors state that current defense evaluations focus on single-turn benchmarks (attack rejection rate >90%, FPR <5%) and cannot capture agent-specific cascading failures; prior work (Li et al., 2026b) identified shortcut bias only on static prompt concatenation.
- Core observation: the authors propose a "capability-alignment paradox"—defense training overfits to surface attack patterns (keywords, position) rather than semantic threat understanding, causing the agent to fail before it sees any external content.
- Paper contributions: characterize three agent-specific biases (agentic incapability, cascade amplification, trigger-word bias), attribute the failures to shortcut learning, and provide diagnostic methods (Step-1 execution analysis, depth-stratified cascade measurement, a 350-sample challenge set).
- Threat model:
- Attacker goal: hijack agent behavior via indirect prompt injection (Appendix A.2).
- Attack surface: malicious instructions embedded in tool observations (documents, web pages, API responses); there are also two vectors, goal hijacking and cascade exploitation.
- Victim system: multi-step LLM agents deployed with defense-trained models (StruQ, SecAlign, Meta SecAlign).
- The paper does not state the attacker's knowledge assumptions (white-box/black-box).
What related research exists?
Related work covers three groups: prompt injection attacks and defenses, shortcut learning, and agent evaluation; the authors state that this paper extends single-turn shortcut analysis to multi-step agents.
Prompt Injection Attacks and Defenses
- Attack work (Perez and Ribeiro, 2022; Greshake et al., 2023; Toyer et al., 2023, etc.)—manipulating LLM behavior via adversarial instructions, including direct and indirect injection.
- Defense work—StruQ (Chen et al., 2025b) uses XML delimiters to distinguish instructions from observations; SecAlign (Chen et al., 2024) uses DPO preference alignment; instruction hierarchy (Wallace et al., 2024); Constitutional AI (Bai et al., 2022) and Deliberative Alignment (Guan et al., 2024). The paper notes that the latter two do not address multi-step cascade dynamics.
- Evaluation benchmarks (Liu et al., 2024; Yi et al., 2025; Han et al., 2024)—the paper notes that they use single-turn metrics and lack cascade dynamics.
Shortcut Learning
- Models exploit spurious correlations rather than robust strategies (Geirhos et al., 2020; Ilyas et al., 2019; Stutz et al., 2019); LLMs exhibit position bias (Liu et al., 2023), lexical shortcuts (Zhao et al., 2021), and format sensitivity (Wu et al., 2024).
- Li et al. (2026b)—identifies three defense-specific shortcuts, position, trigger word, and domain, in single-turn settings; this paper extends this to multi-step agents.
Agent Evaluation
- AgentDojo (Debenedetti et al., 2024), AgentBench (Liu et al., 2025), ToolBench (Qin et al., 2023)—evaluate multi-step execution; the paper notes that prior work measures per-turn refusal rates and lacks end-to-end failures.
Baselines and Benchmarks: the defenses compared in this paper are StruQ, SecAlign, and Meta SecAlign, and the base models are Llama-3-8B, Llama-3.1-8B, and Mistral-7B; evaluation uses AgentDojo (97 tasks) and a self-built 350-sample challenge set.
Authors' positioning: this paper extends single-turn shortcut bias analysis to multi-step agents, revealing agentic incompetence and cascade amplification, two types of failure masked by single-turn evaluation.
How does the paper address this problem?
The authors formalize three types of shortcut bias and design two sets of controlled diagnostic experiments using AgentDojo and a self-built 350-sample challenge set.
Overall approach: attribute the failure of defense training to shortcut learning, formalize three agent-specific biases, and measure each with two sets of controlled diagnostic experiments.
Problem Setup and Formalization
- The agent runs in a ReAct loop: at step t it receives context ct = [s, u, h<t],生成动作 at = fθ(ct),直到 finish 或达到最大深度 Tmax。
- 防御训练在良性-攻击对上微调得到 fθ′;过度防御指 fθ′ 拒绝 fθ 能正确处理的良性内容。
- 级联失败形式化:∃ t ≤ Tmax : fθ′(ct) = refuse ∧ ∀ t′ > t : fθ′(ct′) ≠ finish, i.e., after one refusal, retries still cannot complete the task.
Definitions of the Three Biases
- Agentic incompetence bias: defense training lowers the model's probability of generating a valid action a ∈ A, manifesting as explicit refusal or invalid output at Step-1 (when no tool observation is present).
- Cascade amplification bias: the agent framework treats failures as recoverable errors and retries, so systematic incompetence causes retries to encounter the same failure, CFR(fθ′)/CFR(fθ) > 1.
- Trigger-word bias: spurious correlation between keywords and attack labels in the defense dataset leads the model to learn a P(y=attack | w ∈ x) pattern match, causing TPR to drop while FPR rises.
Diagnosis 1: Agentic Incompetence and Cascade Failure
- Using AgentDojo (97 tasks across the four domains workspace, banking, travel, slack), trigger phrases are injected into tool observations with probability ptrigger = 0.3 (pool Vtrigger contains 50 attack-like phrases).
- Step-1 execution behavior is analyzed (before any observation appears), and completion rate CRd is computed stratified by completion depth d ∈ {1-2, 3-5, 6-9, 10}; the bimodal pattern of high completion at depths 1–9 and near-zero at depth 10 serves as evidence of cascading.
Diagnosis 2: Trigger-word Bias and the Safety-Utility Trade-off
- N = 350 challenge samples are constructed: 289 adversarial samples (three types: social engineering, obfuscation, instruction override, designed to evade keyword matching) and 61 benign samples (technical documents containing legitimate safety terminology).
- Three failure types: Type 1 (base model refuses but defended model completes, n=160), Type 2 (bypassed across defense configurations, n=129), Type 3 (base model completes but defended model refuses, n=61).
- Metrics: TPR (proportion of adversarial samples correctly refused) and FPR (proportion of benign samples incorrectly refused).
Implementation Details
- All experiments use greedy decoding (temperature 0), with at most 512 tokens generated per call (Appendix A.9.4).
- StruQ training uses 50K benign-attack pairs with instruction tokens weighted 2×; SecAlign uses 30K preference triples with DPO β = 0.1 (Appendix A.6, A.9.4).
- Statistical tests: Fisher's exact test, Wilson 95% confidence intervals, chi-square test for depth stratification (Appendix A.9.1).
What experiments did the paper conduct?
Across 3 base models × 4 defense configurations, the authors report Step-1 failure of 47–77%, SecAlign-Mistral completion rate of 1.0%, and obfuscation attack bypass of 81–86%.
Experimental Setup
- Models tested: three base models, Llama-3-8B, Llama-3.1-8B, and Mistral-7B, with four defense configurations: Base (no safety training), StruQ, SecAlign, and Meta SecAlign (Llama-3.1-8B only).
- Datasets: 97 AgentDojo multi-step tasks (4 domains); a challenge subset of 350 samples (289 adversarial, 61 benign), selected from an initial evaluation of 6 models × 1000 prompts (Appendix A.3).
- Metrics: CR (completion rate), CFR (cascade failure rate at depth-10 timeout), depth-stratified CR, TPR, FPR, classification bypass rate.
- Determination method: task completion is defined as the agent calling finish and verify(τ, u) = True; adversarial/benign labels were reviewed by consensus of two annotators, Cohen's κ = 0.89 (Appendix A.3.3).
- Decoding: greedy decoding, maximum 512 tokens; the paper does not report the number of repetitions.
Main Results
According to Table 2 (AgentDojo 97 tasks):
Swipe horizontally to read the table
Model Defense CR CFR Avg Depth Llama-3-8B Base 86.6% 13.4% 5.32 Llama-3-8B StruQ 80.4% 19.6% 5.38 Llama-3-8B SecAlign 63.9% 36.1% 7.78 Llama-3.1-8B Meta SecAlign 85.6% 14.4% 5.45 Mistral-7B Base 50.5% 49.5% 6.14 Mistral-7B StruQ 14.4% 85.6% 8.70 Mistral-7B SecAlign 1.0% 99.0% 9.94 - The authors state that defense training cascades single-step incompetence into task-level failure: SecAlign raises CFR from 13–50% (base models) to 36–99%, an amplification of 2.0–2.7× (Table 5).
- Figure 3 shows a bimodal distribution: tasks either complete at depths 1–9 or cascade to a depth-10 timeout, and defended models have near-zero completion rate at maximum depth (0–5.4% vs 13.3% for base models).
- Table 1: defended models fail Step-1 on 47–77% (base models about 3%); StruQ produces 69–71% invalid outputs, and SecAlign has an explicit refusal rate of 46–47%, all occurring before any tool observation appears.
Trigger-word Bias: Dual Degradation of Safety and Utility
- What was measured: TPR/FPR and classification bypass rate on the 350 challenge samples (Table 3, Table 4).
- Results: Base-Llama3-8B TPR 82.7%, StruQ drops to 37.4% (−45.3pp), SecAlign drops to 26.7% (−56.0pp); FPR rises from 0% to 70.5% (StruQ) and 24.6% (SecAlign). Obfuscation attack bypass rate 81–86%, social engineering 73–78% (Table 4).
- Authors' interpretation: defenses learn surface shortcuts, and fail once an attack changes syntax or avoids trigger words; Mistral cross-validation confirms systematic over-refusal.
The "input" role mechanism of Meta SecAlign (Appendix A.7)
- What was measured: on 97 AgentDojo tasks, tool observations marked with the "input" role (Experiment 1), and a single-turn comparison with and without role marking on 1000 prompts (500 adversarial, 500 benign) (Experiments 2a/2b).
- Results: Experiment 1 completion rate 89.7% (baseline 86.6%), but LLM safety warnings 0%; Experiment 2b (ideal marking) TPR 79.6%, FPR 3.6%, Experiment 2a (realistic deployment) TPR 68.0%, ASR 32.0% (Table 8).
- Authors' interpretation: the "input" role requires identifying adversarial content in advance, creating a circular dependency; multi-step agents cannot exploit this mechanism, and the authors consider it unsuitable for general deployment.
Other Ablations and Analyses
- Depth-stratified CR (Table 6): SecAlign-Mistral completion rate at depths 1–2 is 0.0%, with 99.0% concentrated at depth 10; Llama-3 base models complete 45.4% at depths 1–2.
- Retry depth (Table 5): SecAlign's average retry depth increases by +2.5 to +3.8 steps relative to base models (Appendix A.4.2).
- FPR by content type (Table 7, n=61): StruQ 70.0% (21/30) on general trigger samples, 71.0% (22/31) on safety context; SecAlign-Llama3 3.3% (1/30) and 45.2% (14/31) respectively.
- Meta SecAlign classification bypass (Table 4): Direct Request 53.4% vs Constraint Removal 2.8%, variance 50.7%.
- Case studies (Appendix A.5): in Case 1, SecAlign-Llama3 refuses at Step-1 on a benign file task and retries until timeout; in Case 3, a social engineering attack bypasses StruQ (the authors report a 78% bypass rate).
What are some points that can be further explored?
The authors only note that model and defense coverage is limited; the experiments cover 3 base models, 4 defenses, 97 tasks, and 350 challenge samples.
Limitations noted by the authors and future directions
- The evaluation covers only Llama-3 (8B), Llama-3.1-8B, Mistral (7B) and three defense configurations (StruQ, SecAlign, Meta SecAlign) (Section 8).
- The authors state that the shortcut learning mechanism is architecture-independent and should generalize to larger model scales, but the quantitative magnitude may differ (Section 8).
- The challenge subset was manually curated to characterize specific failure modes (paradoxical safety degradation, high-frequency bypass, keyword false rejection), rather than to estimate overall defense performance under arbitrary attack distributions (Appendix A.3.3).
- Future directions (Appendix A.8): the authors propose agent-aware defense design principles (context-sensitive evaluation, multi-step coherence, semantic threat modeling) and candidate paths (chain-of-thought defense, multi-stage filtering, agent-aware training, position-invariant architectures), all of which are ideas rather than implemented work.
Scope of experimental coverage
- The models tested are 3 base models: Llama-3-8B, Llama-3.1-8B and Mistral-7B, and the defense configurations are 3: StruQ, SecAlign and Meta SecAlign (Section 6.1).
- The evaluation environments are the AgentDojo 97 tasks (four domains: workspace, banking, travel, slack) and a 350-sample challenge subset (289 adversarial, 61 benign) (Section 6.1).
- Adversarial samples cover three categories: social engineering, obfuscation (Base64, ROT13, URL encoding) and instruction override; Meta SecAlign additionally uses the Direct Request and Constraint Removal categories (Section 5, Table 4).
- The annotation protocol was independent review by two annotators with disagreements resolved by discussion, Cohen's κ = 0.89 (Appendix A.3.3).
- The paper does not report the number of repeated runs for each condition; statistical tests use Fisher's exact test and Wilson 95% confidence intervals (Appendix A.9.1).
Summarize the main content of the paper
The authors state that defense training makes multi-step agents pay an "autonomy tax": execution capability is broken while attacks are still bypassed, and the root cause is shortcut learning.
An analysis paper on the failure of prompt injection defenses on multi-step agents, proposing the concept of "autonomy tax".
- Problem: defense training looks good on single-turn benchmarks (attack refusal >90%, FPR <5%), but the authors state that these metrics mask failures in multi-step deployment.
- Method: on 97 AgentDojo tasks and a self-built 350-sample challenge set, evaluate Llama-3-8B, Llama-3.1-8B, Mistral-7B with three defenses, StruQ, SecAlign, and Meta SecAlign, using Step-1 execution analysis, depth-stratified cascade measurement, and trigger-word bias diagnosis.
- Result 1 (agentic incompetence): 47–77% of benign tasks fail at Step-1 for defended models (about 3% for base models), occurring before any tool observation appears (Table 1).
- Result 2 (cascade amplification): SecAlign-Mistral completion rate is only 1.0% (base model 50.5%), with 99% of tasks cascading to timeout; SecAlign's CFR is amplified 2.0–2.7× (Table 2, Table 5).
- Result 3 (trigger-word bias): obfuscation attack bypass rate 81–86%, social engineering 73–78%, while benign technical content FPR reaches 25–71% (Table 3, Table 4).
- Authors' conclusion: the three biases are uniformly attributed to shortcut learning—defense training overfits to surface correlations such as keywords rather than semantic threat understanding; the authors argue that the current defense paradigm optimizes for single-turn refusal benchmarks, making multi-step agents unreliable, and that new methods are needed that preserve tool execution capability under adversarial conditions.