Prompt
Parse this invoice text and return structured JSON: 'Invoice #INV-2024-0847 dated March 15, 2024. Bill to: TechStart Ltd, 42 Innovation Drive, London. Items: 3x Widget A ($50 each), 1x Widget B ($120). Subtotal: $270. Tax (20%): $54. Total: $324.'
Baseline output (GPT-4o) ✓
{
"invoice_number": "INV-2024-0847",
"date": "2024-03-15",
"bill_to": {
"name": "TechStart Ltd",
"address": "42 Innovation Drive, London"
},
"items": [
{"name": "Widget A", "quantity": 3, "unit_price": 50, "total": 150},
{"name": "Widget B", "quantity": 1, "unit_price": 120, "total": 120}
],
"subtotal": 270,
"tax_rate": 0.20,
"tax": 54,
"total": 324
}
Candidate output (Claude Haiku) ✗
Here's the parsed invoice data:
Invoice Number: INV-2024-0847
Date: March 15, 2024
Bill to: TechStart Ltd, 42 Innovation Drive, London
Items:
- Widget A × 3 = $150
- Widget B × 1 = $120
Subtotal: $270
Tax (20%): $54
Total: $324
Returned markdown instead of JSON. Schema break: no valid JSON object.