The Dreaming Agent: Three-Level Memory with a Small Model (and the Naive RAG That Beat It)
I turned LightMem's memory architecture into a demo: an agent that stores facts as it talks and that, when you ask it to "dream", consolidates its memory —merging, updating, promoting and forgetting— as a visible diff. Fully local, with 3B and 7B models. I measured it against a naive RAG with three runs per condition, and it lost: 79 vs 88 % with 7B, 58 vs 93 % with 3B. This post covers what I built, where it breaks, and why, with small models, the best memory turned out to be the one that rewrites the least.