Skip to main content
Glama

find_path

Read-only

Find the shortest path between two items in a knowledge graph. Traverses edges up to a set depth and returns the ordered list of item IDs and edge types.

Instructions

Find the shortest path between two items in your knowledge graph. Traverses knowledge_edges up to max_depth hops and returns the ordered list of item IDs and edge types along the path, or "no path found" if disconnected.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
item_aYesUUID of the start item
item_bYesUUID of the end item
max_depthNoMaximum path length to search (default 5)

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
foundYes
path_lengthYes
path_item_idsYes
path_edge_typesYes
Behavior4/5

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

Annotations already indicate readOnlyHint=true, and the description adds behavioral details such as traversing knowledge_edges up to max_depth hops and returning specific outputs, complementing the annotations without contradiction.

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

Conciseness5/5

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

The description is a single, well-structured sentence that front-loads the purpose and efficiently covers key details without waste.

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?

Given the output schema exists, the description adequately covers the tool's functionality, algorithm (traversal up to max_depth), and output format, making it complete for the agent.

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

Parameters3/5

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

Schema coverage is 100% with each parameter described; the description reiterates max_depth behavior but does not add significant new parameter-level information, keeping the baseline at 3.

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 finds the shortest path between two items in a knowledge graph, using a specific verb and resource, and distinguishes it from sibling tools like deep_search or get_related by its pathfinding focus.

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

Usage Guidelines4/5

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

The description implies usage for discovering connections between two items, but does not explicitly state when not to use or provide alternatives, though sibling tools provide context.

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/lildaddyo/braintube-mcp'

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