A talk on how we use simulation-based optimization at Instacart to manage several tradeoffs and achieve supply/demand equilibrium when trying to solve how many shoppers we need to staff for.
DATA SUMMIT 24 Building Real-Time Pipelines With FLaNK
Supply optimization instacart
1. Supply Optimization At Instacart
Jagannath Putrevu
SF Bay Area Machine Learning Meetup
5/3/2017
2. v
Supply Forecasting - McDonald’s
Single Server Queue
Service Time: 5 min/order
Orders per hour: 12
24 orders per hour
60 orders per hour
.
.
2 servers per hour
5 servers per hour
.
.
Demand Supply
3. v
Supply Forecasting - Chipotle?
Multi Server Queue
Variable Service Speeds Per Server
Demand Supply
24 orders per hour
60 order per hour
.
.
?
?
.
.
4. v
Supply Forecasting - Instacart?
What the talk will cover:
● Logistics @ Instacart
● Fulfillment Models
● Problem Formulation
● Simulation Based Optimization Framework
What it will not cover:
● Technology stack
● Algorithm details
● Results & Comparisons
11. v
What is Efficiency?
Efficiency =
Deliveries
Total Time
Deliveries
Active Time
Active Time
Total Time
= X
Active Efficiency= X Utilization
How fast? How busy?
12. v
Time Components In Labor Hours
Begin Shift End Shift
Deliver to Customer
Wait for Batch
Drive to Store Shop Groceries
Pickup Bags from Store
13. v
Time Components In Labor Hours
Deliver to Customer
Wait for Batch
Drive to Store Shop Groceries
Pickup Bags from Store
End ShiftBegin Shift
In-store Shopper
14. v
Time Components In Labor Hours
Deliver to Customer
Wait for Batch
Drive to Store Shop Groceries
Pickup Bags from Store
Full Service
Begin Shift
FullServiceShopper
FullService
FullService
End Shift
15. v
Time Components In Labor Hours
Deliver to Customer
Wait for Batch
Drive to Store Shop Groceries
Pickup Bags from Store
Driver
DriverDriverBegin Shift
Driver
End Shift
16. v
Time Components And Factors Affecting Them
Idle Time: Supply/Demand equilibrium, Variance in Cancellations
How busy?
How fast?
Driving Time: Batching (Number of Orders Per Trip), Proximity To Store, Traffic
Picking Time: Speed of Shopper, Shopping List Sorting, Checkout Times
Bags Pickup Time: Staging Area Layout, Number of Bags being picked up
Delivery Time: Traffic, Order Time/Space Density, Routing Algorithm Efficiency
18. v
Problem Statement
● For a given day, how do we staff :
○ In-store shoppers (ISS) at each store location,
○ Full Service shoppers (FSS) across the entire zone,
● so as to:
○ maximize active efficiency,
○ minimize idleness,
○ minimize lost deliveries
23. v
System
Outputs
Number of Shoppers Required
Percentage of Volume Done Through
Handoff
Estimated Efficiency & Utilization
Inputs
Demand
(variable)
Store Locations
(fixed)
Shopper Pool
(variable)
Fulfillment Times
(predicted, variable)
Cancellation Probability
(predicted)
Handoff vs Full-Service
Idleness vs Efficiency vs Lost
Deliveries
Store Timings Shift Length Requirements Business rules
Constraints
24. v
Simulate An Ideal Universe
Assume infinite Supply, solve the fulfillment problem, and generate optimal set of trips
25. v
Staff For An Ideal Universe
● When do all the trips begin and end in the optimal solution?
● Back-calculate how many shoppers we need and at what times we need them