Skip to main content
Glama

get_neighbors

Find every note linked to a given note in the wikilink graph, up to 3 hops away, returned as a flat list of titles. Answers what a note is connected to without extra graph data.

Instructions

What is around ONE note in the [[wikilink]] graph, out to depth hops. Answers "what is this connected to" with a flat list of titles — no node indices to decode, no whole-vault payload. For the shape of that neighbourhood — which notes link to each other, not just which are near — use get_graph with root_title and depth instead; it scopes the same way and keeps the edges.

Traversal is undirected: a note linking HERE is a neighbour just as much as one linked FROM here, because "what is this connected to" means both. links_out and links_in describe the direct relation to the note you asked about, and are sent only when true — so a depth-2 row carries neither. That is not a missing value: "which way does the arrow point" has no answer two hops away. Each note appears once, at the shortest depth that reaches it, and depth: 1 means directly linked.

These are LINKS people wrote, not similarity — a note about the same subject that nobody linked is not here. get_graph's semantic_edges cover that, and search covers finding it at all. An empty result means nothing links to or from this note, which is a fact about the writing, not about the topic.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
idNo
depthNoHops to walk. 1 = directly linked notes; each extra hop widens the set fast
titleNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.3.0

TDQS

A4.4/5.0
Behavior5/5

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

With no annotations, the description carries the full transparency burden, and it delivers: undirected traversal, links_out/links_in sent only when true, absence at depth 2 meaning no arrow direction, deduplication at shortest depth, and the distinction between human-written links and semantic similarity. It even defines what an empty result means.

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 long but densely purposeful: every paragraph explains a non-obvious behavior or decision boundary, and the core purpose is front-loaded in the first sentence. The extended clarifications prevent misinterpretations that would otherwise require trial and error.

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?

Given no output schema and no annotations, the description covers output shape, traversal semantics, and empty-result meaning very thoroughly. The main gap is target-note parameter resolution: an agent still cannot be fully certain whether to pass id, title, or both, and what happens if both are supplied.

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

Parameters2/5

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

Schema coverage is only 33%, so the description must compensate, but it never explains how the target note is identified via id or title, nor their relationship or precedence. It adds excellent semantics for depth, but the two most important parameters for addressing 'ONE note' are left essentially undocumented.

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 first sentence states a specific operation with a precise resource and scope: 'What is around ONE note in the [[wikilink]] graph, out to depth hops.' It also clarifies the output shape ('flat list of titles') and explicitly contrasts itself with get_graph, making it easy to distinguish from siblings.

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?

The description gives explicit routing guidance: use get_graph for the edge structure with 'same scope,' and use get_graph's semantic_edges or search when similarity or finding a note is the goal. It also explains when an empty result is meaningful, so an agent knows what conclusion to draw.

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