Skip to main content

AI Smart Contract Security and EVMbench

EVMbench is an OpenAI and Paradigm benchmark testing whether AI agents can detect, patch and exploit smart contract bugs. How it works and what it means.

Written by Eco
AI Smart Contract Security and EVMbench

EVMbench is a benchmark from OpenAI and Paradigm that measures how well AI agents detect, patch and exploit high-severity smart contract vulnerabilities. OpenAI says it draws on 117 curated vulnerabilities from 40 audits, and Paradigm says it uses real vulnerabilities from open code audits plus custom tasks, "containerized per-task so agents operate in realistic environments" (OpenAI: EVMbench; Paradigm: EVMbench).
​

This article explains what EVMbench tests, why AI smart contract security matters for agents, and how teams use AI auditing alongside human review.
​

What Is EVMbench?

EVMbench is an evaluation for AI agents working on Ethereum Virtual Machine smart contracts. It scores agents on three tasks: finding vulnerabilities in a contract repository, patching them, and exploiting them in a test environment. The goal is a repeatable way to compare models that claim to help with contract security.
​

In the detect task, agents audit a repository and are scored on how many of the known, ground-truth vulnerabilities they find (OpenAI). The EVMbench paper was accepted to ICML 2026 (OpenReview).
​

How Does EVMbench Test AI Agents?

EVMbench tests AI agents by placing each one in an isolated environment with a real or custom contract codebase and asking it to detect, patch or exploit a known vulnerability. Results are compared against ground truth from prior audits, so a score reflects actual bugs found rather than plausible-sounding reports.
​

Task

What the agent does

Why it matters

Source

Detect

Audits a repository for vulnerabilities

Measures recall against known bugs

Patch

Fixes the vulnerable code

Tests whether fixes hold

Exploit

Exploits the bug in a sandbox

Shows real attack capability

Why Does AI Smart Contract Security Matter?

AI smart contract security matters because the same capability cuts both ways: models that find bugs for auditors can find them for attackers. A benchmark that measures exploitation gives defenders a sense of how capable automated attackers are becoming, and it gives auditors a baseline for which tools are worth adding to a review.
​

It also matters for coding agents. Developers increasingly use AI tools to write contract code, and generated code needs the same audit as human code. See smart contract audits for the human review process.
​

Should AI Replace Smart Contract Audits?

AI should not replace smart contract audits; current practice uses it as an additional pass alongside human auditors. Benchmarks like EVMbench measure recall on known vulnerability types, which is useful, but audits also cover design flaws, economic attacks and business logic that a benchmark task may not represent.
​

A related approach reduces how much custom contract code exists at all. Eco's Sauce SDK runs programs on an existing engine instead of deploying a new contract per program, so teams do not write, audit and deploy their own contract for each workflow (Sauce docs). That shifts review to the program's conditions. See security risks of autonomous AI agents.
​

What Kinds of Smart Contract Bugs Does AI Look For?

AI tools for smart contract security look for the same vulnerability classes human auditors look for. EVMbench focuses on high-severity issues drawn from real audits, which usually fall into a handful of well-known categories. Knowing the categories helps teams judge where an AI pass is likely to help and where human review still carries the weight.
​

Category

What goes wrong

How well automated tools tend to cope

Reentrancy

An external call lets an attacker re-enter a function before state is updated

Pattern is well known; tools often flag it

Access control

A privileged function is callable by the wrong account

Missing checks are often visible in code; intent may not be

Arithmetic and precision

Rounding, decimals or unit mismatches leak value

Needs understanding of the token math, harder to spot

Oracle and price manipulation

A contract trusts a price that an attacker can move

Requires reasoning about markets, not just code

Business logic

The code does what it says, but what it says is wrong for the protocol's goals

Hardest for any tool; needs the spec and context

Upgrade and initialization

Proxies, initializers or upgrade paths can be hijacked

Checkable, but depends on deployment details

The right column is a general description of the problem's shape, not a benchmark result. For model-by-model results, read the EVMbench paper and announcement directly (OpenAI: EVMbench).
​

How Teams Use AI in a Smart Contract Audit Workflow

Teams that use AI in audits treat it as one more reviewer with a specific job, not as a replacement for the audit. A workflow that fits most projects:

  1. Write the spec first. State what the contracts are supposed to do, who may call what, and which invariants must always hold. AI and human reviewers both need this to judge whether code is wrong.

  2. Run static analysis and tests. Deterministic tools and a strong test suite catch many simple issues cheaply.

  3. Run an AI review pass. Ask the model to audit the repository against the spec and list findings with the exact lines and a proposed exploit path.

  4. Triage findings. A person confirms or rejects each one. False positives are common; so are real findings described imprecisely.

  5. Reproduce real issues. Write a failing test or a proof of concept for each confirmed finding before fixing it.

  6. Human audit. External auditors review the code, the spec and the earlier findings, with attention to design and economic attacks.

  7. Re-review fixes. Every patch gets its own review, because fixes introduce bugs too.

EVMbench's three tasks map onto steps three, five and the patching that follows: detect, exploit to confirm, then patch (OpenAI).
​

Why Exploit Benchmarks Matter for Defenders

A benchmark that measures whether an AI agent can exploit a contract tells defenders something uncomfortable but useful: how much skill an attacker can now automate. If agents get better at turning a known bug into a working exploit, the time between a bug being discoverable and being exploited shrinks. That raises the value of finding bugs before deployment and of limiting how much value any single contract can lose.
​

It also changes how teams should think about deployed code. Contracts that hold funds and cannot be paused or upgraded become more exposed as automated exploitation improves. Teams should know, for each contract, what happens if a bug is found tomorrow: can it be paused, who can do it, and how quickly.
​

Vibe Coding Smart Contracts: What Can Go Wrong

Vibe coding means describing what you want to an AI tool and accepting the code it produces with little review. For web pages that may be fine. For smart contracts that hold money, the risks are specific:

  • Plausible but wrong access control: generated code may include an owner check on some functions and miss it on another.

  • Copied patterns from old code: models learn from public code, including code written before a vulnerability class was well understood.

  • Silent assumptions: the model may assume a token has a certain number of decimals, or that a price feed is always fresh.

  • No tests for the hard cases: generated tests often cover the happy path and skip the adversarial one.

  • Immutable mistakes: once deployed, a contract cannot simply be edited, so bugs persist until a migration.

AI coding tools are useful for contract work when the developer understands the code, writes the invariants, and treats generated code as a draft for review. Benchmarks like EVMbench measure the review side; they do not make generated code safe to deploy unreviewed.
​

Reducing the Amount of Custom Contract Code

One way to shrink the audit surface is to write less custom contract code in the first place. Many workflows, such as a swap with a minimum received, a payment to a list of recipients, or a rebalance to a target, do not need a new contract each time; they need a transaction that checks conditions and calls existing protocols.
​

Eco's Sauce SDK takes that approach. Programs are written in SauceScript, a subset of TypeScript syntax, compiled to bytecode for the V12 engine, and run through a Pot, with no new contract deployed per program (Sauce docs). The repository README puts it as "not a contract you write": there is no contract for the team to write, audit and deploy for each workflow (Sauce on GitHub). Review shifts to the program's conditions, which still need checking. The landing page's own wording is that a bytecode match shows reproducibility, not safety.
​

AI Security for Agents That Transact

Smart contract security and agent security meet when an AI agent can call contracts. Even a well-audited contract can be misused by an agent that calls it with the wrong parameters or follows an injected instruction. The defenses are different layers: audits protect the contract from attackers; execution limits protect the agent's funds from the agent's own mistakes. See security risks of autonomous AI agents and when an AI agent sends crypto by mistake.
​

Choosing AI Tools for Contract Review

Choosing an AI tool for contract review is easier with a short, practical test than with marketing claims. Take a contract your team already audited, where the findings are known, and run the tool on the version before fixes. Then check four things.

  • Recall: how many of the known issues did it find? This is the same idea EVMbench's detect task scores.

  • Precision: how many of its findings were real? A tool that buries two real issues under dozens of false ones costs reviewer time.

  • Explanation quality: could a developer act on its findings without re-deriving them?

  • Data handling: where does the code go, and is that acceptable for unreleased contracts?

Repeat the test when models change, since results can move between versions. Keep the test contract private so the tool cannot have seen the answers in public data.
​

Security Beyond the Code

Many large losses in crypto have come from outside contract code: stolen keys, compromised front ends, social engineering of signers, and misconfigured deployments. AI code review does not address those. A complete security program also covers key management, signer procedures, monitoring of deployed contracts, and an incident plan that says who can pause what. Benchmarks measure one slice of the problem well; teams need to cover the rest themselves.
​

How to Read an AI Audit Report

AI-generated audit findings vary in quality, so reviewers should read them with a few questions in mind. Does the finding point to exact lines? Does it describe a concrete sequence of calls that triggers the problem? Does it state the impact in terms of who loses what? Can it be reproduced with a test? Findings that answer all four are worth a person's time immediately. Findings that answer none are often pattern matches that do not apply to this code, though they occasionally point at something real described badly.
​

Frequently Asked Questions

Who built EVMbench?

OpenAI and Paradigm, per both organizations' announcement posts.
​

What does EVMbench measure?

Agents' ability to detect, patch and exploit high-severity smart contract vulnerabilities.
​

Can AI find all smart contract vulnerabilities?

No. AI tools find many known patterns but struggle with business logic and economic attacks that depend on the protocol's intent. Human audits remain standard.
​

Can you deploy AI-written smart contracts without review?

You should not. AI-written contracts need the same review, testing and audit any contract needs. Treat generated code as a draft.
​

What is the difference between detect, patch and exploit in EVMbench?

Detect asks the agent to find vulnerabilities, patch asks it to fix them, and exploit asks it to demonstrate an attack in a sandbox.
​

Does a passing AI review mean a contract can skip a human audit?

No. A clean AI review means the tool did not find issues it knows how to look for. Human auditors still review design, economics and the spec, which is where many serious and costly bugs live.
​

Related Reading

Sources: OpenAI, Paradigm and OpenReview pages linked inline, accessed November 2026.
​

Did this answer your question?