Hacker News new | ask | show | jobs
by pilgrim0 15 days ago
Extracting structured data from PDFs is something people have been doing forever, way before LLMs, there are state of the art OCR tools out there you can use as a lib, it’s hardly something that justify using a LLM
3 comments

The problem is, it's not very well structured.

The position of (for instance) the check # on a physical check varies quite widely, as can date position and format, and a fair number of them are still written by hand.

On top of that, I'm scanning thousands of these each year, and the invoice underneath the check ranges from the gamut of: "pristine copy just re-printed 'cause the customer didn't include one" through "bad inkjet photocopy of a photograph taken w/ a potato phone and then printed" and includes variations such as "customer included half-a-dozen invoices to be paid w/ one check, and if arranging them and the check _just so_ all will fit in the document camera window, saving a trip to the sheet feeder scanner"

A co-worker actually worked on this for a different program, one where actually sending in paperwork in good condition was expected and customary, but his system had a reject/failure rate of ~10% --- that would be almost 1,000 invoices each year for the program I am handling.

Yes it is. It's a poorly defined problem, and it needs to be correct, and existing OCR tools aren't perfect. Are the end of the day, it comes down to money and time, and throwing them at ChatGPT is cheap and fast enough to be used.
OCR is not the same as turning unstructured data (the freeform text OCRed from the PDF) into structured data.