Token Classification
Transformers
Safetensors
layoutlmv3
ner
on-device
privacy
flowx
openner
cross
de-identification
Instructions to use flowxai/docformner with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use flowxai/docformner with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("token-classification", model="flowxai/docformner")# Load model directly from transformers import AutoProcessor, AutoModelForTokenClassification processor = AutoProcessor.from_pretrained("flowxai/docformner") model = AutoModelForTokenClassification.from_pretrained("flowxai/docformner", device_map="auto") - Notebooks
- Google Colab
- Kaggle
File size: 2,208 Bytes
d58e253 | 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 | ---
license: apache-2.0
library_name: transformers
pipeline_tag: token-classification
base_model: microsoft/layoutlmv3-base
tags:
- ner
- on-device
- privacy
- flowx
- openner
- cross
- de-identification
- token-classification
metrics:
- f1
---
# DocFormNER
**DocFormNER** is a small, on-device cross NER model from the FlowX **OpenNER** family. Developed by **FlowX.AI**. Runs 100% on-premise / air-gapped, so no data leaves your boundary.
## What it does
- **Task:** token-classification
- **Base model:** `microsoft/layoutlmv3-base`
- **Entity types (9):** APP_NO, BORROWER, INCOME, INTEREST_RATE, LENDER, LOAN_AMOUNT, LTV, PROPERTY_ADDR, TERM_YEARS
- **Held-out F1:** 1.0000
- **Runtime:** CPU, Apple Silicon, one GPU, or browser/edge via ONNX (INT8). ~100-160 ms/doc on CPU.
## Why a small model
Fine-tuned encoders match or beat frontier LLMs on structured, convention-bound extraction, at a fraction of the latency and cost, with **zero data egress**. Identifiers are validated by checksum (IBAN mod-97, card Luhn, ISIN/LEI, container ISO-6346, VIN, national IDs), a correctness guarantee general LLMs lack. See the FlowX OpenNER benchmark for measured results.
> **Document-AI preview.** DocFormNER is a **LayoutLMv3** model that reads text + 2D layout + the page image, so it works on scanned / photographed forms (mortgage packets, bills of lading, ACORD forms). This checkpoint is trained on **synthetic rendered forms** as a walking skeleton; for production, fine-tune on real OCR'd documents (FUNSD / DocLayNet / CORD or your own scans) with the same `{words, bboxes, labels, image}` shape.
## Usage
```python
from transformers import AutoTokenizer, AutoModelForTokenClassification
tok = AutoTokenizer.from_pretrained("flowxai/docformner")
model = AutoModelForTokenClassification.from_pretrained("flowxai/docformner")
```
## License & attribution
Licensed under the **Apache License 2.0**. Copyright 2026 **FlowX.AI** (https://flowx.ai). See the `NOTICE` file. Trained on synthetic, checksum-validated data.
_Part of the FlowX OpenNER model family. Synthetic-data F1 reflects an in-distribution synthetic distribution; validate on real documents before production use._ |