opencontext-memory
SQLite + FTS5 memory store and 19 MCP-style tools for OpenContext Runtime.
This package is the concrete memory backend the conductor (opencontext-sdd)
and the CLI (opencontext memory v2 …) read and write through. It is local
only — no network, no cloud sync, no third-party drivers — and rides the
Python 3.12 stdlib sqlite3 (FTS5 is built-in on the supported versions).
Public exports
from opencontext_memory import MemoryStore, WriteQueue
Storage shape
The canonical schema lives in
opencontext_memory/store/schema.sql
and is the single source of truth for tables, indices, and the FTS5 virtual
table. MemoryStore loads it on first open.
| Table | Role |
|---|---|
observations |
Canonical row store (id, sync_id, …, deleted_at) |
observations_fts |
FTS5 mirror of observations(title, content) |
memory_relations |
7-verb × 4-status typed relations |
sessions |
mem_session_start / mem_session_end |
Cross-process safety
Concurrent writers in the same process serialise through a per-connection
lock; concurrent writers across processes serialise through WriteQueue,
which uses fcntl.flock on POSIX and a msvcrt-compatible lockfile on
Windows.
Mock LLM
The package never makes network calls. The tests/conftest.py autouse
fixture asserts no real LLM env vars are set during test execution so future
tool surface inherits the same guarantee.
Metadata
Release files for opencontext-memory 2.0.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| opencontext_memory-2.0.1-py3-none-any.whl | Python 3 | none | any | Details |
Release files / opencontext_memory-2.0.1-py3-none-any.whl
| Download URL | opencontext_memory-2.0.1-py3-none-any.whl |
|---|---|
| Size | 59.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
5ac1f647ef4b533bb3d69ae4e30333cd251f1cf7a3c3ad239bcc2030a9cc6816
|
|
BLAKE2b-256 checksum How to use checksums |
91aad303f35bc633fda62aafd034eb2feee5e15a133a8e7d19938ae32cab59c3
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.14
|