ast-grep outline is released!
@hd_nvim9.6K followers
78,123 views
40 Comments
Comments from the original post on X (Twitter)

@hd_nvim
See the release blog
22 likes

@hd_nvim
2/ The problem: agents often open whole files just to answer “what’s inside?” That is expensive and noisy when the next step is only choosing the right source range. outline gives the agent enough structure to navigate before doing a full read.
13 likes

@hd_nvim
3/ Examples: ast-grep outline src/parser.ts ast-grep outline src ast-grep outline --match Parser --view expanded Same primitive, different navigation question: file shape, folder surface, or focused detail.
12 likes

@hd_nvim
4/ In benchmarks, `ast-grep outline` reduced file reads by roughly: - Django: 55% - OkHttp: 40% - VS Code: 35% The point is not to replace reading code. It is to make the next read smaller, more targeted, and easier to justify.
11 likes

@hd_nvim
5/ Design choices are intentionally constrained: No index, so less project state to maintain and better worktree support Local facts only, so it doesn't pretend to know defs, types, or call graphs Declarative extraction, so language coverage stays configurable and extensible
3 likes

@hd_nvim
6/ The sweet spot is between grep and a full language server: grep: fast, textual, local outline: fast, syntax aware, local LSP: richer, typed, global Use the heavy tool when you need semantics. Use outline when you need a map
9 likes

@hd_nvim
7/7 The tool is incomplete and still has TODO: stable JSON output, broader built-in extraction, custom extractors, etc. Try ast-grep outline and let me know where it helps or where the extraction rules should be improved!
4 likes

@neogoose_btw
Can ast grep analyze the source line of code if it contains definition or not?
4 likes

@hd_nvim
hmmm, I'm not sure about the question. but probably finding definition needs a LSP or at least better graph algo
1 like

@neogoose_btw
I mean simply classify that line literally contains a definition e.g function getUser() vs simply getUser()

@hd_nvim
it definitely does classify
1 like

@CatChen
A companion skill is necessary.
2 likes

@hd_nvim
In the upcoming release!
4 likes

@mohsen____
This is amazing! I'll integrate this into yek
2 likes

@JamesNguyen868
Really like the ast grow you build thanks
1 like

@cyrusnewday
@ewind_dev Let’s fucking go
1 like

@SantoshYadavDev
Congratulations buddy 👏
1 like

@ChadSigmaRizz
Does it work similarly to tree sitter ?
1 like

@hd_nvim
generated by @suyanhanx
4 likes

@ChadSigmaRizz
@suyanhanx I see, it looks interesting. I would love to compare it to a tree sitter tool or MCP.....
3 likes















