Your agent forgets the day. This gives it back.
An agent is good at the conversation in front of it and bad at everything before it. A day of work leaves hundreds of messages behind — a preference mentioned once, a decision, a name, an open loop, a correction — and tomorrow the context window has moved on.
minicpm-dream is a nightly pass over that day. It reads the transcript, asks MiniCPM5-2B to pull out what is worth keeping, checks every claim against the words that produced it, and writes the result to a private ledger on your machine. In the morning there is a memory your agent can use and a diary you can read. It runs on your own hardware: no cloud account, no subscription, and no conversation leaves your disk.
The project is at v1.0.0-rc1. The quality numbers below come from the author's own regression tests and are not a general benchmark.
What You Get
- A memory that persists: facts, preferences, projects, people, decisions and open loops, stored with absolute dates and full history.
- A diary, not a dump:
DREAMS.mdsays what was promoted, what changed and what needs a human — in sentences. - Receipts: every stored memory carries the verbatim quote it came from. No quote, no memory.
- Corrections without erasure: a changed fact supersedes the old one; nothing is silently deleted.
forgetleaves a tombstone. - Reviewed writes: new or contested entries go to a review file first. Applying them needs an explicit flag and makes a backup.
Try It With the Mock
No model download needed: the repo ships a scripted mock that runs the whole pipeline offline.
git clone https://github.com/RegeneratusLabs/minicpm-dream
cd minicpm-dream
uv venv .venv && source .venv/bin/activate
uv pip install -e ".[dev]"
minicpm-dream run --source jsonl \
--input evals/synthetic-days/basic/episodes.jsonl \
--backend mock --mock-script evals/synthetic-days/basic/mock_script.json
Then read what it wrote, and ask it why:
cat ~/.local/share/minicpm-dream/DREAMS.md
minicpm-dream search "dentist"
minicpm-dream explain <memory-id>
A trimmed diary entry:
### Promoted
- **preferences** — Josh prefers dark mode in all editors.
↳ "I prefer dark mode in all my editors"
- **open_loops** — Josh has a dentist appointment. (on 2026-11-06)
↳ "dentist tomorrow at 3pm"
### Safety
- loss guard: ok (0→3 entries, 0→152 chars)
- ingest: kept 8/8, redactions 1, quarantined 0, duplicates 0
The last memory shows the split of work. The model was allowed to read "tomorrow"; code resolved it to 2026-11-06 before anything was stored, so the memory does not go stale next week. The quote stays as it was said, because it is the receipt.
How It Works
Hermes state.db ─┐
JSONL export ────┤→ filter/redact → chunk + date anchors → MiniCPM extract
│ ↓
│ evidence verifier
│ ↓
└──────────────→ hybrid retrieval → reconcile (ADD/UPDATE/
SUPERSEDE/MERGE/NOOP/DEFER)
↓
SQLite ledger + DREAMS.md + reviewed Hermes proposals
- Ingest filters noise, redacts secrets, quarantines prompt injection and de-duplicates. It reads Hermes
state.dbread-only, or any JSONL transcript. - Prepare chunks the day and resolves relative dates ("tomorrow", "last Saturday") into absolute dates in code, not in the model.
- Extract asks the model for typed memories, one constrained JSON call per chunk.
- Verify rejects any memory whose quote is not present in the source turn.
- Reconcile decides ADD, UPDATE, SUPERSEDE, MERGE, NOOP or DEFER against what is already known, and escalates uncertain decisions for review.
- Apply writes a bitemporal SQLite ledger, a daily
DREAMS.md, and (for Hermes) reviewed proposals rather than direct edits.
Built for a Small Model
A 2B model should not be trusted to invent dates, silently delete memories or decide merges alone. So the protocol is narrow and the safeguards live outside the model: dates are resolved in code, every memory needs a verbatim quote, merges are checked for invented numbers, supersession keeps history, and uncertain operations become review items instead of writes. A run that would drop more than 25% of active memory is rolled back.
Hermes Agent is the first adapter. The core is harness-agnostic: any transcript that exports to JSONL works.
Install for Real
Default model: MiniCPM5-2B Q4_K_M (about 1.56 GB, 131K context).
minicpm-dream setup --download # download + checksum the GGUF
minicpm-dream setup --download-embeddings # optional OpenBMB retrieval models
minicpm-dream doctor
minicpm-dream run --source hermes --window day --dry-run
minicpm-dream run --source hermes --window day
Inference uses llama.cpp's llama-server, or any OpenAI-compatible endpoint such as vLLM, SGLang, Ollama or LM Studio. On the reference machine (6-core i5-8500T, 15 GB RAM, no GPU) a dense day takes roughly 5–7 minutes in quality mode; --fast trades recall for time.
Model stack:
| Tier | Model | When |
|---|---|---|
| Default | MiniCPM5-2B Q4_K_M | CPU/local nightly pass |
| Cheap verifier | MiniCPM5-1B Q4_K_M | Second opinion / triage |
| Quality | MiniCPM4.1-8B Q4_K_M | GPU or weekly deep pass |
| Long context | MiniCPM-SALA | Whole-week pass on a large GPU |
| Embeddings | MiniCPM-Embedding-Light | Local hybrid retrieval |
| Reranker | MiniCPM-Reranker-Light | Local reranking |
Results and Limits
On a 24-message / 14-fact synthetic day, the optimised 2B pipeline reaches 0.80–0.97 F1 (best run P 0.93 / R 1.00 / F1 0.97 in 334 s), versus 0.81–0.90 for DeepSeek Flash. The remaining gap is run-to-run variance. The author stresses these are regression comparisons on one synthetic scenario, not a benchmark.
Known limits:
- A 2B model can still miss a fact, over-compress a quote or choose a wrong operation. The design turns those failures into rejections or review items, not silent bad memory.
- Quality mode costs several minutes for a dense day on a CPU; cloud models are 10–20× faster.
- English is the primary tested language; other languages need their own eval fixtures.
- No encryption at rest; use full-disk encryption if that matters.
- No HTTP server or web UI; the CLI and JSONL are the integration surface.
This is a community project under the MIT license. Model weights are downloaded separately under their own licenses.
Links
- GitHub: RegeneratusLabs/minicpm-dream
- Author's post on X: @RightSideOfAI
