File size: 1,637 Bytes
7ff7119
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
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
{
  "type": "object",
  "title": "DeliveryNoteSchema",
  "description": "Structured-extraction schema for delivery notes.",
  "properties": {
    "document_number": { "type": ["string", "null"] },
    "issue_date": { "type": ["string", "null"] },
    "delivery_date": { "type": ["string", "null"] },
    "purchase_order_reference": { "type": ["string", "null"], "description": "Related purchase order number (for three-way matching)" },
    "supplier": {
      "type": ["object", "null"],
      "properties": {
        "name": { "type": ["string", "null"] },
        "tax_id": { "type": ["string", "null"] },
        "address": { "type": ["string", "null"] }
      }
    },
    "customer": {
      "type": ["object", "null"],
      "properties": {
        "name": { "type": ["string", "null"] },
        "tax_id": { "type": ["string", "null"] },
        "address": { "type": ["string", "null"] }
      }
    },
    "line_items": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "item_code": { "type": ["string", "null"] },
          "description": { "type": ["string", "null"] },
          "quantity": { "type": ["number", "null"] },
          "unit": { "type": ["string", "null"] }
        }
      }
    },
    "notes": { "type": ["string", "null"] },
    "_quotes": { "type": "array", "items": { "type": "string" } },
    "_confidence": { "type": "object" },
    "_source": {
      "type": "object",
      "properties": {
        "file_name": { "type": "string" },
        "page_number": { "type": ["integer", "null"] }
      }
    }
  },
  "required": ["_quotes", "_confidence"]
}