Memory for knowledge graphs

Pick 2 of 3 for knowledge graphsOfficialAnthropic (reference)86,581

Knowledge graphs model the world as entities and the relations between them, so an agent can answer multi-hop questions and walk dependencies. The reference Memory server is our second pick of three here: a lightweight local knowledge graph of entities, relations, and observations that gives an agent persistent graph-shaped memory without standing up a database.

It ranks second because it is deliberately small. For a real graph workload, Neo4j sits ahead of it. But for persistent, structured recall across sessions without infrastructure, this server is the simplest thing that works, and that simplicity is the whole point.

How Memory fits

create_entities adds nodes with a name, type, and observations, and create_relations links them with directed, active-voice edges, which is how the graph gets built. add_observations attaches atomic facts to existing entities as the agent learns more. For querying, search_nodes matches a query string, open_nodes retrieves specific nodes by exact name, and read_graph returns the whole graph at once. Maintenance is covered by delete_entities, delete_observations, and delete_relations, so the agent can prune stale facts and edges.

The honest limits: this is a local store with string-match search, not a query language. There is no Cypher, no path-finding primitive, and read_graph returning everything means it does not scale to large graphs. Neo4j is the stronger pick when you need a real graph database with proper traversal queries and volume. SurrealDB fits when graphs sit alongside document and relational shapes in one multi-model store. Choose the Memory server when you want simple, persistent entity-relation memory for an agent and the graph stays small.

Tools you would use

ToolWhat it does
create_entitiesCreate multiple new entities in the knowledge graph, each with a name, entity type, and observations.
create_relationsCreate multiple new directed relations between existing entities, expressed in active voice.
add_observationsAdd new observations (atomic facts) to one or more existing entities.
delete_entitiesRemove entities and all of their associated relations from the graph.
delete_observationsRemove specific observations from existing entities.
delete_relationsRemove specific relations from the knowledge graph.
read_graphRead the entire knowledge graph, returning all entities and relations.
search_nodesSearch for nodes in the graph that match a query string.
open_nodesRetrieve specific nodes by their exact names.
Full Memory setup and config →

FAQ

Can the Memory server run graph traversal queries like Cypher?
No. It offers string-match search via search_nodes, exact lookup via open_nodes, and a full dump via read_graph, but no query language or path-finding. For multi-hop traversal queries and larger graphs, Neo4j is the stronger pick; Memory is for lightweight persistent recall.
Why pick the Memory server over a real graph database?
Because it needs no infrastructure. It keeps a local knowledge graph an agent can build and read across sessions using create_entities, create_relations, and add_observations. When the graph grows or you need real traversal, move to Neo4j; Memory is the simple, persistent option for small graphs.