Detection has two halves. Reading the exception codes is the easy half and catches the obvious cases. Noticing that nothing has happened is the half that catches the expensive ones.
Key takeaways
Normalise carrier statuses into a small set of meanings; the raw codes differ wildly.
Measure the typical gap between scans per carrier and service, from your own shipments.
Flag at roughly three times the typical gap, in working days.
The never-scanned shipment is a separate and common case.
Keep the raw status alongside the normalised one, always.
Two detectors
Fig 1. The two detection paths. One reacts to events; the other reacts to their absence and is where the value is.
App integration
Machine learning
Management
Analytics
Normalising statuses
Carriers use dozens of status codes and no two use the same vocabulary. Mapping them to a small set — collected, in transit, out for delivery, delivered, attempted, address problem, refused, held — is unglamorous configuration work that makes everything downstream possible.
Keep the raw code and text next to the normalised meaning, always. The mapping will be wrong sometimes, new codes appear, and a normalised value with no original is a fact you cannot check.
What normal looks like
Fig 2. Three services with very different normal behaviour. A single silence threshold cannot serve all three, which is why it is derived per service from your own shipment history.
The numbers come from your own delivered shipments: take the gaps between consecutive scans on everything that arrived fine, and the flag threshold is roughly three times the typical one. That is a crude rule and it works considerably better than a number somebody chose.
It also self-corrects. When a carrier changes their scanning practice — fewer intermediate scans is a common cost saving — the observed gaps widen and the threshold follows, instead of producing a wave of false exceptions that trains everybody to ignore them.
Working days, again
A gap over a weekend is not a gap. Every threshold here is in working hours against the carrier’s own operating pattern, including the Saturday services that do scan and the ones that do not.
The shipment that never started
Fig 3. The never-collected shipment. It is the single most common real exception in most businesses and it has no carrier status at all, because the carrier has never seen it.
Compute
Machine learning
Management
Front-end & mobile
This case deserves its own tighter threshold, because a parcel with no first scan after a day is almost always sitting somewhere in your own building. It is also the cheapest exception to fix, since the goods are within reach.
It is worth counting separately for the same reason. A steady rate of never-collected shipments is a warehouse process problem wearing a carrier problem’s clothes, and attributing it correctly is the first step to fixing it.