Песочница: TESSACORPORATION

Intent ID: 17

Назад
1) Загрузить файл и получить сырой OCR JSON
Сохраняем последний файл и сырой OCR, чтобы можно было повторно тестировать маппинг без перезагрузки.
Скачать последний файл (90724344.pdf)
2) Правила трансформации
Правила трансформации OCR-данных в целевую схему (включая валидацию).
Промпт LLM-подсказки
Используется кнопкой «Подсказать rules».
Сырой OCR JSON (Pass 1)
{
  "awb": "145-9981 7631",
  "items": [
    {
      "boxes": 1,
      "length": "70",
      "variety": "ALSTRO BICOLOR HOT PEPPER",
      "category": "Flowers",
      "quantity": 10,
      "box_number": "1",
      "plantation": "TESSA- P",
      "unit_price": 0.32,
      "box_marking": "QB ALSTRO",
      "total_price": 3.2
    },
    {
      "boxes": 1,
      "length": "70",
      "variety": "ALSTRO BICOLOUR CORSICA",
      "category": "Flowers",
      "quantity": 10,
      "box_number": "1",
      "plantation": "TESSA- P",
      "unit_price": 0.32,
      "box_marking": "QB ALSTRO",
      "total_price": 3.2
    },
    {
      "boxes": 1,
      "length": "70",
      "variety": "ALSTRO HOT PINK INTENZ DARK PINK",
      "category": "Flowers",
      "quantity": 10,
      "box_number": "1",
      "plantation": "TESSA- P",
      "unit_price": 0.32,
      "box_marking": "QB ALSTRO",
      "total_price": 3.2
    },
    {
      "boxes": 1,
      "length": "70",
      "variety": "ALSTRO HOT PINK SECRET",
      "category": "Flowers",
      "quantity": 10,
      "box_number": "1",
      "plantation": "TESSA- P",
      "unit_price": 0.32,
      "box_marking": "QB ALSTRO",
      "total_price": 3.2
    },
    {
      "boxes": 1,
      "length": "70",
      "variety": "ALSTRO LAVENDER ANTARIS",
      "category": "Flowers",
      "quantity": 10,
      "box_number": "1",
      "plantation": "TESSA- P",
      "unit_price": 0.32,
      "box_marking": "QB ALSTRO",
      "total_price": 3.2
    },
    {
      "boxes": 1,
      "length": "70",
      "variety": "ALSTRO LAVENDER GALAXY",
      "category": "Flowers",
      "quantity": 10,
      "box_number": "1",
      "plantation": "TESSA- P",
      "unit_price": 0.32,
      "box_marking": "QB ALSTRO",
      "total_price": 3.2
    },
    {
      "boxes": 1,
      "length": "70",
      "variety": "ALSTRO PEACH CANYON",
      "category": "Flowers",
      "quantity": 10,
      "box_number": "1",
      "plantation": "TESSA- P",
      "unit_price": 0.32,
      "box_marking": "QB ALSTRO",
      "total_price": 3.2
    },
    {
      "boxes": 1,
      "length": "70",
      "variety": "ALSTRO PINK ELEGANCE",
      "category": "Flowers",
      "quantity": 10,
      "box_number": "1",
      "plantation": "TESSA- P",
      "unit_price": 0.32,
      "box_marking": "QB ALSTRO",
      "total_price": 3.2
    },
    {
      "boxes": 1,
      "length": "70",
      "variety": "ALSTRO PINK PRIMADONNA",
      "category": "Flowers",
      "quantity": 10,
      "box_number": "1",
      "plantation": "TESSA- P",
      "unit_price": 0.32,
      "box_marking": "QB ALSTRO",
      "total_price": 3.2
    },
    {
      "boxes": 1,
      "length": "70",
      "variety": "ALSTRO PURPLE AARON",
      "category": "Flowers",
      "quantity": 10,
      "box_number": "1",
      "plantation": "TESSA- P",
      "unit_price": 0.32,
      "box_marking": "QB ALSTRO",
      "total_price": 3.2
    },
    {
      "boxes": 1,
      "length": "70",
      "variety": "ALSTRO PURPLE AMATISTA",
      "category": "Flowers",
      "quantity": 10,
      "box_number": "1",
      "plantation": "TESSA- P",
      "unit_price": 0.32,
      "box_marking": "QB ALSTRO",
      "total_price": 3.2
    },
    {
      "boxes": 1,
      "length": "70",
      "variety": "ALSTRO RED BAHIA",
      "category": "Flowers",
      "quantity": 10,
      "box_number": "1",
      "plantation": "TESSA- P",
      "unit_price": 0.32,
      "box_marking": "QB ALSTRO",
      "total_price": 3.2
    },
    {
      "boxes": 1,
      "length": "70",
      "variety": "ALSTRO RED RED QUEEN",
      "category": "Flowers",
      "quantity": 10,
      "box_number": "1",
      "plantation": "TESSA- P",
      "unit_price": 0.32,
      "box_marking": "QB ALSTRO",
      "total_price": 3.2
    },
    {
      "boxes": 1,
      "length": "70",
      "variety": "ALSTRO SNOW TIME",
      "category": "Flowers",
      "quantity": 10,
      "box_number": "1",
      "plantation": "TESSA- P",
      "unit_price": 0.32,
      "box_marking": "QB ALSTRO",
      "total_price": 3.2
    },
    {
      "boxes": 1,
      "length": "70",
      "variety": "ALSTRO YELLOW FLORIDA",
      "category": "Flowers",
      "quantity": 10,
      "box_number": "1",
      "plantation": "TESSA- P",
      "unit_price": 0.32,
      "box_marking": "QB ALSTRO",
      "total_price": 3.2
    }
  ],
  "country": "Kyrgyz Republic (Kyrgyzstan)",
  "summary": {
    "total_boxes": 1,
    "total_stems": 150,
    "total_amount": 48.0
  },
  "supplier": "TOO QAZAQ IMEX /SOCIEDAD DE RESPONSABILIDAD LIMITADA",
  "invoice_date": "",
  "invoice_number": "",
  "processing_report": {
    "notes": "Тип инвойса: составной (вариант 1). Обнаружена 1 физическая коробка со смешанными сортами. Раскрытие мультибокса не применялось. Обнаружены расхождения между рассчитанными и ожидаемыми итоговыми значениями (количество стеблей, общая сумма). Поля invoice_number и invoice_date оставлены пустыми в соответствии с правилами трансформации, несмотря на их наличие в исходных данных.",
    "status": "warning",
    "sum_boxes": 1,
    "sum_stems": 150,
    "sum_amount": 48.0,
    "items_count": 15,
    "discrepancies": [
      "Total amount mismatch: expected 320.00, calculated 48.00.",
      "Total stems mismatch: expected 700, calculated 150."
    ],
    "expected_boxes": 1,
    "expected_stems": 700,
    "expected_amount": 320.0
  }
}
Результат (Pass 2)

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