# subagent-tuner

> A Claude Code mod that picks the model and reasoning effort of every subagent, by asking you, recommending by task type, or applying your saved default.

subagent-tuner is an open-source Claude Code mod published under the MIT license by Kruhlikau. When the agent starts a subagent, it settles that subagent's model and reasoning effort by asking the user, by a recommendation based on the kind of task, or by a saved default. The latest listed release is v0.1.4, and it requires Claude Code 2.1.287 or later.

## What It Is

subagent-tuner is a plugin (mod) for Claude Code that intercepts Agent calls and sets only their `model` and `effort` fields. The aim is for a review to run on Opus while a file search runs on a cheaper, faster model. It shows a band above the prompt with the current mode and saved default, and it stores both in Claude Code's own plugin store so they persist across sessions.

## How the modes work

Manual is the default after install and asks before a subagent starts. On terminals 144 columns wide or more the question appears as a pane beside the transcript, with model and effort selectors and options to run, run and save as default, or cancel. On narrower terminals it uses a short chain of dialogs. A dismissed question starts the subagent with what was shown.

Auto never asks. The saved default wins, even over a model or effort the agent set itself, such as a `CLAUDE.md` rule that passes `model: "opus"`. A field left at the recommendation setting keeps what the call set, otherwise takes the recommendation. A toast reports what was applied.

## The recommendation

The task kind is inferred from the subagent's type, else its description. Review, audit, verify, adversarial and security tasks map to opus with high effort. Implement, build and fix map to sonnet with medium effort. Explore, search and research map to haiku with low effort. Prompts longer than 4,000 characters get one step more effort, and other tasks inherit the session's model and effort.

## Scope and safeguards

It leaves `claude -p` and SDK-hosted runs unchanged and never touches forks. In the VS Code extension it cannot show the band, so it behaves as Auto. The README states it reads each Agent call's subagent type, description, model, effort and prompt length, and makes no network calls. It runs `sh` or `powershell.exe` only to wait for the pane answer, and writes an empty sentinel file in its own `.waits/` folder.

## Setup path

Install inside Claude Code with `/plugin install subagent-tuner --marketplace Kruhlikau/subagent-tuner`, choose the user scope, and it works in that session. Alternatives include a two-step marketplace add, a shell command, or loading a local clone with `--plugin-dir`. The README reports testing on Claude Code 2.1.295 and 2.1.296 on macOS and Windows 11.

## Features
- Chooses model and reasoning effort per subagent
- Manual mode with pick pane or dialogs before a subagent starts
- Auto mode applying a saved default over agent-set values
- Task-based recommendations (review on opus/high, build on sonnet/medium, search on haiku/low)
- Extra effort step for prompts over 4,000 characters
- Clickable band above the prompt to switch mode and cycle defaults
- Settings persisted across sessions
- Leaves claude -p, SDK hosts and forks untouched
- No network calls

## Integrations
Claude Code

## Platforms
WINDOWS, MACOS, LINUX, API, VSC_EXTENSION, CLI

## Pricing
Open Source

## Version
0.1.4

## Links
- Website: https://github.com/Kruhlikau/subagent-tuner
- Documentation: https://github.com/Kruhlikau/subagent-tuner
- Repository: https://github.com/Kruhlikau/subagent-tuner
- EveryDev.ai: https://www.everydev.ai/tools/subagent-tuner
