Skip to content

Slash Commands

Wayland Core intercepts lines that start with / before the engine sees them. A line with a leading / and a recognized command word is dispatched to a handler. Anything else is forwarded to the agent loop as ordinary input.

Two layers exist:

  • Engine slash dispatcher (8 built-ins): active in the TUI, REPL, and one-shot modes.
  • TUI command registry (27 built-ins): the source of truth for the interactive palette and /help inside the full-screen TUI. These are not all individually wired as engine handlers; they describe available actions and route through the TUI event system.

A slash command must start at column 0 with no leading whitespace. A bare /, a / followed immediately by whitespace, or any line with leading whitespace before the / are all treated as regular input.

/style terse # matches: command=style, args=[terse]
/style terse # not a command (leading space)
/ style # not a command (space after slash)
/ # not a command (bare slash)

Arguments after the command word are split on whitespace and passed to the handler. SlashInvocation carries command, args, and the raw line. Source: crates/wcore-agent/src/slash/mod.rs.

If you mistype a TUI command the registry suggests the closest match using Damerau-Levenshtein distance (maximum distance 2). A typo like /repmap produces “did you mean /repomap?”. Ties are not suggested.


These 8 commands are handled by Dispatcher::with_builtins() in wcore-agent and work in every run mode: TUI, --no-tui REPL, and one-shot. The dispatcher is upgraded at session start to Dispatcher::with_runtime(...) which wires /memory, /plugin, and /skill to the live engine surfaces rather than stub responses.

Print all registered commands with one-line descriptions.

/help

Output is sorted alphabetically. Source: crates/wcore-agent/src/slash/help.rs.

List built-in agent personas, show a specific one, or create a new user-defined agent through an interactive flow.

/agent # list all built-in agents
/agent list # same as above
/agent show <name> # print system prompt, model, max_turns, allowed_tools
/agent new # interactive six-step flow; saves to ~/.wayland/agents/<name>.toml

The /agent new flow prompts for: description, optional built-in to inherit from, extra tools, model override, max-turns override, and save name. Blank at any prompt aborts. A name that clashes with a built-in is rejected. After saving, the agent is available as --agent=<name> on the next session start. Source: crates/wcore-agent/src/slash/agent.rs.

Inject a style directive into the current session’s system prompt.

/style terse # concise responses
/style playful # informal tone
/style focused # minimal commentary
/style match-me # mirror the user's own tone
/style # print the four options

An unknown style argument returns an error. The directive is applied via engine.inject_history; it affects subsequent turns, not the current one. Source: crates/wcore-agent/src/slash/style.rs.

Inspect or clear memory partitions for the current session.

/memory # show all partitions (same as show)
/memory show # show procedural and core (user model) counts
/memory show <partition> # show one partition (argument accepted, display is summary)
/memory clear <partition> # clear all tiers of the named partition

Valid partition names: working, episodic, semantic, procedural, core.

/memory clear requires a partition name; omitting it returns an error. The clear operation removes all tier rows for that partition (session, project, global tiers, for combinations that exist) and prints a per-tier row count. Source: crates/wcore-agent/src/slash/memory.rs.

Inspect loaded plugins. Install and remove operations require a CLI restart to take effect, so /plugin install and /plugin remove describe the correct CLI workflow rather than mutating session state directly.

/plugin # same as list
/plugin list # list runtime plugin handles loaded in this session
/plugin install <name> # prints the CLI command to run; requires restart
/plugin remove <name> # prints the CLI command to run; takes effect next session

Built-in static plugins are wired directly into the engine and are not enumerated by /plugin list. Source: crates/wcore-agent/src/slash/plugin.rs.

Browse the loaded skill catalog.

/skill # same as list
/skill list # list all skills with source and visibility
/skill show <name> # print description, paths, source, file_path, and visibility
/skill run <name> # if the skill exists, gives the correct invocation path

Skill dispatch flows through the agent’s SkillTool to preserve the approval and procedural-memory pipeline. /skill run confirms the skill exists in the catalog and instructs you to ask the agent to use it directly (for example: “use the <name> skill”). It does not bypass the tool-call path. Source: crates/wcore-agent/src/slash/skill.rs.

Drop the conversation history and clear the screen. The engine’s message buffer is emptied; this is not undoable.

/clear

End the session immediately.

/exit

/quit is also accepted in REPL mode via the repl_loop at main.rs:1323.


The interactive TUI has 27 built-in commands registered in CommandRegistry::with_builtins(). These feed the command palette (/ in the Workspace surface), the /help grouped listing, and the “did you mean” typo corrector. User-invocable skills extend the registry at runtime via CommandRegistry::register.

Commands are grouped into six intent sections, listed here in the order the palette and /help render them. Only /rewind is marked destructive.

CommandDescription
/resumeReopen a past session.
/rewindRestore files to an earlier snapshot. Destructive.
/newStart fresh, keep this provider.
/compactFold context now, keep decisions.
/quitEnd this session.
/exitEnd this session (alias for muscle memory).
CommandDescription
/modelSwitch model.
/providerSwitch provider.
/profileLoad a saved profile (fast, review).
CommandDescription
/repomapRebuild the codebase symbol index.
/memoryShow what Wayland remembers about this project.
/costTokens and spend this session.
CommandDescription
/toolsList tools, toggle permissions.
/mcpManage MCP servers.
/authConnect a provider via OAuth.
/skillsBrowse and run skills.
/pluginsInstall or remove plugins.
/hooksManage hooks.
/voiceToggle voice capture (same as Ctrl+Space).
CommandDescription
/planSwitch to plan-before-acting mode (read-only agent pass).
/modeCycle approval mode: Default, Auto-edit, Force.
/theme [light|dark|auto]Switch the live color theme without a restart.
/configOpen the settings screen.
/setupRe-run the onboarding flow.

/theme accepts light, dark, or auto as an argument. A missing or unrecognized argument falls back to auto. Source: crates/wcore-cli/src/tui/commands/mod.rs.

CommandDescription
/doctorCheck provider connectivity, API keys, and MCP server health.
/replayInspect a recorded session trace.
/helpShow keys and commands for the current screen.

The TUI registry finds the closest known command to any unrecognized input using Damerau-Levenshtein distance (insertions, deletions, substitutions, and adjacent transpositions each count as 1). Suggestions are only made when one command is unambiguously closer than all others and within distance 2. When two commands tie at the same distance the dispatcher returns “unknown” rather than guessing.