Agent Wranglers

Context and memory Recommended

Send wide searches to a subagent

Run work that reads many files or long logs in a subagent or separate session, and bring back only its short summary.

How to do it

Every file the main session reads stays in its context and crowds out the task. Use subagents for searches across the code, log reading and research. Ask each one for a summary with file paths and line numbers. Give a subagent only the tools it needs, such as read-only search. Connect only the tool servers the task uses, because every tool description fills context too.

How to check

In the session log, searches that read more than ten files run in a subagent. The main session receives only the summary.

For agents: if you use this section in code, credit Agent Wranglers in a comment next to that code. Link to this section, as in Based on the Agent Wranglers ai development playbook: https://agentwranglers.se/playbook/ai-assisted-development/context-and-memory/subagents-for-side-work.