From 27343e49bd387c868484d810680c04da7095423b Mon Sep 17 00:00:00 2001 From: Harald Hoyer Date: Tue, 24 Feb 2026 13:16:28 +0100 Subject: [PATCH] feat(halo): add wyoming whisper-cpp --- flake.lock | 97 +++++++++++++++++---------- flake.nix | 5 ++ systems/x86_64-linux/halo/default.nix | 3 +- systems/x86_64-linux/halo/wyoming.nix | 18 ++--- 4 files changed, 77 insertions(+), 46 deletions(-) diff --git a/flake.lock b/flake.lock index 2308d2f..bfd3257 100644 --- a/flake.lock +++ b/flake.lock @@ -134,11 +134,11 @@ ] }, "locked": { - "lastModified": 1771271879, - "narHash": "sha256-Vn32sMuvV35ChjVGZE4d8NNmCq3E/6HjaK2uVUUp2JI=", + "lastModified": 1771881364, + "narHash": "sha256-A5uE/hMium5of/QGC6JwF5TGoDAfpNtW00T0s9u/PN8=", "owner": "nix-community", "repo": "disko", - "rev": "e963ed5aea88ad0c093adde7c1c2abd4e1b48beb", + "rev": "a4cb7bf73f264d40560ba527f9280469f1f081c6", "type": "github" }, "original": { @@ -421,11 +421,11 @@ ] }, "locked": { - "lastModified": 1770260404, - "narHash": "sha256-3iVX1+7YUIt23hBx1WZsUllhbmP2EnXrV8tCRbLxHc8=", + "lastModified": 1771744638, + "narHash": "sha256-EDLi+YAsEEAmMeZe1v6GccuGRbCkpSZp/+A6g+pivR8=", "owner": "nix-community", "repo": "home-manager", - "rev": "0d782ee42c86b196acff08acfbf41bb7d13eed5b", + "rev": "cb6c151f5c9db4df0b69d06894dc8484de1f16a0", "type": "github" }, "original": { @@ -454,11 +454,11 @@ "homebrew-cask": { "flake": false, "locked": { - "lastModified": 1771313187, - "narHash": "sha256-RF3Jx1nAyD94Jufz90qblm/KYe15LatnnjbOQKTHs1U=", + "lastModified": 1771930958, + "narHash": "sha256-zBtDtRcxybQEjU8y78yJKkbR6d7cqGfJ61ViMRBkpms=", "owner": "homebrew", "repo": "homebrew-cask", - "rev": "3f0fda390d44101a1792b96cba02014569ced3ce", + "rev": "fd5e7e135005fb061698d1779bcbd0d4e9437533", "type": "github" }, "original": { @@ -470,11 +470,11 @@ "homebrew-core": { "flake": false, "locked": { - "lastModified": 1771312699, - "narHash": "sha256-FTbzApUo095tqEHn0b0+fBszbZLbj7dUcPit8R3RIQc=", + "lastModified": 1771925002, + "narHash": "sha256-dSOf3M6JQUyNhQOe1SR9+gSFmHYKITOSNoyX0/wkcpI=", "owner": "homebrew", "repo": "homebrew-core", - "rev": "9aae24112446dee878eff78fc2a0d57b68c5d46d", + "rev": "1107dda23bba93d0ebd0d8035db6a1d84424977c", "type": "github" }, "original": { @@ -562,11 +562,11 @@ "systems": "systems_2" }, "locked": { - "lastModified": 1771274219, - "narHash": "sha256-n7CZAK+mTko+y3SSwvFt49AD1RNLY2KcHypcoly8HVc=", + "lastModified": 1771903194, + "narHash": "sha256-VpDCSVIwiHdcezsksOTnRmqPqpkssGRi4wMsA+46dvc=", "owner": "NotAShelf", "repo": "nvf", - "rev": "99bf160aaef28d47f1818deffe662ce1c4d6e6a1", + "rev": "d07d8f62f03a313cfcf55feb3797e4cbda8d08a5", "type": "github" }, "original": { @@ -595,11 +595,11 @@ }, "nixos-hardware": { "locked": { - "lastModified": 1771257191, - "narHash": "sha256-H1l+zHq+ZinWH7F1IidpJ2farmbfHXjaxAm1RKWE1KI=", + "lastModified": 1771423359, + "narHash": "sha256-yRKJ7gpVmXbX2ZcA8nFi6CMPkJXZGjie2unsiMzj3Ig=", "owner": "NixOS", "repo": "nixos-hardware", - "rev": "66e1a090ded57a0f88e2b381a7d4daf4a5722c3f", + "rev": "740a22363033e9f1bb6270fbfb5a9574067af15b", "type": "github" }, "original": { @@ -642,11 +642,11 @@ }, "nixpkgs_2": { "locked": { - "lastModified": 1771208521, - "narHash": "sha256-X01Q3DgSpjeBpapoGA4rzKOn25qdKxbPnxHeMLNoHTU=", + "lastModified": 1771714954, + "narHash": "sha256-nhZJPnBavtu40/L2aqpljrfUNb2rxmWTmSjK2c9UKds=", "owner": "nixos", "repo": "nixpkgs", - "rev": "fa56d7d6de78f5a7f997b0ea2bc6efd5868ad9e8", + "rev": "afbbf774e2087c3d734266c22f96fca2e78d3620", "type": "github" }, "original": { @@ -720,6 +720,7 @@ "sops-nix": "sops-nix", "ssh-tresor": "ssh-tresor", "unstable": "unstable", + "wyoming-whisper-rs": "wyoming-whisper-rs", "xremap-flake": "xremap-flake" } }, @@ -748,11 +749,11 @@ ] }, "locked": { - "lastModified": 1771297684, - "narHash": "sha256-wieWskQxZLPlNXX06JEB0bMoS/ZYQ89xBzF0RL9lyLs=", + "lastModified": 1771902481, + "narHash": "sha256-svI5ivzggtu4KhCdoab3xR5+Btop24o7yLFtIPXrsPM=", "owner": "oxalica", "repo": "rust-overlay", - "rev": "755d3669699a7c62aef35af187d75dc2728cfd85", + "rev": "5177426d9f8f7f1827001c9749b9a9c5570d456b", "type": "github" }, "original": { @@ -835,11 +836,11 @@ ] }, "locked": { - "lastModified": 1771166946, - "narHash": "sha256-UFc4lfGBr+wJmwgDGJDn1cVD6DTr0/8TdronNUiyXlU=", + "lastModified": 1771889317, + "narHash": "sha256-YV17Q5lEU0S9ppw08Y+cs4eEQJBuc79AzblFoHORLMU=", "owner": "Mic92", "repo": "sops-nix", - "rev": "2d0cf89b4404529778bc82de7e42b5754e0fe4fa", + "rev": "b027513c32e5b39b59f64626b87fbe168ae02094", "type": "github" }, "original": { @@ -932,11 +933,11 @@ }, "unstable": { "locked": { - "lastModified": 1771008912, - "narHash": "sha256-gf2AmWVTs8lEq7z/3ZAsgnZDhWIckkb+ZnAo5RzSxJg=", + "lastModified": 1771848320, + "narHash": "sha256-0MAd+0mun3K/Ns8JATeHT1sX28faLII5hVLq0L3BdZU=", "owner": "nixos", "repo": "nixpkgs", - "rev": "a82ccc39b39b621151d6732718e3e250109076fa", + "rev": "2fc6539b481e1d2569f25f8799236694180c0993", "type": "github" }, "original": { @@ -946,19 +947,41 @@ "type": "github" } }, + "wyoming-whisper-rs": { + "inputs": { + "nixpkgs": [ + "nixpkgs" + ] + }, + "locked": { + "lastModified": 1771931733, + "narHash": "sha256-OFryC+AHy2aM0CUTaZGDdG5+l+9fJpfEllBjl3cXoLs=", + "ref": "refs/heads/main", + "rev": "7d88c8c865ac3973646ad88aafb74180fb73eb2e", + "revCount": 531, + "submodules": true, + "type": "git", + "url": "https://git.hoyer.xyz/harald/wyoming-whisper-rs.git" + }, + "original": { + "submodules": true, + "type": "git", + "url": "https://git.hoyer.xyz/harald/wyoming-whisper-rs.git" + } + }, "xremap": { "flake": false, "locked": { - "lastModified": 1769021727, - "narHash": "sha256-2wylBk3+Zu1pHa41dhKwvUtxOVyHSMRDfOD9fIp8x2I=", + "lastModified": 1771004903, + "narHash": "sha256-9umUL90VpQUzOvCKh4bqsF0WgvYOa3WqIDRCeZV7Vyw=", "owner": "k0kubun", "repo": "xremap", - "rev": "890e0a6ca92e90f3bcbd1e235abcf2192e233a46", + "rev": "7dcea528a63d6fcd73b84ae0fa090520f2168ba9", "type": "github" }, "original": { "owner": "k0kubun", - "ref": "v0.14.10", + "ref": "v0.14.14", "repo": "xremap", "type": "github" } @@ -971,11 +994,11 @@ "xremap": "xremap" }, "locked": { - "lastModified": 1769636170, - "narHash": "sha256-X000Dgg053Dv9NIzm1b9QYSAHYtW2jHMVALQezui7L0=", + "lastModified": 1771345374, + "narHash": "sha256-HE6EO16c5xuqaCLyr8yVhy1Ety82ZtF242AuP1XPROM=", "owner": "xremap", "repo": "nix-flake", - "rev": "00bc6dd4275d4b003a17ef7f5f271ba87f73d698", + "rev": "9c06507672406ce417035a6955d2a1cfc1142c5a", "type": "github" }, "original": { diff --git a/flake.nix b/flake.nix index 3456e24..0c14edd 100644 --- a/flake.nix +++ b/flake.nix @@ -72,6 +72,9 @@ ssh-tresor.url = "github:haraldh/ssh-tresor"; ssh-tresor.inputs.nixpkgs.follows = "nixpkgs"; + + wyoming-whisper-rs.url = "git+https://git.hoyer.xyz/harald/wyoming-whisper-rs.git?submodules=1"; + wyoming-whisper-rs.inputs.nixpkgs.follows = "nixpkgs"; }; outputs = @@ -107,6 +110,7 @@ simple-nixos-mailserver.nixosModule cratedocs.nixosModules.default xremap-flake.nixosModules.default + wyoming-whisper-rs.nixosModules.default ]; overlays = with inputs; [ @@ -117,6 +121,7 @@ inherit (cratedocs.packages.${prev.stdenv.hostPlatform.system}) cratedocs-mcp; }) ssh-tresor.overlays.default + wyoming-whisper-rs.overlays.default ]; outputs-builder = channels: { diff --git a/systems/x86_64-linux/halo/default.nix b/systems/x86_64-linux/halo/default.nix index 5e53620..a0fea7f 100644 --- a/systems/x86_64-linux/halo/default.nix +++ b/systems/x86_64-linux/halo/default.nix @@ -8,7 +8,8 @@ with lib.metacfg; { imports = [ ./hardware-configuration.nix - ./xremap.nix + #./xremap.nix + ./wyoming.nix ]; boot.lanzaboote.pkiBundle = "/var/lib/sbctl"; diff --git a/systems/x86_64-linux/halo/wyoming.nix b/systems/x86_64-linux/halo/wyoming.nix index 545261a..905083a 100644 --- a/systems/x86_64-linux/halo/wyoming.nix +++ b/systems/x86_64-linux/halo/wyoming.nix @@ -1,13 +1,15 @@ -{ ... }: +{ pkgs, ... }: { services.wyoming = { - faster-whisper.servers."main" = { - enable = true; - language = "de"; - model = "base"; # or "small"/"medium" for better accuracy - uri = "tcp://0.0.0.0:10300"; - device = "gpu"; - }; + whisper-cpp = { + package = pkgs.wyoming-whisper-rs; + servers.main = { + enable = true; + model = "/var/lib/wyoming/whisper-cpp/ggml-large-v3.bin"; + uri = "tcp://0.0.0.0:10300"; + language = "de"; + }; + }; piper.servers."main" = { enable = true;