Give Claude Code
persistent memory.
The Claude Code plugin automatically captures every session, turn, and tool call as an immutable TES event. Your conversations become a searchable knowledge base — shared across sessions and teams.
How it works
Install once, remember forever
Install the plugin
Run the setup command. It registers the MCP server (tes-memory) and installs the five hook scripts into your Claude Code environment.
Configure credentials
Add your TES API key and client ID to the memory config file. The plugin reads these at startup — no other configuration needed.
Start coding
Every Claude Code session is now tracked automatically. Use search_memories to find past decisions, patterns, and solutions across your entire history.
Hook lifecycle
SessionStartFires when Claude Code opens. Emits a SESSION_START event to TES with session metadata.
UserPromptSubmitFires before each user message is processed. Captures the user's prompt as a TES event.
PostToolUseFires after each tool call. Captures tool name, input, and result as a TOOL_USE event.
StopFires when Claude generates a final response. Emits a CHAT_TURN event with token totals for the session.
SessionEndFires when the session closes. Finalises the session record in TES.
MCP tools
Three tools, one knowledge base
The tes-memory MCP server exposes these tools directly to Claude. Claude can search and store memories without any prompting.
search_memoriesSearch your TES memory store with a natural language query. Returns semantically similar memories ranked by relevance. Every Claude Code session, turn, and tool result is searchable.
// Claude automatically searches your memory when relevant
// You can also invoke it directly:
search_memories({
query: "how we handle auth in the API",
limit: 5,
})store_memorySave a memory to TES with optional tags and metadata. Memories are embedded with BGE-M3 (1024-dim) and stored in the event spine — permanent and searchable.
store_memory({
content: "We use JWT tokens with 1-hour expiry. Refresh tokens stored in httpOnly cookies.",
tags: ["auth", "api", "security"],
})list_memory_layersSee what memory layers are available and their current sizes. TES uses a 7-layer bio-inspired memory system: episodic, semantic, procedural, working, and more.
list_memory_layers()
// Returns: episodic (42 nodes), semantic (18 nodes),
// procedural (7 nodes), working (3 nodes), ...Setup
Installation
1. Install the SDK
npm install -g @pentatonic/ai-agent-sdk2. Run setup
npx @pentatonic/ai-agent-sdk setup-claude-codeThis installs the MCP server and hook scripts into your Claude Code settings.
3. Configure credentials
---
apiKey: tes_your_api_key_here
clientId: your-client-id
endpoint: https://tes.pentatonic.com
---
# TES Memory Configuration
# Get your API key from https://api.pentatonic.comSave this as ~/.claude/tes-memory.local.md. The plugin reads it at startup.
4. Verify
# Start Claude Code — the plugin loads automatically
# Ask Claude to search your memories:
# "Search my memories for anything about authentication"Claude Code Plugin
Never lose context between sessions again
Every conversation becomes a searchable knowledge base. Free tier includes 10,000 events per month.