Repository navigation
feat(chat): surface org skills in the "/" picker - #4373
Merged
Merged
Conversation
The slash picker only listed MCP prompts + resources. Add the org skill catalog (home + public sets, incl. storefront) as a third category so users can insert a skill directly from chat. Selecting a skill inlines its SKILL.md (like a prompt) and appends a note pointing the agent at the sandbox dir where the skill's files are mounted, so it can read any referenced scripts/templates via bash. The catalog comes from the existing /fs/skills endpoint (buildSkillCatalog), so the picker never drifts from what the runtime exposes in <available-skills>. Skill fetch is fault-tolerant — a failure never takes down the prompts/resources picker. Co-Authored-By: Claude Opus 4.8 <[email protected]>
Applies the Important findings from the multi-perspective review: - Route the skills query key through a new KEYS.slashSkills constant instead of an inline array (convention). Distinct from KEYS.orgFsSkills, which caches an incompatible stripped shape on the same endpoint. - Namespace the suggestion list's React key by kind so a skill and a prompt/resource sharing a name no longer collide (added optional `kind` to BaseItem). - Harden the inlined SKILL.md: wrap the body in <skill-content> delimiters and frame it as untrusted reference data (public sets sync from external repos), and put the resolvable skill id in the header so the agent's "already loaded" dedup matches <available-skills>. - Add derive-parts.test.ts covering skillMentionToParts (happy path, empty/ whitespace content, null + wrong-shape metadata, prompt not misclassified). Co-Authored-By: Claude Opus 4.8 <[email protected]>
pedrofrxncx
approved these changes
Jul 8, 2026
Selecting a skill now inlines SKILL.md plus its sibling text/reference files (each wrapped in a <skill-file path="…"> delimiter) instead of just SKILL.md with a prose "cat the rest with bash" instruction. Scripts and binaries are left on disk and pointed to with one short line, so the agent isn't handed a manual step and doesn't get executable/binary content dumped into context. fetchOrgFsSkillFiles does a bounded recursive walk of the skill folder (depth/count/size caps, text extensions only), reads matches in parallel, and flags `truncated` when a cap trims the set. Co-Authored-By: Claude Opus 4.8 <[email protected]>
fetchOrgFsText is now only used internally by fetchOrgFsSkillFiles (the "/" skill picker switched from a single SKILL.md read to the folder walk), so its export is dead — knip fails the build on it. Make it module-private. Co-Authored-By: Claude Opus 4.8 <[email protected]>
Drop the verbose "Apply the skill / do NOT call the skill tool" framing.
Selecting a skill now inlines just like a prompt: a `[/name]` label + the
markdown/text docs baked in (each in a <skill-file path="…"> block). Files
left on disk (scripts, assets, oversized/binary) are surfaced as a compact
path list under the mount, so the agent knows what exists without re-reading
the skill.
fetchOrgFsSkillFiles now returns { files, omittedPaths } instead of a
truncated flag, and only inlines md/mdx/markdown/txt (everything else → path).
Co-Authored-By: Claude Opus 4.8 <[email protected]>
decocms Bot
pushed a commit
that referenced
this pull request
Jul 8, 2026
PR: #4373 feat(chat): surface org skills in the "/" picker Bump type: minor - decocms (apps/mesh/package.json): 3.106.1 -> 3.107.0 Deploy-Scope: web
tlgimenes
pushed a commit
that referenced
this pull request
Jul 16, 2026
…TS.md (#4475) Mined ~300 merged PRs for the delta between the first PR proposal and the work added before merge. The dominant shape: a first draft ships the happy path, then a hardening pass (often a different engineer who takes over the branch and merges — the vibecoder→engineer handoff) adds the same categories every time. Encoded those 9 categories as an actionable first-pass checklist, each citing a real PR (#4008, #4230, #4365, #4409, #4426, #4445, #4357, #4355, #4449, #4350, #4373, #4416, #4446, #4461, #4134, #4469). Covers: variant/edge-case handling, tenant/permission scoping, concurrency & silent-data-loss, test-per-fix + invert-bug-tests + real-PG, dead-code/knip, lifecycle symmetry + state reset, kill-switch/GC/git-exclude for risky infra, input validation vs over-engineering, compile-time type-safety. Co-authored-by: Claude Opus 4.8 (1M context) <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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
The chat
/picker only surfaced MCP prompts and resources. Skills (including the always-loadedstorefrontpublic set) were only discoverable by the agent via the<available-skills>catalog + theskilltool — the user had no way to insert one from chat.This adds the org skill catalog as a third category in the
/dropdown (order: prompts → resources → skills).Selection behavior (inline + file note)
Selecting a skill inlines its
SKILL.mdbody into the message (same model as MCP prompts/resources) and appends a note pointing the agent at the sandbox dir where the skill's files are mounted, so it can read any referenced scripts/templates via bash:This closes the gap of pure-inline (SKILL.md often references sibling files) without needing the agent to blind-call the
skilltool.Changes
use-org-fs.ts—OrgFsSkillCatalogEntry+fetchOrgFsSkillCatalog(reuses the existing/fs/skillsendpoint →buildSkillCatalog) andfetchOrgFsText(/read).mention-slash.tsx— thirdkind: "skill"; fetch skills in parallel, filter by name/id/description,fetchAndInsertSkillreadsSKILL.mdon select. Skill fetch is fault-tolerant (missingORG_FS_READdegrades to[], never breaks prompts/resources).mention/node.tsx—"skill"added tokind; skill chip is non-clickable (no edit dialog).derive-parts.ts—skillMentionToPartsrenders the inlined body + file note.Using the same
/fs/skillscatalog the runtime uses keeps the picker from ever drifting from<available-skills>.Testing
bun run --cwd=apps/mesh check→ exit 0bun run fmt→ cleanbun run lint→ 0 errors (7 pre-existing warnings, untouched files)Not yet done (flagging for review):
SKILL.md.derive-partsskill branch (pure, testable) — can add if wanted.🤖 Generated with Claude Code
Summary by cubic
Add org skills to the chat “/” picker and inline skill docs on select. Picking a skill inserts its
SKILL.mdand sibling text/markdown files as<skill-file>blocks and lists other files under the sandbox mount.New Features
/fs/skills(order: prompts → resources → skills); stays in sync with<available-skills>.storefront).SKILL.md+ sibling text files as<skill-file path="…">blocks; non-text/oversized files stay on disk and are listed under<sandboxPath>/.Bug Fixes
kind; addedkindtoBaseItem.KEYS.slashSkillsfor picker caching (distinct fromKEYS.orgFsSkills).fetchOrgFsTextexport to satisfy knip.Written for commit 14875b2. Summary will update on new commits.