4 ms·
How is it different from subagents?
by greymalik 1y ago
How is it different from subagents?
- simonw 1y agoThey complement each other. Subagents are mainly a token context optimization hack. They're a way for Claude Code to run a bunch of extra tools calls (e.g. to investigate the source of a bug) without consuming many tokens in the parent agent loop - the subagent gets its own loop, can use up to ~240,000 tokens exploring a problem and can then reply back up to the parent agent with a short description of what it did or what it figured out. A subagent might use one or more skills as part of running. A skill might advise Claude Code on how best to use subagents to solve a problem.
- SafeDusk 1y agoI like to think of subagents as “OS threads” with its own context and designed to hand off task to. A good use case is Cognition/Windsurf swe-grep which has its own model to grep code fast. I was inspired by it but too bad it’s closed for now, so I’m taking a stab with an open version https://github.com/aperoc/op-grep https://github.com/aperoc/op-grep.