Install any skill in seconds. Free to start, no credit card required.
Get Started Free →Forward-looking spend extrapolation. Computes a USD-per-day rate from the recent measurement window, projects to 7d/30d/90d/365d horizons, and surfaces "days until budget exhausted" when a budget is configured. Predictive counterpart to `cost-budget-check` (reactive).
| Test case | Without → With | Effect | Δ tokens | Δ turns |
|---|---|---|---|---|
| case-01 | ✗→✓ | ▲ Improved | 46% | 0% |
| case-02 | ✗→✓ | ▲ Improved | 103% | 0% |
| case-05 | ✗→✓ | ▲ Improved | 14% | 0% |
| case-07 | ✗→✓ | ▲ Improved | -52% | 0% |
| case-08 | ✗→✓ | ▲ Improved | -16% | 0% |
Forward-looking cost projection that pairs with cost-budget-check:
cost-budget-check answers "have we crossed the line?" — reactivecost-projection answers "when will we cross the line?" — predictivesession-* records from the cost-tracking namespace (same source cost-budget-check uses).capturedAt/startedAt).windowSpend / windowDays.budget-config key set by cost-budget set):ALREADY REACHED markers for thresholds already exceeded.--window <duration> Measurement window. Nh|Nd|Nw|Nm. Default 7d. --horizons <csv> Projection horizons. Default 7d,30d,90d,365d. --format table|json Default table (markdown).
Env: PROJECTION_NAMESPACE override (default cost-tracking), PROJECTION_QUIET=1 (alias for --format json).
| Sessions in window | 3 |
| Window spend | $3.000000 |
| **USD per day** | **$0.428571** |
| All-time spend | $3.000000 across 3 sessions |
## Projected spend (linear extrapolation)
| Horizon | Days | Projected spend |
|---|---:|---:|
| 7d | 7 | $3.0000 |
| 30d | 30 | $12.8571 |
## Budget exhaustion ($20.00 configured)
| Threshold | Target | Remaining | Time at current rate |
|---|---:|---:|---|
| 75% | $15.00 | $12.00 | 28.0 days |
| 90% | $18.00 | $15.00 | 35.0 days |
| 100% | $20.00 | $17.00 | 39.7 days |cost-projection --format json | jq '.budget.exhaustion[2].daysUntilReached < 7' → fail builds when 100% exhaustion is < 1 week away.Linear extrapolation assumes the current rate holds. The footer reminds operators to re-run after workload shifts. For drift detection over MULTIPLE windows, pair with cost-trend (which already covers benchmark-drift).
Other measured skills in the registry, with their headline benchmark lift.