Copilot /speckit.specify does not honor preset spec-template override
Summary
When using the Copilot integration, a preset that overrides only spec-template appears to install and resolve correctly, but /speckit.specify still uses the core/default template because the generated Copilot agent instructions hardcode .specify/templates/spec-template.md instead of resolving the effective template through the preset resolution stack.
This makes template-only preset overrides unreliable for Copilot, even though the preset documentation says templates and commands are resolved independently and command overrides are optional.
Environment
- OS: Windows
- Spec Kit CLI:
specify 0.8.18.dev0
- Integration: Copilot / VS Code
- Project initialized with
.github/agents/*.agent.md and .github/prompts/*.prompt.md
What The Documentation Implies
The presets documentation says:
- Presets can provide template files and command files.
- Each file is looked up independently, so different files can come from different layers.
- Command overrides are optional.
- If only different template sections are needed, a template override should be sufficient.
specify preset resolve <name> shows the winning file.
Reproduction
- Install a preset that provides
templates/spec-template.md but does not override speckit.specify.
- Verify the template resolves from the preset:
specify preset resolve spec-template
Observed resolver output:
spec-template:
C:\git\harness\crm-project\.specify\presets\harness-presets\templates\spec-template.md
(top layer from: harness-presets v0.1.0)
- Run
/speckit.specify from Copilot in VS Code.
- Inspect the generated
spec.md.
Expected Behavior
/speckit.specify should use the effective spec-template selected by the preset resolution stack. In this case, it should use:
.specify/presets/harness-presets/templates/spec-template.md
A preset that only overrides spec-template should affect the generated spec without requiring a command override.
Actual Behavior
The generated spec follows the core/default template instead of the preset template.
The generated Copilot agent file contains hardcoded instructions like:
Copy `.specify/templates/spec-template.md` to `SPECIFY_FEATURE_DIRECTORY/spec.md` as the starting point
Load `.specify/templates/spec-template.md` to understand required sections.
Because the agent reads the core path directly, it bypasses the preset resolver even though specify preset resolve spec-template reports the preset template as the winner.
Why This Matters
This creates a mismatch between preset documentation and Copilot runtime behavior:
specify preset resolve spec-template says the preset template wins.
- The Copilot
/speckit.specify agent still reads the core template path.
- Users are forced to override
speckit.specify as a workaround, even when they only want to change the spec template shape.
Suggested Fix
Update the Copilot speckit.specify command/agent instructions so they resolve the effective template instead of hardcoding .specify/templates/spec-template.md.
For example, the generated agent instructions could say:
Resolve the active `spec-template` using the Spec Kit preset resolution stack, equivalent to `specify preset resolve spec-template`, then read that resolved file as the starting template.
Do not directly read `.specify/templates/spec-template.md` unless the resolver returns that path.
Alternatively, the command-generation layer could materialize the winning template path into the generated agent instructions.
Additional Note
After adding a speckit.specify command override, Copilot loads the preset command correctly. However, that should not be required for a template-only override according to the preset documentation.
Copilot /speckit.specify does not honor preset spec-template override
Summary
When using the Copilot integration, a preset that overrides only
spec-templateappears to install and resolve correctly, but/speckit.specifystill uses the core/default template because the generated Copilot agent instructions hardcode.specify/templates/spec-template.mdinstead of resolving the effective template through the preset resolution stack.This makes template-only preset overrides unreliable for Copilot, even though the preset documentation says templates and commands are resolved independently and command overrides are optional.
Environment
specify 0.8.18.dev0.github/agents/*.agent.mdand.github/prompts/*.prompt.mdWhat The Documentation Implies
The presets documentation says:
specify preset resolve <name>shows the winning file.Reproduction
templates/spec-template.mdbut does not overridespeckit.specify.specify preset resolve spec-templateObserved resolver output:
/speckit.specifyfrom Copilot in VS Code.spec.md.Expected Behavior
/speckit.specifyshould use the effectivespec-templateselected by the preset resolution stack. In this case, it should use:A preset that only overrides
spec-templateshould affect the generated spec without requiring a command override.Actual Behavior
The generated spec follows the core/default template instead of the preset template.
The generated Copilot agent file contains hardcoded instructions like:
Because the agent reads the core path directly, it bypasses the preset resolver even though
specify preset resolve spec-templatereports the preset template as the winner.Why This Matters
This creates a mismatch between preset documentation and Copilot runtime behavior:
specify preset resolve spec-templatesays the preset template wins./speckit.specifyagent still reads the core template path.speckit.specifyas a workaround, even when they only want to change the spec template shape.Suggested Fix
Update the Copilot
speckit.specifycommand/agent instructions so they resolve the effective template instead of hardcoding.specify/templates/spec-template.md.For example, the generated agent instructions could say:
Alternatively, the command-generation layer could materialize the winning template path into the generated agent instructions.
Additional Note
After adding a
speckit.specifycommand override, Copilot loads the preset command correctly. However, that should not be required for a template-only override according to the preset documentation.