← cerebral.work cerebral.work
project · editor experiment · zed fork

dreamcode

Dreamcode is the editor experiment attached to reverie — a place to test what context-aware editing actually feels like in daily use, when the agent in the side panel never starts with a blank slate.

Reverie is a daemon. Without an editor that knows how to talk to it, most of its value lives in HTTP traces. Dreamcode is the answer to the question we kept asking ourselves: if memory were really solved, what would change about the editor? It’s a fork of Zed, in development since April 2026, that wraps every agent in reverie’s context, persists planner state across prompts, and exposes the daemon’s live activity as a first-class view. Single contributor, dev channel, no tagged release yet — a research-grade artifact, not a product launch.

What changes from upstream Zed

Two new components and one piece of middleware. Everything else — the editor, the workspace, the agent panel, the language-model registry — is unmodified upstream Zed. We are not trying to out-design Zed. We are trying to find out what an editor with a memory feels like.

A reverie-backed agent

A new agent backend that runs reverie’s deep-agentic planner inside the editor instead of routing each prompt to a single-shot LLM call. The planner’s nested subagent activity streams back into the parent chat as it happens, so you see the agent thinking in structure rather than waiting for a monolithic answer. Cancellation is responsive in milliseconds — a small but load-bearing piece of UX when the agent is doing real work on your behalf.

Memory middleware on every agent

The structurally interesting move. A small wrapper around any Zed agent connection — Claude, Gemini, OpenAI, Zed-native, custom — calls the reverie daemon before each prompt to pull relevant memory, and writes back a summary after each completion. The result: every agent in the editor inherits memory continuity, not just reverie’s own. The agent you already use suddenly remembers what it learned last week. If reverie isn’t running, dreamcode degrades quietly — no spinners, no broken UX, one log line per session.

A live dream inspector

A bottom-dock panel that polls the reverie daemon’s event stream and shows what’s happening inside the system in real time — observations being saved, retrievals being served, consolidation phases firing. The same telemetry surface a daemon operator would watch in a Grafana dashboard, exposed as a first-class editor view. It turns out that being able to see the memory layer changes what people will trust it with.

Session-persistent planner state

Each agent thread keeps its plan and scratch state across prompts in the same session. The planner gets to see what it was working on without re-reading the conversation, and the right division emerges naturally between episodic state (lives in the session) and durable knowledge (goes to reverie).

Why two repositories? Reverie is the daemon — it can run standalone for any client that wants a real memory layer, IDE or otherwise. Dreamcode is the editor that happens to be wired to it. Keeping them separate means reverie is reusable; dreamcode is the reference integration.

Status

← reverie (the daemon side) Get in touch