Песочница: TESSACORPORATION

Intent ID: 17

Назад
1) Загрузить файл и получить сырой OCR JSON
Сохраняем последний файл и сырой OCR, чтобы можно было повторно тестировать маппинг без перезагрузки.
Скачать последний файл (90727657.pdf)
2) Правила трансформации
Правила трансформации OCR-данных в целевую схему (включая валидацию).
Промпт LLM-подсказки
Используется кнопкой «Подсказать rules».
Сырой OCR JSON (Pass 1)
{
  "awb": "145-9981 7664",
  "items": [
    {
      "boxes": 1,
      "length": "60",
      "variety": "MONDIAL",
      "category": "Flowers",
      "quantity": 300,
      "box_number": "1",
      "plantation": "TESSA- 1",
      "unit_price": 0.45,
      "box_marking": "HB XL 2",
      "total_price": 135.0
    },
    {
      "boxes": 1,
      "length": "50",
      "variety": "LOLA",
      "category": "Flowers",
      "quantity": 350,
      "box_number": "1",
      "plantation": "TESSA- 1",
      "unit_price": 0.5,
      "box_marking": "HB XXL 2",
      "total_price": 175.0
    },
    {
      "boxes": 1,
      "length": "60",
      "variety": "EXPLORER",
      "category": "Flowers",
      "quantity": 350,
      "box_number": "1",
      "plantation": "TESSA- 1",
      "unit_price": 0.5,
      "box_marking": "HB XL 1",
      "total_price": 175.0
    },
    {
      "boxes": 1,
      "length": "60",
      "variety": "EXPLORER",
      "category": "Flowers",
      "quantity": 350,
      "box_number": "1",
      "plantation": "TESSA- 1",
      "unit_price": 0.5,
      "box_marking": "HB XL 1",
      "total_price": 175.0
    },
    {
      "boxes": 1,
      "length": "60",
      "variety": "EXPLORER",
      "category": "Flowers",
      "quantity": 350,
      "box_number": "1",
      "plantation": "TESSA- 1",
      "unit_price": 0.5,
      "box_marking": "HB XL 1",
      "total_price": 175.0
    },
    {
      "boxes": 1,
      "length": "60",
      "variety": "MONDIAL",
      "category": "Flowers",
      "quantity": 300,
      "box_number": "1",
      "plantation": "TESSA- 1",
      "unit_price": 0.45,
      "box_marking": "HB XL 2",
      "total_price": 135.0
    },
    {
      "boxes": 1,
      "length": "60",
      "variety": "EXPLORER",
      "category": "Flowers",
      "quantity": 350,
      "box_number": "1",
      "plantation": "TESSA- 1",
      "unit_price": 0.5,
      "box_marking": "HB XL 1",
      "total_price": 175.0
    },
    {
      "boxes": 1,
      "length": "60",
      "variety": "EXPLORER",
      "category": "Flowers",
      "quantity": 350,
      "box_number": "1",
      "plantation": "TESSA- 1",
      "unit_price": 0.5,
      "box_marking": "HB XL 1",
      "total_price": 175.0
    },
    {
      "boxes": 1,
      "length": "60",
      "variety": "EXPLORER",
      "category": "Flowers",
      "quantity": 350,
      "box_number": "1",
      "plantation": "TESSA- 1",
      "unit_price": 0.5,
      "box_marking": "HB XL 1",
      "total_price": 175.0
    },
    {
      "boxes": 1,
      "length": "50",
      "variety": "CANDLELIGHT",
      "category": "Flowers",
      "quantity": 125,
      "box_number": "1",
      "plantation": "TESSA- 1",
      "unit_price": 0.6,
      "box_marking": "HB XXL 2",
      "total_price": 75.0
    },
    {
      "boxes": 1,
      "length": "60",
      "variety": "CANDLELIGHT",
      "category": "Flowers",
      "quantity": 175,
      "box_number": "1",
      "plantation": "TESSA- 1",
      "unit_price": 0.7,
      "box_marking": "HB XXL 2",
      "total_price": 122.5
    },
    {
      "boxes": 1,
      "length": "60",
      "variety": "MONDIAL",
      "category": "Flowers",
      "quantity": 300,
      "box_number": "1",
      "plantation": "TESSA- E2",
      "unit_price": 0.45,
      "box_marking": "HB XL 2",
      "total_price": 135.0
    },
    {
      "boxes": 1,
      "length": "50",
      "variety": "PANDORA",
      "category": "Flowers",
      "quantity": 100,
      "box_number": "1",
      "plantation": "TESSA- E2",
      "unit_price": 0.4,
      "box_marking": "QB 2",
      "total_price": 40.0
    },
    {
      "boxes": 1,
      "length": "50",
      "variety": "PANDORA",
      "category": "Flowers",
      "quantity": 100,
      "box_number": "1",
      "plantation": "TESSA- E2",
      "unit_price": 0.4,
      "box_marking": "QB 2",
      "total_price": 40.0
    },
    {
      "boxes": 1,
      "length": "50",
      "variety": "QUEEN'S CROWN",
      "category": "Flowers",
      "quantity": 200,
      "box_number": "1",
      "plantation": "TESSA- E2",
      "unit_price": 0.6,
      "box_marking": "HB",
      "total_price": 120.0
    },
    {
      "boxes": 1,
      "length": "60",
      "variety": "MONDIAL",
      "category": "Flowers",
      "quantity": 300,
      "box_number": "1",
      "plantation": "TESSA- F",
      "unit_price": 0.45,
      "box_marking": "HB XL 2",
      "total_price": 135.0
    },
    {
      "boxes": 1,
      "length": "50",
      "variety": "CANDLELIGHT",
      "category": "Flowers",
      "quantity": 50,
      "box_number": "1",
      "plantation": "TESSA- P",
      "unit_price": 0.6,
      "box_marking": "HB XL 2",
      "total_price": 30.0
    },
    {
      "boxes": 1,
      "length": "60",
      "variety": "CANDLELIGHT",
      "category": "Flowers",
      "quantity": 150,
      "box_number": "1",
      "plantation": "TESSA- P",
      "unit_price": 0.7,
      "box_marking": "HB XL 2",
      "total_price": 105.0
    },
    {
      "boxes": 1,
      "length": "50",
      "variety": "CANDLELIGHT",
      "category": "Flowers",
      "quantity": 50,
      "box_number": "1",
      "plantation": "TESSA- P",
      "unit_price": 0.6,
      "box_marking": "HB XL 2",
      "total_price": 30.0
    },
    {
      "boxes": 1,
      "length": "60",
      "variety": "CANDLELIGHT",
      "category": "Flowers",
      "quantity": 150,
      "box_number": "1",
      "plantation": "TESSA- P",
      "unit_price": 0.7,
      "box_marking": "HB XL 2",
      "total_price": 105.0
    },
    {
      "boxes": 1,
      "length": "CANDLELIGHT",
      "variety": "S",
      "category": "Flowers",
      "quantity": 6,
      "box_number": "1",
      "plantation": "1",
      "unit_price": 150.0,
      "box_marking": null,
      "total_price": 0.6
    },
    {
      "boxes": 1,
      "length": "60",
      "variety": "CANDLELIGHT",
      "category": "Flowers",
      "quantity": 4,
      "box_number": "1",
      "plantation": "1",
      "unit_price": 100.0,
      "box_marking": null,
      "total_price": 0.7
    },
    {
      "boxes": 1,
      "length": "CANDLELIGHT",
      "variety": "TESSA- S",
      "category": "Flowers",
      "quantity": 6,
      "box_number": "1",
      "plantation": "HB XXL 1",
      "unit_price": 150.0,
      "box_marking": null,
      "total_price": 0.6
    },
    {
      "boxes": 1,
      "length": "60",
      "variety": "CANDLELIGHT",
      "category": "Flowers",
      "quantity": 4,
      "box_number": "1",
      "plantation": "HB XXL 1",
      "unit_price": 100.0,
      "box_marking": null,
      "total_price": 0.7
    }
  ],
  "country": "Kyrgyz Republic (Kyrgyzstan)",
  "summary": {
    "total_boxes": 18,
    "total_stems": 5250,
    "total_amount": 2752.5
  },
  "supplier": "TOO QAZAQ IMEX /SOCIEDAD DE RESPONSABILIDAD LIMITADA",
  "invoice_date": "",
  "invoice_number": "",
  "processing_report": {
    "notes": "Invoice type A (composite boxes). 18 physical boxes detected (based on header rows count). Multi-box expansion not applied. Data quality issues detected in last few items regarding column alignment for variety, length, unit_price and total_price.",
    "status": "warning",
    "sum_boxes": 24,
    "sum_stems": 5250,
    "sum_amount": 2752.5,
    "items_count": 24,
    "discrepancies": [
      "Item at index 20: 'length' value 'CANDLELIGHT' is not numeric as expected. It appears shifted or data quality issue.",
      "Item at index 20: 'unit_price' value '150' and 'total_price' value '0.6' are likely misaligned/shifted. Original: col 8=150, col 9=$0.60.",
      "Item at index 21: 'length' value '60' is not numeric as expected for 'CANDLELIGHT' variety. Data might be shifted.",
      "Item at index 21: 'unit_price' value '100' and 'total_price' value '0.7' are likely misaligned/shifted. Original: col 8=100, col 9=$0.70.",
      "Item at index 22: 'length' value 'CANDLELIGHT' is not numeric as expected. It appears shifted or data quality issue.",
      "Item at index 22: 'unit_price' value '150' and 'total_price' value '0.6' are likely misaligned/shifted. Original: col 8=150, col 9=$0.60.",
      "Item at index 23: 'length' value '60' is not numeric as expected for 'CANDLELIGHT' variety. Data might be shifted.",
      "Item at index 23: 'unit_price' value '100' and 'total_price' value '0.7' are likely misaligned/shifted. Original: col 8=100, col 9=$0.70.",
      "Summary: total_boxes calculated as 18 (number of header rows) might be different from physical boxes '19' if available in OCR (col 0 of TOTALS row)."
    ],
    "expected_boxes": null,
    "expected_stems": 5250,
    "expected_amount": 2752.5
  }
}
Результат (Pass 2)

  
История (последние 20)
ID Файл Дата