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

setup: banner names the chosen family; the user's own home (root's included) is allowed as a data folder; a missing DeepSeek engine package is said plainly (supported cards), the developer hint only with --verbose; tests

Niko122100ce92068aa8
diff --git a/setup.py b/setup.py
index ff3d0c4ed..aaa732c0e 100644
--- a/setup.py
+++ b/setup.py
@@ -7925,9 +7925,11 @@ def install_dsv41(a, family, gpu, hip, amd, cuda_tk, multi, port, ram, adopted,
if exe is not None and exe.parent != Path(eng):
lib_dirs = [*lib_dirs, str(exe.parent)] # its own package carries the libraries it needs
if exe is None:
- fail(f"this engine ({meta.get('version')}) has no DeepSeek-V4.1 engine (strata-dsv41) yet",
- "update Strata, or compile it with cmake -DSTRATA_BUILD_DSV41=ON and point STRATA_DSV41_EXE at it, then run setup again "
- "(nothing has been downloaded)")
+ if os.environ.get("STRATA_VERBOSE") == "1" or "--verbose" in sys.argv:
+ say(" Details for developers: build it with cmake -DSTRATA_BUILD_DSV41=ON and point STRATA_DSV41_EXE at it.")
+ fail("DeepSeek's engine is not available for this computer yet",
+ "Supported graphics cards: NVIDIA RTX 30 and RTX 50 series, and the Radeon AI PRO R9700. Update Strata later (a newer version may add "
+ "your card), or pick another model. Nothing has been downloaded.")
ok(f"engine: {exe}")
step(5, f"downloading {fam['title']} {model}")
@@ -8464,7 +8466,9 @@ def main() -> int:
a.gpus = ",".join(str(i) for i in order)
else:
a.gpu = order[0]
- say("Strata - Qwen3.8-Flash-Next on a normal PC (a GPU + system RAM + CPU)")
+ say("Strata - " + (MULTI_FILE_FAMILIES[a.family]["title"] if a.family in MULTI_FILE_FAMILIES else
+ OWN_PATH_FAMILIES[a.family]["title"] if a.family in OWN_PATH_FAMILIES else "Qwen3.8-Flash-Next")
+ + " on a normal PC (a GPU + system RAM + CPU)")
have = installed_configs()
# A plain start of an installed model finds everything where it already is: it creates, moves and copies nothing
# (the model paths are in the run config; the data folder is the one settings.json remembers). Setting up, checking,
diff --git a/strata_control/folders.py b/strata_control/folders.py
index 940b2ee96..29134a73a 100644
--- a/strata_control/folders.py
+++ b/strata_control/folders.py
@@ -76,7 +76,7 @@ def problem(raw: str | os.PathLike | None) -> tuple[str, str] | None:
if os.name == "nt" else "Type the whole path, starting with /, like /data/strata-models. Nothing was downloaded or changed.")
full = os.path.abspath(path)
for root in _system_roots():
- if _inside(full, root):
+ if _inside(full, root) and not _inside(full, os.path.expanduser("~")): # the running user's own home is theirs (root's /root included)
return (f"{full} is a system folder, and Strata should not keep model files there.", _next())
try:
if path.exists():
diff --git a/tests/terminal/test_folders_home.py b/tests/terminal/test_folders_home.py
new file mode 100644
index 000000000..94cf103db
--- /dev/null
+++ b/tests/terminal/test_folders_home.py
@@ -0,0 +1,34 @@
+"""strata_control/folders.problem: a system folder is refused, except inside the running user's own home (root's /root included)."""
+from __future__ import annotations
+
+import os
+import tempfile
+import unittest
+from pathlib import Path
+from unittest import mock
+
+from strata_control import folders
+
+
+class OwnHome(unittest.TestCase):
+ def test_a_system_folder_is_still_refused(self):
+ root = folders._system_roots()[0]
+ with mock.patch.dict(os.environ, {"HOME": tempfile.gettempdir(), "USERPROFILE": tempfile.gettempdir()}):
+ p = folders.problem(str(Path(root) / "strata-models"))
+ self.assertIsNotNone(p)
+ self.assertIn("system folder", p[0])
+
+ def test_the_users_own_home_is_allowed_even_when_it_is_under_a_system_root(self):
+ with tempfile.TemporaryDirectory() as d:
+ home = Path(d) / "rootlike"
+ home.mkdir()
+ with mock.patch.object(folders, "_system_roots", lambda: [d]), \
+ mock.patch.dict(os.environ, {"HOME": str(home), "USERPROFILE": str(home)}):
+ self.assertIsNone(folders.problem(str(home / "models")))
+ other = Path(d) / "elsewhere"
+ other.mkdir()
+ self.assertIn("system folder", folders.problem(str(other / "models"))[0])
+
+
+if __name__ == "__main__":
+ unittest.main()
diff --git a/tools/test_setup_dsv41.py b/tools/test_setup_dsv41.py
index dc03252ed..add4bf8c1 100644
--- a/tools/test_setup_dsv41.py
+++ b/tools/test_setup_dsv41.py
@@ -213,8 +213,11 @@ class Install(unittest.TestCase):
def test_no_engine_stops_before_the_download(self):
rc, out = self.install(engine=False)
self.assertEqual(rc, 1, out)
- self.assertIn("no DeepSeek-V4.1 engine (strata-dsv41)", out)
- self.assertIn("nothing has been downloaded", out)
+ self.assertIn("DeepSeek's engine is not available for this computer yet", out)
+ self.assertIn("RTX 30", out)
+ self.assertNotIn("cmake", out)
+ self.assertNotIn("STRATA_DSV41_EXE", out)
+ self.assertIn("Nothing has been downloaded", out)
self.assertFalse([c for c in self.calls if c[0] == "get"])
def test_own_files_are_checked_not_downloaded(self):