Local-first, embedded graph memory for AI agents
Tell it facts in plain English. ClawGraph turns them into structured graph memory automatically.
Stored in an embedded Kuzu database. No servers, no Docker, just a local file.
The LLM infers and maintains your graph schema as you add facts.
Query the graph directly, export JSON, and inspect how memory is actually being stored.
Drop into any agentic loop with from clawgraph import Memory.
Today: OpenAI-compatible APIs and Kuzu. Future: broader LLM providers and additional database backends.
ClawGraph is aimed at one specific lane: a small, Python-first memory layer for agents that want structured recall without running separate infrastructure.
Instead of trying to be a full memory platform, it focuses on being local, inspectable, and easy to drop into agent workflows.
pip install clawgraph
# Store facts
clawgraph add "John works at Acme Corp as a software engineer"
clawgraph add "Alice is a data scientist at Google"
# Query the graph
clawgraph query "Where does John work?"
# Batch add (one LLM call for multiple facts)
clawgraph add-batch "Bob is a designer" "Bob works at Netflix"
# JSON output for agents
clawgraph query "Who works at Acme?" --output json
# Recommended model
clawgraph config llm.model gpt-5.4-mini
from clawgraph import Memory
with Memory() as mem:
mem.add("John works at Acme Corp")
mem.add("Alice is a data scientist at Google")
results = mem.query("Who works at Acme?")
llm:
model: gpt-5.4-mini
temperature: 0.0
db:
path: ~/.clawgraph/data
Recommended today: gpt-5.4-mini for fast agent loops. Higher-end models can be used for more ambiguous extraction workloads.