Docs: Clarify that only users, not the AI, can invoke slash commands

Resolved 💬 3 comments Opened Aug 5, 2025 by coygeek Closed Nov 30, 2025

Title: Docs: Clarify that only users, not the AI, can invoke slash commands

Body:

Hi Claude Code team,

I'd like to suggest a small but important clarification for the documentation regarding slash command invocation.

The Issue

Currently, the documentation clearly explains what slash commands are and how a user can invoke them. However, it doesn't explicitly state that the AI model itself cannot decide to run a slash command.

A new user might reasonably assume they can instruct the model to perform an action that maps to a slash command (e.g., prompting "Okay, now create a pull request for these changes," expecting Claude to run /pr on its own). This can lead to confusion when the model instead tries to use its other tools (like git) or explains that it can't perform the action in that way.

Suggested Solution

I recommend adding a Note or Tip block to the en/docs/claude-code/slash-commands documentation page to make this distinction clear. This could be placed near the top of the page, after the main description, to set the right expectation for users early on.

Suggested Text:

<Note>
  **Who can run slash commands?**

  Slash commands must be invoked directly by the user in the prompt input. The Claude AI model cannot decide to run a slash command on its own as part of its response or workflow.

  For example, you must type `/review` yourself. You cannot ask the model, "please run a review," and expect it to invoke the slash command. Instead, the model will use its available tools (like `Read`, `Grep`, etc.) to perform the review task based on your natural language instruction.
</Note>

This clarification would help users better understand the interaction model and the distinction between user-initiated commands and AI-initiated tool usage.

Thanks for creating such a powerful and useful tool

View original on GitHub ↗

This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗