08. Extending Matcha

Memory

Memory is a **local** store of notes and session metadata under ~/.matcha/memory/. You turn it on for a session, save a fact with /remember, browse the files with /memory, and clear them from the shell. Nothing here is a MatchaCode cloud memory service.

Turn memory on

Memory is **off** by default. Enable it in one of these ways (first match wins):

  1. matcha --no-memory — always off
  2. matcha --experimental-memory — on
  3. MATCHA_MEMORY=1 or 0
  4. [memory] enabled = true in ~/.matcha/config.toml
  5. Default: off

Mid-session toggle

/memory on
/memory off

Alias: /mem. The toggle is **session-scoped**. It does not rewrite config.toml. Off removes the memory tools for this session and leaves files on disk. On re-initializes local storage and registers the tools again.

/memory with no argument opens the browser (needs a configured memory destination, even if you currently have it toggled off). In that modal, t is the same on/off toggle.

Save a note: `/remember`

/remember is always in the slash menu.

/remember always open PR links after pushing

With no text, Matcha CLI enters remember mode (the prompt shows a remember accent). The next line you type becomes the note.

A review panel opens. Confirm to write. On save you should see something like Memory saved to ~/.matcha/memory/MEMORY.md. Project-specific notes go in the workspace MEMORY.md; cross-project preferences go in the global file.

You can also say “remember …” in ordinary chat. The durable copy is still the Markdown file. For a guaranteed delete, edit the file yourself (or use matcha memory clear). Asking the assistant to “forget …” is best-effort.

What is on disk

PathScope
~/.matcha/memory/MEMORY.mdGlobal
~/.matcha/memory/<project-slug>-<hash8>/MEMORY.mdThis workspace
…/sessions/Per-session metadata logs

Clones and worktrees that share the same git origin (org/repo) share one workspace directory. Otherwise the hash is from the directory path.

When a session ends, Matcha CLI may append a **metadata** summary (message counts, a few topics, UTC time) **without** an LLM call. Trivial sessions are skipped. That is local bookkeeping, not /flush.

A file watcher reindexes edits you make in an editor. The preview in /memory is read-only; edit the path you copy with y.

Browse: `/memory`

/memory

Split view: file list (Global / Workspace / Sessions) and a preview. Narrow terminals hide the preview.

KeyAction
/ or j/kMove
/Filter
yCopy the selected path
x twiceDelete a **session** file only
tToggle memory on or off
EscClose

Clear from the shell

matcha memory clear
matcha memory clear --workspace
matcha memory clear --global
matcha memory clear --all
matcha memory clear --yes

Default scope is workspace (MEMORY.md, sessions/, and the local index). --yes skips the confirmation prompt.

What is not available

SurfaceWhy it is out
/flushLLM session summary — not a supported procedure
/dreamLLM consolidation — not a supported procedure
Auto-dream / embedding configSame inference family
Vector “semantic” search setupNeeds embedding inference

To keep a fact, use /remember (or edit MEMORY.md). To drop a store, use matcha memory clear or delete the file.

What you should see

You ranResult
matcha --experimental-memory then /memory on“Memory enabled for this session.”
/remember always use conventional commits then confirmMemory saved to ~/.matcha/memory/…
/memoryFile list + preview
/flush or /dreamNot a supported procedure