DeepSeek Harness (DSH) 的插件系统支持功能的灵活扩展。对于依赖计费时段(峰谷电价)来控制模型推理成本的用户,实时掌握当前所处的时段至关重要。dsh-peak-valley 插件通过在界面左下角提供可视化的状态反馈,解决了这一问题。

This is a static plugin maintained by CreateCN. It displays the current peak or valley status using a floating capsule, with a countdown.

Core Features

  • Floating capsule in the lower-left corner showing the current period: valley hours display a green dot, peak hours display an orange dot, and unconfigured displays a gray dot.
  • Countdown to the next peak/valley period: the capsule shows the countdown to the next period and refreshes automatically every 30 seconds.
  • Configurable peak/valley ranges: users can define specific period ranges in the configuration file.
  • Configuration persistence: configuration items are automatically saved to DSH’s settings.yaml.

Installation and Activation

Run the following command to install the plugin:

dsh plugin --profile web add github:CreateCN/dsh-peak-valley

After installation, DeepSeek Harness must be restarted for the plugin to take effect.

Typical Usage

Configuration can be managed through the Settings panel inside the capsule, or by directly editing ~/.dsh/settings.yaml. The configuration namespace is dsbal-peakvalley.

Example configuration:

dsbal-peakvalley:
  timezone: Asia/Shanghai     # 可选,留空则使用本机时区
  peakRanges:
    - 00:30-16:30            # 峰时区间,每行一个 HH:MM-HH:MM,支持跨午夜
  valleyRanges:
    - 16:30-00:30            # 谷时区间

The range format is HH:MM-HH:MM. If the end time is earlier than the start time, it indicates crossing midnight (for example, 16:30-00:30).

Applicable Scenarios and Notes

  • Applicable scenarios: Suitable for users who need to adjust inference strategies based on peak/valley periods or who are concerned about billing costs.
  • Notes: The plugin runs with the current DSH process permissions. It is recommended to check the source code and license (MIT) before installation.
  • Uninstallation: If you need to remove it, you can run:
dsh plugin --profile web rm dsh-peak-valley
# 重启 DSH

This plugin provides DSH users with intuitive time management capabilities through a lightweight UI overlay. For more details, see the plugin catalog or the source repository.