Skip to content
  • Auto
  • Light
  • Dark
DiscordForumGitHubSign up
Development tools
Community tools
View as Markdown
Copy Markdown

Open in Claude
Open in ChatGPT

Letta Snippets

Letta Snippets is a VS Code extension that provides code snippets for the Letta Python SDK. It helps you quickly scaffold common Letta patterns—agent creation, memory blocks, tool definitions, and more—without typing boilerplate from scratch.

Install directly from the VS Code Marketplace:

  1. Open VS Code
  2. Go to Extensions (Cmd+Shift+X on Mac, Ctrl+Shift+X on Windows/Linux)
  3. Search for “Letta Snippets”
  4. Click Install

Or install via the command line:

Terminal window
code --install-extension Vedant0200.letta-snippets

Type a prefix and press Tab to expand the snippet. All snippets are available in Python files.

PrefixDescription
letta-clientInitialize a Letta client
letta-agentCreate a new agent
letta-toolDefine a custom tool
letta-memoryCreate a memory block
letta-messageSend a message to an agent

Type letta-agent in a Python file and press Tab to expand:

from letta_client import Letta
client = Letta(token="your-api-key")
agent = client.agents.create(
name="my-agent",
model="gpt-4o",
embedding="openai/text-embedding-ada-002",
)

The snippet places your cursor at key positions so you can quickly customize the generated code.