Introduction¶
The plugin system of DeepSeek Harness (DSH) allows you to extend behavior locally. When working with DeepSeek models through DSH, a common scenario arises: you’re currently in a DeepSeek billing peak window (weekdays 9:00–12:00 and 14:00–18:00), but the question at hand would be better suited for off-peak submission to save costs. The Deferred Ask plugin solves this pain point: it queues the question you type in the composer and only submits it when DeepSeek is billing at off-peak rates.
What It Is¶
Deferred Ask is a DSH plugin developed by maintainer wangyz911, categorized as a model inference plugin. Its core value proposition: queue questions in the DSH composer, wait for an off-peak window to open, then automatically submit them—reducing token costs while still getting the answers you need.
Core Features¶
- Queueing questions: Type a question in the composer and press
Ctrl+Enteror click “Defer to off-peak” to queue it. The queue is stored inlocalStorage(key:dsh.deferredAsk.queue.v1) and persists across page reloads. - Off-peak submission: The plugin checks system time every 30 seconds and only creates a one-time schedule once an off-peak window is confirmed, submitting the question five seconds later. The gap between queueing time and submission time is measured in seconds.
- Billing windows (Asia/Shanghai, UTC+8):
- Weekdays 09:00–12:00 and 14:00–18:00: peak rate (full price).
- All other hours (including weekends): off-peak rate (peak rate × 0.5).
- Chinese public holidays: treated as regular weekdays (off-peak rate), but no early submission—execution only occurs after 18:00.
- Submission target: By default, a new session is created. The target folder is resolved by priority: current session’s workspace → the
cwdfield in the Host session summary → the pinned folder in the panel (highest priority). - In-session continuation: Select “Continue in this session” in the panel (stored as
"path": "") to force submission into the current session; select “Automatic” to release the pin and restore the default resolution logic. - Retry mechanism: On submission failure, the question is retained and retried with exponential backoff (starting at 5 minutes, up to 1 hour max), with an error message displayed on the question. The same question will never be submitted concurrently twice.
- Send immediately: The panel provides a “Send now” button that submits at the peak rate immediately—useful for testing or changing your mind on the fly.
- Limitations: Up to 50 queued questions. The discount applies only to token-based billing; subscription plans do not receive price adjustments based on time.
Installation & Enablement¶
The current npm registry version is 1.0.12, which has a bundle name mismatch that prevents the plugin from appearing. The source repository already contains a fixed version 1.0.13. It is recommended to install from source first:
dsh plugin --profile <profile> add github:wangyz911/dsh-deferred-ask
Once npm publishes 1.0.13, you can install directly by package name:
dsh plugin --profile <profile> add dsh-deferred-ask
If you already have 1.0.12 installed via npm, the plugin will not appear below the composer. Switching to a source install resolves this:
dsh plugin --profile <profile> add github:wangyz911/dsh-deferred-ask
If you prefer to keep the npm install, you can edit line 15 of node_modules/dsh-deferred-ask/client.js in your config to change id: '@local/dsh-deferred-ask' to id: 'dsh-deferred-ask'. The client watcher will reload the bundle within one second—no restart needed.
Typical Usage¶
- Open any conversation in DSH and navigate to the composer.
- Type your question and press
Ctrl+Enter. The question is queued and displayed below the composer. - In the panel, choose “Continue in this session” or “Automatic” to determine the submission target.
- Wait for an off-peak window to open (e.g., a weekend or after 18:00 on a weekday). The plugin will auto-submit within 30 seconds.
- If submission fails, check the error hint on the question. The plugin will automatically retry with exponential backoff.
Use Cases & Caveats¶
- Ideal for users who batch questions during off-peak hours, debug code, or engage in long conversations.
- The plugin runs with the current DSH process’s permissions. Review the source code and license (MIT) before installing.
- Billing discounts apply only to token-based billing; subscription plans do not adjust prices based on time of day.
- The plugin requires DSH to remain running to detect the clock and submit questions. After closing the app, submission will be attempted on the next tick following restart.
- Submissions typically start a new session. It is recommended to write questions as self-contained, complete prompts rather than brief “continue from last conversation” instructions.
In Short¶
Deferred Ask queues your questions and submits them at the right billing window, reducing usage costs. For more details and source code, visit the plugin directory page and the GitHub repository.