From 95ce70c4fd836c4e0981080eb659279719b2447c Mon Sep 17 00:00:00 2001 From: Classic298 <27028174+Classic298@users.noreply.github.com> Date: Tue, 30 Dec 2025 14:31:13 +0100 Subject: [PATCH] Update Chat.svelte (#20256) --- src/lib/components/chat/Chat.svelte | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/lib/components/chat/Chat.svelte b/src/lib/components/chat/Chat.svelte index 61c431f53e..c5221d6f67 100644 --- a/src/lib/components/chat/Chat.svelte +++ b/src/lib/components/chat/Chat.svelte @@ -1731,13 +1731,14 @@ if (model) { // If there are image files, check if model is vision capable + // Skip this check if image generation is enabled, as images may be for editing or are generated outputs in the history const hasImages = createMessagesList(_history, parentId).some((message) => message.files?.some( (file) => file.type === 'image' || file?.content_type?.startsWith('image/') ) ); - if (hasImages && !(model.info?.meta?.capabilities?.vision ?? true)) { + if (hasImages && !(model.info?.meta?.capabilities?.vision ?? true) && !imageGenerationEnabled) { toast.error( $i18n.t('Model {{modelName}} is not vision capable', { modelName: model.name ?? model.id