Undercut for Zed

Zed's agent already watches .agents/skills/. Give it one that stops overpaying.

Undercut is a free, MIT-licensed policy file Zed's built-in agent panel loads the same way it loads any other Agent Skill — cheap tier first, escalate only on evidence, never on a vibe. Zed's agent is multi-model by design, wired up to whichever provider you configure; the rubric doesn't care which one that is, only whether the unit of work is mechanically verifiable.

Install for Zed See the benchmarks
Works anywhere a SKILL.md is read
Claude Code Codex Cursor Copilot Zed

How this maps onto Zed

.agents/skills/ is Zed's own native path — not a cross-tool alias.

Zed ships a documented Agent Skills mechanism: a skill is a folder containing a SKILL.md file with YAML frontmatter (name, description), and Zed watches two skill roots — <worktree>/.agents/skills/<name>/ for the current project, and ~/.agents/skills/<name>/ globally. That's the exact directory Undercut already ships under, and it's Zed's primary, first-party path for this — not a compatibility fallback borrowed from another tool. By default the agent picks up skills autonomously: it sees a catalog of every installed skill's name and description in its system prompt and calls the skill when a task matches, the same gated discovery every other companion page on this site describes.

Separately, Zed also has an Instructions mechanism for always-on context — a project root file, checked in a fixed precedence order (.rules, then a handful of legacy per-tool rules filenames, then AGENTS.md, then CLAUDE.md, then GEMINI.md, first match wins), plus a personal ~/.config/zed/AGENTS.md. Zed's own docs describe Skills, not Instructions, as the fit for conditional, invoked-by-name guidance rather than blanket always-on rules — which is what a scored routing rubric is, so Agent Skills is the path this page installs to.

Undercut's tier names — cheap, standard, frontier, apex — are generic on purpose. Zed doesn't lock you to one vendor's model lineup; whichever provider you've configured, models.md resolves each tier to a real model for that family. Nothing about this sits between Zed and your model provider — it's a policy file the agent reads at dispatch time, no proxy, no network hop, nothing to route around if you remove the skill folder.

Install for Zed

Free. MIT. Nothing installs, nothing proxies your traffic.

Option 1 — copy the skill directory directly (recommended, confirmed path)

Clone or download undercutsh/firstpass, then copy skills/firstpass/ into .agents/skills/firstpass/ at the project root. Zed watches that directory and picks up the change without a restart.

$ mkdir -p .agents/skills && cp -r firstpass/skills/firstpass ./.agents/skills/firstpass

Option 2 — install once, for every project

Zed also watches a global skills root, so it doesn't need to live in each repo: ~/.agents/skills/ (%APPDATA%\Zed\-relative on Windows, per Zed's own docs).

$ mkdir -p ~/.agents/skills && cp -r firstpass/skills/firstpass ~/.agents/skills/firstpass

Zed's docs note that skills must be direct children of the skills root — nesting a skill folder inside a subfolder isn't picked up.

Option 3 — skills CLI

$ npx skills add undercutsh/firstpass

What's still unverified: the community skills CLI lists Zed among its supported targets and says it "installs SKILL.md files into your repository so Zed can reference them," but doesn't publish which exact directory it writes to. Since .agents/skills/ is Zed's own documented path, this option most likely lands there — but we haven't confirmed it end-to-end against a real Zed session, so treat it as unverified until you check. Option 1 or 2 above is directly confirmed against Zed's own docs.

Validate it yourself

  1. 1Read the published results — testing/README.md and the raw JSON in testing/results/
  2. 2Reproduce for free, no API key, no spend: node src/main.js --mock
  3. 3Open Zed's agent panel on a repo with the skill installed and check whether it lists firstpass in its skill catalog before starting mechanical work

Zero lock-in. It's a policy Zed's agent reads — delete the directory and you're back to status quo.

How it works

The Undercut Rubric · v1

Six flags assign a tier. Three triggers are the only way up.

This is a named, versioned spec — not internal logic we could quietly change. When the rubric changes (a new flag, a different cap), the version number moves and the changelog says why.

Every unit of work gets scored against six flags, then assigned the cheapest tier that can plausibly handle it. It only moves up a tier when something objective proves it needs to — a failed check, a measured disagreement, an explicit uncertainty flag. It never moves up on a guess, and it never moves back down mid-task.

unit of work
6-flag rubric
0 flags
cheap~90% of units land here ✓
1–2
standard
3+/own
frontier
↑ escalate +1 tier only on: fail ×2 · two runs disagree · tagged "uncertain" residue only — never redoes the batch
See the rubric

Step 1 — Base tier, six-flag rubric

Unverifiable — can output be checked mechanically? (tests, schema, diff, grep)
Ambiguous — one right answer, or several defensible ones?
Blast — reversible? touches money, auth, user data, production, deletes?
Cross-cutting — one file/source, or reasoning across many?
Novel — pattern-following, or genuinely new design?
Format-strict — must output match an exact schema?

0 flags → cheap · 1–2 → standard · 3+ or any ownership/judgment call → frontier. Apex only when you can write one sentence stating why the marginal intelligence pays for the cost.

The override — single biggest lever

Cheap-to-verify ⇒ cheap-to-generate. If output can be checked mechanically, it starts at the lowest tier regardless of how hard it looks — verification catches failure. Only unverifiable work needs to start high.

Step 2 — Escalate exactly one tier, on evidence only

  • Verification fails twice at the current tier
  • Two cheap-tier runs disagree on ambiguous-flagged work
  • The worker tags an item "uncertain"

Residue-only handoff

The next tier up gets only the failed or uncertain items, plus verification notes. It resolves the residue — it never redoes the batch.

Hysteresis — guardrails

Never de-escalate mid-task. Max one retry per tier. Anything still unresolved goes to a single batched apex tie-break call. One hard file in a 700-file job doesn't drag the other 699 up a tier.

 unit of work
      |
  6-flag rubric
      |
  +---+----+
  | 0 flags|--> cheap
  | 1-2    |--> standard
  | 3+/own |--> frontier
  +---+----+
      | fail x2 / disagree / uncertain
      v
  escalate +1 tier
  (residue only)
      |
  still unresolved?
      v
  single batched
  apex tie-break

Why it holds up

Flags steer. Verification and escalation decide.

Even when the rubric flags are scored imperfectly, the escalator still routes work to the right tier almost every time — because a wrong flag only ever costs one extra cheap attempt, never a wrong answer or a big bill.

See the data

A stock dispatcher model reproduces the rubric flags imperfectly — Haiku hits 90% agreement, Sonnet 93%. The weakest flag (format-strict) is only 60%. None of that matters: under the shipped policy, both dispatchers still route 100% of units to the correct tier. A wrong flag changes the ladder cap, never the base tier — worst case, one extra cheap attempt.

Haiku dispatcher
90% flag agreement
100% tier-match
Sonnet dispatcher
93% flag agreement
100% tier-match

The rules are about the work, not the model.

Every rule is a property of the unit of work — verifiable, ambiguous, blast-radius — never a specific model's known weakness. Vendor cards go stale as models change; work properties don't. It's also hard-won — a format-strict rule that worked on Anthropic backfired on Gemini, which is exactly why the rubric no longer encodes per-vendor behavior.

Honest limits

What this doesn't do.

Not a proxy, not a gateway, doesn't enforce anything at the network layer, and doesn't auto-flag in production — Zed's agent scores the flags itself (measured robust to getting them wrong, see above). Doesn't promise a dollar figure for your workload — savings are workload-dependent, and real workloads escalate more than benchmarks. Every figure on this page is an observation from our tasks and our graders, not a guarantee about your codebase — verification is not proof, it's a reproducible data point you can run yourself. The Instructions-vs-Skills distinction described above is Zed's own documented split, but we haven't independently run this skill inside a live Zed agent session end-to-end; treat that specific claim as unverified until you check it against Option 1 above. Full list of general limits, with the finance/procurement note and the paid-tier disclosure, is on the main page.

Undercut the top tier. Not the quality bar.

Nothing about this page expires. What does keep happening is the token bill, one session at a time, on whatever Zed's agent is currently doing with mechanical work.

View on GitHub