PerryLink/dsh-budget
PerryLink★ 0TypeScript最后同步: 2026-08-16
Cost governance for DeepSeek Harness: aggregated token/cost metering per model, session and day, budget caps with threshold alerts and over-limit policies, carbon footprint estimation, per-model latency benchmarks, a Settings budget tab, and the /budget command
README 摘要
💰 dsh-budget Cost governance for DeepSeek Harness: budgets, carbon, and latency in one panel. Know what every session costs — before it costs you. English · 简体中文 · Español · Português · हिन्दी Compatibility Surface Status Harness DeepSeek Harness 0.1.0-rc.6 Node ^22.19.0 \ \ =24.0.0 Surfaces Host + Web client (Settings budget tab); /budget command What you get dsh-budget turns the session event stream into a four-in-one cost governance loop: - Aggregated metering — tokens (uncached input / output / cache read / cache write), estimated USD cost, and carbon footprint per model, session, and day, priced through a built-in USD-per-1M table merged with your config.prices . - Budget governance — session/daily/monthly caps; a warn-ratio threshold alert (webhook POST + desktop-notification flag) and three over-limit policies: alert (notify only), block (short-circuit new model requests until the user lifts the block), degrade (block with corrective guidance naming the cheaper model from your degradation map). - Carbon & latency — token→carbon bridge (tokens × kWh/token × PUE × regional grid intensity, ported from AI-Carbon-Footprint-Calculator) and per-model latency percentiles. - Surface…
在 GitHub 查看完整 README →