Get up and running with Kimi, GLM, MiniMax, DeepSeek, gpt-oss, Qwen, Gemma and other models.
Fall back to CPU runner with zero layers
Daniel Hiltgenc4014e73a254
diff --git a/llm/server.go b/llm/server.goindex 81a2dec4b..33c56f1fa 100644--- a/llm/server.go+++ b/llm/server.go@@ -105,6 +105,10 @@ func NewLlamaServer(gpus gpu.GpuInfoList, model string, ggml *GGML, adapters, pr// disable partial offloading when model is greater than total system memory as this// can lead to locking up the systemopts.NumGPU = 0+ } else if gpus[0].Library != "metal" && layers == 0 {+ // Don't bother loading into the GPU if no layers can fit+ cpuRunner = serverForCpu()+ gpuCount = 0} else if opts.NumGPU < 0 && layers > 0 && gpus[0].Library != "cpu" {opts.NumGPU = layers}