DocFlow Invoice Parser FA

Enterprise-grade Persian invoice field extraction model configuration by Aria AI.

Model Description

DocFlow AI combines vision OCR with NLP heuristics and business-rule validation to extract structured data from Persian and bilingual financial documents. This repository hosts the production pipeline configuration and serves as the model card for the DocFlow product line.

Component Technology
OCR EasyOCR (fa/en) + image preprocessing
Field extraction ParsBERT NER + regex + line-based KV parsing
Validation Pydantic business rules engine
Review workflow Accountant approve/reject queue
Export JSON, Excel (openpyxl)
API FastAPI + PostgreSQL

Intended Uses

  • Accounts payable automation
  • Invoice digitization for ERP integration (SAP, Rahkaran, Sepidar)
  • Pilot deployments with accountant-in-the-loop review

Out-of-Scope Uses

  • Legal contract analysis (see ContractGuard)
  • Processing real PII in public Spaces without on-prem deployment
  • Fully autonomous posting without human review

Training Data

Synthetic and anonymized invoices from docflow-invoice-samples-fa.

Evaluation Metrics (Internal Pilot)

Field Precision Recall F1
vendor_name 0.94 0.91 0.92
invoice_number 0.96 0.93 0.94
total_amount 0.97 0.95 0.96
invoice_date 0.89 0.87 0.88
Macro avg 0.94 0.92 0.93

Limitations

  • Heuristic demo pipeline; accuracy varies on handwritten or low-quality scans
  • Jalali date parsing does not validate calendar correctness
  • Line-item table detection requires structured tabular layout

Bias & Fairness

Trained primarily on standard printed Persian invoices from manufacturing and distribution sectors. Performance may be lower on handwritten or non-standard layouts.

Demo

Interactive Space: docflow-invoice-parser-fa

Citation

@misc{docflow_invoice_parser_fa_2025,
  title={DocFlow AI: Intelligent Persian Invoice Parser},
  author={Aria AI Engineering Team},
  year={2025},
  url={https://huggingface.co/alirezaaminzadeh/docflow-invoice-parser-fa}
}

License

Apache 2.0

Downloads last month
55
Inference Providers NEW
This model isn't deployed by any Inference Provider. ๐Ÿ™‹ Ask for provider support

Space using alirezaaminzadeh/docflow-invoice-parser-fa 1