Interactive Commands
All commands are typed at the TUI prompt, prefixed with /. Unknown slash commands are submitted to the agent as regular text (useful for paths starting with /).
Session Management
| Command | Description |
|---|---|
/new | Start a new session (autosaves current if non-empty) |
/continue | Resume the most recent session (like cast -c, but mid-session) |
/fork | Create a new session from the current safe context and switch to it |
/worktree <name> | Switch current session into an isolated git worktree (list, remove <name>) |
/sessions | Session picker with type-to-filter search (by message text, project path, or id); switch or delete |
/clear | Clear conversation context (and save the cleared state) |
/compact | Force context compaction now (auto-triggers near the limit) |
/dream | Verify the recent project trajectory and consolidate durable project memory |
/distill | Verify repeated work and package high-confidence workflows as a skill or persona |
/undo | Undo the last turn: restore files from the most recent checkpoint and drop the last user message (and everything after it) |
/copy | Copy last assistant response to clipboard |
/current | Show all status bar data (even disabled segments) |
/quit, /exit | Save and exit |
/undo requires a checkpoint from the previous turn. In a Git workspace, every file is restored to its pre-turn tree without changing the user's Git index; files created during the turn are removed, while files that were untracked before the turn are restored. Outside Git, Cast restores files changed through its write and edit tools from shadow backups. Arbitrary changes made through bash or an MCP tool in a non-Git workspace cannot be reversed. /undo is refused while the agent is running (use /abort first) and is a no-op if there is nothing to undo.
Removing files created during the turn also removes any you created in that window — the restore cannot tell them apart, and they cannot be brought back. When there are such files, /undo names them and asks before proceeding; over the web API it refuses and asks you to re-run as /undo --force. --force skips the question.
/fork leaves the original session unchanged and starts an independent new session with the context currently sent to the model. It deliberately does not restore compacted-out history, copy checkpoints or pending pickers, or create a Git worktree: both sessions use the same working directory unless you switch one with /worktree.
Model and Provider
| Command | Description |
|---|---|
/model | Open model picker (shows current model) |
/model <name> | Switch to a specific model (validated) |
/subagent-model | Open model picker for sub-agents |
/subagent-model <name> | Switch sub-agent model |
/subagent-model-provider [name|off] | Show/change the saved provider used for the sub-agent model |
/plan-model [name|off] | Show/change the model used in plan mode |
/plan-model-provider [name|off] | Show/change the saved provider used for the plan model |
/reasoning | Change reasoning level (opens picker if model supports it) |
/reasoning-display (/rd) | Toggle reasoning blocks in the transcript — off by default since reasoning models stream a lot of auxiliary thinking that clutters the chat |
/reasoning-format | Select the reasoning request protocol for the active provider |
/provider | Open provider picker (switch, add, or delete providers) |
/provider add | Add a new provider (name → URL → key wizard) |
/provider delete | Delete a provider |
/provider <name> | Switch to a named provider |
Persona
| Command | Description |
|---|---|
/persona | Open persona picker |
/persona <name> | Switch to a specific persona |
See Personas for the full list.
Skills and MCP
| Command | Description |
|---|---|
/skills | Toggle skills on/off (multi-select). Also: list, enable/disable, uninstall, help |
/skills-sh | skills.sh — search / list-available / install / uninstall universal skills |
/skill:<name> [args] | Force-load and run a skill by name |
/mcp | Toggle MCP servers on/off. Also: list, enable/disable, uninstall, help |
/hooks | List lifecycle hooks; also enable/disable <id> and help |
/reload | Re-scan skills, rules, MCP servers, personas, and context files for cwd |
Bare /skills / /mcp = multi-select toggle. list is read-only. uninstall always confirms (picker or typed). See Skills and MCP.
Hot-reload vs /reload
You never need to quit cast or start a new session for these changes. The current chat continues.
| Change | Apply how |
|---|---|
/skills / /mcp toggle, enable / disable | Automatic (hot-reload) |
/skills uninstall, /mcp uninstall | Automatic |
New/edited files on disk: skills, mcp.json, rules, personas, context files (including npx skills add) | /reload refreshes the current resource catalog; persona overrides created in chat are picked up automatically on the next user message |
/reload only re-scans cwd resources — it does not reset the conversation.
Rules
| Command | Description |
|---|---|
/rules | List loaded rules with their apply mode, globs, and scope |
/rule:<name> | Invoke a rule by name (loads its full content into context) |
See Rules for rule types and creation.
Plan Mode
| Command | Description |
|---|---|
/plan | Enter plan mode (explore and plan only, no code changes) |
/build | Exit plan mode, restore full toolset |
/plan-model [name|off] | Show/change the model used while plan mode is active |
See Plan Mode for the full workflow.
Autonomous and Self-Verification
| Command | Description |
|---|---|
/goal <description> | Work autonomously toward a goal until it's done — bounded, never-ask |
/review | Ask the agent to review and verify its own work |
/code-review [range] [-- path…] | Review a diff: scope, groups and language rules computed before the model sees it |
/goal [N] <description> runs one autonomous turn that keeps iterating (tools → verify → fix → repeat) until the goal is met, without yielding back to ask for permission. At most one clarifying question (via the question tool) if the goal is genuinely ambiguous. A leading number (/goal 10 …) sets the iteration budget yourself — or use --steps N. By default the run is bounded to 25 model calls. Each model call can carry several tool calls, so the budget is a ceiling on LLM turns, not on individual tools. Near the cap the model is nudged to wrap up, and if it burns through anyway a warning fires and the run stops — it never loops forever on unproductive tool calls. Note: a tight budget can cut a long task short before it's finished, so size it to the task. Use it for start-to-finish tasks: "fix the tests", "set up the project and make the first commit", "implement X and verify it runs". Works in the TUI and the web composer.
/code-review [range] [-- path…] reviews a change rather than the session. What must not go wrong is computed first, in code: which files are in scope (staged, unstaged and untracked against HEAD, or any git range you pass), which are filtered as generated, vendored or binary — each named with its reason so nothing looks silently missed — how they group into review units (a large file alone; a test with its implementation; otherwise by directory, capped), and which language rules apply. Only the judging is left to the model.
Findings go through a review_report tool that checks each one against the file: a line that doesn't hold is moved to where the quoted code actually is, and a finding whose code is nowhere in the file — or whose file is outside the scope — is dropped before you ever read it. A finding on a line the change didn't touch is kept and flagged as context.
/code-review # working tree vs HEAD
/code-review main..feature # a branch's changes
/code-review HEAD~3..HEAD -- src/ # narrow a large change to one subtreeRules live in prompts/review-rules/ — one document per language, loaded only for the languages actually in the diff, plus a shared default whose two standing orders are precision over recall (a false positive costs the trust you need for the next finding) and don't duplicate the toolchain (whatever the linter, formatter, compiler or test run already says is not a review comment). Add your own by dropping a file in that directory.
/review asks the agent to verify its own most recent work: identify what changed (git diff / touched files), find and run the project's test and lint commands, and report honestly what was verified and what remains open — it never claims a check it didn't actually run.
Steering
Just type. A plain message sent while the agent is running is steered into the running turn — no command needed, in the TUI and the web UI alike. /steer stays for when you want to be explicit (and for scripts).
These commands work while the agent is running:
| Command | Short | Description |
|---|---|---|
/steer <message> | /s | Inject a message into the running turn |
/queue <message> | /q | Queue a message for after the current turn |
/queue-reset | /qr | Clear the message queue |
/abort, /stop | Stop current agent run |
/steer interrupts the current turn with new context — the message is injected immediately into the conversation, and the agent sees it on the next tool-call iteration. Useful for correcting course mid-execution.
/queue saves a message to run after the agent finishes its current turn. The message becomes a new turn automatically.
If nothing is running, both /steer and /queue submit the message as a normal prompt.
/abort stops the current run and clears both the steering and follow-up queues — anything queued before the abort is discarded.
Both steering and follow-up messages reset the doom loop counter — repeating a failing command after user guidance is treated as a new attempt, not a loop.
Context and Usage
Token usage and context size are shown automatically in the TUI status bar (prompt tokens in, completion tokens out, prompt-cache hit %, cost, context percentage, tokens/second, and sub-agent tokens).
Use /statusbar to toggle individual segments on/off and reorder them — useful on narrow terminals where the full bar overflows. Segments can be moved between the left and right sides of the bar with ←/→, and reordered within each side with j/k. Default: persona, mode, model (left) and elapsed (right); enable others via /statusbar.
| Command | Description |
|---|---|
/current | All status bar data: model, context, tokens in/out with cache %, cost, sub-agent tokens, repo, session |
/context | The AGENTS.md / CLAUDE.md files loaded for this directory, with their size, plus any file that could not be read |
Configuration
| Command | Description |
|---|---|
/permissions | Open permission mode picker |
/permissions default | Switch to gated mode (confirm dangerous commands) |
/permissions bypass | Switch to bypass mode (no confirmation) |
/web | Toggle web tools (web_search, web_fetch) on/off |
/web-search-provider | Switch the web_search backend between DuckDuckGo (free, rate-limited), Tavily (API key, 1000 free/month), and Brave Search (API key) |
/web-fetch-provider | Switch web_fetch between Jina Reader and direct local fetch |
/statusbar | Toggle and reorder status bar segments (multi-select picker) |
/theme | Open theme picker |
/theme <id> | Switch to a specific theme |
/turn-cap [N|reset] | Show/set the per-turn iteration safety cap (default 500, 10–10000); applies on the next agent call. Also configurable via maxTurnIterations in settings.json and Settings → Bash |
Utility
| Command | Description |
|---|---|
/repo | Show cwd, git branch, dirty state, remote, and HEAD |
/keys | List all keybindings |
/help | Show the command list |
/ssh | Manage SSH hosts — list, add, remove (persists to ~/.cast/ssh.json) |
Keybindings
| Action | Keys |
|---|---|
| Previous / next prompt | ↑ / ↓ (moves within a multi-line draft first; moves the selection while the command palette is open) |
| Cursor left/right | ← / → (or Ctrl+B / Ctrl+F) |
| Word left/right | Alt+← / Alt+→ (or Ctrl+← / Ctrl+→) |
| Line start/end | Home / End (or Ctrl+A / Ctrl+E) |
| Delete char | Backspace / Delete |
| Delete word | Ctrl+W / Alt+Backspace |
| Delete to line start | Ctrl+U |
| Delete to line end | Ctrl+K |
| Submit | Enter |
| Line break | Shift+Enter or Alt+Enter — or end the line with \ and press Enter, which works on any terminal |
| Stop turn (2×) | Esc |
| Clear the input | Ctrl+L |
| Exit (2× to confirm) | Ctrl+C |
| Attach image | Ctrl+G |
| Complete a command, or a file path | Tab |
Esc stops the current turn while generating (twice within 2s); Ctrl+L clears the input in any state.
Tab completes a slash command in the palette, and a path-shaped token anywhere else (one containing /, or starting with ~) — ambiguous ones list what is left to choose from. Tab in ordinary prose does nothing.
Line breaks: Shift+Enter and Alt+Enter need a terminal that reports modified Enter (the Kitty keyboard protocol or modifyOtherKeys); everywhere else, end the line with a backslash and press Enter.
A long draft wraps at the terminal's edge, on word boundaries. The composer draws at most three rows and follows the cursor, with ↑/↓ in the prompt column where the draft continues past them — ↑/↓ move between rows, wrapped ones included.
Ctrl+C — press twice within 2s to exit. Does not stop a turn — use Esc for that.
During a Running Agent
Typing a plain message steers the running turn — no command needed. Besides that, these commands are accepted while the agent is executing:
/steer//s— inject context/queue//q— queue follow-up/queue-reset//qr— clear queue/abort//stop— stop the run
All other input is rejected with a notice. Use Esc to stop the current turn (clears input when idle).