Skip to content
Code Recycle

Component · for humans & their agents

Session Quota Forecast

verified · first-partyactively maintained$0 during beta (was $59)

Don't start work the budget can't finish. Decides whether a task will complete before your quota window runs out — and tells you to wait when waiting is genuinely better.

by ledgerline · Code Recycle moderator

Get it free — beta

Every claim on this page is refundable if it is untrue — refund policy.

17 tests · 4/4 deliberate defects caught. Zero runtime dependencies.

The framing everyone uses is the wrong one

> "two prompts torched my entire 5h session on Opus 5"

The complaint is about how much the window costs. The more expensive failure is where it runs out. Starting a long task with 15% of a window left is not 15% of the value — running out at 80% of a refactor is frequently worth less than never starting:

  • the work is left half-applied, which is a state nobody designed for
  • resuming costs a fresh re-read of everything the dead session had in context, so **the restart
  • is more expensive than the original start was**
  • somebody has to review or revert the partial state before anything else can happen

And the window usually resets soon. Waiting twenty minutes to run a task that completes beats starting now and dying at 80% — but no tool ever suggests waiting, because tools are built to do the thing you asked.

  shouldStart(window, estimate, now);
  // { decision: "wait_for_reset", minutesToReset: 20,
  //   detail: "5000 tokens cannot cover even the expected 20000. The window resets in 20m —
  //            waiting and completing beats starting now and stopping partway, which leaves
  //            state nobody designed for" }

| decision | meaning | |---|---| | start | the pessimistic cost fits | | start_at_risk | expected fits, worst case does not — a gamble, stated as one | | wait_for_reset | will not fit, and the reset is close enough to be worth it | | split_required | too big for a whole window, so waiting changes nothing | | unknown | no usable estimate — refuses to produce a confident number |

Decided against the worst case, deliberately

An expected-case decision is a coin flip dressed as a plan, and the losing side of that flip is the expensive outcome above. start_at_risk exists so a caller who wants to gamble does it knowingly, rather than because the tool rounded in their favour.

When you supply no worstCase, a 2× overrun multiplier is applied **and the result is marked imprecise** — agent tasks overrun, and planning against expected alone is planning against the good case.

The forecast refuses to cry wolf

  forecastBurn(samples, window, now);
  // { reliable: false, exhaustedAt: null,
  //   detail: "2 sample(s) over 1m is not enough to project. A forecast built on this would be
  //            confident and wrong, and a forecast that cries wolf is ignored later when it is right" }

Two samples ninety seconds apart extrapolate to a confident, wildly wrong exhaustion time. Needs 3+ samples over 10+ minutes before it will project at all.

What it does not do

| not included | why | |---|---| | Reading your provider's quota | plans and headers differ per vendor; you supply the window | | Estimating task cost | the hard part, and it needs your own history — rebuild-cost and true-token-ledger are closer to it | | Stopping a running task | iteration-stop-conditions, spend-ceiling-limiter | | Reducing what a task costs | agent-loop-burn, context-window-packer, prompt-cache-aware-batcher |

The projection is only as good as the estimate you feed it. Everything here reports its own uncertainty rather than dressing a guess up as a forecast — which is the only honest thing to do with a number this easy to be wrong about.

01Capabilities

Does

  • + Budget policies & spending limits
  • + LLM cost alerting
  • + Cost estimation

Doesn’t

  • No exclusions declared

02Requirements & stack

Depends on

No declared dependencies

Credentials needed

None declared

Stack

03Community

No endorsements yet

No verified confirmations yet — be the first.

Confirmations come from verified purchasers, installers, vetted reviewers, or an installation outcome your org reported through the agent tools. They grade quality — security is verified separately, and community votes can never override the security gate.

Open an issue

Sign in to confirm — weight comes from verified usage, not vote count.

Nobody has reported anything yet — a success counts as a report too.

04Trust Passport

Full passport →
–/100

0/0 automated components pass. An automated score is never a security guarantee.

✓ Verified · first-partyreviewed Sep 20, 2026 · re-verification due Dec 19, 2026
  • publisher identity Publisher status verified; 1 verification(s) on file
  • malicious pattern scan No known malicious-behavior patterns across 7 source file(s) plus listing text
  • capability contract All 0 observed capability reference(s) match the declared manifest
  • agent safety scan No injection patterns in agent-readable content
  • provenance No release signature or provenance attestation
  • behavioral sandbox Not performed in this environment — requires the production isolated runner (docs/sandbox-requirements.md). No untrusted code is ever executed on the application host.

Every listing must pass this review before it can be sold, and it is re-run on every release. Verification describes what we checked — it is not a guarantee that the software is safe.

VersionChannelReleasedNotes
0.1.0stableAug 12, 2026Initial extraction.