Skip to content

Part 2 of 7 · Product recall tracer series ~5 min read

The fifteen seconds at goods-in that decide what a recall costs

Everything else in this system can be built after the notice arrives. This part cannot. A batch code that was not written down at delivery is not recoverable from anywhere, at any price, and that single fact is what makes goods-in the whole design.

Key takeaways

  • Batch codes arrive three ways and a keyboard is the worst of them.
  • Store supplier, batch, quantity and date together or the row is not traceability.
  • A photograph of the case label is a legitimate primary record.
  • Best-before is not a batch code, but it is often the only code there is.
  • Unreadable is a state to record, not a failure to hide.

Three ways a code arrives

Three routes for a batch code converging on one registerThree boxes on the left feed one box on the right. The delivery note, with a batch column often handwritten, arrives by photo or scan. The case label, with a printed lot code and best-before, arrives by phone photo. A supplier feed, a despatch advice that is rare but exact, arrives by file or API. All three converge on the Batch register, holding supplier, batch, quantity, date and site, which in turn feeds a box labelled Confidence recorded: scanned, read, or assumed. A note says three routes produce one row, the third is the only exact one and the fewest suppliers offer it, so the design has to be good at the first two.The delivery notebatch column, oftenhandwrittenphoto or scanThe case labelprinted lot codeand best-beforephone photoA supplier feeddespatch advice,rare but exactfile or APIBatch registersupplier, batch, qty,date, siteConfidence recordedscanned, read,or assumedThree routes, one row. The third is the only exact one and the fewest suppliers offer it, so the design has to be good at the first two.
Fig 1. Whatever the route, the same five fields come out, plus an honest note about how they were obtained.
  • Machine learning
  • Front-end & mobile
  • Outside AWS

Why not just type it

Because a batch code is a string with no meaning and no checksum, typed by somebody holding a scanner in the other hand, in a cold room, against a clock. The error rate is high and, worse, the errors are silent: L4127 entered as L4l27 does not fail, it just quietly stops matching the notice that arrives four months later.

A photograph does not have that failure mode. It is wrong or it is unreadable, and both of those are states the system can record and a person can resolve. The image is also the evidence: when an inspector asks how you know that pallet was batch L4127, a picture of the case is a better answer than a database field.

What a traceable row actually contains

Goods-in from pallet to an open batch balanceA vertical chain inside an AWS account container, entered from a box on the left labelled Delivery, a pallet at the back door. Capture takes the note, label or feed and sends photos to S3 as a side output. Read the codes extracts batch, best-before and quantity. Match the product maps the supplier description to your own line codes and has a side exit reading no match, ask. Write the row stores supplier, batch, quantity, date and site. Open the balance records units remaining in this batch. A note says the last step is what makes the register usable years later, because a batch is not an event but a balance that draws down as things sell.AWS ACCOUNTDeliverypallet at theback doorCapturenote, label orfeedS3the photographis the evidenceRead the codesbatch, best-before,quantityMatch the productto your ownline codesAsk a humana new supplierdescriptionno matchWrite the rowsupplier, batch,qty, date, siteOpen the balanceunits remainingin this batchThe last step is what makes the register usable years later: a batch is not an event, it is a balance that draws down as things sell.
Fig 2. Five steps, one of which can stop and ask. Matching a supplier’s description to your own product code is the step that fails, and it fails quietly if you let it.
  • Storage
  • Machine learning
  • Analytics
  • Front-end & mobile
  • People

Best-before is not a batch code, and often it is all you have

Plenty of suppliers print no lot code at all, or print one that is really a date in disguise. Recall notices know this, which is why they usually name both: a batch code and a best-before date, sometimes as alternatives. So the register stores both, keeps them distinct, and never derives one from the other.

The temptation is to normalise — to turn 23/156 and L23-156 and 156/23 into one canonical form. Resist it at ingest. Store the string exactly as printed, and do the fuzzy comparison at trace time where a human can see what matched what. A normaliser that silently merges two real batches is worse than no normaliser.

The five fields, and why each one is there

  • Supplier. One step back. Also the only route to the rest of the batch.
  • Batch code, verbatim. Exactly as printed, including the parts that look like noise.
  • Best-before. Separate field. Half of all notices name it instead.
  • Quantity and site. Turns the batch into a balance you can draw down.
  • Confidence. Scanned, read from a photo, or assumed. Changes what you can claim later.

The cost of skipping it

Fifteen seconds a delivery line, at a hundred lines a week, is about twenty minutes. The comparison is not against zero, because without it a recall means pulling every unit of the line and writing to every customer who ever bought it — and doing that once costs more than a year of the twenty minutes.

There is a second cost that is easier to miss. A business that cannot bound a recall also cannot defend itself against one. If you can show that only four hundred and ninety-six units of the affected batches ever left your building, that is the size of the problem. If you cannot, the size of the problem is whatever anybody claims.

All posts