Qwen3.8-Flash-Next on any consumer hardware: one-click install for Windows / Linux. Strata inference engine, OpenAI/Anthropic API on localhost, optional image input.
C++
setup: Unsloth's UD-IQ4_XS is a regular choice (no longer experimental); UD-Q4_K_XL stays experimental
Niko122191b0f5365972
diff --git a/README.de.md b/README.de.mdindex a3215ecf9..e400395e2 100644--- a/README.de.md+++ b/README.de.md@@ -121,7 +121,7 @@ stark komprimiert. Kleinere Größen sind schneller. Größere sind etwas klüge| **32 GB** | **Coder** | passt in 32 GB und ist für Code gemacht (mit einer 24-GB-Karte laufen auch Q2_0 und IQ2_XS) || **48 GB** | **IQ2_XS** (oder Q2_0, das schnellste) | die größeren Größen passen nicht || **64 GB** | **IQ2_XS** (empfohlen) oder IQ3_XXS / IQ3_S | alle Größen passen; IQ3_S ist das beste und das langsamste |-| **96 GB oder mehr** | **IQ3_S** oder das 4-Bit-Modell von Unsloth (experimentell) | Platz für die größten Größen, auch wenn alles andere offen ist |+| **96 GB oder mehr** | **IQ3_S** oder Unsloths UD-IQ4_XS (~4 Bit) | Platz für die größten Größen, auch wenn alles andere offen ist |- **[Coder](docs/MODELS.md#coder):** eine Version für Code, bei der die Hälfte der Experten entfernt wurde. Sieerreicht 91 % des SWE-bench-Verified-Werts des vollen Modells (von ihren Autoren gemessen) und passt in 32 GB RAM.@@ -129,6 +129,9 @@ stark komprimiert. Kleinere Größen sind schneller. Größere sind etwas klügeoder IQ3_S, die alle Experten behalten.- **[Swift 1.5](docs/MODELS.md#swift-15):** ein Fine-Tune, das viel kürzer nachdenkt, bevor es antwortet. Dubekommst die Antwort früher, bei etwa gleicher Qualität.+- **[Unsloth UD-IQ4_XS](docs/MODELS.md#unsloth-ud-iq4_xs):** die ~4-Bit-Version von Unsloth, in der Qualität+ zwischen IQ3_S und UD-Q4_K_XL. 94 GB Download. Mit weniger als ~80 GB RAM liest Strata einen Teil davon während+ der Antwort von der SSD, dort ist es also langsamer (eine NVMe-SSD hilft).- **[Unsloth UD-Q4_K_XL](docs/MODELS.md#unsloth-ud-q4_k_xl-experimental)** (experimentell): am nächsten am vollenModell. Aber Strata liest das meiste davon während der Antwort von der SSD, deshalb schreibt es auf einem PC mit64 GB nur 7-8.5 Tokens/s.diff --git a/README.es.md b/README.es.mdindex 60b5f1d92..936c13de1 100644--- a/README.es.md+++ b/README.es.md@@ -118,7 +118,7 @@ tamaños pequeños son más rápidos. Los grandes son algo más inteligentes.| **32 GB** | **Coder** | cabe en 32 GB y está hecho para programar (con una tarjeta de 24 GB también funcionan Q2_0 e IQ2_XS) || **48 GB** | **IQ2_XS** (o Q2_0, el más rápido) | los tamaños más grandes no caben || **64 GB** | **IQ2_XS** (recomendado), o IQ3_XXS / IQ3_S | caben todos los tamaños; IQ3_S es el mejor y el más lento |-| **96 GB o más** | **IQ3_S**, o el de 4 bits de Unsloth (experimental) | espacio para los tamaños más grandes con todo lo demás abierto |+| **96 GB o más** | **IQ3_S**, o el UD-IQ4_XS de Unsloth (~4 bits) | espacio para los tamaños más grandes con todo lo demás abierto |- **[Coder](docs/MODELS.md#coder):** una versión para programar a la que se le quitó la mitad de los expertos. Alcanzael 91% de la puntuación SWE-bench Verified del modelo completo (medido por sus autores) y cabe en 32 GB de RAM. Es@@ -126,6 +126,9 @@ tamaños pequeños son más rápidos. Los grandes son algo más inteligentes.conservan todos los expertos.- **[Swift 1.5](docs/MODELS.md#swift-15):** un ajuste fino que piensa mucho menos tiempo antes de responder. Recibesla respuesta antes, con más o menos la misma calidad.+- **[Unsloth UD-IQ4_XS](docs/MODELS.md#unsloth-ud-iq4_xs):** la versión de ~4 bits de Unsloth, entre IQ3_S y+ UD-Q4_K_XL en calidad. Una descarga de 94 GB. Con menos de ~80 GB de RAM, Strata lee una parte desde el SSD+ mientras responde, así que ahí es más lento (un SSD NVMe ayuda).- **[Unsloth UD-Q4_K_XL](docs/MODELS.md#unsloth-ud-q4_k_xl-experimental)** (experimental): el más parecido al modelocompleto. Pero Strata lee la mayor parte desde el SSD mientras responde, así que solo escribe 7-8.5 tokens/s en unPC con 64 GB.diff --git a/README.fr.md b/README.fr.mdindex 352321695..22faf7d89 100644--- a/README.fr.md+++ b/README.fr.md@@ -118,7 +118,7 @@ compressées. Les petites tailles sont plus rapides. Les grandes sont un peu plu| **32 Go** | **Coder** | il tient dans 32 Go et il est fait pour le code (avec une carte de 24 Go, Q2_0 et IQ2_XS tournent aussi) || **48 Go** | **IQ2_XS** (ou Q2_0, le plus rapide) | les plus grandes tailles ne tiennent pas || **64 Go** | **IQ2_XS** (recommandé), ou IQ3_XXS / IQ3_S | toutes les tailles tiennent ; IQ3_S est le meilleur et le plus lent |-| **96 Go ou plus** | **IQ3_S**, ou le 4 bits d'Unsloth (expérimental) | de la place pour les plus grandes tailles, avec tout le reste ouvert |+| **96 Go ou plus** | **IQ3_S**, ou l'UD-IQ4_XS d'Unsloth (~4 bits) | de la place pour les plus grandes tailles, avec tout le reste ouvert |- **[Coder](docs/MODELS.md#coder) :** une version pour le code, avec la moitié des experts en moins. Elle atteint 91 %du score SWE-bench Verified du modèle complet (mesuré par ses auteurs) et tient dans 32 Go de RAM. Elle est moins@@ -126,6 +126,9 @@ compressées. Les petites tailles sont plus rapides. Les grandes sont un peu pluIQ2_XS ou IQ3_S, qui gardent tous les experts.- **[Swift 1.5](docs/MODELS.md#swift-15) :** un fine-tune qui réfléchit bien moins longtemps avant de répondre. Vousavez la réponse plus tôt, avec à peu près la même qualité.+- **[Unsloth UD-IQ4_XS](docs/MODELS.md#unsloth-ud-iq4_xs)** : la version ~4 bits d'Unsloth, entre IQ3_S et+ UD-Q4_K_XL en qualité. Un téléchargement de 94 Go. Avec moins de ~80 Go de RAM, Strata en lit une partie depuis+ le SSD pendant qu'il répond, il y est donc plus lent (un SSD NVMe aide).- **[Unsloth UD-Q4_K_XL](docs/MODELS.md#unsloth-ud-q4_k_xl-experimental)** (expérimental) : le plus proche du modèlecomplet. Mais Strata en lit la plus grande partie depuis le SSD pendant qu'il répond, donc il n'écrit que7-8.5 tokens/s sur un PC avec 64 Go.diff --git a/README.ja.md b/README.ja.mdindex 29f61f670..897322fb5 100644--- a/README.ja.md+++ b/README.ja.md@@ -118,13 +118,15 @@ Strata のインストール、起動、停止もできます。| **32 GB** | **Coder** | 32 GB に収まり、コード向けに作られている(24 GB のカードなら Q2_0 と IQ2_XS も動く) || **48 GB** | **IQ2_XS**(または最速の Q2_0) | 大きいサイズは収まらない || **64 GB** | **IQ2_XS**(おすすめ)、または IQ3_XXS / IQ3_S | すべてのサイズが収まる。IQ3_S がいちばん賢く、いちばん遅い |-| **96 GB 以上** | **IQ3_S**、または Unsloth の 4-bit(試験的) | ほかのものを全部開いたままでも、最大のサイズが入る余裕がある |+| **96 GB 以上** | **IQ3_S**、または Unsloth の UD-IQ4_XS(約 4-bit) | ほかのものを全部開いたままでも、最大のサイズが入る余裕がある |- **[Coder](docs/MODELS.md#coder):** エキスパートを半分取り除いたコーディング向け版です。フルモデルの SWE-bench Verified スコアの91% に届き(作者による測定)、32 GB の RAM に収まります。コード以外では弱く、中国語などの CJK のテキストも苦手です(#438)。そうした用途には、すべてのエキスパートを残している Q2_0、IQ2_XS、IQ3_S を選んでください。- **[Swift 1.5](docs/MODELS.md#swift-15):** 答える前に考える時間がずっと短いファインチューン版です。ほぼ同じ品質のまま、答えが早く返ってきます。+- **[Unsloth UD-IQ4_XS](docs/MODELS.md#unsloth-ud-iq4_xs):** Unsloth の約 4-bit 版で、品質は IQ3_S と UD-Q4_K_XL の間です。+ ダウンロードは 94 GB。RAM が約 80 GB 未満だと、答えている間に Strata がその一部を SSD から読むので遅くなります(NVMe SSD が有効です)。- **[Unsloth UD-Q4_K_XL](docs/MODELS.md#unsloth-ud-q4_k_xl-experimental)**(試験的):フルモデルにいちばん近いものです。ただし答えている間、Strata はその大部分を SSD から読むので、64 GB の PC では毎秒 7-8.5 トークンしか書き出せません。- **[OrcaRouter's Uncensored IQ3_XXS](docs/MODELS.md#orcarouter-uncensored-iq3_xxs):** 手動でセットアップします。diff --git a/README.md b/README.mdindex 01cba0156..ae464b410 100644--- a/README.md+++ b/README.md@@ -118,13 +118,16 @@ sizes are faster. Larger sizes are a bit smarter.| **32 GB** | **Coder** | it fits 32 GB, and it is made for code (with a 24 GB card, Q2_0 and IQ2_XS run too) || **48 GB** | **IQ2_XS** (or Q2_0, the fastest) | the larger sizes do not fit || **64 GB** | **IQ2_XS** (recommended), or IQ3_XXS / IQ3_S | every size fits; IQ3_S is the best and the slowest |-| **96 GB or more** | **IQ3_S**, or Unsloth's 4-bit (experimental) | room for the largest sizes with everything else open |+| **96 GB or more** | **IQ3_S**, or Unsloth's UD-IQ4_XS (~4-bit) | room for the largest sizes with everything else open |- **[Coder](docs/MODELS.md#coder):** a coding version with half of the experts removed. It reaches 91% of the fullmodel's SWE-bench Verified score (measured by its authors) and fits 32 GB of RAM. It is weaker outside code,including Chinese and other CJK text (#438). For those, take Q2_0, IQ2_XS or IQ3_S, which keep every expert.- **[Swift 1.5](docs/MODELS.md#swift-15):** a fine-tune that thinks for a much shorter time before it answers. Youget the answer sooner, at about the same quality.+- **[Unsloth UD-IQ4_XS](docs/MODELS.md#unsloth-ud-iq4_xs):** Unsloth's ~4-bit version, between IQ3_S and+ UD-Q4_K_XL in quality. A 94 GB download. With less than ~80 GB of RAM, Strata reads part of it from the SSD+ while it answers, so it is slower there (an NVMe SSD helps).- **[Unsloth UD-Q4_K_XL](docs/MODELS.md#unsloth-ud-q4_k_xl-experimental)** (experimental): the closest to the fullmodel. But Strata reads most of it from the SSD while it answers, so it writes only 7-8.5 tokens/s on a 64 GB PC.- **[OrcaRouter's Uncensored IQ3_XXS](docs/MODELS.md#orcarouter-uncensored-iq3_xxs):** you set it up by hand. It isdiff --git a/README.pt-BR.md b/README.pt-BR.mdindex 4cead3b49..a34dbf2f5 100644--- a/README.pt-BR.md+++ b/README.pt-BR.md@@ -118,7 +118,7 @@ Os tamanhos menores são mais rápidos. Os maiores são um pouco mais inteligent| **32 GB** | **Coder** | cabe em 32 GB e é feito para código (com uma placa de 24 GB, Q2_0 e IQ2_XS também rodam) || **48 GB** | **IQ2_XS** (ou Q2_0, o mais rápido) | os tamanhos maiores não cabem || **64 GB** | **IQ2_XS** (recomendado), ou IQ3_XXS / IQ3_S | todos os tamanhos cabem; IQ3_S é o melhor e o mais lento |-| **96 GB ou mais** | **IQ3_S**, ou o 4-bit da Unsloth (experimental) | espaço para os maiores tamanhos com todo o resto aberto |+| **96 GB ou mais** | **IQ3_S**, ou o UD-IQ4_XS da Unsloth (~4-bit) | espaço para os maiores tamanhos com todo o resto aberto |- **[Coder](docs/MODELS.md#coder):** uma versão para programação com metade dos experts removida. Ela alcança 91%da pontuação do modelo completo no SWE-bench Verified (medido pelos autores) e cabe em 32 GB de RAM. É mais fraca@@ -126,6 +126,9 @@ Os tamanhos menores são mais rápidos. Os maiores são um pouco mais inteligentmantêm todos os experts.- **[Swift 1.5](docs/MODELS.md#swift-15):** um fine-tune que pensa por bem menos tempo antes de responder. Vocêrecebe a resposta mais cedo, com quase a mesma qualidade.+- **[Unsloth UD-IQ4_XS](docs/MODELS.md#unsloth-ud-iq4_xs):** a versão de ~4 bits da Unsloth, entre IQ3_S e+ UD-Q4_K_XL em qualidade. Um download de 94 GB. Com menos de ~80 GB de RAM, o Strata lê uma parte dele do SSD+ enquanto responde, então ali ele fica mais lento (um SSD NVMe ajuda).- **[Unsloth UD-Q4_K_XL](docs/MODELS.md#unsloth-ud-q4_k_xl-experimental)** (experimental): o mais próximo do modelocompleto. Mas o Strata lê a maior parte dele do SSD enquanto responde, então ele escreve só 7-8.5 tokens/s num PCcom 64 GB.diff --git a/README.zh-CN.md b/README.zh-CN.mdindex ac46df386..6eb1220dd 100644--- a/README.zh-CN.md+++ b/README.zh-CN.md@@ -113,12 +113,14 @@ NVIDIA 和 AMD 的步骤完全一样。安装程序会识别你的显卡,并| **32 GB** | **Coder** | 32 GB 装得下,而且专为代码打造(如果显卡是 24 GB,Q2_0 和 IQ2_XS 也能跑) || **48 GB** | **IQ2_XS**(或 Q2_0,最快) | 更大的规格装不下 || **64 GB** | **IQ2_XS**(推荐),或 IQ3_XXS / IQ3_S | 所有规格都装得下;IQ3_S 最好,也最慢 |-| **96 GB 或以上** | **IQ3_S**,或 Unsloth 的 4-bit 版本(实验性) | 开着其他程序也能放下最大的规格 |+| **96 GB 或以上** | **IQ3_S**,或 Unsloth 的 UD-IQ4_XS(约 4-bit) | 开着其他程序也能放下最大的规格 |- **[Coder](docs/MODELS.md#coder):** 编程版本,去掉了一半专家。它达到完整模型 SWE-bench Verified 分数的 91%(由其作者测得),32 GB 内存就能装下。代码以外的能力较弱,包括中文和其他中日韩文本(#438)。这类用途请选 Q2_0、IQ2_XS 或 IQ3_S,它们保留了所有专家。- **[Swift 1.5](docs/MODELS.md#swift-15):** 一个微调版本,回答前思考的时间短得多。你能更早拿到答案,质量基本不变。+- **[Unsloth UD-IQ4_XS](docs/MODELS.md#unsloth-ud-iq4_xs):** Unsloth 的约 4-bit 版本,质量介于 IQ3_S 和 UD-Q4_K_XL 之间。+ 下载 94 GB。内存少于约 80 GB 时,Strata 回答时要从 SSD 读取其中一部分,所以会更慢(NVMe SSD 有帮助)。- **[Unsloth UD-Q4_K_XL](docs/MODELS.md#unsloth-ud-q4_k_xl-experimental)**(实验性):最接近完整模型。但 Strata回答时要从 SSD 读取其中大部分内容,所以在 64 GB 的电脑上每秒只能写 7-8.5 个 token。- **[OrcaRouter 的 Uncensored IQ3_XXS](docs/MODELS.md#orcarouter-uncensored-iq3_xxs):** 需要手动设置,不在安装程序的菜单里。diff --git a/docs/AI_SETUP.md b/docs/AI_SETUP.mdindex 93cf92189..3eb9dfcf1 100644--- a/docs/AI_SETUP.md+++ b/docs/AI_SETUP.md@@ -14,7 +14,7 @@ Work through the steps in order. Tell the user what you are doing in plain wordsuser the key. Never put a tunnel or port forward in front of a server without a key.- Do not change the user's system beyond what setup does (setup installs Python for the user account if needed,and everything else inside the Strata folder and its `Strata-data` folder). Ask before installing drivers.-- The model download is ~70 GB (up to 111 GB for Unsloth's 4-bit). Confirm the user is fine with that before you+- The model download is ~70 GB (94 GB for Unsloth's UD-IQ4_XS, 111 GB for UD-Q4_K_XL). Confirm the user is fine with that before youstart, especially on a metered connection.- Setup is long-running (an hour or more on a slow connection). Run it in the background or with a long timeout andpoll its output; do not kill it because it is quiet for a while. It is resumable: running the same command again@@ -73,7 +73,7 @@ By the PC's RAM (ask the user whether they mainly want it for code - then the Co| 32 GB | `--family coder` (size IQ1_M) | for code; with a 24 GB card Q2_0 and IQ2_XS also run (setup picks the low-RAM mode) || 48 GB | `--family qwen --model IQ2_XS` | or `Q2_0` (fastest) || 64 GB | `--family qwen --model IQ2_XS` (recommended) | `IQ3_XXS` / `IQ3_S` are slower and a bit better |-| 96 GB+ | `--family qwen --model IQ3_S` | `--family unsloth --model UD-Q4_K_XL` is experimental: NVIDIA only, NVMe SSD, 7-8.5 tokens/s on 64 GB |+| 96 GB+ | `--family qwen --model IQ3_S` | `--family unsloth --model UD-IQ4_XS` (~4-bit, 94 GB, part of the experts read from the SSD under ~80 GB of RAM); `--model UD-Q4_K_XL` is experimental: NVIDIA only, NVMe SSD, 7-8.5 tokens/s on 64 GB |`--family swift` (Swift 1.5, a fine-tune that thinks shorter; sizes Q2_0, IQ2_XS, IQ3_XXS) is the alternative to`qwen`. With `--yes` and no `--model`, setup picks the recommended size for the RAM itself. More: [MODELS.md](MODELS.md).@@ -93,7 +93,7 @@ The flags (all of them: `START-HERE.bat --help`):| --- | --- || `--yes` | take the recommended answer to every question (no prompts) || `--family qwen\|swift\|coder\|unsloth` | the model version |-| `--model Q2_0\|IQ2_XS\|IQ3_XXS\|IQ3_S\|IQ1_M\|UD-Q4_K_XL` | the size (the Coder is IQ1_M, Unsloth UD-Q4_K_XL) |+| `--model Q2_0\|IQ2_XS\|IQ3_XXS\|IQ3_S\|IQ1_M\|UD-IQ4_XS\|UD-Q4_K_XL` | the size (the Coder is IQ1_M, Unsloth UD-IQ4_XS or UD-Q4_K_XL) || `--context N` | context in tokens; default by VRAM: 32768 under 14 GB, 65536 under 20 GB, else 131072 || `--vision yes\|no\|gpu\|cpu` | read pictures; `--yes` leaves images off. AMD cards: `cpu` || `--gpu N` / `--gpus 0,1` / `--gpus all` | one card, or several sharing the model (default: the card with the most VRAM) |@@ -133,7 +133,7 @@ Notes:## 6. Start the serverSetup prints the start script it wrote (`start script: run-<model>.bat`). The name is the family tag plus the size,-lower case: `run-iq2_xs`, `run-swift-iq2_xs`, `run-coder-iq1_m`, `run-unsloth-ud-q4_k_xl`.+lower case: `run-iq2_xs`, `run-swift-iq2_xs`, `run-coder-iq1_m`, `run-unsloth-ud-iq4_xs`.```Windows (PowerShell): Start-Process -FilePath ".\run-iq2_xs.bat" (opens its own window)diff --git a/docs/MCP_SERVER.md b/docs/MCP_SERVER.mdindex b72c659c2..4fc053697 100644--- a/docs/MCP_SERVER.md+++ b/docs/MCP_SERVER.md@@ -111,7 +111,7 @@ The command is `python <Strata folder>/tools/strata_mcp.py`. The transport is st| --- | --- | --- || `strata_status` | Whether a model is running: the model, engine version, context, busy or idle, VRAM and RAM in use. What is installed: models, start scripts, engine version, data folder, downloads. An install in progress. This PC's hardware: OS, CPU, RAM, GPUs, page file, free disk. The model and context setup recommends for this PC. | `port`, `hardware` (true/false) || `strata_models` | Every family and size setup offers, with download size, RAM needed, whether it fits this PC, and whether it is installed. Also the context lengths and the recommendation. | - |-| `strata_install` | Runs setup without questions, in the background (see below). Without `confirm: true` it only returns the plan. A second call shows the progress. `cancel: true` stops the install. | `family` (qwen, swift, coder, unsloth), `model` (Q2_0, IQ2_XS, IQ3_XXS, IQ3_S, IQ1_M, UD-Q4_K_XL), `context` (8192 ... 524288), `vision` (no, yes, gpu, cpu), `kv` (int8, q4_0, k8v4), `gpu` (a number) or `gpus` ("0,2", "all"), `backend` (auto, cuda, hip), `low_ram`, `port`, `data_dir`, `confirm`, `cancel` |+| `strata_install` | Runs setup without questions, in the background (see below). Without `confirm: true` it only returns the plan. A second call shows the progress. `cancel: true` stops the install. | `family` (qwen, swift, coder, unsloth), `model` (Q2_0, IQ2_XS, IQ3_XXS, IQ3_S, IQ1_M, UD-IQ4_XS, UD-Q4_K_XL), `context` (8192 ... 524288), `vision` (no, yes, gpu, cpu), `kv` (int8, q4_0, k8v4), `gpu` (a number) or `gpus` ("0,2", "all"), `backend` (auto, cuda, hip), `low_ram`, `port`, `data_dir`, `confirm`, `cancel` || `strata_start` | Starts an installed model in the background and waits until it answers. If it is not ready after `wait_seconds` (default 50), it returns "loading". | `model` (an id from `strata_status`, e.g. `q2_0`, `coder-iq1_m`; default: the most recently used), `port`, `gpu`, `wait_seconds` (0-600) || `strata_stop` | Unloads the model through the server's own API, then ends the server it started. | `port`, `force` || `strata_logs` | The last lines of the server log, the engine log or the setup log. | `source` (server, engine, setup), `model`, `lines` (1-500) |diff --git a/docs/MODELS.md b/docs/MODELS.mdindex b2e0d00ed..1ffc87f5a 100644--- a/docs/MODELS.md+++ b/docs/MODELS.md@@ -14,7 +14,7 @@ The installer recommends one for your PC; this page explains the choice. Back to| **32 GB** | **Coder** | it fits 32 GB; best at code, weaker at everything else ([why](#coder)). With a 24 GB card, Q2_0 and IQ2_XS run too ([low-RAM mode](#a-big-graphics-card-and-little-ram)) and are the better pick for general use || **48 GB** | **IQ2_XS** (or Q2_0, the fastest) | the larger sizes do not fit || **64 GB** | **IQ2_XS** (recommended), or IQ3_XXS / IQ3_S | every size fits (IQ3_S with little else open) |-| **96 GB or more** | **IQ3_S**, or [Unsloth's 4-bit](#unsloth-ud-q4_k_xl-experimental) (experimental) | room for the largest sizes |+| **96 GB or more** | **IQ3_S**, or [Unsloth's UD-IQ4_XS](#unsloth-ud-iq4_xs) (~4-bit) | room for the largest sizes |Not sure? Take **IQ2_XS**. The **Coder** is the one that fits a 32 GB PC, but it keeps only 256 of the 512 experts,chosen on code data, so it is weaker outside code and in languages other than English. For general use, or whenever@@ -117,9 +117,22 @@ More: [details](DETAILS.md#or-swift-15-a-fine-tune-that-thinks-shorter).START-HERE.bat --setup --family swift --model IQ2_XS```+### Unsloth UD-IQ4_XS++**Unsloth's UD-IQ4_XS** (~4-bit) is the fourth version in setup's menu (`--family unsloth`, its first size), a+regular choice from 0.1.39: a 94 GB download with 59.5 GB of experts (IQ3_S and IQ4_NL), between IQ3_S and UD-Q4_K_XL+in quality. Strata keeps your RAM minus 24 GB of the experts in RAM and reads the rest from the SSD while it answers:+on a 64 GB PC part of them come from the SSD (slower; an NVMe SSD helps), from ~80 GB of RAM all of them stay in RAM.+It needs 48 GB of RAM or more and engine 0.1.38 or newer; images are an option, as with the other models.+Details: [UD-IQ4_XS](UNSLOTH_Q4.md#ud-iq4_xs-setup-from-0139-621).++```+START-HERE.bat --setup --family unsloth --model UD-IQ4_XS+```+### Unsloth UD-Q4_K_XL (experimental)-**Unsloth's 4-bit UD-Q4_K_XL** (experimental) is the fourth version in setup's menu (`--family unsloth`): the closest+**Unsloth's 4-bit UD-Q4_K_XL** (experimental) is the second size of the same family (`--family unsloth`): the closestto the full model, but a 111 GB download whose 77 GB of experts do not fit in RAM. Strata keeps your RAM minus 24 GBof them in RAM and reads the rest from the SSD while it answers: 7-8.5 tokens/s on a 64 GB PC with a 12 GB GPU, severaltimes slower than the sizes above, and long prompts are slow. It needs 48 GB of RAM or more, an NVMe SSD and one@@ -129,15 +142,6 @@ NVIDIA GPU (no images yet). Details and measurements: [UD-Q4_K_XL](UNSLOTH_Q4.mdSTART-HERE.bat --setup --family unsloth --model UD-Q4_K_XL```-**Unsloth's UD-IQ4_XS** (experimental, 0.1.39, #621) is the smaller choice of the same family: a 94 GB download with-59.5 GB of experts (IQ3_S and IQ4_NL), between IQ3_S and UD-Q4_K_XL. Setup runs it the same way (a RAM budget of your-RAM minus 24 GB, the rest from the SSD), so on a 64 GB PC far fewer experts come from the SSD than with UD-Q4_K_XL, and-on 96 GB all of them stay in RAM. Not measured on NVIDIA yet: [details](UNSLOTH_Q4.md#ud-iq4_xs-experimental-setup-from-0139-621).--```-START-HERE.bat --setup --family unsloth --model UD-IQ4_XS-```-### OrcaRouter Uncensored IQ3_XXSFor **OrcaRouter's Flash-Next Uncensored IQ3_XXS**, see the [manual compatibility setup](ORCA.md). It needs andiff --git a/docs/UNSLOTH_Q4.md b/docs/UNSLOTH_Q4.mdindex 6bffe67f8..e275dec7c 100644--- a/docs/UNSLOTH_Q4.md+++ b/docs/UNSLOTH_Q4.md@@ -221,10 +221,11 @@ engine with `--short-read` covering the positions to compare; llama.cpp's side w| `STRATA_PARTIAL_PIN=1` | Registers the hottest part of the RAM budget (up to `STRATA_PARTIAL_PIN_GIB`, default 24) with the GPU driver, so the GPU computes a share of the misses over PCIe (`--pcie-frac`). Measured no faster on this PC, and it changes the numerics of those experts (GPU kernels instead of the CPU's), so off. || `STRATA_FETCH_THREADS=N` | Threads that read the experts from the GGUF while it answers (default 8; 16 was no faster). The prompt path has its own: `STRATA_STAGER_THREADS` (default 32 here) and `STRATA_STAGER_RING` (128). |-## UD-IQ4_XS (experimental, setup from 0.1.39, #621)+## UD-IQ4_XS (setup from 0.1.39, #621)-Unsloth's `UD-IQ4_XS` at the same revision is in setup too: `START-HERE.bat --setup --family unsloth --model-UD-IQ4_XS` (engine 0.1.38 or newer). It sits between IQ3_S and UD-Q4_K_XL: its routed experts are IQ3_S gate/up (IQ4_XS+Unsloth's `UD-IQ4_XS` at the same revision is in setup too, as a regular choice (not experimental; the Unsloth+family's first size and its default): `START-HERE.bat --setup --family unsloth --model UD-IQ4_XS` (engine 0.1.38 or+newer). It sits between IQ3_S and UD-Q4_K_XL: its routed experts are IQ3_S gate/up (IQ4_XSin one layer) with IQ4_NL downs (Q8_0 in five layers), 59.5 GB of them; the dense side (Q8_0 projections, the IQ4_NLPLE table, a Q6_K head) is UD-Q4_K_XL's. Three shards, 93.7 GB:@@ -235,8 +236,10 @@ PLE table, a Q6_K head) is UD-Q4_K_XL's. Three shards, 93.7 GB:| `Qwen3.8-Flash-Next-UD-IQ4_XS-00003-of-00003.gguf` | 43,836,407,744 | `d4634e6d84f0ebb0940be15c90d3790bf6464e3dea3a1cddc567dc0e83ad8833` |Setup treats it like UD-Q4_K_XL (the list above): the same RAM budget (your RAM less 24 GB; at most all 55 GiB of its-experts, so a 96 GB PC holds all of them), the pack with `--compat-bf16`, no `experts.bin`, one GPU by default, no-images. It does not ask on AMD: its experts' formats have prompt kernels there too.+experts, so a PC with ~80 GB of RAM or more holds all of them), the pack with `--compat-bf16`, no `experts.bin`, one+GPU by default. It does not ask on AMD: its experts' formats have prompt kernels there too. Images are an option (asked,+off by default; NVIDIA): the image path has no restriction for this pack, which uses the original model's image+encoder; not yet run with images.What is known so far: it packs and runs on a Strix Halo (AMD gfx1151, 128 GB unified memory), where prompts read at~820 tokens/s at 8K and 64K and the answers passed the retrieval checks at 8K and 64K. It has **not** been measured ondiff --git a/setup.py b/setup.pyindex 96c40d115..d615996f5 100644--- a/setup.py+++ b/setup.py@@ -138,14 +138,17 @@ MODELS = {# keeps a RAM budget of them (--resident-budget-gib, chosen below) and reads the rest from the GGUF on the SSD"UD-Q4_K_XL": {"about": "4-bit (Unsloth Dynamic), EXPERIMENTAL: the best quality, but most experts come from the ""SSD on a 64 GB PC (7-8.5 tokens/s measured)", "download_gb": 111.3, "ram_gb": 48,- "arena_gb": 77.0, "families": ("unsloth",), "budget": True, "nvidia_only": True},- # #621 EXPERIMENTAL: Unsloth's UD-IQ4_XS - IQ3_S gate/up experts with IQ4_NL (43 layers) or Q8_0 (5) downs, the- # dense side as UD-Q4_K_XL's; three shards. Packed and run on a Strix Halo (AMD); not measured on NVIDIA yet. Its- # 59.5 GB of experts: a RAM budget of them, like UD-Q4_K_XL, but far fewer read from the SSD on a 64 GB PC- "UD-IQ4_XS": {"about": "~4-bit i-quant (Unsloth Dynamic), EXPERIMENTAL: between IQ3_S and UD-Q4_K_XL; part of "- "its experts come from the SSD on a 64 GB PC (not measured on NVIDIA yet)",+ "arena_gb": 77.0, "families": ("unsloth",), "budget": True, "nvidia_only": True,+ "experimental": True},+ # #621: Unsloth's UD-IQ4_XS - IQ3_S gate/up experts with IQ4_NL (43 layers) or Q8_0 (5) downs, the dense side as+ # UD-Q4_K_XL's; three shards. A regular choice from 0.1.39 (no longer experimental). Its 59.5 GB of experts: a+ # RAM budget of them, like UD-Q4_K_XL, but far fewer read from the SSD on a 64 GB PC and none from ~80 GB of RAM.+ # Images: the vision path has no restriction for this pack (the same base model and image encoder), so setup asks+ "UD-IQ4_XS": {"about": "~4-bit i-quant (Unsloth Dynamic), between IQ3_S and UD-Q4_K_XL in quality; on a PC with "+ "less than ~80 GB of RAM part of its experts are read from the SSD","download_gb": 93.7, "ram_gb": 48, "arena_gb": 59.5, "families": ("unsloth",), "budget": True,- "shards": 3, "file": "Qwen3.8-Flash-Next-{q}-0000{i}-of-00003.gguf", "engine": (0, 1, 38)},+ "shards": 3, "file": "Qwen3.8-Flash-Next-{q}-0000{i}-of-00003.gguf", "engine": (0, 1, 38),+ "vision": True},}# The experimental Unsloth file's four shards at the pinned revision: name -> (bytes, sha256), checked after the# download (setup trusts no other model file by name and size alone either: check_shards reads their directories).@@ -200,16 +203,16 @@ FAMILIES = {"mmproj_hf": hf("ISTA-DASLab/Qwen3.8-Flash-Next-GSQ-RCO-Coder-GGUF"),"mmproj": "mmproj-Qwen3.8-Flash-Next-BF16.gguf", "name": "qwen3.8-flash-next-coder","profile": "expert-profile-coder.bin"},- # EXPERIMENTAL: Unsloth's UD-Q4_K_XL (four shards) and UD-IQ4_XS (three, #621) of the original model- # (docs/UNSLOTH_Q4.md); no images yet- "unsloth": {"title": "Qwen3.8-Flash-Next (Unsloth)", "by": "Unsloth's 4-bit quantizations (EXPERIMENTAL)",- "about": "UD-Q4_K_XL (111 GB download) or UD-IQ4_XS (94 GB); part of the experts read from the SSD: "- "slower (UD-Q4_K_XL: 7-8.5 tokens/s on a 64 GB PC)",+ # Unsloth's UD-IQ4_XS (three shards, #621; a regular choice from 0.1.39) and the EXPERIMENTAL UD-Q4_K_XL (four)+ # of the original model (docs/UNSLOTH_Q4.md); "experimental" and "vision" are per model (MODELS)+ "unsloth": {"title": "Qwen3.8-Flash-Next (Unsloth)", "by": "Unsloth's ~4-bit quantizations",+ "about": "UD-IQ4_XS: a 94 GB download; with less than ~80 GB of RAM part of its experts are read from "+ "the SSD (UD-Q4_K_XL, 111 GB: experimental)","hf": hf("unsloth/Qwen3.8-Flash-Next-GGUF") + "{q}/","file": "Qwen3.8-Flash-Next-{q}-0000{i}-of-00004.gguf", "shards": 4, "tag": "unsloth-","mmproj_hf": hf("ISTA-DASLab/Qwen3.8-Flash-Next-GSQ-RCO-GGUF"),"mmproj": "mmproj-Qwen3.8-Flash-Next-BF16.gguf", "name": "qwen3.8-flash-next-unsloth",- "experimental": True, "vision": False, "pack_args": ["--compat-bf16"],+ "vision": False, "pack_args": ["--compat-bf16"],"sha256": {**UNSLOTH_SHARDS, **UNSLOTH_IQ4_XS_SHARDS}},}MMPROJ = "mmproj-Qwen3.8-Flash-Next-BF16.gguf"@@ -3836,7 +3839,8 @@ def main() -> int:for m, d in MODELS.items():verdict = "fits" if ram >= d["ram_gb"] else "tight" if ram >= d["ram_gb"] - 8 else "does not fit"if d.get("budget"):- verdict = (f"EXPERIMENTAL, fits with {resident_budget_gib(m, ram)} GiB of its experts in RAM, the rest "+ verdict = (("EXPERIMENTAL, " if d.get("experimental") else "") ++ f"fits with {resident_budget_gib(m, ram)} GiB of its experts in RAM, the rest ""read from the SSD" if ram >= d["ram_gb"] else "does not fit")if hip: # #429: not run on AMD yet (its prompt kernels are CUDA-only)verdict += " - NVIDIA only so far, untested on AMD"@@ -3864,6 +3868,7 @@ def main() -> int:say(f" Its license: {fam['license']}")say()names = [m for m in MODELS if family in MODELS[m].get("families", ("qwen", "swift"))]+ names.sort(key=lambda m: bool(MODELS[m].get("experimental"))) # an experimental size last, never the defaultif a.model and a.model not in names:# #444: say which family has that size, and (with --gguf-dir) which files Strata can run at allelsewhere_fams = [f for f in FAMILIES if f in MODELS[a.model].get("families", ("qwen", "swift"))]@@ -3889,8 +3894,9 @@ def main() -> int:# Unsloth's UD-Q4_K_XL: a RAM budget of experts, the rest from the GGUF on the SSD - not the low-RAM mode (no# experts.bin: it would be another 77 GB on the disk), and one GPU (the budget mode has no layer split) unless# the RAM holds the GGUFs and 24 GB more: then several, without the budget, if asked for (#498)- warn(f"{model} is EXPERIMENTAL (docs/UNSLOTH_Q4.md): most of its experts are read from the SSD while it "- "answers, so it is several times slower than the 2-3-bit models; quality checked against llama.cpp")+ if MODELS[model].get("experimental"):+ warn(f"{model} is EXPERIMENTAL (docs/UNSLOTH_Q4.md): most of its experts are read from the SSD while it "+ "answers, so it is several times slower than the 2-3-bit models; quality checked against llama.cpp")if hip and MODELS[model].get("nvidia_only"):# #429 (jkuepker): checked before the 111 GB download. The HIP engine has no prompt kernels for its# Q4_K / Q5_K experts (STRATA_MMQ_KQUANTS is CUDA-only) and it has not been run on AMD: asked, not refused@@ -3986,7 +3992,7 @@ def main() -> int:kv = ["int8", "q4_0"][int(ask("KV cache?", ["1", "2"], "1", a.yes)) - 1]if ctx > 8192:ok(f"KV cache: {'8-bit' if kv == 'int8' else '4-bit (Hadamard-rotated)'}")- if fam.get("vision") is False:+ if MODELS[model].get("vision", fam.get("vision")) is False: # UD-IQ4_XS: images, unlike UD-Q4_K_XLvision = "none"if a.vision not in (None, "no", "none"):warn(f"images are not available with {model} yet: off")@@ -4147,7 +4153,7 @@ def main() -> int:passdownload(fam["hf"].format(q=model) + s.name, s)check_shards(shards)- for s in shards: # the experimental Unsloth file: pinned sizes and SHA-256+ for s in shards: # the Unsloth files: pinned sizes and SHA-256if s.name in fam.get("sha256", {}):verify_sha256(s, *fam["sha256"][s.name])ok("model files present")diff --git a/tools/strata_mcp.py b/tools/strata_mcp.pyindex bfbb7b416..6857715ae 100644--- a/tools/strata_mcp.py+++ b/tools/strata_mcp.py@@ -61,10 +61,11 @@ FALLBACK_MODELS = {"ram_gb": 32, "arena_gb": 23.4, "families": ("coder",)},"UD-Q4_K_XL": {"about": "4-bit (Unsloth Dynamic), EXPERIMENTAL: the best quality, but most experts come from the ""SSD on a 64 GB PC (7-8.5 tokens/s measured)", "download_gb": 111.3, "ram_gb": 48,- "arena_gb": 77.0, "families": ("unsloth",), "budget": True},- "UD-IQ4_XS": {"about": "~4-bit i-quant (Unsloth Dynamic), EXPERIMENTAL: between IQ3_S and UD-Q4_K_XL; part of "- "its experts come from the SSD on a 64 GB PC (not measured on NVIDIA yet)",- "download_gb": 93.7, "ram_gb": 48, "arena_gb": 59.5, "families": ("unsloth",), "budget": True},+ "arena_gb": 77.0, "families": ("unsloth",), "budget": True, "experimental": True},+ "UD-IQ4_XS": {"about": "~4-bit i-quant (Unsloth Dynamic), between IQ3_S and UD-Q4_K_XL in quality; on a PC with "+ "less than ~80 GB of RAM part of its experts are read from the SSD",+ "download_gb": 93.7, "ram_gb": 48, "arena_gb": 59.5, "families": ("unsloth",), "budget": True,+ "vision": True},}FALLBACK_FAMILIES = {"qwen": {"title": "Qwen3.8-Flash-Next", "about": "the original model", "tag": ""},@@ -72,10 +73,10 @@ FALLBACK_FAMILIES = {"authors' numbers)", "tag": "swift-"},"coder": {"title": "Qwen3.8-Flash-Next Coder", "about": "half the experts (code, tools, images kept): needs ~32 GB ""of RAM, faster; weaker outside coding", "tag": "coder-"},- "unsloth": {"title": "Qwen3.8-Flash-Next (Unsloth)", "about": "UD-Q4_K_XL (111 GB download) or UD-IQ4_XS (94 GB); "- "part of the experts read from the SSD: slower "- "(UD-Q4_K_XL: 7-8.5 tokens/s on a 64 GB PC)",- "tag": "unsloth-", "experimental": True, "vision": False},+ "unsloth": {"title": "Qwen3.8-Flash-Next (Unsloth)", "about": "UD-IQ4_XS: a 94 GB download; with less than ~80 GB "+ "of RAM part of its experts are read from the SSD "+ "(UD-Q4_K_XL, 111 GB: experimental)",+ "tag": "unsloth-", "vision": False},}FALLBACK_CONTEXTS = [8192, 32768, 65536, 131072, 262144, 393216, 524288]BENCH_PROMPT = ("Write a short story (about 300 words) about a lighthouse keeper who finds a message in a bottle. "@@ -426,7 +427,9 @@ class Strata:@staticmethoddef sizes_of(models, family) -> list:- return [m for m in models if family in models[m].get("families", ("qwen", "swift"))]+ """The family's sizes as setup lists them: an experimental one last (never the default)."""+ return sorted((m for m in models if family in models[m].get("families", ("qwen", "swift"))),+ key=lambda m: bool(models[m].get("experimental")))# ---- pathsdef settings_path(self) -> Path:@@ -709,17 +712,21 @@ class Strata:verdict = "fits" if ram >= d["ram_gb"] else "tight" if ram >= d["ram_gb"] - 8 else "does not fit"try:if d.get("budget"):- verdict = ("experimental: part of its experts in RAM, the rest read from the SSD"+ verdict = (("experimental: " if d.get("experimental") else "")+ + "part of its experts in RAM, the rest read from the SSD"if ram >= d["ram_gb"] else "does not fit")elif S and S.low_ram_needed(m, ram) and S.low_ram_fits(m, ram, vram):verdict = "fits in the low-RAM mode (slower: the GPU holds part of the experts)"except Exception: # noqa: BLE001passsizes.append({"model": m, "about": d["about"], "download_gb": d["download_gb"],+ "experimental": bool(d.get("experimental")),+ "images": d.get("vision", fd.get("vision", True)) is not False,"ram_needed_gb": d["ram_gb"], "experts_gb": d.get("arena_gb"),"on_this_pc": verdict, "installed": tag in have, "id": tag})out.append({"family": f, "title": fd["title"], "about": fd.get("about"),- "experimental": bool(fd.get("experimental")), "images": fd.get("vision", True) is not False,+ "experimental": bool(fd.get("experimental")),+ "images": any(x["images"] for x in sizes) if sizes else fd.get("vision", True) is not False,"sizes": sizes})return out@@ -935,7 +942,7 @@ def tool_defs(models: dict, families: dict, contexts: list) -> list:"annotations": ro},{"name": "strata_models", "title": "Strata models","description": "The models and sizes Strata's setup offers (families: qwen = Qwen3.8-Flash-Next, swift = "- "Swift 1.5, coder = the Coder, unsloth = experimental 4-bit), with download size, RAM needed, "+ "Swift 1.5, coder = the Coder, unsloth = Unsloth's ~4-bit), with download size, RAM needed, ""whether each fits this PC, which are installed, the context lengths, and the recommendation. ""Read-only.","inputSchema": {"type": "object", "additionalProperties": False, "properties": {}},@@ -952,7 +959,8 @@ def tool_defs(models: dict, families: dict, contexts: list) -> list:"family": {"type": "string", "enum": list(families),"description": "qwen = Qwen3.8-Flash-Next (the original), swift = Swift 1.5 (thinks ""shorter), coder = the Coder (half the experts, ~32 GB RAM, for code), "- "unsloth = 4-bit EXPERIMENTAL (slow)"},+ "unsloth = Unsloth's ~4-bit (UD-IQ4_XS; UD-Q4_K_XL is "+ "experimental), part of the experts read from the SSD"},"model": {"type": "string", "enum": list(models),"description": "the size (quantization): see strata_models"},"context": {"type": "integer", "enum": contexts,@@ -1224,8 +1232,8 @@ class Tools:context = 32768 if vram < 14 else 65536 if vram < 20 else 131072if models[model].get("budget"):context = 8192 if vram < 14 else 32768- if vision in ("yes", "gpu", "cpu") and families[family].get("vision") is False:- raise ToolError(f"images are not available with {families[family]['title']} yet: use vision=no")+ if vision in ("yes", "gpu", "cpu") and models[model].get("vision", families[family].get("vision")) is False:+ raise ToolError(f"images are not available with {families[family]['title']} {model} yet: use vision=no")if vision is not None and backend == "hip" and vision != "no":raise ToolError("images are not available on the AMD backend yet: use vision=no")target = self.check_data_dir(data_dir) if data_dir else s.data_dir()@@ -1266,7 +1274,7 @@ class Tools:"the options (finished steps are skipped)")if families[family].get("license"):plan["license"] = families[family]["license"]- if families[family].get("experimental"):+ if families[family].get("experimental") or models[model].get("experimental"):plan["experimental"] = Truereturn plan, argsdiff --git a/tools/test_setup_choices.py b/tools/test_setup_choices.pyindex 65a39dbf7..c706a6230 100644--- a/tools/test_setup_choices.py+++ b/tools/test_setup_choices.py@@ -145,7 +145,7 @@ class GgufDirUnsupported(unittest.TestCase):code, out, _, _ = install(ram, found, ["--gguf-dir", d, "--family", "unsloth", "--model", "IQ3_XXS"])self.assertEqual(code, 1)self.assertIn("has no IQ3_XXS model file", out)- self.assertIn("choose one of: UD-Q4_K_XL, UD-IQ4_XS (or IQ3_XXS: --family qwen --model IQ3_XXS, --family swift --model "+ self.assertIn("choose one of: UD-IQ4_XS, UD-Q4_K_XL (or IQ3_XXS: --family qwen --model IQ3_XXS, --family swift --model ""IQ3_XXS)", out)self.assertIn("Strata runs ISTA-DASLab's GSQ-RCO files", out)diff --git a/tools/test_setup_unsloth.py b/tools/test_setup_unsloth.pyindex 895b3ab6b..9b9d271d9 100644--- a/tools/test_setup_unsloth.py+++ b/tools/test_setup_unsloth.py@@ -1,4 +1,5 @@-"""Tests for setup.py's experimental Unsloth UD-Q4_K_XL choice (docs/UNSLOTH_Q4.md): the four pinned shards with+"""Tests for setup.py's Unsloth choices (docs/UNSLOTH_Q4.md): UD-IQ4_XS (regular from 0.1.39) and the experimental+UD-Q4_K_XL: the four pinned shards withtheir sizes and SHA-256, the RAM budget from the PC's RAM, the pack with --compat-bf16 (never experts.bin), theengine version it needs, one GPU, no images. Mocked - no GPU, no downloads, nothing written outside a temp folder.@@ -36,7 +37,8 @@ class Pins(unittest.TestCase):self.assertEqual(fam["hf"].format(q=M),f"https://huggingface.co/unsloth/Qwen3.8-Flash-Next-GGUF/resolve/{REV}/UD-Q4_K_XL/")self.assertEqual(setup.MODELS[M]["families"], ("unsloth",)) # no other family lists it- self.assertTrue(fam["experimental"])+ self.assertTrue(setup.MODELS[M]["experimental"]) # 0.1.39: per model, not the family+ self.assertFalse(fam.get("experimental"))self.assertEqual(list(setup.FAMILIES)[0], "qwen") # not the default choicedef test_not_in_the_other_families(self):@@ -139,7 +141,18 @@ class Base(unittest.TestCase):def tearDown(self):self.tmp.cleanup()- def main(self, argv, ram=63.7, version="0.1.32", n_gpus=1, model=True, amd=(), free=500.0, m=M):+ def main(self, argv, ram=63.7, version="0.1.32", n_gpus=1, model=True, amd=(), free=500.0, m=M, answers=None,+ family=True):+ """answers: None = --yes; else {words of a question: its answer} (Enter for the others), and every question+ asked is kept in self.asked. family=False: no --family (the first menu is shown)."""+ self.asked = []++ def fake_input(prompt=""):+ if answers is None:+ raise AssertionError(f"asked {prompt!r}")+ self.asked.append(prompt)+ return next((v for k, v in answers.items() if k in prompt), "")+eng = self.t / "engine"eng.mkdir(exist_ok=True)(eng / "BUILD.json").write_text(json.dumps({"version": version, "source": "local"}))@@ -180,10 +193,11 @@ class Base(unittest.TestCase):mock.patch.object(setup, "saved_calibration", lambda cfg: None),mock.patch.object(setup, "start", mock.Mock(side_effect=AssertionError("started"))),mock.patch.dict(sys.modules, {"gguf_reader": types.SimpleNamespace(GGUFFile=FakeGGUF)}),- mock.patch.object(sys, "argv", ["setup.py", "--family", "unsloth", *(["--model", m] if model else []),- "--yes", "--no-start",+ mock.patch.object(sys, "argv", ["setup.py", *(["--family", "unsloth"] if family else []),+ *(["--model", m] if model else []),+ *(["--yes"] if answers is None else []), "--no-start","--models-dir", str(self.t / "models"), *argv]),- mock.patch("builtins.input", mock.Mock(side_effect=AssertionError("asked"))),+ mock.patch("builtins.input", fake_input),]with contextlib.ExitStack() as st:for p in patches:@@ -247,7 +261,7 @@ class Main(Base):code, out, cfg = self.main(["--context", "8192"], ram=31.9, model=False) # --yes alone: still a stopself.assertEqual(code, 1)self.assertIn("needs 48 GB of RAM or more", out)- self.assertIn("--model UD-Q4_K_XL --yes", out) # the way to insist+ self.assertIn("--model UD-IQ4_XS --yes", out) # the way to insist (0.1.39: the family's default size)self.assertEqual(self.downloads, [])def test_amd_is_asked_before_the_download(self):@@ -255,7 +269,9 @@ class Main(Base):download, saying why; it is not refused outright (the owner's rule: --model with --yes goes on)."""r9700 = [{"index": 0, "name": "AMD Radeon AI PRO R9700", "vram_gb": 31.9, "arch": "gfx1201","driver": "amdgpu"}]- code, out, cfg = self.main(["--context", "8192", "--backend", "hip"], model=False, amd=r9700)+ # chosen in the menu (2 = UD-Q4_K_XL, after the regular UD-IQ4_XS), not by --model: the answer is no+ code, out, cfg = self.main(["--context", "8192", "--backend", "hip", "--vision", "no"], model=False,+ amd=r9700, answers={"Which size": "2", "Try it anyway": "n"})self.assertEqual(code, 1, out)self.assertIn("has not been run on AMD cards yet", out)self.assertIn("--model UD-Q4_K_XL --yes", out)@@ -366,8 +382,9 @@ X = "UD-IQ4_XS"class IQ4XS(Base):- """#621 (EXPERIMENTAL): Unsloth's UD-IQ4_XS - three pinned shards, the same RAM-budget setup as UD-Q4_K_XL (the- pack with --compat-bf16, never experts.bin, one GPU, no images), engine 0.1.38 or newer, no AMD question."""+ """#621: Unsloth's UD-IQ4_XS, a regular (not experimental) choice from 0.1.39 - three pinned shards, the same+ RAM-budget setup as UD-Q4_K_XL (the pack with --compat-bf16, never experts.bin, one GPU), engine 0.1.38 or newer,+ no AMD question; images are asked like the 2-3-bit models' (off by default)."""def test_pins(self):fam = setup.FAMILIES["unsloth"]@@ -396,7 +413,7 @@ class IQ4XS(Base):def test_install(self):code, out, cfg = self.main(["--context", "8192"], version="0.1.38", m=X)self.assertEqual(code, 0, out)- self.assertIn("EXPERIMENTAL", out)+ self.assertNotIn("is EXPERIMENTAL", out) # (the menu still lists UD-Q4_K_XL)base = f"https://huggingface.co/unsloth/Qwen3.8-Flash-Next-GGUF/resolve/{REV}/UD-IQ4_XS/"self.assertEqual(self.downloads, [base + n for n in setup.UNSLOTH_IQ4_XS_SHARDS])self.assertEqual(self.verified, [(n, *v) for n, v in setup.UNSLOTH_IQ4_XS_SHARDS.items()])@@ -411,12 +428,62 @@ class IQ4XS(Base):for flag in ("--ple-gguf", "--mmap-experts", "--resident-experts", "--vision"):self.assertNotIn(flag, args)self.assertEqual(cfg["model_name"], "qwen3.8-flash-next-unsloth-ud-iq4_xs")+ pack = self.t / "data" / "packs" / "unsloth-ud-iq4_xs" # its own pack and tokenizer+ self.assertEqual(packs[0][packs[0].index("--out") + 1], str(pack))+ self.assertEqual(args[args.index("--pack") + 1], str(pack))+ self.assertEqual(cfg["tokenizer"], str(pack / "tokenizer"))+ self.assertNotIn("vision", cfg) # images: asked, off by defaultwith tempfile.TemporaryDirectory() as t: # a start reads the choice backp = Path(t) / "strata-unsloth-ud-iq4_xs.json"p.write_text(json.dumps(cfg))ch = setup.choices_from_config(p)self.assertEqual((ch["family"], ch["model"]), ("unsloth", X))+ def test_family_default_and_menus(self):+ """The first menu lists the Unsloth family without [experimental]; its size menu puts UD-IQ4_XS first (the+ default, Enter) and UD-Q4_K_XL second, still marked EXPERIMENTAL; --model names are unchanged."""+ code, out, cfg = self.main(["--context", "8192", "--vision", "no"], version="0.1.38", model=False,+ family=False, answers={"Which model": "4"}, m=X)+ self.assertEqual(code, 0, out)+ fam_line = next(ln for ln in out.splitlines() if ln.startswith(" 4) "))+ self.assertIn("Qwen3.8-Flash-Next (Unsloth)", fam_line)+ self.assertIn("UD-IQ4_XS: a 94 GB download", fam_line)+ self.assertNotIn("[experimental]", out)+ size_lines = [ln for ln in out.splitlines() if ln.startswith((" 1) UD-", " 2) UD-"))]+ self.assertEqual(len(size_lines), 2, out)+ self.assertTrue(size_lines[0].startswith(" 1) UD-IQ4_XS ~4-bit"), size_lines[0])+ self.assertNotIn("EXPERIMENTAL", size_lines[0])+ self.assertTrue(size_lines[1].startswith(" 2) UD-Q4_K_XL 4-bit"), size_lines[1])+ self.assertIn("EXPERIMENTAL", size_lines[1])+ self.assertTrue(any("Which size" in q and "[1]" in q for q in self.asked), self.asked)+ self.assertEqual(cfg["model_name"], "qwen3.8-flash-next-unsloth-ud-iq4_xs")+ code, out, cfg = self.main(["--context", "8192"], version="0.1.38", model=False, m=X) # --yes: same default+ self.assertEqual(code, 0, out)+ self.assertEqual(cfg["model_name"], "qwen3.8-flash-next-unsloth-ud-iq4_xs")+ for m, name in ((M, "qwen3.8-flash-next-unsloth-ud-q4_k_xl"), (X, "qwen3.8-flash-next-unsloth-ud-iq4_xs")):+ code, out, cfg = self.main(["--context", "8192"], version="0.1.38", m=m) # --model by name+ self.assertEqual((code, cfg["model_name"]), (0, name), out)++ def test_images(self):+ """Images on: the original model's image encoder (the same base model), the vision flags in the config."""+ code, out, cfg = self.main(["--context", "8192", "--vision", "yes"], version="0.1.38", m=X)+ self.assertEqual(code, 0, out)+ self.assertNotIn("images are not available", out)+ self.assertIn("images: on", out)+ self.assertEqual(self.downloads[-1], setup.hf("ISTA-DASLab/Qwen3.8-Flash-Next-GSQ-RCO-GGUF")+ + "mmproj-Qwen3.8-Flash-Next-BF16.gguf")+ self.assertIn("--vision", cfg["args"])+ self.assertTrue(cfg["vision"]["model"].endswith("UD-IQ4_XS-00001-of-00003.gguf"))+ self.assertIn("--resident-budget-gib", cfg["args"])++ def test_check_verdict(self):+ code, out, _ = self.main(["--check"], m=X)+ self.assertEqual(code, 0, out)+ line = next(ln for ln in out.splitlines() if ln.strip().startswith(X))+ self.assertIn("fits with 40 GiB of its experts in RAM", line)+ self.assertNotIn("EXPERIMENTAL", line)+ self.assertIn("EXPERIMENTAL", next(ln for ln in out.splitlines() if ln.strip().startswith(M)))+def test_engine_0138(self):code, out, cfg = self.main(["--context", "8192"], version="0.1.37", m=X)self.assertEqual(code, 1)diff --git a/tools/test_strata_mcp.py b/tools/test_strata_mcp.pyindex 051380501..bacffb780 100644--- a/tools/test_strata_mcp.py+++ b/tools/test_strata_mcp.py@@ -300,7 +300,8 @@ class Validation(FakeRoot):self.assertRejected("strata_install", {"backend": "rocm"}, "backend must be one of")self.assertRejected("strata_install", {"command": "setup.py --build"}, "unknown argument")self.assertRejected("strata_install", {"family": "swift", "model": "IQ3_S"}, "has no IQ3_S")- self.assertRejected("strata_install", {"family": "unsloth", "vision": "yes"}, "images are not available")+ self.assertRejected("strata_install", {"family": "unsloth", "model": "UD-Q4_K_XL", "vision": "yes"},+ "images are not available")self.assertRejected("strata_install", {"vision": "yes\nrm"}, "control characters")def test_data_dir_paths(self):@@ -545,12 +546,31 @@ class Helpers(unittest.TestCase):for m, d in S.MODELS.items():for k in ("download_gb", "ram_gb", "arena_gb"):self.assertEqual(d[k], M.FALLBACK_MODELS[m][k], f"{m} {k}")+ for k in ("experimental", "vision"):+ self.assertEqual(d.get(k), M.FALLBACK_MODELS[m].get(k), f"{m} {k}")self.assertEqual(d.get("families", ("qwen", "swift")), M.FALLBACK_MODELS[m].get("families", ("qwen", "swift")))self.assertEqual(list(S.FAMILIES), list(M.FALLBACK_FAMILIES))for f, d in S.FAMILIES.items():self.assertEqual(d["tag"], M.FALLBACK_FAMILIES[f]["tag"])self.assertEqual(list(S.CONTEXTS), M.FALLBACK_CONTEXTS)+ def test_unsloth_sizes(self):+ """0.1.39: UD-IQ4_XS is a regular size, listed first (the family's default); UD-Q4_K_XL stays experimental."""+ s = M.Strata(HERE.parent)+ for models in (s.tables()[0], M.FALLBACK_MODELS):+ self.assertEqual(s.sizes_of(models, "unsloth"), ["UD-IQ4_XS", "UD-Q4_K_XL"])+ self.assertFalse(models["UD-IQ4_XS"].get("experimental"))+ self.assertTrue(models["UD-Q4_K_XL"].get("experimental"))+ self.assertEqual(s.sizes_of(M.FALLBACK_MODELS, "qwen"), ["Q2_0", "IQ2_XS", "IQ3_XXS", "IQ3_S"])+ fam = next(f for f in s.model_table({"ram_gb": 63.7, "gpus": []}) if f["family"] == "unsloth")+ self.assertFalse(fam["experimental"])+ self.assertTrue(fam["images"])+ by = {x["model"]: x for x in fam["sizes"]}+ self.assertEqual((by["UD-IQ4_XS"]["experimental"], by["UD-IQ4_XS"]["images"]), (False, True))+ self.assertEqual((by["UD-Q4_K_XL"]["experimental"], by["UD-Q4_K_XL"]["images"]), (True, False))+ self.assertFalse(by["UD-IQ4_XS"]["on_this_pc"].startswith("experimental"))+ self.assertTrue(by["UD-Q4_K_XL"]["on_this_pc"].startswith("experimental"))+def test_recommendation_follows_ram(self):s = M.Strata(HERE.parent)gpu = [{"index": 0, "name": "x", "vram_gb": 24.0, "usable": True, "vendor": "nvidia"}]