dsh-web-search-ddg
aooyoo
Zero-token DuckDuckGo search provider for the DeepSeek Harness (DSH) web seam — local headless browser, no API key, no m…
XEsx630/dsh-screenshot
WeChat-style screenshot for the DeepSeek Harness composer: capture the screen (optionally hiding the DSH window), drag-select a region, and attach the image directly to the message. Windows + PowerShell server-side crop.
PROJECT TOPICS
PROJECT README
为 DeepSeek Harness(DSH)Web 对话框提供微信 PC 客户端式截图:点击截图按钮 → 遮罩框选(或先隐藏 DSH 窗口再截)→ 确认后图片卡直接出现在输入框上方,可直接发送;模型拿到图片路径后用本地 vision MCP(或其他读图工具)读取内容。
截图:<绝对路径> 文本(编辑器内为隐藏引用),模型据此调用 vision 工具读图dsh plugin --profile web add github:XEsx630/dsh-screenshot
# 或指定版本标签
dsh plugin --profile web add "github:XEsx630/dsh-screenshot#v0.1.0"
dsh.bundle manifest 会自动把 dsh-screenshot 行挂进 profile。重启 dsh web 并刷新浏览器。
把插件源码放到任意目录(如 D:\path\to\dsh-screenshot),以 link: 方式挂载到 web profile:
~/.dsh/profiles/web/package.json:dependencies 增加 "dsh-screenshot": "link:D:/path/to/dsh-screenshot"dsh.profile.bundles 增加 "dsh-screenshot"~/.dsh/profiles/web/ 运行 pnpm installdsh web 并刷新浏览器截图:C:...\screenshot-xxx.png`后调用mcpvisiondescribe_image/mcpvisionocr_image` 读取内容截图按钮 ──POST /capture──▶ PowerShell screenshot.ps1(全屏,可选隐藏窗口)
└─▶ 临时 PNG($DSH_HOME/uploads/.screenshot-<uuid>.png)
遮罩预览 ◀──GET /preview──────┘
拖拽框选(纯坐标,无 canvas)
└─POST /crop {rect, stage}──▶ 服务端换算物理像素(PNG 真实尺寸比例)
└─▶ PowerShell crop.ps1(System.Drawing Clone)
└─▶ 正式 PNG(screenshot-<时间戳>.png)
图片卡进对话框 ──发送──▶ 注入「截图:<路径>」──▶ 模型调 vision MCP 读图
设计要点:
source: 'screenshot')与 dsh-file-uploads 的引用通道平行共存,互不干扰dsh-screenshot/
├── package.json # dsh.bundle + dsh.client 声明
├── cordis.patch.yml # 插件挂载行
├── README.md
└── lib/
├── index.js # Host: /api/screenshot 路由(capture/crop/preview/delete)
├── client.js # Client: 按钮/菜单/遮罩框选/引用序列化/卡片栏
├── screenshot.ps1 # PowerShell 全屏截图(可选隐藏前台窗口、DPI 感知)
└── crop.ps1 # PowerShell 服务端裁剪(System.Drawing Clone)
| 方法 | 路径 | 说明 |
|---|---|---|
| POST | /api/screenshot/capture |
body {hideWindow?, allScreens?} → 全屏截图到临时文件,返回 {id, width, height, url} |
| POST | /api/screenshot/crop |
body {id, rect:{x,y,w,h}, stage:{w,h}} → 服务端裁剪 → 返回 {file:{name,path,size}} 并清理临时文件 |
| GET | /api/screenshot/preview?id= |
返回临时 PNG(前端预览) |
| DELETE | /api/screenshot/preview?id= |
删除临时 PNG(取消时清理) |
.screenshot-<uuid>.png,id 严格校验 UUID;超过 10 分钟的残留临时文件在下次启动时清扫$DSH_HOME/uploads(可用 DSH_UPLOAD_DIR 重定向到非 C 盘)MIT
CLASSIFICATION EVIDENCE
系统优先读取 GitHub Topics,再与站内分类词典和词根规则比对。