Guides

Architecture

How GNO is built — Bun, SQLite, local models, and the shared retrieval core.

GNO is a Bun-compiled TypeScript application with a SQLite-backed index, local model inference via node-llama-cpp, and a shared retrieval core that every surface (CLI, Web UI, SDK, REST API, MCP) plugs into.

Runtime

Storage layout

Surfaces

Every GNO surface speaks to the same shared retrieval core:

Data flow

  1. Ingestion — file walker reads sources, parsers extract text + frontmatter, chunker splits into retrievable units
  2. Embedding — chunk text is encoded to dense vectors via the chosen embedding model
  3. Indexing — chunks land in SQLite FTS and sqlite-vec tables; docs, links, and tags land in relational tables
  4. Retrieval — query enters the pipeline, hits BM25 + vector, merges, reranks, returns
  5. Answer — for ask, the top matches go to the local LLM with a citation-preserving prompt