sqlite-graphrag 1.0.78

Persistent GraphRAG memory for Claude Code, Codex, Cursor, and 24+ AI agents in a single 6 MB Rust binary. LLM-only and one-shot in v1.0.78: every `remember` / `ingest` spawns a headless claude code or codex subprocess (OAuth, no MCP, no hooks). No daemon. No ONNX runtime. No model download. Graph-native retrieval with FTS5 + cosine + multi-hop traversal. OAuth-only enforcement: API keys ABORT the spawn.
Documentation
[package]
name = "sqlite-graphrag"
version = "1.0.78"
edition = "2021"
rust-version = "1.88"
description = "Persistent GraphRAG memory for Claude Code, Codex, Cursor, and 24+ AI agents in a single 6 MB Rust binary. LLM-only and one-shot in v1.0.78: every `remember` / `ingest` spawns a headless claude code or codex subprocess (OAuth, no MCP, no hooks). No daemon. No ONNX runtime. No model download. Graph-native retrieval with FTS5 + cosine + multi-hop traversal. OAuth-only enforcement: API keys ABORT the spawn."
license = "Apache-2.0 OR MIT"
repository = "https://github.com/daniloaguiarbr/sqlite-graphrag"
homepage = "https://docs.rs/sqlite-graphrag"
documentation = "https://docs.rs/sqlite-graphrag"
readme = "README.md"
keywords = ["graphrag", "sqlite", "llm", "embeddings", "memory"]
categories = ["command-line-utilities", "database", "api-bindings"]
default-run = "sqlite-graphrag"
include = [
    "src/**/*.rs",
    "Cargo.toml",
    "Cargo.lock",
    "README.md",
    "README.pt-BR.md",
    "CHANGELOG.md",
    "CHANGELOG.pt-BR.md",
    "LICENSE",
    "LICENSE-MIT",
    "LICENSE-APACHE",
    "CODE_OF_CONDUCT.md",
    "CODE_OF_CONDUCT.pt-BR.md",
    "CONTRIBUTING.md",
    "CONTRIBUTING.pt-BR.md",
    "SECURITY.md",
    "SECURITY.pt-BR.md",
    "INTEGRATIONS.md",
    "INTEGRATIONS.pt-BR.md",
    "llms.txt",
    "llms-full.txt",
    "llms.pt-BR.txt",
    "docs/AGENTS.md",
    "docs/AGENTS.pt-BR.md",
    "docs/COOKBOOK.md",
    "docs/COOKBOOK.pt-BR.md",
    "docs/HOW_TO_USE.md",
    "docs/HOW_TO_USE.pt-BR.md",
    "docs/MIGRATION.md",
    "docs/MIGRATION.pt-BR.md",
    "docs/TESTING.md",
    "docs/TESTING.pt-BR.md",
    "docs/CROSS_PLATFORM.md",
    "docs/CROSS_PLATFORM.pt-BR.md",
    "docs/DOCUMENTATION_FRAMEWORK.md",
    "docs/decisions/adr-*.md",
    "docs/decisions/adr-*.pt-BR.md",
    "docs/schemas/*.schema.json",
    "docs/schemas/README.md",
    "skill/sqlite-graphrag-en/SKILL.md",
    "skill/sqlite-graphrag-pt/SKILL.md",
    "rust-toolchain.toml",
    ".cargo/config.toml",
    "benches/**/*.rs",
    "tests/**/*.rs",
    "migrations/**/*",
    "scripts/**/*",
]
exclude = [
    ".serena/",
    ".claude/",
    ".vscode/",
    ".idea/",
    "target/",
    "logs/",
    "memory/",
    "docs_rules/",
    "docs_prd/",
    "docs/CLAUDE.md",
    "docs/CLAUDE.pt-BR.md",
    "CLAUDE.md",
    "AGENTS.md",
    "MEMORY.md",
    "ralph-loop.local.md",
    "*.profraw",
    "*.profdata",
    "*.log",
    "graphrag.sqlite",
    "graphrag.sqlite-shm",
    "graphrag.sqlite-wal",
    "*.sqlite",
    "*.sqlite-shm",
    "*.sqlite-wal",
    "gaps.md",
    "fuzz/",
]

[[bin]]
name = "sqlite-graphrag"
path = "src/main.rs"

[[bench]]
name = "cli_benchmarks"
harness = false

[[bench]]
name = "regression_baseline"
harness = false

[[test]]
name = "loom_lock_slots"
path = "tests/loom_lock_slots.rs"

[dependencies]
# rusqlite pinned at 0.37; upgrade to 0.39 deferred — refinery 0.9.1 (currently
# published) constrains rusqlite to ">=0.23, <=0.38" (refinery_core/Cargo.toml at
# v0.9.1). Native SQLite linking forbids two rusqlite versions in the graph
# (see https://stackoverflow.com/questions/69403524). Reassess when a refinery
# release supporting rusqlite 0.39 ships; tracked for v1.0.41.
async-trait = "0.1"
semver = { version = "1", features = ["serde"] }
ahash = "0.8"
mimalloc = { version = "0.1", default-features = false }
rusqlite = { version = "0.37", features = ["bundled", "blob", "load_extension", "functions", "trace", "backup"] }
# v1.0.76: sqlite-vec REMOVED. All vector search now runs in pure Rust over a
# `memory_embeddings(memory_id, embedding BLOB, source)` table, with cosine
# similarity computed on demand. This eliminates a heavy build-time dep and
# the `load_extension` runtime cost. The `vec` command is now an alias for
# inspecting the embeddings table.
clap = { version = "4.6", features = ["derive", "env"] }
clap_complete = "4"
serde = { version = "1", features = ["derive"] }
serde_json = "1"
tracing = { version = "0.1", features = ["attributes"] }
tracing-subscriber = { version = "0.3", features = ["json", "env-filter", "fmt", "ansi", "registry", "tracing-log"] }
refinery = { version = "0.9", features = ["rusqlite"] }
# v1.0.76: siphasher pinned to 1.x to compute migration checksums in
# the `migrate --rehash` subcommand. Same algorithm and same version
# that refinery-core 0.9.1 uses internally (SipHasher13 over
# name | version | sql). Without this dep we would have to vendor the
# SipHasher13 implementation; the dep is already in the build graph
# transitively, so this entry only makes the link explicit.
siphasher = "1"
anyhow = "1"
thiserror = "2"
blake3 = "1"
directories = "5"
# fastrand: dependency-free PRNG for jitter (H7+M7); MSRV 1.36, ~30 LOC, no transitive deps
fastrand = "2"
fs4 = { version = "0.9", features = ["sync"] }
interprocess = "2"
regex = "1"
tokio = { version = "1", features = ["rt-multi-thread", "sync", "time", "io-util", "macros", "process"] }
tokio-util = { version = "0.7", features = ["rt"] }
chrono = { version = "0.4", default-features = false, features = ["clock", "serde"] }
chrono-tz = "0.10"
sysinfo = { version = "0.32", default-features = false, features = ["system"] }
ctrlc = { version = "3.4", features = ["termination"] }
# Pin preventivo — constant_time_eq 0.4.3 bumped MSRV para 1.95.0 em versão patch.
# Entra como dep transitiva de blake3 (range ^0.4). Sem este pin, `cargo install`
# sem --locked resolve 0.4.3 e quebra a instalação em toolchains 1.88..1.94.
# Reavaliar quando CI passar em 1.95 e `rust-version` avançar para 1.95.
constant_time_eq = "=0.4.2"
# parking_lot: faster Mutex + deadlock detection in debug builds (P09 parallelism gap)
parking_lot = "0.12"
libc = "0.2"
rayon = "1.10"
text-splitter = { version = "0.30.1", default-features = false, features = ["markdown"] }
# v1.0.76: fastembed, ort, ndarray, tokenizers, hf-hub removed from the
# default build. Embedding generation is now LLM headless only (claude
# code / codex CLI OAuth). The default build is a small, fast Rust
# binary that delegates generation to external processes. Enable the
# `embedding-legacy` feature ONLY for the transition window; the
# feature is removed in v1.1.0.
unicode-normalization = "0.1.25"
tempfile = "3"
sys-locale = "0.3"
wait-timeout = "0.2"
which = "7"

# v1.0.76: legacy fastembed / ort / tokenizers are pulled in ONLY when
# the corresponding feature is enabled. The default build has none of
# these crates in the dependency graph.
fastembed = { version = "5.13.4", default-features = false, optional = true, features = ["hf-hub-rustls-tls", "ort-download-binaries-rustls-tls", "image-models"] }
ort = { version = "=2.0.0-rc.12", default-features = false, optional = true, features = ["std", "ndarray", "tracing", "download-binaries", "tls-rustls", "copy-dylibs"] }
ndarray = { version = "0.16", optional = true }
tokenizers = { version = "0.22", default-features = false, optional = true, features = ["onig"] }
huggingface-hub = { package = "hf-hub", version = "0.4", default-features = false, optional = true, features = ["ureq"] }
# Cargo's `dep:` syntax uses the manifest name, not the package rename.
# We document the rename in a comment so the feature wiring stays
# unambiguous: the `huggingface-hub` line above IS the `hf-hub` crate.

[target.'cfg(windows)'.dependencies]
# G29 (v1.0.68): pinned exact to 0.59.0 because HANDLE type changed
# from `isize` (0.48/0.52) to `*mut c_void` (>= 0.59); future patch versions
# could regress again.  Tracked in Cargo.lock via `cargo update -p windows-sys`.
windows-sys = { version = "=0.59.0", features = ["Win32_System_Console"] }

[dev-dependencies]
assert_cmd = "2"
insta = { version = "1", features = ["json"] }
tracing-test = "0.2"
criterion = { version = "0.5", features = ["html_reports"] }
proptest = { version = "1", features = ["std"] }
tempfile = "3"
predicates = "3"
serde_json = "1"
serial_test = "3"
mockall = "0.13"
wiremock = "0.6"
libc = "0.2"
jsonschema = "0.29"
[target.'cfg(sqlite_graphrag_loom)'.dev-dependencies]
# Só compila quando RUSTFLAGS="--cfg sqlite_graphrag_loom" é passado — previne livelock térmico.
# Incidente 2026-04-19: loom ativado sem gate saturou i9-14900KF em Tjmax 100°C.
loom = "0.7"

[profile.release]
lto = "fat"
codegen-units = 1
strip = true
opt-level = 3
panic = "abort"
debug = false
overflow-checks = false
incremental = false

[profile.release.package."*"]
opt-level = 3

[profile.bench]
inherits = "release"
debug = 1

[features]
# Opt-in for future heavy tests (stress/exhaustive property tests).
slow-tests = []
# Enable parking_lot deadlock detection thread (10s polling interval).
deadlock-detection = ["parking_lot/deadlock_detection"]
# v1.0.76 — Default LLM-only build
# The default build (no features) is the LLM-only build: it does NOT pull in
# fastembed / ort / ndarray / tokenizers / hf-hub. All embedding generation,
# NER, and vector search run in pure Rust over the embeddings table, with
# generation delegated to claude code / codex CLI headless (OAuth, no MCP,
# no hooks). The CLI is one-shot; there is no daemon.
llm-only = []
# v1.0.76 — Legacy fastembed pipeline
# Opt-in for the transition window. Enables fastembed + ort + ndarray +
# tokenizers + hf-hub. Will be REMOVED in v1.1.0; do not depend on this in
# new code. Users on this feature should migrate to LLM-only by running
# `sqlite-graphrag migrate --to-llm-only` and rebuilding with --no-default-features.
embedding-legacy = ["dep:fastembed", "dep:ort", "dep:ndarray", "dep:tokenizers", "dep:huggingface-hub"]
# v1.0.76 — Legacy GLiNER NER
# Opt-in for the transition window. Enables the ONNX GLiNER model loader
# for automatic NER. Will be REMOVED in v1.1.0; users should rely on the
# LLM extraction backend (claude / codex) via ExtractionBackend::Llm.
ner-legacy = ["dep:ort", "dep:ndarray"]
# Full binary with everything (default in v1.0.74, removed in v1.1.0).
full = ["embedding-legacy", "ner-legacy"]

[profile.dev]
opt-level = 1

[profile.dev.package."*"]
opt-level = 2

[lints.rust]
unexpected_cfgs = { level = "warn", check-cfg = ['cfg(sqlite_graphrag_loom)', 'cfg(sqlite_graphrag_miri)', 'cfg(feature, values("embedding-legacy"))'] }