Letta

Letta

Stateful AI agents with persistent memory — formerly MemGPT, agents learn and self-improve over time

Open source alternative to:LangChainOpenAI APIOpenRouter

Letta (formerly MemGPT) is a framework for building stateful AI agents with 23k+ GitHub stars — a LangChain alternative focused on persistent memory and self-improving agents.

Key features

Memory management

  • Persistent memory across conversations and sessions
  • Editable memory blocks for agent state
  • Automatic memory consolidation and summarization
  • Multi-tier memory (core, archival, recall)
  • Memory search and retrieval

Agent capabilities

  • Self-improving agents that learn from interactions
  • Multi-step reasoning and planning
  • Tool use and function calling
  • Multi-agent orchestration
  • Human-in-the-loop workflows

Developer experience

  • Python SDK with type hints
  • REST API for language-agnostic access
  • Pre-built agent templates
  • Integration with OpenAI, Anthropic, and local models
  • Web UI for agent management

Production features

  • Conversation persistence and history
  • Agent versioning and rollback
  • Usage analytics and cost tracking
  • Role-based access control
  • SSO and enterprise authentication

At a glance

LicenseApache-2.0
StackPython, TypeScript, PostgreSQL
Self-hostedYes — Letta OSS
Cloudletta.com (managed)
MemoryPersistent, multi-tier

Self-hosting

pip install letta

Letta can be embedded in your application or run as a standalone server. The cloud version provides managed infrastructure and team features.

Screenshots

Letta screenshot 1

Category

Developer Tools

Tags

aiagentsmemoryllm