r/CheapAgent • • 10d ago

Worker timeout

Hi, i get into timeout with worker very often, how to resolve this issue?

2 Upvotes

4 comments sorted by

1

u/memers_meme123 10d ago

Sorry about that! A timeout means the worker hit its time limit: 20 minutes of work per step. Three things help:

  1. Smaller steps. Ask Claude to split the work into smaller steps. The usual cause is one big step that touches many files or needs a lot of exploring.

  2. More time. Put a cheapag.json in your project: { "limits": { "max_minutes": 40 } } Or put the same limits in ~/.config/cheapag/config.json to apply it to every project.

  3. A faster model. Slow models, and models that think a lot before answering, eat the clock. Run /cheapag:model and pick a faster model or a lower effort level. This needs 1.4.1: npx cheap-agent@latest

Which provider and model are you using? If it times out even on small steps, the provider is probably slow, and I’d like to look into it.

1

u/L0v3lyB3ar 10d ago

No problem, I use Claude with Deepseek api directly, can you add this instructions in the git repo with an example of the config.json too?

1

u/memers_meme123 9d ago

Sure, it’ll go in the README with the next release. Until then, here it is:

Give the worker more time. Create cheapag.json in your project folder:

{
  "limits": { "max_minutes": 40, "max_turns": 40 }
}

max_minutes is the time each step gets (default 20). Time spent waiting for your answer doesn’t count. max_turns is how many turns it gets (default 25). Raise both, or a step that gets more time runs out of turns instead.

To use this in every project, put the same thing in ~/.config/cheapag/config.json. If a project has its own cheapag.json, that wins.

On DeepSeek direct: the strongest preset uses V4 Pro, which is slower. balanced uses Flash. If you picked strongest, switch back with:

npx cheap-agent login --preset balanced

And ask Claude for smaller steps. One big step that touches many files is the most common reason for a timeout.

2

u/L0v3lyB3ar 9d ago

I've already set that values as a per project rule, but it happens, I'll try with smaller tasks/steps as a rule.

I'm already on the balanced preset.