diff --git a/flake.lock b/flake.lock index 8f360dd..4ee6f7e 100644 --- a/flake.lock +++ b/flake.lock @@ -23,6 +23,64 @@ "type": "github" } }, + "blueprint": { + "inputs": { + "nixpkgs": [ + "llm-agents", + "nixpkgs" + ], + "systems": [ + "llm-agents", + "systems" + ] + }, + "locked": { + "lastModified": 1776249299, + "narHash": "sha256-Dt9t1TGRmJFc0xVYhttNBD6QsAgHOHCArqGa0AyjrJY=", + "owner": "numtide", + "repo": "blueprint", + "rev": "56131e8628f173d24a27f6d27c0215eff57e40dd", + "type": "github" + }, + "original": { + "owner": "numtide", + "repo": "blueprint", + "type": "github" + } + }, + "bun2nix": { + "inputs": { + "flake-parts": [ + "llm-agents", + "flake-parts" + ], + "nixpkgs": [ + "llm-agents", + "nixpkgs" + ], + "systems": [ + "llm-agents", + "systems" + ], + "treefmt-nix": [ + "llm-agents", + "treefmt-nix" + ] + }, + "locked": { + "lastModified": 1778446047, + "narHash": "sha256-oQvcadh2BCkrog+SGrG6YffKJrveYpjj3TdQJWaKhaM=", + "owner": "nix-community", + "repo": "bun2nix", + "rev": "f2bc12af1a6369648aac41041ceeaa0b866599c6", + "type": "github" + }, + "original": { + "owner": "nix-community", + "repo": "bun2nix", + "type": "github" + } + }, "colmena": { "inputs": { "flake-compat": "flake-compat", @@ -186,6 +244,27 @@ "type": "github" } }, + "flake-parts_4": { + "inputs": { + "nixpkgs-lib": [ + "llm-agents", + "nixpkgs" + ] + }, + "locked": { + "lastModified": 1778716662, + "narHash": "sha256-m1Yf0wZ8j1OHjTc2UwHwyQRSnNeSgLJOd7q5Y45hzi4=", + "owner": "hercules-ci", + "repo": "flake-parts", + "rev": "f7c1a2d347e4c52d5fb8d10cb4d94b5884e546fb", + "type": "github" + }, + "original": { + "owner": "hercules-ci", + "repo": "flake-parts", + "type": "github" + } + }, "flake-utils": { "locked": { "lastModified": 1659877975, @@ -257,7 +336,7 @@ }, "flake-utils_5": { "inputs": { - "systems": "systems_6" + "systems": "systems_7" }, "locked": { "lastModified": 1731533236, @@ -275,7 +354,7 @@ }, "flake-utils_6": { "inputs": { - "systems": "systems_7" + "systems": "systems_8" }, "locked": { "lastModified": 1731533236, @@ -478,6 +557,31 @@ "type": "github" } }, + "llm-agents": { + "inputs": { + "blueprint": "blueprint", + "bun2nix": "bun2nix", + "flake-parts": "flake-parts_4", + "nixpkgs": [ + "nixpkgs-unstable" + ], + "systems": "systems_5", + "treefmt-nix": "treefmt-nix" + }, + "locked": { + "lastModified": 1780050433, + "narHash": "sha256-90mQY7VUvn6WoNh+m4LSqS+XTcofWOBLgYYmSJVyr98=", + "owner": "numtide", + "repo": "llm-agents.nix", + "rev": "0fb42103f93cd5c1152254856d7eccb3e91c8bf6", + "type": "github" + }, + "original": { + "owner": "numtide", + "repo": "llm-agents.nix", + "type": "github" + } + }, "models-dev": { "flake": false, "locked": { @@ -756,8 +860,8 @@ "noctalia", "nixpkgs" ], - "systems": "systems_5", - "treefmt-nix": "treefmt-nix" + "systems": "systems_6", + "treefmt-nix": "treefmt-nix_2" }, "locked": { "lastModified": 1779588472, @@ -827,6 +931,7 @@ "ketchup": "ketchup", "ksoloti-pr": "ksoloti-pr", "lanzaboote": "lanzaboote", + "llm-agents": "llm-agents", "models-dev": "models-dev", "niri-flake": "niri-flake", "nix-flatpak": "nix-flatpak", @@ -957,6 +1062,21 @@ } }, "systems_5": { + "locked": { + "lastModified": 1681028828, + "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=", + "owner": "nix-systems", + "repo": "default", + "rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e", + "type": "github" + }, + "original": { + "owner": "nix-systems", + "repo": "default", + "type": "github" + } + }, + "systems_6": { "locked": { "lastModified": 1689347949, "narHash": "sha256-12tWmuL2zgBgZkdoB6qXZsgJEH9LR3oUgpaQq2RbI80=", @@ -971,7 +1091,7 @@ "type": "github" } }, - "systems_6": { + "systems_7": { "locked": { "lastModified": 1681028828, "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=", @@ -986,7 +1106,7 @@ "type": "github" } }, - "systems_7": { + "systems_8": { "locked": { "lastModified": 1681028828, "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=", @@ -1041,6 +1161,27 @@ } }, "treefmt-nix": { + "inputs": { + "nixpkgs": [ + "llm-agents", + "nixpkgs" + ] + }, + "locked": { + "lastModified": 1775636079, + "narHash": "sha256-pc20NRoMdiar8oPQceQT47UUZMBTiMdUuWrYu2obUP0=", + "owner": "numtide", + "repo": "treefmt-nix", + "rev": "790751ff7fd3801feeaf96d7dc416a8d581265ba", + "type": "github" + }, + "original": { + "owner": "numtide", + "repo": "treefmt-nix", + "type": "github" + } + }, + "treefmt-nix_2": { "inputs": { "nixpkgs": [ "noctalia", diff --git a/flake.nix b/flake.nix index 0085ba0..956a1a3 100644 --- a/flake.nix +++ b/flake.nix @@ -83,6 +83,10 @@ inputs.nixpkgs.follows = "nixpkgs-unstable"; }; nix-flatpak.url = "github:gmodena/nix-flatpak/?ref=latest"; + llm-agents = { + url = "github:numtide/llm-agents.nix"; + inputs.nixpkgs.follows = "nixpkgs-unstable"; + }; }; outputs = { diff --git a/home/common/default.nix b/home/common/default.nix index 8ef913b..5194ee0 100644 --- a/home/common/default.nix +++ b/home/common/default.nix @@ -46,97 +46,103 @@ in # release notes. home.stateVersion = "23.11"; # Please read the comment before changing. - home.packages = with pkgs; [ - atool - unzip - htop - gnupg - pkgs-unstable.yubioath-flutter - pkgs-unstable.yubikey-manager - gcc - sqlite - noto-fonts - noto-fonts-cjk-sans - noto-fonts-color-emoji - source-sans-pro - mosh - docker-compose - (signal-desktop.override { - commandLineArgs = "--password-store=gnome-libsecret"; - }) - cargo - blanket - wl-clipboard - gnumeric - gh - neovim-remote - pkgs-unstable.gradia - crystal - shards - moreutils - keymapp - gnumake - tig - jq - yt-dlp - ffmpeg - otp - manix - (writeShellScriptBin "fd" '' - ${fd}/bin/fd -H "$@" - '') - pkgs-unstable.rpi-imager - picocom - imagemagick - ghostscript - inkscape - jless - scribus - dnscontrol - protonmail-bridge - hydroxide - imapsync - nixfmt-rfc-style - tree - virt-manager - pkgs-unstable.ncspot - pkgs-unstable.devbox - pkgs-unstable.feishin - openscad - pkgs-unstable.shairport-sync-airplay2 - (writeShellScriptBin "pw" '' - ${lib.getExe rbw} ls --fields 'id,folder,name' | \ - ${lib.getExe gawk} -F '\t' '{print $1 "\t" ($2 == "" ? "" : $2 "/") $3}' | \ - ${lib.getExe config.services.walker.package} -d -l 2 | \ - xargs ${lib.getExe rbw} get "$@" | ${lib.getExe' wl-clipboard "wl-copy"} - '') - (google-fonts.override { fonts = [ "Tajawal" ]; }) - pkgs-unstable.opencode - (writeShellScriptBin "nr" '' - ${lib.getExe nix} run "nixpkgs#''${1}" "$@" - '') - blueman - pavucontrol - (writeShellScriptBin "voxtoggle" '' - status=$(${lib.getExe config.programs.voxtype.package} status) - pid=$(cat ''${XDG_RUNTIME_DIR}/voxtype/pid) + home.packages = + with pkgs; + [ + atool + unzip + htop + gnupg + pkgs-unstable.yubioath-flutter + pkgs-unstable.yubikey-manager + gcc + sqlite + noto-fonts + noto-fonts-cjk-sans + noto-fonts-color-emoji + source-sans-pro + mosh + docker-compose + (signal-desktop.override { + commandLineArgs = "--password-store=gnome-libsecret"; + }) + cargo + blanket + wl-clipboard + gnumeric + gh + neovim-remote + pkgs-unstable.gradia + crystal + shards + moreutils + keymapp + gnumake + tig + jq + yt-dlp + ffmpeg + otp + manix + (writeShellScriptBin "fd" '' + ${fd}/bin/fd -H "$@" + '') + pkgs-unstable.rpi-imager + picocom + imagemagick + ghostscript + inkscape + jless + scribus + dnscontrol + protonmail-bridge + hydroxide + imapsync + nixfmt-rfc-style + tree + virt-manager + pkgs-unstable.ncspot + pkgs-unstable.devbox + pkgs-unstable.feishin + openscad + pkgs-unstable.shairport-sync-airplay2 + (writeShellScriptBin "pw" '' + ${lib.getExe rbw} ls --fields 'id,folder,name' | \ + ${lib.getExe gawk} -F '\t' '{print $1 "\t" ($2 == "" ? "" : $2 "/") $3}' | \ + ${lib.getExe config.services.walker.package} -d -l 2 | \ + xargs ${lib.getExe rbw} get "$@" | ${lib.getExe' wl-clipboard "wl-copy"} + '') + (google-fonts.override { fonts = [ "Tajawal" ]; }) + (writeShellScriptBin "nr" '' + ${lib.getExe nix} run "nixpkgs#''${1}" "$@" + '') + blueman + pavucontrol + (writeShellScriptBin "voxtoggle" '' + status=$(${lib.getExe config.programs.voxtype.package} status) + pid=$(cat ''${XDG_RUNTIME_DIR}/voxtype/pid) - if [[ "$status" == "stopped" ]]; then - exit 1 - elif [[ "$status" == "recording" ]]; then - kill -SIGUSR2 "$pid" - else - kill -SIGUSR1 "$pid" - fi - '') - (writeShellScriptBin "scrot" '' - set -eo pipefail + if [[ "$status" == "stopped" ]]; then + exit 1 + elif [[ "$status" == "recording" ]]; then + kill -SIGUSR2 "$pid" + else + kill -SIGUSR1 "$pid" + fi + '') + (writeShellScriptBin "scrot" '' + set -eo pipefail - ${lib.getExe grim} -t ppm -g "$(${lib.getExe slurp} -o -d -F monospace)" - | ${lib.getExe gradia} - '') - inputs.tree_hugger.packages.${stdenv.hostPlatform.system}.default - (writeShellScriptBin "ns" "${lib.join " " (ns-ipc [ ''"$@"'' ])}") - ]; + ${lib.getExe grim} -t ppm -g "$(${lib.getExe slurp} -o -d -F monospace)" - | ${lib.getExe gradia} + '') + inputs.tree_hugger.packages.${stdenv.hostPlatform.system}.default + (writeShellScriptBin "ns" "${lib.join " " (ns-ipc [ ''"$@"'' ])}") + ] + ++ (with inputs.llm-agents.packages.${pkgs.stdenv.hostPlatform.system}; [ + pi + opencode + crush + ]); programs = { noctalia-shell = {