Blog Document AI No. 12
Checking extracted order data before it reaches your ERP
Any system that reads documents will sometimes read one wrongly. OCR misreads characters; templates pick up the wrong box after a layout change; AI models occasionally put a value in the wrong field. The question is not whether errors happen but whether you catch them before an order is shipped.
The good news is that purchase orders carry a lot of internal evidence about whether they were read correctly.
Arithmetic: the order checks itself
An order states the same information more than once:
- Each line's amount should equal quantity times unit price, less any discount.
- The line amounts should add up to the subtotal.
- The subtotal, less any discount, plus carriage and tax, should equal the total.
A single misread digit in a quantity or a price almost always breaks one of these. VioPO runs all three and returns them in checks, each with a plain description of what was compared, such as "The line amounts add up to 1357.85; the subtotal printed is 1357.85."
These checks catch reading errors, but also mistakes on the order itself. A customer whose order does not add up should hear about it before you ship.
What arithmetic cannot catch
Some errors leave the sums intact:
- Addresses. Delivery and invoice addresses swapped, or a line from one box read into the other.
- Part numbers. A misread character in a code:
NJ-1104read asNJ-1184. - Descriptions and references. Usually harmless, but the PO number itself is a reference, and it must be exact.
These are caught by matching against what you already know.
Matching: check against your own records
- Customer. Does the buyer's VAT number, company number or account reference match a customer you have?
- Delivery address. Is it one of that customer's known sites? A new delivery address is worth a person's attention for its own sake, as it is also a common feature of order fraud.
- Products. Does every part number match a product, directly or through the customer's cross-reference?
- Prices. Are they within your tolerance of your price list or the quoted price?
- PO number. Have you already received an order with this number from this customer? A duplicate may be a resend or a revision.
A simple decision rule
Post automatically only when:
- every arithmetic check passed;
- there are no warnings;
- customer, delivery address and every product matched;
- prices are within tolerance;
- the PO number is new for this customer.
Everything else goes to a person, with the reason it was held. Start strict. As you see which held orders were actually fine, you can relax the rules that are too cautious for your business.
Measure it
For the first few weeks, have a person check a sample of the orders that passed automatically, as well as the ones that were held. That tells you two things: how often something wrong got through, and how much time the automation is saving. Both numbers are worth having before you widen it.
You can see VioPO's checks on real output in the example output, and read how each one works in the docs.