Dataset Viewer
Auto-converted to Parquet Duplicate
id
stringlengths
13
13
vat_variant
stringclasses
4 values
discount_variant
stringclasses
5 values
number_format
stringclasses
3 values
layout
stringclasses
3 values
consistency
stringclasses
3 values
edge_case
stringclasses
5 values
correct_total
float64
-341,637.36
647k
rendered_total
float64
-341,637.36
647k
currency
stringclasses
1 value
has_discount
stringclasses
2 values
is_credit_note
stringclasses
2 values
INV-2026-0001
implicit_rate_stated
explicit_percentage
english
mixed
correct
none
248,054.76
248,054.76
EUR
yes
no
INV-2026-0002
implicit_no_rate
explicit_percentage
swiss
table
total_error
none
183,313.83
188,813.24
EUR
yes
no
INV-2026-0003
explicit_excluded
trade_terms
swiss
mixed
correct
none
99,019.2
99,019.2
EUR
yes
no
INV-2026-0004
explicit_excluded
trade_terms
german
table
total_error
none
222,953.88
218,494.8
EUR
yes
no
INV-2026-0005
implicit_rate_stated
explicit_amount
german
paragraph
correct
single_item
70,671.98
70,671.98
EUR
yes
no
INV-2026-0006
explicit_included
explicit_percentage
english
table
subtotal_error
none
14,856.5
14,856.5
EUR
yes
no
INV-2026-0007
implicit_no_rate
obfuscated
german
paragraph
correct
none
132,230.36
132,230.36
EUR
yes
no
INV-2026-0008
explicit_excluded
trade_terms
german
mixed
correct
none
201,192.6
201,192.6
EUR
yes
no
INV-2026-0009
implicit_rate_stated
trade_terms
swiss
table
correct
none
112,513.44
112,513.44
EUR
yes
no
INV-2026-0010
explicit_excluded
explicit_percentage
german
table
correct
none
229,496.31
229,496.31
EUR
yes
no
INV-2026-0011
explicit_excluded
explicit_amount
english
paragraph
subtotal_error
single_item
6,666.89
6,666.89
EUR
yes
no
INV-2026-0012
implicit_no_rate
explicit_amount
german
table
total_error
none
159,868.63
163,066
EUR
yes
no
INV-2026-0013
explicit_included
none
german
paragraph
subtotal_error
none
18,892.68
18,892.68
EUR
no
no
INV-2026-0014
explicit_excluded
none
english
paragraph
correct
credit_note
-79,621.32
-79,621.32
EUR
no
yes
INV-2026-0015
explicit_included
none
german
mixed
subtotal_error
none
159,918.6
159,918.6
EUR
no
no
INV-2026-0016
explicit_excluded
none
swiss
table
total_error
credit_note
-146,179.2
-144,717.41
EUR
no
yes
INV-2026-0017
implicit_rate_stated
none
swiss
mixed
correct
none
173,887.68
173,887.68
EUR
no
no
INV-2026-0018
explicit_included
trade_terms
english
paragraph
subtotal_error
none
229,466.64
229,466.64
EUR
yes
no
INV-2026-0019
implicit_no_rate
explicit_amount
swiss
mixed
correct
none
126,042.8
126,042.8
EUR
yes
no
INV-2026-0020
implicit_rate_stated
none
english
table
correct
reverse_charge
321,030.2
321,030.2
EUR
no
no
INV-2026-0021
implicit_rate_stated
trade_terms
english
mixed
subtotal_error
none
312,061.44
312,061.44
EUR
yes
no
INV-2026-0022
implicit_rate_stated
obfuscated
english
mixed
correct
none
207,631.46
207,631.46
EUR
yes
no
INV-2026-0023
explicit_included
none
german
table
correct
none
246,128.76
246,128.76
EUR
no
no
INV-2026-0024
implicit_rate_stated
explicit_percentage
swiss
paragraph
subtotal_error
single_item
8,349
8,349
EUR
yes
no
INV-2026-0025
implicit_rate_stated
none
swiss
table
total_error
none
13,563.84
13,156.92
EUR
no
no
INV-2026-0026
explicit_excluded
explicit_percentage
german
table
total_error
none
391,999
384,159.02
EUR
yes
no
INV-2026-0027
implicit_no_rate
obfuscated
german
mixed
correct
none
55,425.94
55,425.94
EUR
yes
no
INV-2026-0028
implicit_no_rate
none
swiss
table
correct
none
23,388.48
23,388.48
EUR
no
no
INV-2026-0029
explicit_included
none
swiss
mixed
correct
none
8,877.6
8,877.6
EUR
no
no
INV-2026-0030
explicit_excluded
obfuscated
swiss
mixed
total_error
none
83,896.42
82,218.49
EUR
yes
no
INV-2026-0031
implicit_no_rate
explicit_percentage
swiss
mixed
correct
none
7,004.65
7,004.65
EUR
yes
no
INV-2026-0032
implicit_no_rate
explicit_amount
german
mixed
subtotal_error
none
300,464.06
300,464.06
EUR
yes
no
INV-2026-0033
explicit_included
none
german
table
correct
none
181,352.04
181,352.04
EUR
no
no
INV-2026-0034
explicit_included
none
swiss
mixed
correct
none
434,010.12
434,010.12
EUR
no
no
INV-2026-0035
implicit_rate_stated
none
german
table
subtotal_error
none
19,955.16
19,955.16
EUR
no
no
INV-2026-0036
implicit_no_rate
none
english
mixed
correct
none
169,940.52
169,940.52
EUR
no
no
INV-2026-0037
implicit_rate_stated
none
swiss
table
correct
none
62,289
62,289
EUR
no
no
INV-2026-0038
implicit_no_rate
explicit_percentage
swiss
paragraph
total_error
none
366,138.72
362,477.33
EUR
yes
no
INV-2026-0039
implicit_no_rate
none
english
paragraph
correct
none
29,194.56
29,194.56
EUR
no
no
INV-2026-0040
explicit_included
none
german
table
total_error
none
490,071.36
499,872.79
EUR
no
no
INV-2026-0041
explicit_included
none
swiss
paragraph
total_error
none
159,024.72
154,253.98
EUR
no
no
INV-2026-0042
explicit_excluded
obfuscated
german
paragraph
correct
none
97,879.5
97,879.5
EUR
yes
no
INV-2026-0043
implicit_rate_stated
none
english
paragraph
correct
none
647,037.72
647,037.72
EUR
no
no
INV-2026-0044
implicit_rate_stated
obfuscated
swiss
paragraph
subtotal_error
mixed_vat
128,063.97
128,063.97
EUR
yes
no
INV-2026-0045
implicit_no_rate
none
english
table
total_error
none
411,321.96
398,982.3
EUR
no
no
INV-2026-0046
explicit_excluded
trade_terms
german
table
correct
none
446,312.04
446,312.04
EUR
yes
no
INV-2026-0047
implicit_no_rate
none
german
paragraph
subtotal_error
none
139,862.28
139,862.28
EUR
no
no
INV-2026-0048
explicit_excluded
explicit_amount
german
paragraph
correct
none
70,065.2
70,065.2
EUR
yes
no
INV-2026-0049
implicit_no_rate
obfuscated
swiss
table
correct
none
6,411.25
6,411.25
EUR
yes
no
INV-2026-0050
implicit_no_rate
trade_terms
english
paragraph
correct
none
186,871.2
186,871.2
EUR
yes
no
INV-2026-0051
implicit_no_rate
explicit_amount
swiss
table
correct
none
187,983.48
187,983.48
EUR
yes
no
INV-2026-0052
explicit_excluded
explicit_percentage
german
mixed
correct
none
346,551.49
346,551.49
EUR
yes
no
INV-2026-0053
explicit_included
obfuscated
german
mixed
correct
none
132,416.62
132,416.62
EUR
yes
no
INV-2026-0054
explicit_included
none
swiss
mixed
subtotal_error
none
216,143.04
216,143.04
EUR
no
no
INV-2026-0055
explicit_included
explicit_percentage
swiss
mixed
correct
none
412,645.43
412,645.43
EUR
yes
no
INV-2026-0056
explicit_included
trade_terms
swiss
mixed
correct
none
483,187.2
483,187.2
EUR
yes
no
INV-2026-0057
implicit_no_rate
obfuscated
english
mixed
total_error
none
157,680.11
156,103.31
EUR
yes
no
INV-2026-0058
explicit_included
explicit_percentage
german
mixed
total_error
none
70,208.19
72,314.44
EUR
yes
no
INV-2026-0059
implicit_no_rate
explicit_amount
swiss
mixed
correct
none
102,729.74
102,729.74
EUR
yes
no
INV-2026-0060
implicit_rate_stated
explicit_amount
english
paragraph
correct
none
188,869.67
188,869.67
EUR
yes
no
INV-2026-0061
explicit_included
explicit_percentage
swiss
paragraph
correct
none
203,642.57
203,642.57
EUR
yes
no
INV-2026-0062
explicit_excluded
none
swiss
mixed
correct
mixed_vat
153,197.2
153,197.2
EUR
no
no
INV-2026-0063
explicit_excluded
none
english
table
subtotal_error
none
63,542.76
63,542.76
EUR
no
no
INV-2026-0064
implicit_no_rate
explicit_percentage
german
table
total_error
none
486,496.23
491,361.19
EUR
yes
no
INV-2026-0065
explicit_included
obfuscated
german
table
subtotal_error
none
235,392.64
235,392.64
EUR
yes
no
INV-2026-0066
implicit_no_rate
none
english
paragraph
correct
none
358,384.44
358,384.44
EUR
no
no
INV-2026-0067
implicit_no_rate
obfuscated
swiss
mixed
correct
none
109,920.54
109,920.54
EUR
yes
no
INV-2026-0068
explicit_excluded
explicit_amount
english
table
correct
none
432,291.44
432,291.44
EUR
yes
no
INV-2026-0069
explicit_included
obfuscated
german
table
correct
none
306,808.99
306,808.99
EUR
yes
no
INV-2026-0070
explicit_included
explicit_amount
english
table
total_error
none
145,721.39
148,635.82
EUR
yes
no
INV-2026-0071
explicit_excluded
none
english
paragraph
subtotal_error
credit_note
-341,637.36
-341,637.36
EUR
no
yes
INV-2026-0072
implicit_rate_stated
none
english
paragraph
total_error
none
37,269.72
36,897.02
EUR
no
no
INV-2026-0073
implicit_no_rate
none
english
paragraph
correct
none
17,166.96
17,166.96
EUR
no
no
INV-2026-0074
implicit_no_rate
explicit_percentage
english
mixed
correct
none
33,489.46
33,489.46
EUR
yes
no
INV-2026-0075
explicit_included
explicit_percentage
german
mixed
total_error
none
315,897.8
319,056.78
EUR
yes
no
INV-2026-0076
explicit_excluded
none
english
table
correct
none
210,316.2
210,316.2
EUR
no
no
INV-2026-0077
implicit_rate_stated
explicit_percentage
swiss
mixed
correct
single_item
10,957.77
10,957.77
EUR
yes
no
INV-2026-0078
explicit_included
explicit_percentage
swiss
mixed
correct
none
72,110.96
72,110.96
EUR
yes
no
INV-2026-0079
implicit_no_rate
explicit_amount
swiss
paragraph
correct
none
181,838.71
181,838.71
EUR
yes
no
INV-2026-0080
implicit_no_rate
explicit_percentage
german
mixed
total_error
none
58,206.45
57,042.32
EUR
yes
no
INV-2026-0081
explicit_excluded
explicit_amount
english
paragraph
correct
none
174,750.88
174,750.88
EUR
yes
no
INV-2026-0082
explicit_included
trade_terms
swiss
paragraph
correct
none
228,867
228,867
EUR
yes
no
INV-2026-0083
explicit_included
none
swiss
mixed
correct
none
179,169.84
179,169.84
EUR
no
no
INV-2026-0084
implicit_no_rate
none
english
mixed
subtotal_error
credit_note
-275,836.44
-275,836.44
EUR
no
yes
INV-2026-0085
implicit_rate_stated
explicit_amount
german
mixed
subtotal_error
none
170,813.1
170,813.1
EUR
yes
no
INV-2026-0086
explicit_excluded
explicit_percentage
german
paragraph
correct
none
104,133.35
104,133.35
EUR
yes
no
INV-2026-0087
explicit_included
trade_terms
swiss
paragraph
correct
none
89,905.92
89,905.92
EUR
yes
no
INV-2026-0088
explicit_excluded
explicit_amount
english
table
subtotal_error
none
35,768.3
35,768.3
EUR
yes
no
INV-2026-0089
explicit_included
none
swiss
mixed
subtotal_error
none
5,665.2
5,665.2
EUR
no
no
INV-2026-0090
explicit_included
none
english
paragraph
total_error
credit_note
-277,509.84
-283,060.04
EUR
no
yes
INV-2026-0091
implicit_rate_stated
explicit_amount
english
mixed
correct
none
211,996.28
211,996.28
EUR
yes
no
INV-2026-0092
implicit_no_rate
explicit_amount
english
paragraph
correct
none
286,031.59
286,031.59
EUR
yes
no
INV-2026-0093
explicit_included
explicit_percentage
english
table
subtotal_error
none
41,492.81
41,492.81
EUR
yes
no
INV-2026-0094
implicit_no_rate
obfuscated
swiss
table
correct
none
61,939.35
61,939.35
EUR
yes
no
INV-2026-0095
implicit_no_rate
trade_terms
german
mixed
subtotal_error
none
235,704.24
235,704.24
EUR
yes
no
INV-2026-0096
explicit_included
explicit_percentage
english
paragraph
correct
none
349,646
349,646
EUR
yes
no
INV-2026-0097
explicit_excluded
explicit_percentage
german
paragraph
correct
none
329,643.24
329,643.24
EUR
yes
no
INV-2026-0098
explicit_excluded
trade_terms
swiss
table
total_error
none
285,194.52
279,490.63
EUR
yes
no
INV-2026-0099
implicit_no_rate
none
swiss
mixed
correct
none
14,088
14,088
EUR
no
no
INV-2026-0100
implicit_no_rate
obfuscated
swiss
table
correct
none
227,249.46
227,249.46
EUR
yes
no
End of preview. Expand in Data Studio

InvoiceBenchmark

200 synthetic invoices with cent-perfect ground truth, designed to measure the one thing language models are supposed to be able to do: read a number.

The Pitch

Invoice processing is the use case every enterprise AI pitch deck opens with. The numbers are either right or wrong, and the distance between right and wrong can be measured to the cent. This dataset exists because we ran the experiment and discovered that the gap between "this looks easy" and "this actually works" is wider than the industry would like to admit.

Five open-weight models. Four architectures. The best one scored 83%. The largest one scored 77%. The reasoning models performed worse than the plain models at every size. The full write-up is at jngb.online/notes/06-too-dangerous-to-release.

What's in the Box

Component Path Format Count
Invoices (text) output/invoices/ Markdown 200
Invoices (visual, PDF) output/pdf/ PDF 200
Invoices (visual, PNG) output/png/ PNG 200
Ground truth output/ground_truth/ JSON 200
Manifest output/manifest.csv CSV 1
Distribution summary output/summary.json JSON 1
Generator invoice_generator.py Python 1
Evaluation harness run_benchmark.py Python 1
Prompts prompts/ Text 2

Each invoice exists in two formats. The Markdown version is plain text β€” the kind of thing you would paste into a prompt. The PDF version is a rendered, styled document β€” the kind of thing a multimodal or vision model would receive as an image. Both formats share the same ground truth: same numbers, same structure, same controlled dimensions.

Each ground-truth JSON records the canonical correct values, the variant parameters that control how the invoice was constructed, and (for error-injected invoices) both the correct and the deliberately-wrong number.

All monetary values use Python's Decimal with ROUND_HALF_UP rounding. No floating-point arithmetic touches the money pipeline. The total is correct to the cent unless it has been deliberately broken.

The Five Dimensions

Every invoice varies along five controlled axes. The point is not to produce "hard" invoices β€” it is to hold everything else constant and vary one thing at a time, so that when a model fails, the failure is attributable.

VAT phrasing (4 variants): explicit_included β€” prices include VAT, the model must not double-count. explicit_excluded β€” VAT added on top. implicit_rate_stated β€” rate visible, inclusion ambiguous. implicit_no_rate β€” VAT amount shown, rate omitted.

Discount phrasing (5 variants): none β€” no discount, a sanity check for models that invent one. explicit_percentage β€” "5% early payment discount applied". explicit_amount β€” a fixed rebate. trade_terms β€” "2/10 net 30", which is conditional and should NOT be applied. obfuscated β€” the percentage buried inside a reference string.

Number format (3 variants): english (1,234.56), german (1.234,56), swiss (1'234.56). The German format is the single most consequential trap in the dataset. A model that reads 1.234 as 1.234 rather than 1,234 will be off by three orders of magnitude β€” and the resulting number will still look plausible.

Layout (3 variants): table (Markdown pipe-table), paragraph (prose), mixed (table for line items, prose for summary).

Consistency (3 variants): correct (60%) β€” the invoice adds up. subtotal_error (20%) β€” the stated subtotal is wrong by Β±5 to Β±50 EUR. total_error (20%) β€” the stated total is wrong by Β±1–3%. The model should flag these.

A sixth dimension covers edge cases (10% of the corpus): reverse_charge (0% VAT, Article 196), mixed_vat (two VAT rates), credit_note (negative amounts), single_item (one line, nowhere to hide).

Baseline Results

Tested in May 2026 on five open-weight models. Two evaluation conditions: autopilot (the model reads the invoice and reports the total) and hybrid (the model extracts structured fields, Python recomputes the total).

Llama 3.1 8B Qwen3 8B Gemma 4 31B QwQ 32B Llama 3.3 70B
Parse rate 99% 57% 100% 81% 100%
Exact match (autopilot) 69% ~85%* 83% ~73%* 77%
Exact match (hybrid) 43% ~77%* 83% ~77%* 81%
Wrong but would pass review 23% ~13%* 18% ~11%* 16%
Error detection rate 18% 45% 83% 38% 75%
Worst single error 99.9% 100%* 3% 100%* 99.9%
Time per invoice 25s 32s 19s 112s 3s
Hardware MacBook Air 1Γ— H100 1Γ— H100 1Γ— H100 8Γ— H100
Running cost Free €2.73/hr €2.73/hr €2.73/hr €23/hr

* Of the invoices where the model produced parseable output.

Three findings that may save someone a weekend:

  1. Reasoning models are worse. At 8B, the reasoning variant failed to produce parseable output 43% of the time. At 32B, it reasoned its way to €0.00 on twenty-two invoices. Thinking longer about an invoice does not produce a better answer.

  2. Bigger is not better β€” at least not here. Llama 70B on eight GPUs lost to Gemma 31B on one. Nine times the parameters, eight times the cost, worse results.

  3. The German comma is the most expensive punctuation mark in Europe. An invoice for €364,065.64, formatted as 364.065,64, comes back as €363.07. The error is invisible in the right typeface. No amount of parameters retrains the prior.

How to Run

Generate the corpus

python invoice_generator.py --output ./output --count 200 --seed 42

Fully deterministic. Python 3.10+, no external dependencies.

Verify the ground truth

python invoice_generator.py --output ./output --verify

Run the benchmark

# Local model via Ollama
python run_benchmark.py --models llama3.1:8b

# Remote model via vLLM
python run_benchmark.py --models vllm:google/gemma-4-31b-it --vllm-url http://gpu-server:8000/v1

# Multiple models, single condition
python run_benchmark.py --models llama3.1:8b,qwen3:8b --conditions B

Results are written to results/ as timestamped CSVs. The harness supports two conditions: B (autopilot β€” the model does everything) and C (hybrid β€” the model extracts, Python calculates).

Scoring

Exact match means the model's reported total equals the ground-truth total to the cent. "Wrong but close enough" means the answer is within 5% β€” the kind of error that sails through manual review. Both are worth tracking. The first tells you whether the model works. The second tells you how dangerous it is when it doesn't.

Data Format

Invoice (Markdown)

A plain-text rendering of a European B2B invoice. Company names are fictional (Pierce & Pierce, Vandelay Industries, Cyberdyne Systems, Wonka Industries, and so on). Street addresses are invented. IBANs have correct country prefixes and lengths but random digits β€” they are not real bank accounts.

Invoice (PDF)

The same invoice, rendered as a styled single-page PDF (and converted to 200 DPI PNG) with a line-item table, header block, and summary section. The PNG versions are the recommended input for vision models β€” most inference engines (including Ollama) accept PNG/JPG but not PDF. German number formatting (1.234,56), Swiss formatting (1'234.56), and English formatting (1,234.56) are all preserved visually β€” the model must read the numbers from the rendered document, not from parsed text.

Use the PDF versions to benchmark multimodal and vision-language models on document understanding. The text versions test reading comprehension; the PDF versions test whether the model can extract the same information when it has to see the invoice instead of read it.

Ground Truth (JSON)

{
  "invoice_id": "INV-2026-0042",
  "vendor": "Pierce & Pierce Holdings Ltd",
  "subtotal": "7542.50",
  "vat_rate": "0.20",
  "vat_amount": "1508.50",
  "discount": {
    "type": "percentage",
    "value": "0.05",
    "applied_to": "subtotal",
    "conditional": false
  },
  "discount_amount": "377.13",
  "total": "8673.87",
  "variants": {
    "vat_variant": "explicit_excluded",
    "discount_variant": "explicit_percentage",
    "number_format": "english",
    "layout": "table",
    "consistency": "correct",
    "edge_case": "none"
  },
  "rendered_subtotal": "7542.50",
  "rendered_total": "8673.87",
  "error_note": null
}

All monetary values are two-decimal strings. The distinction between total and rendered_total matters: for error-injected invoices, rendered_total is what the model sees, and total is the correct answer.

Known Limitations

All invoices are rendered in English regardless of the vendor's implied nationality. A bilingual corpus (English/German) would be a natural extension.

A single VAT rate of 20% is used throughout the main corpus. Country-specific rates (19% DE, 21% NL, 25% NO) are not modelled.

The corpus is 200 invoices by design β€” dense enough for per-dimension signal, small enough to run against expensive models. Scale to any size with --count.

Company names are drawn from films, TV, and novels. If you are benchmarking a model that was trained on Office Space quotes, Initech Solutions GmbH may be easier to parse than it should be.

Citation

If you use this dataset, please cite:

@misc{invoicebenchmark2026,
  title={InvoiceBenchmark: A Controlled Corpus for Measuring LLM Invoice Processing Accuracy},
  author={Neugebauer, Jakob},
  year={2026},
  url={https://www.jngb.online/notes/06-too-dangerous-to-release},
  note={200 synthetic invoices varying across five controlled dimensions with cent-perfect ground truth}
}

Licence

MIT. Use it, break it, publish your results, tell people about it.

Downloads last month
50