cyberneticlibrary

Scale agents within token budget

loop-until-budgetworkflowsetup L22
unfallenwill/batonjs
What it does

Run task until token budget or goal completion

Best for

When a task needs to run repetitively until completion or token budget exhaustion.

Outputs
  • · JSON object matching declared schema
Preconditions
  • · Workflow harness must inject phase(), agent(), parallel() globals
Failure modes
  • · Phase exits early if any agent returns null or throws
  • · Subsequent phases cannot recover from prior phase failure