feat(user/malte): openai helper tool "heygpt"
This commit is contained in:
parent
abef74b9d4
commit
c1804e7fe7
|
@ -88,6 +88,9 @@ in {
|
||||||
radicale-password = {
|
radicale-password = {
|
||||||
inherit sopsFile owner mode;
|
inherit sopsFile owner mode;
|
||||||
};
|
};
|
||||||
|
openai-heygpt-api-key = {
|
||||||
|
inherit sopsFile owner mode;
|
||||||
|
};
|
||||||
pw-mail-pm = {
|
pw-mail-pm = {
|
||||||
inherit sopsFile owner mode;
|
inherit sopsFile owner mode;
|
||||||
};
|
};
|
||||||
|
|
|
@ -4,6 +4,7 @@ pw-mail-pm: ENC[AES256_GCM,data:v3EqEZyuy6r8qveDlq7t+UuyK7m2Zg==,iv:96HpxVd8bRub
|
||||||
pw-mail-uni: ENC[AES256_GCM,data:CRZn0nNnwZRYETbpiWY=,iv:CAncz9DWCo89ffnLrRqCp6djV24ZFwC7KrdVi9w3p7A=,tag:/mw3lIuUWCeqwbo/15HjOA==,type:str]
|
pw-mail-uni: ENC[AES256_GCM,data:CRZn0nNnwZRYETbpiWY=,iv:CAncz9DWCo89ffnLrRqCp6djV24ZFwC7KrdVi9w3p7A=,tag:/mw3lIuUWCeqwbo/15HjOA==,type:str]
|
||||||
pw-mail-gmx: ENC[AES256_GCM,data:byvzb3zSVOHLjGzHwx43h0YhMoeDvUR2/g==,iv:tQEg751oi+LIjJ1dzW4Kv/irSgTCIuh2Fl4YQ0Pm6M8=,tag:1Uarz2dCkpTmJIh+/HYeEA==,type:str]
|
pw-mail-gmx: ENC[AES256_GCM,data:byvzb3zSVOHLjGzHwx43h0YhMoeDvUR2/g==,iv:tQEg751oi+LIjJ1dzW4Kv/irSgTCIuh2Fl4YQ0Pm6M8=,tag:1Uarz2dCkpTmJIh+/HYeEA==,type:str]
|
||||||
pw-mail-schulverwalter: ENC[AES256_GCM,data:jEFDG1EDywlwdrB/5KlrLYxde0CTSaOxtjLgC0lZbl0=,iv:pYhX7cihkK7HfXoFe8lfkZ4G0TVuSKLIDUXZnh6P60Y=,tag:zMh13xBGsnjpvtci7EnFNg==,type:str]
|
pw-mail-schulverwalter: ENC[AES256_GCM,data:jEFDG1EDywlwdrB/5KlrLYxde0CTSaOxtjLgC0lZbl0=,iv:pYhX7cihkK7HfXoFe8lfkZ4G0TVuSKLIDUXZnh6P60Y=,tag:zMh13xBGsnjpvtci7EnFNg==,type:str]
|
||||||
|
openai-heygpt-api-key: ENC[AES256_GCM,data:iC4NkkbMB2WIN9Z1Nw+KWPKG2NUitpH1EUrBfGFTta6y0XLRDs0o6D01EyF3vXOiEOcd,iv:W47ORUJv3KNTBBlFrBQvMAYvf3aeNFkSGYomirK/2xM=,tag:jBFjAfsk8TSmxBxge9zFeQ==,type:str]
|
||||||
sftp-key: ENC[AES256_GCM,data:4DTZnkaLvzeoGQowHqpcZfvvZls8LsOd/4ER5Fzw135nLDogVQWDN2ae8ce2CeCbfl4ZqCZNAlEueg3SIJ8Ew10zVkac4wU7mal1MPvqsDjH+ufiBIs5100DOCkWn376U0eZ/AVuwYY8/CA1ZeZ+LfQU3grpnN/9I4Q8QCZqW4zlPSJtF7V5/fU4Na1gJswKeaFXMdT7O+JWpfqb2jLl3HUO7m69VYlOD9/B8BcOU1PSfJGhat1bzeiNB6h22eEoZtUtLoF9P+O11IrOMiHbK610gSH8TM64Fu1Y8a7rx/UtlYpeDs1FA28Ldrb+YxZHfhJbhp8xNX/22NaDSDwFnZLIaY0KOv3lzICqpAmLB9s2r4kOAw64dopgYdw+XXb8qQ4o2iOwWQ3HCXCqKLxImRubktQu3jD6AOPoCDcDwPqzNfPDoo+OWNAGpLSS9LGN8+uRgtNIkfCEx+cU3gU9HhvBmbXVUFLObpNFo7XZJj3l/mHWKZ/rOKpyX8c6+Hx4zlQfUrChxt65X8f/8rSyB3Nq9SqCELBiaINu,iv:nUp0rBZjCyibnmVV8qIsFXmfqAjWExh5bH50ynVFwj0=,tag:TiaKa+lK0m6JC8tGcrfqIw==,type:str]
|
sftp-key: ENC[AES256_GCM,data:4DTZnkaLvzeoGQowHqpcZfvvZls8LsOd/4ER5Fzw135nLDogVQWDN2ae8ce2CeCbfl4ZqCZNAlEueg3SIJ8Ew10zVkac4wU7mal1MPvqsDjH+ufiBIs5100DOCkWn376U0eZ/AVuwYY8/CA1ZeZ+LfQU3grpnN/9I4Q8QCZqW4zlPSJtF7V5/fU4Na1gJswKeaFXMdT7O+JWpfqb2jLl3HUO7m69VYlOD9/B8BcOU1PSfJGhat1bzeiNB6h22eEoZtUtLoF9P+O11IrOMiHbK610gSH8TM64Fu1Y8a7rx/UtlYpeDs1FA28Ldrb+YxZHfhJbhp8xNX/22NaDSDwFnZLIaY0KOv3lzICqpAmLB9s2r4kOAw64dopgYdw+XXb8qQ4o2iOwWQ3HCXCqKLxImRubktQu3jD6AOPoCDcDwPqzNfPDoo+OWNAGpLSS9LGN8+uRgtNIkfCEx+cU3gU9HhvBmbXVUFLObpNFo7XZJj3l/mHWKZ/rOKpyX8c6+Hx4zlQfUrChxt65X8f/8rSyB3Nq9SqCELBiaINu,iv:nUp0rBZjCyibnmVV8qIsFXmfqAjWExh5bH50ynVFwj0=,tag:TiaKa+lK0m6JC8tGcrfqIw==,type:str]
|
||||||
sops:
|
sops:
|
||||||
kms: []
|
kms: []
|
||||||
|
@ -38,8 +39,8 @@ sops:
|
||||||
U05rN3hQTFkxTHFDVnpZWGxNY25maFUKdrn4Jtqc9U9GXyRAPhHE8iyVFL5NvnrZ
|
U05rN3hQTFkxTHFDVnpZWGxNY25maFUKdrn4Jtqc9U9GXyRAPhHE8iyVFL5NvnrZ
|
||||||
0KVOCWycdGVltDjTFVpyLoCiwZcTDDza/vjFcCro1zgcsdVuPl0orA==
|
0KVOCWycdGVltDjTFVpyLoCiwZcTDDza/vjFcCro1zgcsdVuPl0orA==
|
||||||
-----END AGE ENCRYPTED FILE-----
|
-----END AGE ENCRYPTED FILE-----
|
||||||
lastmodified: "2023-11-18T10:07:07Z"
|
lastmodified: "2023-12-12T11:48:30Z"
|
||||||
mac: ENC[AES256_GCM,data:lJZrTJUBBvdAlcJIXLiy2x+tCDdyFdR1mCsh4Zju6Qzl/GMthghLTTrn9VcHSxD6TBuLb49+SYpy1XNTQUzI8czftcnEaGlF1k1y3TOSE+1PzEiPsMmIafCq+8ke1bJE0d+y0DT1Qsk+pjpbtht5iKJnR2zasd1h2kSJgjOyHR0=,iv:LygZWWT2YNw4opQAvzNgfFkNdyJQcXKkRB48kFgjxpE=,tag:St89/E1Nj2Jl4tFM+iDf6w==,type:str]
|
mac: ENC[AES256_GCM,data:oBTR5BBuAOlNdcdkVI9pl3XKLZkAQMYLzqyI1f81izG7qL/dWO6F0PQqVxZwBcf7BQjlfRIXRjzVW41EFd85I1m2q1o+/2LWZY7a6qtuWe3nyNswrXI2q1uPInASfil9GX0Kht1pgy2WeSsjYOKGcGDTkHaAABfMRSfyT4DJRk4=,iv:j7XwHgPbtpFHzZLHv7L/oMLdIslNdSxcm4qUgse23w8=,tag:r9w1u5L8C7zx+Lq+wWNbvg==,type:str]
|
||||||
pgp:
|
pgp:
|
||||||
- created_at: "2023-11-18T10:06:28Z"
|
- created_at: "2023-11-18T10:06:28Z"
|
||||||
enc: |-
|
enc: |-
|
||||||
|
|
|
@ -17,6 +17,14 @@ in {
|
||||||
python39.pkgs.xkcdpass
|
python39.pkgs.xkcdpass
|
||||||
silicon
|
silicon
|
||||||
mdcat
|
mdcat
|
||||||
|
(heygpt.overrideAttrs (_: {
|
||||||
|
src = builtins.trace "REMOVE heygpt override after hash fix lands" (fetchFromGitHub {
|
||||||
|
owner = "fuyufjh";
|
||||||
|
repo = "heygpt";
|
||||||
|
rev = "v0.4.1";
|
||||||
|
hash = "sha256-oP0yIdYytXSsbZ2pNaZ8Rrak1qJsudTe/oP6dGncGUM=";
|
||||||
|
});
|
||||||
|
}))
|
||||||
];
|
];
|
||||||
|
|
||||||
programs.fish = {
|
programs.fish = {
|
||||||
|
@ -95,6 +103,9 @@ in {
|
||||||
wl-paste | silicon -f 'Hack Nerd Font FC Ligatured' --pad-horiz 40 --pad-vert 50 --theme gruvbox --shadow-blur-radius 30 -b '#ebdbb2' --shadow-color '#282828' --no-window-controls --output /tmp/image.png $argv && wl-copy < /tmp/image.png
|
wl-paste | silicon -f 'Hack Nerd Font FC Ligatured' --pad-horiz 40 --pad-vert 50 --theme gruvbox --shadow-blur-radius 30 -b '#ebdbb2' --shadow-color '#282828' --no-window-controls --output /tmp/image.png $argv && wl-copy < /tmp/image.png
|
||||||
'';
|
'';
|
||||||
nonix = "sed 's:/nix/store/[^-]\\+-\\([^/ ]*\\):< \\1>:g'";
|
nonix = "sed 's:/nix/store/[^-]\\+-\\([^/ ]*\\):< \\1>:g'";
|
||||||
|
c = ''
|
||||||
|
heygpt --api-key $OPENAI_API_KEY --api-base-url $OPENAI_API_BASE --model gpt-3.5-turbo --system "Imagine you are linux terminal command selector. I will describe task, and you will respond only using linux command, without description, without explanation." $argv
|
||||||
|
'';
|
||||||
};
|
};
|
||||||
|
|
||||||
shellInit = ''
|
shellInit = ''
|
||||||
|
@ -113,6 +124,9 @@ in {
|
||||||
set -g fish_color_autosuggestion brblack
|
set -g fish_color_autosuggestion brblack
|
||||||
set -g fish_color_cancel red --bold
|
set -g fish_color_cancel red --bold
|
||||||
set -g fish_color_valid_path normal --bold
|
set -g fish_color_valid_path normal --bold
|
||||||
|
|
||||||
|
set -g OPENAI_API_KEY (cat /run/secrets/openai-heygpt-api-key)
|
||||||
|
set -g OPENAI_API_BASE https://api.openai.com/v1
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue