Where does the bug appear (feature/product)?
Cursor IDE
Describe the Bug
AGENTS.md rules from one repository are being applied when working in other repositories within a multi-repo workspace. According to the documentation, AGENTS.md should be plain markdown that automatically scopes to its directory, but in practice it leaks across repository boundaries in workspaces with multiple projects.
Steps to Reproduce
- Create a workspace with multiple repositories
- Add an AGENTS.md file to one repository
- Open a file from a completely different repository in the same workspace
- Observe that rules from the first repository’s AGENTS.md are being applied to the files from the different repository
- The only workaround is adding frontmatter with globs (e.g., globs: [“/repository-name/”]), which contradicts the “plain markdown” design stated in the documentation
Expected Behavior
According to https://cursor.com/docs/rules:
- “Unlike Project Rules, AGENTS.md is a plain markdown file without metadata or complex configurations”
- AGENTS.md should automatically scope to its repository root and subdirectories
- Rules should not leak into other repositories in the same workspace
- No frontmatter should be needed for proper directory scoping in multi-repo environments
Operating System
MacOS
Version Information
Cursor IDE (latest version as of 2026-03-21)
For AI issues: which model did you use?
Claude Sonnet 4.5 (Agent mode)
Additional Information
The nested AGENTS.md support mentioned in the docs suggests directory-based scoping should work automatically, but it appears to break down in multi-repo workspaces. This forces users to either:
- Add frontmatter with globs (defeats the “plain markdown” purpose)
- Move to .cursor/rules/*.mdc (more complex setup)
- Accept cross-repo rule pollution
Does this stop you from using Cursor
No - Cursor works, but with this issue