News for hackers. Stuff that matters.

Show HN: Sqry – semantic code search using AST and call graphs

https://sqry.dev

I built sqry, a local code search tool that works at the semantic level rather than the text level.

The motivation: ripgrep is great for finding strings, but it can't tell you "who calls this function", "what does this function call", or "find all public async functions that return Result". Those questions require understanding code structure, not just matching patterns.

sqry parses your code into an AST using tree-sitter, builds a unified call/ import/dependency graph, and lets you query it:

  sqry query "callers:authenticate"
  sqry query "kind:function AND visibility:public AND lang:rust"
  sqry graph trace-path main handle_request
  sqry cycles
  sqry ask "find all error handling functions"
The `sqry ask` command translates natural language into sqry query syntax locally, using a compact 22M-parameter model with no network calls.

Some things that might be interesting to HN:

- 35 language plugins via tree-sitter (C, Rust, Go, Python, TypeScript, Java, SQL, Terraform, and more) - Cross-language edge detection: FFI linking (Rust↔C/C++), HTTP route matching (JS/TS↔Python/Java/Go) - 33-tool MCP server so AI assistants get exact call graph data instead of relying on embedding similarity - Arena-based graph with CSR storage; indexed queries run ~4ms warm - Cycle detection, dead code analysis, semantic diff between git refs

It's MIT-licensed and builds from source with Rust 1.90+. Fair warning: full build takes ~20 GB disk because 35 tree-sitter grammars compile from source.

Repo: https://github.com/verivusai-labs/sqry Docs: https://sqry.dev

Happy to answer questions about the architecture, the NL translation approach, or the cross-language detection.

( 2 comments | 2 points | on HN )
Re:Show HN: Sqry – semantic code search using AST and call g... by thebuilderjr on Friday March 06, 2026 @06:25PM (#47282461)
Interesting project. The thing I'd be most curious about in day-to-day use is freshness: when you save a file in a mixed-language repo, do you incrementally invalidate/rebuild just the affected AST + edge set, or is the graph eventually consistent until a background reindex catches up? The initial index numbers are great, but for editor/MCP workflows the make-or-break issue is whether "who calls this now?" is still accurate a few hundred ms after a refactor.
Re:Show HN: Sqry – semantic code search using AST and call g... by UltraSane on Saturday March 07, 2026 @05:58AM (#47286461)
This is actually really cool and something I have played around with using Neo4j