Песочница: GUAISA / SUNRITE FARMS

Intent ID: 25

Назад
1) Загрузить файл и получить сырой OCR JSON
Сохраняем последний файл и сырой OCR, чтобы можно было повторно тестировать маппинг без перезагрузки.
Скачать последний файл (0263248.PDF)
2) Правила трансформации
Правила трансформации OCR-данных в целевую схему (включая валидацию).
Промпт LLM-подсказки
Используется кнопкой «Подсказать rules».
Сырой OCR JSON (Pass 1)
{
  "awb": "145-99817701/PC 604001812",
  "items": [
    {
      "boxes": 1,
      "length": "40",
      "variety": "BICO LOR PINK ESPERANCE",
      "category": "ROSE",
      "quantity": 500,
      "box_number": "1-1",
      "plantation": "GUANQUILQUI AGROPECUARIA INDUSTRIAL S.A",
      "unit_price": 0.22,
      "box_marking": "MECH TA OOC",
      "total_price": 110.0
    },
    {
      "boxes": 1,
      "length": "50",
      "variety": "BICO LOR PINK ESPERANCE",
      "category": "ROSE",
      "quantity": 500,
      "box_number": "1-2",
      "plantation": "GUANQUILQUI AGROPECUARIA INDUSTRIAL S.A",
      "unit_price": 0.32,
      "box_marking": "MECH TA OOC",
      "total_price": 160.0
    },
    {
      "boxes": 1,
      "length": "50",
      "variety": "HOT PINK GOTCHA",
      "category": "ROSE",
      "quantity": 400,
      "box_number": "1-3",
      "plantation": "GUANQUILQUI AGROPECUARIA INDUSTRIAL S.A",
      "unit_price": 0.35,
      "box_marking": "BUKETO PT",
      "total_price": 140.0
    },
    {
      "boxes": 1,
      "length": "50",
      "variety": "CREAM VENDELA",
      "category": "ROSE",
      "quantity": 500,
      "box_number": "2-1",
      "plantation": "GUANQUILQUI AGROPECUARIA INDUSTRIAL S.A",
      "unit_price": 0.2,
      "box_marking": "MECH TA OOC",
      "total_price": 100.0
    },
    {
      "boxes": 1,
      "length": "50",
      "variety": "CREAM VENDELA",
      "category": "ROSE",
      "quantity": 500,
      "box_number": "2-2",
      "plantation": "GUANQUILQUI AGROPECUARIA INDUSTRIAL S.A",
      "unit_price": 0.2,
      "box_marking": "MECH TA OOC",
      "total_price": 100.0
    },
    {
      "boxes": 1,
      "length": "50",
      "variety": "CREAM VENDELA",
      "category": "ROSE",
      "quantity": 550,
      "box_number": "2-3",
      "plantation": "GUANQUILQUI AGROPECUARIA INDUSTRIAL S.A",
      "unit_price": 0.2,
      "box_marking": "MECH TA OOC",
      "total_price": 110.0
    },
    {
      "boxes": 1,
      "length": "50",
      "variety": "CREAM VENDELA",
      "category": "ROSE",
      "quantity": 550,
      "box_number": "2-4",
      "plantation": "GUANQUILQUI AGROPECUARIA INDUSTRIAL S.A",
      "unit_price": 0.2,
      "box_marking": "MECH TA OOC",
      "total_price": 110.0
    }
  ],
  "country": null,
  "summary": {
    "total_boxes": 7,
    "total_stems": 3500,
    "total_amount": 830.0
  },
  "supplier": "GUANQUILQUI AGROPECUARIA INDUSTRIAL S.A",
  "invoice_date": "04/02/2026",
  "invoice_number": "0263248",
  "processing_report": {
    "notes": "Тип инвойса: плоский. Обнаружено 7 физических коробок. Данные успешно извлечены. Применено раскрытие мультибокса для 2 позиций, каждая из которых содержала по 2 физические коробки. Общая сумма стеблей и коробок, а также сумма по позициям, соответствуют сводным данным.",
    "status": "ok",
    "sum_boxes": 7,
    "sum_stems": 3500,
    "sum_amount": 830.0,
    "items_count": 7,
    "discrepancies": [],
    "expected_boxes": 7,
    "expected_stems": 3500,
    "expected_amount": 830.0
  }
}
Результат (Pass 2)
Report: ok
items=7, boxes=7/7.0, stems=3500.0/3500.0, amount=830.0/830.0
notes: Тип инвойса: гибридный (данные объединены в одной строке OCR, но логически это плоский инвойс), обнаружено 7 физических коробок, применялось раскрытие мультибокса для 2 позиций, генерированы уникальные box_number для дубликатов.
{
  "awb": "PACIFIC AIR",
  "items": [
    {
      "boxes": 1,
      "length": "50",
      "variety": "HOT PINK GOTCHA",
      "category": "ROSE",
      "quantity": 400.0,
      "box_number": "1 H",
      "plantation": "MECHTA OOO.-RU",
      "unit_price": 0.35,
      "box_marking": "BUKETOPT",
      "total_price": 140.0
    },
    {
      "boxes": 1,
      "length": "50",
      "variety": "HOT PINK GOTCHA",
      "category": "ROSE",
      "quantity": 500.0,
      "box_number": "1 V-1",
      "plantation": "MECHTA OOO.-RU",
      "unit_price": 0.32,
      "box_marking": "BUKETOPT",
      "total_price": 160.0
    },
    {
      "boxes": 1,
      "length": null,
      "variety": "LIGHT PINK NENA",
      "category": "ROSE",
      "quantity": 500.0,
      "box_number": "1 V-2",
      "plantation": "MECHTA OOO.-RU",
      "unit_price": 0.22,
      "box_marking": "BUKETOPT",
      "total_price": 110.0
    },
    {
      "boxes": 1,
      "length": "50",
      "variety": "CREAM VENDELA",
      "category": "ROSE",
      "quantity": 500.0,
      "box_number": "2 V-1",
      "plantation": "MECHTA OOO.-RU",
      "unit_price": 0.2,
      "box_marking": "BUKETOPT",
      "total_price": 100.0
    },
    {
      "boxes": 1,
      "length": "50",
      "variety": "CREAM VENDELA",
      "category": "ROSE",
      "quantity": 500.0,
      "box_number": "2 V-2",
      "plantation": "MECHTA OOO.-RU",
      "unit_price": 0.2,
      "box_marking": "BUKETOPT",
      "total_price": 100.0
    },
    {
      "boxes": 1,
      "length": "50",
      "variety": "CREAM VENDELA",
      "category": "ROSE",
      "quantity": 550.0,
      "box_number": "2 B-1",
      "plantation": "MECHTA OOO.-RU",
      "unit_price": 0.2,
      "box_marking": "BUKETOPT",
      "total_price": 110.0
    },
    {
      "boxes": 1,
      "length": "50",
      "variety": "CREAM VENDELA",
      "category": "ROSE",
      "quantity": 550.0,
      "box_number": "2 B-2",
      "plantation": "MECHTA OOO.-RU",
      "unit_price": 0.2,
      "box_marking": "BUKETOPT",
      "total_price": 110.0
    }
  ],
  "country": "Republic of Kazakhstan",
  "summary": {
    "total_boxes": 7.0,
    "total_stems": 3500.0,
    "total_amount": 830.0
  },
  "supplier": "MECHTA OOO.-RU",
  "invoice_date": "02/19/2026",
  "invoice_number": "0261178",
  "processing_report": {
    "notes": "Тип инвойса: гибридный (данные объединены в одной строке OCR, но логически это плоский инвойс), обнаружено 7 физических коробок, применялось раскрытие мультибокса для 2 позиций, генерированы уникальные box_number для дубликатов.",
    "status": "ok",
    "sum_boxes": 7,
    "sum_stems": 3500.0,
    "sum_amount": 830.0,
    "items_count": 7,
    "discrepancies": [],
    "expected_boxes": 7.0,
    "expected_stems": 3500.0,
    "expected_amount": 830.0
  }
}
История (последние 20)
ID Файл Дата
24 0261178.PDF 2026-02-23 17:08:43.771770+00:00 Excel