Skip to main content
Glama

get_neighbors

Find callers, implementations, subclasses, instantiations, or dependencies for a PHP symbol, route, or channel, with incoming, outgoing, or both directions.

Instructions

Like get_node in one direction: "in" what uses it (callers, implementations, subclasses, instantiations), "out" what it depends on.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "name": "<name>"
    },
    "name": "get_neighbors"
  }
}

Input Schema

NameRequiredDescriptionDefault
nameYesShort or fully qualified name, Class::method, route (POST /orders), channel or API operation; service@Name in a multi-service repository.
directionNo"in", "out" or "both" (default both).

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A3.5/5.0
Behavior3/5

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

No annotations are supplied, so the description carries the full behavioral burden, and it does disclose the traversal semantics per direction, which is the essential behavior. It says nothing about return shape, result size, pagination, or how an ambiguous or missing name is handled.

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?

One tight sentence with no filler, and the direction distinctions are front-loaded before any elaboration. The colon-and-parenthetical structure is dense but readable.

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

Completeness4/5

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

For a two-parameter read tool with no output schema, the description covers the decision that matters, namely which direction to traverse and what each yields. Only edge details such as ambiguous-name behavior or result limits are absent.

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%, so both parameters are already documented, and the enum values for direction are defined there. The description adds real meaning by mapping "in"/"out" to concrete relationship categories (callers, implementations, subclasses, instantiations vs. dependencies), which is a modest value-add rather than a full elaboration.

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 defines the tool by relation to a named sibling ("Like get_node in one direction") and then specifies what each direction returns, so an agent can tell it apart from get_node and impact_of. It never states the verb directly (returns/lists neighbors), relying on the get_node analogy to carry that meaning.

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

Usage Guidelines3/5

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

Usage is implied by the direction semantics: pick "in" to find callers/implementations/subclasses, "out" to find dependencies. There is no explicit when-to-use versus when-not-to-use, and no guidance on when impact_of or outline would be the better choice.

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

Deploy Server

Other Tools