File size: 3,524 Bytes
156e7ce
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
---
license: cc-by-4.0
pretty_name: Form Field Detection Benchmark
task_categories:
  - object-detection
  - image-to-text
language:
  - en
tags:
  - document-ai
  - forms
  - form-understanding
size_categories:
  - n<1K
configs:
  - config_name: default
    data_files:
      - split: test
        path: data/test-*
---

# Form Field Detection Benchmark

A fixed, test-only benchmark for end-to-end form-field extraction. It contains the exact **100 clean
form pages and 701 fields** used by the
[`form-field-vlm` scorecard](https://huggingface.co/nutrientdocs/form-field-vlm) and
[leaderboard](https://huggingface.co/spaces/nutrientdocs/form-field-vlm-leaderboard). Try the complete
server-side pipeline in the [demo](https://huggingface.co/spaces/nutrientdocs/form-field-vlm-demo).

The task is to return every interactive widget as constrained JSON with:

- `box`: `[x0, y0, x1, y1]` on a 0–1000 page grid
- `type`: `text`, `choice_checkbox`, `choice_radio`, `choice_select`, or `signature`
- `label`: the field's text label
- `group_id`: shared radio-group identifier, otherwise `null`

## Metrics

The headline is typed-field F1 at **IoU 0.5**. A match requires sufficient box overlap and the
correct fine field type. We also report IoU 0.2, per-type precision/recall/F1, Box F1, Box Recall, density slices,
count MAE, false positives per page, and measured seconds per page.

IoU 0.5 is the ranking metric because downstream form filling needs tight widget boxes. IoU 0.2 is a
diagnostic for approximately correct but loosely grounded predictions.

## Schema

```python
from datasets import load_dataset
benchmark = load_dataset("nutrientdocs/form-field-vlm-benchmark", split="test")
```

| Field | Meaning |
|---|---|
| `image` | RGB form-page image |
| `page_id` | Stable benchmark page identifier |
| `width`, `height` | Original image dimensions |
| `fields` | Gold field objects in original page coordinates |
| `source` | Upstream source family |
| `license_class` | Redistribution classification |

## Scoring

The reference scorer accepts a JSON list of predictions in original page pixels:

```bash
python score.py --benchmark-repo nutrientdocs/form-field-vlm-benchmark \
  --predictions predictions.json --out result.json
```

Each prediction is `{page_id, box: [x,y,w,h], type, label?, group_id?}` in original page pixels. The
self-contained scorer downloads the public test split and emits the complete IoU 0.5 and 0.2 breakdown
used by the leaderboard. Submit the resulting JSON with the model ID, license, runtime environment, and
seconds/page for review.

## Scope

This fixed 100-page set is small enough to run across local and cloud VLMs, but it should not be treated
as a comprehensive measure of all form styles. A future, larger document-disjoint benchmark should be
published separately rather than silently changing this set.

## License and attribution

The benchmark pages derive from [**CommonForms**](https://github.com/jbarrow/commonforms), released under
**CC-BY-4.0**. See
[`ATTRIBUTION.md`](./ATTRIBUTION.md) for the citation and provenance statement.

## About the author

<a href="https://nutrient.io/">
  <img src="https://avatars2.githubusercontent.com/u/1527679?v=3&s=200" height="80" />
</a>

This project is maintained and funded by [Nutrient](https://nutrient.io/) - The deterministic document infrastructure enterprises run their highest-stakes workflows on: replayable output, clear exceptions, and full audit trails on the messy, regulated documents where AI alone breaks.