Skip to content

agent-memory

workspacepersistent

Long-term TOON memory artifacts backed by .mcp-ai-agent-guidelines/memory/*.toon files. Use agent-memory for persistent cross-session artifacts, agent-session for session-scoped state, and agent-snapshot for codebase baselines.

The memory system stores rich structured artifacts (summaries, details, context, tags, relevance scores) and supports semantic search via the find command.

CommandDescription
statusShow long-term artifact summary — total count, storage size
listEnumerate all stored memory artifacts with IDs and summaries
readRead one memory artifact by artifactId
findSearch artifacts — optionally filter by tags and minRelevance
writePersist a new memory artifact (requires summary)
enrichAppend Context7 library documentation to an existing artifact
deleteDelete a memory artifact by artifactId
ParameterTypeCommandsDescription
commandstringallOne of the commands above
artifactIdstringread, enrich, deleteTarget artifact ID (format: {toolName}-{sessionId})
tagsstring[]findFilter to artifacts matching ANY of the given tags
minRelevancestringfindMinimum relevance threshold 0–1 as decimal string (default: "0")
summarystringwriteShort summary text — required when writing
detailsstringwriteExtended detail text stored as content.details
artifactContextstringwriteRequest context string stored as content.context
relevancestringwriteRelevance score 0–1 as decimal string
libraryContextstringenrichContext7 documentation to append — does not mutate raw details

Artifacts use a three-part tag structure: [toolName, "topic:toolName", sessionId]

PatternExampleUse
Tool namedocs-generateFind all artifacts from docs-generate sessions
Topic prefixtopic:docs-generateSame — preferred post-2026-04-12
Session IDsession-gMxSsE2nGw0TFind all artifacts from a specific session
{ "command": "list" }

Then find relevant artifacts by tool name:

{ "command": "find", "tags": ["docs-generate"] }

Then read a specific artifact:

{ "command": "read", "artifactId": "docs-generate-session-gMxSsE2nGw0T" }
{
"command": "write",
"summary": "Added lucide-astro icon headers to all 20 tool pages",
"details": "Converted .md → .mdx, injected icon imports, added .tool-header-icon CSS class",
"artifactContext": "Phase 3 icon enhancement session",
"relevance": "0.9"
}
{
"command": "enrich",
"artifactId": "docs-generate-session-gMxSsE2nGw0T",
"libraryContext": "... fetched Context7 docs for astro-mermaid ..."
}

Comparison: Memory vs. Session vs. Snapshot

Section titled “Comparison: Memory vs. Session vs. Snapshot”
ToolScopeFormatUse
agent-memoryCross-session persistent.toon (TOON binary)Long-term knowledge artifacts, session summaries
agent-sessionCurrent session only.toon / JSONIn-progress state, intermediate outputs
agent-snapshotCodebase baselineJSON + fingerprintFile change tracking, codebase diffs

Artifacts are stored in .mcp-ai-agent-guidelines/memory/ as .toon files. These files are not auto-injected into context — you must call list then read explicitly to retrieve them.