v1.3.1

Search code and notes.
Build context for your task.

Find code and notes by meaning or exact text. Build a context pack with related code, line numbers, and selection reasons. Files and queries stay on your machine.

Terminal - ig
# Retrieve a decision from preindexed notes.
$ ig "what did we decide about cache invalidation?" ~/notes
notes/decisions/cache.md:42
Invalidate on writes; keep reads cache-first.
$ ig context "fix refresh-token races" --since main --budget 8000
Budget: 7642 / 8000 estimated tokens
Candidates: 31 retrieved | 14 selected
Task + diff Current work included
Graph Relationships followed
8K Default token budget
0 Bytes uploaded

Give your agent the code behind the task.

Not a longer result list. A bounded pack connecting current work to code an agent needs to understand before editing.

Current work becomes retrieval signal

ig context --since main finds the Git merge base of the current branch and main. It includes committed changes from that base to the current branch, plus staged, unstaged, and untracked files, task anchors, and paths found in an issue or stack trace. The main ref is not itself the diff base. Context packs follow dependencies, dependents, definitions, callers, references, tests, configuration, docs, and recent co-changes.

PrimaryDependenciesDependentsDefinitionsCallersReferences TestsConfigDocs

Each item includes exact lines, its role, why it was selected, and how it relates to the task.

$ ig context "fix refresh-token races" --since main --budget 8000

# ivygrep context
...
Budget: 7642 / 8000 estimated tokens
Coverage: 7 files | 2 primary | 1 definitions | 1 dependencies | 0 dependents | 2 callers | 0 references | 1 tests | 0 config | 0 docs
Candidates: 31 retrieved | 14 selected

## Evidence
### 1. src/auth/refresh.rs:118-166 [primary, definition]
Why: task anchor; changed implementation.
Signals: lexical, symbol, git change.

Use current changes

Context packs include staged, unstaged, and untracked changes. With --since main, they also include commits on the current branch since the merge base of that branch and main.

Include related code

Each pack can include definitions, callers, dependencies, tests, configuration, and documentation. Selection reasons explain each item.

Set a token budget

The --budget option limits the rendered pack in estimated tokens. Context packs supply evidence for an agent to inspect.

Search notes by meaning

Markdown vaults, research logs, meeting notes, decisions, and agent memories stay local.

Local semantic recall

Index your notes once. Search them from the CLI, MCP, Web UI, or TUI. A filesystem watcher updates changed files.

74.9% recall@20 at 87.63 ms warm p95 on MemoryQuest (v1.2.7).

This historical benchmark measures retrieval. It does not measure answer accuracy or the current model.

# Build local semantic index once.
$ ig --add ~/notes --wait-for-enhancement

# Reuse it for memory retrieval.
$ ig -n 20 \
  "what did we decide about cache invalidation?" \
  ~/notes

Local vaults

Search Markdown, text, JSON, and other supported documents without uploading notes or queries.

Updated notes

The filesystem watcher indexes changed files. Background workers update their hash vectors and neural vectors.

Inspect evidence

Results preserve exact file paths, lines, scores, and previews so retrieved memories stay auditable.

Built for live knowledge, not one-off searches

Task state, repository relationships, notes, and incremental indexes stay connected across CLI, MCP, and Web.

Task-aware inputs

Combine a task, issue, trace, branch diff, staged files, and dirty worktree before selecting code.

Repository relationships

Expand from task anchors through definitions, callers, references, dependencies, dependents, tests, configuration, docs, and recent co-changes.

Bounded evidence

Token-aware selection and deduplication produce one pack with exact paths, lines, roles, reasons, and relationships.

Thin worktree overlays

Worktrees reuse the repository base index. Their overlays store changed chunks and tombstones that hide base files deleted on that branch.

Incremental availability

Changed chunks update incrementally. Starting with v1.3.1, files confirmed missing disappear from results immediately while the watcher removes owned index entries or records an overlay tombstone. Permission and other read errors are not treated as deletion.

Exact and semantic

Move between semantic notes, natural-language code intent, literal text, symbols, references, callers, paths, and project-wide search.

One context contract

CLI, JSON, MCP, and Web expose the same structured search results and task-context packs.

Local by design

No hosted inference or telemetry. Code, notes, queries, embeddings, and indexes stay on your machine. Neural search downloads pinned model assets on first use; --hash avoids the download.

Browse indexed workspaces

The local browser UI searches tracked workspaces, scopes results to a folder, and opens indexed files beside the result list.

Result cards show language icons, syntax-highlighted snippets, line markers, and selected-state highlighting. The file viewer highlights focused result lines and previews Markdown with a source toggle.

Every bind, loopback included, prints an authenticated URL, so other users on a shared machine cannot query the local API. Open that URL directly and do not share it: the browser exchanges the token for an HttpOnly session cookie and removes it from the address, while a bare http://127.0.0.1:4747/ returns 401. Set IVYGREP_NO_BROWSER=1 to skip the automatic browser launch. On another device, replace only 127.0.0.1 with the server's LAN or Tailscale address and preserve the complete token=... query string. Restart the daemon to invalidate access.

Non-loopback serving uses plain HTTP: the token authenticates requests but does not encrypt source or results. Use a trusted network only, preferably Tailscale or an SSH tunnel. Never expose the port directly to the internet or untrusted Wi-Fi.

$ ig --web
$ ig --web "auth flow" .
$ ig --web --host 0.0.0.0 --port 4747

How indexing and search fit together

BM25 and literal search are available first; background jobs add hash and neural vectors.

1

Lexical index

File chunks go into SQLite and Tantivy first, so search works before vector jobs finish.

2

Rank matching files

Search combines exact text, keywords, symbols, paths, and vector matches. Results include file paths, line numbers, and previews.

3

Local vectors

Background workers add hash vectors and neural vectors. The default potion-code-16m-v2 model downloads 33.5 MB of assets and runs on CPU. Metal and CUDA accelerate optional transformer profiles.

Git-aware indexing

Worktrees share a base index. Branch switches reconcile only changed paths, including deletions.

Worktree overlays

Each worktree references the shared base index. Its overlay stores changed chunks and tombstones that hide base files deleted on that branch.

Branch-switch deltas

Merkle reconciliation handles changed paths, including deletions. Content hashes skip byte-identical files across branches.

Context stays practical at repository scale

Three hash-only trials on deterministic synthetic CC0 data measure local indexing, query latency, and footprint at scale.

6.19 ms

Warm CLI p95

150,576 chunks/s

Controlled indexing

0.42 GiB

Final index size

Median of three sequential v1.2.7 trials on deterministic synthetic CC0 data in hash-only mode. These are scale and footprint measurements, not semantic quality or agent outcomes. Hardware, repository shape, index state, and load affect absolute results.

45 language/file types, 24 Tree-sitter ASTs

Tree-sitter sources get function/class-level chunks. Other supported files use heuristic chunks.

Tree-sitter AST 24 languages

Rust Python Go JavaScript TypeScript Java C C++ C# Scala Kotlin PHP Ruby Swift Elixir Zig Bash Haskell OCaml Lua Dart Objective-C Perl Starlark macros/targets

Heuristic chunking 21 more

Nim Groovy Erlang Clojure R Julia PowerShell SQL Protobuf Thrift GraphQL Terraform Dockerfile Makefile Markdown HTML CSS XML Config JSON Text

MCP for coding agents

Use MCP search to find code. Set output=context_pack, optional since=main, and a token budget to build the same context pack available from CLI and Web.

One-command setup

The installer preserves existing configuration, verifies MCP, and runs a search.

Claude Code

ig agent install claude

Codex

ig agent install codex

Cursor

ig agent install cursor
ig agent doctor

Manual MCP setup

Claude Code

claude mcp add -s user ig -- ig --mcp

OpenAI Codex

codex mcp add ig -- ig --mcp

Gemini CLI

gemini mcp add --scope user --transport stdio ig ig --mcp

Cursor

{"mcpServers":{"ig":{"type": "stdio", "command": "ig", "args": ["--mcp"]}}}

OpenCode

{"mcp":{"ig":{"type": "local", "command": ["ig", "--mcp"], "enabled": true}}}

MCP search settings

Pass the absolute repository or worktree path to ig_search. Use a natural-language query for concepts, literal=true for identifiers, or output=context_pack with since=main and budget_tokens=8000 for implementation context.

The first search creates an index and starts incremental watching. Worktrees reuse one shared base index and store only divergent chunks and tombstones.

MCP search flow

Agent sends query
"find error handling logic"
ig searches index
BM25 + Vector + Literal
Returns top chunks
Function bodies, classes, imports
Agent gets context
Without loading entire files

Contributing

Choose a scoped issue, run the relevant checks, and keep the pull request focused.

Start small

Pick a scoped issue with setup and validation guidance.

Good first issues

Discuss larger changes

Use Discussions for questions and designs that affect storage, ranking, or compatibility.

Discussions

Open a pull request

Follow the contributor guide and include the checks that cover the change.

Contributor guide

Install ivygrep

The shell installer selects CUDA only on compatible NVIDIA Linux x86_64 hosts with the CUDA 13 runtime, and Metal on Apple Silicon. Homebrew uses portable builds on Linux and Intel macOS, and Metal on Apple Silicon. GPU builds only speed up transformer profiles (IVYGREP_MODEL_PROFILE=code|code-hq|general); the default potion-code-16m-v2 profile runs on CPU. Run ig hardware to inspect the selected build.

Homebrew for macOS and Linux

$ brew install bvolpato/tap/ivygrep

Metal on Apple Silicon for transformer profiles. Portable on Linux and Intel macOS.

Shell installer for Linux and macOS

$ curl -fsSL https://raw.githubusercontent.com/bvolpato/ivygrep/main/install.sh | sh

Selects CUDA only on Linux x86_64 with a supported NVIDIA GPU and complete CUDA 13 runtime; selects Metal on Apple Silicon. Other supported hosts use the portable build.

WinGet for Windows

$ winget install --id BrunoVolpato.ivygrep --exact

Portable Windows build. Upgrade with winget upgrade --id BrunoVolpato.ivygrep --exact.

Windows PowerShell

irm https://raw.githubusercontent.com/bvolpato/ivygrep/main/install.ps1 | iex

Portable Windows build. Verifies checksum and updates PATH.

Search once. Build context once.

1

Find code by intent

ig "where is refresh token rotated?"
2

Build bounded task context

ig context "fix refresh-token races" --since main --budget 8000