top | item 47210564

Show HN: Reflex – local code search engine and MCP server for AI coding

1 points| therecluse26 | 1 hour ago |github.com

I built Reflex after getting frustrated with hosted code search tools' infrastructure overhead, slow reindexing and accuracy limitations as drift occurs between the index and local state. It's a local-first code search engine written in Rust that combines trigram indexing with Tree-sitter symbol extraction and static dependency analysis.

The MCP server is what I get the most value from. Claude Code and other AI coding assistants can search your codebase, find symbol definitions, trace dependencies, and navigate across branches without ever loading raw file contents into the context window. It gives the AI accurate knowledge of your codebase at a fraction of the token cost.

Switching branches is instant. Reflex reindexes only what changed, so you're never waiting for a full reindex when jumping between branches. You can index any branch in seconds on your laptop with no server, no configuration, and no cost.

Other things it does:

- Full-text search via trigram indexing (finds every occurrence, not just definitions) - Symbol-aware search with Tree-sitter (filter by function, class, struct, etc.) - Dependency analysis: what imports a file, what a file imports, circular deps, dead code - Incremental reindexing via blake3 hashing (only reindexes changed files) - Fully offline, all data stays on your machine

Install: npm install -g reflex-search or cargo install reflex-search

Happy to answer any questions about the implementation or use cases.

discuss

order

No comments yet.