You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[FEATURE]: Provide compatibility for agent discovery with GitHub Copilot? #5052
I have verified this feature I'm about to request hasn't been suggested before.
Describe the enhancement you want to request
OpenCode expects agents in:
.opencode/agent/ (singular) or a custom directory set via OPENCODE_CONFIG_DIR.
GitHub Copilot expects agents in:
.github/agents/ (plural) with files like foo.agent.md.
Hybrid Strategy
I would like to be able to point from OpenCode configuration to existing agent files from a GitHub Copilot project.
I could try to use OPENCODE_CONFIG_DIR, but then I would need to rename .github/agents to .github/agent, breaking the GitHub Copilot structure.
=> Could you please
also allow .opencode/agents as source for agent discovery?
or add extra option on level of "agents" folder, for example OPENCODE_AGENTS_DIR?
Possible workarounds for now: a) Use symbolic links between folders on os level b) Create individual agent definitions in opencode.jsonc and point to external foo.agent.md files from GitHub folder
"agent": {
"code-reviewer": {
"description": "Reviews code for best practices and potential issues",
"model": "anthropic/claude-sonnet-4-5",
"prompt": "{file:./.github/agents/code-reviewer.md}",
"tools": { "write": false, "edit": false }
}
}
c) Include agent files as instructions (does not make sense)
"instructions": [
"./.github/agents/*.md" //includes GitHub Copilot agent definitions in instructions (does not really make sense)
],
These issues discuss similar concerns about agent discovery flexibility and compatibility with different project structures (including GitHub Copilot's directory naming). The #3432 issue is now closed but addressed the custom config path scenario, while #4479 proposes a more comprehensive configuration solution.
Feel free to ignore if your specific case requires different functionality or if these don't fully address your GitHub Copilot compatibility scenario.
Activity
github-actions commentedon Dec 4, 2025
This issue might be a duplicate of existing issues. Please check:
These issues discuss similar concerns about agent discovery flexibility and compatibility with different project structures (including GitHub Copilot's directory naming). The #3432 issue is now closed but addressed the custom config path scenario, while #4479 proposes a more comprehensive configuration solution.
Feel free to ignore if your specific case requires different functionality or if these don't fully address your GitHub Copilot compatibility scenario.