{
  "tool_id": "art-701-three-way-invoice-match",
  "note": "Fifteen fixtures F1 to F15; F1 (the seal vector) is vectors[0]. Expected output_payload values were hand-derived from the build spec first (integer minor-unit totals, half-up tax at 825 bp, the 200 bp tolerance boundary at exact pass and 201 bp fail, days-from-civil window edges at 10 and 15 days, the normalized-number rule INV-0042 vs inv42) and only then checked against compute(); every refusal case names its reason. human_sign_off: PENDING.",
  "vectors": [
    {
      "name": "F1-clean-match-seal",
      "policy_parameters": {
        "currency": "USD",
        "invoice": {
          "invoice_number": "INV-0042",
          "issue_date": "2026-09-30",
          "vendor_id": "V-1",
          "po_number": "PO-7",
          "subtotal_minor": 170000,
          "tax_minor": 14025,
          "total_minor": 184025,
          "lines": [
            {
              "line": 1,
              "po_line": 1,
              "sku": "A-100",
              "qty": 10,
              "unit_price_minor": 12000,
              "amount_minor": 120000
            },
            {
              "line": 2,
              "po_line": 2,
              "sku": "B-200",
              "qty": 5,
              "unit_price_minor": 4000,
              "amount_minor": 20000
            },
            {
              "line": 3,
              "po_line": 3,
              "sku": "C-300",
              "qty": 2,
              "unit_price_minor": 15000,
              "amount_minor": 30000
            }
          ]
        },
        "purchase_order": {
          "po_number": "PO-7",
          "lines": [
            {
              "line": 1,
              "sku": "A-100",
              "qty": 10,
              "unit_price_minor": 12000
            },
            {
              "line": 2,
              "sku": "B-200",
              "qty": 5,
              "unit_price_minor": 4000
            },
            {
              "line": 3,
              "sku": "C-300",
              "qty": 2,
              "unit_price_minor": 15000
            }
          ]
        },
        "goods_receipt": {
          "receipt_id": "GR-3",
          "lines": [
            {
              "po_line": 1,
              "qty_received": 10
            },
            {
              "po_line": 2,
              "qty_received": 5
            },
            {
              "po_line": 3,
              "qty_received": 2
            }
          ]
        },
        "vendor_terms": {
          "price_tolerance_bp": 200,
          "tax_rate_bp": 825,
          "tax_rounding": "half_up"
        },
        "prior_invoices": [],
        "duplicate_window_days": 14
      },
      "output_payload": {
        "outcome": "match",
        "po_number": "PO-7",
        "receipt_id": "GR-3",
        "lines": [
          {
            "line": 1,
            "paired_po_line": 1,
            "qty": 10,
            "qty_ordered": 10,
            "qty_received": 10,
            "unit_price_minor": 12000,
            "po_unit_price_minor": 12000,
            "variance_bp": 0,
            "amount_ok": true,
            "verdict": "ok"
          },
          {
            "line": 2,
            "paired_po_line": 2,
            "qty": 5,
            "qty_ordered": 5,
            "qty_received": 5,
            "unit_price_minor": 4000,
            "po_unit_price_minor": 4000,
            "variance_bp": 0,
            "amount_ok": true,
            "verdict": "ok"
          },
          {
            "line": 3,
            "paired_po_line": 3,
            "qty": 2,
            "qty_ordered": 2,
            "qty_received": 2,
            "unit_price_minor": 15000,
            "po_unit_price_minor": 15000,
            "variance_bp": 0,
            "amount_ok": true,
            "verdict": "ok"
          }
        ],
        "totals": {
          "line_sum_minor": 170000,
          "subtotal_ok": true,
          "tax_expected_minor": 14025,
          "tax_ok": true,
          "total_expected_minor": 184025,
          "total_ok": true
        },
        "mismatches": [],
        "duplicates": [],
        "domain_errors": [],
        "hold_recommended": false,
        "scope_note": "Integer minor units only: fractional quantities and sub-minor-unit prices are refused, not rounded. One currency per invoice. One declared tax rate; no tax-jurisdiction logic."
      },
      "golden_hash": "a52bb0025fa24cc852916664074485dbe41738628395c343223d16fadd59b775"
    },
    {
      "name": "F2-qty-over-received",
      "policy_parameters": {
        "currency": "USD",
        "invoice": {
          "invoice_number": "INV-0042",
          "issue_date": "2026-09-30",
          "vendor_id": "V-1",
          "po_number": "PO-7",
          "subtotal_minor": 194000,
          "tax_minor": 16005,
          "total_minor": 210005,
          "lines": [
            {
              "line": 1,
              "po_line": 1,
              "sku": "A-100",
              "qty": 12,
              "unit_price_minor": 12000,
              "amount_minor": 144000
            },
            {
              "line": 2,
              "po_line": 2,
              "sku": "B-200",
              "qty": 5,
              "unit_price_minor": 4000,
              "amount_minor": 20000
            },
            {
              "line": 3,
              "po_line": 3,
              "sku": "C-300",
              "qty": 2,
              "unit_price_minor": 15000,
              "amount_minor": 30000
            }
          ]
        },
        "purchase_order": {
          "po_number": "PO-7",
          "lines": [
            {
              "line": 1,
              "sku": "A-100",
              "qty": 10,
              "unit_price_minor": 12000
            },
            {
              "line": 2,
              "sku": "B-200",
              "qty": 5,
              "unit_price_minor": 4000
            },
            {
              "line": 3,
              "sku": "C-300",
              "qty": 2,
              "unit_price_minor": 15000
            }
          ]
        },
        "goods_receipt": {
          "receipt_id": "GR-3",
          "lines": [
            {
              "po_line": 1,
              "qty_received": 10
            },
            {
              "po_line": 2,
              "qty_received": 5
            },
            {
              "po_line": 3,
              "qty_received": 2
            }
          ]
        },
        "vendor_terms": {
          "price_tolerance_bp": 200,
          "tax_rate_bp": 825,
          "tax_rounding": "half_up"
        },
        "prior_invoices": [],
        "duplicate_window_days": 14
      },
      "output_payload": {
        "outcome": "mismatch",
        "po_number": "PO-7",
        "receipt_id": "GR-3",
        "lines": [
          {
            "line": 1,
            "paired_po_line": 1,
            "qty": 12,
            "qty_ordered": 10,
            "qty_received": 10,
            "unit_price_minor": 12000,
            "po_unit_price_minor": 12000,
            "variance_bp": null,
            "amount_ok": true,
            "verdict": "qty_over_received"
          },
          {
            "line": 2,
            "paired_po_line": 2,
            "qty": 5,
            "qty_ordered": 5,
            "qty_received": 5,
            "unit_price_minor": 4000,
            "po_unit_price_minor": 4000,
            "variance_bp": 0,
            "amount_ok": true,
            "verdict": "ok"
          },
          {
            "line": 3,
            "paired_po_line": 3,
            "qty": 2,
            "qty_ordered": 2,
            "qty_received": 2,
            "unit_price_minor": 15000,
            "po_unit_price_minor": 15000,
            "variance_bp": 0,
            "amount_ok": true,
            "verdict": "ok"
          }
        ],
        "totals": {
          "line_sum_minor": 194000,
          "subtotal_ok": true,
          "tax_expected_minor": 16005,
          "tax_ok": true,
          "total_expected_minor": 210005,
          "total_ok": true
        },
        "mismatches": [
          {
            "code": "LINE_QTY_OVER_RECEIVED",
            "line": 1,
            "text": "Line 1: invoiced 12, received 10"
          }
        ],
        "duplicates": [],
        "domain_errors": [],
        "hold_recommended": true,
        "scope_note": "Integer minor units only: fractional quantities and sub-minor-unit prices are refused, not rounded. One currency per invoice. One declared tax rate; no tax-jurisdiction logic."
      },
      "golden_hash": "8062f5ece52ef2c530303e13891d19985b09456fbfe361953f6d1c70da0c171c"
    },
    {
      "name": "F3-qty-over-ordered",
      "policy_parameters": {
        "currency": "USD",
        "invoice": {
          "invoice_number": "INV-0042",
          "issue_date": "2026-09-30",
          "vendor_id": "V-1",
          "po_number": "PO-7",
          "subtotal_minor": 194000,
          "tax_minor": 16005,
          "total_minor": 210005,
          "lines": [
            {
              "line": 1,
              "po_line": 1,
              "sku": "A-100",
              "qty": 12,
              "unit_price_minor": 12000,
              "amount_minor": 144000
            },
            {
              "line": 2,
              "po_line": 2,
              "sku": "B-200",
              "qty": 5,
              "unit_price_minor": 4000,
              "amount_minor": 20000
            },
            {
              "line": 3,
              "po_line": 3,
              "sku": "C-300",
              "qty": 2,
              "unit_price_minor": 15000,
              "amount_minor": 30000
            }
          ]
        },
        "purchase_order": {
          "po_number": "PO-7",
          "lines": [
            {
              "line": 1,
              "sku": "A-100",
              "qty": 10,
              "unit_price_minor": 12000
            },
            {
              "line": 2,
              "sku": "B-200",
              "qty": 5,
              "unit_price_minor": 4000
            },
            {
              "line": 3,
              "sku": "C-300",
              "qty": 2,
              "unit_price_minor": 15000
            }
          ]
        },
        "goods_receipt": {
          "receipt_id": "GR-3",
          "lines": [
            {
              "po_line": 1,
              "qty_received": 12
            },
            {
              "po_line": 2,
              "qty_received": 5
            },
            {
              "po_line": 3,
              "qty_received": 2
            }
          ]
        },
        "vendor_terms": {
          "price_tolerance_bp": 200,
          "tax_rate_bp": 825,
          "tax_rounding": "half_up"
        },
        "prior_invoices": [],
        "duplicate_window_days": 14
      },
      "output_payload": {
        "outcome": "mismatch",
        "po_number": "PO-7",
        "receipt_id": "GR-3",
        "lines": [
          {
            "line": 1,
            "paired_po_line": 1,
            "qty": 12,
            "qty_ordered": 10,
            "qty_received": 12,
            "unit_price_minor": 12000,
            "po_unit_price_minor": 12000,
            "variance_bp": null,
            "amount_ok": true,
            "verdict": "qty_over_ordered"
          },
          {
            "line": 2,
            "paired_po_line": 2,
            "qty": 5,
            "qty_ordered": 5,
            "qty_received": 5,
            "unit_price_minor": 4000,
            "po_unit_price_minor": 4000,
            "variance_bp": 0,
            "amount_ok": true,
            "verdict": "ok"
          },
          {
            "line": 3,
            "paired_po_line": 3,
            "qty": 2,
            "qty_ordered": 2,
            "qty_received": 2,
            "unit_price_minor": 15000,
            "po_unit_price_minor": 15000,
            "variance_bp": 0,
            "amount_ok": true,
            "verdict": "ok"
          }
        ],
        "totals": {
          "line_sum_minor": 194000,
          "subtotal_ok": true,
          "tax_expected_minor": 16005,
          "tax_ok": true,
          "total_expected_minor": 210005,
          "total_ok": true
        },
        "mismatches": [
          {
            "code": "LINE_QTY_OVER_ORDERED",
            "line": 1,
            "text": "Line 1: invoiced 12, ordered 10"
          }
        ],
        "duplicates": [],
        "domain_errors": [],
        "hold_recommended": true,
        "scope_note": "Integer minor units only: fractional quantities and sub-minor-unit prices are refused, not rounded. One currency per invoice. One declared tax rate; no tax-jurisdiction logic."
      },
      "golden_hash": "db5cadfa181963b41bf7895f4c560b84ac53c4ecd031ff8b358fdab0309d07c9"
    },
    {
      "name": "F4-price-at-tolerance-passes-one-bp-over-fails",
      "policy_parameters": {
        "currency": "USD",
        "invoice": {
          "invoice_number": "INV-0042",
          "issue_date": "2026-09-30",
          "vendor_id": "V-1",
          "po_number": "PO-8",
          "subtotal_minor": 142804,
          "tax_minor": 11781,
          "total_minor": 154585,
          "lines": [
            {
              "line": 1,
              "po_line": 1,
              "sku": "A-100",
              "qty": 10,
              "unit_price_minor": 10200,
              "amount_minor": 102000
            },
            {
              "line": 2,
              "po_line": 2,
              "sku": "B-200",
              "qty": 4,
              "unit_price_minor": 10201,
              "amount_minor": 40804
            }
          ]
        },
        "purchase_order": {
          "po_number": "PO-8",
          "lines": [
            {
              "line": 1,
              "sku": "A-100",
              "qty": 10,
              "unit_price_minor": 10000
            },
            {
              "line": 2,
              "sku": "B-200",
              "qty": 4,
              "unit_price_minor": 10000
            }
          ]
        },
        "goods_receipt": {
          "receipt_id": "GR-8",
          "lines": [
            {
              "po_line": 1,
              "qty_received": 10
            },
            {
              "po_line": 2,
              "qty_received": 4
            }
          ]
        },
        "vendor_terms": {
          "price_tolerance_bp": 200,
          "tax_rate_bp": 825,
          "tax_rounding": "half_up"
        },
        "prior_invoices": [],
        "duplicate_window_days": 14
      },
      "output_payload": {
        "outcome": "mismatch",
        "po_number": "PO-8",
        "receipt_id": "GR-8",
        "lines": [
          {
            "line": 1,
            "paired_po_line": 1,
            "qty": 10,
            "qty_ordered": 10,
            "qty_received": 10,
            "unit_price_minor": 10200,
            "po_unit_price_minor": 10000,
            "variance_bp": 200,
            "amount_ok": true,
            "verdict": "ok"
          },
          {
            "line": 2,
            "paired_po_line": 2,
            "qty": 4,
            "qty_ordered": 4,
            "qty_received": 4,
            "unit_price_minor": 10201,
            "po_unit_price_minor": 10000,
            "variance_bp": 201,
            "amount_ok": true,
            "verdict": "price_over_tolerance"
          }
        ],
        "totals": {
          "line_sum_minor": 142804,
          "subtotal_ok": true,
          "tax_expected_minor": 11781,
          "tax_ok": true,
          "total_expected_minor": 154585,
          "total_ok": true
        },
        "mismatches": [
          {
            "code": "LINE_PRICE_OVER_TOLERANCE",
            "line": 2,
            "text": "Line 2: price variance 201 bp exceeds tolerance 200 bp"
          }
        ],
        "duplicates": [],
        "domain_errors": [],
        "hold_recommended": true,
        "scope_note": "Integer minor units only: fractional quantities and sub-minor-unit prices are refused, not rounded. One currency per invoice. One declared tax rate; no tax-jurisdiction logic."
      },
      "golden_hash": "123ca61734a71a2d69548c2b73aefa8cc2b9e91a7080c16722e98c8f9db5ee63"
    },
    {
      "name": "F5-line-not-on-po",
      "policy_parameters": {
        "currency": "USD",
        "invoice": {
          "invoice_number": "INV-0042",
          "issue_date": "2026-09-30",
          "vendor_id": "V-1",
          "po_number": "PO-7",
          "subtotal_minor": 175000,
          "tax_minor": 14438,
          "total_minor": 189438,
          "lines": [
            {
              "line": 1,
              "po_line": 1,
              "sku": "A-100",
              "qty": 10,
              "unit_price_minor": 12000,
              "amount_minor": 120000
            },
            {
              "line": 2,
              "po_line": 2,
              "sku": "B-200",
              "qty": 5,
              "unit_price_minor": 4000,
              "amount_minor": 20000
            },
            {
              "line": 3,
              "po_line": 3,
              "sku": "C-300",
              "qty": 2,
              "unit_price_minor": 15000,
              "amount_minor": 30000
            },
            {
              "line": 4,
              "sku": "D-400",
              "qty": 1,
              "unit_price_minor": 5000,
              "amount_minor": 5000
            }
          ]
        },
        "purchase_order": {
          "po_number": "PO-7",
          "lines": [
            {
              "line": 1,
              "sku": "A-100",
              "qty": 10,
              "unit_price_minor": 12000
            },
            {
              "line": 2,
              "sku": "B-200",
              "qty": 5,
              "unit_price_minor": 4000
            },
            {
              "line": 3,
              "sku": "C-300",
              "qty": 2,
              "unit_price_minor": 15000
            }
          ]
        },
        "goods_receipt": {
          "receipt_id": "GR-3",
          "lines": [
            {
              "po_line": 1,
              "qty_received": 10
            },
            {
              "po_line": 2,
              "qty_received": 5
            },
            {
              "po_line": 3,
              "qty_received": 2
            }
          ]
        },
        "vendor_terms": {
          "price_tolerance_bp": 200,
          "tax_rate_bp": 825,
          "tax_rounding": "half_up"
        },
        "prior_invoices": [],
        "duplicate_window_days": 14
      },
      "output_payload": {
        "outcome": "mismatch",
        "po_number": "PO-7",
        "receipt_id": "GR-3",
        "lines": [
          {
            "line": 1,
            "paired_po_line": 1,
            "qty": 10,
            "qty_ordered": 10,
            "qty_received": 10,
            "unit_price_minor": 12000,
            "po_unit_price_minor": 12000,
            "variance_bp": 0,
            "amount_ok": true,
            "verdict": "ok"
          },
          {
            "line": 2,
            "paired_po_line": 2,
            "qty": 5,
            "qty_ordered": 5,
            "qty_received": 5,
            "unit_price_minor": 4000,
            "po_unit_price_minor": 4000,
            "variance_bp": 0,
            "amount_ok": true,
            "verdict": "ok"
          },
          {
            "line": 3,
            "paired_po_line": 3,
            "qty": 2,
            "qty_ordered": 2,
            "qty_received": 2,
            "unit_price_minor": 15000,
            "po_unit_price_minor": 15000,
            "variance_bp": 0,
            "amount_ok": true,
            "verdict": "ok"
          },
          {
            "line": 4,
            "paired_po_line": null,
            "qty": 1,
            "qty_ordered": null,
            "qty_received": null,
            "unit_price_minor": 5000,
            "po_unit_price_minor": null,
            "variance_bp": null,
            "amount_ok": true,
            "verdict": "line_not_on_po"
          }
        ],
        "totals": {
          "line_sum_minor": 175000,
          "subtotal_ok": true,
          "tax_expected_minor": 14438,
          "tax_ok": true,
          "total_expected_minor": 189438,
          "total_ok": true
        },
        "mismatches": [
          {
            "code": "LINE_NOT_ON_PO",
            "line": 4,
            "text": "Line 4: not on purchase order PO-7"
          }
        ],
        "duplicates": [],
        "domain_errors": [],
        "hold_recommended": true,
        "scope_note": "Integer minor units only: fractional quantities and sub-minor-unit prices are refused, not rounded. One currency per invoice. One declared tax rate; no tax-jurisdiction logic."
      },
      "golden_hash": "4c27aea7207bf8330aecdbcdb6f0db98a71a3bde800404c49bf4044eb1669ad8"
    },
    {
      "name": "F6-no-po",
      "policy_parameters": {
        "currency": "USD",
        "invoice": {
          "invoice_number": "INV-0042",
          "issue_date": "2026-09-30",
          "vendor_id": "V-1",
          "po_number": "PO-7",
          "subtotal_minor": 170000,
          "tax_minor": 14025,
          "total_minor": 184025,
          "lines": [
            {
              "line": 1,
              "po_line": 1,
              "sku": "A-100",
              "qty": 10,
              "unit_price_minor": 12000,
              "amount_minor": 120000
            },
            {
              "line": 2,
              "po_line": 2,
              "sku": "B-200",
              "qty": 5,
              "unit_price_minor": 4000,
              "amount_minor": 20000
            },
            {
              "line": 3,
              "po_line": 3,
              "sku": "C-300",
              "qty": 2,
              "unit_price_minor": 15000,
              "amount_minor": 30000
            }
          ]
        },
        "goods_receipt": {
          "receipt_id": "GR-3",
          "lines": [
            {
              "po_line": 1,
              "qty_received": 10
            },
            {
              "po_line": 2,
              "qty_received": 5
            },
            {
              "po_line": 3,
              "qty_received": 2
            }
          ]
        },
        "vendor_terms": {
          "price_tolerance_bp": 200,
          "tax_rate_bp": 825,
          "tax_rounding": "half_up"
        },
        "prior_invoices": [],
        "duplicate_window_days": 14
      },
      "output_payload": {
        "outcome": "no_po",
        "po_number": "PO-7",
        "receipt_id": "GR-3",
        "lines": [
          {
            "line": 1,
            "paired_po_line": null,
            "qty": 10,
            "qty_ordered": null,
            "qty_received": null,
            "unit_price_minor": 12000,
            "po_unit_price_minor": null,
            "variance_bp": null,
            "amount_ok": true,
            "verdict": "line_not_on_po"
          },
          {
            "line": 2,
            "paired_po_line": null,
            "qty": 5,
            "qty_ordered": null,
            "qty_received": null,
            "unit_price_minor": 4000,
            "po_unit_price_minor": null,
            "variance_bp": null,
            "amount_ok": true,
            "verdict": "line_not_on_po"
          },
          {
            "line": 3,
            "paired_po_line": null,
            "qty": 2,
            "qty_ordered": null,
            "qty_received": null,
            "unit_price_minor": 15000,
            "po_unit_price_minor": null,
            "variance_bp": null,
            "amount_ok": true,
            "verdict": "line_not_on_po"
          }
        ],
        "totals": {
          "line_sum_minor": 170000,
          "subtotal_ok": true,
          "tax_expected_minor": 14025,
          "tax_ok": true,
          "total_expected_minor": 184025,
          "total_ok": true
        },
        "mismatches": [],
        "duplicates": [],
        "domain_errors": [],
        "hold_recommended": true,
        "scope_note": "Integer minor units only: fractional quantities and sub-minor-unit prices are refused, not rounded. One currency per invoice. One declared tax rate; no tax-jurisdiction logic."
      },
      "golden_hash": "7e48145204201af7d5ad5bf7202c7d9b1b7a854b080ee14594c50793c792d30f"
    },
    {
      "name": "F7-tax-half-up-rounding-edge",
      "policy_parameters": {
        "currency": "USD",
        "invoice": {
          "invoice_number": "INV-0007",
          "issue_date": "2026-09-30",
          "vendor_id": "V-1",
          "po_number": "PO-7",
          "subtotal_minor": 1000,
          "tax_minor": 83,
          "total_minor": 1083,
          "lines": [
            {
              "line": 1,
              "po_line": 1,
              "sku": "A-100",
              "qty": 1,
              "unit_price_minor": 1000,
              "amount_minor": 1000
            }
          ]
        },
        "purchase_order": {
          "po_number": "PO-7",
          "lines": [
            {
              "line": 1,
              "sku": "A-100",
              "qty": 10,
              "unit_price_minor": 1000
            }
          ]
        },
        "goods_receipt": {
          "receipt_id": "GR-3",
          "lines": [
            {
              "po_line": 1,
              "qty_received": 10
            }
          ]
        },
        "vendor_terms": {
          "price_tolerance_bp": 200,
          "tax_rate_bp": 825,
          "tax_rounding": "half_up"
        },
        "prior_invoices": [],
        "duplicate_window_days": 14
      },
      "output_payload": {
        "outcome": "match",
        "po_number": "PO-7",
        "receipt_id": "GR-3",
        "lines": [
          {
            "line": 1,
            "paired_po_line": 1,
            "qty": 1,
            "qty_ordered": 10,
            "qty_received": 10,
            "unit_price_minor": 1000,
            "po_unit_price_minor": 1000,
            "variance_bp": 0,
            "amount_ok": true,
            "verdict": "ok"
          }
        ],
        "totals": {
          "line_sum_minor": 1000,
          "subtotal_ok": true,
          "tax_expected_minor": 83,
          "tax_ok": true,
          "total_expected_minor": 1083,
          "total_ok": true
        },
        "mismatches": [],
        "duplicates": [],
        "domain_errors": [],
        "hold_recommended": false,
        "scope_note": "Integer minor units only: fractional quantities and sub-minor-unit prices are refused, not rounded. One currency per invoice. One declared tax rate; no tax-jurisdiction logic."
      },
      "golden_hash": "9c681fca92e03de329e2394820f200dc572d1596271ad9c1dc6b0d72673dc32c"
    },
    {
      "name": "F8-total-mismatch",
      "policy_parameters": {
        "currency": "USD",
        "invoice": {
          "invoice_number": "INV-0042",
          "issue_date": "2026-09-30",
          "vendor_id": "V-1",
          "po_number": "PO-7",
          "subtotal_minor": 170000,
          "tax_minor": 14025,
          "total_minor": 184026,
          "lines": [
            {
              "line": 1,
              "po_line": 1,
              "sku": "A-100",
              "qty": 10,
              "unit_price_minor": 12000,
              "amount_minor": 120000
            },
            {
              "line": 2,
              "po_line": 2,
              "sku": "B-200",
              "qty": 5,
              "unit_price_minor": 4000,
              "amount_minor": 20000
            },
            {
              "line": 3,
              "po_line": 3,
              "sku": "C-300",
              "qty": 2,
              "unit_price_minor": 15000,
              "amount_minor": 30000
            }
          ]
        },
        "purchase_order": {
          "po_number": "PO-7",
          "lines": [
            {
              "line": 1,
              "sku": "A-100",
              "qty": 10,
              "unit_price_minor": 12000
            },
            {
              "line": 2,
              "sku": "B-200",
              "qty": 5,
              "unit_price_minor": 4000
            },
            {
              "line": 3,
              "sku": "C-300",
              "qty": 2,
              "unit_price_minor": 15000
            }
          ]
        },
        "goods_receipt": {
          "receipt_id": "GR-3",
          "lines": [
            {
              "po_line": 1,
              "qty_received": 10
            },
            {
              "po_line": 2,
              "qty_received": 5
            },
            {
              "po_line": 3,
              "qty_received": 2
            }
          ]
        },
        "vendor_terms": {
          "price_tolerance_bp": 200,
          "tax_rate_bp": 825,
          "tax_rounding": "half_up"
        },
        "prior_invoices": [],
        "duplicate_window_days": 14
      },
      "output_payload": {
        "outcome": "mismatch",
        "po_number": "PO-7",
        "receipt_id": "GR-3",
        "lines": [
          {
            "line": 1,
            "paired_po_line": 1,
            "qty": 10,
            "qty_ordered": 10,
            "qty_received": 10,
            "unit_price_minor": 12000,
            "po_unit_price_minor": 12000,
            "variance_bp": 0,
            "amount_ok": true,
            "verdict": "ok"
          },
          {
            "line": 2,
            "paired_po_line": 2,
            "qty": 5,
            "qty_ordered": 5,
            "qty_received": 5,
            "unit_price_minor": 4000,
            "po_unit_price_minor": 4000,
            "variance_bp": 0,
            "amount_ok": true,
            "verdict": "ok"
          },
          {
            "line": 3,
            "paired_po_line": 3,
            "qty": 2,
            "qty_ordered": 2,
            "qty_received": 2,
            "unit_price_minor": 15000,
            "po_unit_price_minor": 15000,
            "variance_bp": 0,
            "amount_ok": true,
            "verdict": "ok"
          }
        ],
        "totals": {
          "line_sum_minor": 170000,
          "subtotal_ok": true,
          "tax_expected_minor": 14025,
          "tax_ok": true,
          "total_expected_minor": 184025,
          "total_ok": false
        },
        "mismatches": [
          {
            "code": "TOTAL_MISMATCH",
            "text": "Invoice total 184026 does not equal expected total 184025"
          }
        ],
        "duplicates": [],
        "domain_errors": [],
        "hold_recommended": true,
        "scope_note": "Integer minor units only: fractional quantities and sub-minor-unit prices are refused, not rounded. One currency per invoice. One declared tax rate; no tax-jurisdiction logic."
      },
      "golden_hash": "929156d61f11e85fdbe38d682d4ea247b5fa309fda7e5fb37a59129d4e3457e7"
    },
    {
      "name": "F9-duplicate-by-normalized-number",
      "policy_parameters": {
        "currency": "USD",
        "invoice": {
          "invoice_number": "INV-0042",
          "issue_date": "2026-09-30",
          "vendor_id": "V-1",
          "po_number": "PO-7",
          "subtotal_minor": 170000,
          "tax_minor": 14025,
          "total_minor": 184025,
          "lines": [
            {
              "line": 1,
              "po_line": 1,
              "sku": "A-100",
              "qty": 10,
              "unit_price_minor": 12000,
              "amount_minor": 120000
            },
            {
              "line": 2,
              "po_line": 2,
              "sku": "B-200",
              "qty": 5,
              "unit_price_minor": 4000,
              "amount_minor": 20000
            },
            {
              "line": 3,
              "po_line": 3,
              "sku": "C-300",
              "qty": 2,
              "unit_price_minor": 15000,
              "amount_minor": 30000
            }
          ]
        },
        "purchase_order": {
          "po_number": "PO-7",
          "lines": [
            {
              "line": 1,
              "sku": "A-100",
              "qty": 10,
              "unit_price_minor": 12000
            },
            {
              "line": 2,
              "sku": "B-200",
              "qty": 5,
              "unit_price_minor": 4000
            },
            {
              "line": 3,
              "sku": "C-300",
              "qty": 2,
              "unit_price_minor": 15000
            }
          ]
        },
        "goods_receipt": {
          "receipt_id": "GR-3",
          "lines": [
            {
              "po_line": 1,
              "qty_received": 10
            },
            {
              "po_line": 2,
              "qty_received": 5
            },
            {
              "po_line": 3,
              "qty_received": 2
            }
          ]
        },
        "vendor_terms": {
          "price_tolerance_bp": 200,
          "tax_rate_bp": 825,
          "tax_rounding": "half_up"
        },
        "prior_invoices": [
          {
            "id": "X",
            "vendor_id": "V-1",
            "invoice_number": "inv42",
            "issue_date": "2026-09-20",
            "total_minor": 999,
            "po_number": "PO-9"
          }
        ],
        "duplicate_window_days": 14
      },
      "output_payload": {
        "outcome": "match",
        "po_number": "PO-7",
        "receipt_id": "GR-3",
        "lines": [
          {
            "line": 1,
            "paired_po_line": 1,
            "qty": 10,
            "qty_ordered": 10,
            "qty_received": 10,
            "unit_price_minor": 12000,
            "po_unit_price_minor": 12000,
            "variance_bp": 0,
            "amount_ok": true,
            "verdict": "ok"
          },
          {
            "line": 2,
            "paired_po_line": 2,
            "qty": 5,
            "qty_ordered": 5,
            "qty_received": 5,
            "unit_price_minor": 4000,
            "po_unit_price_minor": 4000,
            "variance_bp": 0,
            "amount_ok": true,
            "verdict": "ok"
          },
          {
            "line": 3,
            "paired_po_line": 3,
            "qty": 2,
            "qty_ordered": 2,
            "qty_received": 2,
            "unit_price_minor": 15000,
            "po_unit_price_minor": 15000,
            "variance_bp": 0,
            "amount_ok": true,
            "verdict": "ok"
          }
        ],
        "totals": {
          "line_sum_minor": 170000,
          "subtotal_ok": true,
          "tax_expected_minor": 14025,
          "tax_ok": true,
          "total_expected_minor": 184025,
          "total_ok": true
        },
        "mismatches": [],
        "duplicates": [
          {
            "id": "X",
            "reasons": [
              "within_window",
              "same_number_normalized"
            ],
            "likely": true
          }
        ],
        "domain_errors": [],
        "hold_recommended": true,
        "scope_note": "Integer minor units only: fractional quantities and sub-minor-unit prices are refused, not rounded. One currency per invoice. One declared tax rate; no tax-jurisdiction logic."
      },
      "golden_hash": "89d711e7aa5fa6630c6eed0dbc3d8e144dc53ca7752e155bed74fe46d84160f8"
    },
    {
      "name": "F10-duplicate-same-total-within-14-days",
      "policy_parameters": {
        "currency": "USD",
        "invoice": {
          "invoice_number": "INV-0042",
          "issue_date": "2026-09-30",
          "vendor_id": "V-1",
          "po_number": "PO-7",
          "subtotal_minor": 170000,
          "tax_minor": 14025,
          "total_minor": 184025,
          "lines": [
            {
              "line": 1,
              "po_line": 1,
              "sku": "A-100",
              "qty": 10,
              "unit_price_minor": 12000,
              "amount_minor": 120000
            },
            {
              "line": 2,
              "po_line": 2,
              "sku": "B-200",
              "qty": 5,
              "unit_price_minor": 4000,
              "amount_minor": 20000
            },
            {
              "line": 3,
              "po_line": 3,
              "sku": "C-300",
              "qty": 2,
              "unit_price_minor": 15000,
              "amount_minor": 30000
            }
          ]
        },
        "purchase_order": {
          "po_number": "PO-7",
          "lines": [
            {
              "line": 1,
              "sku": "A-100",
              "qty": 10,
              "unit_price_minor": 12000
            },
            {
              "line": 2,
              "sku": "B-200",
              "qty": 5,
              "unit_price_minor": 4000
            },
            {
              "line": 3,
              "sku": "C-300",
              "qty": 2,
              "unit_price_minor": 15000
            }
          ]
        },
        "goods_receipt": {
          "receipt_id": "GR-3",
          "lines": [
            {
              "po_line": 1,
              "qty_received": 10
            },
            {
              "po_line": 2,
              "qty_received": 5
            },
            {
              "po_line": 3,
              "qty_received": 2
            }
          ]
        },
        "vendor_terms": {
          "price_tolerance_bp": 200,
          "tax_rate_bp": 825,
          "tax_rounding": "half_up"
        },
        "prior_invoices": [
          {
            "id": "Y",
            "vendor_id": "V-1",
            "invoice_number": "INV-777",
            "issue_date": "2026-09-25",
            "total_minor": 184025,
            "po_number": "PO-8"
          }
        ],
        "duplicate_window_days": 14
      },
      "output_payload": {
        "outcome": "match",
        "po_number": "PO-7",
        "receipt_id": "GR-3",
        "lines": [
          {
            "line": 1,
            "paired_po_line": 1,
            "qty": 10,
            "qty_ordered": 10,
            "qty_received": 10,
            "unit_price_minor": 12000,
            "po_unit_price_minor": 12000,
            "variance_bp": 0,
            "amount_ok": true,
            "verdict": "ok"
          },
          {
            "line": 2,
            "paired_po_line": 2,
            "qty": 5,
            "qty_ordered": 5,
            "qty_received": 5,
            "unit_price_minor": 4000,
            "po_unit_price_minor": 4000,
            "variance_bp": 0,
            "amount_ok": true,
            "verdict": "ok"
          },
          {
            "line": 3,
            "paired_po_line": 3,
            "qty": 2,
            "qty_ordered": 2,
            "qty_received": 2,
            "unit_price_minor": 15000,
            "po_unit_price_minor": 15000,
            "variance_bp": 0,
            "amount_ok": true,
            "verdict": "ok"
          }
        ],
        "totals": {
          "line_sum_minor": 170000,
          "subtotal_ok": true,
          "tax_expected_minor": 14025,
          "tax_ok": true,
          "total_expected_minor": 184025,
          "total_ok": true
        },
        "mismatches": [],
        "duplicates": [
          {
            "id": "Y",
            "reasons": [
              "same_total",
              "within_window"
            ],
            "likely": true
          }
        ],
        "domain_errors": [],
        "hold_recommended": true,
        "scope_note": "Integer minor units only: fractional quantities and sub-minor-unit prices are refused, not rounded. One currency per invoice. One declared tax rate; no tax-jurisdiction logic."
      },
      "golden_hash": "a0d775f2f3350e22491cf6a995c3d17f55e26d7d2b16a779b84166fc2261a784"
    },
    {
      "name": "F11-same-total-15-days-not-duplicate",
      "policy_parameters": {
        "currency": "USD",
        "invoice": {
          "invoice_number": "INV-0042",
          "issue_date": "2026-09-30",
          "vendor_id": "V-1",
          "po_number": "PO-7",
          "subtotal_minor": 170000,
          "tax_minor": 14025,
          "total_minor": 184025,
          "lines": [
            {
              "line": 1,
              "po_line": 1,
              "sku": "A-100",
              "qty": 10,
              "unit_price_minor": 12000,
              "amount_minor": 120000
            },
            {
              "line": 2,
              "po_line": 2,
              "sku": "B-200",
              "qty": 5,
              "unit_price_minor": 4000,
              "amount_minor": 20000
            },
            {
              "line": 3,
              "po_line": 3,
              "sku": "C-300",
              "qty": 2,
              "unit_price_minor": 15000,
              "amount_minor": 30000
            }
          ]
        },
        "purchase_order": {
          "po_number": "PO-7",
          "lines": [
            {
              "line": 1,
              "sku": "A-100",
              "qty": 10,
              "unit_price_minor": 12000
            },
            {
              "line": 2,
              "sku": "B-200",
              "qty": 5,
              "unit_price_minor": 4000
            },
            {
              "line": 3,
              "sku": "C-300",
              "qty": 2,
              "unit_price_minor": 15000
            }
          ]
        },
        "goods_receipt": {
          "receipt_id": "GR-3",
          "lines": [
            {
              "po_line": 1,
              "qty_received": 10
            },
            {
              "po_line": 2,
              "qty_received": 5
            },
            {
              "po_line": 3,
              "qty_received": 2
            }
          ]
        },
        "vendor_terms": {
          "price_tolerance_bp": 200,
          "tax_rate_bp": 825,
          "tax_rounding": "half_up"
        },
        "prior_invoices": [
          {
            "id": "Z",
            "vendor_id": "V-1",
            "invoice_number": "INV-888",
            "issue_date": "2026-09-15",
            "total_minor": 184025,
            "po_number": "PO-8"
          }
        ],
        "duplicate_window_days": 14
      },
      "output_payload": {
        "outcome": "match",
        "po_number": "PO-7",
        "receipt_id": "GR-3",
        "lines": [
          {
            "line": 1,
            "paired_po_line": 1,
            "qty": 10,
            "qty_ordered": 10,
            "qty_received": 10,
            "unit_price_minor": 12000,
            "po_unit_price_minor": 12000,
            "variance_bp": 0,
            "amount_ok": true,
            "verdict": "ok"
          },
          {
            "line": 2,
            "paired_po_line": 2,
            "qty": 5,
            "qty_ordered": 5,
            "qty_received": 5,
            "unit_price_minor": 4000,
            "po_unit_price_minor": 4000,
            "variance_bp": 0,
            "amount_ok": true,
            "verdict": "ok"
          },
          {
            "line": 3,
            "paired_po_line": 3,
            "qty": 2,
            "qty_ordered": 2,
            "qty_received": 2,
            "unit_price_minor": 15000,
            "po_unit_price_minor": 15000,
            "variance_bp": 0,
            "amount_ok": true,
            "verdict": "ok"
          }
        ],
        "totals": {
          "line_sum_minor": 170000,
          "subtotal_ok": true,
          "tax_expected_minor": 14025,
          "tax_ok": true,
          "total_expected_minor": 184025,
          "total_ok": true
        },
        "mismatches": [],
        "duplicates": [
          {
            "id": "Z",
            "reasons": [
              "same_total"
            ],
            "likely": false
          }
        ],
        "domain_errors": [],
        "hold_recommended": false,
        "scope_note": "Integer minor units only: fractional quantities and sub-minor-unit prices are refused, not rounded. One currency per invoice. One declared tax rate; no tax-jurisdiction logic."
      },
      "golden_hash": "a0d0ea479ef7431c3bbd274b67fa0fdecf93f850c943715e6971f9209e41e8ee"
    },
    {
      "name": "F12-po-unit-price-zero",
      "policy_parameters": {
        "currency": "USD",
        "invoice": {
          "invoice_number": "INV-0042",
          "issue_date": "2026-09-30",
          "vendor_id": "V-1",
          "po_number": "PO-9",
          "subtotal_minor": 10000,
          "tax_minor": 825,
          "total_minor": 10825,
          "lines": [
            {
              "line": 1,
              "po_line": 1,
              "sku": "Z-1",
              "qty": 3,
              "unit_price_minor": 0,
              "amount_minor": 0
            },
            {
              "line": 2,
              "po_line": 2,
              "sku": "Z-2",
              "qty": 2,
              "unit_price_minor": 5000,
              "amount_minor": 10000
            }
          ]
        },
        "purchase_order": {
          "po_number": "PO-9",
          "lines": [
            {
              "line": 1,
              "sku": "Z-1",
              "qty": 3,
              "unit_price_minor": 0
            },
            {
              "line": 2,
              "sku": "Z-2",
              "qty": 2,
              "unit_price_minor": 0
            }
          ]
        },
        "goods_receipt": {
          "receipt_id": "GR-9",
          "lines": [
            {
              "po_line": 1,
              "qty_received": 3
            },
            {
              "po_line": 2,
              "qty_received": 2
            }
          ]
        },
        "vendor_terms": {
          "price_tolerance_bp": 200,
          "tax_rate_bp": 825,
          "tax_rounding": "half_up"
        },
        "prior_invoices": [],
        "duplicate_window_days": 14
      },
      "output_payload": {
        "outcome": "mismatch",
        "po_number": "PO-9",
        "receipt_id": "GR-9",
        "lines": [
          {
            "line": 1,
            "paired_po_line": 1,
            "qty": 3,
            "qty_ordered": 3,
            "qty_received": 3,
            "unit_price_minor": 0,
            "po_unit_price_minor": 0,
            "variance_bp": 0,
            "amount_ok": true,
            "verdict": "ok"
          },
          {
            "line": 2,
            "paired_po_line": 2,
            "qty": 2,
            "qty_ordered": 2,
            "qty_received": 2,
            "unit_price_minor": 5000,
            "po_unit_price_minor": 0,
            "variance_bp": null,
            "amount_ok": true,
            "verdict": "price_over_tolerance"
          }
        ],
        "totals": {
          "line_sum_minor": 10000,
          "subtotal_ok": true,
          "tax_expected_minor": 825,
          "tax_ok": true,
          "total_expected_minor": 10825,
          "total_ok": true
        },
        "mismatches": [
          {
            "code": "LINE_PRICE_OVER_TOLERANCE",
            "line": 2,
            "text": "Line 2: purchase order unit price is zero and the invoiced unit price 5000 is not"
          }
        ],
        "duplicates": [],
        "domain_errors": [],
        "hold_recommended": true,
        "scope_note": "Integer minor units only: fractional quantities and sub-minor-unit prices are refused, not rounded. One currency per invoice. One declared tax rate; no tax-jurisdiction logic."
      },
      "golden_hash": "cbd63c78a12783ff056a29d1d35bff92da50e440992b5e9bc042323e91874d8d"
    },
    {
      "name": "F13-receipt-missing-two-way-flag",
      "policy_parameters": {
        "currency": "USD",
        "invoice": {
          "invoice_number": "INV-0042",
          "issue_date": "2026-09-30",
          "vendor_id": "V-1",
          "po_number": "PO-7",
          "subtotal_minor": 170000,
          "tax_minor": 14025,
          "total_minor": 184025,
          "lines": [
            {
              "line": 1,
              "po_line": 1,
              "sku": "A-100",
              "qty": 10,
              "unit_price_minor": 12000,
              "amount_minor": 120000
            },
            {
              "line": 2,
              "po_line": 2,
              "sku": "B-200",
              "qty": 5,
              "unit_price_minor": 4000,
              "amount_minor": 20000
            },
            {
              "line": 3,
              "po_line": 3,
              "sku": "C-300",
              "qty": 2,
              "unit_price_minor": 15000,
              "amount_minor": 30000
            }
          ]
        },
        "purchase_order": {
          "po_number": "PO-7",
          "lines": [
            {
              "line": 1,
              "sku": "A-100",
              "qty": 10,
              "unit_price_minor": 12000
            },
            {
              "line": 2,
              "sku": "B-200",
              "qty": 5,
              "unit_price_minor": 4000
            },
            {
              "line": 3,
              "sku": "C-300",
              "qty": 2,
              "unit_price_minor": 15000
            }
          ]
        },
        "vendor_terms": {
          "price_tolerance_bp": 200,
          "tax_rate_bp": 825,
          "tax_rounding": "half_up"
        },
        "prior_invoices": [],
        "duplicate_window_days": 14
      },
      "output_payload": {
        "outcome": "match",
        "po_number": "PO-7",
        "receipt_id": null,
        "lines": [
          {
            "line": 1,
            "paired_po_line": 1,
            "qty": 10,
            "qty_ordered": 10,
            "qty_received": null,
            "unit_price_minor": 12000,
            "po_unit_price_minor": 12000,
            "variance_bp": null,
            "amount_ok": true,
            "verdict": "receipt_missing"
          },
          {
            "line": 2,
            "paired_po_line": 2,
            "qty": 5,
            "qty_ordered": 5,
            "qty_received": null,
            "unit_price_minor": 4000,
            "po_unit_price_minor": 4000,
            "variance_bp": null,
            "amount_ok": true,
            "verdict": "receipt_missing"
          },
          {
            "line": 3,
            "paired_po_line": 3,
            "qty": 2,
            "qty_ordered": 2,
            "qty_received": null,
            "unit_price_minor": 15000,
            "po_unit_price_minor": 15000,
            "variance_bp": null,
            "amount_ok": true,
            "verdict": "receipt_missing"
          }
        ],
        "totals": {
          "line_sum_minor": 170000,
          "subtotal_ok": true,
          "tax_expected_minor": 14025,
          "tax_ok": true,
          "total_expected_minor": 184025,
          "total_ok": true
        },
        "mismatches": [],
        "duplicates": [],
        "domain_errors": [],
        "hold_recommended": false,
        "scope_note": "Integer minor units only: fractional quantities and sub-minor-unit prices are refused, not rounded. One currency per invoice. One declared tax rate; no tax-jurisdiction logic."
      },
      "golden_hash": "2f9b4eb30f88acf3b02b4444efec216d56d6275db58efbe2c5cb19ca84aee87b"
    },
    {
      "name": "F14-line-amount-mismatch",
      "policy_parameters": {
        "currency": "USD",
        "invoice": {
          "invoice_number": "INV-0042",
          "issue_date": "2026-09-30",
          "vendor_id": "V-1",
          "po_number": "PO-7",
          "subtotal_minor": 169000,
          "tax_minor": 13943,
          "total_minor": 182943,
          "lines": [
            {
              "line": 1,
              "po_line": 1,
              "sku": "A-100",
              "qty": 10,
              "unit_price_minor": 12000,
              "amount_minor": 119000
            },
            {
              "line": 2,
              "po_line": 2,
              "sku": "B-200",
              "qty": 5,
              "unit_price_minor": 4000,
              "amount_minor": 20000
            },
            {
              "line": 3,
              "po_line": 3,
              "sku": "C-300",
              "qty": 2,
              "unit_price_minor": 15000,
              "amount_minor": 30000
            }
          ]
        },
        "purchase_order": {
          "po_number": "PO-7",
          "lines": [
            {
              "line": 1,
              "sku": "A-100",
              "qty": 10,
              "unit_price_minor": 12000
            },
            {
              "line": 2,
              "sku": "B-200",
              "qty": 5,
              "unit_price_minor": 4000
            },
            {
              "line": 3,
              "sku": "C-300",
              "qty": 2,
              "unit_price_minor": 15000
            }
          ]
        },
        "goods_receipt": {
          "receipt_id": "GR-3",
          "lines": [
            {
              "po_line": 1,
              "qty_received": 10
            },
            {
              "po_line": 2,
              "qty_received": 5
            },
            {
              "po_line": 3,
              "qty_received": 2
            }
          ]
        },
        "vendor_terms": {
          "price_tolerance_bp": 200,
          "tax_rate_bp": 825,
          "tax_rounding": "half_up"
        },
        "prior_invoices": [],
        "duplicate_window_days": 14
      },
      "output_payload": {
        "outcome": "mismatch",
        "po_number": "PO-7",
        "receipt_id": "GR-3",
        "lines": [
          {
            "line": 1,
            "paired_po_line": 1,
            "qty": 10,
            "qty_ordered": 10,
            "qty_received": 10,
            "unit_price_minor": 12000,
            "po_unit_price_minor": 12000,
            "variance_bp": 0,
            "amount_ok": false,
            "verdict": "ok"
          },
          {
            "line": 2,
            "paired_po_line": 2,
            "qty": 5,
            "qty_ordered": 5,
            "qty_received": 5,
            "unit_price_minor": 4000,
            "po_unit_price_minor": 4000,
            "variance_bp": 0,
            "amount_ok": true,
            "verdict": "ok"
          },
          {
            "line": 3,
            "paired_po_line": 3,
            "qty": 2,
            "qty_ordered": 2,
            "qty_received": 2,
            "unit_price_minor": 15000,
            "po_unit_price_minor": 15000,
            "variance_bp": 0,
            "amount_ok": true,
            "verdict": "ok"
          }
        ],
        "totals": {
          "line_sum_minor": 169000,
          "subtotal_ok": true,
          "tax_expected_minor": 13943,
          "tax_ok": true,
          "total_expected_minor": 182943,
          "total_ok": true
        },
        "mismatches": [
          {
            "code": "LINE_AMOUNT_MISMATCH",
            "line": 1,
            "text": "Line 1: qty times unit price 120000 does not equal invoiced amount 119000"
          }
        ],
        "duplicates": [],
        "domain_errors": [],
        "hold_recommended": true,
        "scope_note": "Integer minor units only: fractional quantities and sub-minor-unit prices are refused, not rounded. One currency per invoice. One declared tax rate; no tax-jurisdiction logic."
      },
      "golden_hash": "1753f81d657b0ca35db6941c9b06a7dc95e8e780c05742071cf1101f0e344b19"
    },
    {
      "name": "F15-refusal-fractional-qty",
      "policy_parameters": {
        "currency": "USD",
        "invoice": {
          "invoice_number": "INV-0042",
          "issue_date": "2026-09-30",
          "vendor_id": "V-1",
          "po_number": "PO-7",
          "subtotal_minor": 170000,
          "tax_minor": 14025,
          "total_minor": 184025,
          "lines": [
            {
              "line": 1,
              "po_line": 1,
              "sku": "A-100",
              "qty": 2.5,
              "unit_price_minor": 12000,
              "amount_minor": 120000
            },
            {
              "line": 2,
              "po_line": 2,
              "sku": "B-200",
              "qty": 5,
              "unit_price_minor": 4000,
              "amount_minor": 20000
            },
            {
              "line": 3,
              "po_line": 3,
              "sku": "C-300",
              "qty": 2,
              "unit_price_minor": 15000,
              "amount_minor": 30000
            }
          ]
        },
        "purchase_order": {
          "po_number": "PO-7",
          "lines": [
            {
              "line": 1,
              "sku": "A-100",
              "qty": 10,
              "unit_price_minor": 12000
            },
            {
              "line": 2,
              "sku": "B-200",
              "qty": 5,
              "unit_price_minor": 4000
            },
            {
              "line": 3,
              "sku": "C-300",
              "qty": 2,
              "unit_price_minor": 15000
            }
          ]
        },
        "goods_receipt": {
          "receipt_id": "GR-3",
          "lines": [
            {
              "po_line": 1,
              "qty_received": 10
            },
            {
              "po_line": 2,
              "qty_received": 5
            },
            {
              "po_line": 3,
              "qty_received": 2
            }
          ]
        },
        "vendor_terms": {
          "price_tolerance_bp": 200,
          "tax_rate_bp": 825,
          "tax_rounding": "half_up"
        },
        "prior_invoices": [],
        "duplicate_window_days": 14
      },
      "output_payload": {
        "outcome": "refused",
        "refusal_reason": "REFUSED_FRACTIONAL_QTY",
        "po_number": "PO-7",
        "receipt_id": "GR-3",
        "lines": [],
        "totals": null,
        "mismatches": [],
        "duplicates": [],
        "domain_errors": [
          {
            "code": "REFUSED_FRACTIONAL_QTY",
            "text": "invoice line 1 quantity must be an integer greater than zero"
          }
        ],
        "hold_recommended": true,
        "scope_note": "Integer minor units only: fractional quantities and sub-minor-unit prices are refused, not rounded. One currency per invoice. One declared tax rate; no tax-jurisdiction logic."
      },
      "golden_hash": "fffee7f66848aec6899e633881750c618f8a13fc50c5c92d95a4106a0357ad89"
    }
  ]
}
