[BUG] Slash command autocomplete hint shows wrong argument description for multi-argument commands

Resolved 💬 3 comments Opened Oct 8, 2025 by sammywachtel Closed Oct 8, 2025

Preflight Checklist

  • [x] I have searched existing issues and this hasn't been reported yet
  • [x] This is a single bug report (please file separate reports for different bugs)
  • [x] I am using the latest version of Claude Code

What's Wrong?

Slash Command Autocomplete Displays Wrong Argument Description

When defining a slash command with multiple arguments, the autocomplete hint displays the second argument's description instead of the first argument's description.

---

💡 Real-World Example

📸 Screenshots

My command config (YAML):
<img width="773" height="285" alt="Command Config" src="https://github.com/user-attachments/assets/3f26c26d-3ab1-4a78-a203-8b8e8ee8f3bd" />

Autocomplete hint:
<img width="745" height="100" alt="Autocomplete Hint" src="https://github.com/user-attachments/assets/6600abeb-7d3c-4a12-bf78-65c67f4f72e4" />

---

From my /ap_exec command:

arguments:
  - name: scope
    type: string
    description: Scope folder under `.agent_process/work/`.
    required: true
  - name: iteration
    type: string
    description: Iteration folder name (e.g., `iteration_02`, `iteration_02_a`).
    required: true

The hint shows “Iteration folder name…” (the second argument) when I need to know about the scope parameter (the first argument).

---

🧭 Environment

  • Claude Code Version: 2.0.10 (Claude Code)
  • Platform: macOS 26.0.1 (25A362)
  • Command Location: .claude/commands/ (project-level)

---

⚠️ Impact

  • Confusing for users trying to understand command arguments
  • Forces users to read the command file directly to understand argument order
  • Reduces discoverability of proper command usage

---

🛠️ Suggested Fix

The autocomplete hint should either:

  1. Show the first argument's description (not the second), or
  2. Show the main command description instead of any argument description, or
  3. Show a formatted hint like:

``
/command <arg1> <arg2> - Main description
``

---

🔄 Workaround

The command still works correctly when invoked (e.g., /ap_exec scope iteration), but the hint is misleading during composition.

What Should Happen?

---

✅ Expected Behavior

The autocomplete hint should display:

/example    This is the FIRST argument description. (project)

Or ideally:

/example <first_arg> <second_arg>    Example command with two arguments. (project)

---

❌ Actual Behavior

The autocomplete hint displays:

/example    This is the SECOND argument description. (project)

The hint shows the second argument's description instead of the first, which is confusing when trying to understand what the first positional argument should be.

Error Messages/Logs

Steps to Reproduce

🧩 Steps to Reproduce

  1. Create a slash command with multiple required arguments in .claude/commands/example.md:

```yaml
---
name: /example
description: Example command with two arguments.
arguments:

  • name: first_arg

type: string
description: This is the FIRST argument description.
required: true

  • name: second_arg

type: string
description: This is the SECOND argument description.
required: true
---
Command body here...
```

  1. Type /example in Claude Code
  2. Observe the autocomplete hint

---

Claude Model

Sonnet (default)

Is this a regression?

I don't know

Last Working Version

_No response_

Claude Code Version

2.0.10

Platform

Anthropic API

Operating System

macOS

Terminal/Shell

PyCharm terminal

Additional Information

_No response_

View original on GitHub ↗

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