Document Template – YAML Configuration Guide
Document templates are used to extract specific fields from documents such as invoices, forms, or reports.
Each field is defined individually with its own position and data type.
fields:
- name: invoice_number
type: text
- name: date
type: date
- name: total
type: currency
Each field requires coordinates defining its position on the document.
areas:
invoice_number:
x: 100
y: 150
width: 300
height: 50
total:
x: 500
y: 700
width: 200
height: 60
template:
type: document
name: invoice_header
source:
type: pdf
fields:
- name: invoice_number
type: text
- name: date
type: date
- name: total
type: currency
areas:
invoice_number:
x: 100
y: 150
width: 300
height: 50
date:
x: 400
y: 150
width: 200
height: 50
total:
x: 500
y: 700
width: 200
height: 60