Get Graph Neighbors
get_graph_neighborsTraverse the wikilink graph outward from a starting note within set hop depth. Returns notes grouped by depth with hop distance and direction (inbound/outbound) in indented tree. Explore topic clusters or map local neighborhoods.
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-5, default: 1). Higher values explore further but can return many 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 |