Skip to main content
Glama

bfs

Retrieve related entities by traversing from a starting entity to a specified depth using breadth-first search.

Instructions

BFS traversal from a starting entity.

Args: start_entity_id: Entity ID to start from. max_depth: Max traversal depth (1-10).

Returns: List of (entity_id, name, type, depth) entries.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
max_depthNo
start_entity_idYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior2/5

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

No annotations are provided, and the description does not disclose behavioral traits such as read-only nature, authentication needs, or side effects. It only describes input and output.

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 short with an opening one-liner and structured Args/Returns sections. It is front-loaded and efficient, though could be slightly more concise.

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

Completeness3/5

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

With 2 parameters, no annotations, and an output schema (explaining returns in text), the description covers basic usage but lacks context on graph nature, prerequisites, or error cases, leaving gaps.

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 0%, so the description adds meaning by explaining start_entity_id and max_depth (with range 1-10). However, it lacks details like entity type requirements or error handling, making it adequate but not comprehensive.

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

Purpose4/5

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

The description states 'BFS traversal from a starting entity,' which is a clear verb (traversal) and resource (entity graph). However, it does not distinguish from sibling tools like search_graph or get_entity_relations.

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

Usage Guidelines2/5

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

No guidance is provided on when to use BFS vs alternatives, nor any when-not-to-use conditions. Given sibling tools like search_graph, context on graph traversal choice would be helpful.

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/moliver28/corpus-kb'

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