Favicon of XERJ

XERJ

A local AI search engine that indexes code, documents and data offline on Linux, macOS and Windows, with an Elasticsearch-compatible API.

Screenshot of XERJ website

XERJ is a local search engine for developers building AI agents that need to retrieve code, documents or stored knowledge without reading whole files into their context. It runs on a laptop or self-hosted server.

  • Code retrieval finds definitions, signatures and file locations using tree-sitter parsing, so coding agents can consult implementations in related repositories before writing code.
  • Mixed folder indexing handles code, PDF, DOCX, SQLite, CSV and logs, detects formats from their contents and infers field types; interrupted indexing can resume.
  • Hybrid search combines keyword and vector retrieval in one engine, with a built-in offline embedder and alternatives for neural encoding or an external embedding provider.
  • Agent memory and graph stores knowledge in separate agent namespaces and provides a knowledge graph with evidence attached to its links.
  • Elasticsearch compatibility lets existing client libraries and Kibana query the engine through its HTTP API.

XERJ is open source under Apache 2.0 and runs on Linux, macOS and Windows. Its default embedding works fully offline without signup or an external embedding key, but uses lexical feature hashing: matches depend on vocabulary overlap rather than neural understanding. Choosing an external embedding proxy sends that work to another provider.

Reference coding is most useful for private or unfamiliar code. It can offer little benefit, or worsen results, for public libraries a model already knows. API compatibility also has limits: scroll queries that exceed its bounded snapshot window are rejected.

Similar to XERJ