Skip to main content
Auto memory lets the agent keep its own persistent notes outside a project, so it can recall past decisions, corrections, and gotchas in later sessions instead of relearning them each time.
Disabled by default. Turn it on at Settings > Agent > Enable Auto Memory (under Experimental features).

How it works

When enabled, every session gets a memory directory outside the project, under ~/.bricks-project-desktop/memory/:
  • Project chats — keyed to the project
  • Main Chat — a single directory shared by all Main Chat sessions
  • Worktree chats — share the same memory directory as the project’s main checkout, since memory is keyed to the project rather than the branch or worktree folder. A note saved from a worktree chat is visible from the main checkout’s chat, and vice versa
  • Sub-agents — spawned during a session share that session’s memory directory
MEMORY.md acts as an index. The agent is expected to keep it under ~200 lines and move detail into topic files stored alongside it. At the start of each turn, the first 200 lines (or 25 KB, whichever limit hits first) of MEMORY.md are added to the system prompt automatically; the agent reads topic files on demand with read_file when their subject comes up.

What the agent saves

The agent decides what’s worth remembering — durable, non-obvious facts likely to matter in future sessions, such as your corrections and preferences, decisions along with their reasoning, and hard-won debugging insights. It’s instructed to skip secrets, session-transient details, and anything already covered by AGENTS.md/CLAUDE.md or application.json. You can ask the agent to remember or forget something at any time — it updates MEMORY.md and its topic files the same way it edits any other file.

Tool access

The memory directory sits outside the project, so read_file, write_file, and edit_file can all reach it there, and a memory write bypasses restrictions that normally apply to project files:
  • Not subject to the project sandbox’s write restrictions
  • Not blocked by Plan mode — the agent can still save a memory note while Plan mode otherwise limits it to read-only
  • Doesn’t trigger diagnostics or notify the running app — a memory write is invisible to the simulator and Config Editor, the same as a skill file
When the sandbox is on, the memory directory is added to the sandboxed read and write allowlists automatically, so sandboxed sessions keep working with no extra configuration.

Open the memory folder

Once a chat has saved at least one memory file, Open Memory appears in its Actions menu and opens the memory directory in your file manager when clicked. The item stays hidden until the directory has content.

Data storage

Set the BRICKS_PROJECT_DESKTOP_DATA_DIR environment variable to override the default data directory (~/.bricks-project-desktop/), which moves the memory root along with it.