Skip to content
Leon Achata
All work
Agents

RoutePlanner AI

Paste your stops the way you would text a friend and get the provably fastest visiting order, drawn on a map.

The problem

Couriers, sales reps and field teams plan multi-stop routes by hand (or with “nearest first”) and lose hours driving in the wrong order.

How it works

A LangGraph pipeline parses the message with an LLM, geocodes every place in parallel, builds a directed travel-time matrix with Google Maps and solves the order: Held-Karp dynamic programming returns the proven optimum up to 12 stops, and OR-Tools guided local search takes over beyond that. Each node fails with a specific message instead of a generic error.

Pipeline

  1. 01Parse
  2. 02Geocode
  3. 03Distance matrix
  4. 04Optimize
  5. 05Directions

Where it's used

  • Last-mile delivery and courier dispatch
  • Sales and field-service visits
  • Multi-stop trip and itinerary planning

Highlights

  • Proven-optimal routes up to 12 stops (Held-Karp), OR-Tools beyond
  • Directed matrices that respect one-way streets; open paths for one-way trips
  • Parallel, cached geocoding biased to the configured country
  • Tests and CI; one-click Google Maps link for the driver

Stack

LangGraphOpenAIGoogle Maps APIsOR-ToolsFastAPI

Want something like this for your company?

I build production versions of these systems on your data and your infrastructure.

Related service: Agents & workflow automation

Contact me