Proposal: Add Support for Agent Rules Standard with AGENTS.md for Cross-Agent Interoperability #1412
Closed
sgryphon
started this conversation in
1. Feature requests
Replies: 1 comment
-
Hi @sgryphon, AGENTS.md support was added in 4.73.0! |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Problem Statement
The AI coding agent ecosystem is increasingly fragmented, with each tool requiring its own configuration files for natural language guidelines—such as YAML-based Custom Modes for defining agent behavior in tasks like code generation or refactoring. This leads to duplication when developers use multiple agents, increasing maintenance efforts, version control complexity, and the risk of inconsistencies in rules like coding styles, security practices, or workflows.
Proposed Feature
To address this, I suggest adding support for the Agent Rules standard, a minimalist community specification that uses a single
AGENTS.md
file in the project root to provide shared natural language instructions. This would allow users to define rules once and reuse them across compatible agents, integrating seamlessly alongside existing Custom Modes without replacement.Kilo already supports fallback to cline and roo rules, so fall back to a standard AGENTS.md should be an easy add for global support. https://kilocode.ai/docs/advanced-usage/custom-rules
For the full specification, examples, and a list of supporting tools, please refer to https://agent-rules.org/.
Benefits
AGENTS.md
can be shared with other agents, such as ChatGPT Codex CLI (native support), OpenCode (native support), Aider (configurable via --conventions-file), and Gemini CLI (configurable via settings.json), enabling consistent guidance in multi-tool environments.Technical Implementation Details
The change could be implemented with minimal effort (approximately 20-30 lines of code) while maintaining backward compatibility:
src/extension.ts
, retrieve the workspace root usingvscode.workspace.workspaceFolders
. Check for the file withfs.existsSync(root + '/AGENTS.md')
and, if present, read its content as UTF-8 text usingfs.readFileSync
.src/llm/promptBuilder.ts
or inject it as a default Custom Mode insrc/modes/modeProvider.ts
(e.g.,prompt += \n\nProject Guidelines: ${agentsContent}
).package.json
, such as"useAgentRules": { "type": "boolean", "default": true, "description": "Enable loading of AGENTS.md from project root for Agent Rules standard." }
, to allow users to opt out.src/tests/
by mockingfs
to verify content inclusion in prompts, ensuring no regressions for existing modes.This approach ensures
AGENTS.md
is treated as an additional source of guidance, processed in conjunction with current configs.Beta Was this translation helpful? Give feedback.
All reactions