Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 895cc4edc4
ℹ️ About Codex in GitHub
Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
| } else if (hashSkillMentions.length > 0) { | ||
| // Hash skill mentions: #skill-name (multiple allowed) | ||
| messageTextForSend = formatHashSkillInvocationText(messageText, hashSkillMentions); | ||
| skillMuxMetadata = buildHashSkillMentionsMetadata(hashSkillMentions.map((m) => m.name)); |
There was a problem hiding this comment.
Preserve original #skill text for display/highlight
Here the message is rewritten via formatHashSkillInvocationText and only hashSkillMentions metadata is stored. Because user-message display falls back to the stored message text when there’s no rawCommand, the chat history will show “Using skill …” instead of the original #skill tokens. That means the new highlight path never actually matches (no # remains) and users lose the exact input they typed. Consider preserving the original text (e.g., add a raw text field in metadata for hash-skill messages) or only rewrite the text sent to the model while keeping displayed content unchanged.
Useful? React with 👍 / 👎.
3c4cb51 to
cbaee6f
Compare
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