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++
launch: on a Mac, use prepared model files with the Metal defaults (the Terminal has no Mac model installer)
Niko122108297223e4c7
diff --git a/strata_cli/launch/adopt.py b/strata_cli/launch/adopt.pyindex 76a8257ef..0960f0a02 100644--- a/strata_cli/launch/adopt.py+++ b/strata_cli/launch/adopt.py@@ -21,7 +21,8 @@ UNSUPPORTED = ("no nvidia gpu found", "no amd gpu", "nvidia gpu", "not supporteddef setup_cannot_handle_this_card(message: str) -> bool:low = (message or "").lower()- return "no nvidia gpu found" in low or "no amd gpu strata can use" in low or "nvidia-smi did not answer" in low+ return ("no nvidia gpu found" in low or "no amd gpu strata can use" in low or "nvidia-smi did not answer" in low+ or "no mac model installer" in low)def find_shards(folder: Path) -> list[Path]:@@ -61,12 +62,19 @@ def plan(*, family: str, model: str, model_dir: Path, data_dir: Path, src: Path,args = ["--pack", str(pack), "--native", str(shards[0])]if len(shards) > 1:args += ["--ple-gguf", str(shards[-1])]- args += ["--expert-profile", str(profile), "--expert-cache", "auto", "--prefill", "auto", "--spec", "4", "--spec-min-p", "0.5"]- if mtp.exists():- args += ["--mtp", str(mtp)]- args += ["--max-context", str(context), "--kv", kv or ("int8" if context > 8192 else "fp16")]+ if backend == "metal":+ # a Mac: the Metal defaults metal/setup_mac.py writes for a model that streams from the SSD (one token per step, no draft layer, the GGUF mapped in place)+ args += ["--expert-profile", str(profile), "--expert-cache", "64", "--prefill", "auto", "--spec", "2", "--suffix-draft", "0",+ "--max-context", str(context), "--mmap-experts"]+ else:+ args += ["--expert-profile", str(profile), "--expert-cache", "auto", "--prefill", "auto", "--spec", "4", "--spec-min-p", "0.5"]+ if mtp.exists():+ args += ["--mtp", str(mtp)]+ args += ["--max-context", str(context), "--kv", kv or ("int8" if context > 8192 else "fp16")]cfg = {"exe": "component:strata-engine", "args": args, "cwd": str(src), "tokenizer": str(tokenizer), "model_name": model_name,"log": str(log), "lib_dirs": [], "port": 8080}+ if backend == "metal":+ cfg["env"] = {"STRATA_METAL_STREAM": "1"}if backend:cfg["backend"] = backendreturn cfg, []diff --git a/strata_cli/launch/runner.py b/strata_cli/launch/runner.pyindex 6b172cdee..428c031eb 100644--- a/strata_cli/launch/runner.py+++ b/strata_cli/launch/runner.py@@ -369,6 +369,11 @@ class Runner:self.emit("model", f"{s.family} {s.model} is already installed with these choices.", 100)return pathtitle = f"{s.family} {s.model}"+ if sys.platform == "darwin" and not (cat.src / "metal" / "setup_mac.py").is_file():+ # this Terminal does not carry the Mac installer (it builds the engine from source): use model files prepared on this Mac+ adopted = self.adopt_prepared_files("no Mac model installer in this Terminal")+ if adopted is not None:+ return adoptedself.emit("model", f"Getting {title} ready (a download may be large; it continues where it stopped if interrupted)…", 0)argv = [self.python, str(cat.src / "setup.py"), *self.setup_args()]env = self._env()