Skip to content

Local UI to run and train LLMs and diffusion models. Supports GGUF, MLX, Qwen3.8, DeepSeek-V4.1, MiniMax-H3, Gemma 4, FLUX and more.

Repair four checks that went red on main with the decision-model merges (#12954)

Daniel Hand801c8467160
diff --git a/scripts/risky_loaders_baseline.json b/scripts/risky_loaders_baseline.json
index 1795904d690..a3af6c47a53 100644
--- a/scripts/risky_loaders_baseline.json
+++ b/scripts/risky_loaders_baseline.json
@@ -258,6 +258,14 @@
"count": 1,
"reason": "Loads the vendored laya package shipped inside Studio (_VENDORED_LAYA)."
},
+ {
+ "file": "studio/backend/core/systemone/native_worker.py",
+ "rule": "dynamic-import",
+ "sink": "spec_from_file_location",
+ "digest": "33b35eda3d46f307",
+ "count": 1,
+ "reason": "Loads the vendored Clef reference (unsloth/_vendor/clef/joint_schema_model.py) from the installed unsloth package or the repo checkout, located via find_spec; a fixed file name, never caller input."
+ },
{
"file": "studio/backend/core/training/account_jobs.py",
"rule": "dynamic-import",
@@ -546,6 +554,14 @@
"count": 1,
"reason": "Imports the laya copy vendored in this repository at a fixed path (studio/backend/vendor/laya/__init__.py); never a downloaded or user-supplied file."
},
+ {
+ "file": "unsloth/models/decision_gguf.py",
+ "rule": "dynamic-import",
+ "sink": "spec_from_file_location",
+ "digest": "6894b59960c95a35",
+ "count": 1,
+ "reason": "Loads Studio's standard-library gguf_export_contract.py from a constant path beside the unsloth package; nothing caller-supplied picks the file."
+ },
{
"file": "unsloth/models/loader.py",
"rule": "dynamic-import",
diff --git a/studio/frontend/src/i18n/locales/he.ts b/studio/frontend/src/i18n/locales/he.ts
index 5be15ff85f4..84a0d795170 100644
--- a/studio/frontend/src/i18n/locales/he.ts
+++ b/studio/frontend/src/i18n/locales/he.ts
@@ -2917,6 +2917,14 @@ export const he = {
"GPU עונה מהר יותר, אך שומר את הזיכרון שלו שמור עד להפעלה מחדש.",
deviceCpu: "CPU",
deviceGpu: "GPU",
+ backend: "סביבת ריצה",
+ backendAuto: "אוטומטי",
+ backendDescription:
+ "במצב אוטומטי Clef מוגש דרך llama.cpp כשלמודל יש גרסת GGUF, ואחרת דרך PyTorch. llama.cpp קורא גם תמונות.",
+ backendStatus: "סביבת ריצה: {backend}",
+ backendNone: "לא זמין",
+ mediaImages: "קורא טקסט ותמונות.",
+ mediaText: "קורא טקסט בלבד.",
checking: "בודק…",
notDownloaded: "לא הורד · {size}",
downloading: "מוריד…",
@@ -3054,6 +3062,11 @@ export const he = {
methodLabel: "שיטה",
methodTooltip:
"האופן שבו המודל מאומן. LoRA ו-QLoRA מעדכנים מתאמים (Adapters) קטנים במקום את כל המשקולות.",
+ trainAsLabel: "אימון בתור",
+ trainAsTooltip:
+ "מודל שפה כותב טקסט. מודל החלטות בוחר אחת מהאפשרויות שנתת לו, עם הסתברות, ופועל ב-Decision API.",
+ trainAsLanguage: "מודל שפה",
+ trainAsDecision: "מודל החלטות",
datasetLabel: "מערך נתונים",
datasetTooltip: "נתוני האימון המשמשים לכוונון עדין של המודל.",
hfTokenDescription: "נדרש עבור מודלים ומערכי נתונים פרטיים או מוגבלים.",
@@ -4206,6 +4219,18 @@ export const he = {
openFileFailed: "לא ניתן לפתוח את הקובץ",
},
},
+ exportDecision: {
+ title: "מודל החלטות",
+ description:
+ "מודלי החלטות מסוג {layout} מיוצאים ל-GGUF עבור שרת ההחלטות של llama.cpp. בחר קוונטיזציה אחת או יותר.",
+ adapterNote: "נקודת ביקורת זו מכילה מתאמי LoRA; הם ממוזגים לפני ההמרה.",
+ notEligibleTitle: "ייצוא GGUF אינו זמין",
+ ggufOnly: "מודלי החלטות מיוצאים ל-GGUF בלבד",
+ existing: "כבר יוצא: {quantizations}",
+ outputNote: "קובצי GGUF נשמרים בתיקיית ההרצה: {path}",
+ methodLabel: "GGUF של מודל החלטות",
+ outputLabel: "GGUF החלטות ({quantizations})",
+ },
decisions: {
title: "נסו החלטה",
description: "שאלו את Laya שאלה על כל טקסט.",
diff --git a/studio/frontend/src/i18n/locales/sv.ts b/studio/frontend/src/i18n/locales/sv.ts
index fd21b9bc853..a062575a410 100644
--- a/studio/frontend/src/i18n/locales/sv.ts
+++ b/studio/frontend/src/i18n/locales/sv.ts
@@ -3017,6 +3017,14 @@ export const sv = {
"GPU svarar snabbare men håller sitt minne reserverat tills omstart.",
deviceCpu: "CPU",
deviceGpu: "GPU",
+ backend: "Körmiljö",
+ backendAuto: "Automatisk",
+ backendDescription:
+ "Automatisk kör Clef via llama.cpp när modellen har en GGUF-version och faller annars tillbaka på PyTorch. llama.cpp läser också bilder.",
+ backendStatus: "Körmiljö: {backend}",
+ backendNone: "inte tillgänglig",
+ mediaImages: "Läser text och bilder.",
+ mediaText: "Läser bara text.",
checking: "Kontrollerar …",
notDownloaded: "Inte hämtad · {size}",
downloading: "Hämtar …",
@@ -3159,6 +3167,11 @@ export const sv = {
methodLabel: "Metod",
methodTooltip:
"Hur modellen tränas. LoRA och QLoRA uppdaterar små adaptrar i stället för varje vikt.",
+ trainAsLabel: "Träna som",
+ trainAsTooltip:
+ "En språkmodell skriver text. En beslutsmodell väljer ett av alternativen du ger den, med en sannolikhet, och körs i Decision API.",
+ trainAsLanguage: "Språkmodell",
+ trainAsDecision: "Beslutsmodell",
datasetLabel: "Datauppsättning",
datasetTooltip: "Träningsdata som används för att finjustera modellen.",
hfTokenDescription:
@@ -4349,6 +4362,18 @@ export const sv = {
openFileFailed: "Det gick inte att öppna filen",
},
},
+ exportDecision: {
+ title: "Beslutsmodell",
+ description:
+ "{layout}-beslutsmodeller exporteras till GGUF för llama.cpp:s beslutsserver. Välj en eller flera kvantiseringar.",
+ adapterNote: "Den här kontrollpunkten innehåller LoRA-adaptrar; de slås samman före konverteringen.",
+ notEligibleTitle: "GGUF-export är inte tillgänglig",
+ ggufOnly: "Beslutsmodeller exporteras bara till GGUF",
+ existing: "Redan exporterad: {quantizations}",
+ outputNote: "GGUF-filer sparas i körningsmappen: {path}",
+ methodLabel: "GGUF för beslutsmodell",
+ outputLabel: "Besluts-GGUF ({quantizations})",
+ },
decisions: {
title: "Testa ett beslut",
description: "Ställ en fråga till Laya om valfri text.",
diff --git a/studio/frontend/tests/general-settings-token-sync.test.ts b/studio/frontend/tests/general-settings-token-sync.test.ts
index 8b172de70b9..e8f6713e84d 100644
--- a/studio/frontend/tests/general-settings-token-sync.test.ts
+++ b/studio/frontend/tests/general-settings-token-sync.test.ts
@@ -2,6 +2,7 @@
// Copyright 2026-present the Unsloth AI Inc. team. All rights reserved. See /studio/LICENSE.AGPL-3.0
import assert from "node:assert/strict";
+import { readFileSync } from "node:fs";
import test from "node:test";
import {
@@ -15,6 +16,18 @@ const tabUrl = new URL(
import.meta.url,
);
+// Every update-banner preference the tab can import, read off the module itself: #12893 added
+// the audio.cpp banner to the tab after this test pinned three names, and every case failed on
+// the missing export. Setters are no-ops and readers say the banner is hidden.
+const updateBannerPrefStub = Object.fromEntries(
+ [
+ ...readFileSync(
+ new URL("../src/hooks/use-llama-update-pref.ts", import.meta.url),
+ "utf8",
+ ).matchAll(/^export function (\w+)/gm),
+ ].map(([, name]) => [name, name.startsWith("set") ? () => undefined : () => false]),
+);
+
type EffectSlot = {
cleanup?: () => void;
deps?: unknown[];
@@ -132,12 +145,7 @@ function generalTab(initialToken: string) {
emitTrainingRunsChanged: noop,
TRAINING_UI_PREFERENCE_KEYS: [],
},
- "@/hooks/use-llama-update-pref": {
- setShowLlamaUpdateBanner: noop,
- setShowWhisperUpdateBanner: noop,
- useShowLlamaUpdateBanner: () => false,
- useShowWhisperUpdateBanner: () => false,
- },
+ "@/hooks/use-llama-update-pref": updateBannerPrefStub,
"@/hooks": {
useHfTokenValidation: () => ({
isValid: false,
diff --git a/tests/studio/test_backend_ci_parallel_isolation.py b/tests/studio/test_backend_ci_parallel_isolation.py
index 30026e3fe76..64d4d4428b2 100644
--- a/tests/studio/test_backend_ci_parallel_isolation.py
+++ b/tests/studio/test_backend_ci_parallel_isolation.py
@@ -258,6 +258,8 @@ _CLOCKS = ("monotonic", "perf_counter", "process_time", "time")
# onto something else.
BENIGN_TIMING = {
("test_media_auto_switch.py", "_until"),
+ # A 600 s poll deadline while llama-server loads the model: descheduling only delays the poll.
+ ("test_decision_native_gpu.py", "_bare_llama_server"),
# A 10 s poll deadline: descheduling only delays the poll, it cannot make the condition false.
("test_npu_chat_route.py", "_wait_for"),
("test_openai_auto_switch.py", "test_any_finished_download_drops_the_resolver_cache"),