npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

dsh-siliconflow-vision

v1.1.1

Published

DSH 插件:通过硅基流动(SiliconFlow)视觉大模型识别/分析图片,支持本地文件路径、http(s) 图片 URL 与 base64 data URL。含持久化的粘贴识别面板(web 端)。

Readme

dsh-siliconflow-vision

License: MIT

DSH(DeepSeek Harness)插件:通过**硅基流动(SiliconFlow)**的视觉大模型识别/分析图片。

当前主模型通常只支持文本输入,无法直接"看"图。本插件注册一个 analyze_image 模型工具,把图片交给硅基流动的视觉模型(默认 Qwen/Qwen3-VL-32B-Instruct)识别, 再把结果返回给对话模型——从而让 DSH 会话获得完整的图片识别能力。

功能

  • ✅ 识别服务器本地图片文件(传路径)
  • ✅ 识别 http(s) 图片 URL
  • ✅ 识别 base64 data URL
  • ✅ 自定义识别指令(prompt),如"识别图中所有文字"、"图里有什么动物"
  • ✅ 可切换模型(Qwen3-VL 系列、GLM-4.5V、PaddleOCR-VL 等)
  • 🖼️ 可选:交互式"粘贴识别"面板(动态插件形态,见 dynamic/)

安装

方式一:作为 bundle 安装(推荐,持久生效)

把本目录(或 git clone 后的目录)通过 dsh plugin 安装到某个 profile:

dsh plugin --profile demo add ./dsh-siliconflow-vision

安装后 dsh --profile demo 启动即加载 analyze_image 工具。

方式二:作为动态插件加载(会话级)

把 dynamic/host.js 与 dynamic/client.js 的内容通过会话的 cordis 插件工具(cordis_define + cordis_run)加载, 可获得输入框上方的"粘贴识别"面板(浏览器端粘贴/选图 → 识别 → 结果自动发送到主会话)。 注意动态插件是会话级的,进程重启后需要重新激活。

配置 API Key

优先使用环境变量:

export SILICONFLOW_API_KEY="sk-xxxxxxxx"

或者写入密钥文件(任选其一,文件内容为纯文本 Key):

$DSH_HOME/siliconflow.key
~/.dsh/siliconflow.key

Key 在 硅基流动控制台 获取。

使用

在对话中让模型识别图片即可,例如:

分析一下 /root/data/photo.png 里有什么
识别这张图的文字:https://example.com/screenshot.png

模型会调用 analyze_image 工具,参数:

| 参数 | 必填 | 说明 | | --- | --- | --- | | image | ✅ | 服务器本地路径 / http(s) URL / data URL | | prompt | — | 对图片的问题或指令,缺省为通用中文描述 | | model | — | 硅基流动模型 ID,默认 Qwen/Qwen3-VL-32B-Instruct | | maxTokens | — | 输出 token 上限,默认 1024 |

可选模型

| 模型 ID | 特点 | | --- | --- | | Qwen/Qwen3-VL-32B-Instruct | 默认,识别能力强 | | Qwen/Qwen3-VL-8B-Instruct | 更快、更省 | | Qwen/Qwen3-VL-30B-A3B-Instruct | 性价比 | | zai-org/GLM-4.5V | 通用视觉 | | PaddlePaddle/PaddleOCR-VL-1.5 | OCR 文字识别专用 |

技术说明

  • 运行环境:Node.js >= 18(使用原生 fetch,无需 python/shell)
  • 请求格式:OpenAI 兼容 POST https://api.siliconflow.cn/v1/chat/completions
  • 本地图片读取后转 base64 data URL 传入,不走磁盘临时文件
  • API Key 不会出现在插件代码里,从环境变量或密钥文件读取

License

MIT