Docs/Getting Started

Getting Started

v0.1 pre-release

Install the SDK, connect an agent, and store your first graph-native memory — in under 5 minutes.

What is Agentverse Memory?

Agentverse Memory is a managed, graph-native memory service for AI agents — exposing all four memory types (episodic, semantic, procedural, working) through a single MCP-compatible API, with zero LLM inference at write time and graph traversal at every pricing tier, including free.

It sits between your agent and persistent storage: your agent writes memories, the service indexes and connects them in a LadybugDB knowledge graph, and retrieval uses pheromone-weighted graph traversal rather than brute-force vector search. The write path calls no LLM — the in-process engine write op is 0.035ms p95 (am-local), so writes carry none of the ~2–3s LLM-extraction latency competitors like Mem0 incur.

Prerequisites

RequirementMinimum
Python3.10+
Node.js18+ (TypeScript SDK)
MCP clientAny JSON-RPC 2.0 client (Claude Desktop, Cursor, custom)
API keyFree — get one at memory.agentverse.ai

Installation

Python SDK

pip install agentverse-memory

TypeScript / Node.js SDK

npm install @fetchai/agentverse-memory
# or
yarn add @fetchai/agentverse-memory

Both SDKs wrap the JSON-RPC 2.0 MCP transport. You can also call the API directly without an SDK.

Quick Start — Python

1Store an episodic memory (something that happened)
2Store a semantic fact (a knowledge triple)
3Query by natural language
4Traverse the graph from an entity
quickstart.py
from agentverse_memory import MemoryClient
# 1. Initialize the client
client = MemoryClient(
api_key="avmem_sk_your_key_here", # from memory.agentverse.ai dashboard
agent_id="my-research-agent", # unique per agent
base_url="https://am-server-jbneh74b5q-uc.a.run.app", # or set AVMEM_BASE_URL env var
)
# 2. Store an episodic memory (something that happened)
episode = client.episodes.store(
content="User asked about the Q1 sales report. Pulled data from Salesforce.",
metadata={
"user_id": "user_42",
"session_id": "sess_abc123",
"tags": ["sales", "q1", "report"],
}
)
print(episode.id) # ep_01hx...
# No LLM calls at write time — sub-ms in-process engine write op
# 3. Store a semantic memory (a knowledge triple)
fact = client.facts.store(
subject="Acme Corp",
predicate="signed_contract_with",
object_="Fetch.ai",
metadata={
"valid_at": "2026-01-15", # when this fact became true
"confidence": 0.95,
"source": "CRM",
}
)
print(fact.id) # fact_02hy...
# 4. Query memories by natural language
results = client.episodes.query(
query="What did the user ask about sales?",
limit=5,
)
for r in results:
print(f"[{r.score:.2f}] {r.content[:80]}")
# 5. Graph traversal — follow edges from a concept
graph_results = client.facts.traverse_graph(
seed_node="Acme Corp",
max_depth=2,
limit=20,
)
for node in graph_results.nodes:
print(f"{node.subject} --[{node.predicate}]--> {node.object_}")
Output
ep_01hxq7kn3m...
fact_02hyr9mp4n...
[0.94] User asked about the Q1 sales report. Pulled data from Salesforce.
Acme Corp --[signed_contract_with]--> Fetch.ai
Fetch.ai --[headquartered_in]--> London

Quick Start — TypeScript

quickstart.ts
import { MemoryClient } from "@fetchai/agentverse-memory";
// 1. Initialize the client
const client = new MemoryClient({
apiKey: "avmem_sk_your_key_here",
agentId: "my-research-agent",
});
// 2. Store an episodic memory
const episode = await client.episodes.store({
content: "User asked about the Q1 sales report.",
metadata: {
userId: "user_42",
sessionId: "sess_abc123",
tags: ["sales", "q1", "report"],
},
});
console.log(episode.id); // ep_01hx...
// 3. Store a semantic fact
const fact = await client.facts.store({
subject: "Acme Corp",
predicate: "signed_contract_with",
object: "Fetch.ai",
metadata: { validAt: "2026-01-15", confidence: 0.95 },
});
// 4. Query episodes
const results = await client.episodes.query({
query: "What did the user ask about sales?",
limit: 5,
});
results.forEach((r) => {
console.log(`[${r.score.toFixed(2)}] ${r.content.slice(0, 80)}`);
});
// 5. Graph traversal
const graph = await client.facts.traverseGraph({
seedNode: "Acme Corp",
maxDepth: 2,
limit: 20,
});
graph.nodes.forEach((n) => {
console.log(`${n.subject} --[${n.predicate}]--> ${n.object}`);
});

MCP Integration (No SDK)

Any MCP-compatible client can connect without installing any SDK. Add this to your client config:

Claude Desktop

claude_desktop_config.json
{
"mcpServers": {
"agentverse-memory": {
"url": "https://am-server-jbneh74b5q-uc.a.run.app/mcp",
"headers": {
"Authorization": "Bearer avmem_sk_your_key_here"
}
}
}
}

Restart Claude Desktop. You'll see all 35 memory tools available.

Cursor

.cursor/mcp.json
{
"mcpServers": {
"agentverse-memory": {
"url": "https://am-server-jbneh74b5q-uc.a.run.app/mcp",
"headers": {
"Authorization": "Bearer avmem_sk_your_key_here"
}
}
}
}

Memory Types

All four types are available on every plan, including free.

TypeWhat it storesTools prefixUse it for
EpisodicTime-stamped events and interactionsmemory_*_episode*Conversation history, action logs
SemanticKnowledge triples: (subject, predicate, object)memory_*_fact*Facts, relationships, entity states
ProceduralSkill definitions: goal → steps → outcomememory_*_procedure*Workflows, how-to knowledge
WorkingEphemeral key/value with TTLmemory_*_working*Scratchpad, task state, short-lived context

Shared Spaces Builder+

Multiple agents can share a common memory graph. 5 dedicated shared space tools handle creation, joining, entity storage, querying, and listing. Access is controlled via JWT tokens or ASI Chain DID credentials.

shared_space.py
from agentverse_memory import MemoryClient
# Orchestrator creates a shared memory space
orchestrator = MemoryClient(api_key="...", agent_id="orchestrator")
space = orchestrator.spaces.create(name="research-team-memory")
print(space.id, space.invite_token)
# Worker agent joins via invite token
worker = MemoryClient(api_key="...", agent_id="worker-agent-1")
worker.spaces.join(space_id=space.id, invite_token=space.invite_token)
# Any agent in the space can query the shared knowledge graph
results = orchestrator.spaces.query(
space_id=space.id,
query="What did the team discover about Acme Corp?",
limit=10,
)

Next Steps

Having trouble? Open an issue on GitHub or ping us in #memory-support on Discord.