agent-scorecard

Open-source scanner · CLI and MCP server

How safely is your agent built?

Point it at an agent codebase and get a 0 to 100 score across the seven layers that keep agents out of trouble, with file and line evidence for every finding and the fix for every gap.

$ pipx install agent-scorecard && agent-scorecard scan ./my-agent
Read-only. Never runs your code Zero runtime dependencies Python, TS, Go
$ agent-scorecard scan ./my-agentexample
77/100
CGrade Ccapped by a missing critical control
  1. 1Tool boundaries54
  2. 2Human approval gates100
  3. 3Audit trail92
  4. 4Secrets and egress62
  5. 5Budgets and limits100
  6. 6Untrusted input57
  7. 7Evals and rollback71
UI-01 Untrusted content is marked as data. MISSING: web pages and tool results reach the model with nothing telling it they are data, not instructions. agent/prompts.py:41

The rubric

27 checks across seven layers

Each check says why it matters, what the scanner looks for, what earns full and partial credit, and how to fix it. Checks that can't apply, like sandboxing in an agent that never runs commands, are left out of the score instead of counted against you.

L1Tool boundaries

Tools are allowlisted, tiered by risk, sandboxed when they execute, confined to a workspace, and pinned.

TB-01TB-02TB-03TB-04TB-05

L2Human approval gates

Risky actions wait for a person, the approval is bound to that exact action, and anything unexpected fails closed.

AG-01AG-02AG-03AG-04

L3Audit trail

Every tool call is a structured event, traced end to end, stored where it can't be quietly edited, with secrets redacted.

AU-01AU-02AU-03AU-04

L4Secrets and egress

No keys in the repo, secrets loaded at runtime, scanning in CI, and outbound calls limited to known hosts.

SE-01SE-02SE-03SE-04

L5Budgets and limits

Hard caps on steps, spend and time, so a loop or a bad prompt can't run all night on your card.

BL-01BL-02BL-03

L6Untrusted input

Fetched content is labelled as data, model output is schema-validated, and tool arguments are checked before use.

UI-01UI-02UI-03

L7Evals and rollback

Tests run in CI, behaviour evals and safety tests exist, and there is a kill switch or dry-run mode.

ER-01ER-02ER-03ER-04

Orange IDs are critical controls. Missing any one caps the grade at C, whatever the rest looks like.

Field test

Seven agent repos, scored

Three popular open-source agents and four of my own, each pinned to a commit so anyone can reproduce the result. The best-known project did not score the highest, and my own ranged from an A to an F.

RepositoryScoreGradeL1L2L3L4L5L6L7Critical gaps

Scored on 9 November 2026 with agent-scorecard 0.1.0. A grade with * is capped at C by a missing critical control; a dash means the layer doesn't apply because the app never calls tools. These are static signals, not a penetration test.

Scoring

Built so one strong layer can't hide a missing one

The number is a summary. The useful output is the list of gaps, each tied to the line of code it came from.

PASS 2 · PARTIAL 1 · MISSING 0

Weighted by severity: critical ×3, high ×2, medium ×1. Not-applicable checks drop out.

Layers average evenly

A perfect audit trail doesn't make up for having no approval gate, so each layer counts the same.

Critical gaps cap the grade

A 90 with no step cap is still a C. Grades run A at 85 and up to F under 40.

Comments don't count

"We fail closed" in a docstring is not a control. Tests, examples and dev tooling are kept out of production signals.

Agent Safety Review

The scanner finds signals. The review checks they hold.

A fixed-price review by a senior engineer who builds production agents, delivered in five business days. For teams heading into a launch, an enterprise deal or a security questionnaire.

Scorecard Review

$1,500fixed
  • Annotated scorecard, every finding checked by hand
  • Top 10 fixes ranked by risk and effort, with code-level guidance
  • A one-page summary for your customer's security reviewer

One agent, one repo · 5 business days

Full Review

$3,000fixed
  • Everything in the Scorecard Review
  • Threat model: what the agent can touch and who can steer it
  • Data-flow review of secrets, customer data and untrusted input
  • Prompt-injection walkthrough against your real tools
  • 60-minute call with your team, and a re-score within 30 days

One agent with its tools, MCP servers and deploy config · 5 business days

Code only, no production accessRead access to the repo or a tarball. Nothing is run against your systems.

Half up front, half on deliveryIf the report doesn't give you five fixes worth making, you don't pay the second half.

Your code stays yoursReviewed privately, deleted 30 days after delivery, NDA on request.

Send a line about your agent and what it can do. You'll hear back within one business day with a fit check and a start date.

Book a review