The logistics data bottleneck
In supply chain and logistics, the 'bilty' (lorry receipt) is the source of truth for a shipment. Yet, unlike standardized GST invoices, bilties are highly unstructured. They vary by transport company, are often handwritten, feature overlapping stamps, and arrive as skewed smartphone photos.
Currently, back-office teams manually type this data into ERPs. This manual process causes a 48-hour delay in invoicing and payment reconciliation, severely impacting cash flow.
Why traditional OCR fails on bilties
Standard template-based OCR (Optical Character Recognition) fails because it relies on fixed bounding boxes (e.g., 'the date is always in the top right'). When a driver submits a bilty from a new transport vendor with a completely different layout, template OCR breaks.
Furthermore, traditional OCR does not understand the relationship between text fields. It might read '12' and 'Tons', but it doesn't know that '12 Tons' is the payload weight.
The Document AI solution (LayoutLM)
Akshora AI Labs solves this using spatial Document AI models, specifically fine-tuned versions of LayoutLM v3.
- Spatial Understanding: LayoutLM processes both the text and its physical position on the page simultaneously. It learns that the word 'Weight' is usually adjacent to the actual payload value, regardless of where it appears on the page.
- Handwriting & Noise Resilience: The model is trained to extract data even when a physical stamp partially obscures a printed field, or when the document is a skewed photograph.
- Deterministic Validation: Before data hits the ERP, custom Python scripts validate the extraction (e.g., checking that the extracted origin and destination pin codes are valid formats).
Integration and operational workflow
The workflow is fully automated:
- A driver uploads a photo of the bilty via a WhatsApp bot.
- The image is routed to a FastAPI backend where it is pre-processed (deskewed and denoised).
- The LayoutLM model extracts the critical key-value pairs (Consignor, Consignee, Weight, Date, Lorry Number).
- The data is validated and immediately pushed into the company's ERP via API.
