Description
Two GitHub Copilot CLI documentation pages give conflicting guidance about precedence when a personal custom agent and a repository custom agent share the same name.
The custom-agent how-to says:
If you have custom agents with the same name in both locations, the one in your home directory will be used, rather than the one in the repository.
https://docs.github.com/en/copilot/how-tos/copilot-cli/customize-copilot/create-custom-agents-for-cli
However, the CLI configuration reference says that project-level agents take precedence over personal agents when they share the same name:
https://docs.github.com/en/copilot/reference/copilot-cli-reference/cli-config-dir-reference#agents
Why this matters
These statements prescribe opposite behavior, making it unclear which agent Copilot CLI will invoke when both of these files exist:
~/.copilot/agents/example.agent.md
.github/agents/example.agent.md
This also makes it difficult to select predictable agent behavior in repositories shared across a team.
Suggested change
Please clarify the actual precedence implemented by Copilot CLI and update both pages to state the same rule. It would also be helpful to clarify whether identity and deduplication are determined by the filename, the frontmatter name, or another identifier.
Description
Two GitHub Copilot CLI documentation pages give conflicting guidance about precedence when a personal custom agent and a repository custom agent share the same name.
The custom-agent how-to says:
https://docs.github.com/en/copilot/how-tos/copilot-cli/customize-copilot/create-custom-agents-for-cli
However, the CLI configuration reference says that project-level agents take precedence over personal agents when they share the same name:
https://docs.github.com/en/copilot/reference/copilot-cli-reference/cli-config-dir-reference#agents
Why this matters
These statements prescribe opposite behavior, making it unclear which agent Copilot CLI will invoke when both of these files exist:
~/.copilot/agents/example.agent.md.github/agents/example.agent.mdThis also makes it difficult to select predictable agent behavior in repositories shared across a team.
Suggested change
Please clarify the actual precedence implemented by Copilot CLI and update both pages to state the same rule. It would also be helpful to clarify whether identity and deduplication are determined by the filename, the frontmatter
name, or another identifier.