anomalyco / anomalyco/opencode
tui: slash-invoked skills drop trailing arguments after autocomplete
@simonklee is already working on this.
Since Sep 12, 2026.
- Dominant language
- TypeScript
- Stars
- 209k
- Forks
- 27.5k
- PR merge metrics
- PR metrics pending
Description
Summary
OpenCode V2 drops the trailing user request when a skill is invoked through slash autocomplete. The skill is activated, but text following the skill name never reaches the model.
Environment
- opencode version:
v2.0.2 - OS: Darwin 25.6.0 (
arm64) - Terminal: Ghostty (
TERM=xterm-ghostty,COLORTERM=truecolor) - Shell:
/bin/zsh - Install/channel: latest
- Active plugins: five local plugins; reproduced at the repository transport boundary independently of plugin execution
Reproduction
- Start OpenCode V2 with a slash-invocable skill.
- Select the skill through slash autocomplete and submit:
/skill-name This is a Test - Inspect the resulting model input.
Expected Behavior
The skill instructions should be activated and This is a Test should reach the model as the user's request.
Actual Behavior
The skill is activated, but This is a Test is discarded.
The slash parser correctly produces { name: "skill-name", arguments: "This is a Test" }. Both TUI paths then call session.skill with only the skill name:
packages/tui/src/component/prompt/index.tsxpackages/tui/src/mini/stream-v2.transport.ts
The session.skill protocol payload has no text or arguments field, so Session.skill appends only the skill instructions before resuming execution.
Additional Context
This is deterministic on v2.0.2 and was reproduced with a focused mini transport test.
This is a regression of #41245, which was closed after #41188 preserved skill arguments. The regression appears to have been introduced by #43523, merged on 19 August. That change switched slash autocomplete from inserting a prompt-bound skill attachment to inserting a plain slash invocation. Before that change, the completion-driven path sent the skill attachment and surrounding user text together.
Existing coverage tests only /tigerstyle without arguments and explicitly expects no user prompt. It does not cover /tigerstyle review this change.
Workaround: reference the skill with @skill-name or ask for it in natural language so the ordinary user prompt is preserved.
Related: #40463 reports similar argument loss in V1's older command-template implementation, but this report concerns the current V2 native skill activation path.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.