Where does the bug appear (feature/product)?
Cursor IDE
Describe the Bug
All custom subagents in ~/.cursor/agents are loaded into context at the start of a conversation, wasting significant tokens.
Description:
When starting a new conversation, Cursor appears to inject the definitions of all custom subagents located in the ~/.cursor/agents directory into the initial context window, regardless of whether they are actually invoked or relevant to the prompt.
I currently have over 60 custom subagents defined. Because they are all loaded upfront, a massive amount of tokens is wasted at the very beginning of every new chat.
Steps to Reproduce
- Create multiple custom subagents (e.g., 10+) in the ~/.cursor/agents directory.
- Open Cursor and start a brand new chat/conversation.
- Check the initial token usage. (In my case, it consumed 11.4K tokens).
- Close Cursor and rename the agents directory to disable them: mv ~/.cursor/agents ~/.cursor/agents.bak.
- Restart Cursor and start a new chat.
- Check the initial token usage again. (It drops significantly to 1.4K tokens).
Expected Behavior
Custom subagent definitions should be loaded dynamically (lazy-loaded) only when they are explicitly called or deemed relevant by the router. The initial context should remain lightweight.
Screenshots / Screen Recordings
Operating System
Linux
Version Information
Version: 3.6.21
VS Code Extension API: 1.105.1
Commit: e7a7e93f4d75f8272503ecf33cedbaae10114a10
Date: 2026-05-28T21:45:36.072Z
Layout: editor
Build Type: Stable
Release Track: Default
Electron: 39.8.1
Chromium: 142.0.7444.265
Node.js: 22.22.1
V8: 14.2.231.22-electron.0
xterm.js: 6.1.0-beta.220
OS: Linux x64 6.17.0-29-generic
Additional Information
Actual Behavior:
All custom subagent definitions are blindly loaded into the system prompt/context at the start of the conversation, wasting roughly 10,000 tokens in my case on unused agents. This severely eats into the context window and wastes resources.
Does this stop you from using Cursor
Yes - Cursor is unusable

