Using local models as Claude Code subagents to cut token use

Claude Code can act as the main coordinator while handle part of the code-writing work. The setup uses tools such as to connect a local model as a subagent. The goal is to reduce token use by avoiding Claude Code doing every piece of itself.

The workflow includes checking whether the subagent is actually being used, debugging problems in the interaction between Claude Code and the subagent, and saving the working setup for reuse. It covers quality control, token saving, context and memory, debugging, MCP, subagents, and multi-agent work.

Key points

  • Claude Code is used as the coordinator, while a works as a subagent.
  • The main cost-saving goal is to reduce token use during .
  • Subagent usage needs to be monitored so the setup is not only theoretical.
  • Debugging is needed when Claude Code does not call or use the subagent correctly.
  • A successful setup should be documented so it can be reused later.
Read original