Journals / Case study

How Oda stopped guessing how long a delivery stop takes

In November 2021 and June 2022 Oda's data team described how it went from no data on stop time to a LightGBM model feeding its route planner. Error per stop fell 23 percent. The spread of route delay fell only 10 percent, and Oda said so plainly. The measuring, the driver promise and the honest result are the lesson.

21 NOV 202615 min readLogistics · Last-mile delivery · Route planning · Gradient boosting Based on: Oda, 2021
Our diagram titled Seven minutes a stop, then a measured one, in three bands. Measure, without extra work for drivers: a geofence per customer, a circle around the address whose enter and exit times give the stop time, checked by hand by an analyst riding along with a stopwatch, and drivers get a written list of what the data is not for. Predict each stop: LightGBM trained on two years of recorded stop times and tuned with Optuna, with the named features order size, area for parking, customer history, floor and lift. Plan the route: the route planner gets predicted stop times and predicted driving times; the result is stop-time error down 23 percent and the spread of route delay down 10 percent. A note quotes Oda's verdict on the route-level gain: A little, but not as much as we had hoped.
Diagram: MORARI. Source: Oda

A delivery route is two kinds of time: driving and stopping. Map tools are good at the first. The second, parking, carrying bags, waiting at a door, is usually a flat guess.

Oda, a Norwegian online grocer with its own vans (it was called Kolonial.no until 2019), described how it replaced that guess in two posts on Oda Product & Tech: Part 1 by Siri Bruskeland on 22 November 2021, about measuring, and Part 2 by Tarjei Bondevik on 23 June 2022, about the model. Medium blocks our client, so we read archived copies of Part 1 and Part 2. Every result below is Oda's own; nobody outside checked it.

The problem: half the route was a guess

Oda calls it service time: "the non-driving time a driver spends serving customers on his or her route." That covers finding parking, picking and scanning the order, carrying it in and tidying the van.

It is not a detail. "Service time makes up around 50% of the total time spent on our routes, which means it’s really important that we plan for a realistic amount of time." Part 1 lists who pays when the number is wrong: customers through late or vague arrival times, drivers through stress, and the company through "inefficient routes."

The rule in 2019 was simple. "We basically planned for seven minutes with each customer, with some adjustments." The catch: "we didn’t have any (good) data on the service time we actually spent serving each customer."

Measuring it: a circle around every door

The team looked at continuous GPS tracking, extra buttons for drivers and timestamps from map apps. It chose geofencing: a virtual circle around each customer's coordinates. "By using geofencing, we could get a time stamp for when the driver enters the geofence around a customer, and when they exit it again." The gap between the two is the stop.

Two reasons are given. It "would also be much less intrusive to our drivers’ privacy than, for instance, continuous GPS tracking", and drivers get no extra buttons to press.

Test it cheaply first. Before any engineering, the analyst put a free Android geofence app on one of the drivers' Zebra handhelds, set circles of at least 50 metres around the next customers and rode along. "The timestamps matched the manually measured service times really well". The open problems were edge cases: a driver passing one customer's circle on the way to another, or two customers inside one circle.

Agree the rules with drivers before building. Oda brought in its privacy experts and wrote down what the data is for and what it is not for. A table in Part 1 says the timestamps are used for one thing: more precise data on how long each customer takes, so planning gets better. They are not used to track where each driver has been, to compare drivers on speed, or to rate driving skills. Retention was cut short: "the timestamps would only be stored in the production database for 30 days", and the analytics store keeps only durations.

Check again after building. The analyst rode routes with a stopwatch against the geofence times. On the one route Part 1 charts, most stops agree within about a minute, and one stop is far off, flagged as an edge case to handle.

The first win needed no machine learning. With real data, simple analysis of floor, lift, number of boxes and order weight let the team set the planned time by hand. Part 1 calls it "a pretty good estimation."

The model: gradient boosting on two years of stops

Part 2 starts from "two years of service time recordings" and names the most important features:

  • order size: weight, number of items, number of boxes;
  • the area, "relevant for parking difficulties";
  • the customer: earlier stop times there, which floor, whether there is a lift.

"We fed these features into our lightgbm gradient boosting model, and trained the model using Bayesian optimization in our hyperparameter tuning with the optuna library." LightGBM is a fast tree-boosting library; Optuna picks its settings.

The prediction goes into the route planner, next to a separate model for driving time between stops. "These two models are used as input to our route planner so that, ideally, the route planner optimizes routes based on correctly predicted service and driving times." Part 2 says nothing about first-time customers with no history, retraining or what happens when a prediction is missing.

How they measured it

Per stop. For six weeks from mid-November 2021 the model ran in Sandvika, west of Oslo, chosen because its mix of city and countryside matches the whole area. About 10 percent of deliveries were there. Everywhere else kept the old rule, and a naive baseline, always the historical average, ran alongside.

Line chart of mean absolute error in seconds per day from 4 November 2021 to early January 2022, with a dashed line around 18 November where the test starts. Three lines: Test area (ML model) in blue, Control area (Business logic model) in orange, Naive model in green. Before the dashed line all three sit between about 120 and 145 seconds. After it the blue line drops to about 100 to 120 seconds, with spikes near 125 to 130 seconds in December, while orange stays around 130 to 145 and green around 135 to 155.
The test area's error dropped the night the model started. Note that the old rule (orange) is only a few seconds better than the plain average (green). Image from Part 2, Oda Product & Tech, used with credit, converted to WebP only. Image: Oda

The model "consistently performed ~30 seconds better than the previously used Business logic model". Oda is upfront about the design: "Note that the comparison is somewhat flawed since these are different areas." What convinced it was that the drop came "abruptly overnight". It also notes the model "struggles the days right before Christmas Eve", when shopping changes. The model went live in the whole delivery area in January 2022.

Over the whole area, Oda reports that the mean absolute error per stop "has dropped 23%". Our arithmetic: 30 seconds being 23 percent puts the old error around 130 seconds, which matches the chart.

Per route. The question that matters to customers is whether the van arrives on time. Oda's answer: "A little, but not as much as we had hoped". It compared delay (actual minus planned arrival), on routes that left the depot on time, for April and May 2022 with the model against September and October 2021 with the old rule.

Density chart titled Delay distribution, entire delivery area, with delay in minutes from minus 60 to plus 90 on the horizontal axis. Two curves: ML model with sigma 17.1 in blue and Business logic model with sigma 19.1 in orange. Both peak just below zero; the blue peak is taller and narrower and its tail on the late side is a little thinner. Both have a small bump near minus 35 minutes.
Route delay with the model (blue) and the old rule (orange): slightly tighter, not dramatically. The bump near minus 35 minutes is drivers far ahead of schedule. Image from Part 2, Oda Product & Tech, used with credit, converted to WebP only. Image: Oda

The standard deviation of delay went from 19.1 to 17.1 minutes. "Although there’s a reduction of 10% of the distribution’s standard deviation, this improvement is quite modest given that the MAE of the service time predictions has dropped 23%."

The explanation is the useful part. A hand-tuned rule can get a whole route roughly right while every stop is wrong, because the errors cancel. Oda's example: "In the Business logic model era, drivers got too little time for the complicated deliveries in central areas of Oslo. Typically, drivers would see an average of 1.5 minutes additional delay per stop in that area." Rural stops gave the time back. With the model, "there is less variation in the delay per area, with no clear systematic bias in the urban and rural areas."

Two cautions from us. The two periods are different seasons, and the driving-time model changed at the same time, so the 10 percent is not the stop-time model alone. And no on-time rate, cost or stops-per-hour figure is given.

What it delivered

Fairness more than speed. Drivers in central Oslo stopped losing 1.5 minutes per stop to a rule that ignored where they were. Oda also lists less manual tuning "as Oda is growing and operating in several markets", a system it can add data to, and insight into what drives stop time.

Its next steps were honest too: cleaner training data, because "A lot of messy, unpredictable things happen on the road", a weather feature, since stop times were still adjusted by hand in snow, and some exploration to handle drift in new markets.

What has changed since

The model became part of the business yardstick. A 2023 Oda post by the Part 1 author (we read it and the 2025 post below from Oda's RSS feed, which Medium serves to our client) names stops per on-road hour as the key metric and lists "Route planning, driver assignment, service time prediction and the delivery tools our drivers use" among the levers.

It is still an input. A November 2025 Oda post says its route planner "must solve routes for over 5,000 customers across multiple depots and vehicle types", and do it in under 30 minutes. It is written in Rust, and that more volume means "better input estimates (like predicted customer service times)." It gives no new accuracy figure, so we cannot say whether the 2022 model was retrained or replaced. Oda's careers page, undated, says the planner launched after summer 2021.

The company changed shape. Oda merged with Sweden's Mathem in 2024 and now sells its platform to other grocers as Oda Systems. Its 2025 results release says "Mathem now runs on Oda’s technology platform, Oda Systems". A floor-and-lift model built for Oslo now has to work in other cities.

Others do the same. Dutch grocer Picnic wrote about "drop time" in 2020, before Oda: "A simple linear regression model already turned out to be a lot more accurate than what was in use at the time." Its neural network cut error "by approximately 30% when evaluating historical test data", and a pilot hub raised deliveries per trip "by roughly 20%". A February 2026 Picnic post says it still predicts "the exact number of minutes it takes to park the vehicle and bring the groceries to your doorstep", now from "order size, building characteristics, and customer familiarity". No numbers this time.

Research caught up with the area feature. A 2024 preprint models stop time for cargo bikes and vans from open map data and finds "geospatial embeddings can effectively capture urban contexts and facilitate generalizations to new contexts and cities", useful when an operator has little history of its own.

And the tooling is free. The open-source VROOM route optimiser takes a service duration per job, even per vehicle type. A stop-time model only has to write one number per stop.

Why it matters for your business

Indonesian last mile has more reasons for a slow stop than Oslo: a guard post that phones the resident in a gated estate, an apartment lobby that holds parcels, an office that sends someone down, a vague address, cash on delivery, no motorbike parking at a mall. We could find no official or survey data that measures any of this. A 2022 UGM thesis says "Empirical studies on first-last mile parcel delivery in urban Indonesia is still rare". So treat that list as hypotheses to test on your own timestamps. Oda's features, floor, lift, order size, area and customer history, are the evidence-backed start.

The volume is real. A March 2026 report quotes a Komdigi deputy minister saying the sector handles "sekitar 7 juta paket setiap hari", with logistics costs still "di atas 14 persen terhadap Produk Domestik Bruto (PDB)". ITDP Indonesia, an advocacy group, estimates last mile at 53 percent of logistics cost, without a cited source.

The law cares about the drivers more than the model. Under UU 27/2022 (UU PDP), driver timestamps tied to a name and a customer's address are personal data. Collection must be "terbatas dan spesifik, sah secara hukum, dan transparan" (Pasal 16), with a lawful basis such as the contract (Pasal 20), deletion once data is "tidak lagi diperlukan" (Pasal 43), and an impact assessment for "evaluasi, penskoran, atau pemantauan yang sistematis" (Pasal 34). Tracking named drivers and scoring them sits close to that line; a stop-time model that only plans routes sits further away. PP 33/2026, signed 16 July 2026 and in force six months after promulgation, adds a right to object to decisions based only on automated processing (Pasal 93). We read a regional government's copy; check the final text on JDIH. Our reading, not legal advice.

Oda's driver promise, 30 days of timestamps and durations only, is close to what the law asks. It is also why drivers accepted the system.

How we would build it today

Our diagram titled Log the stop, beat the median, then model, for an Indonesian operator with 10 to 50 vans or motorbikes, in three bands. Measure: four app events, arrived, unloading, handed over and left, with a geofence as a cross-check, and stopwatch rides on a few routes to check the timestamps, flagging breaks and calls inside a stop. Baseline, then model: a median baseline per customer, else per area and building type, then gradient boosting on building, floor, handover type, cash on delivery and order size, predicting a median and an 80th percentile. Plan, test, protect drivers: nightly to the planner, one stop time per job, shadow first and then alternate days; driver rules in writing, keep durations, drop raw GPS, no driver ranking by stop time. A note says UU PDP asks for purpose, retention and an impact assessment, and PP 33/2026 adds a right to object to automated decisions.
Measure first, beat a median, then let a model set each stop, with the driver rules written before the first timestamp. Diagram: MORARI. Source: Oda

Picture a grocery or distribution operator with 10 to 50 vans or motorbikes, a route planner and a driver app.

  1. Define the stop. From arrival to leaving for the next stop. Log four app events (arrived, unloading, handed over, left) and keep a geofence as a cross-check. Test the circle size: 50 metres can swallow three neighbours in a dense kampung or a tower block.
  2. Write the driver promise first. What the data is for, what it is not for, how long raw positions are kept. Copy Oda's table.
  3. Ride along. A stopwatch on a few routes against the app times. Flag lunch, prayer breaks and calls inside a stop, or they inflate the averages.
  4. Beat a median before training anything. Median stop time per customer, else per area and building type. Report error and bias, early versus late, per segment.
  5. Log the Indonesian features. Building type (tower, office, ruko, gated estate, house), floor, lift, handover type (guard, lobby, door), cash on delivery, order size, vehicle, time of day, an address-quality flag. Leave the driver ID out at first, so the model does not learn to punish slow people.
  6. Check you have the data. At about 30 stops a day, Oda's route size, and 25 working days, 10 vehicles log roughly 7,500 stops a month and 50 vehicles about 37,500. One to two months is enough for gradient boosting on a few features. New customers fall back to the area median.
  7. Model with a buffer. LightGBM, or linear regression first as Picnic did, with a time-based split. Predict a median and an 80th percentile, so the planner can add slack where the model is unsure.
  8. Feed the planner nightly. One number per stop into VROOM's service field or your own planner. Shadow mode first, then alternate model and old rule by day within the same area. That is the clean test Oda admits it did not run.
  9. Measure money, not just error. Late stops, stops per on-road hour, and whether windows can tighten. Expect Oda's lesson: route-level gains smaller than per-stop gains.

No real-time service, GPU or custom planner is needed at this size. Steps 1 to 4 are a month of logging; the model and the planner link are probably two to three weeks of work after that.