🤖 feat: support #skill mentions #2009
Open
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Summary
Adds
#skill-namementions in ChatInput (autocomplete + insertion) and wires them through to the backend as real agent-skill invocations, consistent with existing/<skill-name>behavior.Background
We already support skill invocations via unknown slash commands (
/<skill-name>). This adds a more natural inline syntax (#skill-name) that can appear multiple times in one message.Implementation
#skilltokens at the cursor and extracting valid mentions.#skillusing the existingCommandSuggestionsUI./<skill>invocation is present) to make the intent explicit to the model.muxMetadata(type: "agent-skill-set") with all mentioned skills.AgentSession) materializes those skills into synthetic<agent-skill ...>snapshot messages (deduped) before the user message, so skill content is actually inserted into the prompt.MessageQueuetreatsagent-skill-setlikeagent-skillto avoid leaking skill metadata across queued messages.Validation
make static-checkbun test src/common/utils/hashSkillMentions.test.ts src/browser/utils/hashSkillSuggestions.test.tsTEST_INTEGRATION=1 bun x jest tests/ui/hashSkillSuggestions.integration.test.tsGenerated with
mux• Model:openai:gpt-5.2• Thinking:high• Cost:$25.72