dsh-plugin-ollama-usage
在终端中运行以下命令:
dsh plugin install CJ-SH/dsh-plugin-ollama-usage
将以下提示词粘贴到 DeepSeek Harness 对话框中:
在 DeepSeek Harness 中执行 dsh plugin install CJ-SH/dsh-plugin-ollama-usage 即可从源码地址 https://github.com/CJ-SH/dsh-plugin-ollama-usage 安装该插件。
插件介绍
You are running Ollama Cloud as a backend inside dsh's web chat. Quota headroom, weekly burn rate—these details live on a separate Ollama dashboard you have to open in another tab. dsh-plugin-ollama-usage pulls the single GET /api/usage endpoint into the chat page itself: a compact panel sits below the composer in active sessions and in the hero area of new conversations, showing both the 5-hour rolling window and the weekly window with their respective percentages, refreshed every five minutes. When credentials are missing or the endpoint returns anything other than 2xx, the panel simply does not render—no placeholder, no error.
Credentials are handled in two modes. The default credential mode reuses your existing OLLAMA_API_KEY without the plugin ever writing to a shared secret; the key mode uses a plugin-specific reference OLLAMA_USAGE_API_KEY that the plugin owns exclusively. Keys are read only on the Host side, never shipped to the browser, and never appear in error messages. The plugin reads one endpoint, modifies no provider configuration, initiates no conversations, and its registration inserts only its own line with an independent route—zero coupling to other bundles.
If you already use Ollama Cloud inside dsh on a daily basis and do not want to context-switch to a dashboard every time you finish a prompt, this is the quiet little widget that answers the question for you. It tucks itself under the input box, stays out of the way when you are fine, and makes the limit visible the moment it matters.
使用场景
- 在 dsh 对话页输入框下方一眼看到 Ollama Cloud 5 小时滚动配额占比,无需另开标签页
- 5 小时窗口即将耗尽时,hero 新会话区域同步显示预警比例
- 在设置 → 插件 → 插件配置中切换凭据模式或调整 baseURL
适合人员
- 日常在 dsh Web 端使用 Ollama Cloud 作为推理后端的独立开发者
- 需要实时掌握配额消耗、避免意外 429 超时的技术用户
- 偏好零侵入、只读端点、不改动 provider 配置的插件使用者