Local code intelligence that fits in a context window.
// tree-sitter AST → SQLite graph → one CLI call → structured signal.
curl -fsSL https://inari.hermestech.uk/install.sh | sh
irm https://inari.hermestech.uk/install.ps1 | iex
The problem
Without structural context, every refactoring task starts with the agent blindly loading source files. 8,000-12,000 tokens burned on navigation before a single edit. That's your money evaporating into context windows.
inari parses your code with tree-sitter, stores the result in a local SQLite graph, and lets agents query call hierarchies, type relationships, and dependency chains in ~200 tokens. No server. No API key. Just a binary.
Without inari -- 25:1 navigation-to-edit ratio
With inari -- 12:1 navigation-to-edit ratio
↑ 32% cheaper | 67% more edits | every read counts
See it in action
inari sketch PaymentService returns everything an agent needs to make correct edits --
without reading a single source file. The agent knows who calls what, what depends on what, and what's internal.
inari refs processPayment before touching the signature.
Command reference
Every output is structured for LLM consumption -- labelled fields, consistent separators, --json on everything. No parsing needed.
Compressed structural overview. Methods with caller counts, deps, type signatures. ~200 tokens instead of ~4,000.
Use before: reading source or editing a class.
Every reference grouped by kind -- instantiations, imports, type annotations, call sites -- with file and line.
Use before: changing a function signature.
Direct and transitive callers. At depth 1, shows who calls this. At depth 2+, shows the blast radius -- which entry points are ultimately affected.
Use before: any refactor that changes a public API.
Semantic search by what code does, not what it's named. Local embeddings -- no API key, works offline.
Use when: navigating unfamiliar code by intent.
What does this symbol depend on? Direct imports, called functions, extended classes. Transitive with --depth.
Use when: understanding what must exist first.
Show how requests reach a symbol. Traces the call graph backward from target to entry points. Use for debugging -- see how a bug is triggered.
Use when: checking if an internal change is safe.
Full repository overview in ~500-1000 tokens. Entry points, core symbols ranked by caller count, architecture layers. Start here for complex tasks.
Use when: starting work on an unfamiliar codebase.
List API controllers, workers, and event handlers. Symbols with zero incoming calls -- the starting points for every request flow.
Use when: understanding how requests enter the system.
Build or refresh the code index. Incremental by default. --full rebuilds from scratch. --watch auto re-indexes on file changes.
Use: once on setup. --watch during development.
What depends on this symbol? Reverse dependency traversal. Know the blast radius before deleting or renaming anything.
Use before: deleting or renaming a symbol.
Index health check. Symbol count, file count, last indexed time, stale files. Know if your index is fresh before range-based edits.
Use when: checking if the index is stale.
Self-update from GitHub Releases. Downloads and replaces the binary in-place. --check to see available version without installing.
Use: when a new version is available.
Setup
Everything lives in .inari/ -- a SQLite DB and a TOML config. No daemon, no Docker, no cloud dependency. Gitignore it and forget it.
$ curl -fsSL https://inari.hermestech.uk/install.sh | sh
$ inari init && inari index
Scale up
Workspaces federate queries across independent project graphs. Your TypeScript frontend, Rust backend, and Python ML service -- one --workspace flag queries them all. Each keeps its own .inari/ index.
Discover projects and create a workspace manifest. Each project keeps its own .inari/ index.
Use: once per workspace.
Unified map across all members. Entry points, core symbols, architecture -- tagged by project.
Use: orienting across repos.
Watch all members. One watcher per project, one command to rule them all. Ctrl+C stops everything.
Use: during development.
Language support
Each language is a plugin: grammar + two query files (symbols.scm, edges.scm). TypeScript, C#, Python, Rust, and Go ship built-in. Adding a new language is ~200 lines of Go.