Inspiration
In rapidly growing metropolises across Latin America like Monterrey, last-mile delivery couriers face an uphill battle every day. Urban logistics are plagued by sudden torrential flash floods, spontaneous road closures, suffocating rush-hour bottlenecks, and strict delivery time windows. Traditional navigation tools like Google Maps or Waze solve point-to-point commuting, but they fail to address the holistic economics of a courier's shift. Drivers are left following primitive greedy heuristics ("deliver to the nearest stop next"), which leads to costly empty deadhead miles, high fuel consumption, missed customer SLA windows, and diminished take-home pay. We were inspired to build OptiGoAI: an intelligent, end-to- end routing engine and driver cockpit that pairs industrial-grade mathematical optimization with an adaptive, conversational AI co-pilot. ────── ## What it does
OptiGoAI is a next-generation last-mile logistics intelligence platform and driver cockpit that turns chaotic delivery routes into synchronized, highly profitable shifts: • Dual-Engine Real-Time Benchmarking: In the interactive cockpit, dispatchers and drivers can run an OptiGo AI shift side-by-side against a standard Greedy Dispatcher in real time, visibly comparing delivery velocity, cumulative distance, and net earnings. • Dynamic Contingency & Weather Adaptation: When severe weather storms strike or major transit arteries are blocked, OptiGoAI instantly triggers live rerouting algorithms, navigating around affected sectors without stranding the courier. • In-Cab AI Co-Pilot (DeepSeek Powered): An intelligent, contextual conversational agent that proactively alerts drivers about road hazards, explains route rebalancing decisions, and provides tactical shift recommendations. • Hardware Telemetry HUD: Connects directly to the physical device's native GPS sensors via HTML5 Geolocation, streaming real-time speed, compass heading, coordinates, and precision radius onto an Esri Dark Gray spatial interface. • Quantifiable ROI & Shift Analytics: Delivers comprehensive post-shift breakdowns detailing net profitability, fuel expenditures, and carbon footprint mitigation. ────── ## How we built it We designed OptiGoAI with a resilient, decoupled full-stack architecture: • Frontend & Driver Cockpit: Built on Next.js 16 (Turbopack), TypeScript, and Tailwind CSS, featuring Lucide vector icons, multi-language internationalization (English/Spanish), and glassmorphic telemetry overlays. • Spatial Mapping: Powered by Leaflet with customized Esri World Dark Gray Canvas vector layers, polyline rendering, and smooth vehicle motion interpolation. • Optimization Backend: Developed with Django REST Framework (Python 3.12), implementing Google OR-Tools to solve complex Vehicle Routing Problems with Time Windows (VRPTW) and capacity constraints. • Cognitive Layer: Integrated DeepSeek AI via streaming API endpoints to provide dynamic conversational intelligence, anomaly explanation, and driver sentiment coaching. • Device Telemetry: Utilized the native navigator.geolocation API with high-accuracy GPS polling, asynchronous lock throttling, and defensive fallback engines for uninterrupted offline/online simulation. ────── ## Challenges we ran into
- Cartographic Layout Stability in Modern Next.js: Integrating client-only Leaflet maps within Next.js 16 App Router caused container zero-height collapses and black tile rendering when expanding dynamic cockpit panels. We engineered a bulletproof absolute- inset positioning hierarchy to ensure rock-solid responsiveness.
- Synchronized Dual-Thread Simulation: Running two competing routing simulations concurrently (OptiGo AI vs. Greedy) with asynchronous API telemetry sync without locking the React render loop required designing a single-ticker atomic state dispatcher with millisecond-precision timers.
- Dynamic Real-Time Obstruction Rerouting: When a simulated avenue is blocked mid- route, calculating alternative street polylines on the fly without introducing latency into the driver’s navigation display required optimizing spatial graph nodes and precomputing safety buffers. ────── ## Accomplishments that we're proud of
• Proven Algorithmic Superiority: OptiGoAI consistently outperforms standard greedy dispatching across every simulated benchmark: • -25.6% reduction in total transit distance. • -27.2% decrease in shift completion time. • -29.1% reduction in fuel consumption and CO₂ emissions. • Zero SLA time-window violations (compared to repeated delays in greedy models). • Smooth 1-Click Parallel Execution: Enabling judges to press one single button (⚡ Run Both) to watch two distinct algorithms race each other on a live interactive map. • Hardware-Integrated Telemetry: Bridging the gap between software simulation and physical reality by pulling authentic GPS speed, heading, and location directly from the user's phone or tablet. ────── ## What we learned
• Combinatorial Optimization vs. Heuristics: We deepened our understanding of why local greedy decisions trap couriers in dead-ends, and how global optimization (like OR-Tools Guided Local Search) uncovers non-obvious, highly efficient global schedules. • Human-Centric AI in Logistics: Drivers don't just want raw mathematical coordinates; they need an empathetic, clear AI Co-Pilot that explains why a route changed and calms stress during high-traffic or hazardous conditions. ────── ## What's next for OptiGoAI
• Collaborative Multi-Fleet Dispatching: Expanding the OR-Tools model to orchestrate hundreds of couriers simultaneously, dynamically exchanging delivery packages between drivers in overlapping zones. • Native Mobile PWA & Background Geofencing: Packaging OptiGoAI as an installable Progressive Web App with background geofencing and push notifications when approaching customer doors. • EV Telemetry & Eco-Charging Routing: Integrating electric vehicle battery state-of- charge (SoC) metrics to dynamically schedule rapid-charging stops during off-peak delivery windows. • Direct ERP & E-Commerce Connectors: Building ready-to-use API plugins for Shopify, Mercado Libre, and SAP Logistics to automate order ingestion straight from warehouse docks to the driver’s screen.
Built With
- deepseek-api
- django
- nextjs
- openstreetmap
- postegresql
Log in or sign up for Devpost to join the conversation.