Skip to main content
Glama

route_analysis_tool

Find the shortest or fastest route between two locations on a road network. Compare routes across different networks to assess changes.

Instructions

Analyze the optimal route between two locations in the network.

Accepts place names (e.g., "강남역", "Gangnam Station") or road names (e.g., "테헤란로").

TWO ROUTING MODES:
1. "distance" (default): Shortest path by edge length. Works without simulation data.
2. "traveltime": Optimal path using actual simulation results (edgedata XML) as edge weights.
   Requires weight_file (edgedata XML from a previous simulation).
   Can also use other attributes: "density", "CO2_abs", etc.

Use cases:
- "What is the shortest path from Gangnam Station to Samseong Station?" -> routing_mode="distance"
- "What is the optimal path based on actual travel time?" -> routing_mode="traveltime", weight_file=edgedata.xml
- "What is the lowest-CO2 path?" -> routing_mode="traveltime", weight_attribute="CO2_abs"
- "How does the path change after a road closure?" -> compare_net_file + compare_weight_file

In web mode, use [SHOW_ROUTE:edges|color|net_file_name] marker to visualize the result.
Always include net_file_name from the result so routes render on the correct network.

Args:
    net_file: Network file path
    origin: Origin location (place name, landmark, or road name)
    destination: Destination location (place name, landmark, or road name)
    routing_mode: "distance" (default, edge length) or "traveltime" (simulation-weighted)
    weight_file: Edgedata XML file for weighted routing (required when routing_mode="traveltime").
                 Use the netstate/edgedata file from simulation output.
    weight_attribute: Attribute to use as edge weight (default: "traveltime").
                     Other options: "density", "CO2_abs", "fuel_abs", etc.
    compare_net_file: Optional second network for before/after route comparison
    compare_weight_file: Optional edgedata for the comparison network

Returns:
    Dict with route edges, distance, time, road names.
    If comparison provided, includes both routes and diff.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
originYes
net_fileYes
destinationYes
weight_fileNo
routing_modeNodistance
compare_net_fileNo
weight_attributeNotraveltime
compare_weight_fileNo
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description carries full burden. It explains that distance mode works without simulation data, and traveltime requires weight_file. It also describes return format and web visualization marker. Could be improved by explicitly stating no side effects or limitations.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is well-structured with sections, but somewhat long. However, given the tool's complexity (8 parameters, two modes, comparison feature), all content is necessary and front-loaded. Minor redundancy could be trimmed, but overall efficient.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Despite no output schema, the description describes the return dict (route edges, distance, time, road names) and comparison results. It covers all parameters, modes, and special instructions for web mode, making the tool fully understandable without additional context.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 0%, but the description adds extensive meaning to all 8 parameters: explains defaults, required vs optional, formats, and usage context (e.g., weight_file required when routing_mode='traveltime'). This fully compensates for lack of schema descriptions.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool's purpose: analyzing optimal routes between two locations. It specifies input types (place names, road names) and two routing modes (distance and traveltime), distinguishing it from sibling tools like network_summary_tool.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Provides explicit use cases with examples, explains when to use each routing mode, and mentions comparison scenarios. Includes guidance for web mode marker, making it easy for an agent to decide when and how to invoke the tool.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/urban-ai-institute/kra35-prismx-agentsumo'

If you have feedback or need assistance with the MCP directory API, please join our Discord server