# CapLite: Prompt-Injection Defense for Small Language Model Agents without Model-Written Security Artifacts

CapLite blocks prompt injection in small agents without model-written security artifacts

Zimo Xu, Wenzhuo Liu, Hideki Nakayama · arXiv · 2026-11-12

- **Problem** Small models write security policies badly, so prompt-injection defenses that rely on them fail.
- **Method** CapLite derives its policy from tool schemas and rejects writes the user's request does not state.
- **Results** CapLite had no successful attack in 13,935 attacked AgentDojo episodes. Its utility under attack was 29.0% against 27.2% for CaMeL, using 18% of CaMeL's tokens per episode.

![Figure 4: CapLite. Top, the trusted instruction path: the Planner sees only the request q and the tool schemas Σ and commits the write calls, with placeholders…](https://refivu.com/papers/960c67c8-5daf-4bf3-b6e9-64d4b7a65f38/figures/figure-ee3c7b72e4178dec083c0f4d1bf85e6b.png?thumb=512)

**Figure 4** : CapLite. Top, the trusted instruction path: the Planner sees only the request q and the tool schemas Σ and commits the write calls, with placeholders for values to look up, before any tool result is read. Code derives the policy from Σ and the grounding set G(q) from q. Bottom, the untrusted observation path: the Reader makes read-only tool calls, whose results may contain the attacker’s text. The Binder picks a candidate identifier and the Composer writes payload text. The Mediator, which is deterministic code, admits a write only if every authority argument is in G(q), checks the destination of every read, and asks the user when a value is missing. All model calls use one SLM.

[Original paper](https://arxiv.org/abs/2611.17115v1) · [CC BY 4.0](https://creativecommons.org/licenses/by/4.0/) · Zimo Xu, Wenzhuo Liu, Hideki Nakayama · CapLite: Prompt-Injection Defense for Small Language Model Agents without Model-Written Security Artifacts · Original paper figure · Extracted the figure area from page 5 of the original PDF.

## Why model-written guards break down

Enforcement defenses that move the decision into code have the strongest guarantees, yet each of the four studied here still relies on a artifact the agent's own model writes. CaMeL writes a program, Progent a policy, IPIGuard a dependency graph and DRIFT a trajectory with a parameter checklist. The enforcement is only as sound as that artifact, so the study asks whether small open-weight models can be trusted to write it.

Across 15 open-weight models the answer is no, and the failures take two different forms.

When the artifact decides what is allowed, a model's mistake becomes an admitted attack. Progent's policies admitted attacks on 14 of 15 models, 676 in total, and reached 132 of 929 on Qwen3-32B. IPIGuard's graphs were breached on 13 of 15 models with 435 attacks, and DRIFT's constraints on 11 of 15 with 214 attacks. Figure 2 shows the per-model pattern, and the authors read DRIFT's zeros on four models as inaction, since those models complete only 4.7% to 9.5% of attacked tasks.

CaMeL fails in the other direction, because its interpreter enforces the data-flow policy on whatever program the model writes. Its security held in most cases, with 20 successful attacks in 13,935 episodes, 17 of them on LFM2.5-2.6B. The programs often don't run, and on Granite-4.2-8B the final program was unrunnable in 68% of episodes because the model returned no code at all.

Larger models don't write better artifacts, so the failure rates don't follow model size.

## The key idea: code authorizes, the model proposes

CapLite keeps the model in the role of proposing actions and gives authorization to deterministic code. Unclassified tools are denied by the Mediator, so an unfamiliar verb costs utility rather than security. Every argument of a write tool becomes an authority field unless the schema marks it as free text, a date or time, or an enum or boolean.

The Planner sees only the request and the tool documentation, and it commits the write calls before any tool result is read. Its placeholders, such as $event\_id, stand in for values the Reader must look up. Because the Reader's calls also pass the Mediator, a read to a destination the request doesn't state is refused.

The Binder extracts typed candidate values from the observations and keeps only authority or control values that appear in G(q). The Binder picks one candidate identifier or answers none or ask, and it never writes a value itself.

The two guarantees hold by construction: executed writes are a prefix of the committed plan, and every authority argument is in G(q) or confirmed by the user. A trace audit re-derives the policy and G(q) outside the running agent, and it finds no violation in 25,452 CapLite episodes.

## How one episode runs across the five roles

The Planner sees only the request and the tool documentation, and in one schema-constrained call it returns at most ten tool calls. The model's proposal is therefore fixed before any tool result is read, which is why injected text cannot add a write.

It adapts its lookups to what it reads, so injected text can change which reads it performs. Its results are untrusted, since they can carry the attacker's text, so every read also passes the Mediator. For each placeholder, the Binder extracts typed candidate values from the observations. The Binder picks one candidate identifier under constrained decoding, or answers none or ask, and it never writes a value.

The Composer writes free-text payload from the request and the observations, and that text is not constrained. Before each committed write, the Mediator checks that the tool is classified, that no placeholder remains and that the arguments match the schema. It also requires every authority argument to equal a member of G(q) exactly, so a substring of the request doesn't count.

Exactness matters for amounts: a request that mentions 100 does not ground an amount of 1. When an authority value exists only in a tool result, no grounded candidate exists, so CapLite asks the user to confirm instead of guessing. The first denial, confirmation request or tool error stops the remaining writes, and the Reporter then answers from the observations.

## What the evaluation covers

The evaluation runs AgentDojo v1.2.2 with its four suites, Workspace, Slack, Banking and Travel. Benign utility uses the 97 user tasks without injection, while utility under attack uses all 949 user-injection pairs.

The study covers 15 open-weight models, with 13 small models from 1.7B to 12B parameters. Qwen3-32B and the mixture-of-experts Qwen3.6-35B-A3B serve as the two larger references. All models run on vLLM 0.30.0 with native tool calling, temperature 0, seed 0 and thinking disabled. Each call allows at most 2,048 output tokens, and DRIFT's calls allow 8,192.

The eight robustness models are Qwen3-1.7B, Qwen3-4B, Qwen3-4B-Instruct-2507, Qwen3-8B, Qwen3-32B, Llama-3.1-8B, Gemma-4-E4B and Gemma-4-12B.

CaMeL, Progent, IPIGuard and DRIFT run with the authors' algorithms and prompts, and only the model interface changes. The paper removes brackets only when they are absent, and every other part of DRIFT stays unchanged.

Utility under attack is the success rate on the 949 attacked pairs, and attack success rate is the fraction of the 929 tool-goal pairs where the injection goal is achieved.

## Security results against the enforcement defenses

CapLite had no successful attack on any of the 15 models under important\_instructions, which is 0 of 13,935 attacked episodes. For comparison, Progent admitted 676 attacks and CaMeL 20, so the zero isn't an artifact of a weak attack. The authors attribute the zero to the Mediator's checks and the request grounding, not to the model's behavior.

The guarantee is built from two properties that hold by construction in every episode. Committed writes mean the executed writes are a prefix of the writes the Planner committed before any tool result was read.

On the eight robustness models, CapLite stays at zero under the tool\_knowledge attack, the read exfiltration attack and the descriptor collision attack. Under important\_instructions on the same eight models, the undefended agent had 1,258 successful attacks of 7,432. CaMeL had 3 successful attacks of 7,432 on the same eight models. The URL attack fails because the Mediator checks the destination of every read.

![Table 2: Successful attacks k/n (↓) over the eight ro- bustness models. Best in bold, second underlined; the undefended agent is not ranked](https://refivu.com/papers/960c67c8-5daf-4bf3-b6e9-64d4b7a65f38/figures/figure-1eade6fcd87827d5ac1497f6df62dda8.png?thumb=512)

**Table 2** : Successful attacks k/n (↓) over the eight ro- bustness models. Best in bold, second underlined; the undefended agent is not ranked.

[Original paper](https://arxiv.org/abs/2611.17115v1) · [CC BY 4.0](https://creativecommons.org/licenses/by/4.0/)

It checks every executed call and finds no violation in 25,452 CapLite episodes across all models and attacks. The audit confirms that both properties held in every episode, which makes the zero a checked result rather than a claim.

## Utility and cost against CaMeL

CapLite keeps utility under attack close to CaMeL's while spending far fewer tokens per episode. CapLite is higher on Granite-4.2-8B by 21.3 points, where CaMeL rarely obtains a program. CapLite is also higher on LFM2.5-2.6B by 6.8 points. Figure 5 shows the per-model utility and the paired difference between the two defenses.

![Figure 5: (a) Per model, undefended benign utility (gray) and utility under attack of CaMeL (orange) and CapLite (blue). (b) Paired difference CapLite − CaMeL…](https://refivu.com/papers/960c67c8-5daf-4bf3-b6e9-64d4b7a65f38/figures/figure-4c5b5a3b23a881a5a47a3b63c9add7f7.png?thumb=512)

**Figure 5** : (a) Per model, undefended benign utility (gray) and utility under attack of CaMeL (orange) and CapLite (blue). (b) Paired difference CapLite − CaMeL on matched episodes; colored points have intervals that exclude zero. Error bars show 95% bootstrap confidence intervals, resampled by user task.

[Original paper](https://arxiv.org/abs/2611.17115v1) · [CC BY 4.0](https://creativecommons.org/licenses/by/4.0/)

The cost gap is the larger part of the comparison. Because CapLite and CaMeL both have zero or near-zero attack success, CapLite reaches the same utility at 5.5 times lower cost. To compare utility and cost directly, the authors report utility per thousand tokens, which is utility under attack divided by tokens per episode in thousands. CapLite reaches 1.69 on this measure, compared to 1.24 for DRIFT, 0.64 for Progent, 0.59 for IPIGuard and 0.29 for CaMeL.

CapLite has the highest value among the enforcement defenses on 12 of the 15 models.

CapLite's utility under attack is still lower than the undefended agent's. The gap is 21 points, at 29.0% for CapLite against 50.2% for the undefended agent. Most of this gap comes from the small model's planning, which the authors examine in Appendix D. In 38% of the failures, every committed write runs or a read-only task is answered, yet the task still fails.

The defenses that write their own artifacts buy utility with attacks, so CapLite is the cheapest point among those with no or near-no successful attack.

## What the ablations show

Each ablation removes one component of CapLite, and the authors measured each on the eight robustness models. Benign utility rises by 5.6 points and utility under attack by 3.5 points when the Mediator is removed. In exchange, 106 of 7,432 attacks succeed, an ASR of 1.4%, on every one of the eight models. So the Mediator keeps the attack success at zero, and it also accounts for part of the utility gap.

![Table 3: Ablations of CapLite, averaged over the eight robustness models. Each row removes one component. BU and UA are in %, k is the number of successful att…](https://refivu.com/papers/960c67c8-5daf-4bf3-b6e9-64d4b7a65f38/figures/figure-92d4a64dc000e91b755f745e4d1fe6ac.png?thumb=512)

**Table 3** : Ablations of CapLite, averaged over the eight robustness models. Each row removes one component. BU and UA are in %, k is the number of successful attacks out of 8×929 = 7,432 and ASR is k/7,432 in %.

[Original paper](https://arxiv.org/abs/2611.17115v1) · [CC BY 4.0](https://creativecommons.org/licenses/by/4.0/)

This variant admits 53 attacks, an ASR of 0.7%, because an injection can add a write whenever the attacker's goal uses values the request states. Commitment therefore matters: the committed writes cap what an injected text can add, which is why the authors call the replanning Planner necessary. Replacing the candidate-only Binder with a free-text Binder keeps the attack count at 0.

The free-text Binder costs 2.0 points of benign utility, because the Mediator still checks the result it writes.

Removing the Reporter is the largest change in the table, and it halves utility. Benign utility drops from 25.6% to 12.5%, and utility under attack drops from 26.1% to 11.0%. The attack count stays at 0 without the Reporter, so the Reporter is a utility component rather than a security one. The per-model ablation numbers are in Table 7, which the authors give for each of the eight robustness models.

## What the results do not establish

The results come from one benchmark, so AgentDojo's four suites are the only setting the paper tests. The robustness attacks, including tool\_knowledge and the two attacks written against CapLite's design, were run on eight models only. Benign utility, utility under attack and ASR for the main comparison cover all 15 models, but the wider attack set does not.

CapLite's utility under attack is 21 points below the undefended agent's, at 29.0% against 50.2%. On Gemma-4-E4B and Gemma-4-12B, CapLite's utility under attack is significantly below CaMeL's. The paper does not say how the gap on those two models would change with a different planner.

The guarantees also have a boundary: an answer-only goal involves no write, so the write-integrity guarantee doesn't cover it. CapLite doesn't defend that kind of injection, and the paper shows it in Case 5. Free-text arguments such as message bodies are written by the Composer and aren't constrained by the guarantee. Authority values the user doesn't state need a confirmation, which the evaluation counts as a failure.

## Paper info

- **Authors**: Zimo Xu, Wenzhuo Liu, Hideki Nakayama
- **Venue**: arXiv · Preprint
- **First published**: 2026-11-12
- **Added**: 2026-11-14
- **Updated**: 2026-11-12
- **Version**: v1
- **arXiv**: 2611.17115
- **Category**: cs.AI · cs.CL · cs.CR
- **Original paper terms**: [CC BY 4.0](https://creativecommons.org/licenses/by/4.0/)
- **What we show**: Paper info, commentary and permitted figures from the original paper

[Original paper ↗](https://arxiv.org/abs/2611.17115v1) · [PDF ↗](https://arxiv.org/pdf/2611.17115v1)

AI commentary is a separate explanation from the original paper and may contain errors. The original paper and figures follow each source's terms of use and any rights noted separately.

## Abstract

Enforcement defenses against prompt injection, such as CaMeL, Progent, IPIGuard and DRIFT, ask the agent's own model to write a security artifact (a program, a privilege policy, a dependency graph or a constraint list) that code then enforces. We ask whether small language model (SLM) agents can be trusted to write these artifacts. Across 15 open-weight models, 13 of them between 1.7B and 12B parameters, they cannot: the policies, graphs and constraints that the agent's model writes admit attacks on 14 (Progent), 13 (IPIGuard) and 11 (DRIFT) of the models, and CaMeL's programs fail to run in up to 68% of episodes. We present CapLite, which derives its policy from the tool schemas, commits the write calls before any tool result is read, and admits a write only if every argument that decides whom or what it affects is stated in the user's request. This guarantees write integrity: injected text cannot add a write, and no write reaches a recipient, amount, object or destination that the user did not state. No attack succeeds in 13,935 attacked AgentDojo episodes. CapLite reaches utility under attack comparable to CaMeL's (29.0% vs. 27.2%) with fewer tokens than every other enforcement defense and than the undefended agent: 17.1k per episode, 18% of CaMeL's, and the highest utility per token of all enforcement defenses.

## Quote from the paper

Zimo Xu, Wenzhuo Liu, Hideki Nakayama (2026). CapLite: Prompt-Injection Defense for Small Language Model Agents without Model-Written Security Artifacts. arXiv:2611.17115v1. https://arxiv.org/abs/2611.17115v1

**BibTeX**

```
@misc{xu2026caplite,
  title = {{CapLite: Prompt-Injection Defense for Small Language Model Agents without Model-Written Security Artifacts}},
  author = {Zimo Xu and Wenzhuo Liu and Hideki Nakayama},
  year = {2026},
  eprint = {2611.17115},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2611.17115v1}
}
```

## Other paper commentary

- [DiFiT: Distribution-Fidelity-guided Visual Token Pruning for Multimodal Large Language Models](https://refivu.com/en/papers/ded3d71e-2778-4155-b22f-1de96026dbd7-difit-distribution-fidelity-guided-visual-token-pruning-for.md)
- [Mind the Accuracy-Approval Gap: How Users Evaluate Sycophantic AI in Everyday Tasks](https://refivu.com/en/papers/d62f0b2a-4b25-4637-8d3b-cd531c6a07d1-mind-the-accuracy-approval-gap-how-users-evaluate.md)
- [Pretraining Data Statistics Shape the Phases of Learning Entity Comparison in Language Models](https://refivu.com/en/papers/d3386662-50ed-4e67-b429-1af214567cba-pretraining-data-statistics-shape-the-phases-of-learning.md)
- [Shortcuts or Memorisation? Revisiting Data Corruption in Natural Language Understanding with Large Language Models](https://refivu.com/en/papers/47df16a6-990c-4da2-8525-44fedd241d7b-shortcuts-or-memorisation-revisiting-data-corruption-in.md)
- [Detection Is Not Early Warning: Evaluating Token-Level Alarms on Language Model Failures](https://refivu.com/en/papers/a122ecba-1df3-4dbc-8d8e-5a9f7551225f-detection-is-not-early-warning-evaluating-token-level.md)
- [Data-Efficient LLM Safety Alignment Guided by Interpretable Features](https://refivu.com/en/papers/d514fbae-eb94-4527-90e2-8212403262b6-data-efficient-llm-safety-alignment-guided-by-interpretable.md)
- [Beyond Word Error Rate: A Failure Taxonomy of Streaming Dictation ASR](https://refivu.com/en/papers/e8fb5a0c-b402-4b49-ba80-da8b68fe6fd6-beyond-word-error-rate-a-failure-taxonomy-of.md)
- [Auditing AI peer reviewers: a benchmark on real scientific papers](https://refivu.com/en/papers/c598dfe3-b1f5-4167-8e48-4616d3618025-auditing-ai-peer-reviewers-a-benchmark-on-real.md)
- [Joint Null-Space Projection for Data-Free Model Merging](https://refivu.com/en/papers/f9691bb7-ed21-4090-a4f1-370598491e09-joint-null-space-projection-for-data-free-model.md)
- [Can MLLMs Reason over Surround-View Driving Videos? A Multi-View Autonomous Driving QA Benchmark](https://refivu.com/en/papers/4b8d9089-87de-4543-b218-764bfa6f9850-can-mllms-reason-over-surround-view-driving-videos.md)
- [Where is My Mug? Training-Free Framework for Personalized Image Segmentation](https://refivu.com/en/papers/0286e0e9-1ea4-424a-aa68-549360c643fc-where-is-my-mug-training-free-framework-for.md)
- [The Neighbour's Label: Opposite Subgroup Effects of Same-Dialogue Exposure in Next-Act Evaluation](https://refivu.com/en/papers/c48d4fb9-6b58-4535-adf3-ac3ff1fd009d-the-neighbour-s-label-opposite-subgroup-effects-of.md)

## Terms in this paper

- [Planner](https://refivu.com/en/terms/7d6a4dbe5e87-planner)

---

AI-written text can contain mistakes. [Refivu](https://refivu.com/en/papers/960c67c8-5daf-4bf3-b6e9-64d4b7a65f38-caplite-prompt-injection-defense-for-small-language-model)
