Skip to content
NeuralRepo
Get Support

nrepo graph

Terminal window
nrepo graph <id> [options]

Walks outward from one idea through its relations and prints what it finds as a tree. Relations are followed in both directions, so an idea that only ever appears as a target still shows up.

FlagTypeDefaultDescription
--depth <n>number1Hops to traverse. Clamped to a maximum of 5.
--type <types>string(all)Comma-separated relation types to follow: related, blocks, inspires, supersedes, parent, duplicate.
--jsonbooleanfalseOutput nodes and edges as JSON.
--humanbooleanForce human-readable output. Wins over --json.
Terminal window
nrepo graph 391 --depth 2
#42 Rewrite auth flow [exploring]
├── blocks → #43 Add dark mode and a theme picker [exploring]
│ └── related → #61 Design tokens audit [captured]
└── related → #18 Session cookie cleanup [captured]

Each branch is labelled with the relation type that produced it. An idea with no relations prints just itself:

#42 Rewrite auth flow [exploring]
No connections found
Terminal window
# Just the dependency chain
nrepo graph 391 --depth 3 --type blocks --json
# Structural relations only
nrepo graph 391 --type parent,supersedes

--type matches exact type names. An unknown name is not an error — it simply matches nothing, and you get the root alone.

Terminal window
nrepo graph 391 --depth 2 --json
{
"root": 391,
"depth": 2,
"types": null,
"nodes": [
{ "id": 391, "number": 42, "title": "Rewrite auth flow", "status": "exploring", "depth": 0 },
{ "id": 402, "number": 43, "title": "Add dark mode and a theme picker", "status": "exploring", "depth": 1 }
],
"edges": [
{ "source": 391, "target": 402, "type": "blocks" }
]
}

depth echoes the clamped value you asked for, not how far the walk actually reached. types is null when --type was not passed. Edges keep their original direction regardless of which way the traversal crossed them, so the output can be fed straight into a graph layout tool.

Each idea appears once: the first time the walk reaches it. In a diamond-shaped graph only the first edge into a node is drawn in the tree, though every edge is present in edges.