ivvan3016/dsh-ui-pricing0

dsh-ui-pricing

User-configurable cost pricing for dsh: per-model list prices and per-day-of-week time segments with price multipliers, edited through a Plugins-settings card

包名
dsh-ui-pricing
版本
0.1.3
许可证
MIT
最近更新
2026年8月25日

安装

$npx -p @deepseek-ai/dsh dsh plugin --profile web add github:ivvan3016/dsh-ui-pricing

Configuration

The package registers the pricing settings namespace (see dsh-settings):

FieldDefaultMeaning
currencyCNYCurrency code the prices are denominated in.
modelsV4 catalogList prices per model id in currency units per one million tokens; a model with no entry is unpriced. Cache writes are billed at the cache-miss input rate (DeepSeek has no separate write price).
defaultScheduleone 00:00–24:00 segment at multiplier 1The default time policy every day uses unless overridden; a segment is an HH:MM window with a multiplier. A segment whose end is earlier than its start wraps midnight.
overrides{}Per-day exceptions: a day present here uses its own TimeSegment[] instead of the default schedule.
manualSpend0Manual-spend correction delta added to the auto-computed total: a positive value tops the estimate up, a negative one trims it. The CostLine writes it when you correct the total in place (corrected total − auto amount), so the display reads auto + manualSpend and keeps accruing usage on top of the correction.

Settings → Plugins → Plugin configuration shows a Pricing settings card: a per-model price table (model rows are seeded from the wire llm.models() catalog, so the deployment's actual models appear), one default timeline that applies to every day, and day-exception toggles — enabling a weekday gives it its own timeline that overrides the default (e.g. a weekend that is off-peak all day). On a timeline, click inside a segment to split it, drag a handle to move a boundary (dragging never inserts), click × to remove a boundary, and type each segment's multiplier directly.

The cost projection re-registers whenever the section changes, replaying the durable log under the new prices and windows.