Commit graph

4 commits

Author SHA1 Message Date
Danny Avila
f513665ec5 🩹 fix: Address Usage Review Findings — Cost Timing, Scoped Caches, Finalized Output
- carry the post-snapshot output estimate into the context snapshot at
  finalize so the gauge keeps the last response after live resets
- accumulate per-rate billable units and price the session cost at
  render, so usage events arriving before the token-config load still
  count once it resolves
- pass user-scoped token-config cache keys through loadConfigModels
  fetches and drop the controller's unscoped fallback to prevent serving
  another user's resolved config
- tag emitted usage events with a per-run seq so resume dedupe never
  drops a distinct call with an identical payload
- admit the static tokenConfig override in the custom endpoint schema so
  it survives zod parsing into req.config
2026-06-11 15:36:21 -04:00
Danny Avila
84436aa688 🩹 fix: Scoped Token-Config Fallback and Sequential Visibility for Usage Events 2026-06-11 14:17:17 -04:00
Danny Avila
e5ab7cf1b1 🩹 fix: Resolve Codex Findings for Context Usage Tracking 2026-06-10 23:43:24 -04:00
Danny Avila
2c7f5c38af 📊 feat: Real-Time Context Window & Token Usage Tracking 2026-06-10 23:26:23 -04:00