Making Postmates Even More Efficient
When we think of delivering items, we usually think of going from point A to point B.
It’s a simple concept and is familiar to anyone taking a taxi or a Lyft or Uber. The driver goes to point A, then proceeds to point B. Two legs in the route.
While Postmates enables the delivery of virtually anything in a city, currently our platform predominantly moves prepared food. This introduces another leg in parallel to the driver’s delivery — the food preparation at the merchant. When you order that burrito or pizza from the Postmates platform, it relays the order to the merchant on your behalf, and the merchant begins to prepare the food.
So, what was a simple pickup-and-dropoff becomes:
So how do we predict the food preparation time for each merchant? Every single call through the platform is a measurement of a merchant’s food prep time. With enough data, it turns out we can be fairly accurate in predicting these times.
In addition to travel time, the driver has wait time while the merchant prepares the food. When a platform is in its early stages, delays such as these are inevitable. There isn’t really anything else for the driver to do. But as the density of deliveries increases, a driver can utilize this time to finish up an ongoing delivery.
In Postmates-land we call this ‘stacking’. Basically, if we can predict the amount of time a merchant will spend preparing the food, we can offer the delivery to a driver who is currently working on another delivery, such that when they finish their current dropoff, the food will be ready for them at the next pickup location.
The result of this type of stacking is the construction of a set of interleaved deliveries for a driver:
Normalizing the Driver Experience
The tricky thing about stacking deliveries is that it presents drivers with a wide variety of timing scenarios. Some deliveries have short prep times, some have long ones. Making the decision about what to stack in real-time is error prone. It is also difficult to anticipate what the the state of the fleet will be in 30 minutes — deliveries may be delayed or new drivers may come on duty who are a better match.
The next approach attempts to address both of these concerns. Instead of stacking on the driver, we stack on the platform itself by accepting a delivery immediately instead of dispatching to drivers. Only when the food is almost ready do we begin dispatching. We call this new dispatch algorithm Turbo, and it’s rolling out gradually to more and more deliveries.
With Turbo, the picture looks like:
For the driver, we have now constructed a unit of work that is more stable, the familiar:
and at the same time we have leveraged the prep time to find a good match.
There are a few benefits afforded by this new approach:
- Easier decision making for drivers: Now every driver only gets dispatched a delivery when the food is ready to be picked up. They no longer need to care whether a merchant has a long food preparation time or short food preparation time because by the time they are dispatched, the food is ready.
- More time to find a match: What was simply a 15 minute food prep time now becomes 15 minutes to find a driver optimally suited to arrive just in time for the pickup. It’s a much smoother process as we’re effectively giving the platform time to make a decision.
- Consistent units of work for the driver: The combination of simple pickups-and-dropoffs with dense geographic distributions of demand results in shorter, more consistent units of work — about 20 minutes of traveling.
Driver Efficiency Leads to Customer Happiness
Ultimately, this initiative driven by Postmates engineering to eliminate wait times and increase driver utilization (ie. the number of deliveries per hour), is also great for the customer. With this better dispatch algorithm, it means that we can accept delivery requests before knowing who the specific driver will be. For more and more merchants, customers will no longer have to wait for their delivery to get accepted — delivery requests will get accepted right away and we’ll dispatch to the appropriate driver when the food is prepared.
These units of work become an object we can schedule in our system to achieve more efficiency gains. In a factory, these units are boxes, whereas at Postmates, these units are delivery routes. With the time to schedule and a stable unit of work, it opens the door to better scheduling algorithms and even more efficiency gains. In the future, this could translate to coalescing multiple orders from the same merchant into one pickup that can be mapped along a single delivery route. It could also mean the ability for customers to choose a preferred delivery time.
In conjunction with these algorithm changes, in the latest version of the Postmates app released today, you will find UI improvements to surface food preparation times from merchants and the detailed status of your delivery.
By Andrew Wong, Engineer, Postmates