Skip to content

refactor: replace fetch_instructions with skill tool and built-in skills#10913

Merged
hannesrudolph merged 15 commits intomainfrom
refactor/replace-fetch-instructions-with-built-in-skills
Jan 29, 2026
Merged

refactor: replace fetch_instructions with skill tool and built-in skills#10913
hannesrudolph merged 15 commits intomainfrom
refactor/replace-fetch-instructions-with-built-in-skills

Conversation

@hannesrudolph
Copy link
Copy Markdown
Collaborator

@hannesrudolph hannesrudolph commented Jan 23, 2026

Closes #11062

Summary

image image

This PR replaces the fetch_instructions tool with a new unified skill tool system, making it easier for Roo to load specialized instructions for common tasks.

What Changed

New Skill Tool

  • Roo now uses a skill tool to load instructions for tasks like creating MCP servers or custom modes
  • Skills can be built-in (shipped with the extension), global (user-defined), or project-specific
  • Skills are automatically approved, removing the need for manual confirmation when loading instructions

Built-in Skills

Two built-in skills are now included:

  • create-mcp-server: Instructions for creating MCP servers that expose tools and resources
  • create-mode: Instructions for creating custom modes in Roo Code

Removed Settings

  • The "Enable MCP Server Creation" checkbox has been removed from MCP settings
  • MCP server creation instructions are now always available via the built-in skill when needed

New Diff Toggle Setting

  • Added a diffEnabled setting to control whether diff-based editing tools are available

How This Affects You

For most users: No action required. Roo will automatically use the new skill system when you ask it to create MCP servers or custom modes.

For users with custom skills: Your existing project and global skills continue to work and take priority over built-in skills.

For users who disabled MCP server creation: The toggle has been removed. If you don't want Roo to create MCP servers, simply don't ask it to—the instructions are only loaded on demand.

Why This Change

  • Consistency: Skills now work the same way whether they're built-in, global, or project-specific
  • Extensibility: The skill system is more flexible and easier to extend with new capabilities
  • Simplicity: Fewer settings to manage—instructions are loaded when needed rather than requiring upfront configuration

Follow-up Work

⚠️ A follow-up PR is needed to update the mode creation and MCP server creation instructions in the built-in skills to reflect current best practices and documentation.

@dosubot dosubot bot added the size:XL This PR changes 500-999 lines, ignoring generated files. label Jan 23, 2026
@roomote-v0
Copy link
Copy Markdown
Contributor

roomote-v0 bot commented Jan 23, 2026

Oroocle Clock   Follow along on Roo Cloud

Re-review: 1 new issue found.

  • skill tool schema: args is documented optional but is required (see bd37b049a0)
Previous reviews

Mention @roomote in a comment to request specific changes to this pull request or fix all unresolved issues.

@hannesrudolph hannesrudolph force-pushed the refactor/replace-fetch-instructions-with-built-in-skills branch from d876abc to 99b424c Compare January 23, 2026 23:37

// Build approval message
const toolMessage = JSON.stringify({
tool: "skill",
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

SkillTool sends the approval payload as { "tool": "skill", ... }, but ClineSayTool in @roo-code/types does not include a "skill" variant and the webview ChatRow renderer has no case for it. In practice this can render as an unknown tool request (or fail type-safely elsewhere) when the UI tries to parse/display the approval.

Fix it with Roo Code or mention @roomote and request a fix.

@hannesrudolph hannesrudolph changed the title refactor: replace fetch_instructions tool with built-in skills refactor: replace fetch_instructions with skill tool and built-in skills Jan 24, 2026
@hannesrudolph hannesrudolph force-pushed the refactor/replace-fetch-instructions-with-built-in-skills branch from b6f7fe0 to a0d5728 Compare January 24, 2026 00:56
@dosubot dosubot bot added size:XXL This PR changes 1000+ lines, ignoring generated files. and removed size:XL This PR changes 500-999 lines, ignoring generated files. labels Jan 24, 2026
@hannesrudolph hannesrudolph force-pushed the refactor/replace-fetch-instructions-with-built-in-skills branch from d83a9c5 to 57f977f Compare January 24, 2026 02:32
@dosubot dosubot bot added size:XL This PR changes 500-999 lines, ignoring generated files. size:XXL This PR changes 1000+ lines, ignoring generated files. and removed size:XXL This PR changes 1000+ lines, ignoring generated files. size:XL This PR changes 500-999 lines, ignoring generated files. labels Jan 28, 2026
- Add built-in skills (create-mcp-server, create-mode) following slash commands pattern
- Update SkillsManager to merge built-in skills with user skills
- Remove FetchInstructionsTool and related infrastructure
- Remove enableMcpServerCreation setting and UI checkbox
- Remove auto-approval logic for fetchInstructions
- Update system prompt sections to remove fetch_instructions references

Built-in skills are now available through the skills system with
override precedence: project > global > built-in
- Remove <location> from built-in skills in prompt (only show for file-based skills)
- Add 'skill' case to ChatRow.tsx for tool approval UI rendering
- Add 'skill' to ClineSayTool union type and interface
- Update i18n keys from 'instructions' to 'skill'
…L.md files

- Add generate-built-in-skills.ts script to parse SKILL.md files and generate TypeScript
- Add prebundle npm script to auto-generate before builds
- Create built-in/create-mode/SKILL.md for mode creation instructions
- Create built-in/mcp-builder/ with comprehensive MCP server development guide
- Add project-level .roo/skills/mcp-builder/ skill
- Add tests for the generation script
- Update built-in-skills.ts to be auto-generated (DO NOT EDIT DIRECTLY)

The source of truth is now the SKILL.md files. Run 'pnpm generate:skills' to regenerate.
The generator now runs prettier on the output file after generation.
This ensures the generated file is already formatted and won't change
when the pre-commit hook runs prettier via lint-staged.
@mrubens
Copy link
Copy Markdown
Collaborator

mrubens commented Jan 29, 2026

@roomote please resolve the merge conflicts with origin/main

@roomote-v0
Copy link
Copy Markdown
Contributor

roomote-v0 bot commented Jan 29, 2026

Fixaroo Clock   See task on Roo Cloud

Resolved merge conflicts with origin/main. All local checks passed.

View commit | Revert commit

@dosubot dosubot bot added size:XXL This PR changes 1000+ lines, ignoring generated files. and removed size:XL This PR changes 500-999 lines, ignoring generated files. labels Jan 29, 2026
@github-actions
Copy link
Copy Markdown
Contributor

🚀 Preview deployed!

Your changes have been deployed to Vercel:

Preview URL: https://roo-code-website-ild3l82xi-roo-code.vercel.app

This preview will be updated automatically when you push new commits to this PR.

description: ARGS_PARAMETER_DESCRIPTION,
},
},
required: ["skill", "args"],
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In the OpenAI tool schema, args is documented as optional but is currently included in required, which forces callers to always provide it (usually as null). Making args truly optional avoids schema/documentation mismatch and reduces invalid tool payload risk if other tool-callers omit it.

Fix it with Roo Code or mention @roomote and request a fix.

@hannesrudolph hannesrudolph merged commit 67e568f into main Jan 29, 2026
17 checks passed
@hannesrudolph hannesrudolph deleted the refactor/replace-fetch-instructions-with-built-in-skills branch January 29, 2026 14:48
@github-project-automation github-project-automation bot moved this from Triage to Done in Roo Code Roadmap Jan 29, 2026
@github-project-automation github-project-automation bot moved this from New to Done in Roo Code Roadmap Jan 29, 2026
mini2s referenced this pull request in zgsm-ai/costrict Feb 1, 2026