-
-
Shows how the agent analyzes routes, demand, time, and location before selecting the best delivery option.
-
Shows the courier’s mobile interface, where the agent automatically accepts a delivery and displays the next pickup and route.
-
Shows the Monterrey simulation dashboard, visualizing couriers, orders, routes, and performance metrics.
Inspiration
Couriers usually choose the nearest or highest-paying order. However, the best order is not always the one that pays the most now—it is the one that also leaves the courier in the best position for the next opportunity.
We wanted to build a system that looks beyond the current delivery and makes informed, future-oriented decisions.
What it does
Our platform is an autonomous decision assistant for couriers. It combines numerical variables—such as fuel consumption, travel time, route cost, payment, capacity, and opportunity cost—with real-world context like traffic, weather, demand, road closures, and delivery hotspots.
Instead of following a fixed rule, the agent evaluates possible orders, routes, and stop sequences to maximize both current earnings and future opportunities.
Conceptually, each decision optimizes:
$$ U = Revenue - (Fuel + Time + RouteCost) + FutureOpportunity $$
The courier receives the selected route on an iOS map, while an ElevenLabs voice agent explains why the trip was accepted and answers questions hands-free.
How we built it
We built a Go simulator using real street geometry from OpenStreetMap. It generates couriers, orders, weather, traffic, road closures, and changing demand conditions.
A mathematical optimization layer converts different variables into comparable monetary costs. It then evaluates candidate orders while respecting constraints such as vehicle IRequest capacity and pickup-before-delivery precedence.
The simulator publishes snapshots, positions, routes, and decisions through REST and Server-Sent Events. Our SwiftUI app consumes these events, displays the route with Mapbox, and interpolates position updates to create smooth movement.
When a trip is accepted, the app automatically sends its description, ordered stops, and operational context to ElevenLabs, starting a conversational voice experience for the courier.
Challenges we faced
One major challenge was combining variables with different units—minutes, kilometers, fuel costs, payments, traffic, and weather—into a single useful decision model.
We also had to balance immediate profit against future opportunity. A nearby order may be convenient, but another order could leave the courier in a high-demand area and generate more income afterward.
On the technical side, we worked through real-time synchronization, reconnection handling, route-based position interpolation, changing JSON contracts, and voice-session timing.
What we learned
We learned that route optimization is not only about reaching a destination quickly. The destination itself affects what happens next.
We also learned how to combine mathematical optimization with contextual AI. The numerical model provides consistency, while the agent adds situational awareness and explains each decision in understandable language.
What we are proud of
We created an end-to-end system where a simulated event becomes an optimized decision, a live route, and a voice explanation—all automatically.
Our model is extensible: new variables such as vehicle capacity, battery level, safety, driver preferences, or additional operating costs can be incorporated without redesigning the entire system.
What's next
Next, we want to incorporate historical demand forecasting, real traffic and weather data, personalized courier preferences, and learning from completed trips.
Our long-term goal is to help couriers make every delivery part of a better sequence—not just a successful individual trip.
Smarter routes, better choices, more earnings, every trip.
Built With
- agents
- elevenlabs
- fastapi
- golang
- mapbox
- openaisdk
- openstreetmap
- python
- react
- swift
- swiftui
- typescript
- vite
- xcode
Log in or sign up for Devpost to join the conversation.