Schema

Golden Record Schema

Standardized data model for extracted documents. All fields follow consistent types and formats.

SyncAI returns a "Golden Record" - a normalized, validated data structure regardless of input format. This ensures consistent downstream processing.

Invoice Schema

FieldTypeFormatExample
invoice_noStringAlphanumeric ID"INV-2024-0892"
vendorStringCompany name"TechFlow Inc."
dateStringISO 8601: YYYY-MM-DD"2024-01-15"
subtotalFloatDecimal, 2 places8500.00
taxFloatDecimal, 2 places680.00
totalFloatDecimal, 2 places9180.00
line_itemsArrayArray of LineItem[{...}]

LineItem Object

FieldTypeDescription
descriptionStringItem description
quantityFloatNumber of units
unit_priceFloatPrice per unit
amountFloatLine total (quantity × unit_price)

Data Type Reference

FloatMonetary Values

  • • Always a decimal number
  • • 2 decimal places precision
  • • No currency symbols
  • • Example: 9180.00

StringDates

  • • ISO 8601 format
  • • Always YYYY-MM-DD
  • • No time zone info
  • • Example: "2024-01-15"

Full Example Response

{
  "header": {
    "vendor": "TechFlow Inc.",
    "date": "2024-01-15",
    "invoice_no": "INV-2024-0892"
  },
  "amounts": {
    "subtotal": 8500.00,
    "tax": 680.00,
    "total": 9180.00
  },
  "line_items": [
    {
      "description": "Software License - Annual",
      "quantity": 1,
      "unit_price": 5000.00,
      "amount": 5000.00
    },
    {
      "description": "Implementation Support",
      "quantity": 10,
      "unit_price": 350.00,
      "amount": 3500.00
    }
  ]
}