Get Graph Neighbors
get_graph_neighborsTraverse the wikilink graph from a starting note to find all reachable notes within N hops, grouped by depth with direction tags. Use to explore topic clusters or map a note's local neighborhood.
Instructions
Traverse the wikilink graph outward from a starting note and return every note reachable within N hops, grouped by depth level with an indented tree visualization. Each neighbor is tagged with its hop distance and direction (inbound = reached via backlink, outbound = reached via outlink). Use to explore a topic cluster, map a note's local neighborhood, or find related notes beyond direct links. Accepts paths with or without .md extension.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| path | Yes | Starting note path relative to vault root (e.g., 'projects/alpha.md'). Extension optional; falls back to basename match. | |
| depth | No | Maximum link-hops to traverse from the start note (1-3, default: 1). Higher values explore exponentially more notes. | |
| direction | No | Traversal direction: 'outbound' follows outlinks the start note points to, 'inbound' follows backlinks pointing at the start note, 'both' follows either (default) | both |
| maxResults | No | Maximum neighbor notes to return (1-1000, default: 200). Traversal stops early when this cap is reached and a truncation notice is appended. |