In DeepSeek Harness (DSH) development scenarios, a model request failure interrupts the current run and requires manual intervention to continue. The dsh-auto-continue plugin listens for request errors, automatically injects a “continue” instruction after a failure, and switches models along the fallback chain, eliminating the need for manual intervention.
Core Features¶
This plugin primarily solves the automatic recovery problem when model inference fails:
- Monitoring & Recording: Listens for
agent/request-errorto record failures. Failed models are persisted to~/.dsh/auto-continue/model-fails.and survive a DSH restart. - Cooldown Mechanism: Default cooldown period is 5 hours. Within the cooldown window, every switch skips that model until the cooldown expires.
- Cyclic Switching: Failed models are skipped on every switch during the cooldown; the plugin cycles through models along the fallback chain until a working model is found.
- Per-Session Limit: Default cap of 100 continues per session; the counter resets automatically after a normal completion.
- Rate Limit Handling: 429 rate limiting also follows the retry → switch loop.
- Truncation Behavior:
max-tokenstruncation only injects “continue” without switching the model. - Restart Behavior: After a restart, historical leftover failed rounds are not resumed.
- Manual Control: Supports manual pause/resume.
Installation¶
Install via the plugin manager:
github:cglyvip/dsh-auto-continue
Before installing, confirm that the plugin manager declares dsh.bundle.patch; otherwise, the manager will report an error.
Configuration & Usage¶
Session Commands¶
The following commands can be used within a session:
/autocont— view status/autocont on|off— temporary toggle (effective for the current run only)/autocont reset— clear cooldowns and counters
File Configuration¶
The settings file is located at ~/.dsh/auto-continue/settings. (takes priority over the profile). To fully revert to the profile configuration, you can delete this file.
In the profile’s cordis.patch.yml, you can override the following fields:
retriesPerModel: Number of retries for the same model after a failure (default: 3).continueMax: Maximum number of continues per session (default: 100).fallbacks: Fallback chain (list of provider+model).
Logs & File Paths¶
- Log file:
~/.dsh/auto-continue/activity.log(auto-rotated to.oldwhen exceeding 512KB). - Persistent records:
~/.dsh/auto-continue/model-fails.
After installation and restarting DSH, it is recommended to first check activity.log to confirm the plugin has been loaded.