The all-in-one local AI studio for your desktop: chat, image and video generation and a coding agent in one free, open source app. Windows and Linux. No Docker, no terminal, no cloud required.
TypeScript agentai-chatai-studioall-in-onecoding-agentdesktop-appfluximage-generationlinuxllmlocal-ailocal-llmopen-sourceprivacyself-hostedstable-diffusionuncensoreduncensored-aivideo-generationwindows
feat(ui): die Built-in Engine heisst ueberall LU Engine
purple69cfeaf09e22
diff --git a/src-tauri/src/commands/download.rs b/src-tauri/src/commands/download.rsindex b83e6b9e..4a1d704a 100644--- a/src-tauri/src/commands/download.rs+++ b/src-tauri/src/commands/download.rs@@ -1109,7 +1109,7 @@ pub fn detect_model_path(provider: String) -> Result<serde_json::Value, String>// Accept the display name too ("Built-in Engine") — the Discover tab// passes `providers.openai.name`, not the internal id, so without these// aliases a built-in-active install couldn't add a second chat model.- "builtin" | "built-in engine" | "built in engine" => {+ "builtin" | "lu engine" | "built-in engine" | "built in engine" => {return crate::commands::engine::builtin_models_dir().map(|p| serde_json::json!(p.to_string_lossy()));}diff --git a/src-tauri/src/commands/engine.rs b/src-tauri/src/commands/engine.rsindex b91dbda9..9b661f31 100644--- a/src-tauri/src/commands/engine.rs+++ b/src-tauri/src/commands/engine.rs@@ -765,7 +765,7 @@ fn port_is_bindable(port: u16) -> bool {/// Said when the whole bounded walk came back empty.pub(crate) fn no_free_port_message(first: u16, last: u16) -> String {format!(- "The built-in engine could not open a local port. Every port it may use between {first} and {last} is taken or blocked on this machine. Close whatever is holding them (a llama-server left over from an earlier session is the usual cause), or check whether a firewall or a reserved Windows port range covers that block, then try again."+ "The LU Engine could not open a local port. Every port it may use between {first} and {last} is taken or blocked on this machine. Close whatever is holding them (a llama-server left over from an earlier session is the usual cause), or check whether a firewall or a reserved Windows port range covers that block, then try again.")}@@ -814,7 +814,7 @@ fn wait_for_health(port: u16, timeout: Duration) -> Result<(), String> {std::thread::sleep(Duration::from_millis(300));}Err(format!(- "Built-in engine did not become healthy on port {port} within {}s (the budget scales with model size, huge GGUFs can take minutes on a cold first load)",+ "LU Engine did not become healthy on port {port} within {}s (the budget scales with model size, huge GGUFs can take minutes on a cold first load)",timeout.as_secs()))}@@ -915,7 +915,7 @@ fn install_commands_for(lib: &str) -> Option<(&'static str, &'static str)> {/// ICDs), so "reinstall and it comes along" would be a lie there.pub(crate) fn missing_library_hint(lib: &str, on_linux: bool) -> String {let head = format!(- " A system library the built-in engine needs is missing on this machine: {lib}."+ " A system library the LU Engine needs is missing on this machine: {lib}.");if !on_linux {return format!("{head} Install the package that provides it, then try again.");@@ -1038,10 +1038,10 @@ pub(crate) fn start_failure_message(failure: &StartFailure, port: u16, budget: D// where the log carries a real bind sentence, because "cuda" appears in// the routine backend-init lines of every start on an NVIDIA box and// "set GPU Layers to 0" does not free a busy port.- format!("The built-in engine started and exited again before it could serve on port {port}. It was tried twice. This looks like a graphics-card problem. Open Settings, Built-in Engine and set GPU Layers to 0 to run on the CPU, then try again.")+ format!("The LU Engine started and exited again before it could serve on port {port}. It was tried twice. This looks like a graphics-card problem. Open Settings, LU Engine and set GPU Layers to 0 to run on the CPU, then try again.")} else if failure.died && stderr_blames_the_port(&failure.stderr) {format!(- "The built-in engine could not open port {port}. Another program holds it, or the port sits in a range this system has reserved. The app already tried the next free ports and got the same answer. Close that program or reboot, then try again."+ "The LU Engine could not open port {port}. Another program holds it, or the port sits in a range this system has reserved. The app already tried the next free ports and got the same answer. Close that program or reboot, then try again.")} else if failure.died {let hint = if let Some(lib) = stderr_names_a_missing_system_library(&failure.stderr) {@@ -1051,10 +1051,10 @@ pub(crate) fn start_failure_message(failure: &StartFailure, port: u16, budget: D} else {" Reinstall Locally Uncensored if this keeps happening, or pick a different backend in Settings, AI Backends.".to_string()};- format!("The built-in engine started and exited again before it could serve on port {port}. It was tried twice.{hint}")+ format!("The LU Engine started and exited again before it could serve on port {port}. It was tried twice.{hint}")} else {format!(- "The built-in engine did not become healthy on port {port} within {}s (the budget scales with model size, and huge GGUFs can take minutes on a cold first load).",+ "The LU Engine did not become healthy on port {port} within {}s (the budget scales with model size, and huge GGUFs can take minutes on a cold first load).",budget.as_secs())};@@ -1215,7 +1215,7 @@ fn start_bundled_engine_blocking(// instruction, it is noise; the only real remedies are a reinstall or a// different backend (GH #118).format!(- "The built-in engine program ({}) is missing from this installation. Reinstall Locally Uncensored, or pick a different backend in Settings, AI Backends.",+ "The LU Engine program ({}) is missing from this installation. Reinstall Locally Uncensored, or pick a different backend in Settings, AI Backends.",sidecar_binary_name())})?;@@ -3215,11 +3215,11 @@ mod tests {// Same sidecar, same loader, same missing package. Document Chat used// to answer this with the raw stderr tail alone.let msg = embed_start_failure_message(- "Built-in engine did not become healthy on port 8128 within 60s",+ "LU Engine did not become healthy on port 8128 within 60s","lu-llama-server: error while loading shared libraries: libgomp.so.1: cannot open shared object file: No such file or directory",);assert!(msg.contains("libgomp.so.1"), "{msg}");- assert!(msg.contains("A system library the built-in engine needs is missing"), "{msg}");+ assert!(msg.contains("A system library the LU Engine needs is missing"), "{msg}");// The engine's own last words survive for a bug report.assert!(msg.contains("cannot open shared object file"), "{msg}");// No port or retry wording from the chat path: this one refuses a@@ -3229,7 +3229,7 @@ mod tests {// Negative control: an ordinary slow load keeps the plain message and// gains no packaging advice.let slow = embed_start_failure_message(- "Built-in engine did not become healthy on port 8128 within 60s",+ "LU Engine did not become healthy on port 8128 within 60s","load_tensors: loading model tensors",);assert!(!slow.contains("A system library"), "{slow}");diff --git a/src-tauri/src/commands/proxy.rs b/src-tauri/src/commands/proxy.rsindex 1be52600..33ed5fb6 100644--- a/src-tauri/src/commands/proxy.rs+++ b/src-tauri/src/commands/proxy.rs@@ -556,7 +556,7 @@ pub(crate) fn builtin_model_conflict(return None;}Some(format!(- "The built-in engine has \"{loaded}\" loaded, but this request asked for \"{asked}\". \+ "The LU Engine has \"{loaded}\" loaded, but this request asked for \"{asked}\". \The engine answers with the model it was started with, whatever the model field says, \so this request was refused instead of being answered by the wrong model. \Load \"{asked}\" first (Models, or the chat model picker) and send again."diff --git a/src/api/__tests__/builtin-default-provider.test.ts b/src/api/__tests__/builtin-default-provider.test.tsindex b5d45244..e343885d 100644--- a/src/api/__tests__/builtin-default-provider.test.ts+++ b/src/api/__tests__/builtin-default-provider.test.ts@@ -25,7 +25,7 @@ describe('default provider = built-in engine', () => {expect(openai.enabled).toBe(true)expect(openai.managed).toBe(true)expect(openai.isLocal).toBe(true)- expect(openai.name).toBe('Built-in Engine')+ expect(openai.name).toBe('LU Engine')expect(openai.baseUrl).toBe('http://127.0.0.1:8127/v1')expect(openai.apiKey).toBe('')})diff --git a/src/api/__tests__/builtin-engine-dead-port.test.ts b/src/api/__tests__/builtin-engine-dead-port.test.tsindex 7da2d1ea..81b060ae 100644--- a/src/api/__tests__/builtin-engine-dead-port.test.ts+++ b/src/api/__tests__/builtin-engine-dead-port.test.ts@@ -51,7 +51,7 @@ describe('explainDeadEngine', () => {it('turns the exact reported error into a sentence naming the engine and the port', () => {const out = explainDeadEngine(new Error(raw), MANAGED_URL) as Error- expect(out.message).toMatch(/built-in engine is not answering on 127\.0\.0\.1:8127/i)+ expect(out.message).toMatch(/LU Engine is not answering on 127\.0\.0\.1:8127/i)expect(out.message).toMatch(/Settings/i)})@@ -72,7 +72,7 @@ describe('explainDeadEngine', () => {'ECONNREFUSED 127.0.0.1:8127',]) {const out = explainDeadEngine(new Error(msg), MANAGED_URL) as Error- expect(out.message).toMatch(/built-in engine is not answering/i)+ expect(out.message).toMatch(/LU Engine is not answering/i)}})diff --git a/src/api/__tests__/builtin-ensure.test.ts b/src/api/__tests__/builtin-ensure.test.tsindex 99f06869..a00d4639 100644--- a/src/api/__tests__/builtin-ensure.test.ts+++ b/src/api/__tests__/builtin-ensure.test.ts@@ -130,7 +130,7 @@ describe('explainEngineTransportMessage keeps the raw line reachable', () => {const warn = vi.spyOn(log, 'warn').mockImplementation(() => {})const raw = 'proxy_localhost_stream_chunked: error sending request for url (http://127.0.0.1:8127/v1/chat/completions)'const text = explainEngineTransportMessage(raw, 'http://127.0.0.1:8127')- expect(text).toMatch(/built-in engine is not answering/)+ expect(text).toMatch(/LU Engine is not answering/)expect(text).not.toContain('proxy_localhost')expect(warn).toHaveBeenCalledWith(expect.any(String), expect.objectContaining({ raw }))warn.mockRestore()diff --git a/src/api/__tests__/custom-model-folder.test.ts b/src/api/__tests__/custom-model-folder.test.tsindex 6f32d645..4dfc9cb5 100644--- a/src/api/__tests__/custom-model-folder.test.ts+++ b/src/api/__tests__/custom-model-folder.test.ts@@ -111,7 +111,7 @@ describe('a model found in that folder is an Installed row', () => {const rows = bundledToAIModels(bundled)expect(rows).toHaveLength(1)expect(rows[0].name).toBe('openai::Cydonia-24B-v4.1-Q4_K_M')- expect(rows[0].providerName).toBe('Built-in Engine')+ expect(rows[0].providerName).toBe('LU Engine')expect(rows[0].size).toBe(14_000_000_000)})diff --git a/src/api/__tests__/engine-swap-race.test.ts b/src/api/__tests__/engine-swap-race.test.tsindex b85a6f97..cb902a69 100644--- a/src/api/__tests__/engine-swap-race.test.ts+++ b/src/api/__tests__/engine-swap-race.test.ts@@ -61,7 +61,7 @@ beforeEach(() => {const managedProvider = () =>new OpenAIProvider({- id: 'openai', name: 'Built-in Engine', enabled: true,+ id: 'openai', name: 'LU Engine', enabled: true,baseUrl: MANAGED_URL, apiKey: '', isLocal: true, managed: true,} as never)@@ -142,7 +142,7 @@ describe('ensureBuiltinEngineAlive waits the swap out before probing', () => {describe('a transport failure that still gets through is labelled in English', () => {it('rewrites the exact body the proxy hands back as a 503', () => {const out = explainEngineTransportMessage(RAW, MANAGED_URL)- expect(out).toMatch(/built-in engine is not answering on 127\.0\.0\.1:8127/i)+ expect(out).toMatch(/LU Engine is not answering on 127\.0\.0\.1:8127/i)expect(out).toMatch(/still loading a model/i)expect(out).not.toContain('proxy_localhost_stream_chunked')})@@ -152,7 +152,7 @@ describe('a transport failure that still gets through is labelled in English', ('proxy_localhost: error sending request for url (http://127.0.0.1:8127/v1/models)',MANAGED_URL,)- expect(out).toMatch(/built-in engine is not answering/i)+ expect(out).toMatch(/LU Engine is not answering/i)})// NEGATIVE CONTROL: a real answer from the server keeps the server's own@@ -183,7 +183,7 @@ describe('the provider really hands the plain sentence on (wiring)', () => {const err = await managedProvider().chatWithTools('Hermes', [{ role: 'user', content: 'hi' }] as never, [] as never).then(() => null, (e: Error) => e)- expect(err?.message).toMatch(/built-in engine is not answering/i)+ expect(err?.message).toMatch(/LU Engine is not answering/i)expect(err?.message).not.toContain('proxy_localhost_stream_chunked')})diff --git a/src/api/__tests__/engine.test.ts b/src/api/__tests__/engine.test.tsindex 2367ed03..cb5b1eb3 100644--- a/src/api/__tests__/engine.test.ts+++ b/src/api/__tests__/engine.test.ts@@ -109,7 +109,7 @@ describe('bundledToAIModels', () => {model: 'qwen2.5-0.5b',type: 'text',provider: 'openai',- providerName: 'Built-in Engine',+ providerName: 'LU Engine',})expect(models[1].name).toBe('openai::llama3')})diff --git a/src/api/builtin-ensure.ts b/src/api/builtin-ensure.tsindex d55707c9..e5b58f0a 100644--- a/src/api/builtin-ensure.ts+++ b/src/api/builtin-ensure.ts@@ -102,7 +102,7 @@ export function explainEngineTransportMessage(message: string, baseUrl: string):// now instead of in the chat bubble. House rule: no raw Rust error in front// of a user.log.warn('[builtin-engine] transport failure hidden behind a plain sentence', { raw: msg, host })- return `The built-in engine is not answering on ${host}. It is either still loading a model, failed to start, or was shut down. Wait for the model to finish loading and send again, or open Settings, AI Backends, Built-in Engine and start it there.`+ return `The LU Engine is not answering on ${host}. It is either still loading a model, failed to start, or was shut down. Wait for the model to finish loading and send again, or open Settings, AI Backends, LU Engine and start it there.`}/** True when the `openai` slot is the app-managed built-in engine. */@@ -243,7 +243,7 @@ async function loadBuiltinModel(modelName: string): Promise<void> {// on Windows 10 — they gave up on the built-in engine and moved to// Ollama). Say what is actually wrong instead.throw new Error(- `The built-in engine has no model file named "${bare}". It may have been deleted, moved, or the download did not finish. Open Models, install it again, then pick it in the chat.`,+ `The LU Engine has no model file named "${bare}". It may have been deleted, moved, or the download did not finish. Open Models, install it again, then pick it in the chat.`,)}@@ -447,7 +447,7 @@ export async function diagnoseBuiltinEngine(return {ok: false,repaired: false,- reason: `The built-in engine is not running and its model folder could not be read: ${errText(e)}`,+ reason: `The LU Engine is not running and its model folder could not be read: ${errText(e)}`,}}@@ -457,7 +457,7 @@ export async function diagnoseBuiltinEngine(ok: false,repaired: false,reason:- 'The built-in engine is installed but has no chat model to load yet. Open Models, Discover and install one, then test again.',+ 'The LU Engine is installed but has no chat model to load yet. Open Models, Discover and install one, then test again.',}}@@ -465,7 +465,7 @@ export async function diagnoseBuiltinEngine(return {ok: false,repaired: false,- reason: `The built-in engine is not running. ${runnable.length} model${runnable.length === 1 ? ' is' : 's are'} installed. Pick one in the chat model picker to start the engine.`,+ reason: `The LU Engine is not running. ${runnable.length} model${runnable.length === 1 ? ' is' : 's are'} installed. Pick one in the chat model picker to start the engine.`,}}@@ -483,7 +483,7 @@ export async function diagnoseBuiltinEngine(return {ok: false,repaired: false,- reason: `The built-in engine has no model file named "${bare}". It may have been deleted, moved, or the download did not finish. Open Models and install it again.`,+ reason: `The LU Engine has no model file named "${bare}". It may have been deleted, moved, or the download did not finish. Open Models and install it again.`,}}try {@@ -502,7 +502,7 @@ export async function diagnoseBuiltinEngine(return {ok: false,repaired: false,- reason: `The built-in engine could not start "${pick.name}": ${errText(e)}`,+ reason: `The LU Engine could not start "${pick.name}": ${errText(e)}`,}}}diff --git a/src/api/engine.ts b/src/api/engine.tsindex 219edf51..c1b43e37 100644--- a/src/api/engine.ts+++ b/src/api/engine.ts@@ -19,6 +19,7 @@ import { useProviderStore } from '../stores/providerStore'import { useSettingsStore } from '../stores/settingsStore'import type { CloudModel } from '../types/models'import type { BuiltinEngineTuning } from '../types/settings'+import { LU_ENGINE_NAME } from '../lib/engine-name'/** The user's Built-in Engine expert tuning (settings-backed). Injected into* every start/swap below, so Onboarding, Discover, the model picker and the@@ -361,7 +362,7 @@ export function bundledToAIModels(models: BundledModel[]): CloudModel[] {size: m.size,type: 'text' as const,provider: 'openai' as const,- providerName: 'Built-in Engine',+ providerName: LU_ENGINE_NAME,// The projector answer from disk, carried as the app-wide capability flag// so the composer and the agent loop stop guessing from the model name.// Deliberately left absent (not false) when the backend did not report it,diff --git a/src/api/providers/types.ts b/src/api/providers/types.tsindex 68bdb8e4..1257fc3e 100644--- a/src/api/providers/types.ts+++ b/src/api/providers/types.ts@@ -7,6 +7,8 @@// ── Provider Identity ──────────────────────────────────────────+import { LU_ENGINE_NAME } from '../../lib/engine-name'+export type ProviderId = 'ollama' | 'openai' | 'anthropic' | 'lu-cloud'export interface ProviderConfig {@@ -64,7 +66,7 @@ export interface ProviderPreset {export const PROVIDER_PRESETS: ProviderPreset[] = [// Built-in engine (2.5.7) — bundled llama.cpp llama-server, OpenAI-compatible,// lifecycle owned by the app. Zero external install. Default backend.- { id: 'builtin', name: 'Built-in Engine', providerId: 'openai', baseUrl: 'http://127.0.0.1:8127/v1', isLocal: true, managed: true },+ { id: 'builtin', name: LU_ENGINE_NAME, providerId: 'openai', baseUrl: 'http://127.0.0.1:8127/v1', isLocal: true, managed: true },// Ollama (dedicated provider){ id: 'ollama', name: 'Ollama', providerId: 'ollama', baseUrl: 'http://localhost:11434', isLocal: true },diff --git a/src/api/rag.ts b/src/api/rag.tsindex 7162a953..914dde87 100644--- a/src/api/rag.ts+++ b/src/api/rag.ts@@ -118,7 +118,7 @@ export async function generateEmbeddings(// of the missing part (measured on the Windows box, 2026-08-15).if (!(await bundledEmbedStatus().then((s) => s.running).catch(() => false))) {throw new Error(- "No embedding model is installed for the built-in engine. Open Document Chat and use the install card to download it (84 MB), then drop the file again."+ "No embedding model is installed for the LU Engine. Open Document Chat and use the install card to download it (84 MB), then drop the file again.")}return embedViaBuiltin(texts, model)diff --git a/src/api/vram-handoff.ts b/src/api/vram-handoff.tsindex 0a89c806..ed4a1245 100644--- a/src/api/vram-handoff.ts+++ b/src/api/vram-handoff.ts@@ -935,7 +935,7 @@ async function runHandoff(kind: 'image' | 'video', args: VramHandoffArgs, seq: n// ── (b3) HANDOFF-OUT for the built-in engine (GH #85) ──────────if (willUnloadBundled && bundledTarget) {- emitHandoff('freeing_vram', { kind, detail: 'built-in engine' })+ emitHandoff('freeing_vram', { kind, detail: 'LU Engine' })// Carry the conversation across the eviction: serialize the KV cache to// disk, then stop the engine. Restore happens in the finally. When// either half fails, the next chat turn just re-processes the history,diff --git a/src/components/chat/ContextDropdown.tsx b/src/components/chat/ContextDropdown.tsxindex e1a6093c..882eb74c 100644--- a/src/components/chat/ContextDropdown.tsx+++ b/src/components/chat/ContextDropdown.tsx@@ -114,7 +114,7 @@ export function ContextDropdown() {<buttononClick={() => setOpen((o) => !o)}disabled={busy}- title={`Context window: ${ctx.provider === 'lmstudio' ? "LM Studio's loaded context" : ctx.provider === 'builtin' ? "the built-in engine's loaded context" : 'Ollama num_ctx'}. Changing it reloads the model so it takes effect now.`}+ title={`Context window: ${ctx.provider === 'lmstudio' ? "LM Studio's loaded context" : ctx.provider === 'builtin' ? "the LU Engine's loaded context" : 'Ollama num_ctx'}. Changing it reloads the model so it takes effect now.`}className="flex items-center gap-1 px-1.5 py-0.5 rounded border border-gray-200 dark:border-white/[0.06] hover:border-gray-400 dark:hover:border-white/15 text-gray-500 transition-colors text-[0.55rem] font-mono tabular-nums disabled:opacity-60">{busy ? <Loader2 size={9} className="animate-spin" /> : null}diff --git a/src/components/chat/GroupCostHint.tsx b/src/components/chat/GroupCostHint.tsxindex ee8dc740..cc17fb03 100644--- a/src/components/chat/GroupCostHint.tsx+++ b/src/components/chat/GroupCostHint.tsx@@ -26,7 +26,7 @@ import { isGroupChat } from '../../lib/group-chat'export function groupCostHintText(models: number, builtinSpeakers = 0): string {const base = `1 round = ${models} answers = ${models}x the cost`return builtinSpeakers >= 2- ? `${base}, and the built-in engine reloads between local speakers`+ ? `${base}, and the LU Engine reloads between local speakers`: base}diff --git a/src/components/chat/TokenCounter.tsx b/src/components/chat/TokenCounter.tsxindex d41f8968..5a9596c4 100644--- a/src/components/chat/TokenCounter.tsx+++ b/src/components/chat/TokenCounter.tsx@@ -67,7 +67,7 @@ export function TokenCounter() {: ctx.provider === 'ollama'? 'Ollama num_ctx': ctx.provider === 'builtin'- ? 'built-in engine loaded context'+ ? 'LU Engine loaded context': 'model context'const capped = ctx.sendWindow > 0 && ctx.contextWindow > ctx.sendWindowconst capNote = cappeddiff --git a/src/components/models/DiscoverModels.tsx b/src/components/models/DiscoverModels.tsxindex efe8bae0..1a28cd45 100644--- a/src/components/models/DiscoverModels.tsx+++ b/src/components/models/DiscoverModels.tsx@@ -615,7 +615,7 @@ export function DiscoverModels({ category, search = '', searchSubmitToken = 0 }:try {await startBundledEngine(`${targetDir}/${realName}`)} catch (e) {- setInstallError(`Model downloaded, but the built-in engine failed to start: ${e instanceof Error ? e.message : String(e)}`)+ setInstallError(`Model downloaded, but the LU Engine failed to start: ${e instanceof Error ? e.message : String(e)}`)}}// Outside the built-in branch too: an LM Studio or openai-compat downloaddiff --git a/src/components/models/ModelSelector.tsx b/src/components/models/ModelSelector.tsxindex 1762cfff..b26fecdd 100644--- a/src/components/models/ModelSelector.tsx+++ b/src/components/models/ModelSelector.tsx@@ -233,7 +233,7 @@ function LmStudioServerHint({ onStarted }: { onStarted: () => void }) {</button>{replacesBuiltinEngine && (<p className="text-[0.55rem] text-gray-500 dark:text-gray-400 mt-1 leading-snug">- This also makes LM Studio your local chat backend in place of the built-in engine. You can switch back under Settings, AI Backends, Providers.+ This also makes LM Studio your local chat backend in place of the LU Engine. You can switch back under Settings, AI Backends, Providers.</p>)}{startError && (@@ -741,7 +741,7 @@ export function ModelSelector({ openUpward = false, surface = 'chat', answeredBy}setOpen(false)} catch (e) {- setSelectError(`Couldn't start the built-in engine with "${displayModelName(model.name)}": ${e instanceof Error ? e.message : String(e)}`)+ setSelectError(`Couldn't start the LU Engine with "${displayModelName(model.name)}": ${e instanceof Error ? e.message : String(e)}`)} finally {setSelectingLms(null)}@@ -887,7 +887,7 @@ export function ModelSelector({ openUpward = false, surface = 'chat', answeredByletting an empty local section read as a bug (G20). */}{appMode === 'cloud' && (<div className="px-2.5 py-1.5 border-b border-black/5 dark:border-white/[0.06] text-[0.55rem] text-gray-500">- Cloud mode shows hosted models only. Switch the app to Local mode to use Ollama, LM Studio or the Built-in Engine.+ Cloud mode shows hosted models only. Switch the app to Local mode to use Ollama, LM Studio or the LU Engine.</div>)}diff --git a/src/components/onboarding/BackendSelector.tsx b/src/components/onboarding/BackendSelector.tsxindex 39b2ad8a..494d5315 100644--- a/src/components/onboarding/BackendSelector.tsx+++ b/src/components/onboarding/BackendSelector.tsx@@ -106,7 +106,7 @@ export function BackendSelector({ open, backends, onClose }: Props) {engine already works out of the box and stays active if skipped. */}{builtinActive && (<p className="text-[0.65rem] text-gray-500 text-center leading-relaxed">- You're already set up with the built-in engine. Switching is optional.+ You're already set up with the LU Engine. Switching is optional.</p>)}@@ -158,7 +158,7 @@ export function BackendSelector({ open, backends, onClose }: Props) {onClick={dismiss}className="px-4 py-1.5 rounded-lg text-[0.7rem] text-gray-400 hover:text-white hover:bg-white/10 transition-colors">- {builtinActive ? 'Keep built-in engine' : 'Skip'}+ {builtinActive ? 'Keep LU Engine' : 'Skip'}</button><buttononClick={handleConfirm}diff --git a/src/components/onboarding/Onboarding.tsx b/src/components/onboarding/Onboarding.tsxindex 5ee5b0e7..be7d2269 100644--- a/src/components/onboarding/Onboarding.tsx+++ b/src/components/onboarding/Onboarding.tsx@@ -18,6 +18,7 @@ import { pullModelTauri, checkConnection as checkOllama } from '../../api/ollamaimport { hfUrlToOllamaRef, hfUrlToLmStudioSubdir } from '../../lib/hf-to-provider'import { startBundledEngine, startBundledEmbed } from '../../api/engine'import { BUILTIN_BACKEND_ID, classifyOnboardingBackend, resolveOnboardingBackend } from '../../lib/onboarding-backend'+import { LU_ENGINE_NAME } from '../../lib/engine-name'import { version as currentVersion } from '../../../package.json'import { useReleaseNotesStore } from '../../stores/releaseNotesStore'@@ -235,7 +236,7 @@ export function Onboarding() {if (useBuiltinPath) {destDir = await detectProviderModelPath(BUILTIN_BACKEND_ID)if (!destDir) {- setDownloadError('Could not create the built-in engine model folder. Check app permissions and retry.')+ setDownloadError('Could not create the LU Engine model folder. Check app permissions and retry.')return}} else if (!useOllamaPath) {@@ -316,7 +317,7 @@ export function Onboarding() {try {await startBundledEngine(`${destDir}/${model.filename}`)} catch (e) {- setDownloadError(`Model downloaded, but the built-in engine failed to start: ${e instanceof Error ? e.message : String(e)}`)+ setDownloadError(`Model downloaded, but the LU Engine failed to start: ${e instanceof Error ? e.message : String(e)}`)}} else {// LM Studio etc.: nest under <user>/<repo>/ so the scanner finds@@ -370,7 +371,7 @@ export function Onboarding() {const selectBackendAndContinue = () => {if (selectedBackend === BUILTIN_BACKEND_ID) {setProviderConfig('openai', {- enabled: true, name: 'Built-in Engine',+ enabled: true, name: LU_ENGINE_NAME,baseUrl: 'http://127.0.0.1:8127/v1', isLocal: true, managed: true,})} else if (selectedBackend === 'ollama') {@@ -840,7 +841,7 @@ export function Onboarding() {><Cpu size={16} className={selectedBackend === BUILTIN_BACKEND_ID ? (isDark ? 'text-white' : 'text-gray-900') : 'text-gray-500'} /><div className="flex-1 min-w-0">- <p className="text-[0.72rem] font-medium">Built-in Engine</p>+ <p className="text-[0.72rem] font-medium">LU Engine</p><p className={`text-[0.55rem] ${isDark ? 'text-gray-500' : 'text-gray-400'}`}>Runs on your machine · nothing to install</p></div>{selectedBackend === BUILTIN_BACKEND_ID && <Check size={14} className="text-green-400 shrink-0" />}@@ -1800,7 +1801,7 @@ export function Onboarding() {{pulledModels.length > 0? `${pulledModels.length} model${pulledModels.length > 1 ? 's' : ''} installed. You're ready to go.`: selectedBackend === BUILTIN_BACKEND_ID- ? 'The built-in engine is ready. Install a model anytime from the Models tab.'+ ? 'The LU Engine is ready. Install a model anytime from the Models tab.': detectedBackends.length > 0? `Connected to ${detectedBackends.find(b => b.id === selectedBackend)?.name || detectedBackends[0].name}. You're ready to go.`: 'You can configure backends and install models anytime from Settings and the Models tab.'}diff --git a/src/components/onboarding/__tests__/BackendSelector-builtin.test.ts b/src/components/onboarding/__tests__/BackendSelector-builtin.test.tsindex 606c1d60..77dad01f 100644--- a/src/components/onboarding/__tests__/BackendSelector-builtin.test.ts+++ b/src/components/onboarding/__tests__/BackendSelector-builtin.test.ts@@ -31,8 +31,8 @@ describe('BackendSelector built-in engine awareness', () => {expect(src).toMatch(/providers\.openai\.managed\s*===\s*true/)})- it('relabels the dismiss action to keep the built-in engine', () => {- expect(src).toMatch(/Keep built-in engine/i)+ it('relabels the dismiss action to keep the LU Engine', () => {+ expect(src).toMatch(/Keep LU Engine/i)})it('still persists the opt-out and can enable a picked external backend', () => {diff --git a/src/components/settings/BuiltinEngineSettings.tsx b/src/components/settings/BuiltinEngineSettings.tsxindex 31217317..ddb8c0e9 100644--- a/src/components/settings/BuiltinEngineSettings.tsx+++ b/src/components/settings/BuiltinEngineSettings.tsx@@ -84,7 +84,7 @@ export function BuiltinEngineSettings() {<div className="flex items-start gap-2.5 p-2.5 rounded-lg border border-amber-200 dark:border-amber-500/20 bg-amber-50 dark:bg-amber-500/[0.08] text-amber-900 dark:text-amber-200"><Zap size={14} className="mt-0.5 shrink-0" /><div className="text-[0.65rem] leading-relaxed">- <strong>Expert settings for the built-in engine.</strong> The defaults match what LU shipped with and are right for most machines. Every start of the engine uses these values; a running engine needs Apply & Restart below.+ <strong>Expert settings for the LU Engine.</strong> The defaults match what LU shipped with and are right for most machines. Every start of the engine uses these values; a running engine needs Apply & Restart below.</div></div>diff --git a/src/components/settings/ProviderConfig.tsx b/src/components/settings/ProviderConfig.tsxindex c01a1ff0..7914ae86 100644--- a/src/components/settings/ProviderConfig.tsx+++ b/src/components/settings/ProviderConfig.tsx@@ -79,8 +79,8 @@ export function providerSlotView(id: ProviderId, config: ProviderConfig): SlotViendpointEditable: false,needsKey: false,note: config.baseUrl- ? `Built-in engine, runs locally on ${config.baseUrl}, nothing to configure.`- : 'Built-in engine, runs locally, nothing to configure.',+ ? `LU Engine, runs locally on ${config.baseUrl}, nothing to configure.`+ : 'LU Engine, runs locally, nothing to configure.',}}return {diff --git a/src/components/settings/SettingsPage.tsx b/src/components/settings/SettingsPage.tsxindex 9616a9eb..ff0216e7 100644--- a/src/components/settings/SettingsPage.tsx+++ b/src/components/settings/SettingsPage.tsx@@ -1560,7 +1560,7 @@ export function SettingsPage() {</Section>{builtinManaged && (- <Section title="Built-in Engine (expert)">+ <Section title="LU Engine (expert)"><BuiltinEngineSettings /></Section>)}diff --git a/src/components/settings/__tests__/provider-slot-view.test.ts b/src/components/settings/__tests__/provider-slot-view.test.tsindex 430117f0..45722a5a 100644--- a/src/components/settings/__tests__/provider-slot-view.test.ts+++ b/src/components/settings/__tests__/provider-slot-view.test.ts@@ -72,12 +72,12 @@ describe('the other slots keep working exactly as before', () => {it('leaves the built-in engine on its fixed address with no key', () => {const v = providerSlotView('openai', {- id: 'openai', name: 'Built-in Engine', enabled: true,+ id: 'openai', name: 'LU Engine', enabled: true,baseUrl: 'http://127.0.0.1:8127/v1', apiKey: '', isLocal: true, managed: true,})expect(v.endpointEditable).toBe(false)expect(v.needsKey).toBe(false)- expect(v.note).toContain('Built-in')+ expect(v.note).toContain('LU Engine')})it('keeps a local backend editable, since its port really is the user\'s', () => {diff --git a/src/hooks/__tests__/group-speaker-model-swap.test.ts b/src/hooks/__tests__/group-speaker-model-swap.test.tsindex 8ff4cb60..0fb43c7b 100644--- a/src/hooks/__tests__/group-speaker-model-swap.test.ts+++ b/src/hooks/__tests__/group-speaker-model-swap.test.ts@@ -44,7 +44,7 @@ describe('every speaker gets its own model loaded', () => {})it('says what it is waiting for and clears the line again', () => {- expect(groupTurn).toMatch(/Loading \$\{toLoad\} into the built-in engine for this turn/)+ expect(groupTurn).toMatch(/Loading \$\{toLoad\} into the LU Engine for this turn/)// The announcement is written before the wait, and taken back after it, so// a turn that answers normally shows no leftover status line.const hint = groupTurn.indexOf('Loading ${toLoad}')@@ -78,7 +78,7 @@ describe('every speaker gets its own model loaded', () => {describe('the composer hint tells the truth about local line-ups', () => {it('names the reload when two or more speakers share the engine', () => {expect(groupCostHintText(2, 2)).toBe(- '1 round = 2 answers = 2x the cost, and the built-in engine reloads between local speakers',+ '1 round = 2 answers = 2x the cost, and the LU Engine reloads between local speakers',)})diff --git a/src/hooks/useChat.ts b/src/hooks/useChat.tsindex 79baaeeb..ac5a123b 100644--- a/src/hooks/useChat.ts+++ b/src/hooks/useChat.ts@@ -139,7 +139,7 @@ async function runGroupTurn(convId: string, model: string, allModels: string[],useChatStore.getState().updateMessageContent(convId,assistantMessage.id,- `Loading ${toLoad} into the built-in engine for this turn...`,+ `Loading ${toLoad} into the LU Engine for this turn...`,)await ensureBuiltinEngineAlive(model)// A stop during the load must not leave the loading line standing indiff --git a/src/hooks/useRAG.ts b/src/hooks/useRAG.tsindex e332a8ed..eb1e62f5 100644--- a/src/hooks/useRAG.ts+++ b/src/hooks/useRAG.ts@@ -199,7 +199,7 @@ export function useRAG(conversationId: string | null) {const ollamaUp = await checkConnection(EMBED_PROBE_TIMEOUT_MS)if (!ollamaUp) {throw new Error(- "No embedding backend is running. Start the built-in engine (or Ollama) and try again."+ "No embedding backend is running. Start the LU Engine (or Ollama) and try again.")}diff --git a/src/lib/__tests__/added-provider-can-be-removed.test.ts b/src/lib/__tests__/added-provider-can-be-removed.test.tsindex f180a17e..1370d419 100644--- a/src/lib/__tests__/added-provider-can-be-removed.test.ts+++ b/src/lib/__tests__/added-provider-can-be-removed.test.ts@@ -63,13 +63,13 @@ const JAN_IN_SLOT: HandoverSlot = {describe('THE FIX: a backend put into the local slot can be taken off again', () => {it('the measured state offers a Remove, and it names a way back', () => {- expect(standbyOccupant(JAN_IN_SLOT)?.name).toBe('Built-in Engine')+ expect(standbyOccupant(JAN_IN_SLOT)?.name).toBe('LU Engine')expect(occupantIsRemovable(JAN_IN_SLOT)).toBe(true)})it('Remove puts the slot back exactly as it stood before the takeover', () => {const update = slotRemoveOccupantUpdate(JAN_IN_SLOT)!- expect(update.name).toBe('Built-in Engine')+ expect(update.name).toBe('LU Engine')expect(update.baseUrl).toBe(BUILTIN.baseUrl)expect(update.managed).toBe(true)expect(update.isLocal).toBe(true)@@ -95,7 +95,7 @@ describe('THE FIX: a backend put into the local slot can be taken off again', ()const after = { ...swapped, ...slotForgetStandbyUpdate(swapped)! } as HandoverSlotexpect(standbyOccupant(after)).toBeNull()// and the slot itself was not touched- expect(after.name).toBe('Built-in Engine')+ expect(after.name).toBe('LU Engine')expect(after.enabled).toBe(true)})@@ -133,11 +133,11 @@ describe('NEGATIVE CONTROL: what must stay un-removable', () => {it('the R10 and R11 mechanics are unchanged by all of this', () => {// takeover still remembers- expect(slotTakeoverUpdate(SHIPPED, JAN).displaced?.name).toBe('Built-in Engine')+ expect(slotTakeoverUpdate(SHIPPED, JAN).displaced?.name).toBe('LU Engine')// a slot that was already off is still not remembered as displacedexpect(slotTakeoverUpdate({ ...SHIPPED, enabled: false }, JAN).displaced).toBeUndefined()// and handback still returns the swap patch- expect(slotHandbackUpdate(JAN_IN_SLOT)!.name).toBe('Built-in Engine')+ expect(slotHandbackUpdate(JAN_IN_SLOT)!.name).toBe('LU Engine')})})diff --git a/src/lib/__tests__/builtin-card-survives-add-provider.test.ts b/src/lib/__tests__/builtin-card-survives-add-provider.test.tsindex 6695a3b1..00dcb0c9 100644--- a/src/lib/__tests__/builtin-card-survives-add-provider.test.ts+++ b/src/lib/__tests__/builtin-card-survives-add-provider.test.ts@@ -70,13 +70,13 @@ describe('THE FIX: Add Provider no longer makes the built-in card disappear', ()it('so the list still has a card to draw for the built-in engine', () => {const after = { ...SHIPPED, ...slotTakeoverUpdate(SHIPPED, JAN) } as HandoverSlot- expect(standbyOccupant(after)?.name).toBe('Built-in Engine')+ expect(standbyOccupant(after)?.name).toBe('LU Engine')})it('and Enable on that card hands the slot back to the built-in engine', () => {const after = { ...SHIPPED, ...slotTakeoverUpdate(SHIPPED, JAN) } as HandoverSlotconst back = slotHandbackUpdate(after)!- expect(back.name).toBe('Built-in Engine')+ expect(back.name).toBe('LU Engine')expect(back.baseUrl).toBe('http://127.0.0.1:8127/v1')expect(back.managed).toBe(true)expect(back.enabled).toBe(true)@@ -100,9 +100,9 @@ describe('THE FIX: Add Provider no longer makes the built-in card disappear', ()// Two ways out on screen now: Enable on the Jan row it switched off,expect(isReturnableRow(janOff)).toBe(true)// and Enable on the built-in engine standing by.- expect(standbyOccupant(janOff)?.name).toBe('Built-in Engine')+ expect(standbyOccupant(janOff)?.name).toBe('LU Engine')const back = slotHandbackUpdate(janOff)!- expect(back.name).toBe('Built-in Engine')+ expect(back.name).toBe('LU Engine')expect(back.enabled).toBe(true)// Switching a backend off is not the same as giving up its slot, so the// Disable mark does not travel with the slot.@@ -183,7 +183,7 @@ describe('NEGATIVE CONTROL: the counter-poles of R10 are untouched', () => {const after = { ...SHIPPED, ...slotTakeoverUpdate(SHIPPED, JAN) } as HandoverSlotconst janOff = { ...after, enabled: false }const janOnAgain = { ...janOff, ...slotTakeoverUpdate(janOff, JAN) } as HandoverSlot- expect(standbyOccupant(janOnAgain)?.name).toBe('Built-in Engine')+ expect(standbyOccupant(janOnAgain)?.name).toBe('LU Engine')})})diff --git a/src/lib/__tests__/disable-hands-the-slot-back.test.ts b/src/lib/__tests__/disable-hands-the-slot-back.test.tsindex d0d184d6..23563522 100644--- a/src/lib/__tests__/disable-hands-the-slot-back.test.ts+++ b/src/lib/__tests__/disable-hands-the-slot-back.test.ts@@ -68,7 +68,7 @@ describe('THE FIX: Disable on the slot holder gives the slot back', () => {// what it does: the waiting engine takes the slotconst patch = slotHandbackUpdate(JAN_IN_SLOT)!const newWay = listWith({ ...JAN_IN_SLOT, ...patch } as HandoverSlot)- expect(newWay.openai.name).toBe('Built-in Engine')+ expect(newWay.openai.name).toBe('LU Engine')expect(newWay.openai.managed).toBe(true)expect(newWay.openai.enabled).toBe(true)expect(noChatBackendEnabled(newWay, 'local')).toBe(false)diff --git a/src/lib/__tests__/disable-says-disabled.test.ts b/src/lib/__tests__/disable-says-disabled.test.tsindex df0c223f..58107676 100644--- a/src/lib/__tests__/disable-says-disabled.test.ts+++ b/src/lib/__tests__/disable-says-disabled.test.ts@@ -93,7 +93,7 @@ describe('THE FIX: Disable on the slot holder says the backend is disabled', ()// and switching it back on clears the mark rather than dragging it alongexpect(back.disabledByUser).toBe(false)const reEnabled = { ...afterDisable, ...back } as HandoverSlot- expect(standbyOccupant(reEnabled)?.name).toBe('Built-in Engine')+ expect(standbyOccupant(reEnabled)?.name).toBe('LU Engine')expect(standbyOccupant(reEnabled)?.disabledByUser).toBeUndefined()})})@@ -104,7 +104,7 @@ describe('NEGATIVE CONTROL: everything R10, R11 and R13 settled', () => {// with no local backend at all.const patch = slotDisableOccupantUpdate(JAN_IN_SLOT)!const after = listWith({ ...JAN_IN_SLOT, ...patch } as HandoverSlot)- expect(after.openai.name).toBe('Built-in Engine')+ expect(after.openai.name).toBe('LU Engine')expect(after.openai.managed).toBe(true)expect(after.openai.enabled).toBe(true)expect(noChatBackendEnabled(after, 'local')).toBe(false)@@ -140,7 +140,7 @@ describe('NEGATIVE CONTROL: everything R10, R11 and R13 settled', () => {it('Add Provider still labels the backend it pushed out STANDBY', () => {const pane = read('src/components/settings/ProviderConfig.tsx')expect(pane).toMatch(/took over the local OpenAI compatible slot/)- expect(standbyOccupant(JAN_IN_SLOT)?.name).toBe('Built-in Engine')+ expect(standbyOccupant(JAN_IN_SLOT)?.name).toBe('LU Engine')expect(standbyOccupant(JAN_IN_SLOT)?.disabledByUser).toBeUndefined()})diff --git a/src/lib/__tests__/g20-builtin-return-path.test.ts b/src/lib/__tests__/g20-builtin-return-path.test.tsindex 1069894c..7b9c312e 100644--- a/src/lib/__tests__/g20-builtin-return-path.test.ts+++ b/src/lib/__tests__/g20-builtin-return-path.test.ts@@ -32,7 +32,7 @@ describe('resetProvidersToDefaults hands the slot back to the Built-in Engine',it('restores the shipped Built-in slot', () => {useProviderStore.getState().resetProvidersToDefaults()const openai = useProviderStore.getState().providers.openai- expect(openai.name).toBe('Built-in Engine')+ expect(openai.name).toBe('LU Engine')expect(openai.managed).toBe(true)expect(openai.enabled).toBe(true)expect(openai.baseUrl).toBe('http://127.0.0.1:8127/v1')diff --git a/src/lib/__tests__/lmstudio-backend-adopt.test.ts b/src/lib/__tests__/lmstudio-backend-adopt.test.tsindex 8c4c1644..3345bf30 100644--- a/src/lib/__tests__/lmstudio-backend-adopt.test.ts+++ b/src/lib/__tests__/lmstudio-backend-adopt.test.ts@@ -117,9 +117,9 @@ describe('ModelSelector LM Studio banner', () => {expect(refetch).toBeGreaterThan(adopt)})- it('says out loud that the built-in engine loses the slot, and names the way back', () => {+ it('says out loud that the LU Engine loses the slot, and names the way back', () => {expect(src).toContain('adoptionReplacesBuiltinEngine')- expect(src).toMatch(/This also makes LM Studio your local chat backend in place of the built-in engine/)+ expect(src).toMatch(/This also makes LM Studio your local chat backend in place of the LU Engine/)expect(src).toMatch(/Settings, AI Backends, Providers/)})})diff --git a/src/lib/__tests__/lu-engine-name.test.ts b/src/lib/__tests__/lu-engine-name.test.tsnew file mode 100644index 00000000..4c0c5765--- /dev/null+++ b/src/lib/__tests__/lu-engine-name.test.ts@@ -0,0 +1,174 @@+/**+ * A14 (2.6.8): the app-managed llama-server sidecar shipped as "Built-in+ * Engine" and is called "LU Engine" from now on.+ *+ * The rename is only a label, so the risk is not that the new name is wrong+ * anywhere. It is that the OLD name is still on disk: every `lu-providers`+ * blob written by 2.5.7 through 2.6.7 carries it on the openai slot, and a+ * second copy of it in the `displaced` memory when another backend pushed the+ * engine aside. Two things therefore have to hold at once, and both are pinned+ * here:+ *+ * 1. everything that ASKS "is this the app's own engine" answers yes to both+ * names, so an old store does not lose its VRAM handling or its INSTALLED+ * badges the moment it is opened by 2.6.8,+ * 2. everything the user READS says LU Engine, including the card drawn from+ * that old store.+ *+ * The negative controls are the reason the matcher is a substring test and not+ * a free-for-all: a backend the user named himself must survive both.+ */++import { describe, it, expect, vi, beforeEach, afterEach } from 'vitest'+import { LU_ENGINE_NAME, LEGACY_ENGINE_NAME, isLuEngineName, renameLegacyEngine } from '../engine-name'+import { isBuiltinEngineEntry } from '../lmstudio-match'++vi.mock('../../api/providers/registry', () => ({ clearProviderCache: vi.fn() }))+vi.mock('../../api/backend', () => ({+ secretGet: vi.fn().mockRejectedValue(new Error('no vault')),+ secretSet: vi.fn(),+ secretDelete: vi.fn(),+ isTauri: () => false,+ backendCall: vi.fn(),+}))++describe('the name itself', () => {+ it('is the one the user reads', () => {+ expect(LU_ENGINE_NAME).toBe('LU Engine')+ expect(LEGACY_ENGINE_NAME).toBe('Built-in Engine')+ })+})++describe('isLuEngineName answers for both names', () => {+ it('the new one', () => {+ expect(isLuEngineName('LU Engine')).toBe(true)+ expect(isLuEngineName('lu engine')).toBe(true)+ })++ it('the one still sitting in every store written before 2.6.8', () => {+ expect(isLuEngineName('Built-in Engine')).toBe(true)+ expect(isLuEngineName('built-in engine')).toBe(true)+ expect(isLuEngineName('Built in Engine')).toBe(true)+ })++ // NEGATIVE CONTROL. A matcher that says yes to everything would make every+ // test above pass and would stop the LM Studio slot from ever being told+ // apart from ours, which is the switch modelStore hangs the VRAM eviction on.+ it('and to nothing else', () => {+ for (const other of ['Ollama', 'LM Studio', 'LU Cloud', 'Anthropic', 'Jan', 'llama.cpp', 'vLLM', '', null, undefined]) {+ expect(isLuEngineName(other), `${other}`).toBe(false)+ }+ })+})++describe('the INSTALLED badge reads a row under either name', () => {+ const row = (providerName: string) => ({ provider: 'openai', providerName, model: 'qwen2.5-0.5b-instruct-q8_0' })++ it('a row stamped by 2.6.8', () => {+ expect(isBuiltinEngineEntry(row(LU_ENGINE_NAME))).toBe(true)+ })++ it('a row recorded by an older version and still in the chat', () => {+ expect(isBuiltinEngineEntry(row(LEGACY_ENGINE_NAME))).toBe(true)+ })++ // NEGATIVE CONTROL: an LM Studio row shares provider 'openai' with ours and+ // must not be sent through the engine repair on a Use press.+ it('but never an LM Studio row, which shares the openai provider id', () => {+ expect(isBuiltinEngineEntry(row('LM Studio'))).toBe(false)+ expect(isBuiltinEngineEntry({ provider: 'ollama', providerName: LU_ENGINE_NAME })).toBe(false)+ })+})++describe('renameLegacyEngine relabels only the shipped name', () => {+ it('swaps the old label for the new one', () => {+ expect(renameLegacyEngine({ name: 'Built-in Engine', baseUrl: 'x' })).toEqual({ name: 'LU Engine', baseUrl: 'x' })+ })++ it('leaves a config that already carries the new name alone, object identity included', () => {+ const cfg = { name: 'LU Engine' }+ expect(renameLegacyEngine(cfg)).toBe(cfg)+ })++ // NEGATIVE CONTROL: the user's own backend keeps the name he typed. A blanket+ // rename would take it from him on the first launch after the update.+ it('never touches a backend the user named himself', () => {+ for (const name of ['Jan', 'My built-in box', 'Ollama', 'LM Studio']) {+ expect(renameLegacyEngine({ name }).name, name).toBe(name)+ }+ })+})++// ── The store the user actually has on disk ──────────────────────────────────++function installLocalStorage(seed?: Record<string, string>) {+ const map = new Map<string, string>(Object.entries(seed ?? {}))+ const ls = {+ getItem: (k: string) => (map.has(k) ? map.get(k)! : null),+ setItem: (k: string, v: string) => { map.set(k, String(v)) },+ removeItem: (k: string) => { map.delete(k) },+ clear: () => { map.clear() },+ key: (i: number) => [...map.keys()][i] ?? null,+ get length() { return map.size },+ }+ vi.stubGlobal('localStorage', ls)+ vi.stubGlobal('window', { localStorage: ls })+}++async function freshStore() {+ vi.resetModules()+ const mod = await import('../../stores/providerStore')+ return mod.useProviderStore+}++describe('a store written before the rename opens under the new name', () => {+ afterEach(() => { vi.unstubAllGlobals() })+ beforeEach(() => { vi.resetModules() })++ it('the openai slot the engine holds is relabelled', async () => {+ installLocalStorage({+ 'lu-providers': JSON.stringify({+ version: 1,+ state: {+ providers: {+ openai: { id: 'openai', name: 'Built-in Engine', enabled: true, baseUrl: 'http://127.0.0.1:8127/v1', apiKey: '', isLocal: true, managed: true },+ },+ },+ }),+ })+ const store = await freshStore()+ expect(store.getState().providers.openai.name).toBe('LU Engine')+ // The rename must not switch the engine off or hand the slot away.+ expect(store.getState().providers.openai.enabled).toBe(true)+ expect(store.getState().providers.openai.managed).toBe(true)+ })++ it('and so is the standby card it left behind when another backend took the slot', async () => {+ installLocalStorage({+ 'lu-providers': JSON.stringify({+ version: 1,+ state: {+ providers: {+ openai: {+ id: 'openai', name: 'Jan', enabled: true, baseUrl: 'http://localhost:1337/v1', apiKey: '', isLocal: true, managed: false,+ displaced: { name: 'Built-in Engine', baseUrl: 'http://127.0.0.1:8127/v1', isLocal: true, managed: true },+ },+ },+ },+ }),+ })+ const store = await freshStore()+ const slot = store.getState().providers.openai+ // NEGATIVE CONTROL in the same frame: Jan is the user's own entry and keeps+ // its name, while the card it owes now says LU Engine.+ expect(slot.name).toBe('Jan')+ expect(slot.displaced?.name).toBe('LU Engine')+ expect(slot.displaced?.managed).toBe(true)+ })++ it('a fresh install starts on the new name too', async () => {+ installLocalStorage()+ const store = await freshStore()+ expect(store.getState().providers.openai.name).toBe('LU Engine')+ })+})diff --git a/src/lib/builtin-model-identity.ts b/src/lib/builtin-model-identity.tsindex 145767a2..40f0022d 100644--- a/src/lib/builtin-model-identity.ts+++ b/src/lib/builtin-model-identity.ts@@ -87,7 +87,7 @@ export function builtinModelMatches(*/export function builtinModelMismatchMessage(loadedName: string, requestedName: string): string {return (- `The built-in engine has "${loadedName}" loaded, but this request asked for "${requestedName}". ` ++ `The LU Engine has "${loadedName}" loaded, but this request asked for "${requestedName}". ` +'The engine serves only the model it was started with, so answering would have used the wrong model. ' +`Install or pick "${requestedName}" in Models and send again.`)diff --git a/src/lib/engine-name.ts b/src/lib/engine-name.tsnew file mode 100644index 00000000..9d26af39--- /dev/null+++ b/src/lib/engine-name.ts@@ -0,0 +1,43 @@+/**+ * What the user calls the app-managed llama-server sidecar.+ *+ * 2.6.8 (A14): it shipped as "Built-in Engine" from 2.5.7 on and is called+ * "LU Engine" from now on. Only the label moved. Every internal identifier+ * stays: the provider slot is still `openai`, the preset id is still+ * `builtin`, the Tauri commands are still `*_bundled_engine`.+ *+ * Two names therefore exist in the wild at once. The old one is written into+ * `lu-providers` on every machine that ran an earlier version, into the+ * `displaced` memory of the openai slot, and into chats that recorded which+ * backend answered. So the app WRITES the new name and READS both.+ */++/** The name written into every new provider config and model row. */+export const LU_ENGINE_NAME = 'LU Engine'++/** The name written by 2.5.7 through 2.6.7. Still on disk, never written again. */+export const LEGACY_ENGINE_NAME = 'Built-in Engine'++/**+ * True when a provider or model row names the app-managed engine, under+ * either its current or its former name.+ *+ * Substring, not equality: `bundledToAIModels` and the provider presets both+ * stamp the bare name, but a persisted row can carry a suffix, and the pre-2.6.8+ * matcher this replaces was a substring test too.+ */+export function isLuEngineName(name: string | null | undefined): boolean {+ const n = (name || '').toLowerCase()+ return n.includes('lu engine') || n.includes('built-in engine') || n.includes('built in engine')+}++/**+ * The same name with the old label swapped for the new one, for configs that+ * were persisted before the rename. Anything else is returned untouched, so a+ * backend the user named himself keeps his name.+ */+export function renameLegacyEngine<T extends { name?: string }>(config: T): T {+ if (!config || typeof config.name !== 'string') return config+ if (config.name.trim().toLowerCase() !== LEGACY_ENGINE_NAME.toLowerCase()) return config+ return { ...config, name: LU_ENGINE_NAME }+}diff --git a/src/lib/lmstudio-match.ts b/src/lib/lmstudio-match.tsindex 9208338d..07464e64 100644--- a/src/lib/lmstudio-match.ts+++ b/src/lib/lmstudio-match.ts@@ -18,6 +18,8 @@// missing one, and would otherwise wrongly mark every quant sibling of a model// (e.g. all 7 "Qwen 3.6 27B" rows) as installed from a single download.+import { isLuEngineName } from './engine-name'+export interface InstalledModelLike {provider?: stringproviderName?: string@@ -71,13 +73,14 @@ function isLmStudioEntry(m: InstalledModelLike): boolean {}/**- * A built-in-engine entry. `bundledToAIModels` stamps every downloaded GGUF- * with `provider: 'openai'` and `providerName: 'Built-in Engine'`, and its- * `model` is the file stem, so the same filename matcher fits it exactly.+ * An LU Engine entry. `bundledToAIModels` stamps every downloaded GGUF with+ * `provider: 'openai'` and `providerName: 'LU Engine'` ('Built-in Engine'+ * before 2.6.8, still on disk in older chats), and its `model` is the file+ * stem, so the same filename matcher fits it exactly.*/export function isBuiltinEngineEntry(m: InstalledModelLike | null | undefined): boolean {if (!m || m.provider !== 'openai') return false- return (m.providerName || '').toLowerCase().includes('built-in engine')+ return isLuEngineName(m.providerName)}/**diff --git a/src/lib/release-notes.ts b/src/lib/release-notes.tsindex 1381c992..6514c6fe 100644--- a/src/lib/release-notes.ts+++ b/src/lib/release-notes.ts@@ -38,7 +38,7 @@ export const RELEASE_NOTES: ReleaseNote[] = ['Reasoning models carry an effort control next to the Think button. Low, Medium or High, and Max on GLM 5.3, decides how many tokens a reply may spend on thinking.','GLM 5.3 (Pro) and GLM 5.3 Flash (Hosted) are in the cloud catalogue, and the cloud model list keeps one fixed order, so a new chat starts on the same model every time instead of a different one on each load.','The side panel folds away, and while it is closed your latest chats sit on the main screen. The note about which model wrote the chat you are reading is a quiet dot on the model picker now instead of a chip in the composer.',- 'The built-in engine moves to a free port when 8127 is taken, and a chat model you downloaded stays visible as Installed with a Use button that starts the engine for it.',+ 'The built-in engine is called LU Engine from now on. It moves to a free port when 8127 is taken, and a chat model you downloaded stays visible as Installed with a Use button that starts the engine for it.','AMD on Windows is read from the HIP SDK, the Linux packages name the libraries they need, the ComfyUI installer proves its own environment, your own model folder is read, Document Chat works in Cloud mode, and the prompt history in Create can be cleared.',],details: [@@ -47,7 +47,8 @@ export const RELEASE_NOTES: ReleaseNote[] = [items: ['The side panel folds away. While it is closed your latest chats sit on the main screen, and they belong to the panel again the moment you open it.','What the open chat actually ran on stopped taking a chip of its own in the composer row. It is a small dot on the corner of the model picker now, with the full sentence in the picker\'s tooltip, and it is only there when the chat on screen and the pick beside it disagree.',- 'The built-in engine moves to a free port when 8127 is taken or reserved by the system, and it retries the start once after a failure instead of giving up until the next restart. Windows port reservations are marked as researched rather than proven, because no such reservation could be staged here.',+ 'The built-in engine is called LU Engine from now on. Same engine, same models, same folder; only the name in Settings, in the model list and in the messages changed.',+ 'The LU Engine moves to a free port when 8127 is taken or reserved by the system, and it retries the start once after a failure instead of giving up until the next restart. Windows port reservations are marked as researched rather than proven, because no such reservation could be staged here.','A chat model you downloaded stays visible as Installed even while the engine is not running, and its tile carries a Use button that starts the engine and loads that model, instead of showing you a file you cannot reach.','The ComfyUI installer proves that the environment it just built can really import ComfyUI, installs back what is missing, and names a missing Visual C++ runtime instead of ending in a silent crash.','Repair environment runs the same check with a time limit and a Cancel that really cancels, and the trainer setup stopped blaming the network for failures that were never about the network.',@@ -56,10 +57,10 @@ export const RELEASE_NOTES: ReleaseNote[] = ['The CivitAI API key has a field again, under Settings, AI Backends, Model Storage. Downloads from the CivitAI search carry the key, and a download CivitAI refuses names the missing setting instead of a bare error number.','AMD on Windows is read from the HIP SDK itself. The only ROCm probe ran rocm-smi, which the Windows SDK does not ship, so an installed ROCm went unseen; LU reads HIP_PATH and hipinfo now and names the card\'s architecture, and an image run that fails names that architecture and get_arch_list instead of a HIP traceback. It is marked as researched rather than proven, because there is no RDNA4 card here.','The Model Manager stopped putting system RAM in the GPU field. ComfyUI reports system memory on a CPU device in a field called vram_total, so a machine with 64 GB of RAM read as if it had 62 GB of video memory.',- 'The Linux packages ask for the libraries the built-in engine links against. The deb and the rpm named the desktop libraries but not libvulkan1 and libgomp1, so on a machine without them the install went through, the engine then died in the loader, and the message blamed your graphics card. The missing library is named now, together with the command that installs it. If you run the AppImage instead, it needs the Vulkan loader (libvulkan1) from your system, because an AppImage cannot carry that one itself.',+ 'The Linux packages ask for the libraries the LU Engine links against. The deb and the rpm named the desktop libraries but not libvulkan1 and libgomp1, so on a machine without them the install went through, the engine then died in the loader, and the message blamed your graphics card. The missing library is named now, together with the command that installs it. If you run the AppImage instead, it needs the Vulkan loader (libvulkan1) from your system, because an AppImage cannot carry that one itself.','The Coding Agent\'s working directory can be removed again. There is a Remove button beside the folder picker and one in the header, both are locked while a run is going, and picking a different folder moves the current chat over to it.','The prompt history in Create can be cleared. Every entry has its own remove button, and Clear all at the top of the list wipes the lot after a second click.',- 'Settings shows the port the built-in engine really runs on, the Model Storage folder says when it could not be read or was too big to scan, and a ComfyUI install or repair can be cancelled from Settings and keeps showing its progress while you look at other settings.',+ 'Settings shows the port the LU Engine really runs on, the Model Storage folder says when it could not be read or was too big to scan, and a ComfyUI install or repair can be cancelled from Settings and keeps showing its progress while you look at other settings.','On the Mac, LU stopped searching your whole home folder for a ComfyUI it never runs there. That search touched the Desktop and Music folders, so macOS asked for access to Apple Music and to the Desktop at first launch, and the window sat on LOADING while the search ran. On Windows and Linux the same search moved off the main thread, so a slow disk no longer freezes the window.',],},diff --git a/src/stores/__tests__/releaseNotesStore.test.ts b/src/stores/__tests__/releaseNotesStore.test.tsindex 48cb41bf..4ae3b32b 100644--- a/src/stores/__tests__/releaseNotesStore.test.ts+++ b/src/stores/__tests__/releaseNotesStore.test.ts@@ -62,7 +62,7 @@ describe('the notes table', () => {// green while the branch moves on, so the shipping note is pinned to the// headline features of the release it ships with. For 2.6.8 those are the// effort control on reasoning models, GLM 5.3 in the cloud catalogue, the- // engine that steps off a taken 8127, the model that stays Installed, the+ // built-in engine renamed to LU Engine, the engine that steps off a taken 8127, the model that stays Installed, the// ComfyUI installer that repairs its own environment, the model folder// that is finally read, the CivitAI key field, the HIP SDK on Windows with// its vram_total mix-up, the Linux packages that name libvulkan1, the@@ -83,7 +83,7 @@ describe('the notes table', () => {.join('\n').toLowerCase()for (const anchor of [- 'effort', 'glm 5.3', 'installed', 'built-in engine', '8127',+ 'effort', 'glm 5.3', 'installed', 'lu engine', '8127','repair environment', 'model storage', 'civitai', 'hip sdk','vram_total', 'libvulkan1', 'working directory', 'document chat','prompt history', 'side panel', 'researched rather than proven', 'apple music', 'too big to scan',diff --git a/src/stores/modelStore.ts b/src/stores/modelStore.tsindex 02579c63..83d1ba31 100644--- a/src/stores/modelStore.ts+++ b/src/stores/modelStore.ts@@ -8,6 +8,7 @@ import { isLmStudioProvider } from '../lib/hf-to-provider'import { isTauri, backendCall } from '../api/backend'import { useChatStore } from './chatStore'import { log } from '../lib/logger'+import { isLuEngineName } from '../lib/engine-name'export interface PullState {progress: PullProgress@@ -139,14 +140,15 @@ export const useModelStore = create<ModelState>()(const prevIsLms = isLmStudioProvider((prevModel && 'providerName' in prevModel && prevModel.providerName) as string | undefined,)- // The built-in engine (llama.cpp sidecar) occupies the `openai::` slot- // with providerName 'Built-in Engine' and holds its GGUF in VRAM with+ // The LU Engine (llama.cpp sidecar) occupies the `openai::` slot+ // with providerName 'LU Engine' ('Built-in Engine' before 2.6.8, still+ // on disk in older chats) and holds its GGUF in VRAM with// -ngl 999. It is NOT caught by the LM-Studio or the bare-Ollama branch// below, so before 2.5.7 wired this in, switching away from a built-in// model to an Ollama/LM-Studio model left the sidecar resident → two// models in VRAM at once (the exact case this guard exists to prevent).const prevIsBuiltin =- !!prevModel && 'providerName' in prevModel && prevModel.providerName === 'Built-in Engine'+ !!prevModel && 'providerName' in prevModel && isLuEngineName(prevModel.providerName)if (prevIsLms) {const bareKey = prev.replace(/^[^:]+::/, '') // strip LU's routing prefixunloadLmStudioModel(bareKey).catch((e) =>@@ -155,7 +157,7 @@ export const useModelStore = create<ModelState>()(} else if (prevIsBuiltin) {const nextModel = get().models.find((m) => m.name === name)const nextIsBuiltin =- !!nextModel && 'providerName' in nextModel && nextModel.providerName === 'Built-in Engine'+ !!nextModel && 'providerName' in nextModel && isLuEngineName(nextModel.providerName)if (!nextIsBuiltin) {backendCall('stop_bundled_engine').catch((e) =>log.warn('[modelStore] failed to stop built-in engine on switch-away', { err: e }),diff --git a/src/stores/providerStore.ts b/src/stores/providerStore.tsindex fcc7dd26..da14be2d 100644--- a/src/stores/providerStore.ts+++ b/src/stores/providerStore.ts@@ -10,6 +10,7 @@ import { persist } from 'zustand/middleware'import type { ProviderId, ProviderConfig } from '../api/providers/types'import { clearProviderCache } from '../api/providers/registry'import { onLocalSlotChanged } from '../lib/builtin-slot-eviction'+import { LU_ENGINE_NAME, renameLegacyEngine } from '../lib/engine-name'import { secretGet, secretSet, secretDelete } from '../api/backend'import { CLOUD_BASE } from '../api/cloud/config'@@ -71,7 +72,7 @@ const DEFAULT_PROVIDERS: Record<ProviderId, ProviderConfig> = {},openai: {id: 'openai',- name: 'Built-in Engine',+ name: LU_ENGINE_NAME,enabled: true,baseUrl: 'http://127.0.0.1:8127/v1',apiKey: '',@@ -281,10 +282,24 @@ export const useProviderStore = create<ProviderState>()(// hit an undefined config after an update.merge: (persisted: unknown, current: ProviderState): ProviderState => {const p = (persisted ?? {}) as Partial<ProviderState>+ const merged = { ...DEFAULT_PROVIDERS, ...(p.providers ?? {}) }+ // 2.6.8 (A14): every store written before the rename carries the label+ // "Built-in Engine" on the openai slot, and a second copy of it in the+ // `displaced` memory when another backend pushed the engine aside. Both+ // are what the provider card and the standby card print, so both are+ // relabelled here. Only that exact name is touched, so a backend the+ // user named himself is left alone.+ for (const id of Object.keys(merged) as ProviderId[]) {+ const cfg = renameLegacyEngine(merged[id])+ const displaced = cfg.displaced ? renameLegacyEngine(cfg.displaced) : undefined+ if (cfg !== merged[id] || displaced !== cfg.displaced) {+ merged[id] = displaced ? { ...cfg, displaced } : cfg+ }+ }return {...current,...p,- providers: { ...DEFAULT_PROVIDERS, ...(p.providers ?? {}) },+ providers: merged,}},// Don't persist transient state, only configs + user's "don't show again" preference.