Dev Patel

v0.1.0 · dry-run verified · Oct 2026 → Present

Your Agent vs. Their Agent

It fights the billing department.
You approve every word.

An open-source agent that disputes bills, appeals denials and reverses fees for you — it reads the document, finds the errors, drafts the letter and chases the deadline, and sends nothing without your approval of the exact text.

The approval screen: a drafted request to reverse $142 in bank fees, waiting on one button. Approval is tied to a hash of this exact text. Fictional demo case.

Highlights

61editable playbooks
12deterministic checks
111tests

The problem.

Billing departments count on friction. A duplicate charge on a hospital bill, an MRI denied as not medically necessary, an overdraft fee you never opted into: each is recoverable, and each takes a letter, a deadline nobody tells you about, a follow-up and an escalation.

An AI that writes those letters for you has to be held to a higher bar than one that writes emails. It mustn't invent an amount, accuse a hospital of something it only suspects, or send anything you didn't read.

What I built.

Intake reads PDFs, scans and photos; with an API key Claude extracts structured facts against a schema, and without one a regex parser handles common layouts — every case shows which path produced its facts. Twelve deterministic checks look for duplicate charges, unbundled lab panels, math errors, likely surprise-billing violations and overdraft fees without an opt-in. They never invent amounts.

Six playbooks — medical bill, insurance denial, bank fee, card dispute, parking ticket, subscription — are editable Markdown files with steps, follow-up timers, deadlines with their legal basis and an escalation map. A state machine runs them on an injectable clock: draft, approve, execute, follow up, nudge, escalate, read the reply, next step.

Every outbound message starts awaiting approval, and approval stores a SHA-256 of the exact channel, recipient, subject and body, so editing the draft voids it. Dry run is the default; live sending needs a setting and a typed SEND per action. Every approval, refusal and send lands in a hash-chained audit log that detects edits and deletions.

Screens.

The dashboard after the demo's simulated weeks: money at stake against money recovered, six drafts awaiting approval, and every case's next step. All fictional.
The dashboard after the demo's simulated weeks: money at stake against money recovered, six drafts awaiting approval, and every case's next step. All fictional.
An internal insurance appeal rendered to PDF in dry run, built from the patient's own notes and citing the rules it relies on. Fictional patient and plan.
An internal insurance appeal rendered to PDF in dry run, built from the patient's own notes and citing the rules it relies on. Fictional patient and plan.

What I considered.

Rejected

Let the model rewrite letters freely

Templates produce a complete draft offline; Claude only tailors it, and a fact guard rejects any rewrite that drops or changes a claim number, account number or dollar amount.

Rejected

Draft as soon as a document has been read

Rejected after review. A misread parser would have produced confident false claims. Each case type has key facts; if one is missing or only guessed, the case waits for you and nothing is drafted.

Chosen

Approval bound to the exact text, dry run by default, and an audit log you can verify

Uncertain findings ask questions instead of accusing, and possible ticket defects never go in a letter. The cost is that nothing happens on its own: you mail the letters, and no AI voice negotiates on the phone yet.

Results.

  • make demo runs two fictional cases on a simulated clock from first letter to final outcome: a medical bill with a duplicate X-ray and an unbundled lab test ($476 removed), and an MRI denial taken to external review and overturned ($2,350).
  • All 18 demo approvals and executions are recorded in the hash-chained audit log, and every action is approved explicitly and run in dry run.
  • An independent review drove 22 regression tests, including the key-facts gate, refusal to approve drafts with unfilled blanks, and hedged letter language for uncertain findings. 111 tests in CI.
  • Live SMTP, Gmail and Twilio bridge calls are implemented against their real APIs and tested with mocked transports only.

Architecture

How it fits together.

DocumentPDF · scan · emailExtractClaude or offlineparser · key factsChecks12 deterministicscreensPlaybookstate machinedeadlines · escalationYour approvalSHA-256 of the textaudit log → outbox
  1. 01

    DocumentPDF · scan · email

  2. 02

    ExtractClaude or offline · parser · key facts

  3. 03

    Checks12 deterministic · screens

  4. 04

    Playbookstate machine · deadlines · escalation

  5. 05

    Your approvalSHA-256 of the text · audit log → outbox

The model can read and draft. Only an approval of the exact text, from you, lets anything out.

In hindsight

The live Claude path has never run against the real API — the demo's model responses are hand-authored fixtures, labelled as such everywhere they appear — and the rules it cites are general U.S. federal baselines with a 'verify' note on each. It isn't a lawyer and says so. The review taught me the difference between an error in a chat answer and an error in a letter with your name on it: the most important code in the project is the gate that refuses to draft when it isn't sure of a fact.

Tech specs.

Type
Project
Where
Personal
When
Oct 2026 → Present
Duration
1 mo
Status
v0.1.0 · dry-run verified
Stack
PythonClaudeFastAPIJinjapydanticSQLiteTesseractreportlabGitHub Actions
Caveats
Demo cases and documents are fictional. The live Claude path, SMTP, Gmail and Twilio are tested with mocks only; the demo replays hand-authored model responses.