Skip to main content

Prompt Injection Benchmarks: AgentDojo, InjecAgent and BIPIA Explained

· By Natalie Walls

Prompt injection benchmarks are shared test sets that measure how often a model or agent follows instructions hidden in content it reads. The three most cited are BIPIA, InjecAgent and AgentDojo, and each tests a different setup: plain question answering over documents, single tool calls, and full multi step agents.

Here's what each one measures, taken from the papers themselves, and how to read the numbers you see quoted.

BIPIA: injection in everyday tasks

BIPIA, by Jingwei Yi and colleagues, describes itself as "the first benchmark for indirect prompt injection attacks" (Yi et al., arXiv). It hides malicious instructions in external content across five tasks: email QA, web QA, table QA, summarization and code QA (full paper).

  • Attacks: 30 text attack types and 20 code attack types, each with five instructions.
  • Size: 86,250 test prompts, with separate attack types held out for testing.
  • Finding: the models tested were broadly vulnerable. The authors say models struggle to tell context from instructions and don't know when not to follow instructions found in outside content.

BIPIA also proposes defenses based on boundary awareness and explicit reminders. It's a good fit if your app summarizes or answers questions about documents but doesn't take actions.

InjecAgent: injection that triggers tools

InjecAgent, by Qiusi Zhan and colleagues, moves the test into tool use (Zhan et al., arXiv). A tool returns content containing an attacker's instruction, and the question is whether the agent then calls a tool the attacker wants.

  • Size: 1,054 test cases covering 17 user tools and 62 attacker tools.
  • Attacker goals: direct harm to the user, or stealing private data.
  • Finding: across 30 agents tested, a ReAct-prompted GPT-4 was vulnerable 24% of the time, and adding a "hacking prompt" to the attacker's text nearly doubled that.

It's a good fit if your agent calls tools based on what it reads, like an email or calendar assistant.

AgentDojo: realistic multi step agents

AgentDojo, by Edoardo Debenedetti and colleagues, was published in the NeurIPS 2024 Datasets and Benchmarks track (NeurIPS proceedings). It gives agents realistic jobs, like managing email, using an e-banking site or booking travel, and plants injections in the data they handle (Debenedetti et al., arXiv).

  • Size: 97 tasks and 629 security test cases.
  • Two scores: utility, meaning whether the agent finishes the user's task, and security, meaning whether it avoids the attacker's goal.
  • Design: the authors stress it's an extensible environment, not a fixed test suite, so you can add new tasks, attacks and defenses.

Scoring utility alongside security matters. A defense that blocks every injection by refusing to do anything would look perfect on security alone.

Quick comparison

BIPIAInjecAgentAgentDojo
SettingDocument tasksSingle tool callsMulti step agents
Test cases86,250 test prompts1,054629 security cases
Best forSummarizers, RAGTool-using assistantsFull agents

How to read benchmark numbers

A score is about the benchmark, not your app. A 2026 study tested fifteen injection detectors on AgentDojo, tau-bench and BIPIA and found rankings transferred poorly. The best detector on BIPIA caught only 2% of AgentDojo injections at a 1% false positive rate (Liu, arXiv). The author links this to how closely test data matches each detector's training data.

Passing isn't proof. NVIDIA's red teaming research makes the same point: passing public benchmarks doesn't show a model is secure, though failing one does reveal a weakness (NVIDIA Technical Blog).

Check the date. Models change fast. A vulnerability rate from a 2024 paper describes the models tested then.

Using benchmarks in practice

  • Use them to compare defenses under the same conditions, not as a safety certificate.
  • Pick the benchmark closest to your setup: documents, single tools or full agents.
  • Build a small private test set from your own tool outputs, because that's what your users' attackers will use.

Your private set can start very simply. Put a harmless instruction, like asking the model to print CANARY-7, into the kinds of documents your app actually reads, and check whether the marker shows up. Our canary payloads give you six ready made starting points. For how detectors fit in, see Prompt Injection Detection Tools, and for wiring tests into your pipeline, read Automated Prompt Injection Testing in CI.