DeepSeek Harness Plugin Hub
← Plugins

@dsh-external/dsh-cost-guard

Cost Guard

成本守卫: A cost-saving plugin for DeepSeek V4-Flash-0731 pure API pricing—calculates session costs, cache hit rates, and the amount saved with full cache hits according to the official peak/off-peak tiers dated 2026-08-17 (peak: 09:00-12:00 / 14:00-18:00); ¥ budget guard (budget = hard limit: once the

The plugin will be installed here. Keep web if you are unsure.

npx -y @deepseek-ai/dsh plugin --profile web add github:sixtysevenlf/dsh-cost-guard#eb9cdc8ad6d43cc5d0f7dce042ac98237dca7460

Description

成本守卫: A cost-saving plugin for DeepSeek V4-Flash-0731 pure API pricing—calculates session costs, cache hit rates, and the amount saved with full cache hits according to the official peak/off-peak tiers dated 2026-08-17 (peak: 09:00-12:00 / 14:00-18:00); ¥ budget guard (budget = hard limit: once the set budget is spent, llm/stream is short-circuited, no new billing is generated, and execution stops at the limit without an additional switch); session-level convergence switch (input box button); automatic cost routing (for complex tasks, automatically selects depth/convergence/off-peak execution based on complexity × peak/off-peak period × remaining budget; the dynamic safeguard 1−2σ/B converges first and then hard-stops, working automatically with convergence); peak/off-peak awareness and off-peak queue (the cost_defer daemon executes automatically during idle periods). Zero dependencies, prefix-cache neutral, assembled at the host layer without touching internal state in dsh-client-modules (compatibility-friendly).

Compatibility and provenance

Cost Guard is published as @dsh-external/dsh-cost-guard and currently resolves to version 0.1.27. The Hub verifies its manifest and preserves the exact installation source for reproducible installs.

DSH compatibility
*
Runtime surfaces
web
Release source
github
Registry updated

Versions

0.1.27stable