Slash commands
Control Letta Code's behavior during an interactive session with slash commands
Control Letta Code’s behavior during an interactive session with slash commands. Press Tab to autocomplete command names.
Built-in slash commands
Section titled “Built-in slash commands”Commands are also available from autocomplete: type / in an interactive CLI session and press Tab.
Common session commands
Section titled “Common session commands”| Command | Description |
|---|---|
/agents | Browse agents (pinned, Letta Code, all) |
/model | Switch model |
/init | Initialize or re-initialize your agent’s memory |
/doctor | Audit and refine your memory structure |
/remember [text] | Ask the agent to remember something from the conversation |
/goal [status|pause|resume|complete|clear|disable|--replace|--token-budget N <objective>] | Manage a long-running conversation goal |
/memory | View your agent’s memory |
/palace | Open the Memory Palace in your browser |
/search [query] | Search messages across agents |
/connect | Connect LLM API keys and coding plans |
/clear | Clear in-context messages |
/chdir <path> | Change the working directory for the current TUI session |
Agent and conversation management
Section titled “Agent and conversation management”| Command | Description |
|---|---|
/new | Start a new conversation with the current agent |
/resume [id] | Browse and resume past conversations, or switch directly by ID |
/fork | Fork the current conversation |
/btw <question> | Fork the conversation and ask a side question in the background |
/pin [-l] | Pin the current agent globally, or locally with -l |
/unpin [-l] | Unpin the current agent globally, or locally with -l |
/rename agent [name] or /rename convo [name] | Rename the current agent or conversation |
/description <text> | Update the current agent’s description |
/export | Export the current agent as an AgentFile (.af) |
Memory, tools, and configuration
Section titled “Memory, tools, and configuration”| Command | Description |
|---|---|
/reflect [transcript_file] | Launch a reflection agent |
/sleeptime | Configure reflection trigger settings |
/compaction | Configure compaction mode settings |
/compact [all|sliding_window] | Summarize conversation history immediately |
/memfs [enable|disable|sync|reset] | Manage filesystem-backed memory |
/toolset | Switch toolset (default, codex, or gemini) |
/experiments | Toggle local experiments |
/reload | Reload settings and restart TUI effects |
/system | Switch system prompt |
/personality | Switch to a personality preset |
/subagents | Manage custom subagents |
/mcp | Manage MCP servers |
/secret <set|list|unset> [key] [value] | Manage secrets for shell commands |
/skills | Browse available skills by source |
/skill-creator [description] | Enter guided skill creation mode |
/memory-repository <set|unset|status|push> [url] | Push the agent memory repo to an additional git remote |
Interface and maintenance
Section titled “Interface and maintenance”| Command | Description |
|---|---|
/usage | Show session usage statistics and balance |
/context | Show context window usage |
/recompile | Recompile the current agent and conversation |
/feedback | Send feedback to the Letta team |
/hooks | Manage hook configuration |
/statusline [subcommand] | Configure CLI footer status lines |
/title | Configure the terminal window title |
/reasoning-tab [on|off|status] | Toggle the Tab shortcut for reasoning tiers |
/terminal [--revert] | Set up or remove terminal shortcuts such as Shift+Enter |
/ade | Open the current agent in ADE in your browser |
/install-github-app | Set up the Letta Code GitHub Action in this repository |
/plan | Enter plan mode |
/plan-mode on|off | Enable or disable plan mode |
/disconnect <provider> | Disconnect an existing provider account |
/bg | Show background shell processes |
/ralph [prompt] | Start Ralph Wiggum loop mode |
/yolo-ralph [prompt] | Start Ralph loop mode with bypass permissions |
/exit | Exit this session |
/logout | Clear credentials and exit |
/skill-creator replaces the older /skill shortcut in the interactive CLI.
Goal mode
Section titled “Goal mode”Use /goal for long-running autonomous work. It is the recommended successor to /yolo-ralph for most use cases because it adds persistent conversation state, status commands, token/time tracking, and goal lifecycle tools.
/goal improve benchmark coverageA goal is stored on the current conversation. While it is active, Letta Code reminds the agent of the objective and automatically continues the work between turns until the goal is completed, paused, cleared, disabled, or budget-limited.
Common goal commands:
| Command | Description |
|---|---|
/goal or /goal status | Show the current goal and usage |
/goal --token-budget 50000 <objective> | Set a goal with a token budget |
/goal --replace <objective> | Replace the current goal |
/goal pause | Pause automatic continuation |
/goal resume | Resume a paused goal |
/goal complete | Manually mark the goal complete |
/goal clear | Remove the goal |
/goal disable | Remove the goal and disable goal tools for the conversation |
Goal mode tracks active time and tokens used. Before the agent marks a goal complete, it is prompted to audit the objective against real evidence such as files, command output, tests, or PR state.
For a deeper comparison with /ralph and /yolo-ralph, see Goal mode.
Invoking skills
Section titled “Invoking skills”Skills are normally loaded by the agent when relevant, but you can invoke a specific skill directly with slash syntax:
/<skill-name> [optional instructions]For example:
/acquiring-skills find a browser testing skillUse /skills to browse available skills by source. Direct skill invocation loads the named skill’s instructions, then continues with the rest of your request. See Skills for skill installation, scopes, and authoring.
Custom slash commands
Section titled “Custom slash commands”Custom slash commands let you define frequently used prompts as Markdown files that Letta Code can execute. Commands can be project-specific (shared with your team) or personal (available across all projects).
Syntax
Section titled “Syntax”/<command-name> [arguments]| Parameter | Description |
|---|---|
<command-name> | Name derived from the Markdown filename (without .md extension) |
[arguments] | Optional arguments passed to the command |
Command types
Section titled “Command types”Project commands
Section titled “Project commands”Commands stored in your repository and shared with your team. These show “(project)” in /help.
Location: .commands/
# Create a project commandmkdir -p .commandsecho "Review this code for security vulnerabilities:" > .commands/security.mdPersonal commands
Section titled “Personal commands”Commands available across all your projects. These show “(user)” in /help.
Location: ~/.letta/commands/
# Create a personal commandmkdir -p ~/.letta/commandsecho "Explain this code in simple terms:" > ~/.letta/commands/explain.mdArguments
Section titled “Arguments”Pass dynamic values to commands using argument placeholders:
All arguments with $ARGUMENTS
Fix issue #$ARGUMENTS following our coding standardsUsage: /fix-issue 123 high-priority → $ARGUMENTS becomes “123 high-priority”
Positional arguments with $1, $2, etc.
Review PR #$1 with priority $2 and assign to $3Usage: /review-pr 456 high alice → $1=“456”, $2=“high”, $3=“alice”
Dynamic content
Section titled “Dynamic content”Execute shell commands when the slash command runs using !`command` syntax:
Current branch: !`git branch --show-current`Recent commits:!`git log --oneline -5`Shell commands are executed and replaced with their output.
File references
Section titled “File references”Include file contents using the @ prefix:
Review the implementation in @src/utils/helpers.js
Compare @src/old-version.js with @src/new-version.jsFrontmatter
Section titled “Frontmatter”Command files support frontmatter for metadata:
| Property | Purpose | Default |
|---|---|---|
description | Brief description shown in /help | First line of prompt |
argument-hint | Arguments expected (shown in autocomplete) | None |
Example:
---description: Review code changes in the current branchargument-hint: "[focus area]"---
Review all uncommitted changes in this repository. Focus on:
- Code quality and best practices- Potential bugs or edge cases- Suggestions for improvement
$ARGUMENTSPriority
Section titled “Priority”Project commands (.commands/) take precedence over global commands (~/.letta/commands/). Custom commands appear in autocomplete alongside built-in commands.
Skills vs slash commands
Section titled “Skills vs slash commands”Use slash commands for
Section titled “Use slash commands for”Quick, frequently used prompts:
- Simple prompt snippets you use often
- Quick reminders or templates
- Frequently used instructions that fit in one file
Examples:
/review→ “Review this code for bugs and suggest improvements”/explain→ “Explain this code in simple terms”/optimize→ “Analyze this code for performance issues”
Use Skills for
Section titled “Use Skills for”Comprehensive capabilities with structure:
- Complex workflows with multiple steps
- Capabilities requiring scripts or utilities
- Knowledge organized across multiple files
- Team workflows you want to standardize
Examples:
- Code review Skill with security checklist, performance patterns, and linting scripts
- Documentation Skill with style guides and templates
- Deployment Skill with environment-specific configs and validation
Key differences
Section titled “Key differences”| Aspect | Slash Commands | Skills |
|---|---|---|
| Complexity | Simple prompts | Complex capabilities |
| Structure | Single .md file | Directory with SKILL.md + resources |
| Context | Injected once when invoked | Pinned to context when loaded |
| Survives compaction | No | Yes |
| Discovery | Explicit (/command) | Agent loads automatically or via /<skill-name> |
| Scope | Project or personal | Project, agent, global, or bundled |
Example comparison
Section titled “Example comparison”As a slash command:
Review this code for:
- Security vulnerabilities- Performance issues- Code style violationsUsage: /review (one-time injection)
As a Skill:
.skills/code-review/├── SKILL.md (overview and workflows)├── SECURITY.md (security checklist)├── PERFORMANCE.md (performance patterns)└── STYLE.md (style guide reference)Usage: Agent loads the skill automatically, or you invoke it directly with /code-review, and it has persistent access to all reference material throughout the conversation.
See also
Section titled “See also”- Skills - Create comprehensive capabilities with multiple files
- Memory - Understand and manage agent memory
- CLI reference - Command-line options and flags