Skip to content

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++

Mac install plan: no card, KV or RAM-mode options; the context follows unified memory; a Mac too small for the model is refused in plain words

Niko1221ccb33b7c7c1a
diff --git a/tools/strata_mcp.py b/tools/strata_mcp.py
index f4256dcd3..1ed5e25bb 100644
--- a/tools/strata_mcp.py
+++ b/tools/strata_mcp.py
@@ -1537,6 +1537,12 @@ class Tools:
sizes = s.sizes_of(models, family)
if model not in sizes:
raise ToolError(f"{families[family]['title']} has no {model}; its sizes: {', '.join(sizes)}")
+ mac = bool(hw.get("mac"))
+ if mac: # a Mac: no card to pick, no KV choice, no RAM mode: unified memory decides
+ if rec.get("model") is None and model is not None and s.mac() and hw.get("ram_gb", 0) < s.mac().MIN_STREAM_RAM_GB:
+ raise ToolError(f"{model} does not fit this Mac: {rec['why']}")
+ gpu = gpus = kv = low_ram = None
+ context = context or (s.mac().recommend_context(hw.get("ram_gb") or 0) if s.mac() else 32768)
if context is None:
usable = [g for g in hw.get("gpus", []) if g.get("usable")]
vram = max((g["vram_gb"] for g in usable), default=12)
diff --git a/tools/test_strata_mcp.py b/tools/test_strata_mcp.py
index 5ff8f1df7..0ce2afe46 100644
--- a/tools/test_strata_mcp.py
+++ b/tools/test_strata_mcp.py
@@ -668,6 +668,22 @@ class MacCatalog(unittest.TestCase):
s, hw = self.hw(8)
self.assertEqual({x["on_this_pc"] for x in s.model_table(hw)[0]["sizes"]}, {"does not fit"})
+ def test_the_install_plan_on_a_mac_has_no_card_kv_or_ram_options(self):
+ s, hw = self.hw(32)
+ s.hardware = lambda fresh=False: hw
+ s.disk_free = lambda p: 1000.0
+ with tempfile.TemporaryDirectory() as own:
+ plan, args = M.Tools(s).install_plan("qwen", "Q2_0", None, "no", "int8", 0, None, None, "auto", None, None, own)
+ self.assertEqual(plan["context"], 32768)
+ self.assertEqual(args[:9], ["--yes", "--no-start", "--family", "qwen", "--model", "Q2_0", "--context", "32768", "--vision"])
+ for flag in ("--kv", "--gpu", "--gpus", "--low-ram", "--backend"):
+ self.assertNotIn(flag, args)
+ self.assertIn("--gguf-dir", args)
+ with self.assertRaises(M.ToolError):
+ s2, hw2 = self.hw(8)
+ s2.hardware = lambda fresh=False: hw2
+ M.Tools(s2).install_plan(None, None, None, None, None, None, None, None, None, None, None)
+
def test_a_pc_is_unchanged(self):
s = M.Strata(HERE.parent)
r = s.recommend({"ram_gb": 96, "gpus": [{"index": 0, "name": "x", "vram_gb": 24.0, "usable": True, "vendor": "nvidia"}],