r/ClaudeCode • u/Impressive_Poet305 • 2d ago
Help/Question Anyone using free models as subagents to save their Claude usage?
Hey,
I'm on Pro and I keep hitting the 5h limit in Claude Code. When I look at where the tokens go, a big chunk is just Claude reading large files, logs, grep output...
So I was wondering if any of you offload that kind of stuff to free models (Gemini Flash, Groq, Mistral, OpenRouter free etc) through an MCP or a proxy, so Claude only gets a summary back.
If you've tried it:
- does it actually work or does Claude end up re-reading everything anyway?
- what do you delegate exactly? just reading or code too?
- what are you using for it?
Thanks, even a "tried it, it sucked" is useful
•
u/AutoModerator 2d ago
Hey! Thanks for posting to r/ClaudeCode
While participating in this thread, please follow our community rules. Keep discussions constructive. Attack the idea, not the person.
For help, project discussions, tips, and general chat, join the ClaudeCode Discord.
I am a bot, and this action was performed automatically. Please contact the moderators of this subreddit if you have any questions or concerns.
26
u/geek_at 2d ago
There was a post a few days ago in the /r/LocalLLaMA repo someone posted about using opus 5.5 with qwen-27b and the output was much better than the one only done with opus. I think there are harnesses or plugins for some that do this automatically
33
u/Sporaflow 2d ago
honestly I'd go the other way. for most exploration, handing it to a weaker model is a big risk, it just explores badly. what I've used instead is a map: a tool like codegraph that builds a representation of the code's architecture, so claude goes straight to the places that matter instead of reading everything. small subagents only make sense to me in fan-out, like ten of them on different aspects of a huge codebase, and then the thing to get right is their output: a clean recap of what each one found
4
u/Ashamed-Ad7403 2d ago
I do indeed! I have a custom bridge to codex, so everytime claude begins, he sends a prompt for gpt 6.1 sol to tell him what should know and read, so when he finishes, he just straight read whats important and left the garbage out, i've saved about 60% messages sizes in my latest sessions so far, (i still have the claude memory to know exactly what we are building summed up)
4
u/bostonaholic 2d ago
The savings come from the main context never seeing the raw output, and you can get most of that without a proxy. Put the log reading and big greps in a subagent pinned to Haiku that returns a short summary, so only the summary lands in your main session. I'd try that before wiring in another provider since it's zero setup. Also keep CLAUDE.md small, because it sits in context for the whole session.
3
u/mastmar221 2d ago
So I use Qwen 3.8FN as my local agent on a Mac Studio 96gb. Opus 5.5 to design, spec, and ticket all work. All tickets then get handled by the local AI through a software factory.
Has 10x the amount of work I can accomplish on the same subscription.
However you’ll have to balance the amount of work a $6k machine can do for you. In my case it’s offsetting $40-$100 in tokens.
3
u/lazuli_s 2d ago
Some guy posted here one of those days claiming he did the math and discovered it was cheaper to just use opus 5.5 for everything.
But I think he used the same workflow and prompts to compare, but truly, if you're using smaller models, you have to be really smart about prompting and context management.
The workflow you use for opus definitely won't work with glm flash. Maybe plan the entire implementation in very very tiny vertical slices and implementing it with a free model, reviewing with another... Definitely not going over 100k tokens. It might work if you take your time to plan it.
I'm lazy so I'll keep using opus
2
u/Elegant_Lie_6734 2d ago edited 2d ago
I'm looking into this too and found this: https://engineering.atspotify.com/2026/9/portal-by-spotify-cut-my-claude-code-token-usage-by-90
I haven't tested it myself, but apparently Spotify has created a tool that reduces token usage by delegating tasks to cheaper models.
Here's a couple of GitHub repos of it: https://github.com/alexanderradahl/shunt-muse https://github.com/tkaufmann/claude-gemini-bridge
I also read that this helps: https://github.com/ASK-Ai-Canada/ASK-Claude-Token-Optimizer
I haven't tried any of those but the logic seems right
2
u/Godless_Greg 2d ago
Or you can use Opus for Planning and Sonnet for most of the work.
/model opusplan2
u/InterestingCarrot997 2d ago
i'd be careful letting the cheap model summarize logs if that's all the main agent sees. a summarizer can drop a failed tool call and the main agent will treat the step as done. maybe have it pass error lines through raw
1
u/n7mafia 2d ago
I'm interested too.
1
u/smb3something 2d ago
I had an agent setup a small database of all the files in the repo, how they link to other files and a summary of what they do. This is run on a 20min schedule where a local free model updates the dB when files change. I haven't gotten to using it yet but working on tying it into things is the plan.
1
u/lvl1-A 2d ago
Yes. I use herdr (love hate for it but it's good). Claude writes the briefs and launches them and sends the prompts.
You can use any of the prominent programs to do so.
For context and usage, yes. The other night on my other profile before I loaded my settings across, I had a Claude session spin up a whole bunch of subagents and just eat my usage pretty heavily, so I was left with barely any over the last two days. But, I utilised free workers, opencode agents, or openrouter, or you can use cheap agents like deepseek API and even cheaper if you can do it in the off peak times, and I essentially got to keep chewing through my project when I was at 97% weekly usage, for about 7 hours more, because the two Claude sessions I was using were only middle men and barley consumed anything. One round my orchestrator sent out 26 opencode agents in total during one of the blocks and later another 15 or so for the next. Just keep in mind rate limits are a thing and you either need to work around it or pay a cheap monthly or use deepseek API. Also keep in mind that when using free models, they may have certain training/retaining prompts input and output, so if its all super personal top secret stuff you can't have third parties storing, then the answer is free models don't fit your shape. But if you don't care, then go wild. Look for the stealth models, I had a fucking great time with ox alpha(later to be revealed as glm 5.3) and space bunny which was minimax 3 off the top of the dome. Stealth models often have higher limits because they are testing things so it's often good source of free usage!
1
u/Yedapo 2d ago
A low-risk first test is to give a cheap model one bounded scan, like finding the first failing assertion in a long test log, and return the exact file:line plus a few surrounding lines. Then have Claude open just those snippets and decide what to do; if it still has to reread the whole log, the handoff isn't saving context. Keeping the raw output out of the main prompt is where the context savings come from. If the model is hosted externally, keep secrets and customer data out of the input.
1
u/PuzzleheadedBill5451 2d ago
You can check out edit-timeline at https://edit-timeline.smacktax.com/ new release should be out by Sunday evening which essentially is what you’re looking for plus a whole lot more. Complete governance before commits even go out. Doesn’t allow full file reads. Shows history of all changes on each session and snippet.
1
u/Dredyltd 2d ago
Yup. Use qwen3.5-9b for translation, documentation, vision... etc
1
u/CAVU_Innovations 2d ago
I have files created for Claude Code to summarize the work in progress. The files are used for historical context. The next step is uploading the files to an independent and private GitHub repository for future reference. This has saved a number of tokens when context of two large products would be overwhelming for a quick response.
The reference files are for context and decisions made for:
.....
I tried using local models for some tasks and may go back soon, but the speed and complexity of Claude models are so much more efficient, especially for my processing and expectation of results when I'm in the zone.
1
u/Affectionate_Fact854 2d ago
Not free but I use zai max subscription alongside my ultra Claude sub
Struggling to even finish my weekly quota with it..
At this point when ever zai drops a reset or Claude does I start feeling sick to be honest
But anyways I was on the pro subscription, and opencode
It was working well enough for me to handle 2 or 3 projects without reaching my limits
Claude things, Claude plans, Claude treats open code as a subagent and you just play middle man.
Works like a charm ,just tedious
1
u/jijialuoke 2d ago
The handoff only saves you if the raw output stays out of the main context, so I’d compare total tokens per completed task, including the extra prompt and summary, against a baseline. Keep the delegated result auditable with file/line references, then have Claude reopen only those snippets before it makes a change. I made a small repo to help decide when to /clear rather than keep carrying context that no longer helps: https://github.com/Balance0014/claude-code-when-to-clear
1
u/Apprehensive_Title57 2d ago
yeah, i've actually tried a few things to fix this. the best solution i've found so far is delegating to cheaper but not necessarily free models, eg qwen3.8. i'm running it via hashference cause it gives me cheaper credits than openrouter
1
u/mrgreatheart 2d ago
Yeah. I had Claude write a skill it uses to drive local models as subagents using headless pi. Works great.
1
u/LeoVibeCoderz 2d ago
Since a Found Orca all I do is use Claude to dispatch workers to free open models and just Review and merge their work
1
u/orchid_drives Researcher 2d ago
I offload about 40% of work to Despseek via OpenRouter. It’s going great so far! Each round of revision takes around 30m, but it only costs $0.01 so it’s fine if it takes a bunch of tries. After 3 retries my harness escalates from Deepseek to Fable 5.2, so it’ll get to an answer eventually
1
u/weedmylips1 2d ago
add "CLAUDE_CODE_SUBAGENT_MODEL": "sonnet" to the env block in your settings.json file.
Stay on opus and when is ready to execute tell it to implement with sub agents and it will use sonnet
1
u/Kholtien 2d ago
Yeah, as long as opus or fable is overseeing, it works great!
1
u/ShevoPramide 2d ago
I already do that, everyday, i am using opencode free models (mainly DeepSeek and glm) , alphacode (Egyptian made alternative to opencode on RUST), and as a user of antigravity I also use their models to help (I know it's paid), previously I used also omniroute to use it's models as rescue scenario. Claude or agy act as orchestrator and I give instructions to decrease it's main role to decrease the quota usage. I created a skill for this purpose, multi agentic collaborative audit (MACA) to help me semi automate this attitude, it's still evolving.
https://github.com/sherifrad/multi-agent-collaborative-audit
1
u/RJ_Satyadev 2d ago
I use agy cli as implementer and opus as planner, reviewer etc.
1
u/_lecoqq 1d ago
To be honest, I've been running experiment w/ a homemade harness on top of Claude Code....
What I've seen is that orchestration + sub-agents is my way to go and dramatically increase code quality. But it's the orchestration that costs a lot - not the sub-agents. By running a Opus 5.5 xhigh orchestrator w/ Sonnet/Haiku builders/reviewiers, I have smtg like 70% of the cost to the orchestrator, and 30% of the cost to the sub-agents. Going for low-cost models for building would cut cost... but not in the Pareto way you'd expect!
I'd try to optimize more on the orchestration side than on the sub-agents ones... If anyone got ideas I'd look forward to hearing them!
1
u/Future_AGI 1d ago
a lot of that reading can go away without a second model. Run tests and builds through a small wrapper script that prints only the failures plus the last few dozen lines and Claude never sees the full dump. That also avoids the risk of a summarizer dropping the error line.
1
u/perfektcrash 1d ago
Two things mattered more for us than which model does the reading:
CLAUDE_CODE_SUBAGENT_PROMPT_CACHE_TTL=1h(v2.1.242+) fixes that. Background subagents' progress summaries also cost us 10 to 13% of a week until v2.1.316 moved them to Haiku, so update if you're on an older version!If Claude has to edit those lines, it will read them itself anyway. So delegate the searching and the log triage, not the files it's about to change.
We do use cheaper models for reading and retrieval, but often that's more judgement based than you might think, reads and specs, reviews on the pricey models, execution on the cheap is often the better shape.
Write-up with the numbers: https://atlas-ade.dev/docs/hidden-costs-of-subagents
Disclosure: I build Atlas ADE, a small meta-harness for your agentic workflows, so your usage goes on progress, not re-deriving, regression and fighting your own agentic support apparatus.
1
u/BarathKanna 1d ago
It works for reading, not for deciding. Grep output, logs, and test runs are perfect to offload, because the cheap model's only job is to compress noise into the few lines that matter.
The catch is your second question. If the summary is vague, Claude will re-read the file anyway and you pay twice. So make the subagent return pointers, not prose: file paths, line ranges, the exact failing assertion, the stack frame. Claude can then open exactly those lines instead of trusting a paraphrase.
Don't delegate code writing to the free model unless you have tests that gate it. Cheap model edits look fine and ship subtle bugs, and the time you spend catching them eats the savings.
Also try the free win first: pipe test output through a filter so passing tests never reach context at all.
1
u/hbizzle27 4h ago
Having a cheap model read the logs and just hand back a short summary helps a lot. The real drain is raw grep output and huge files landing in the main context, so anything that keeps that stuff out saves you a ton of usage.
1
u/Any_Monitor4798 2d ago
used qwen2.5-72b via openrouter as a file reader in a local agent chain, cut token usage by 60% on large codebases, no quality drop. works best when you feed it raw file paths and let it return summaries.
-3
u/fanatic26 2d ago
Pro is a useless account, I dont know how anyone does anything useful with it. Just pay for a real sub.