DSH Plugins Marketplace

DSH Plugins

Plugins

/

Models & Providers

/

dsh-send-photos

d

dsh-send-photos

Manifest valid

Declares image input on relay routes whose endpoint omits modality metadata, so models that can see photos stop being rejected as text-only. This also overrides routes that are explicitly declared tex

hasBundlePatch

dsh-send-photos

English: README.en.md

让 DSH 接受本会被拒收的图片,用在那些收得下图、却没有声明多模态能力的中转站/反代上。

问题

DSH 判断一个模型能不能收图,只读 llm-pi-ai 解析出来的模型元数据。中转站的 /v1/models 通常不返回模态信息,配置里于是没有 input,落到默认值 ["text"]。图片在到达上游之前就被本地两道闸门拦掉:

层位置表现
会话准入dsh-api-session-controller prompt()session/attachment-invalid,reason MODEL_DOES_NOT_SUPPORT_IMAGES
请求适配dsh-llm-pi-ai streamWithSnapshot()LlmError UNSUPPORTED_CONTENT

所以模型明明认得图,DSH 却在你按下发送时就拒绝。

做法

两道闸门读的是同一个值:adapter 的 modelOf() 解析出的模型对象。插件只在这个方法外面套一层,对管辖范围内的路由,把缺失的 image 补进 input。

  • 不写配置:不碰 cordis.patch.yml,不碰 settings 文档,不动 profile。
  • 不改请求:图片仍以标准 OpenAI image part 发出,没有编码、拆分或伪装。
  • 可逆:插件卸载时把 modelOf 原样还原。
  • 只作用于存在 modelOf 的适配器(pi-ai 路由)。官方 DeepSeek 账号路由走另一个适配器,不受影响。
  • 监听 llm/adapters-updated,后挂载的路由、后新增的模型同样被覆盖。

安装

这是一个 DSH bundle 包(dsh.bundle.patch),不是普通 npm 脚本。

# 桌面版:在插件管理器里以本地目录安装,或
dsh plugin --profile <你的 profile> add link:<本目录绝对路径>

安装后 profile 的 package.json 会增加一条依赖,Loader 里多一行 dsh-send-photos。

卸载:在插件管理器中移除该 bundle(plugin_manager 的 remove_bundle),或

dsh plugin --profile <你的 profile> remove dsh-send-photos

配置

- id: dsh-send-photos
  name: dsh-send-photos
  config:
    providers: []          # 要覆盖的 route;空数组 = 全部已挂载路由
    modalities: [text, image]
    enabled: true

只作用于某个中转站:

    providers:
      - my-relay

注意

  • 这是补声明,不是让上游变强。某个模型上游确实不收图时,请求会在上游失败;把该 route 从 providers 里排除即可。
  • 显式写了 ["text"] 的模型也会被覆盖(解析后无法区分“声明为纯文本”和“没声明”)。如果某个 route 上有这类模型,用 providers 缩小范围,或只保留需要的那条。
  • 依赖 llm-pi-ai 路由(api: openai-completions 这类)。若将来 DSH 改了适配器内部方法名,插件会打一条 warn 并保持无害的空转。
  • 在 DSH 0.2.1-rc.2 上验证通过。

License

MIT

Comments

Loading…

Similar plugins

dsh-vision-bridge

by GooDAnDReaDY

Routes images to a vision model of your choice - auto-rewrite, explicit tools, or hybrid - so a text-only chat model does not fail a turn that contains a picture.

Tools & CapabilitiesVision & MultimodalTerminal & ClientsManifest valid

★ 2

↓ 593/wk

MIT

JavaScript

Sep 26, 2026

dsh plugin --profile web add @goodandready/dsh-vision-bridge

Transparent multimodal routing for text-only models: every image in every model call is fully transcribed (verbatim OCR, data, uncertainty zones, injection-hardened) by your own multimodal understande

Tools & CapabilitiesVision & MultimodalManifest valid

★ 0

dsh plugin --profile web add dsh-mmroute

by ct-jyjntc

Declare whether a configured third-party model accepts image (multimodal) input; writes the modality into the owning provider settings and verifies it through runtime model resolution.

Tools & CapabilitiesModels & ProvidersManifest valid

★ 0

MIT

JavaScript

Sep 7, 2026

dsh plugin --profile web add dsh-model-modality

by Junkrat9527

Vision for text-only dsh models: paste an image and a configured multimodal model transcribes it to text automatically — transparent twin routing, an agent-callable read-image tool, no built-in keys o

Tools & CapabilitiesVision & MultimodalManifest valid

★ 0

↓ 45/wk

MIT

JavaScript

Aug 18, 2026

dsh plugin --profile web add @iroam2375/dsh-autovision

Local OCR fallback for text-only routes: when the session model declares it cannot accept images, the attached image is cached locally and its path injected so the model can call ocr_image — PP-OCRv5

Tools & CapabilitiesVision & MultimodalManifest valid

★ 0

dsh plugin --profile web add dsh-ocr-local

Text-to-image and image-to-image for a model that cannot draw, through any OpenAI-compatible image API, with multiple providers and an automatic fallback model.

Models & ProvidersManifest valid

★ 0

dsh plugin --profile web add kkj-luna-dsh-image-bridge