diff --git a/bin/lib/nim.js b/bin/lib/nim.js index b735dff9632..64c074dad79 100644 --- a/bin/lib/nim.js +++ b/bin/lib/nim.js @@ -35,12 +35,14 @@ function detectGpu() { const perGpuMB = lines.map((l) => parseInt(l.trim(), 10)).filter((n) => !isNaN(n)); if (perGpuMB.length > 0) { const totalMemoryMB = perGpuMB.reduce((a, b) => a + b, 0); + // Only mark nimCapable if at least one NIM model fits in GPU VRAM + const canRunNim = nimImages.models.some((m) => m.minGpuMemoryMB <= totalMemoryMB); return { type: "nvidia", count: perGpuMB.length, totalMemoryMB, perGpuMB: perGpuMB[0], - nimCapable: true, + nimCapable: canRunNim, }; } } diff --git a/bin/lib/onboard.js b/bin/lib/onboard.js index c440cb9b75a..3c7b7f972f6 100644 --- a/bin/lib/onboard.js +++ b/bin/lib/onboard.js @@ -1587,6 +1587,9 @@ async function preflight() { const gpu = nim.detectGpu(); if (gpu && gpu.type === "nvidia") { console.log(` ✓ NVIDIA GPU detected: ${gpu.count} GPU(s), ${gpu.totalMemoryMB} MB VRAM`); + if (!gpu.nimCapable) { + console.log(" ⓘ GPU VRAM too small for local NIM — will use cloud inference"); + } } else if (gpu && gpu.type === "apple") { console.log(` ✓ Apple GPU detected: ${gpu.name}${gpu.cores ? ` (${gpu.cores} cores)` : ""}, ${gpu.totalMemoryMB} MB unified memory`); console.log(" ⓘ NIM requires NVIDIA GPU — will use cloud inference");