Noel Lee

Dental Lab Case Intake

Python, OCR, Azure Document Intelligence, Playwright, SQLite, PySide6, Microsoft Access

Foothill Dental Ceramics handles hundreds of active cases a month. Staff used to type every one into a Microsoft Access lab manager by hand, from paper work orders and from external dental portals. I wrote the Python program that does that entry now. A recurring entry job that took about 3 hours takes about 5 minutes.

Paper cases

Work orders get scanned into a folder the program watches. The scanner writes files slowly, so it waits until a file's size stops changing before running OCR on it.

OCR runs locally for clean printed pages. Harder pages can go to Azure Document Intelligence. Both feed the same parser, which pulls out the patient, doctor, case ID, shade, intake date, due date, material and notes, and keeps the original scan with the record.

Portal cases

Digital cases show up as email notifications from portals like 3Shape. A Playwright script signs in to the portal, downloads the case details and puts the case in the same review queue as the scans.

Review

OCR is good on printed fields and bad on handwriting. A wrong shade or due date means a remade crown, so nothing reaches Access until someone at the lab approves it. The review screen (PySide6) shows the scan next to the extracted fields, with validation errors and duplicate warnings marked.

Running it at the lab

Errors are logged against the file that caused them, and a failed file stays in the folder to be retried. Command-line tools can rerun any stage. The app is packaged to run on the office PCs without Python installed.

The same program digitized thousands of old case records covering about 10 years, so past cases can be looked up when a doctor asks what was ordered.