v0.4.0 — now on npm

Your coding agent says
"fixed." Verfix checks.

Verfix closes the loop: deterministic browser verification for AI coding agents.
Local-first, no Docker — structured JSON for agents, a recorded trace for humans.

npx verfix init

Does it actually close the loop? We measure it.

The loop-closure benchmark: 8 deliberately broken tiny apps spanning a failure taxonomy — drifted selectors, an occluding modal, a stale session, changed copy, a broken API, and more. The agent gets only Verfix's JSON as its failure signal — no human hints.

AgentClosure rateMean iterations
Codex 7/8 (88%) 2
Cline 6/8 (75%) 2
Grok 5/8 (63%) 2
Null agent (does nothing) 0/8 — enforced in CI
Oracle (known-good fix) 8/8 — enforced in CI 2

Anti-cheat invariants mean deleting an assertion doesn't count as closing the loop — every failed case above was the agent getting caught fixing things the wrong way. The benchmark self-tests in CI: a null agent that scores anything but 0% or an oracle that scores anything but 100% fails the build. Results are from v0.4.1, 2026-07-16 — run it with your own agent.

Stop manually clicking through flows

AI agents generate entire application flows in seconds. Verifying those flows still requires a human.

WITHOUT VERFIX
1Agent writes UI code
2You open browser manually
3Click through every flow
4Spot the bug yourself
5Tell the agent what broke
WITH VERFIX
1Agent writes UI code
2verfix run --flow login
3Structured JSON + fix_hint returned
4Agent reads hint, fixes, retries
5You review timeline if needed

Three steps from zero to verified

This is loop engineering: a goal, a verifier, and a stop condition — not another model grading its own work. Verfix is the verifier.

STEP 01

verfix init

Configure in 30 seconds

The wizard detects your app's URL, makes sure Chromium is available (no Docker, just Node.js), and generates AGENTS.md — read natively by Claude Code, Cursor, Codex, and Copilot — plus an empty verfix.config.json. No preset flows — the agent writes the first one from your actual source.

STEP 02

verfix run --flow <id>

Agent-driven verify loop

Every UI change triggers a flow run — in-process, in your terminal, no queue to poll. The agent receives passed, failures[], and fix_hint. It fixes and retries autonomously, and a source guard flags it if it tries to rewrite your app code instead of the flow.

STEP 03

verfix show <id>

Recorded trace, on demand

If the agent can't self-fix, verfix show opens the full Playwright trace for that run — every action, navigation, console error, network request, and failure screenshot, replayed exactly.

Why not just let the agent drive a browser?

You can — but an improvised check is the agent grading its own homework with a rubric it rewrites every iteration. Verfix inverts it: a fixed instrument the agent can push against.

Agent drives a browserVerfix
Check between iterations different every time byte-identical
Failure output prose / screenshots to interpret 8 typed failure codes + fix_hint
Cost per verification LLM tokens, every time zero tokens in strict mode
Agent edits the measuring stick silent flagged (source-guard)
Evidence whatever it mentions recorded Playwright trace, replay with verfix show

Deterministic by default, AI when it earns it

Each flow can override the global mode — stable flows stay strict, evolving ones use assisted.

ModeSelector strategyAIBest for
strict CSS / data-testid only, fails explicitly none CI/CD, regression
assisted Selector → semantic → AI fallback, in that order on failure Active development
exploratory Natural-language task, AI plans and drives core driver Ad-hoc QA, discovery

Whichever mode fails, the fix goes into the flow, not your app — the easy failure mode for an agent under pressure is sprinkling data-testid through your components until a test goes green. A git-baseline source guard reports every project file an agent touches mid-fix, and sourceCodePolicy: "block" can fail the run until a bogus edit is reverted. See Config-First Verification.

Up in four commands

Requirements: Node.js 20+. That's it — no Docker, no accounts, no cloud.

1

Install

npm install -g verfix
2

Init your project

npx verfix init

The wizard detects your app URL, creates verfix.config.json, and writes AGENTS.md. Default mode is strict — fully deterministic, no AI key needed. Use verfix init --yes for non-interactive mode.

3

Run a flow

verfix run --flow login --output json

Runs in-process. Returns structured JSON. Exit code 0 on pass, 1 on failure.

4

Inspect the trace

verfix show

Opens the newest run's full Playwright trace — every action, console log, network request, and screenshot. Runs and traces persist under .verfix/runs/.

Questions, answered

Is Verfix an AI agent?

No. Verfix is the execution infrastructure for AI agents — the observability, retry mechanics, and structured output that let an agent verify its own UI changes.

Do I need Docker, an account, or AI to use it?

No to all three. strict mode (the default) runs entirely in-process on Node.js 20+, needs no AI key, and there's no hosted SaaS to sign up for. Docker is only needed for the opt-in --server runtime, used by the future hosted CI product.

Will an agent rewrite my app to make a broken test pass?

That's the failure mode Verfix is built to prevent. See Config-First Verification — agents are steered to fix the flow, not your source, and a git-baseline source guard can block a run that edits project code to satisfy a selector.

What is loop engineering?

Designing the goal, verifier, state, stop condition, and escalation of an agent's iteration loop, instead of prompting turn by turn. Verfix is the verifier half — typed pass/fail, JSON state between iterations, exit codes as the stop condition, and a hand-off to a human when it's stuck.

What does it cost?

Nothing. Verfix is free and open source under the Apache 2.0 license.

Verify your first flow in under 2 minutes

No Docker, no accounts, no cloud. Just Node.js and one command.

npx verfix init
Read the docs →