Skip to main content

Module sqlite

Module sqlite 

Source
Expand description

SQLite+FTS5 persistent storage backend for RAG indices.

Provides SqliteIndex (implements SparseIndex) and SqliteStore (convenience wrapper for document + chunk persistence).

This module replaces in-memory HashMap-based indices with SQLite-backed storage using FTS5 for BM25 ranking (Robertson & Zaragoza, 2009).

§Performance Contract

Median search latency: 10–50 ms on a 5000+ document corpus with warm page cache (see sqlite-rag-integration spec, Section 3.1).

Modules§

fts
FTS5 full-text search with BM25 ranking.
schema
SQLite schema definition and migration logic.

Structs§

SqliteIndex
SQLite-backed sparse index using FTS5 for BM25 search.
SqliteStore
Combined document store + BM25 index backed by SQLite.
StoreStats
Statistics about the SQLite store.