Skip to content

[Bug]: deepseek-flash accepts native image input on Chat and Responses, but the registry still routes it through the vision sidecar #4436

Description

@jaychou0642-create

Client or integration

Direct HTTP/API client

Area

Provider adapter

Summary

deepseek-flash (DeepSeek V4.1-Flash) accepts native image input on both /chat/completions and /responses, but the built-in DeepSeek entry still classifies it as text-only via noVisionModels. Attached images are therefore pre-described by the vision sidecar instead of being sent upstream, and the catalog only advertises image input because of that sidecar path. Expected: deepseek-flash should be treated as a native vision model and images should go upstream unchanged.

Reproduction

  1. Send POST https://api.deepseek.com/responses with model deepseek-flash, a 16×16 solid red PNG as an input_image data URL, reasoning.effort = "none", max_output_tokens: 300, stream: false → HTTP 200, output text Red.
  2. Repeat with a 32×32 image whose left half is green and right half is blue, asking "This image has two solid colored halves. Name both colors in left-to-right order." → HTTP 200, output text green, blue.
  3. Repeat the same two-tone image on POST https://api.deepseek.com/chat/completions with an image_url content part → HTTP 200, answer green, blue.
  4. Control: point input_image.image_url at https://example.invalid/missing.png on POST /responses → HTTP 400, input[0].image[0]: Failed to download image from https://example.invalid/missing.png.

Request shape used in steps 1–3:

{
  "model": "deepseek-flash",
  "input": [{
    "role": "user",
    "content": [
      { "type": "input_text", "text": "This image has two solid colored halves. Name both colors in left-to-right order." },
      { "type": "input_image", "image_url": "data:image/png;base64,<32x32 left-green/right-blue>" }
    ]
  }],
  "reasoning": { "effort": "none" },
  "max_output_tokens": 300,
  "stream": false
}

Step 4 is decisive: the server actually downloads and decodes the image, so input_image is not replaced with placeholder text.

The same probe with deepseek-v4-flash-vision-exp (the id the docs still point at) returns "model": "deepseek-flash" in the response body — the retired id is routed to V4.1-Flash — and answers the two-tone image correctly as well.

Version

2.52.0

Operating system

macOS (Apple Silicon)

Provider and model

deepseek / deepseek-flash

Logs or error output

POST /responses         model=deepseek-flash  image=16x16 solid red        -> 200  "Red"
POST /responses         model=deepseek-flash  image=32x32 two-tone         -> 200  "green, blue"
POST /chat/completions  model=deepseek-flash  image=32x32 two-tone         -> 200  "green, blue"
POST /responses         model=deepseek-flash  image=https://example.invalid/missing.png
                        -> 400  input[0].image[0]: Failed to download image from https://example.invalid/missing.png

Redacted configuration

Registry default being overridden by the stale classification, src/providers/registry.ts (DeepSeek first-party entry):

// Issue #88: every DeepSeek API model is text-only input (no image support upstream) — the
// vision sidecar describes attached images for them, and the catalog advertises image input
// on their behalf.
noVisionModels: ["deepseek-chat", "deepseek-reasoner", ...DEEPSEEK_NATIVE_THINKING_MODELS],

DEEPSEEK_NATIVE_THINKING_MODELS is ["deepseek-flash", "deepseek-v4-flash"], so deepseek-flash is classified as text-only. The list predates the V4.1 transition; #4282 moved deepseek-flash into it.

Suggested change:

  • Drop deepseek-flash from the DeepSeek entry's noVisionModels (keep deepseek-chat, deepseek-reasoner, and deepseek-v4-flash until that alias is probed too).
  • Add the positive declaration, following the existing vision-preview pattern: modelInputModalities: { "deepseek-flash": ["text", "image"] }.
  • Note for the changelog: this cannot be fixed from user config. router.ts unions the registry list with the saved list, so entries can be added but never removed at the config level.

Stale upstream docs, for reference:

  • Responses API reference still lists model as [deepseek-v4-flash, deepseek-v4-pro] and claims input_image parts "are replaced with a placeholder text".
  • Vision guide still says only deepseek-v4-flash-vision-exp accepts images and other models return 400.

Checks

  • I searched existing issues and documentation.
  • I removed secrets, tokens, account details, request credentials, and personal data.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingproviderProvider adapters, OpenAI-compat presets, upstream API quirks

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions