Proof of concept · synthetic B2B invoices · 6,468 invoices, 2023–2026

Biomix invoice triage

Every incoming invoice is checked before it is paid. Plain rules handle the clear cases, a model called Jev looks at the doubtful ones, and only what is still doubtful reaches a person. On this data, 99.6% of invoices are approved automatically and 21 go to a reviewer.

Where the invoices went

  1. Tier 1 · Rules 6,468invoices checked against 9 rules
    • 6,043 pass every rule → approved
    • 404 billed ≤ 2 days after the customer's previous invoice → Jev
    • 14 flagged as a likely rebill → review
    • 7 sent twice (corrections) → out of scope
  2. Tier 2 · Jev 404near-duplicates scored by the model
    • 397 score below 0.39 → approved
    • 7 score 0.39 or more → review
  3. Tier 3 · People 21invoices for a reviewer, 0.3% of all
    • 14 from the rules
    • 7 from Jev
SplitInvoicesExcludedRule flagsSent to JevJev flagsApprovedTo review
tune 5,115511 3295 5,09416
test 1,20823 681 1,2024
demo 14500 71 1441
All 6,468714 4047 6,44021

Invoices are split by billing date so nothing is tuned on the data it is judged on: tune before 2026-01-01 (choices are made here), test 2026-01-01 to 2026-08-31 (choices are checked here), demo from 2026-09-01 (the latest batch).

Tier 1: the rules

Arithmetic, prices, commissions, payment schedules and party data are checked line by line. The synthetic data is clean, so those rules all pass. The two rules about repeated billing do the real work.

RuleWhat it checksResult
line_arithmeticEvery line: package_quantity ≥ 1, unit price > 0, line amount = quantity × unit priceall pass
invoice_totalInvoice total = Σ line amounts; line_count = number of lines; lines numbered 1..nall pass
commissionEach line's commission = 5% rounded half up; invoice commission = Σ line commissionsall pass
price_listUnit price = the product's list price for the year, as seen on earlier invoices; a new year's first price must be +0% … +10% per year above the last list priceall pass
payment_scheduleKnown schedule; installment count and first due date match it; 30 days apart; amounts sum to the total, differ by ≤ 1 cent, leftover cents firstall pass
party_consistencyInvoice seller and business unit = the customer's; every line and installment matches the invoice header; each product exists, belongs to the invoice's business unit and keeps its catalogue name and categoryall pass
duplicate_linesSame products and quantities as an invoice of the same customer ≤ 7 days earlierall pass
rebilled_productsBilled ≤ 2 days after the same customer's previous invoice with only products already on it (a partial rebill; Phase 4 found this rule catches them better than Jev)14 flagged
near_duplicate_windowBilled ≤ 2 days after the same customer's previous invoice (Jev decides)418 to Jev

Tier 2: what Jev was asked

Is this invoice the same order as the customer's previous invoice (billed again in whole or in part, or one order split across the two invoices), rather than a separate new order?

Jev (model jev-1.13.0) sees both invoices and the customer's history and answers yes or no with a probability. Scores ran from 0.05 to 0.46, median 0.19. Anything at or above 0.39 goes to a reviewer.

010203040p 0.05: 7 invoicesp 0.06: 20 invoicesp 0.07: 30 invoicesp 0.08: 20 invoicesp 0.09: 11 invoicesp 0.10: 7 invoicesp 0.11: 3 invoicesp 0.13: 6 invoicesp 0.14: 12 invoicesp 0.15: 14 invoicesp 0.16: 21 invoicesp 0.17: 24 invoicesp 0.18: 19 invoicesp 0.19: 31 invoicesp 0.20: 17 invoicesp 0.21: 22 invoicesp 0.22: 23 invoicesp 0.23: 16 invoicesp 0.24: 19 invoicesp 0.25: 21 invoicesp 0.26: 10 invoicesp 0.27: 10 invoicesp 0.28: 5 invoicesp 0.29: 10 invoicesp 0.30: 4 invoicesp 0.31: 2 invoicesp 0.32: 5 invoicesp 0.33: 2 invoicesp 0.34: 1 invoicep 0.35: 1 invoicep 0.36: 2 invoicesp 0.37: 1 invoicep 0.38: 1 invoicep 0.39: 2 invoicesp 0.40: 2 invoicesp 0.41: 1 invoicep 0.43: 1 invoicep 0.46: 1 invoice0.00.10.20.30.40.5threshold 0.39Jev's probability that the invoice repeats the previous orderinvoices
approved sent to review · 404 invoices
All 404 Jev scores
InvoiceSplitScoreOutcome
006328demo0.46Review
002004tune0.43Review
002737tune0.41Review
000593tune0.40Review
000752tune0.40Review
002477tune0.39Review
005663test0.39Review
005577test0.38Approve
000708tune0.37Approve
003434tune0.36Approve
006003test0.36Approve
000892tune0.35Approve
005883test0.34Approve
000831tune0.33Approve
003928tune0.33Approve
002166tune0.32Approve
002418tune0.32Approve
004716tune0.32Approve
005897test0.32Approve
006158test0.32Approve
001453tune0.31Approve
002778tune0.31Approve
001270tune0.30Approve
005501test0.30Approve
005656test0.30Approve
006368demo0.30Approve
000841tune0.29Approve
001619tune0.29Approve
002294tune0.29Approve
002811tune0.29Approve
003125tune0.29Approve
004598tune0.29Approve
006053test0.29Approve
006178test0.29Approve
006187test0.29Approve
006191test0.29Approve
000323tune0.28Approve
000690tune0.28Approve
001381tune0.28Approve
004951tune0.28Approve
004990tune0.28Approve
001071tune0.27Approve
001085tune0.27Approve
003057tune0.27Approve
003635tune0.27Approve
003770tune0.27Approve
004457tune0.27Approve
005747test0.27Approve
005832test0.27Approve
006389demo0.27Approve
006393demo0.27Approve
000115tune0.26Approve
000207tune0.26Approve
000472tune0.26Approve
001570tune0.26Approve
002615tune0.26Approve
002739tune0.26Approve
003021tune0.26Approve
003284tune0.26Approve
003652tune0.26Approve
004374tune0.26Approve
000197tune0.25Approve
001010tune0.25Approve
001082tune0.25Approve
001632tune0.25Approve
001778tune0.25Approve
002163tune0.25Approve
002196tune0.25Approve
002417tune0.25Approve
002683tune0.25Approve
003659tune0.25Approve
003887tune0.25Approve
004058tune0.25Approve
004098tune0.25Approve
004241tune0.25Approve
004495tune0.25Approve
004708tune0.25Approve
005658test0.25Approve
005793test0.25Approve
005840test0.25Approve
006423demo0.25Approve
006458demo0.25Approve
000367tune0.24Approve
000381tune0.24Approve
000586tune0.24Approve
000988tune0.24Approve
001051tune0.24Approve
001136tune0.24Approve
001159tune0.24Approve
001233tune0.24Approve
001598tune0.24Approve
002532tune0.24Approve
002698tune0.24Approve
002754tune0.24Approve
002982tune0.24Approve
003142tune0.24Approve
004104tune0.24Approve
004458tune0.24Approve
005845test0.24Approve
006065test0.24Approve
006235test0.24Approve
000466tune0.23Approve
000564tune0.23Approve
000736tune0.23Approve
000851tune0.23Approve
001200tune0.23Approve
001406tune0.23Approve
001925tune0.23Approve
002148tune0.23Approve
002547tune0.23Approve
002620tune0.23Approve
003677tune0.23Approve
004361tune0.23Approve
004390tune0.23Approve
004891tune0.23Approve
004997tune0.23Approve
005639test0.23Approve
000274tune0.22Approve
000289tune0.22Approve
000498tune0.22Approve
000504tune0.22Approve
000547tune0.22Approve
000622tune0.22Approve
000655tune0.22Approve
000845tune0.22Approve
002162tune0.22Approve
002314tune0.22Approve
002337tune0.22Approve
002475tune0.22Approve
002684tune0.22Approve
002875tune0.22Approve
003769tune0.22Approve
003921tune0.22Approve
003986tune0.22Approve
004156tune0.22Approve
004904tune0.22Approve
004989tune0.22Approve
005238test0.22Approve
005571test0.22Approve
005711test0.22Approve
000330tune0.21Approve
000496tune0.21Approve
000657tune0.21Approve
000707tune0.21Approve
000805tune0.21Approve
000884tune0.21Approve
000956tune0.21Approve
001044tune0.21Approve
001124tune0.21Approve
001440tune0.21Approve
001557tune0.21Approve
001970tune0.21Approve
002286tune0.21Approve
002629tune0.21Approve
002790tune0.21Approve
002826tune0.21Approve
003893tune0.21Approve
004861tune0.21Approve
004881tune0.21Approve
005484test0.21Approve
005509test0.21Approve
005704test0.21Approve
000793tune0.20Approve
001047tune0.20Approve
001523tune0.20Approve
001574tune0.20Approve
002015tune0.20Approve
002060tune0.20Approve
002567tune0.20Approve
002924tune0.20Approve
003145tune0.20Approve
003315tune0.20Approve
003905tune0.20Approve
004030tune0.20Approve
004319tune0.20Approve
004404tune0.20Approve
004814tune0.20Approve
004943tune0.20Approve
005260test0.20Approve
000866tune0.19Approve
001163tune0.19Approve
001170tune0.19Approve
001461tune0.19Approve
001590tune0.19Approve
001616tune0.19Approve
001737tune0.19Approve
002033tune0.19Approve
002574tune0.19Approve
002695tune0.19Approve
002808tune0.19Approve
002810tune0.19Approve
002813tune0.19Approve
003301tune0.19Approve
003668tune0.19Approve
003678tune0.19Approve
003950tune0.19Approve
004100tune0.19Approve
004178tune0.19Approve
004329tune0.19Approve
004978tune0.19Approve
005053tune0.19Approve
005225test0.19Approve
005404test0.19Approve
005441test0.19Approve
005654test0.19Approve
005843test0.19Approve
006052test0.19Approve
006104test0.19Approve
006119test0.19Approve
006192test0.19Approve
000226tune0.18Approve
001008tune0.18Approve
001228tune0.18Approve
001488tune0.18Approve
001621tune0.18Approve
001924tune0.18Approve
002067tune0.18Approve
002277tune0.18Approve
002748tune0.18Approve
003850tune0.18Approve
004086tune0.18Approve
004424tune0.18Approve
004499tune0.18Approve
004661tune0.18Approve
005701test0.18Approve
005740test0.18Approve
006054test0.18Approve
006182test0.18Approve
006237test0.18Approve
000368tune0.17Approve
000544tune0.17Approve
000604tune0.17Approve
000726tune0.17Approve
001013tune0.17Approve
001224tune0.17Approve
001567tune0.17Approve
001630tune0.17Approve
001936tune0.17Approve
002023tune0.17Approve
002280tune0.17Approve
002333tune0.17Approve
002605tune0.17Approve
003976tune0.17Approve
004309tune0.17Approve
004443tune0.17Approve
004456tune0.17Approve
004468tune0.17Approve
005064tune0.17Approve
005672test0.17Approve
005754test0.17Approve
005904test0.17Approve
006011test0.17Approve
006121test0.17Approve
000022tune0.16Approve
000331tune0.16Approve
000982tune0.16Approve
001350tune0.16Approve
001466tune0.16Approve
001511tune0.16Approve
001556tune0.16Approve
001629tune0.16Approve
001920tune0.16Approve
002554tune0.16Approve
002885tune0.16Approve
002948tune0.16Approve
002979tune0.16Approve
003076tune0.16Approve
003205tune0.16Approve
004270tune0.16Approve
004797tune0.16Approve
004946tune0.16Approve
005795test0.16Approve
006102test0.16Approve
006233test0.16Approve
000553tune0.15Approve
001413tune0.15Approve
002012tune0.15Approve
003332tune0.15Approve
003690tune0.15Approve
004152tune0.15Approve
004413tune0.15Approve
004567tune0.15Approve
004823tune0.15Approve
004873tune0.15Approve
004953tune0.15Approve
005316test0.15Approve
005652test0.15Approve
006239test0.15Approve
000122tune0.14Approve
000813tune0.14Approve
001379tune0.14Approve
002032tune0.14Approve
002421tune0.14Approve
002798tune0.14Approve
003723tune0.14Approve
003930tune0.14Approve
004711tune0.14Approve
004959tune0.14Approve
004993tune0.14Approve
006064test0.14Approve
001866tune0.13Approve
002375tune0.13Approve
002423tune0.13Approve
003029tune0.13Approve
005017tune0.13Approve
005431test0.13Approve
000558tune0.11Approve
000747tune0.11Approve
002624tune0.11Approve
001605tune0.10Approve
001981tune0.10Approve
002213tune0.10Approve
003984tune0.10Approve
004387tune0.10Approve
004444tune0.10Approve
005069tune0.10Approve
000592tune0.09Approve
001405tune0.09Approve
002043tune0.09Approve
002510tune0.09Approve
002897tune0.09Approve
002953tune0.09Approve
002998tune0.09Approve
003442tune0.09Approve
003783tune0.09Approve
004957tune0.09Approve
006215test0.09Approve
000781tune0.08Approve
000906tune0.08Approve
000960tune0.08Approve
000981tune0.08Approve
000989tune0.08Approve
001321tune0.08Approve
001514tune0.08Approve
001623tune0.08Approve
002047tune0.08Approve
002334tune0.08Approve
002612tune0.08Approve
002797tune0.08Approve
002871tune0.08Approve
003819tune0.08Approve
004327tune0.08Approve
004650tune0.08Approve
005096tune0.08Approve
005737test0.08Approve
006028test0.08Approve
006135test0.08Approve
000238tune0.07Approve
000396tune0.07Approve
000514tune0.07Approve
000682tune0.07Approve
000694tune0.07Approve
000842tune0.07Approve
001050tune0.07Approve
001091tune0.07Approve
001171tune0.07Approve
001452tune0.07Approve
001848tune0.07Approve
002008tune0.07Approve
002216tune0.07Approve
002678tune0.07Approve
002872tune0.07Approve
003008tune0.07Approve
003605tune0.07Approve
004274tune0.07Approve
004303tune0.07Approve
004419tune0.07Approve
004742tune0.07Approve
004785tune0.07Approve
005071tune0.07Approve
005121test0.07Approve
005443test0.07Approve
005930test0.07Approve
006214test0.07Approve
006223test0.07Approve
006245test0.07Approve
006455demo0.07Approve
000108tune0.06Approve
000346tune0.06Approve
000952tune0.06Approve
001020tune0.06Approve
001232tune0.06Approve
001371tune0.06Approve
001617tune0.06Approve
002322tune0.06Approve
002580tune0.06Approve
002639tune0.06Approve
003177tune0.06Approve
003689tune0.06Approve
004101tune0.06Approve
004247tune0.06Approve
004364tune0.06Approve
004899tune0.06Approve
005097tune0.06Approve
005333test0.06Approve
005578test0.06Approve
006025test0.06Approve
000325tune0.05Approve
000624tune0.05Approve
000903tune0.05Approve
001391tune0.05Approve
002528tune0.05Approve
004321tune0.05Approve
004969tune0.05Approve

Does it catch the right invoices?

The data has no answer key, so the evaluation plants cases with a known answer. Each one is built from real invoices: a rebill, a rebill with changed quantities, a split order, or a real new order moved next to the previous invoice. Then every case goes through the same rules and the same Jev question.

Planted caseShouldCasesJev median scoreJev ≥ 0.39Rebill rule flagsSent to review
Partial rebillSome products from the previous invoice billed again, same quantities. Review 30/30 0.51/0.48 100%/100% 100%/100% 100%/100%
Rebill, quantities changedProducts from the previous invoice billed again with different quantities. Review 30/30 0.35/0.33 40%/23.3% 100%/100% 100%/100%
Split orderOne real order divided over two invoices; every line is billed once. Approve 30/30 0.07/0.07 0%/0% 0%/0% 0%/0%
New order, moved closeA real later order of the same customer, moved to 1–2 days after the previous invoice. Approve 60/60 0.09/0.17 0%/3.3% 1.7%/1.7% 1.7%/3.3%

Each cell shows tune / test. Green means the share is where it should be (≥ 90% for cases to review, ≤ 5% for cases to approve). “Sent to review” is the whole pipeline: rules first, then Jev.

Jev spots exact rebills

Against real new orders its AUC is 1.00 on tune and 1.00 on test. Rebills with changed quantities are harder: only 40% / 23% score above the threshold.

A plain rule does better

“Billed ≤ 2 days later with only products already on the previous invoice” catches every planted rebill, both kinds, and flags 1.7% / 1.7% of real new orders. It now runs in tier 1, and Jev stays behind it as a second opinion.

Splits are left alone

Jev rates split orders as less alike than real new orders (AUC 0.23 / 0.18). That is acceptable: a split bills each line once, so it is approved. False alarms on new orders end at 1.7% / 3.3%.

Jev compared with single invoice features
SignalRebillRebill, qty changedSplit
Jev (model)1.00/1.000.97/0.930.23/0.18
Days since previous invoice0.49/0.490.51/0.510.51/0.51
Products shared0.86/0.720.87/0.800.28/0.19
Product overlap (Jaccard)0.94/0.900.96/0.940.28/0.19
Shared products, same quantity1.00/0.980.49/0.470.49/0.47
Total ÷ previous total0.10/0.060.05/0.050.34/0.61
Same payment schedule0.58/0.610.58/0.610.58/0.61
Both together match an earlier basket0.53/0.510.53/0.490.50/0.51

AUC of each signal at telling that kind apart from a real new order moved close (tune / test). 1.00 separates perfectly, 0.50 is a coin flip, below 0.50 points the wrong way.

The review queue

The 21 invoices a person would look at, with the evidence each one arrives with.

InvoiceSplitFromPreviousDaysShared productsOverlapTotal ÷ prevWhy
000345tune Rule 0003331 30.60 1.51rebilled products: every product (P101, P107, P108) was already on 000333 (billed 2023-05-04)
000593tune Jev 0005861 50.71 0.98Jev rates it 0.40 likely the same order; billed 1 day after 000586 for the same customer
000752tune Jev 0007252 40.50 0.87Jev rates it 0.40 likely the same order; billed 2 days after 000725 for the same customer
000940tune Rule 0009172 30.50 0.93rebilled products: every product (P001, P002, P003) was already on 000917 (billed 2023-08-08)
001005tune Rule 0009822 10.33 1.13rebilled products: every product (P010) was already on 000982 (billed 2023-08-15)
001269tune Rule 0012601 40.67 0.72rebilled products: every product (P001, P002, P005, P007) was already on 001260 (billed 2023-10-16)
001283tune Rule 0012761 20.50 0.71rebilled products: every product (P003, P004) was already on 001276 (billed 2023-10-18)
002004tune Jev 0019881 30.75 1.00Jev rates it 0.43 likely the same order; billed 1 day after 001988 for the same customer
002477tune Jev 0024601 30.75 0.97Jev rates it 0.39 likely the same order; billed 1 day after 002460 for the same customer
002626tune Rule 0025952 10.50 0.81rebilled products: every product (P001) was already on 002595 (billed 2024-08-05)
002737tune Jev 0027261 20.67 1.14Jev rates it 0.41 likely the same order; billed 1 day after 002726 for the same customer
002918tune Rule 0028992 20.50 0.93rebilled products: every product (P005, P010) was already on 002899 (billed 2024-09-17)
003002tune Rule 0029962 30.50 0.79rebilled products: every product (P002, P005, P007) was already on 002996 (billed 2024-10-08)
003649tune Rule 0036351 30.50 0.63rebilled products: every product (P102, P105, P107) was already on 003635 (billed 2025-04-23)
004088tune Rule 0040731 20.50 0.96rebilled products: every product (P001, P007) was already on 004073 (billed 2025-07-02)
004802tune Rule 0047882 10.50 1.15rebilled products: every product (P110) was already on 004788 (billed 2025-10-28)
005663test Jev 0056481 20.29 0.54Jev rates it 0.39 likely the same order; billed 1 day after 005648 for the same customer
005667test Rule 0056412 30.60 1.28rebilled products: every product (P001, P005, P007) was already on 005641 (billed 2026-06-03)
005670test Rule 0056621 30.75 1.15rebilled products: every product (P002, P004, P010) was already on 005662 (billed 2026-06-04)
005745test Rule 0057321 10.33 0.95rebilled products: every product (P010) was already on 005732 (billed 2026-06-17)
006328demo Jev 0063121 40.67 0.87Jev rates it 0.46 likely the same order; billed 1 day after 006312 for the same customer

Data checks before any of this

The delivered files were audited against their documentation first, so the rules rest on facts about the data rather than assumptions.

Limits