FailproofAI
Your agents are failing. FailproofAI saves them =D
Created on 8th August 2026
•
FailproofAI
Your agents are failing. FailproofAI saves them =D
What is the problem your project solves?
Your agent is doing things you never authorised, right now
We handed coding agents a shell and walked away. They run rm -rf, force-push over history, open ~/.aws/credentials, and pipe curl into bash — thousands of times a week, with nobody reviewing a single call.
This is not a hypothetical about future AI risk. It is happening today, on every developer machine, and it is invisible for one reason: the logs exist and nobody has ever read them.
We read one. An ordinary machine. 213 sessions, 17,711 real tool calls:
| What the agent actually did | Times |
|---|---|
Read files outside the project — neighbouring repos, ~/.aws/credentials, .env two directories up | 2,175 |
| Touched environment variables | 1,435 |
Opened .env files | 264 |
| Leaked connection strings into a model's context window | 176 |
Ran rm -rf | 21 |
Pushed straight to main | 14 |
Ran sudo | 9 |
Piped curl into a shell | 4 |
| Guardrails stopping any of it | 0 |
4,867 unauthorised actions. The owner of that machine would have told you their setup was fine — because there was no way to know otherwise.
The harm is real and it is already done
- Your secrets end up at a model provider. An agent reads
.env"for context". That API key is now in a transcript, on someone else's server, forever. You cannot un-send it. - Your history gets rewritten. Force-push,
--no-verify, commits straight tomain— the agent routes around the exact checks that exist to stop it, because they are friction. - Your boundaries do not exist. An agent following a reference walks out of your repo into a client's codebase sitting one directory over.
- Infrastructure gets touched.
kubectl delete,sudo systemctl restart,terraform apply— against something live, with no human in the loop. - It lies about being done. Declares success with tests unrun, changes uncommitted, merge conflicts unresolved.
None of this needs a misaligned model. A perfectly helpful agent produces all of it, because it was asked to get something done and nothing told it where the walls were.
Oversight is the missing layer
We have observability for servers, permissions for humans, and code review for commits. For the software now writing most of our code and executing arbitrary shell, we have nothing — no policy layer, no audit trail, no oversight at all.
The answer is not a better model. It is the same answer as every other system we let touch production: an enforcement layer that says no before the action happens, and a record of what it said no to.
That is failproofai — 40 policies enforcing at the hook layer of 12 agent CLIs, blocking the call before it executes.
But nobody installs a guardrail for a problem they can't see
This is where it actually breaks down. Enforcement only protects people who install it, and nobody installs a policy engine speculatively. You have to believe your agent is misbehaving first.
And the proof that it is has been sitting unread on your own disk the entire time.
That gap is what this project closes — between "agents do harmful things" and "mine did this, 2,175 times, and here are the commands."
How you are solving it?
Show people what their agent already did — then stop it happening again
npx -y failproofai-audit <your-name>
Thirty seconds. No install, no signup, nothing uploaded. It reads the session history already on your disk and replays every tool call your agent has ever made through a real enforcement engine — then shows you, command by command, what would have been blocked.
Live: https://fpai-push2prod.vercel.app
Hackathon repo: https://github.com/SiddarthAA/failproofai-audit
Policy engine: https://github.com/failproofai/failproofai
1. The oversight layer: enforcement at the hook boundary
failproofai intercepts before the tool call runs, and returns allow / deny / instruct. Not a report after the fact — by then the credential is already in the context window and the history is already rewritten.
40 builtin policies, each targeting a specific way agents overstep:
| The agent tries to | The policy that stops it |
|---|---|
| Read outside your project | block-read-outside-cwd |
Open a .env file | block-env-files |
| Leak a key into a transcript | sanitize-api-keys, sanitize-jwt, sanitize-connection-strings |
Force-push / push to main | block-force-push, block-push-master |
rm -rf, sudo, curl | sh | block-rm-rf, block-sudo, block-curl-pipe-sh |
| Touch live infra | block-kubectl, block-terraform, block-aws-cli |
| Finish with tests unrun | require-ci-green-before-stop |
| Disable failproofai itself | block-failproofai-commands |
Why this is hard, and what we had to solve:
- Twelve agent CLIs, twelve incompatible contracts. Claude Code blocks on exit code 2. Cursor ignores that entirely and needs
{followup_message}on stdout. Copilot needs a JSON decision object. OpenCode and OpenClaw expose no shell hooks at all and require in-process plugins. Each is normalised into one policy model. - It sits on the critical path. A guardrail that adds a second per tool call gets uninstalled by Friday. A Rust daemon with a pre-warmed Node worker keeps the ~700 ms cold start off every real call.
- It fails closed. A guardrail you can disable by stopping a service isn't one. On a configured machine, an unreachable daemon or a protocol mismatch denies.
2. The audit: proof, from your own machine
The audit is not a linter with its own rule list. It replays your real history through the exact same engine that would have been enforcing — which makes every finding a counterfactual, not an opinion: this command, on this date, in this project, would have been blocked.
Discovery — 12 adapters read local session stores: Claude Code, Codex, Cursor, Copilot, OpenCode, Pi, Factory, Devin, Antigravity, Goose, Hermes, OpenClaw. JSONL, SQLite, encoded-cwd folder layouts — each with its own format and tool-name canonicalisation.
Scoring — rate-normalised so a busy agent isn't punished for volume; each severity bucket saturates so one bad habit can't alone bottom you out. Gives a 0–100 score, an S–F grade, and a projected score: what you'd get with the missing policies on. On the demo machine, 19 → 92.
Archetype — 8 personas (the cowboy, the explorer, the goldfish, the paranoid architect…) from which policies you trip, weighted against how often each fires for a typical agent. It reflects what you do more than most, not just what you do a lot of.
Evidence — every finding expands to your actual commands, with when and where. That is the moment the abstraction becomes real: not "agents read files they shouldn't" but your cat ../other-repo/.env, on a Tuesday.
3. Privacy is what makes it adoptable
A scan of your shell history is exactly what people won't run for a stranger. So the architecture makes the promise structurally true:
| Never leaves your machine | Sent to the leaderboard |
|---|---|
| Your commands | Policy names |
| File paths, project names | Hit counts |
| Transcripts, cwd | Tool-call totals |
35 KB of scan becomes ~8 KB of counts. The evidence drawer renders locally and is stripped before the POST. The CLI prints exactly what was sent when it finishes.
4. The loop
See what your agent did → get a score and an archetype → share it → enable the policies → re-run and watch it climb. The prescription isn't "be careful" — it's failproofai policies --install block-read-outside-cwd, after which the thing you were just shown becomes impossible.
Built during the hackathon
The audit engine is vendored from failproofai (linked above) and cited as such. Everything else was built today: the standalone npm package and CLI, the local report UI, the whole leaderboard app (ingest, server-side derivation, board, room stats, projector mode, share cards), the database, and the deploy. Published to npm and live on Vercel — verified end to end with a real scan landing on the public board.
How Did You Use Claude?
Claude is both the subject and the builder
1. Claude Code is what the product measures
The primary data source is Claude Code's own session transcripts (~/.claude/projects/<encoded-cwd>/<session>.jsonl). The adapter parses Claude's typed content blocks — tool_use / tool_result — reconstructs each call with its arguments, cwd and timestamp, and replays it through the policy engine. Claude Code subagent transcripts are walked too.
Of the 12 supported agent CLIs, Claude Code is the one the scoring and archetype model were calibrated against, and it's where the demo data comes from.
2. Claude Code built it
The entire project was built in a single day in a Claude Code session — the npm package, the CLI, the local report UI, the leaderboard app, the database layer and the deploy.
The work that mattered wasn't code generation but investigation. Several bugs were only findable by reasoning about a live system, and each was caught before it reached a user:
- A blank local report. The bundled report contains the literal string
</scriptinside a dependency. Inlined into a<script type="module">, the HTML parser closed the tag there — only 194,152 of 426,728 bytes reached the JS engine. Diagnosed by extracting the served module back out of the HTML and runningnode --checkon it. - A silently empty leaderboard. Values bound to
jsonbcolumns were double-encoded, sojsonb_array_elementsfailed with "cannot extract elements from a scalar" — and because the read path caught errors and returned an empty payload, a broken query looked exactly like an empty room. - 16 of 20 submissions failing under load.
CREATE INDEX IF NOT EXISTSran on every request and took a table lock, so a burst contended on DDL instead of inserting. A hackathon booth is a burst. - Six of eight archetype glyphs rendering as noise — measured against the design system's own symmetry rule rather than eyeballed.
3. Claude for design judgement
The colour palette was validated, not chosen by taste: running the grade colours through a contrast/colour-blindness validator failed them (green vs olive at ΔE 13.1 against a floor of 15), so the charts were re-formed as single-hue with identity carried by labels — a design decision made from measurement.
4. The product exists to make Claude Code safer
The output is a prescription for failproofai, which enforces these same policies at Claude Code's hook layer in real time. The audit shows you the counterfactual; the fix blocks the action before it happens.
What is the deployed URL for this project?
https://fpai-push2prod.vercel.app
Technologies used
