Skip to content

Releases: PerryLink/dsh-budget

Release list

v0.1.0

Choose a tag to compare

@github-actions github-actions released this 16 Aug 18:00

[0.1.0] - 2026-08-16

  • Initial release: aggregated token/cost metering, budget caps with threshold alerts and over-limit policies, carbon footprint estimation, per-model latency benchmarks, and the /budget command.

Added

  • Aggregated token/cost metering per model, session, and day from the session/event stream (assistant/message usage with request/header provider/model attribution), priced through the built-in USD-per-1M table merged with config.prices.
  • Session/daily/monthly budget caps with warn-ratio threshold alerts (webhook POST + desktop-notification flag) and alert/block/degrade over-limit policies; block/degrade short-circuit the llm/stream waterfall with a corrective error finish (loop-built requests are frozen and cannot be rewritten, so degrade names the target model instead).
  • Carbon footprint estimation via the token→carbon bridge (tokens × kWh/token × PUE × regional intensity).
  • Per-model latency statistics with p50/p95 aggregation over a bounded window.
  • budget Typert Remote namespace (budget/status, budget/setSettings, budget/unblock) + the browser Settings tab (usage bars, model breakdown, alerts, cap editors, unblock).
  • /budget command (overview, models, unblock <scope>).
  • budget/alert and budget/block session audit events (microtask-deferred past the session-append reentrancy guard).

Ported (upstream assets, Apache-2.0 — see THIRD_PARTY_NOTICES.md)

  • LLM-Cost-Estimator-CN: price table (CNY per 1k, verbatim) and cost formulas → src/estimate/models.ts, src/estimate/cost.ts; operational USD table in src/estimate/prices.ts.
  • Mode-Latency-Benchmark: benchmark vocabulary and percentile statistics → src/estimate/latency-stats.ts.
  • AI-Carbon-Footprint-Calculator: GPU/region/PUE data and formulas + equivalences → src/estimate/carbon.ts.