Vision model + plain-code checks · tested on 25 invoices

Invoice photo in.
Checked data out.

An AI reads the invoice into clean data. Then ordinary code adds up every line, checks the tax and the dates, and a second AI reads it again. If anything doesn't match, a person looks at it before it reaches your books.

0wrong values auto-approved, in 75 test reads
10/10invoices with a planted mistake sent to a human
—clean invoices approved with no human
—median time per invoice, two reads in parallel

Try it

Read an invoice.

Pick one of the 25 made-up test invoices (some have a planted mistake), switch to the rough phone photos, or drop your own. Your photo is read and thrown away.

Drop an invoice photo here or · PNG, JPG, WebP
Waiting for an invoicePick a sample above. It takes about 8 seconds: two models read it at the same time.

The extracted fields show up here, each marked with how sure the system is. You can edit any number and the checks re-run.

How it decides

The AI reads. Code decides.

A vision model is good at reading and bad at arithmetic it can't see. So it's told to copy numbers exactly, even wrong ones, and plain code does the checking.

  1. 1

    Read

    Llama 4 Scout turns the image into JSON: vendor, number, dates, lines, tax, total. It must copy what's printed, never fix it.

    "total": 28160.36
  2. 2

    Read again

    Mistral Small 3.1 reads the same image separately. If the two disagree on any number, date or invoice number, a human looks.

    Scout 28,160.36 · Mistral 28,160.36
  3. 3

    Check

    Six checks in plain code: required fields, every line's quantity × price, lines vs subtotal, the total, the tax rate, and the dates.

    23,852 + 4,293.36 + 15 = 28,160.36
  4. 4

    Decide

    All checks pass and both reads agree: approved. Anything else: sent to a person, with the reason written out.

    approved · 6/6 checks

Test results

25 invoices, read 3 times each.

Made-up invoices in 5 layouts and 6 currencies. 8 are photographed at an angle. 10 have one mistake planted in them, like a line that doesn't add up.

Every read, live setupclick one
Approved, all correctSent to a humanApproved with a wrong valuehas a planted mistake

Hover or tap a square.

FAQ

Fair questions.

The code, the 25 test invoices and every model reply are on GitHub.

Why not let the AI check the maths?

Because it doesn't need to. Adding up lines is exactly what ordinary code does perfectly. The model is only asked to copy what it sees. If it misreads a number, the arithmetic usually stops adding up, and that is caught.

Why read it twice with two different models?

Some misreads still add up: a wrong invoice number or date breaks no arithmetic. A second model reading separately rarely makes the same mistake, so disagreement is a cheap signal to ask a human.

What happens to my photo?

It is sent to the two models, the result comes back to your browser, and that's it. The image and the extracted text are not stored. Only whether it was approved, which checks failed, and how long it took are logged.

Are the test invoices real?

No. All 25 are generated by a script in the repo, with made-up businesses and a "sample invoice" line on every page, so there is no customer data anywhere. The script also records exactly what is printed, which is what the reads are graded against.

What can't it do?

It hasn't been tested on multi-page invoices, Urdu or Arabic text, or very blurry photos. A clean invoice with a wrong vendor name would pass the checks if both models misread it the same way. That's the case a human spot-check is for.

Can it put the data into my accounting software?

This demo stops at checked JSON. Sending approved invoices to QuickBooks, Xero, Zoho Books or a Google Sheet, and the rest to a review queue, is the next step and is a normal integration.

Work with me

Typing invoices into a spreadsheet?

I'm Abdullah, a frontend developer in Lahore who builds AI tools. I'll set this up on your invoices, test it on a sample of your real ones before it goes live, and connect it to where the data needs to go.

  • Your invoices, testedthe same checks, run on a sample of yours first
  • A human queueanything that doesn't add up waits for a person
  • Your softwareapproved data straight into your books or sheet