CLI tool to extend VS Code Copilot agent plugins with repo-specific overrides.
VS Code installs agent plugins in a user-level directory, and adding any customization means modifying the external source directory and these changes are overwritten by any future updates.
agext-cli lets you layer repo-specific overrides on top of any installed agent plugin — without forking or modifying the originals — so every agent behaves exactly the way your project needs.
- Scaffold — Interactively generate a
.extend.yamloverride file from any installed agent plugin - Apply — Merge all
.extend.yamloverrides with base agents and write repo-local.mdagent files - Subagent Remap — Automatically update subagent and handoff references when extended agents are renamed, creating or editing
.extend.yamlfiles as needed - Additive merge — Tools and agents lists are unioned (no duplicates); descriptions and models are replaced
- Prepend / append instructions — Inject repo-specific markdown before or after the agent body
- AI editor pass — Optionally rewrite the merged output with a Copilot SDK model
- Cycle detection — Warns about circular subagent references during remap
Requires Node.js >= 18.
You can install the global cli agext
npm install -g agext-cli
agext -hor run directly with npx.
npx agext-cliInteractively create a .extend.yaml file from an installed agent plugin:
agext scaffold- Lists installed plugins from
~/.vscode/agent-plugins/ - Select a plugin, then an agent
- Generates
.agext/extend/{plugin-name}/agents/{agent-name}.extend.yaml
Apply all extensions to generate repo-local agent files:
agext applyScans .agext/extend/ for .extend.yaml files, merges each with its base agent, and writes the result to .github/agents/{agent-name}.md.
Update subagent references across .extend.yaml files after agents are renamed:
agext remap- Reads existing
.extend.yamlfiles to determine agent renames (vianame-suffix) - Builds a dependency map of subagent and handoff references for each plugin
- Detects and reports circular references
- Creates or updates
.extend.yamlfiles to remap subagent/handoff names so they point to the renamed agents
Run agext apply afterwards to regenerate the agent files.
# Suffix appended to the agent name (default: " - Repo Extended")
name-suffix: " - Repo Extended"
# Replaces the base agent description
description: "Custom description"
# Additional tools (merged with base, no duplicates)
tools:
- browser
# Additional agents (merged with base, no duplicates)
agents:
- MyCustomAgent
# Replaces the base agent model
model:
- Claude Sonnet
- claude-sonnet
# Markdown inserted before the agent body
prepend-instructions: |
Setup instructions here.
# Markdown inserted after the agent body
append-instructions: |
Your repo-specific instructions here.
# Optional: AI edit pass after merge (uses GitHub Copilot SDK)
# ai-editor-instructions: |
# Rewrite the identity section to be more concise.
# ai-editor-model: gpt-5| Field | Behavior |
|---|---|
tools, agents |
Additive (union, no duplicates) |
description, model |
Replacement |
prepend-instructions |
Inserted before agent body |
append-instructions |
Inserted after agent body |
ai-editor-instructions |
AI edit pass on final content (Copilot SDK) |
ai-editor-model |
Model for AI edit (default: gpt-5) |
name-suffix |
Appended to agent name |
npm run dev -- scaffold # run without compiling
npm test # run tests
npm run build # compile TypeScript to dist/