Preface¶
Common text-only models in DeepSeek Harness (DSH), such as deepseek-v4-flash, do not natively accept image input. If a conversation involves only paths or requests for screenshots, the model cannot directly “see” pixel content. The usual workaround is to switch to a multimodal model or run a vision model locally, which incurs higher costs and requires more significant modifications.
dsh-tool-see-image registers the see_image tool on the Host side: it is invoked on-demand by the text model in the session to pass an image at a specified path to a configurable vision API (defaulting to Zhipu GLM-4V-Flash), and then returns the text description to the current session. The following sections introduce its positioning, installation, and configuration.
What is this¶
- Name:
dsh-tool-see-image(npm package name matches, current version 0.1.2, MIT License) - Maintainer: guguthecoder (Community plugin directory SkillHub Entry)
- Category: Model Inference
- Repository: GitHub
The plugin exposes a single tool to DSH: see_image(image_path, question). Reading the image, encoding, and requesting the vision model are all performed on the Host plane, requiring no changes to the main conversation model you are using, nor requiring a local GPU.
How it Works (Brief Overview)¶
- The user asks the model to view an image in the session; the text-only model cannot read the image directly, so it invokes
see_imageinstead. - The plugin uses
ctx.fsto resolve and read the file (adhering to DSH sandbox and observation policies), encoding the image as a base64 data URL. - It sends a
POST …/chat/completionsrequest to a configured OpenAI-compatible endpoint, defaulting to Zhipuglm-4v-flash. - The text description returned by the vision model enters the session, and the text model continues answering you.
When switching to other compatible endpoints like SiliconFlow or Qwen2.5-VL, you only need to modify three configuration items: baseURL, apiKeyEnv, and model.
Core Features¶
see_imageTool: Pass a local (sandbox-visible) image path and an optional question to get a text description; if no question is provided, a built-in Chinese default prompt for “detailed description” is used.- Replaceable Vision Backend: Any OpenAI-compatible
/chat/completionsinterface; defaults to Zhipu GLM-4V-Flash (documented as available for free on the Zhipu side). - Sandbox Awareness: Does not use
node:fsdirectly; usesctx.fsuniformly, consistent with DSH file access policies. - Optional Capability (Script in same repo):
scripts/patch-dsh-image-relay.mjscan automatically convert images pasted into the Web chat box into text before sending to DeepSeek (requires patching the DSH installation directory, independent of the tool installation).
Installation and Enablement (DSH web profile)¶
The official README does not provide a single-line command like dsh plugin add, but instead places the plugin in the profile and mounts it using a Cordis patch. $DSH_HOME is generally ~/.dsh.
- Copy the plugin directory to the profile, for example:
$DSH_HOME/profiles/web/plugins/dsh-tool-see-image/
- Declare the local dependency in the
dependenciesof$DSH_HOME/profiles/web/package.json:
"dsh-tool-see-image": "file:plugins/dsh-tool-see-image"
Run pnpm install in that profile directory (this creates a link to the plugin source under profiles/node_modules).
- Insert the plugin configuration in
$DSH_HOME/profiles/web/cordis.patch.yml, for example with default Zhipu settings:
- insert:
- id: tool-see-image
name: 'dsh-tool-see-image'
config:
baseURL: https://open.bigmodel.cn/api/paas/v4
apiKeyEnv: ZHIPU_API_KEY
model: glm-4v-flash
- Create an API Key (format
id.secret) on the Zhipu Open Platform and set the environment variable (Windows example):
setx ZHIPU_API_KEY "your-key"
Restart dsh web after reopening the terminal (the documentation notes that the web profile’s patch layer currently does not support hot reload, requiring a process restart).
- Start a new session, confirm that
see_imageappears in the tool list, and try running it with natural language:
Use see_image to look at path/to/your/image.png
Configuration Description¶
The following fields can be adjusted in the config block of tool-see-image within cordis.patch.yml (excerpted from the README configuration table):
| Key | Default Value | Description |
|---|---|---|
baseURL |
https://open.bigmodel.cn/api/paas/v4 |
Root path for OpenAI-compatible API; the plugin appends /chat/completions |
apiKeyEnv |
ZHIPU_API_KEY |
Environment variable name storing the API Key |
model |
glm-4v-flash |
Vision model ID |
maxTokens |
1024 |
Max output tokens; glm-4v-flash limit is 1024, higher values return 400 |
timeoutMs |
60000 |
Request timeout (milliseconds) |
maxBytes |
15728640 (15MB) |
Max size limit for a single image |
prompt |
(Chinese detailed description default instruction) | Default question; the tool parameter question takes precedence |
Example for switching to SiliconFlow:
config:
baseURL: https://api.siliconflow.cn/v1
apiKeyEnv: SILICONFLOW_API_KEY
model: Qwen/Qwen2.5-VL-32B-Instruct
Typical Usage¶
- Identify by Path: Specify the image path in the session, ask the model to call
see_image, and write what you want to ask in thequestion(e.g., “What UI controls are in the image”, “What is the error message”). - Uninstall: Remove the insert block for
tool-see-imagefromcordis.patch.yml; remove the link innode_modules; delete the corresponding dependency line inpackage.json; restartdsh web.
The repository provides test/mount-test.mjs: after setting DSH_CHECKOUT to point to the DSH installation root directory containing node_modules/@deepseek-ai, run it to verify if see_image enters the tool registry (output includes tools.schemas() contains see_image: true and === MOUNT TEST PASS ===).
Use Cases and Precautions¶
Suitable for: Users already using text-only models on the DSH web profile who occasionally need to read screenshots, UI images, document scans, etc., and are willing to use cloud vision APIs (default Zhipu free tier) in exchange for description text.
Precautions:
- The plugin runs under DSH Host process permissions and will send image content to third-party APIs according to configuration; please read the source code and MIT License before installation, and keep the key corresponding to
apiKeyEnvsecure. - Single image 15MB limit, request timeout, and
maxTokensare subject to the selected vision model’s restrictions; the documentation records an issue whereglm-4v-flashreturned 400 becausemax_tokensexceeded 1024, and the current default has been changed to 1024. - The paste-to-text patch modifies built-in DSH packages (host-apiproxy, llm-deepseek, client-ui); enable it only if you understand how to rollback (
--revert).
The DSH ecosystem emphasizes “Everything is a plugin”; community directories like SkillHub are independent of DeepSeek / High-Flyer and are not official app stores. This plugin was previously featured in the community awesome-deepseek-harness-plugins list.
Conclusion¶
dsh-tool-see-image separates “image viewing” from the main model capabilities using a small tool: the text model handles reasoning and orchestration, while the vision model handles image reading, requiring no local GPU by default. If you want to enable it in your existing web profile, simply copy the plugin, run pnpm install, write cordis.patch.yml, and configure the API Key as described above.
- Directory Page: https://www.skillhub.cn/plugins/guguthecoder/dsh-tool-see-image
- GitHub: https://github.com/guguthecoder/dsh-tool-see-image