The docs say that AGENTS.md is automatically loaded, however with background agents, it is not.
I even tried to load it via a cursor rule with:
---
alwaysApply: true
---
# AI Implementation
Refer to [AGENTS.md](mdc:AGENTS.md) for full rules.
Do you already have our “Project Instructions” in your context? Specifically the one that talks about our mandatory quality workflow
Thought for 3s
I can see a reference to AGENTS.md in my workspace rules, but I don’t have the full content loaded. Let me read that file to check if it contains your project instructions about the mandatory quality workflow.
Steps to Reproduce
Create an AGENTS.md
Start a background worker, ask it if it has the contents from AGENTS.md in its context.
It will say it does not.
It also doesn’t use any of the rules in practice.
Expected Behavior
AGENTS.md should be loaded into context in every form of using Cursor.
Operating System
Windows 10/11
MacOS
Linux
Current Cursor Version (Menu → About Cursor → Copy)
Not applicable, background agent.
Request ID: bc-a251da8e-a40a-4866-96dc-6a93353c910c
I’ve been testing this by having in my agents.md file the requirement to use semantic commits for git commits and PR titles, and it is ignoring both directives.
for additional context, I even have a .cursor/rules/ file that tells it to use agents.md in the root directory.
neither are automatically being picked up. granted i’m testing it with a very simple task, so maybe it isn’t thinking it needs any context from an agents.md file.
but I would have expected that even on simple tasks it would look for an agents.md file to understanding and coding standards of the repo.
it is only when I specifically direct it with a comment to use the agents.md file that it starts following the guidelines.
I also have an environment.json file to help guide the agents, but either I’m using it wrong or it is also not registering.
"install": {
"command": "make install",
"description": "Install all project dependencies including Rust tools, Docker, and development utilities"
},
"start": {
"command": "sudo service docker start",
"description": "Start Docker Desktop daemon required for database and testing operations"
},
"setup": [
{
"command": "make setup-hooks",
"description": "Set up git hooks for pre-commit linting and pre-push testing"
}
I was hoping this would prompt the agent to run docker on start per the cursor docs, so that it can run the make commands to install the dependencies and rely on the githooks for linting commits and testing pushes.