Local AI search for coding agents
Same score. 2.7x fewer tokens.
XERJ indexes any folder so a coding agent pulls the passage it needs instead of reading files one by one. In the project's controlled study it matched a grep-driven agent's 16 of 16 solved runs on 2.7x fewer output tokens.
Reference coding: output tokens, cost and solve rate
8 tasks · 4 languages · 16 runs per armclaude -p token counts; users report roughly 5x fewer tokens in everyday work.Where it helps
The gain depends on what the model already knows.
XERJ helps most when the code is new to the model. The README states the limit as plainly as the win.
Code the model has not memorised
- Private and internal code
- Niche projects
- Code written after the model's cutoff
Code it already knows
- Popular public libraries the model has already seen
“The value is gated by memorisation.” — the README
Feed it any folder
One command indexes code, docs, logs and PDFs.
XERJ works out what each file is and builds one typed index per dataset, with code symbols and line numbers from tree-sitter. Any Elasticsearch client can query it.
$ xerj --insecure --data-dir ./data &
# wire XERJ into Claude Code/Cursor (MCP + skill)
$ xerj init
$ xerj autoindex ~/my-project
# ranked passages, file:line
$ xerj search "how do we rotate the WAL segment"
# go-to-definition: file:line + signature
$ xerj def "euler_to_rotationmatrix"
# what it did for you - counted, not estimated
$ xerj gain
phase A: 593 datasets inferred, 1955 junk/skipped files
phase B: indexing 25329 files with 8 workers
done in 158.1s, 593 datasets, 83103 records live, 790 junk records
An example indexing run from the README: one command, 593 datasets inferred, junk files set aside.
--insecure is for one person on one dev machine.
It turns off TLS and API-key auth, so anyone who can reach the port can read and delete every index. A fresh node binds to 127.0.0.1 only and refuses a cleartext bind on any other interface unless you explicitly allow it.
Membership is one field report.
Run it, then send back one short report: what you pointed it at, what you used it for, and your honest verdict. A negative verdict is a good report.