Skip to content
DiscordForumGitHubSign up
Reference

Commands

Reference for all Letta Code CLI commands and interactive commands

FlagDescription
lettaStart interactive session (auto-resumes last project agent)
letta --newCreate new agent (reuses global persona/human blocks)
letta --fresh-blocksCreate new agent with all fresh memory blocks
letta --agent <id>Use a specific agent by ID
letta --helpShow help
letta --versionShow version
FlagDescription
--model <model>, -mSpecify model (e.g., sonnet-4.5, gpt-5-codex)
--system <id>Switch system prompt preset
--toolset <name>Force toolset: default, codex, or gemini
--skills <path>Custom skills directory
FlagDescription
-p "prompt"Run a one-off prompt (headless mode)
--output-format <fmt>Output format: text, json, or stream-json
--yoloBypass all permission prompts
--permission-mode <mode>Set permission mode
--tools "Tool1,Tool2"Limit available tools
--allowedTools "..."Allow specific tool patterns
--disallowedTools "..."Block specific tool patterns
FlagDescription
--linkAttach Letta Code tools to agent (use with --agent)
--unlinkRemove Letta Code tools from agent (use with --agent)

Use with --agent to attach or remove Letta Code tools from an existing agent. See Permissions for approval settings.

FlagDescription
letta updateManually check and install updates
DISABLE_AUTOUPDATER=1 lettaDisable auto-updates

All interactive commands start with / during a session.

CommandDescription
/agentShow current agent info and link
/swapSwitch to a different agent
/renameRename the current agent
/downloadExport agent as JSON file
CommandDescription
/modelOpen model selector
/toolsetSwitch toolsets (default/codex/gemini)
/systemSwitch system prompt preset
/streamToggle token streaming on/off
CommandDescription
/linkAttach Letta Code tools to current agent
/unlinkRemove Letta Code tools from current agent
CommandDescription
/initInitialize agent memory for current project
/rememberCommit information to agent memory
/remember <text>Remember specific information
/skillEnter skill creation mode
/skill "<desc>"Start skill creation with description
CommandDescription
/bashesShow running background shell processes
CommandDescription
/clearClear conversation history
/exitExit and show session stats
/logoutClear credentials and exit
VariableDescription
LETTA_API_KEYAPI key for authentication
LETTA_BASE_URLBase URL for self-hosted Letta server
DISABLE_AUTOUPDATERSet to 1 to disable auto-updates