前言¶
DeepSeek Harness(dsh)已經可以記錄會話用量,但 OpenCode Go 的價格、賬單範圍和對賬單的簡單分析,通常還需要單獨處理。下面介紹一個 DSH 社區插件 hiro-nikaitou/dsh-ocg-billing,它在 dsh 的 web composer 下方提供常駐賬單行,並基於緩存的官方價格完成 OpenCode Go 賬單計算。
這是什麼¶
hiro-nikaitou/dsh-ocg-billing 是一個 DSH 插件,定位爲 OpenCode Go billing layer for DeepSeek Harness (dsh)。
它由 hiro-nikaitou 維護,採用 MIT 許可證。資料中說明,這是一個社區插件,與 DeepSeek AI 或 OpenCode 沒有官方從屬關係。
它解決的問題是:在 dsh 的 web 界面中直接查看 OpenCode Go 的估算賬單,並用緩存的價格表完成賬單計算。
核心功能¶
下面是已覈實的能力:
- 在 web composer 下方顯示常駐賬單行(resident bill line)。
- 緩存官方價格,並進行主動更新檢查。
- 支持全局範圍或單會話範圍的賬單計算。
- 使用默認模型對賬單做分析。
安裝與啓用¶
1、從 profile 添加插件路徑:
dsh plugin --profile web add <path-to-this-repo>
2、或者在 ~/.dsh/config.yaml 中寫 overlay 式配置:
# - insert:
# - id: ocg-billing
# name: '@hiro-nikaitou/dsh-ocg-billing'
3、重啓 dsh web。插件加載後,賬單行會出現在 composer 下方。
典型用法¶
啓用後,可以使用這些工具:
ocg_pricing_statusocg_pricing_checkocg_billocg_bill_analyze
其中,ocg_pricing_check 可用於刷新價格緩存;ocg_bill 用於計算賬單;ocg_bill_analyze 用於結合默認模型分析賬單。
適用場景與注意¶
適合在 DSH web 中使用 OpenCode Go、需要查看估算成本的開發者。使用前注意:
- 插件會以當前
dsh進程權限運行,安裝前應檢查源碼和 MIT 許可證。 - 價格是按官方文檔計算的估算值,實際費用以你的 OpenCode Go 訂閱賬單爲準。
- 訂閱費
$10/month僅作爲參考展示,不會加入 usage cost。 - 如果上游佈局變化導致價格滯後或解析異常,可運行
ocg_pricing_check刷新。 - 已覈實資料說明 DeepSeek Harness 處於 developer preview,peer ranges 跟隨已安裝的
0.1.0-rc.6mainline。
鏈接¶
- 目錄頁:https://www.skillhub.cn/plugins/hiro-nikaitou/dsh-ocg-billing
- GitHub:https://github.com/hiro-nikaitou/dsh-ocg-billing