Introduction¶
When configuring model capabilities (such as maxTokens and contextWindow) in DeepSeek Harness (DSH), if the declared values exceed the actual endpoint limits or are incorrect, errors are often not reported. Instead, requests may fail silently (for example, with HTTP 400). The dsh-model-probe plugin probes endpoint behavior directly to correct these declaration errors.
Plugin Overview¶
This plugin is maintained by user xiaomao49 and is a DeepSeek Harness plugin. It sends probe requests to the endpoint, measures the range of capabilities actually accepted by the model, compares the results with the locally declared configuration, and rewrites only the fields proven incorrect by the evidence.
Core Features¶
- Empirical testing and correction: It does not rely on a static knowledge base, but directly measures what the endpoint actually accepts.
- Audit existing values: Unlike plugins that only fill in missing values, it checks whether fields already have values and verifies whether those values are correct.
- Inspection scope: It supports checking four fields:
contextWindow,maxTokens,reasoningEfforts, andinput(image support). - Dual protocol support: It supports both
openai-completionsandanthropic-messagesprotocols. - Self-contained: It is implemented in pure JavaScript, with no build step and no runtime dependencies.
Installation and Activation¶
Before installation, confirm the Profile name actually started by DSH. If installed to the wrong Profile, the plugin will not be loaded.
- Confirm the Profile name:
- DSH Desktop: check the
activefield inprofile-selection/state.json(usually"desktop"). - CLI / Web: use the name specified by
dsh --profile <name>(the default isweb).
- DSH Desktop: check the
- Install the plugin:
dsh plugin --profile web add dsh-model-probe
- Verify the installation:
dsh --profile web --dump-config | grep model-probe
The output contains `id: model-probe`, indicating that it is active.
- Restart: DSH must be completely exited and restarted to complete hot mounting.
Typical Usage¶
Through the Settings Page¶
In the DSH interface, go to Settings -> Model Capability Probe.
- Enable Allow probing for the corresponding Provider.
- Run a scan or confirm applying the changes.
Through Agent Tools¶
In Agent scenarios, the following tools can be used:
model_probe_status: view probe status.model_probe_scan: execute a scan.model_probe_apply: apply corrections.
Notes¶
- Profile limitation: The plugin must be installed to the Profile actually started by DSH (for example,
desktopfor DSH Desktop); otherwise, it will not take effect. - Restart requirement: A full restart of DSH is required for the configuration to take effect.
- Old version compatibility: Versions 0.1.2 and earlier have Peer Dependency warnings (informational only, not affecting runtime) and may fail to report errors correctly when all requests fail. It is recommended to use the latest version.
Summary¶
dsh-model-probe solves silent failures caused by a mismatch between declared model capabilities and the actual endpoint. It is especially suitable for scenarios that require precise control of model context and Token limits. The plugin provides a self-contained pure JavaScript implementation and supports two usage methods: the settings page and Agent tools.