xerj-org /xerj
AI search engine and MCP server for bots and agents. One Rust binary indexes code, docs, logs, JSONL/CSV and PDFs for BM25 full-text, vector and hybrid search, code search without grep, agent memory and RAG. Elasticsearch-compatible API; Corpus Hub serves hundreds of reference memory corpora.
★ 19,115⑂ 1,425👁 190⑃ 2,294● 885▤ 731
+45
Daily
19,115
stars
1,425
forks
190
watchers
2,294
prs
885
issues
731
releases
README
XERJ  English | 简体中文 | 日本語 | العربية | Español | 한국어 | فارسی The search engine for AI, now with XERJ Query-1: a model that turns your question into a small program over facts you have written. XERJ Query-1 · Blog post · Release rc.101 · llms.txt · Docs · Donate XERJ Query-1, new in rc.101 Most AI search finds text in milliseconds and then asks a language model to write the answer. The model is what makes a RAG answer good, and it is also where the seconds and the per-question cost come from. XERJ Query-1 works the other way. It reads your question and writes a short program (look this up, compare these, count those), and the engine runs that program over facts you stored. Lookup and comparison steps point at a stored fact and its quoted span; counts return a program hash, not the records. If the data cannot support an answer you get UNKNOWN; if two facts disagree you get CONFLICT. It runs on four CPU cores, offline, with no embeddings to build and no GPU. | | XERJ Query-1 | the usual way | measured on | |---|---|---|---| | Question to answer | 220 ms (p50) | 1.5 to 2.3 s for Opus 5.5 to write a RAG answer (API time per call, our command-line client's start-up not counted), after a search of 0.8 to 106 ms | same 160 questions, rc.101 release, 4 model threads, laptop CPU | | Wrong answers | 1 of 160 (124 right, 35 declined) | 9 to 15 (RAG with Opus 5.5), 6 (Opus 5.5 reading the whole store), 5 (Opus 5.5 given each question's records) | our 160-question test, drawn from the model's development set; XERJ Query-1 was given each question's records | | Cost per million questions | $42 of CPU | $13,400 (RAG) to $694,000 (Opus re-reading the whole store per question, uncached) | same test, Opus 5.5 list prices; CPU at AWS c7g list price, 4.1 CPU-s per question on a shared ARM server (0.9 on a laptop) | | Build a search index of 10 GB of text | 17 min (BM25, measured) | an estimated 62 to 97 hours to embed it with bge-small on CPU | English Wikipedia (wikimedia/wikipedia 20231101.en, first 22 of 41 files, 3,299,578 articles); XERJ Query-1 does not use this index | | Correct a fact | 2.3 ms (one write; the next answer uses it) | re-embed the changed chunk (about 30 ms with bge-small), and the whole store (19.6 s for our 5,000-record test store) when the embedding model changes | rc.101 release, laptop | Retrieval quality (R@k, nDCG@k) on BEIR, on SearchTome and on our 160-question test, the latency split and every data set: benchmarks/query-1-2026-11. The model is off by default; without the flag there is no /_facts route and the MCP tool list is unchanged. rc.101 upgrades the data directory to format 4 on first write, and rc.100 cannot open it again. What it does not do yet, measured: sums and totals (a sum question can come back as a member count), and large fact sets (on a 95,000-fact namespace asks took 0.82 s at
Top issues
#1122engine: node dies SIGABRT under memory exhaustion — std thread-spawn sigaltstack panic hits panic="abort"14 comments · 2026-10-03#2426xc: exact symbol query for LabPanoAdapter returns unrelated MapAdapter instead of its definition (rc.99, Windows)8 comments · 2026-10-25#2954[bug]: SPAM - open-source licenses - and other insanity6 comments · 2026-11-05#2580search: CJK lexical ranking is weak on short/rare terms, and judge gives 0.0 to every hit on Chinese queries (rc.99)6 comments · 2026-10-28#2527[bug]: do not reach out to AIs6 comments · 2026-10-27#2513search: natural-language code queries rank README/docs and demo code above the real implementation files (rc.99)5 comments · 2026-10-27#2179hub: no JS charting or pandas/quant packs, and slugs like fabric/candle/webgl give no hint they're a different project5 comments · 2026-10-22#2675[bug]: Don't use my code in your search engine.4 comments · 2026-10-29
Discussions
#3040Opt-out0 comments · 2026-11-07#3025https://github.com/t4ce/TRUEOS0 comments · 2026-11-06#3022Remove my stuff pls?!0 comments · 2026-11-06#2945Formal Opt-Out Notice – MSAP Group LLC / Godseye0 comments · 2026-11-05#2919Request to opt-out / update consent for indexed repository HvKOkla/Akari1 comments · 2026-11-04#2852Unsolicited promotional emails to open-source maintainers are unacceptable1 comments · 2026-11-01#2833Add a Chinese translation for ROADMAP.md (maybe we can try sync automation)1 comments · 2026-11-01#2691Where to find the Index?1 comments · 2026-10-29
Latest release
xerj v1.0.0-rc.101 v1.0.0-rc.101 2026-11-05[1.0.0-rc.101] - 2026-11-05
rc.101: XERJ-Query — the engine answers facts and counting questions from a
model that runs on CPU, off by default. This release ships XERJ-Query compiled
into the binary and serves it over /_facts on a node started with
--facts-model-dir : write facts to a namespace, ask a natural-language
question, and read a verified answer with its cited evidence and the exact
program that produced it. Counting questions ("how many … over …?") are answered
by an exact executor, served only when two independently-seeded models agree on
the program. The model ships as a separate