v0.2.1 - launch-ready
First public release. Runcap caps every coding-agent run before it spends, runs 100% on your machine, MIT.
npm install -g runcap
What's in this release
- Hard cap, enforced before the call. Point your agent at a local gateway. It prices each request from its own tokens and returns a 429 the moment the projected spend would cross your ceiling, instead of forwarding the call.
- Pre-call budget guard. Catches both slow accumulated overspend and a single oversized call in one window.
- Cost estimate before you start.
runcap planoutputs a USD cost range and a recommended cap. - Built-in token compressor. Compresses JSON, logs, and stack traces in each request before sending. Never touches your prose or code.
- Rescue prompt when an agent gets stuck.
- Zero-config run.
runcap runauto-manages the cap gateway, no manual gateway or base-URL setup. - Guided first run.
runcapwith no args explains the tool and shows one next step.
Fixes since early builds
- Fixed doubled
/v1in the OpenAI upstream URL that made the gateway return 404. - Dropped em-dashes and now show sub-cent spend correctly in user-facing output.
- Fixed false "High-risk" flag on small tasks.
Pure Node, ESM, zero runtime dependencies. Nothing leaves your laptop.