Skip to content

docs(roadmap): add #460 — bare_slash_command_guidance lookup misses spec.aliases; claw yes/no/cwd/marketplace burn billable tokens; claw skill/y/n give nonsense did-you-mean#3073

Open
Yeachan-Heo wants to merge 1 commit into
mainfrom
docs/roadmap-460-slash-alias-guidance-lookup-misses-aliases
Open

docs(roadmap): add #460 — bare_slash_command_guidance lookup misses spec.aliases; claw yes/no/cwd/marketplace burn billable tokens; claw skill/y/n give nonsense did-you-mean#3073
Yeachan-Heo wants to merge 1 commit into
mainfrom
docs/roadmap-460-slash-alias-guidance-lookup-misses-aliases

Conversation

@Yeachan-Heo
Copy link
Copy Markdown
Contributor

ROADMAP pinpoint #460bare_slash_command_guidance checks spec.name only, never spec.aliases

Dogfooded for the 2026-05-24 10:30 Clawhip pinpoint nudge (message 1508054486134947951).

Triage matrix

Verb Spec relationship Expected Actual Bug class
skills spec name is a slash command. /skills ✅ correct
skill alias of /skills is a slash command. /skills unknown subcommand. Did you mean skills wrong guidance class
plugin spec name is a slash command. /plugin ✅ correct
marketplace alias of /plugin is a slash command. /plugin missing_credentials silent LLM fallthrough
approve spec name is a slash command. /approve ✅ correct
yes alias of /approve is a slash command. /approve missing_credentials silent LLM fallthrough
y alias of /approve is a slash command. /approve unknown subcommand. Did you mean system-prompt nonsense suggestion
deny spec name is a slash command. /deny ✅ correct
no alias of /deny is a slash command. /deny missing_credentials silent LLM fallthrough
n alias of /deny is a slash command. /deny unknown subcommand. Did you mean init, agents, sandbox nonsense suggestion
workspace spec name is a slash command. /workspace ✅ correct
cwd alias of /workspace is a slash command. /workspace missing_credentials silent LLM fallthrough

Root cause (traced)

rust/crates/rusty-claude-cli/src/main.rs:1135-1137:

let slash_command = slash_command_specs()
    .iter()
    .find(|spec| spec.name == command_name)?;  // ← only checks spec.name

Five-line fix: change to spec.name == command_name || spec.aliases.contains(&command_name).

Source spec data already correct in rust/crates/commands/src/lib.rs:

  • L248: SlashCommandSpec { name: "skills", aliases: &["skill"], … }
  • L232: name: "plugin", aliases: &["plugins", "marketplace"]
  • L535: name: "approve", aliases: &["yes", "y"]
  • L542: name: "deny", aliases: &["no", "n"]
  • L689: name: "workspace", aliases: &["cwd"]

The data is right; only the lookup helper is wrong.

Why distinct from existing items

None of these cover slash-command ALIAS lookup failing the canonical-name comparison. The bug here is even worse than #108: in #108 the unknown verb is genuinely unknown to the system; in #460 the verb IS known (it's a documented alias listed in --help as aliases: /yes, /y for /approve) but the bare-CLI lookup helper doesn't consult the alias field.

So the system silently disagrees with itself: --help advertises /yes as a valid approval slash command, but claw yes (the obvious "use that from CLI" attempt) burns LLM tokens.

Why it matters

  1. claw yes, claw no, claw cwd, claw marketplace burn billable tokens with provider keys configured. Same silent-token-burn pathology as 合影 #108 and 前排留念 #117 but specifically for documented slash-command aliases.
  2. /help output explicitly advertises these aliases: /approve … (aliases: /yes, /y). Documentation contract violated.
  3. Did-you-mean suggestions for alias-fallthrough are nonsense. claw y → "Did you mean system-prompt". claw n → "Did you mean init, agents, sandbox".
  4. System self-inconsistency: REPL slash dispatch correctly resolves /skill → /skills via aliases. Tab-completion (slash_command_completion_candidates_with_sessions) enumerates aliases. Only the CLI bare-verb-to-slash-guidance helper misses the alias field — the singular violator in a system that otherwise honors aliases consistently.
  5. marketplace worst case: specifically a documented /plugin alias, claw marketplace is exactly what someone exploring "is there a marketplace?" would type. Silent token burn.

Required fix shape (full detail in ROADMAP entry)

(a) Extend lookup: spec.name == command_name || spec.aliases.contains(&command_name). (b) When formatting guidance, use spec.name for the /<canonical> suggestion: "\claw yes` is a slash command. Start `claw` and run `/approve` inside the REPL.". (c) Optional: include alias in message. (d) Add a claw doctorself-check that walks everyspec.aliases[]and assertsbare_slash_command_guidance(alias)returnsSome(_)`. (e) Regression matrix from table.

Acceptance check

for v in skill marketplace yes y no n cwd; do
  out=$(claw $v --output-format json </dev/null 2>&1 | head -1)
  echo "$out" | grep -q 'is a slash command' || echo "MISS: $v$out"
done

Should print no MISS lines.


[repo owner's gaebal-gajae (clawdbot) 🦞]

…pec.aliases; claw yes/no/cwd/marketplace burn billable tokens with provider keys; claw skill/y/n give nonsense did-you-mean
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants