diff --git a/.agents/skills/write-skill/SKILL.md b/.agents/skills/write-skill/SKILL.md new file mode 100644 index 00000000000..958e667e2bc --- /dev/null +++ b/.agents/skills/write-skill/SKILL.md @@ -0,0 +1,63 @@ +--- +name: write-skill +description: Use when creating, updating, or reviewing agent skills +--- + +# Write Skill + +- Use this skill when creating, updating, or reviewing skill files +- When authoring a skill, include in its description when it should and should not be used +- Keep agent skills short and concise +- Keep skill prose under 200 lines, excluding reference tables; move additional guidance into references +- Use a `references` sub-folder in a skill when it becomes too long or needs to link out to different topics +- Links to references must be kept up-to-date as files are created, updated, or removed +- References must include a table of contents as the first section +- Each entry in the table of contents should include the section heading's line number in the reference file so agents can make targeted reads +- After creating or editing a reference, update its table of contents and verify every entry's line number against the section heading in the final formatted file +- If using a references folder, `SKILL.md` must include: + - A references section + - A table in this section that provides a name/link to the reference and a description for when to use it +- Use the references table to select files relevant to the current task; do not load all references by default +- Read each selected reference's table of contents first, then use its line numbers to read only the relevant sections +- Read additional sections or linked references only when needed to complete the task +- If line numbers are stale, locate the section by its heading +- Avoid duplicating information across references, instead consolidate or extract out information +- Always report contradictions in references and recommend a resolution. Obtain permission before modifying files to resolve them +- Write descriptions that identify the specific tasks that should trigger the skill. Avoid broad wording that causes it to load for unrelated work + +## Examples + +### SKILL.md + +```md +--- +name: skill-name +description: Information about the skill, when to use it, and how to use it +--- + +# Skill name + + + +## References + +| Name | Description | +| :--- | :---------- | +| [Reference](./references/reference.md) | A brief description of the reference and when to use it | +``` + +### .agents/skills//references/.md + +```md +# Reference + +Brief overview of the reference + +## Table of Contents + +- [Example](#example), L:11 + + + +## Example +``` diff --git a/.github/copilot-instructions.md b/.github/copilot-instructions.md index 457e896bfb4..138e44949eb 100644 --- a/.github/copilot-instructions.md +++ b/.github/copilot-instructions.md @@ -2,6 +2,12 @@ **ALWAYS reference these instructions first and fallback to search or bash commands only when you encounter unexpected information that does not match the info here.** +## User feedback on skills + +- When a user explicitly corrects guidance from an active skill or requests a conflicting approach, point out the difference and ask whether it is a one-off exception or a lasting change +- If it is a lasting change, propose a specific update to the relevant skill or reference and obtain permission before editing +- Do not infer permanent guidance from a single action or exception + ## Repository Organization The project is the React implementation of GitHub's Primer Design System authored as a monorepo with separate npm workspaces. diff --git a/.gitignore b/.gitignore index b5ad54840a5..78cc2319772 100644 --- a/.gitignore +++ b/.gitignore @@ -14,9 +14,6 @@ css/ # Dependencies node_modules -# Local agent workspaces -.agents - # Gatsby public/ diff --git a/package-lock.json b/package-lock.json index f827d200403..a214722b049 100644 --- a/package-lock.json +++ b/package-lock.json @@ -83,7 +83,7 @@ "react-dom": "^18.3.1" }, "devDependencies": { - "@primer/react": "38.40.1", + "@primer/react": "38.42.0", "@primer/styled-react": "1.1.1", "@types/react": "^18.3.11", "@types/react-dom": "^18.3.0", @@ -97,7 +97,7 @@ "name": "example-nextjs", "version": "0.0.0", "dependencies": { - "@primer/react": "38.40.1", + "@primer/react": "38.42.0", "@primer/styled-react": "1.1.1", "next": "^16.3.8", "react": "^19.2.8", @@ -140,7 +140,7 @@ "version": "0.0.0", "dependencies": { "@primer/octicons-react": "^19.28.1", - "@primer/react": "38.40.1", + "@primer/react": "38.42.0", "clsx": "^2.1.1", "next": "^16.3.8", "react": "^19.2.8", @@ -31980,13 +31980,13 @@ }, "packages/mcp": { "name": "@primer/mcp", - "version": "1.1.0", + "version": "1.1.1", "dependencies": { "@modelcontextprotocol/client": "^2.2.0", "@modelcontextprotocol/server": "^2.0.0", "@primer/octicons": "^19.15.5", "@primer/primitives": "10.x || 11.x", - "@primer/react": "^38.38.0", + "@primer/react": "^38.42.0", "cheerio": "^1.0.0", "turndown": "^7.2.0", "zod": "^4.3.5" @@ -32051,7 +32051,7 @@ }, "packages/react": { "name": "@primer/react", - "version": "38.40.1", + "version": "38.42.0", "license": "MIT", "dependencies": { "@github/mini-throttle": "^2.1.1",