Retail · Multi-store

The 6-hours-a-day reporting habit

Every morning, reports built themselves before anyone sat down. Thirty staff-hours a week, returned.

A business running on yesterday's numbers

When we arrived at a multi-store retail company, reporting was manual and it was end-of-day. Sales and stock lived in feeds that landed by email, changed format without warning, and disagreed with each other. Turning that into a picture of the business meant a person assembling numbers by hand, so by the time anyone saw a problem, it was already a day old. Retail punishes that lag. Stock runs dry in one store while the same size sits untouched in another, surpluses pile up quietly, and buying gets decided on instinct because instinct is the only thing available at the time.

The report shows up like a newspaper

Every morning, before anyone is at a desk, the first agent wakes up, reads yesterday's sales, and rebuilds the executive picture: sales for every store, category mix, best sellers, and comparisons that actually mean something, the same weekday last week, and a four-week average of that same weekday, measured on the retail calendar the business really runs on rather than the one on the wall. Nobody compiles it. Nobody chases whoever was meant to compile it. The report shows up like a newspaper.

A missing report is acceptable. A wrong report is not.

The second agent takes the whole warehouse out of the management system every morning (every item, size, colour, and exactly where it sits, from retail-ready shelves through to the repair pipeline) and lays it out as a print-ready report in the company's own colours. Then the part that earns its keep: a separate layer recomputes every figure from the raw data and checks it against what the report is about to say. One failed check and nothing ships. That rule is written into the runbook, and it is the reason people stopped quietly re-checking the numbers themselves before they used them.

The workbook every department head actually reads

The biggest single build reconstructs the wide workbook the heads of department live in: stock, sales, cover and size mix for every store, one sheet each plus a combined view, assembled out of three feeds that were never designed to meet. Every figure in it is live, so anyone can click a number and walk back to the rows underneath it. This build also taught the most expensive lesson in the fleet. A delivered report once understated sales badly, because most of the daily files sat outside the window the job searched and were silently never fetched. Nothing had failed loudly; the system simply had not noticed what was missing. The fix became a permanent rule enforced in code: the report must account for every single day it claims to cover.

What to send, and where

Deciding what to pull from the warehouse and send to which store used to be a judgement call made by whoever was free that afternoon: walking the racks, holding a picture of every shop in their head. A lot of time, and a lot of thinking, spent by someone who was needed elsewhere. Now it is an allocation anyone can audit. The agent reads every sendable unit, reads what each store holds and sells by category and size, and produces a per-store pick list a warehouse assistant can work straight off, plus a stays-in-warehouse sheet, so every single unit is accounted for somewhere. And where the answer is genuinely a business decision rather than arithmetic, it says so out loud and hands the question to the buying leads instead of quietly choosing for them.

The hard part was never the code

Running every morning with nobody watching is a discipline, not a feature. Executive surfaces get numbers; caveats, timestamps and exceptions go to the operator and never onto the dashboard. When a feed looks wrong or a total moves implausibly, the agent stops and tells a human rather than guessing. And sometimes the right agent is no agent at all: one loader was deliberately demoted to a plain, boring script, because that made it more reliable overnight. An agent nobody trusts is just a script with opinions. Making this fleet trusted infrastructure was the actual project.

What changed
2–3 hrs/day
Building the daily report by hand → it is finished before the first person sits down.
30 hrs/week
Reporting, warehouse and in-store manual work returned across the team: roughly six hours a day of it.
Every morning
Read by the CEO and every head of department, without anyone being asked to produce it.
Sharper buying
Buying leads decide on yesterday's real numbers instead of on a feeling about last week.
Under the hood

For the person who wants the detail.

Everything above is what it does. This is how it is actually built.

  • 01Scheduled cloud agents, no desktop and no person in the loop. Every write is idempotent, so a re-run can never duplicate a sale.
  • 02Comparisons computed on the retail calendar the business trades on: same weekday last week, and a four-week same-weekday average.
  • 03The warehouse is pulled through the management system's API every morning: item, SKU, size, colour and location, from retail-ready stock through to the repair pipeline.
  • 04A verification layer recomputes every number from the raw data, deliberately re-implementing the logic rather than importing it, so a bug can never validate itself. If one check fails, nothing ships.
  • 05Three incompatible feeds merged into one workbook, including a PDF that has to be parsed back into tables.
  • 06Every visible cell is a live formula over hidden data sheets, so any department head can drill from a headline figure to its source rows.
  • 07Coverage enumeration enforced in code: every day the report claims to cover is reconciled against the files actually present, and gaps are hunted down however far back they sit.
  • 08Replenishment runs two allocation philosophies side by side (push stock to where it sells, versus fill each store to its target), and where they disagree, the gap is escalated to the buying leads as a business question rather than resolved silently by code.
  • 09A conservation check proves the allocation adds up exactly: every unit lands either on a store pick list or on the stays-in-warehouse sheet. Provable, not merely plausible.
  • 10Exactly one writer per database. Agents halt and notify on implausible movement rather than guessing; caveats and exceptions are routed to the operator, never to an executive surface.
  • 11One loader was deliberately downgraded from an agent to a deterministic script, because determinism was worth more than intelligence at 4am.

What would you stop doing by hand?

Three questions, three minutes. We come to the first call already understanding the problem.