Ai Memory Sdk banner
letta-ai letta-ai

Ai Memory Sdk

AI community

Description

An experimental SDK for adding agentic memory and learning in a pluggable way

Installation

This entry records only its repository, not the path inside it, so there is no exact command to give. Open the source below and copy the folder into ~/.claude/skills/, or the file into ~/.claude/agents/.

README

AI Memory SDK

The AI Memory SDK is a lightweight wrapper around [Letta](https://letta.com)'s advanced memory management capabilities. Letta is a platform for building stateful AI agents that truly remember, learn, and evolve. The memory SDK exposes Letta's sophisticated memory architecture through a simplified interface for general-purpose use cases like user profiles, conversation summaries, and domain-specific knowledge bases.

Under the hood, the SDK creates a "subconscious agent"—a Letta agent configured to manage memory blocks. When you send messages, the agent asynchronously processes them and updates its memory blocks. This architecture leverages Letta's core strengths in persistent memory and stateful learning while providing a streamlined API for common memory patterns.

The SDK organizes memory around three concepts:

  • Subjects: what memory is "about" (e.g., user_sarah, project_alpha, team_support). Each subject is backed by a Letta agent with its own memory state.
  • Blocks: named memory sections within a subject (e.g., human, summary, policies, history, preferences). These correspond to Letta's memory blocks—customizable, labeled sections that persist in the agent's core memory.
  • Messages: conversation turns you send to update memory. When you add messages, the Letta agent processes them and updates relevant blocks asynchronously.

This enables user profiles and conversation summaries, plus broader use cases like policy digests, running histories, study guides, or any domain‑specific memory you define.

See Letta's YouTube channel for more information on how to design memory architecture. [This video](https://youtu.be/o4boci1xSbM) provides a general overview.

Quick mental model—blocks live in the agent's context window (core memory), updated automatically as messages flow through:

+========================================+
|         SYSTEM PROMPT                  |