diff --git a/configuration.nix b/configuration.nix index b7f757f..bedf377 100644 --- a/configuration.nix +++ b/configuration.nix @@ -17,6 +17,7 @@ ./modules/security.nix ./modules/power.nix ./modules/xray.nix + ./modules/ollama.nix ./modules/gaming.nix ]; diff --git a/modules/ollama.nix b/modules/ollama.nix new file mode 100644 index 0000000..e031953 --- /dev/null +++ b/modules/ollama.nix @@ -0,0 +1,17 @@ +{ config, pkgs, lib, ... }: + +{ + services.ollama = { + enable = true; + package = pkgs.ollama-rocm; + rocmOverrideGfx = "11.5.1"; # gfx1151, Krackan Point RDNA 3.5 + host = "127.0.0.1"; + port = 11434; + environmentVariables = { + HSA_OVERRIDE_GFX_VERSION = "11.5.1"; + OLLAMA_FLASH_ATTENTION = "1"; + OLLAMA_KV_CACHE_TYPE = "q8_0"; + }; + loadModels = [ "qwen3:14b" ]; + }; +}