MemLedger uses a small local model to manage agent memory
MemLedger is a memory framework for AI agents that keeps work on the user’s own machine instead of sending conversations to a cloud API. It stores the data in one SQLite file, and the model used for memory tasks can be chosen by the user. The example setup uses Qwen3 4B through Ollama for fact extraction, reranking, and resolving contradictions.
The claim is that a small model can be enough because extracting memories is a controlled JSON task, not open-ended writing. Each memory has a provenance chain, so it can show why that memory exists. For example, a preference like “the user prefers Python” can be traced back to the original sentence, the session, the model, the prompt version, the , and any approval step.
If a memory is wrong, the source record and anything derived from it can be deleted together. The project is .
Key points
- MemLedger handles locally instead of relying on a cloud API.
- It stores memory data in a single SQLite file.
- A small model such as Qwen3 4B may be enough for structured JSON memory extraction.
- Every memory can be traced back to the original conversation and extraction step.
- Wrong memories can be removed along with records that depend on them.