Yvesgao/dsh-cost-estimate ↗★ 2

dsh-cost-estimate

DSH plugin: before answering a large question, show an estimate of tokens and DeepSeek API cost as an inline row in the Web chat stream, then update it with the actual usage after the answer. 适合需要实时监控 API 消费、控制 Token 预算的用户。

パッケージ
dsh-cost-estimate
互換性
未検証
Harness ピア範囲
^0.1.0-rc.6
Cordis ピア範囲
^4.0.1
バージョン
0.2.0
ライセンス
MIT
最終更新
2026/08/30

インストール

$npx -p @deepseek-ai/dsh dsh plugin --profile web add github:Yvesgao/dsh-cost-estimate

ドキュメント

README 全文を読む ↗

配置

cordis.patch.yml 中 config 支持以下键:

键默认值说明
minInputTokens8000预估输入超过该 token 数才显示
minCostCny0.01或预估费用上限超过该元数才显示
defaultModeldeepseek-v4-flash首次 usage 锚定前的模型回退值
headerTokensEstimate6000首次 usage 锚定前,系统提示词 + 工具 schema 的启发式 token 数
defaultCacheHitRatio0.5首次 usage 锚定前假定的缓存命中率

示例:

- id: cost-estimate
  name: dsh-cost-estimate
  config:
    minInputTokens: 20000
    minCostCny: 0.05