feat: Add Agent Skills support to system prompt#125
Merged
spachava753 merged 2 commits intomainfrom Jan 4, 2026
Merged
Conversation
The system prompt now supports loading Agent Skills metadata via a new `skills` template function. This allows users to organize domain-specific instructions into reusable, shareable skill modules that follow the Agent Skills specification (agentskills.io). Skills are discovered by scanning directories for folders containing SKILL.md files with YAML frontmatter. The function outputs XML-formatted metadata including skill name, description, and path for agent awareness. Closes #124
…nd improvements The example system prompt now includes a Skills section demonstrating the new `skills` template function for loading Agent Skills metadata. This enables users to extend the agent's capabilities with reusable, modular skill packages. Additional updates align the example prompt with current best practices: clearer code mode description, guidance on understanding external libraries, improved AGENTS.md discovery via `find`, and consolidated reminders section.
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.
This PR adds support for the Agent Skills specification to CPE's system prompt templating.
What's New
A new
skillstemplate function that scans directories for skill folders and injects their metadata into the system prompt. Skills are reusable modules of instructions, scripts, and resources that extend the agent's capabilities for specialized tasks.Example usage in a system prompt template:
This renders XML-formatted skill metadata that makes the agent aware of available skills:
Why
Skills provide a standardized way to package domain-specific knowledge into self-contained, shareable modules. Unlike AGENTS.md files which are project-specific, skills can be reused across projects and shared with others. The agent loads full skill instructions on-demand only when relevant, reducing context usage.
Closes #124