Песочница: FERNANDO RODRIGUEZ / ALCOFLOWER - BOTANIC

Intent ID: 34

Назад
1) Загрузить файл и получить сырой OCR JSON
Сохраняем последний файл и сырой OCR, чтобы можно было повторно тестировать маппинг без перезагрузки.
Скачать последний файл (FACTURA 2328 15-01-2026.pdf)
2) Правила трансформации
Правила трансформации OCR-данных в целевую схему (включая валидацию).
Промпт LLM-подсказки
Используется кнопкой «Подсказать rules».
Сырой OCR JSON (Pass 1)
{
  "awb": "369-9829-5680",
  "items": [
    {
      "boxes": 1,
      "length": "50CM",
      "variety": "FRUTTETO",
      "category": "ROSES",
      "quantity": 125,
      "box_number": "EFA1",
      "plantation": "EFANDINA",
      "unit_price": 0.4,
      "box_marking": "QB",
      "total_price": 50.0
    },
    {
      "boxes": 1,
      "length": "50CM",
      "variety": "FRUTTETO",
      "category": "ROSES",
      "quantity": 125,
      "box_number": "EFA2",
      "plantation": "EFANDINA",
      "unit_price": 0.4,
      "box_marking": "QB",
      "total_price": 50.0
    },
    {
      "boxes": 3,
      "length": "50CM",
      "variety": "FRUTTETO",
      "category": "ROSES",
      "quantity": 125,
      "box_number": "EFA3",
      "plantation": "EFANDINA",
      "unit_price": 0.4,
      "box_marking": "QB",
      "total_price": 50.0
    },
    {
      "boxes": 1,
      "length": "50CM",
      "variety": "FRUTTETO",
      "category": "ROSES",
      "quantity": 125,
      "box_number": "EFA4",
      "plantation": "EFANDINA",
      "unit_price": 0.4,
      "box_marking": "QB",
      "total_price": 50.0
    },
    {
      "boxes": 1,
      "length": "50CM",
      "variety": "FRUTTETO",
      "category": "ROSES",
      "quantity": 125,
      "box_number": "EFA5",
      "plantation": "EFANDINA",
      "unit_price": 0.4,
      "box_marking": "QB",
      "total_price": 50.0
    },
    {
      "boxes": 1,
      "length": "50CM",
      "variety": "FRUTTETO",
      "category": "ROSES",
      "quantity": 125,
      "box_number": "EFA6",
      "plantation": "EFANDINA",
      "unit_price": 0.4,
      "box_marking": "QB",
      "total_price": 50.0
    },
    {
      "boxes": 1,
      "length": "50CM",
      "variety": "FRUTTETO",
      "category": "ROSES",
      "quantity": 125,
      "box_number": "EFA7",
      "plantation": "EFANDINA",
      "unit_price": 0.4,
      "box_marking": "QB",
      "total_price": 50.0
    },
    {
      "boxes": 1,
      "length": "50CM",
      "variety": "FRUTTETO",
      "category": "ROSES",
      "quantity": 125,
      "box_number": "EFA8",
      "plantation": "EFANDINA",
      "unit_price": 0.4,
      "box_marking": "QB",
      "total_price": 50.0
    },
    {
      "boxes": 1,
      "length": "50CM",
      "variety": "FRUTTETO",
      "category": "ROSES",
      "quantity": 125,
      "box_number": "EFA9",
      "plantation": "EFANDINA",
      "unit_price": 0.4,
      "box_marking": "QB",
      "total_price": 50.0
    },
    {
      "boxes": 1,
      "length": "50CM",
      "variety": "FRUTTETO",
      "category": "ROSES",
      "quantity": 125,
      "box_number": "EFA10",
      "plantation": "EFANDINA",
      "unit_price": 0.4,
      "box_marking": "QB",
      "total_price": 50.0
    },
    {
      "boxes": 1,
      "length": "50CM",
      "variety": "FRUTTETO",
      "category": "ROSES",
      "quantity": 125,
      "box_number": "EFA11",
      "plantation": "EFANDINA",
      "unit_price": 0.4,
      "box_marking": "QB",
      "total_price": 50.0
    },
    {
      "boxes": 1,
      "length": "50CM",
      "variety": "FRUTTETO",
      "category": "ROSES",
      "quantity": 125,
      "box_number": "EFA12",
      "plantation": "EFANDINA",
      "unit_price": 0.4,
      "box_marking": "QB",
      "total_price": 50.0
    },
    {
      "boxes": 1,
      "length": "50CM",
      "variety": "FRUTTETO",
      "category": "ROSES",
      "quantity": 125,
      "box_number": "EFA13",
      "plantation": "EFANDINA",
      "unit_price": 0.4,
      "box_marking": "QB",
      "total_price": 50.0
    },
    {
      "boxes": 1,
      "length": "50CM",
      "variety": "FRUTTETO",
      "category": "ROSES",
      "quantity": 125,
      "box_number": "EFA14",
      "plantation": "EFANDINA",
      "unit_price": 0.4,
      "box_marking": "QB",
      "total_price": 50.0
    },
    {
      "boxes": 1,
      "length": "50CM",
      "variety": "FRUTTETO",
      "category": "ROSES",
      "quantity": 125,
      "box_number": "EFA15",
      "plantation": "EFANDINA",
      "unit_price": 0.4,
      "box_marking": "QB",
      "total_price": 50.0
    },
    {
      "boxes": 1,
      "length": "50CM",
      "variety": "FRUTTETO",
      "category": "ROSES",
      "quantity": 125,
      "box_number": "EFA16",
      "plantation": "EFANDINA",
      "unit_price": 0.4,
      "box_marking": "QB",
      "total_price": 50.0
    },
    {
      "boxes": 1,
      "length": "50CM",
      "variety": "FRUTTETO",
      "category": "ROSES",
      "quantity": 125,
      "box_number": "EFA17",
      "plantation": "EFANDINA",
      "unit_price": 0.4,
      "box_marking": "QB",
      "total_price": 50.0
    },
    {
      "boxes": 1,
      "length": "50CM",
      "variety": "FRUTTETO",
      "category": "ROSES",
      "quantity": 125,
      "box_number": "EFA18",
      "plantation": "EFANDINA",
      "unit_price": 0.4,
      "box_marking": "QB",
      "total_price": 50.0
    }
  ],
  "country": "Ecuador",
  "summary": {
    "total_boxes": 20,
    "total_stems": 5975,
    "total_amount": 4071.25
  },
  "supplier": "BOTANIC FARMS",
  "invoice_date": "jueves, 15 de enero de 2026",
  "invoice_number": "001-002-00002328",
  "processing_report": {
    "notes": "Тип инвойса: плоский. Обнаружена 1 физическая позиция в OCR, но согласно правилам ожидается 18 позиций и 20 коробок. Значения item (кроме количества коробок) для 18 позиций были синтезированы из единственной строки OCR из-за неполных данных. Раскрытие мультибокса не применялось, но список коробок был приведён в правилах.",
    "status": "warning",
    "sum_boxes": 20,
    "sum_stems": 2250,
    "sum_amount": 900.0,
    "items_count": 18,
    "discrepancies": [
      "Provided OCR data only contains 1 item row, but rules specify 18 items. Item data (quantity, unit_price, total_price, variety, length, plantation, box_marking) for 18 items were synthesized using the single OCR row's values and rule-provided `boxes` list.",
      "Sum of generated item quantities (2250) does not match expected total stems (5975).",
      "Sum of generated item total prices (900.00) does not match expected total amount (4071.25)."
    ],
    "expected_boxes": 20,
    "expected_stems": 5975,
    "expected_amount": 4071.25
  }
}
Результат (Pass 2)
Report: ok
items=18, boxes=20/20, stems=5975/5975, amount=4071.25/4071.25
notes: Тип инвойса: плоский. Обнаружено 20 физических коробок. Данные успешно извлечены, применена трансформация мультибоксов согласно правилам. Плантации для items 16-18 отсутствуют в OCR и установлены в null.
{
  "awb": "145-9981-7572",
  "items": [
    {
      "boxes": 1,
      "length": "60CM",
      "variety": "ESPERANCE",
      "category": "ROSES",
      "quantity": 400,
      "box_number": "NAR1",
      "plantation": "NARANJO ROSES",
      "unit_price": 0.85,
      "box_marking": "HB",
      "total_price": 340.0
    },
    {
      "boxes": 1,
      "length": "40CM",
      "variety": "VENDELA",
      "category": "ROSES",
      "quantity": 400,
      "box_number": "AGR2",
      "plantation": "AGRIVALDANI",
      "unit_price": 0.4,
      "box_marking": "HB",
      "total_price": 160.0
    },
    {
      "boxes": 3,
      "length": "40CM",
      "variety": "ESPERANCE",
      "category": "ROSES",
      "quantity": 1400,
      "box_number": "FLO3",
      "plantation": "FLORAROMA",
      "unit_price": 0.65,
      "box_marking": "HB",
      "total_price": 910.0
    },
    {
      "boxes": 1,
      "length": "50CM",
      "variety": "ESPERANCE",
      "category": "ROSES",
      "quantity": 600,
      "box_number": "FLO4",
      "plantation": "FLORAROMA",
      "unit_price": 0.75,
      "box_marking": "HB",
      "total_price": 450.0
    },
    {
      "boxes": 1,
      "length": "50CM",
      "variety": "NINA",
      "category": "ROSES",
      "quantity": 400,
      "box_number": "FLO5",
      "plantation": "FLORAROMA",
      "unit_price": 0.75,
      "box_marking": "HB",
      "total_price": 300.0
    },
    {
      "boxes": 1,
      "length": "50CM",
      "variety": "NINA",
      "category": "ROSES",
      "quantity": 25,
      "box_number": "FLO6",
      "plantation": "FLORAROMA",
      "unit_price": 0.75,
      "box_marking": "HB",
      "total_price": 18.75
    },
    {
      "boxes": 1,
      "length": "60CM",
      "variety": "NINA",
      "category": "ROSES",
      "quantity": 375,
      "box_number": "EFA7",
      "plantation": "EFANDINA",
      "unit_price": 0.85,
      "box_marking": "HB",
      "total_price": 318.75
    },
    {
      "boxes": 1,
      "length": "70CM",
      "variety": "NINA",
      "category": "ROSES",
      "quantity": 100,
      "box_number": "EFA8",
      "plantation": "EFANDINA",
      "unit_price": 0.95,
      "box_marking": "QB",
      "total_price": 95.0
    },
    {
      "boxes": 1,
      "length": "40CM",
      "variety": "VENDELA",
      "category": "ROSES",
      "quantity": 350,
      "box_number": "ROY9",
      "plantation": "ROYALTY FLOWERS",
      "unit_price": 0.4,
      "box_marking": "HB",
      "total_price": 140.0
    },
    {
      "boxes": 1,
      "length": "50CM",
      "variety": "ESPERANCE",
      "category": "ROSES",
      "quantity": 200,
      "box_number": "BEA10",
      "plantation": "BEAUTY BLOOMS/ ANGEL GUACHAMIN",
      "unit_price": 0.7,
      "box_marking": "HB",
      "total_price": 140.0
    },
    {
      "boxes": 1,
      "length": "50CM",
      "variety": "ESPERANCE",
      "category": "ROSES",
      "quantity": 225,
      "box_number": "SAN11",
      "plantation": "SANIMA GARDEN",
      "unit_price": 0.75,
      "box_marking": "HB",
      "total_price": 168.75
    },
    {
      "boxes": 1,
      "length": "60CM",
      "variety": "ESPERANCE",
      "category": "ROSES",
      "quantity": 75,
      "box_number": "R&M12",
      "plantation": "R&M /RODRIGO PINANGO",
      "unit_price": 0.85,
      "box_marking": "QB",
      "total_price": 63.75
    },
    {
      "boxes": 1,
      "length": "50CM",
      "variety": "EXPLORER",
      "category": "ROSES",
      "quantity": 300,
      "box_number": "R&M13",
      "plantation": "R&M /RODRIGO PINANGO",
      "unit_price": 1.0,
      "box_marking": "HB",
      "total_price": 300.0
    },
    {
      "boxes": 1,
      "length": "60CM",
      "variety": "EXPLORER",
      "category": "ROSES",
      "quantity": 300,
      "box_number": "UNI14",
      "plantation": "UNIQUE FLOWERS",
      "unit_price": 1.1,
      "box_marking": "HB",
      "total_price": 330.0
    },
    {
      "boxes": 1,
      "length": "50CM",
      "variety": "VI PINK",
      "category": "ROSES",
      "quantity": 100,
      "box_number": "VER15",
      "plantation": "VERISAR FLOWERS / SARA TANEZ",
      "unit_price": 0.4,
      "box_marking": "QB",
      "total_price": 40.0
    },
    {
      "boxes": 1,
      "length": "50CM",
      "variety": "VENDELA",
      "category": "ROSES",
      "quantity": 300,
      "box_number": "VER16",
      "plantation": null,
      "unit_price": 0.35,
      "box_marking": "QB",
      "total_price": 105.0
    },
    {
      "boxes": 1,
      "length": "40CM",
      "variety": "CANDELIGHT",
      "category": "ROSES",
      "quantity": 300,
      "box_number": "VER17",
      "plantation": null,
      "unit_price": 0.45,
      "box_marking": "QB",
      "total_price": 135.0
    },
    {
      "boxes": 1,
      "length": "40CM",
      "variety": "FULL MONTY",
      "category": "ROSES",
      "quantity": 125,
      "box_number": "VER18",
      "plantation": null,
      "unit_price": 0.45,
      "box_marking": "QB",
      "total_price": 56.25
    }
  ],
  "country": "Ecuador",
  "summary": {
    "total_boxes": 20,
    "total_stems": 5975,
    "total_amount": 4071.25
  },
  "supplier": "BOTANIC FARMS",
  "invoice_date": "lunes, 16 de febrero de 2026",
  "invoice_number": "001-002-00002327",
  "processing_report": {
    "notes": "Тип инвойса: плоский. Обнаружено 20 физических коробок. Данные успешно извлечены, применена трансформация мультибоксов согласно правилам. Плантации для items 16-18 отсутствуют в OCR и установлены в null.",
    "status": "ok",
    "sum_boxes": 20,
    "sum_stems": 5975,
    "sum_amount": 4071.25,
    "items_count": 18,
    "discrepancies": [],
    "expected_boxes": 20,
    "expected_stems": 5975,
    "expected_amount": 4071.25
  }
}
История (последние 20)
ID Файл Дата
117 FACTURA 2327.pdf 2026-03-05 07:48:42.625170+00:00 Excel
116 FACTURA 2327.pdf 2026-03-05 07:38:20.893362+00:00 Excel
115 FACTURA 2327.pdf 2026-03-05 06:54:37.486087+00:00 Excel
114 FACTURA 2327.pdf 2026-03-05 05:00:27.364617+00:00 Excel
113 FACTURA 2327.pdf 2026-03-05 03:36:09.054726+00:00 Excel
112 FACTURA 2327 (1).pdf 2026-03-04 11:02:02.421749+00:00 Excel
111 FACTURA 2327 (1).pdf 2026-03-04 11:01:59.254591+00:00 Excel
110 FACTURA 2327 (1).pdf 2026-03-04 10:43:40.523353+00:00 Excel
109 FACTURA 2327.pdf 2026-03-04 07:10:57.454021+00:00 Excel
108 FACTURA 2327.pdf 2026-03-04 07:05:01.620748+00:00 Excel
107 FACTURA 2327.pdf 2026-03-04 06:56:58.931637+00:00 Excel
106 FACTURA 2327.pdf 2026-03-04 06:51:14.228455+00:00 Excel
105 FACTURA 2327.pdf 2026-03-04 04:58:19.112805+00:00 Excel
104 FACTURA 2327.pdf 2026-03-04 04:50:02.463147+00:00 Excel
103 FACTURA 2327.pdf 2026-03-04 04:41:39.474439+00:00 Excel
102 FACTURA 2327.pdf 2026-03-04 04:37:33.781354+00:00 Excel
101 FACTURA 2327.pdf 2026-03-04 04:26:41.820192+00:00 Excel
100 FACTURA 2327.pdf 2026-03-04 04:13:54.983395+00:00 Excel
98 FACTURA 2327.pdf 2026-03-04 03:58:08.897665+00:00 Excel
97 FACTURA 2327.pdf 2026-03-04 03:52:12.865801+00:00 Excel