Repository navigation
Releases
v0.3.9: Claude Code plugin, locked runtime
sqlite-graph-memory is now installable as a Claude Code plugin. The plugin starts the memory server through a locked uv script, so what runs on your machine is what we tested. A settings index now wins over a stray shell env variable, and Hugging Face telemetry is off by default. Also in this release: a privacy policy linked from the plugin manifest, sgm-doctor fixes from review (thanks @Kaap10), sgm-stats reads every YAML form of type, and recall resolves folder-qualified and .md wikilinks.
Full list: CHANGELOG.md. PyPI publishes from this release through the trusted-publisher workflow.
v0.3.8: superseded_by through the entity gate, --pool, plain-rag and mempalace rows
Six changes, five of them from one outside contributor in one week. Thank you, @Jason-Vaughan.
Recall
superseded_bylinks are followed even when the entity gate suppresses general wikilink expansion, so an outdated note still leads to its replacement (#94, picked up #93).sgm-ask --pool N(orBRAIN_TOPK_RETRIEVE=N) overrides the dense candidate pool without changing the 60-note default (#97, picked up #92).
Bench and eval
plain-ragreference row: dense cosine-only baseline, no graph hop, no reranker, reproduced in CI (#91, picked up #21).mempalacerow: MemPalace 3.11.0 with its defaults under the shared extractive answer floor, R@5 0.82, answer 0.42, never abstains (#100).eval/run_ablation.pyreportsgate_rate,hop_applied_rateandrank_churnper cell (#95, picked up #93).eval/build_gold.pyadds a shortheadingquestion class; existing classes and published numbers reproduce unchanged (#96, picked up #93).
Install: pip install 'sqlite-graph-memory[lite]==0.3.8' (torch-free) or [embeddings] for a GPU. Full text in CHANGELOG.md.
Open and unclaimed today, good first issues: #103, #104, #105.
v0.3.7
Recall: the cross-encoder rerank is off by default. sgm-ask, the MCP tool and eval/run_eval.py now order candidates by dense e5 similarity; --rerank or SGM_RERANK=1 brings the cross-encoder back. Measured before the change: on our 184-question gold set the reranker cut body nDCG@12 from 0.815 to 0.640, and on DolphinBench data (Riley, 50 tests, 1000 sessions) Recall@5 fell from 0.61 to 0.48; it still helped short title-style queries. Dense recall is also faster on CPU (about 0.04 s against 2.8 s per query on that slice). rerank_candidates() takes sims= and keeps dense order when no cross-encoder is passed.
uvx install lines work on a newer default Python. On an Intel Mac whose uv defaults to Python
3.14, uvx --from 'sqlite-graph-memory[lite]' ... fell back to release 0.3.5, which has no [lite], and
sgm-index stopped with a hint to install [embeddings]. Apple Silicon below macOS 14 resolves the same
way. The uvx lines in the docs now pin --python 3.12; server.json does too, and that reaches the MCP
Registry with this release.
Shorter demo gif. It now shows the top 5 of each list, so the graph hit fits on one screen.
sgm-index: a rerun re-embeds only what changed. A manifest keyed on the content hash and the index settings lets sgm-index skip untouched notes; size and mtime are the fast path, the hash decides the changed set, and a corrupt manifest falls back to a full build. The default encoder still comes from load_encoder(), so [lite] installs keep working without torch. Thanks @Jason-Vaughan (#85), who picked up #17.
Recall: folder-style wikilinks resolve in the graph hop. [[folder/note]] links now reach their note in expand_1hop the same way sgm-stats counts them, preferring the exact vault-relative path; the vault root is computed once per index, not per link. Thanks @Jason-Vaughan (#84), who picked up #71.
Bench: tangleclaw-style reference row. A stdlib-only pipeline (BM25 + FTS5 + 1-hop wikilinks + superseded_by lineage) in the style of TangleClaw's markdown continuity, reproduced in CI. Same R@5 as bm25; its gain is on superseded decisions and abstention, with no domain words in the abstention gate. Thanks @Jason-Vaughan (#87), who picked up #21.
eval/run_ablation.py: one run sweeps the retrieval knobs. Scores a grid of cells (hops, ghops, gmax, topk, entity gate) on one gold file, reusing the same pipeline functions as sgm-ask and the metrics from run_eval.py; the dense pass runs once per question and each cell slices the widest pool, so only the rerank repeats. The default grid changes one axis at a time against 1-hop; --grid takes multi-axis cells. Thanks @Jason-Vaughan (#86), who picked up #19.
Light backend: a fallback to torch is no longer silent. When the ONNX models fail to load and recall falls back to torch, the answer now starts with a NOTE: line naming the reason and pointing at sgm-doctor. Through MCP the agent sees only the answer, so the stderr line alone hid the slow path (#89).
Docs: install commands use [lite]. Now that v0.3.6 is on PyPI with the [lite] extra, README, llms.txt and the example MCP config install the torch-free stack; [embeddings] stays documented for a GPU.
v0.3.6: light backend, recall without torch
Light backend: recall without torch. New extra [lite] runs the same two models (multilingual-e5-base and the mMiniLMv2 reranker) on ONNX Runtime from their official ONNX exports: 155 MB installed instead of ~2 GB, and on the hub one MCP recall took 7.0 s instead of 33.8 s through torch, with the same hits and scores (embeddings agree to 3e-7). It is picked automatically when installed; SGM_BACKEND=torch|onnx forces either, and an index built by one backend works with the other. pick_device() no longer imports torch on this path: on a Windows CPU laptop that import alone took 44 s and pushed the first MCP call past the client's tool timeout (2026-11-01). Models stay in the persistent Hugging Face cache (SGM_MODEL_CACHE overrides), and sgm-index fetches the reranker too, so the first recall is not also a download. sgm-doctor reports the light backend. Install commands in README keep [embeddings] until [lite] is on PyPI.
sgm-turnstate-show: a corrupt ledger gets one line, not a traceback. When TURNSTATE_DB is not a SQLite file the command now prints not a database: <path> on stderr and exits 1, leaving the file untouched; a missing ledger keeps its friendly line. Thanks @ShahadatTest (#77), who picked up #74.
sgm-stats: a wikilink inside inline code is no longer a graph edge. _links_in already ignored fenced blocks; it now ignores inline code spans too, so an example like `[[x]]` stops inflating the link counts. Thanks @bfs2021 (#78), who picked up #72.
sgm-stats --json on an empty folder prints JSON. A cron script that parses the output now gets an object with verdict: fail, exit_code: 2 and an error field instead of plain text; the exit code stays 2 and plain mode is unchanged. Thanks @sharmao07 (#79), who picked up #73.
--version on sgm-stats and sgm-ask. Both print the package version and exit 0; sgm-ask answers before it touches a model or an index. Thanks @BiswasNehaa (#81), who picked up #75.
v0.3.5: first PyPI build since v0.3.3, MCP recall default 180 s
Release fix. v0.3.4 was tagged but never reached PyPI: the release commit changed only this file, and the publish job stopped on its version check (pyproject, __init__, server.json still said 0.3.3). v0.3.5 is the first PyPI build with everything listed under v0.3.4 plus the entries below, with the version set in all four places.
MCP: recall no longer dies on the first cold call. The default deadline is now 180 seconds (was a fixed 60): on a clean Windows install one CLI recall took 89 s, so the first MCP call timed out. BRAIN_RECALL_TIMEOUT overrides it; valid values are integer seconds from 1 to 600. Invalid values return a visible configuration error without starting recall. Timeout errors name the actual configured deadline. Reproduced during a clean Windows installation: CLI recall succeeded while the MCP child hit the previous fixed 60-second deadline.
Tests: tilde expansion isolated on Windows. The test sets the Windows home directory as well as the Unix home directory. It now checks the temporary profile on Windows instead of writing a marker into the real user's profile.
Docs: preserve an existing agent setup. README links to the existing-setup guide in second-brain-starter-kit, covering per-client memory installation and fresh-chat acceptance without replacing the owner's rules.
sgm-doctor: one command that checks a fresh install in plain words. Python, SQLite, numpy,
torch and sentence-transformers, the two models in the local cache, and your index, each with an
ok/warn/fail verdict and the fix printed next to it; exit 1 when anything fails. On an Intel Mac
with NumPy 2 it names the pairing that crashes indexing instead of a bare import error.
v0.3.4
Credit, written down at last. Four outside pull requests merged since 19.10 and none was named
here. Thanks to @Kaap10: the MCP server now answers non-object JSON
payloads with -32600 Invalid Request instead of failing (#32, closes #22), and finds its
brain_ask sibling and passes a non-zero exit through in test mode (#33, closes #24). Thanks to
@Vamsi-2581: a missing embedding index is now reported as an error
instead of passing silently (#35). Thanks to @Khushbu677: tests for
the turnstate hook's ledger writes (#57). From now on scripts/credit_gate.py runs in CI and goes red
when a merged outside PR has no line here, or when a @handle here does not exist; the rules are in
CONTRIBUTING.md.
Also in this release. Benchmark adapters for four external memory systems (fidelis, mem0 local, second-brain, SQLite FTS5) with CI reruns pinned to one Ollama build and one CPU kernel, and CI guards that freeze released CHANGELOG sections and fail on unreadable tags, pre-release tags and duplicate headers.
v0.3.3: hidden-file and MCP script-mode fixes, feedback form
Install: pip install sqlite-graph-memory==0.3.3 · MCP: uvx sqlite-graph-memory · registry io.github.tonydzi/sqlite-graph-memory. Thanks to @Kaap10 for both bug reports.
v0.3.2: PageRank lane, sgm-stats, llms.txt
The PageRank lane the README credits is now in the package. Personalized PageRank over the [[wikilink]] graph, fused with the reranker by RRF; off by default (SGM_PPR=1 or sgm-ask --ppr), any failure falls back to the reranker's order.
Also: sgm-stats (four health numbers for your link graph, exit codes for cron), BITEMPORAL.md (a pasteable close-don't-delete spec), llms.txt, MCP fixes for non-object JSON payloads and missing index errors, pinned CI actions with Dependabot. Kept at 0.3.x on purpose: the second-brain plugin pins >=0.3.1,<0.4.
Full detail in CHANGELOG.md.
v0.3.1 - MCP Registry listing, Intel Mac fix, credit to Kaap10
Credit where it is due. The MCP server that ships as sgm-mcp was written by Vardhman Gupta
(@Kaap10) in PR #8: the server, its tests and its docs. His
follow-up fixes are the shared answer-file race (commit 3ce7061), the stdout fallback (PR #10)
and the swallowed read errors (PR #14).
He is now listed in the authors field of pyproject.toml, which is the attribution he asked for.
Indexing works on Intel Macs again. A fresh pip install 'sqlite-graph-memory[embeddings]'
on an x86_64 Mac with Python 3.12 crashed sgm-index with NameError: name 'nn' is not defined. Torch stops at 2.2 there, transformers 5.x needs 2.6 and quietly disables torch,
and sentence-transformers 6.x requires transformers 5.x. The embeddings extra now caps
transformers below 4.50 and sentence-transformers below 5 on that one platform. Measured
both ways on the same machine: 0.3.0 from PyPI crashes, this build indexes the 202-note
bench vault cleanly (204 chunks).
Listed in the official MCP Registry. server.json describes the server as
io.github.tonydzi/sqlite-graph-memory, the README carries the mcp-name line the registry
checks, and the publish workflow lists the release after PyPI has it. The package also
installs the MCP server under its own name, sqlite-graph-memory, so registry clients can
start it with uvx.
The README opens with three commands and their real output on the bench vault, including
the honest caveat that vector-only ranks ahead of graph mode on that vault overall.
Reviewed by @Kaap10. Installs: pip install sqlite-graph-memory==0.3.1 · MCP: uvx sqlite-graph-memory · registry: io.github.tonydzi/sqlite-graph-memory.
v0.3.0 - pip install sqlite-graph-memory
Release record, added 2026-10-16: the package went to PyPI on 2026-10-15 and this GitHub release object was cut a day later, so the tag points at a commit slightly after the upload (it adds only the workflow's skip-existing flag). Also in 0.3.0 as uploaded: the embeddings extra pins numpy<2 on Intel Macs, where torch stops at 2.2.
You can install it now. For three months this was a repository you had to clone, and for
an engineer deciding whether to try something, a clone is a much bigger ask than a command.
There is now a pyproject.toml, the modules live in src/sqlite_graph_memory/, and
pip install sqlite-graph-memory gives you five commands: sgm-index, sgm-ask,
sgm-mcp, sgm-turnstate-hook and sgm-turnstate-show.
The MCP server moved inside the package. It used to sit in examples/ and shell out to
../brain_ask.py, which meant the one integration most agents actually use — the MCP tool —
only worked from a checkout. It is now sgm-mcp, so the client config is a command name
instead of a path into someone's clone, and the Stop-hook snippet lost its /path/to/ too.
The heavy half is optional, and says so. The base install is numpy and nothing else,
about 20 MB; sentence-transformers and torch (~2 GB) come from
pip install 'sqlite-graph-memory[embeddings]'. Running the indexer without the extra used
to end in a ModuleNotFoundError traceback through site-packages — which reads like a broken
package rather than a missing option — and now ends in one line naming the extra to install.
tests/test_optional_extra.py covers that path, including the case it must not swallow: an
unrelated missing module still surfaces as itself, instead of sending you after the wrong fix.
CI now proves the package is installable, not just that the tests pass. A wheel can break
without a single test failing — a bad entry point, a file left out of the build, a dependency
that only exists on the author's machine. The new installable job builds the distributions,
runs twine check, installs the wheel into a venv with nothing else in it, and checks that
all five commands start, that schema.sql travelled with the wheel, and that a base install
prints instructions rather than a traceback.