๐ Tab Reference¶
The RLM Code TUI has 5 tabs, each accessible via keyboard shortcuts or the focus bar. This page documents the first four standard tabs. For the Research tab, see ๐ฌ Research Tab.
๐ RLM Tab¶
The central hub for interacting with LLMs and running slash commands.
| Shortcut | Ctrl+1 / F2 |
|---|---|
| Module | rlm_code.ui.tui_app |
What's Inside¶
- Conversation log:
RichLogwidget showing the conversation - RLM input: Text input at the bottom for messages and commands
- Status strip: Compact one-line status bar above the conversation
Message Rendering¶
| Sender | Border | Style |
|---|---|---|
| ๐ค You | Blue (#59b9ff) | White text |
| ๐ค Assistant | Green (#6fd897) | Markdown with model name + elapsed time |
Slash Commands¶
Type any /command in the RLM input. All 50+ slash commands work here. Unknown commands are delegated to the full SlashCommandHandler.
โก Shell Shortcut
Prefix any message with ! to run it as a shell command without switching tabs: !git status
๐ Files Tab¶
Project file browser with syntax-highlighted code preview.
| Shortcut | Ctrl+2 / F3 |
|---|---|
What's Inside¶
- Directory tree: Textual
DirectoryTreerooted at the working directory - Code preview: Syntax-highlighted file viewer with Monokai theme
- Draggable split: In one-screen Files view, drag the vertical splitter between tree and preview to resize both areas
Supported Languages¶
| Extension | Language | Extension | Language |
|---|---|---|---|
.py | Python | .ts | TypeScript |
.js | JavaScript | .tsx | TSX |
.json | JSON | .yaml / .yml | YAML |
.toml | TOML | .md | Markdown |
.sh | Bash | .txt | Plain text |
Click a file in the tree to preview it. Line numbers and indent guides are enabled.
Resizing the Files Layout¶
- Switch to Files (
Ctrl+2) in one-screen mode. - Drag the vertical divider between the left file tree and right preview panel.
- The sidebar width updates live; preview width adjusts automatically.
๐ Details Tab¶
Status panel and diff viewer.
| Shortcut | Ctrl+3 / F4 |
|---|---|
What's Inside¶
- Status panel: Rich table with workspace, model, provider, ACP, mode, layout info
- Diff viewer: Unified diff between a snapshot and the current file state
Snapshot / Diff Workflow¶
The diff uses the diff syntax highlighter with Monokai theme.
โก Shell Tab¶
Terminal-first shell workspace for running commands.
| Shortcut | Ctrl+4 / F5 |
|---|---|
What's Inside¶
- PTY terminal: Interactive terminal pane with keyboard input, history, and tab completion behavior from your shell
- Prompt line: Minimal
>typing line shown in the terminal status area
๐ง Persistent State¶
Powered by PersistentShell, a long-running shell process that preserves:
- โ Environment variables set by previous commands
- โ
Working directory changes (
cd) - โ Shell aliases and functions (within the session)
- โ
Exit codes for inline shell shortcuts (
!cmd,>cmd) and shell command runner
Shell Detection¶
Inline shell execution uses a marker-compatible shell backend (zsh, bash, or sh) for reliable completion detection. PTY shell view uses your configured/default shell in interactive mode.
This keeps shell output predictable while preserving interactive behavior.
When a shell command modifies selected files, preview/diff panes are refreshed automatically.
๐ Command Palette¶
Open with Ctrl+K.
A fuzzy-search modal that lists all available slash commands. Type to filter, arrow keys to navigate, Enter to select.
Available Palette Commands¶
/help /workflow /connect /models /status /sandbox /rlm /rml /harness
/clear /snapshot /diff /view /layout /pane
/copy /focus /exit
Features:
- ๐ Fuzzy text matching
- โฌ๏ธโฌ๏ธ Arrow-key navigation
- โ Enter to select, Esc to close
- Up to 16 results displayed
๐ Connect Wizard¶
Launched with /connect (no arguments).
A multi-step keyboard-driven picker that guides you through:
- ๐ Connection mode: Local models, BYOK cloud providers, or ACP profiles
- ๐ข Provider selection: Available providers with live/preset status
- ๐ค Model selection: Provider-specific model list
Connection Modes¶
| Mode | Description |
|---|---|
| ๐ Local | Ollama, LM Studio, vLLM, SGLang, MLX |
| ๐ BYOK | OpenAI, Anthropic, Gemini, DeepSeek, Groq |
| ๐ ACP | Agent Coding Profile connections |
Direct Connection¶
Examples:
/connect ollama llama3.2:3b
/connect openai gpt-4o sk-...
/connect anthropic claude-sonnet-4-5-20250929
๐ Auto-Connect
If your rlm_config.yaml specifies a default_model, the TUI automatically connects to it on startup.
๐ Greeting Detection¶
The TUI detects simple greetings (hi, hello, hey, yo, sup) and responds instantly without an LLM call:
This avoids unnecessary API calls for trivial interactions.
๐ Slash Command Reference¶
| Command | Description |
|---|---|
/help | ๐ Show all commands and shortcuts |
/workflow | ๐งญ Show recommended RLM workflow steps |
/connect | ๐ Launch connect wizard |
/connect <provider> <model> ... | ๐ Direct model connection |
/models | ๐ List all providers and models |
/status | ๐ Refresh status panel |
/sandbox | ๐ฆ Sandbox status, doctor, runtime switch, profile/backend controls |
/rlm | ๐ง RLM runner (run, bench, status, replay, doctor, chat, observability) |
/rml | ๐ง Alias for /rlm |
/harness | ๐ Tool-using coding harness (tools, doctor, run) |
/clear | ๐งน Clear chat and shell logs |
/snapshot [file] | ๐ธ Take baseline snapshot for diffing |
/diff [file] | ๐ Show diff against snapshot |
/view <tab> | ๐๏ธ Switch active tab |
/layout <single\|multi> | ๐ Switch layout mode |
/pane <name> [show\|hide] | ๐ Toggle individual panes |
/focus <chat\|default> | ๐ฏ Focus mode |
/copy | ๐ Copy last response to clipboard |
/shell <cmd> | โก Run shell command |
/exit | ๐ช Quit the TUI |
โ๏ธ Environment Variables¶
| Variable | Default | Description |
|---|---|---|
RLM_TUI_HISTORY_ITEMS | 4 | ๐ Number of history items in context |
RLM_TUI_HISTORY_ITEM_CHARS | 320 | ๐ Max chars per history item |
RLM_TUI_HISTORY_TOTAL_CHARS | 1800 | ๐ Max total chars for history |
RLM_TUI_THINK_TICK | 0.08 | โฑ๏ธ Thinking animation refresh interval (sec) |
RLM_TUI_EVENT_FLUSH_SECONDS | 0.12 | ๐ก Event log batch flush cadence |
RLM_TUI_EVENT_BATCH_LIMIT | 32 | ๐ก Max events per flush batch |
RLM_TUI_ACP_DISCOVERY_TIMEOUT_SECONDS | 0.45 | ๐ ACP discovery timeout |
RLM_TUI_ACP_CACHE_TTL_SECONDS | 30 | ๐ ACP discovery cache TTL |
RLM_TUI_HARNESS_AUTO | 1 | ๐ Enable automatic harness routing for coding tasks |
RLM_TUI_HARNESS_AUTO_MCP | 1 | ๐ Include MCP tools in auto harness route |
RLM_TUI_HARNESS_AUTO_STEPS | 8 | ๐ Max steps for auto harness runs |
RLM_TUI_HARNESS_PREVIEW_STEPS | 6 | ๐ Steps shown in harness preview |
RLM_TUI_INPUT_DEBOUNCE_SECONDS | 0.0 | โจ๏ธ Input debounce delay |
RLM_TUI_CHAT_MAX_LINES | 2200 | ๐ RLM log line cap |
RLM_TUI_TOOL_MAX_LINES | 1600 | ๐งฐ Tool log line cap |
RLM_TUI_EVENT_MAX_LINES | 3200 | ๐ก Event log line cap |
๐ Copy to Clipboard¶
Copy the last assistant response with F7, Ctrl+Y, /copy, or the Copy button.
| Platform | Tool |
|---|---|
| ๐ macOS | pbcopy |
| ๐ง Linux | wl-copy, xclip, or xsel |