First time here? Complete the Quickstart (For Developers)
or Manual Install guide first, then come back to enable memory.
Prerequisites
Before using Agent Memory, make sure you have the following in place:-
Install path: Developer install — clone the repo and install from source:
-
Extras required:
[dev,rag]—[rag]provides the FAISS index used for memory recall;[dev]adds the developer toolchain -
Lemonade server must be running before you start:
-
Example files referenced in this guide are inside the cloned repo under
examples/
Memory is currently integrated into the Chat Agent. Any agent built on the GAIA Agent base class can add memory via the
MemoryMixin — see the Memory SDK Reference for developer details.Memory is opt-in (beta) and disabled by default. This feature is still under active development — every new GAIA install ships with memory off, so you’ll see standard chat behavior until you turn it on. See Enable Memory below before trying any examples on this page.
Enable Memory
Memory is off by default. Turn it on once and it stays on for every futuregaia chat session on this machine.
Via the Agent UI (recommended)
- Launch the Agent UI:
gaia chat --ui - Click the Brain icon in the toolbar to open the Memory Dashboard.
- Click the Off toggle next to Memory; a confirmation modal appears. Click Enable Memory in the modal to confirm. The agent picks up the change on its next message — no restart needed.
Via the API (for headless / scripted setups)
~/.gaia/memory.db.
Once enabled, conversations are summarized into
~/.gaia/memory.db — a plaintext SQLite file (not encrypted). The Sensitive Data section below explains the sensitive flag for controlling system-prompt visibility; do not store passwords or tokens in agent memory.Try It Right Now
With memory enabled (above), here’s what a second brain feels like. Teach it something in one session, then start a fresh one and watch it recall:gaia chat --ui and click the Brain icon to see every memory, filterable and editable.
How It Works
Agent memory operates on four principles:- Store automatically once enabled — conversations, tool calls, errors, and preferences are captured without manual effort
- Recall naturally — hybrid semantic+keyword search finds memories by meaning, not just exact words. The LLM decides when to search using its own tools (no forced pre-query step).
- Learn continuously — LLM extraction from every conversation, not just regex patterns. The agent sees what it already knows and decides what’s new, what’s changed, and what’s contradicted — like intelligent memory management.
- Be temporally aware — the agent knows the current time, what is coming up, what is overdue, and proactively surfaces time-sensitive items
~/.gaia/memory.db (SQLite with WAL mode for concurrent reads). No cloud services, no external dependencies.
Quick Start
1
Bootstrap your memory
Run the day-zero onboarding flow. The agent asks a few questions about you and optionally scans your system to discover projects, tools, and interests:You can run just the conversational part or just the system discovery:
2
Check memory status
See how much the agent knows and how the memory is structured:This shows counts by category (fact, preference, error, skill, note, reminder), context (work, personal, global), total conversations, tool call stats, and database size.
3
Start chatting
With memory enabled (see Enable Memory above), the agent injects relevant knowledge into its system prompt and uses memory tools during conversation:Try saying things like:
- “Remember that our project uses React 19 with the app router”
- “I prefer concise answers with code examples”
- “What do you know about me?”
- “What did we talk about last week?”
Memory Tools
The agent has 5 memory tools it can use during conversation. You do not call these directly — the LLM decides when to use them based on your conversation.remember
Stores a new fact, preference, error pattern, or skill in persistent memory.recall
Searches memory for relevant knowledge using hybrid semantic+keyword search — it finds concepts, not just exact keywords. If you say “frontend framework,” it matches memories about React, Vue, and Angular, even if those exact words aren’t in your query.time_from and time_to. The agent converts natural language dates (“last week”, “in March”) to concrete time ranges using the current date it always knows:
update_memory
Modifies an existing memory entry. The agent usesrecall first to find the ID, then updates it.
forget
Removes a specific memory entry by ID.search_past_conversations
Searches across all past conversation sessions by keyword (query), time range (days or time_from/time_to), or both.
Your Second Brain
Memory turns GAIA into a personal knowledge system that grows smarter with every conversation. Common uses:- Daily journal — log your work; recall it weeks later by date (“what did I work on the first week of April?”).
- Meeting notes — paste standup notes; the agent extracts per-person facts and deadlines automatically.
- Research notes — save article summaries and find them later by concept, not just keywords.
- Personal reminders — set due dates (including recurring ones); the agent surfaces them proactively.
- Contact profiles — knowledge about people accumulates across conversations, linked to entities.
- Error learning — when a tool fails, the agent remembers the pattern and avoids it next time.
Knowledge Categories
Every memory entry belongs to one of six categories:
The agent automatically categorizes knowledge when you ask it to remember something. You can also specify the category explicitly:
Context Scoping
Different areas of your life produce different knowledge. Without scoping, the agent mixes work deployment commands with personal dentist appointments. Contexts keep them separate.
The agent’s system prompt always includes
global items plus items from the active context. You can switch contexts mid-session:
Sensitive Data
Some knowledge is private — email addresses, API tokens, health information, financial data. Thesensitive flag controls how this data is handled:
The agent can still access sensitive data when you explicitly ask for it via
recall — it just will not be broadcast in the system prompt where it could leak into logs or debugging output.
Entity Linking
For managing contacts, apps, and services, the agent associates knowledge with specific entities using atype:name convention:
Multiple entries can share an entity, building a profile over time. When you say “email Sarah about the roadmap,” the agent calls
recall(entity="person:sarah_chen") to get her email and preferences.
Temporal Awareness
The agent always knows the current date and time. It can track commitments and deadlines using thedue_at field on memory entries.
How reminders work
- You mention something time-sensitive — the agent stores it with a
due_atdate - As the date approaches, the agent sees it in its per-turn context and proactively mentions it
- After mentioning it, the agent marks
reminded_atso it does not repeat itself - If the due date passes, the item appears as overdue until resolved
Intelligent Extraction
After each conversation turn (with memory enabled), the agent automatically decides what’s worth remembering — without you saying “remember.” This isn’t pattern matching; the LLM sees your existing memory alongside the new conversation and decides whether to ADD new knowledge, UPDATE a changed fact (old version preserved with lineage), or DELETE something you’ve contradicted. It extracts information useful in future conversations — facts, preferences, project details, people, deadlines — and skips greetings, confirmations, and ephemeral details. For example, “we standardized on Python 3.12 and I’m using a Ryzen 9 9950X” stores two facts but ignores subjective asides like “it’s much faster.”Memory Dashboard
The Agent UI includes a full-page Memory Dashboard for viewing and managing everything the agent knows. Click the Brain icon in the toolbar to open it.What you can see
- Stats overview — total memories, sessions, tool calls, success rate, and embedding coverage
- Knowledge browser — filterable, sortable table of all memory entries with inline editing
- Tool performance — per-tool success rates, error history, average duration
- Upcoming and overdue — time-sensitive items due soon or past due
- Conversation history — searchable archive of all past sessions with consolidation status
- Superseded items — toggle to see fact history and how knowledge evolved over time
What you can do
- Create new memory entries manually (stored with high confidence)
- Edit any field on any memory entry — content, category, context, entity, sensitivity
- Delete entries the agent got wrong
- Toggle sensitive to hide or show private data
- Search across all knowledge using hybrid semantic+keyword search
- Filter by category, context, or entity
Maintenance actions
The dashboard also provides maintenance tools for keeping your memory healthy:- Consolidate — distill old conversation sessions into durable knowledge notes
- Rebuild Embeddings — re-embed all knowledge items and rebuild the search index
- Reconcile — scan for contradictory facts across sessions and resolve them automatically
To launch the Agent UI with the dashboard:
gaia chat --uiHow Memory Improves Over Time
These mechanisms run automatically — you don’t need to manage them.- Confidence scoring — every entry has a 0.0—1.0 confidence. Newly created entries start lower for auto-captured items (LLM-extracted and discovery at 0.4; tool-stored, error, and consolidation at 0.5) and higher for user-created dashboard entries (0.8). Each recall adds +0.02, so frequently-used memories rank higher in the system prompt.
- Confidence decay — entries not accessed for 30+ days are multiplied by 0.9 once per session start, so stale knowledge fades in favor of what you actively use.
- Fact lineage — when a fact changes, the old version is kept with a
superseded_bylink and its original timestamp, so you can answer “what framework were we using in March?” The dashboard’s superseded view shows the full chain. - Automatic error learning — a failed tool call is stored as an error pattern; the next session’s system prompt includes a “Known errors to avoid” list so the agent doesn’t repeat it.
- Session consolidation — conversations older than 14 days are distilled into durable notes (extracted facts live indefinitely; raw conversations are pruned at 90 days), so old context is never lost.
- Background reconciliation — on startup the agent resolves contradictory facts across sessions, superseding the older item and boosting the newer (and reinforcing) one’s confidence.
Procedural memory (skills)
Beyond remembering facts, the agent learns procedures — the multi-step tool recipes it has already run successfully. When the same kind of goal succeeds several times with the same shape of work, GAIA distils that successful tool sequence into a reusable skill and stores it as a procedure. The next time a similar goal comes up, the agent recalls the proven recipe and reuses it instead of re-planning from scratch. This is automatic: there is no command to run and no skill to install. Synthesis runs during the startup maintenance pass, and a matching skill is injected silently into the agent’s planning context. A procedure is only synthesized when all of these hold:- the same goal succeeded at least 3 times (clustered by goal similarity ≥ 0.82),
- the success rate across those attempts is at least 80%, and
- each successful run was a real multi-step sequence of at least 3 tool calls.
~/.gaia/memory_settings.json under a skill_synthesis section, so you can tighten or relax them per machine.
Synthesized skills follow the same lineage rules as facts: a better recipe supersedes an older one rather than overwriting it, and nothing is deleted automatically.
Off switches:
GAIA_MEMORY_DISABLED=1turns off both synthesis and recall."skill_synthesis": { "enabled": false }inmemory_settings.jsonskips synthesis while leaving the rest of memory active.- A procedure you disable (
enabled = 0) or that has been superseded is never recalled.
gaia memory status to see how many procedures have been synthesized.
Privacy
100% Local
All memory is stored in a single SQLite file at
~/.gaia/memory.db. Nothing is transmitted to any server or cloud service.User Control
You can view, edit, and delete any memory entry via the dashboard or CLI. The agent only knows what you approve.
Bootstrap Consent
System discovery scans are opt-in. The agent shows you what it found and asks for approval before storing anything.
Sensitive Flagging
Mark any entry as sensitive to exclude it from the system prompt. Browser history and email addresses are auto-flagged during bootstrap.
Deleting all memory
To reset discovery-sourced items while preserving your manual edits:CLI Reference
System context (versions, hardware, apps)
System facts — GAIA/Lemonade versions, OS, CPU/GPU/RAM, installed apps — are captured assystem-category memories. Collection is opt-in: the
system_context_enabled flag in ~/.gaia/memory_settings.json defaults to
false. Enable it from the Agent UI Memory Dashboard or by running
gaia memory bootstrap --system (which offers to turn it on).
Once enabled, system facts auto-refresh on agent startup when either:
- a tracked version (GAIA or Lemonade Server) no longer matches the live value — so version facts update immediately after an upgrade, or
- the newest fact is more than 7 days old.
system entries before re-collecting, so values
are replaced rather than duplicated. To force a refresh yourself, run
gaia memory bootstrap --system.
Next Steps
Memory SDK Reference
MemoryMixin API, MemoryStore class, and code examples for adding memory to custom agents
Agent UI
Desktop interface with Memory Dashboard for visual knowledge management
Agent SDK
Chat SDK for building conversational agents programmatically
Build Your First Agent
Create a custom agent with tools and memory in minutes