mirror of
https://github.com/DayuanJiang/next-ai-draw-io.git
synced 2026-09-02 01:20:23 +08:00
fix: allow QvQ (Qwen Visual QA) models to use image input (#808)
QvQ models (e.g. qvq-72b-preview, qvq-max) are visual reasoning models from the Qwen family that support image input. When accessed via providers that prefix model names with 'qwen/' (e.g., OpenRouter), these models contain 'qwen' in their ID but lack the 'vl' or 'vision' indicator. This caused supportsImageInput() to incorrectly return false for model IDs like 'qwen/qvq-72b-preview', blocking image uploads for vision-capable models. Add 'qvq' as an explicit exception in the Qwen text-model check so that QvQ models are correctly allowed to receive image input regardless of the provider prefix. Co-authored-by: octo-patch <octo-patch@github.com>
This commit is contained in:
@@ -208,6 +208,13 @@ describe("supportsImageInput", () => {
|
||||
expect(supportsImageInput("qwen3-vl-flash")).toBe(true)
|
||||
})
|
||||
|
||||
it("returns true for QvQ (Qwen Visual QA) models including OpenRouter-prefixed names", () => {
|
||||
expect(supportsImageInput("qvq-72b-preview")).toBe(true)
|
||||
expect(supportsImageInput("qvq-max")).toBe(true)
|
||||
expect(supportsImageInput("qwen/qvq-72b-preview")).toBe(true)
|
||||
expect(supportsImageInput("qwen/qvq-max")).toBe(true)
|
||||
})
|
||||
|
||||
it("returns false for GLM text models", () => {
|
||||
expect(supportsImageInput("glm-4")).toBe(false)
|
||||
expect(supportsImageInput("glm-4-plus")).toBe(false)
|
||||
|
||||
Reference in New Issue
Block a user