Windows Intel: Qwen IQ2_XS and IQ3_S default to fast mode (DFlash2, --spec 6), the same as Linux Arc; plain decode stays an option

Owner decision 2026-12-03 09:05.  drafting.INTEL_PLAIN_BY_DEFAULT is False (it was True: plain decode by default on Windows Intel, the mode QFN-B70 gated; with DFlash2 the
B70 gives IQ3_S 60 tok/s against 31 plain and 32K runs with no OOM, QFN-B70's pre-freeze check).  Auto drafting is the engine's own rule on those packs again; the Terminal's
safety net and the drafter plan follow it.  The plain decode stays available: the Windows Intel install writes `--suffix-draft 0` (a 2-token window, no draft proposed) when the
person chose drafting Off or the constant is True (adopt.plan); the machinery behind INTEL_PLAIN_BY_DEFAULT / INTEL_PLAIN_PLATFORMS is unchanged.  Coder IQ1_M is unchanged
(--spec 2 with the suffix drafter, gated).

IQ2_XS / IQ3_S with the drafter keep a lot of host RAM busy (QFN-B70, 32 GB box: free RAM down to 10.6 GiB for IQ2_XS, 6.2 GiB for IQ3_S, commit 44 GiB), so setup's Intel install
now warns (does not refuse) on a PC under 32 GB (INTEL_FAST_MIN_RAM_GB) and says drafting Off is the plain mode.

Tests: the Windows Intel rows of test_qwen_windows_intel.py (fast default, Off, the constant, Linux and the other cards untouched), test_intel_download.py (no --suffix-draft in
the default install, the RAM note), the snapshot suite and the register check pass.
This commit is contained in:
Niko1221 committed 2026-12-03 09:15:57 +01:00
1 parent e40b2167ce
commit f875ea080e
5 files changed
+59 -36

No files matched your search

+6
View File
@@ -9597,6 +9597,7 @@ def _select_sycl_cards(a, cards: list[dict]) -> list[dict]:
return list(cards[:1])
INTEL_FAST_MIN_RAM_GB = 32 # IQ2_XS / IQ3_S with the DFlash2 drafter on an Intel Arc (the default since 2026-12-03): QFN-B70's B70 box with 32 GB: free RAM down to 10.6 GiB (IQ2_XS) and 6.2 GiB (IQ3_S, commit 44 GiB): said, not refused
INTEL_GGUF_MIN_RAM_GB = 24 # an Arc run of a Qwen size keeps about 20 GB of the PC's RAM busy (QFN-B70, the B70 box with 32 GB: 20 GB free at the lowest with IQ3_S): said, not refused
@@ -9674,6 +9675,11 @@ def intel_control_setup(a) -> int:
sel_cards = _select_sycl_cards(a, cards) if cards else []
vram = max((float(c.get("vram_gb") or 0) for c in (sel_cards or cards)), default=0.0)
ok("graphics card: " + (", ".join(f"{c['name']} ({c['vram_gb']:g} GB)" for c in cards) or "an Intel Arc"))
from strata_control import drafting as _drafting
_ram = ram_gb()
if model in ("IQ2_XS", "IQ3_S") and family in ("qwen", "coder") and not _drafting.INTEL_PLAIN_BY_DEFAULT and _ram and _ram < INTEL_FAST_MIN_RAM_GB:
warn(f"this computer has {_ram:.0f} GB of RAM: {model} with the fast drafter (DFlash2) on an Intel Arc needs about {INTEL_FAST_MIN_RAM_GB} GB; with less it may run slowly or not start. "
"Choose drafting Off for the plain mode, which needs less.")
if a.check:
return 0
SHAPE_ENGINE.clear()
+3 -2
View File
@@ -317,8 +317,9 @@ def plan(*, family: str, model: str, model_dir: Path, data_dir: Path, src: Path,
return None, [f"the expert profile {prof} is missing"]
from strata_control import intel_app
args += ["--expert-profile", str(prof), "--expert-cache", "auto", "--prefill", "4096", "--spec", "2"]
if not intel_app.QWEN_SYCL_WINDOWS_PACKS.get(str(model), True): # IQ2_XS / IQ3_S: plain decode (a 2-token window with the suffix drafter off; the engine needs T >= 2 for a native pack)
args += ["--suffix-draft", "0"]
from strata_control import drafting as _drafting
if not intel_app.QWEN_SYCL_WINDOWS_PACKS.get(str(model), True) and (_drafting.INTEL_PLAIN_BY_DEFAULT or _drafting.normalize(drafting) == "off"):
args += ["--suffix-draft", "0"] # IQ2_XS / IQ3_S: plain decode (a 2-token window with the suffix drafter off; the engine needs T >= 2 for a native pack), when it is the default or Off was chosen
else:
args += ["--expert-profile", str(profile), "--expert-cache", "auto", "--prefill", "auto", "--spec", "4", "--spec-min-p", "0.5"]
if mtp.exists() and not feed and not win_sycl: # the Flash-Next draft layer is not a feed model's own (a feed entry carries no MTP head yet)
+5 -3
View File
@@ -1547,10 +1547,12 @@ def canonical_pack(args: list[Any] | None = None) -> bool:
return False
#: Intel Arc (the SYCL engine), Qwen3.8-Flash-Next IQ2_XS and IQ3_S: Auto is NO drafter, the plain decode QFN-B70 gated on the B70. With DFlash2 (Auto's pick wherever the engine has it) the Windows run starts with
#: Owner decision 2026-12-03 09:05: Qwen IQ2_XS and IQ3_S on an Intel Arc on Windows default to FAST mode (DFlash2, --spec 6), the same as Linux Arc, so this is False; plain decode stays available (below).
#: Intel Arc (the SYCL engine), Qwen3.8-Flash-Next IQ2_XS and IQ3_S: True = Auto is NO drafter, the plain decode QFN-B70 gated on the B70. With DFlash2 (Auto's pick wherever the engine has it) the Windows run starts with
#: `--spec 6` and the drafter (decode 77-114 tok/s, about twice plain, acceptance 90 %), which was not gated: speculation with this pack is not bit-equal to plain decode (near-tie flips from token 56 to 185 with spec 2).
#: ONE switch: set False and Auto is DFlash2 on Intel again if the owner chooses speed over exact answers (the person can name a drafter in Settings either way).
INTEL_PLAIN_BY_DEFAULT = True
#: ONE switch: False (now) = Auto is DFlash2 on Intel (speed); True = plain decode by default (exact). The person can name a drafter or Off in Settings either way: with Off a Windows Intel IQ2_XS / IQ3_S install is written
#: with `--suffix-draft 0` (strata_cli/launch/adopt.py), which is the plain decode (a 2-token window, no draft proposed).
INTEL_PLAIN_BY_DEFAULT = False
#: The platforms it applies to (sys.platform prefixes). Windows only for now: that is where the B70 gate measured it and where the app's Load put DFlash2 on without a gate. Linux Arc keeps its tuned
#: DFlash2 default for IQ3_S (CLASS_DEFAULTS, tests/terminal/test_drafting_tuned.py); add "linux" here, and update those tests, if the owner wants the plain decode there too.
INTEL_PLAIN_PLATFORMS = ("win",)
+15 -1
View File
@@ -141,7 +141,8 @@ class ArcInstall(unittest.TestCase):
self.assertEqual(self.packed, str(data / "packs" / "iq2_xs"))
cfg = json.loads((home / "strata-iq2_xs.json").read_text(encoding="utf-8"))
a = cfg["args"]
self.assertEqual((cfg["backend"], a[a.index("--spec") + 1], a[a.index("--suffix-draft") + 1]), ("sycl", "2", "0")) # IQ2_XS on Windows: plain decode
self.assertEqual((cfg["backend"], a[a.index("--spec") + 1]), ("sycl", "2"))
self.assertNotIn("--suffix-draft", a) # IQ2_XS on Windows: fast mode by default (owner, 2026-12-03): the drafting rule adds DFlash2 at Load, nothing forces plain
def test_a_pack_that_is_not_gated_on_windows_keeps_the_block_with_its_words(self):
with tempfile.TemporaryDirectory() as t:
@@ -176,6 +177,19 @@ class ArcInstall(unittest.TestCase):
self.run_setup(self.args(), data, home, ram=16.0)
self.assertTrue(any(m.startswith("WARN") and "16 GB of RAM" in m for m in self.said), self.said)
def test_the_fast_drafter_ram_note(self):
with tempfile.TemporaryDirectory() as t:
t = Path(t)
data, home = t / "Strata-data", t / "install"
data.mkdir()
home.mkdir()
self.run_setup(self.args(model="IQ3_S"), data, home, ram=16.0)
self.assertTrue(any(m.startswith("WARN") and "32 GB" in m and "DFlash2" in m for m in self.said), self.said)
self.run_setup(self.args(model="IQ3_S"), data, home, ram=64.0)
self.assertFalse(any("DFlash2" in m for m in self.said), self.said)
self.run_setup(self.args(model="IQ2_XS", family="qwen"), data, home, ram=64.0)
self.assertFalse(any("32 GB" in m for m in self.said), self.said)
def test_files_that_are_there_download_nothing(self):
with tempfile.TemporaryDirectory() as t:
t = Path(t)
@@ -40,11 +40,11 @@ class Tree:
for i in (1, 2):
(self.models / f"Qwen3.8-Flash-Next-GSQ-RCO-{pack_name.split('-')[-1].upper()}-0000{i}-of-00002.gguf").write_bytes(b"x")
def plan(self, model: str, platform: str, context: int = 32768, vram_gb: float = 32.0):
def plan(self, model: str, platform: str, context: int = 32768, vram_gb: float = 32.0, drafting=None):
fam = setup.FAMILIES[self.family]
return adopt.plan(family=self.family, model=model, model_dir=self.models, data_dir=self.data, src=self.src, context=context, kv="int8",
model_name=f"{fam.get('name', self.family)}-{model.lower()}", family_def=fam, log=self.root / "x.log", backend="sycl",
pack_name=self.pack.name, vram_gb=vram_gb, platform=platform)
pack_name=self.pack.name, vram_gb=vram_gb, platform=platform, drafting=drafting)
def value(args, flag):
@@ -81,7 +81,14 @@ class WindowsFlags(unittest.TestCase):
a = cfg["args"]
self.assertEqual(value(a, "--vram-reserve-mib"), "2048")
self.assertEqual(value(a, "--expert-profile"), str(t.src / "data" / "expert-profile-sycl.bin"))
self.assertEqual((value(a, "--spec"), value(a, "--prefill"), value(a, "--suffix-draft")), ("2", "4096", "0")) # IQ2_XS: plain decode (a 2-token window, the suffix drafter off: spec 2 with it is not bit-equal to plain decode here)
self.assertEqual((value(a, "--spec"), value(a, "--prefill")), ("2", "4096"))
self.assertNotIn("--suffix-draft", a) # IQ2_XS: fast mode by default (DFlash2 at Load, owner 2026-12-03); plain decode is the Off choice or the constant
cfg2, _p = t.plan("IQ2_XS", "win32", context=65536, drafting="off")
self.assertEqual(value(cfg2["args"], "--suffix-draft"), "0") # Off: the plain decode (a 2-token window, no draft proposed)
from strata_control import drafting
with mock.patch.object(drafting, "INTEL_PLAIN_BY_DEFAULT", True):
cfg3, _p = t.plan("IQ2_XS", "win32", context=65536)
self.assertEqual(value(cfg3["args"], "--suffix-draft"), "0") # the constant: plain by default again
self.assertNotIn("--spec-min-p", a)
def test_linux_keeps_its_flags(self):
@@ -113,8 +120,8 @@ class WindowsRoute(unittest.TestCase):
class PlainDecodeOnIntel(unittest.TestCase):
"""IQ2_XS and IQ3_S on the SYCL engine on Windows: Auto drafting is NO drafter (the plain decode QFN-B70 gated), in the app's Load and in the Terminal; one constant (drafting.INTEL_PLAIN_BY_DEFAULT) turns
DFlash2 back on, another (INTEL_PLAIN_PLATFORMS) adds Linux."""
"""IQ2_XS and IQ3_S on the SYCL engine on Windows: fast mode (DFlash2) by default since the owner's decision of 2026-12-03 (drafting.INTEL_PLAIN_BY_DEFAULT = False), like Linux Arc. The plain-decode machinery stays behind
the constant (Auto = no drafter on a platform of INTEL_PLAIN_PLATFORMS), and Off is the plain decode in the install's flags."""
NAMES = ("qwen3.8-flash-next-iq2_xs", "qwen3.8-flash-next-iq3_s")
@@ -124,43 +131,36 @@ class PlainDecodeOnIntel(unittest.TestCase):
p.start()
self.addCleanup(p.stop)
def test_auto_means_no_drafter_for_the_two_packs_on_sycl_only(self):
def test_the_default_is_fast_mode_on_windows_intel(self):
from strata_control import drafting
self.assertFalse(drafting.INTEL_PLAIN_BY_DEFAULT)
for name in self.NAMES:
self.assertTrue(drafting.intel_plain("sycl", name), name)
self.assertEqual(drafting.choice_of("auto", model_name=name, backend="sycl"), "off")
self.assertFalse(drafting.intel_plain("sycl", name), name)
d = drafting.decide("auto", model_name=name, backend="sycl", data_dir=None, mtp_here=False)
self.assertEqual((d.drafter, d.note, d.flags), ("off", "", ())) # no drafter, nothing to say, no --spec 6
self.assertFalse(drafting.wants_one_request("auto", model_name=name, backend="sycl")) # no "one request at a time"
self.assertFalse(drafting.needs_pack("auto", model_name=name, backend="sycl", data_dir="x")) # nothing is fetched for it
self.assertFalse(drafting.needs_mtp("auto", model_name=name, backend="sycl", mtp_here=False))
for backend in ("cuda", "hip", "metal", None):
self.assertFalse(drafting.intel_plain(backend, name), (backend, name)) # NVIDIA, AMD and Apple are untouched
for name in ("qwen3.8-flash-next-q2_0", "qwen3.8-flash-next-iq3_xxs", "qwen3.8-flash-next-coder-iq1_m", "qwen3.8-flash-next-unsloth-iq3_s", "swift-iq3_s", None):
self.assertFalse(drafting.intel_plain("sycl", name), name) # the other packs and families keep their rule
self.assertEqual(d.drafter, drafting.decide("auto", model_name=name, backend="sycl", data_dir=None, mtp_here=False).drafter)
self.assertNotEqual(drafting.choice_of("auto", model_name=name, backend="sycl"), "off") # the engine's own Auto rule: DFlash2 where it runs, else the MTP
def test_linux_keeps_its_rule_until_the_owner_says_otherwise(self):
def test_the_constant_brings_plain_back_and_leaves_the_other_cards_alone(self):
from strata_control import drafting
with mock.patch.object(drafting, "_host_platform", lambda: "linux"):
with mock.patch.object(drafting, "INTEL_PLAIN_BY_DEFAULT", True):
for name in self.NAMES:
self.assertFalse(drafting.intel_plain("sycl", name))
self.assertNotEqual(drafting.choice_of("auto", model_name=name, backend="sycl"), "off")
with mock.patch.object(drafting, "INTEL_PLAIN_PLATFORMS", ("win", "linux")), mock.patch.object(drafting, "_host_platform", lambda: "linux"):
self.assertTrue(drafting.intel_plain("sycl", self.NAMES[0])) # one word adds it
self.assertTrue(drafting.intel_plain("sycl", name), name)
self.assertEqual(drafting.choice_of("auto", model_name=name, backend="sycl"), "off")
d = drafting.decide("auto", model_name=name, backend="sycl", data_dir=None, mtp_here=False)
self.assertEqual((d.drafter, d.note, d.flags), ("off", "", ()))
for backend in ("cuda", "hip", "metal", None):
self.assertFalse(drafting.intel_plain(backend, name), (backend, name))
for name in ("qwen3.8-flash-next-q2_0", "qwen3.8-flash-next-coder-iq1_m", "swift-iq3_s", None):
self.assertFalse(drafting.intel_plain("sycl", name), name)
with mock.patch.object(drafting, "_host_platform", lambda: "linux"):
self.assertFalse(drafting.intel_plain("sycl", self.NAMES[0])) # platforms: Windows only
def test_a_named_drafter_and_off_are_the_persons_own(self):
from strata_control import drafting
name = self.NAMES[0]
self.assertEqual(drafting.choice_of("mtp", model_name=name, backend="sycl"), "mtp")
self.assertEqual(drafting.choice_of("off", model_name=name, backend="sycl"), "off")
self.assertEqual(drafting.choice_of("dflash2", model_name=name, backend="sycl"), "dflash2") # asked for by name: the person's choice (the engine may still refuse it)
def test_one_constant_turns_dflash2_back_on(self):
from strata_control import drafting
with mock.patch.object(drafting, "INTEL_PLAIN_BY_DEFAULT", False):
for name in self.NAMES:
self.assertFalse(drafting.intel_plain("sycl", name))
self.assertNotEqual(drafting.choice_of("auto", model_name=name, backend="sycl"), "off") # back to the engine's own Auto rule (DFlash2 where it runs, else the MTP)
self.assertEqual(drafting.choice_of("dflash2", model_name=name, backend="sycl"), "dflash2")
if __name__ == "__main__":