basemind
Local Rust index of a repo's code, docs, git history and memory, served to coding agents over MCP
Tree-sitter code reading for agents: outlines, definitions, callers, file deps and function-level diffs
By jahala (individual) Rust Local · stdio Developer tools
61 popularity score ★ 358 ↓ 1.6k/wk
Opens the app, which asks before it adds the server.
claude mcp add tilth -- npx -y tilth --mcp{
"mcpServers": {
"tilth": {
"command": "npx",
"args": [
"-y",
"tilth",
"--mcp"
]
}
}
}{
"mcpServers": {
"tilth": {
"command": "npx",
"args": [
"-y",
"tilth",
"--mcp"
]
}
}
}{
"servers": {
"tilth": {
"type": "stdio",
"command": "npx",
"args": [
"-y",
"tilth",
"--mcp"
]
}
}
}[mcp_servers.tilth]
command = "npx"
args = ["-y", "tilth", "--mcp"]gemini mcp add --scope user tilth npx -- -y tilth --mcpOpens the app, which asks before it adds the server.
cargo install tilthclaude mcp add tilth -- tilth --mcp{
"mcpServers": {
"tilth": {
"command": "tilth",
"args": [
"--mcp"
]
}
}
}{
"mcpServers": {
"tilth": {
"command": "tilth",
"args": [
"--mcp"
]
}
}
}{
"servers": {
"tilth": {
"type": "stdio",
"command": "tilth",
"args": [
"--mcp"
]
}
}
}[mcp_servers.tilth]
command = "tilth"
args = ["--mcp"]gemini mcp add --scope user tilth tilth -- --mcptilth is a single Rust binary that works both as a command-line tool and as a stdio MCP server (started with `tilth --mcp`). It parses a local codebase with tree-sitter on each request rather than building an index, so an agent can ask structural questions about code instead of chaining grep and file reads.
In MCP mode it offers seven tools by default: reading a file (whole when small, as an outline of functions, classes and imports when it passes roughly 6,000 tokens, or by line range or markdown heading), symbol, text, regex and call-site search with definitions listed first, a glob-based file tree with token-size totals per directory, a file's imports and dependents, a one-call summary of a symbol (signature, body, callees, callers, siblings, tests), a function-level diff of uncommitted, staged or committed changes, and a report of tokens saved this session. Started with `--edit`, it adds an eighth tool, `tilth_write`, and switches reads to line:hash anchors so edits are rejected when the file changed since it was last read.
The tool definitions at v0.10.1 carry details the README leaves out: the `tilth_savings` tool exists at all, multi-symbol search takes at most 5 names, `tilth_write` takes at most 20 files per call, and `tilth_grok` returns 5 callers, 5 callees, 8 siblings and 8 tests by default, widened to 50/30/30/30 with `full` (src/mcp/tools/definitions.rs). In MCP mode, definitions already expanded earlier in the session come back as `[shown earlier]` instead of being repeated.
| Runtime | Node.jsorRust |
|---|
The `tilth` binary: `cargo install tilth` (needs a Rust toolchain), a prebuilt binary from the GitHub releases page, or `npx tilth` (needs Node.js). `tilth_diff` calls the `git` program, so git must be on PATH and the folder must be a git repository for diffs. No account or key.
It parses syntax only and does not resolve types. Callers and dependencies are matched by name, so two functions with the same name in different modules are not told apart, and dynamic dispatch is not followed. Languages without a bundled grammar (17 are parsed) get text search and plain reading only; Dockerfile and Make files are recognised but not parsed. Search returns 10 matches by default, 100 with `full`, and walks the whole tree on each call, so time grows with repository size. Search includes gitignored files, skipping common build and dependency folders such as node_modules, target and .venv. The `--map` codebase skeleton is CLI-only, not an MCP tool.
Suits developers who run coding agents on a local repository and want definitions, call sites, file dependencies and per-function diffs from one local process, with nothing to index and no network calls. Leave out `--edit` to keep it read-only; add it only if you want it to replace the host's own edit tools. Because matching is by name with no type resolution, a language server based tool is the better pick when you need exact references across same-named symbols or dynamic dispatch.
tilth_readtilth_searchtilth_listtilth_depstilth_groktilth_difftilth_savingstilth_write