Skip to content

fix(providers): mark Qwen3.8 Max Preview as vision-capable - #449

Open
ADanMan wants to merge 1 commit into
andrewyng:mainfrom
ADanMan:fix/qwen38-max-preview-vision
Open

fix(providers): mark Qwen3.8 Max Preview as vision-capable#449
ADanMan wants to merge 1 commit into
andrewyng:mainfrom
ADanMan:fix/qwen38-max-preview-vision

Conversation

@ADanMan

@ADanMan ADanMan commented Aug 5, 2026

Copy link
Copy Markdown

Fixes #401.

The bug

Qwen3.8 Max Preview is multimodal (text/image/video/document, per Alibaba's model card), but there's no curated matrix entry for it. capabilities_for() falls through to the qwen-prefix heuristic in coworker/providers/capabilities.py, which hardcodes vision=False for the whole family (deepseek, glm, kimi, minimax, qwen, grok, mistral, magistral). Selecting this model then silently strips any attached image and replaces it with a [image attachment — not viewable by this model] placeholder before the request reaches the model — no error, just a quiet capability downgrade.

The fix

Add a curated matrix entry (coworker/providers/matrix.py), the same pattern already used for the other vision exceptions (Muse Spark, the native vendors):

"qwen:qwen3.8-max-preview": ModelEntry(
    "Qwen3.8 Max Preview · Alibaba",
    ModelCapabilities(tools=True, vision=True, parallel_tool_calls=True, streaming=True),
    1_000_000,
),

pdf is left at its default (False) — same caveat as Muse Spark, since PDF ingestion is unverified over the OpenAI-compatible surface for this vendor and falls back via pdf_support.py. The existing text-only qwen:qwen3-max entry is untouched.

Since _suggested_models() builds the "add model" datalist from models_for_provider() (matrix-derived) plus COMPAT_MODELS, this also makes qwen3.8-max-preview show up as a suggestion for the Qwen provider without any change needed there.

Testing

  • Added test_qwen38_max_preview_is_curated_vision_true in tests/test_providers.py, covering: the new entry resolves vision=True, the existing qwen3-max entry is unaffected, and a bare (unprefixed) model string still falls through to the conservative heuristic — confirming the matrix entry, not the heuristic, is what fixes this.
  • Full suite: 1113 passed, 1 skipped (uv venv --python 3.11 + pip install -e ".[dev,bedrock,messaging]", pytest tests/) — clean on a fresh env with all optional extras installed.

No UI-visible change (no screenshots) — this is a provider-capabilities data fix; effect is that the composer now sends the image instead of dropping it, per the issue's repro steps.

Qwen3.8 Max Preview is multimodal (text/image/video/document per
Alibaba's model card), but the qwen-prefix heuristic in
capabilities.py hardcodes vision=False for the whole family. With no
curated matrix entry for this model, entry_for() falls through to
that heuristic, so image attachments get silently stripped and
replaced with a "[image attachment — not viewable by this model]"
placeholder before the request ever reaches the model.

Add a curated matrix entry, mirroring the existing vision exceptions
for Muse Spark and the native vendors. pdf is left at its default
(False), matching Muse Spark's caveat: PDF support is unverified over
the OpenAI-compatible surface, so it falls back via pdf_support.py.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Feature request: mark Qwen3.8-Max-Preview as vision-capable (currently stripped by the qwen heuristic)

1 participant