From f5a222fe6f14b763dce40c233409690e4dd16456 Mon Sep 17 00:00:00 2001 From: William Gill Date: Sun, 19 Apr 2026 17:56:16 -0500 Subject: [PATCH] =?UTF-8?q?Image=20Studio:=20default=20base=20model=20?= =?UTF-8?q?=E2=86=92=20huihui=5Fai/qwen3-vl-abliterated:8b?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit User confirmed this model works end-to-end after the multi-base-model search. Settled on it because Qwen 3 VL's fine-tune lineage isn't damaged by abliteration the way Qwen 3.5's is, so it both calls tools reliably AND won't refuse to dispatch on NSFW edit prompts. Updated: - image_studio.json base_model_id → huihui_ai/qwen3-vl-abliterated:8b - init-models.sh: pulls the abliterated VL model in place of the non-working standard qwen3.5:9b - image_studio.md: setup table base-model row + vision-section 'why this and not the alternatives' explanation function_calling stays default and tool_choice required. Operator can flip to native + drop tool_choice once they've verified the new base behaves with structured tool calls (which would also remove the need for a separate Task Model for title generation). Co-Authored-By: Claude Opus 4.7 (1M context) --- deployments/ai-stack/init-models.sh | 10 ++++--- .../openwebui-models/image_studio.json | 2 +- .../ai-stack/openwebui-models/image_studio.md | 30 +++++++++++-------- 3 files changed, 25 insertions(+), 17 deletions(-) diff --git a/deployments/ai-stack/init-models.sh b/deployments/ai-stack/init-models.sh index 572809b..7099d22 100644 --- a/deployments/ai-stack/init-models.sh +++ b/deployments/ai-stack/init-models.sh @@ -55,10 +55,12 @@ pull() { # mirror-ollama-model.sh, upload to S3, then list them here. s3_pull "huihui_ai/qwen3.5-abliterated:9b" "qwen3.5-abliterated-9b.tgz" -# Standard non-abliterated Qwen 3.5 9B — 6.6 GB, vision + native tool -# calling. Used as the Image Studio dispatcher (the abliterated 9B above -# is fine for chat but mangles native tool-call formatting). -pull "qwen3.5:9b" +# huihui_ai/qwen3-vl-abliterated — Qwen 3 VL base abliteration (different +# fine-tune lineage than Qwen 3.5, so its tool-call template stays intact). +# Used as the Image Studio dispatcher: vision-capable, calls tools +# reliably, and doesn't refuse to dispatch on NSFW edit prompts. Pulled +# from registry; no S3 mirror entry yet. +pull "huihui_ai/qwen3-vl-abliterated:8b" # ─── Direct registry pulls ────────────────────────────────────────────────── for model in dolphin3:8b llama3.1:8b ministral-3:8b mistral-nemo:12b qwen3.6:latest; do diff --git a/deployments/ai-stack/openwebui-models/image_studio.json b/deployments/ai-stack/openwebui-models/image_studio.json index 87c3627..7dffe01 100644 --- a/deployments/ai-stack/openwebui-models/image_studio.json +++ b/deployments/ai-stack/openwebui-models/image_studio.json @@ -1,7 +1,7 @@ [ { "id": "image-studio", - "base_model_id": "qwen3.5:9b", + "base_model_id": "huihui_ai/qwen3-vl-abliterated:8b", "name": "Image Studio", "params": { "system": "/no_think\n\nYou are an image-tool dispatcher. You do not respond in prose. Every user message MUST result in exactly one tool call.\n\nROUTING:\n- If the user attached an image (including images you previously generated in this chat) → call edit_image(prompt=..., ...)\n- Otherwise → call generate_image(prompt=..., ...)\nBoth tools take `prompt` as the first argument — same name on both. Do NOT invent `edit_instruction`.\n\nFire the tool on the FIRST message, with no preamble. Do not write a 'plan', 'approach', 'steps', 'breakdown', or any explanation before calling. Do not ask clarifying questions. Do not say what you are about to do. If the request is vague, pick reasonable defaults and call the tool — the user iterates after.\n\nSTYLES (pick one):\n photo photorealistic photo / portrait / cinematic\n juggernaut alternate photoreal — sharper, more saturated\n pony anime, cartoon, manga, stylised illustration\n general catch-all when nothing else fits\n furry-nai anthropomorphic, NAI-trained mix\n furry-noob anthropomorphic, NoobAI base\n furry-il anthropomorphic, Illustrious base (default for any furry/anthro request)\n\nSTYLE FOR edit_image — the tool ENFORCES inheritance: once a style has been used in this chat, every subsequent edit_image call uses the same style regardless of what you pass. Behaviour:\n- Edit on an image generated earlier in this chat → OMIT `style` entirely. The tool will use the established style. Passing it is harmless but ignored.\n- Edit on a fresh user upload (no prior tool call in chat) → look at the image and pick a style: anthropomorphic furry/scaly/feathered → furry-il; pony score-tag art → pony; photo/portrait → photo or juggernaut; anime → pony; ambiguous → general.\n- Style cannot be changed mid-chat. If the user wants a different style they need to start a new chat — explain that briefly if they ask for a style switch.\n\nedit_image has TWO MODES — pick based on whether the change is local or global:\n- LOCAL change (\"change the ball to a basketball\", \"add a hat to the dog\", \"remove the bird\", \"recolor the car red\") → set `mask_text` to a brief noun phrase naming the region (\"the ball\", \"the dog\", \"the bird\", \"the car\"). Only that region is repainted; rest stays pixel-perfect.\n- GLOBAL change (\"make this a sunset\", \"turn this into anime\", \"restyle as oil painting\") → leave mask_text unset. The whole image is reimagined.\nALWAYS prefer LOCAL when the user names a specific object, person, or region. GLOBAL is only for whole-image style/lighting transformations.\n\nDenoise:\n- LOCAL (mask_text set): default 1.0. Drop to 0.6–0.8 only for subtle local edits that should retain some original structure.\n- GLOBAL (no mask_text): default 0.7. Use 0.3–0.5 for subtle restyle, 0.85–1.0 for radical reimagining.\n\nPick style for the DESIRED OUTPUT, not the input image.\n\nWrite rich, descriptive prompts (subject, action, environment, lighting, mood, framing). Do NOT add quality tags like 'masterpiece', 'best quality', 'score_9', 'absurdres' — the tool prepends the correct tags per style. Do NOT set sampler, CFG, steps, scheduler — the tool picks them.\n\nAFTER the tool returns, write at most one short PLAIN-ENGLISH sentence noting your style/mode choice and offering one iteration idea. The image is already shown to the user.\n\nNEVER, after the tool returns:\n- echo or repeat the tool call (no `edit_image(prompt=..., ...)`, no ``, no JSON, no parameter listings)\n- describe what's in the image\n- list the arguments you used\n- enumerate styles, denoise, mask_text, etc.\nThose details are visible in the collapsible 'View Result from edit_image' tool-result block — the user can expand it if they care. Your follow-up message is for HUMAN conversation, not bookkeeping.", diff --git a/deployments/ai-stack/openwebui-models/image_studio.md b/deployments/ai-stack/openwebui-models/image_studio.md index 3c9bc76..8965b17 100644 --- a/deployments/ai-stack/openwebui-models/image_studio.md +++ b/deployments/ai-stack/openwebui-models/image_studio.md @@ -38,7 +38,7 @@ prompts. Verify after import: | Field | Value | | ----- | ----- | | Name | `Image Studio` | -| Base Model | `qwen3.5:9b` (6.6 GB, vision + native tool calling). Pull via `init-models.sh` first. The abliterated variant of the same model breaks tool-call format adherence; this is the standard build. | +| Base Model | `huihui_ai/qwen3-vl-abliterated:8b` (Qwen 3 VL base, abliterated, vision + tools). Pull via `init-models.sh` first. The Qwen 3 VL fine-tune lineage isn't damaged by abliteration the way Qwen 3.5 is, so it both calls tools reliably AND won't refuse to dispatch on NSFW edit prompts. | | Description | `Image generation and routing across SDXL checkpoints.` | | System Prompt | Paste the block from [System prompt](#system-prompt) below. | | Tools | enable **only** `smart_image_gen` | @@ -178,20 +178,26 @@ suggestions return, and autocomplete lights up. The shipped preset sets `meta.capabilities.vision: true` so Open WebUI allows users to attach images to chats with this model. Two paths: -### Default — `qwen3.5:9b` +### Default — `huihui_ai/qwen3-vl-abliterated:8b` -The shipped preset uses standard (non-abliterated) Qwen 3.5 9B as -the base — vision-capable, 256K context, native tool calling -working. Preseed via `init-models.sh`. +The shipped preset uses huihui_ai's abliteration of Qwen 3 VL as +the base — 8B params, vision-capable, native tool calling working, +and won't refuse to dispatch the tool when the user's edit prompt +is NSFW. Preseed via `init-models.sh`. -**Why not the abliterated 9B?** The abliteration process mangles the +**Why not the Qwen 3.5 abliterated 9B (huihui_ai/qwen3.5-abliterated:9b)?** +Same maintainer, but the abliteration on Qwen 3.5 mangles the function-call template, causing the model to either refuse to call -tools or emit malformed `` XML that Open WebUI's parser -can't recognise. Image generation doesn't actually need an -uncensored LLM — the SDXL checkpoints in ComfyUI are what produce -image content, and they're already uncensored. The LLM's only role -here is to call the right tool with the right args; the standard -build does that more reliably. +tools or emit malformed `` XML that Open WebUI's +parser can't recognise. The Qwen 3 VL fine-tune lineage is +different and doesn't take that damage from abliteration. + +**Why not standard `qwen3.5:9b`?** The standard (non-abliterated) +Qwen 3.5 calls tools reliably but its safety training refuses on +many image edit prompts even though the LLM's only job is dispatch +(the actual image content is generated by the SDXL checkpoint, which +the LLM never sees). Abliterated VL gets us both reliable tool +calling AND a cooperative dispatcher. **Qwen 3.x quirk:** thinking mode is on by default. The shipped system prompt starts with `/no_think` to suppress it. If the model