Compare commits
No commits in common. "714b23b9028db0ef8da93348ccdb36d5c0a65eeb" and "8795b45fb1ed6db54016d8a014822eba6338a916" have entirely different histories.
714b23b902
...
8795b45fb1
18
flake.lock
generated
18
flake.lock
generated
@ -7,11 +7,11 @@
|
|||||||
]
|
]
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1715381426,
|
"lastModified": 1712386041,
|
||||||
"narHash": "sha256-wPuqrAQGdv3ISs74nJfGb+Yprm23U/rFpcHFFNWgM94=",
|
"narHash": "sha256-dA82pOMQNnCJMAsPG7AXG35VmCSMZsJHTFlTHizpKWQ=",
|
||||||
"owner": "nix-community",
|
"owner": "nix-community",
|
||||||
"repo": "home-manager",
|
"repo": "home-manager",
|
||||||
"rev": "ab5542e9dbd13d0100f8baae2bc2d68af901f4b4",
|
"rev": "d6bb9f934f2870e5cbc5b94c79e9db22246141ff",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@ -35,11 +35,11 @@
|
|||||||
},
|
},
|
||||||
"nixos-unstable": {
|
"nixos-unstable": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1716499749,
|
"lastModified": 1713970445,
|
||||||
"narHash": "sha256-fCkyXpt1PXihhSWOQdgp2iTY5dgQmkHYDiqg1DhjhIM=",
|
"narHash": "sha256-FQy+M/Wj6TT4BzvhXP8Q7XzfYPoYY4KhmSX5YoSNIV8=",
|
||||||
"owner": "NixOS",
|
"owner": "NixOS",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"rev": "b962cd91aa0b1150ebd4e8552943de9b7700fe5e",
|
"rev": "d171375d7786e41160a9cb0a226a99ee68738c14",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@ -51,11 +51,11 @@
|
|||||||
},
|
},
|
||||||
"nixpkgs": {
|
"nixpkgs": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1716492874,
|
"lastModified": 1713958888,
|
||||||
"narHash": "sha256-MLI6m4upxQnqAZ8ymRdEmyWa1EnT2C+wgy/HCU8Y3F0=",
|
"narHash": "sha256-QZh6ag1mnQslIdXZOY3a0TTKIYnKcQax9zmCVp+2e10=",
|
||||||
"owner": "NixOS",
|
"owner": "NixOS",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"rev": "880e6beaf8069075941eafac2d18cdd69558a2d2",
|
"rev": "ecc5586a0b9716f457f7974cbc890d68b3e92282",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -10,11 +10,9 @@ let
|
|||||||
in
|
in
|
||||||
{
|
{
|
||||||
environment = {
|
environment = {
|
||||||
systemPackages = [ ollamaPkg ];
|
systemPackages = [ ollamaPkg pkgs.aichat ];
|
||||||
variables = {
|
variables = {
|
||||||
OLLAMA_ORIGINS = "*";
|
OLLAMA_ORIGINS = "*";
|
||||||
OLLAMA_FLASH_ATTENTION = "1";
|
|
||||||
OLLAMA_NUM_PARALLEL = "3";
|
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -51,7 +49,7 @@ in
|
|||||||
extraConfig = ''
|
extraConfig = ''
|
||||||
proxy_buffering off;
|
proxy_buffering off;
|
||||||
proxy_read_timeout 600s;
|
proxy_read_timeout 600s;
|
||||||
proxy_set_header Host localhost:${toString ollamaPort};
|
proxy_set_header Host localhost:11434;
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
16
hosts/architect/sunshine-ui.patch
Normal file
16
hosts/architect/sunshine-ui.patch
Normal file
@ -0,0 +1,16 @@
|
|||||||
|
diff --git a/cmake/targets/unix.cmake b/cmake/targets/unix.cmake
|
||||||
|
index 2ce0378..cdbf65c 100644
|
||||||
|
--- a/cmake/targets/unix.cmake
|
||||||
|
+++ b/cmake/targets/unix.cmake
|
||||||
|
@@ -2,7 +2,7 @@
|
||||||
|
# put anything here that applies to both linux and macos
|
||||||
|
|
||||||
|
#WebUI build
|
||||||
|
-add_custom_target(web-ui ALL
|
||||||
|
- WORKING_DIRECTORY "${CMAKE_SOURCE_DIR}"
|
||||||
|
- COMMENT "Installing NPM Dependencies and Building the Web UI"
|
||||||
|
- COMMAND bash -c \"npm install && SUNSHINE_BUILD_HOMEBREW=${NPM_BUILD_HOMEBREW} SUNSHINE_SOURCE_ASSETS_DIR=${NPM_SOURCE_ASSETS_DIR} SUNSHINE_ASSETS_DIR=${NPM_ASSETS_DIR} npm run build\") # cmake-lint: disable=C0301
|
||||||
|
+# add_custom_target(web-ui ALL
|
||||||
|
+# WORKING_DIRECTORY "${CMAKE_SOURCE_DIR}"
|
||||||
|
+# COMMENT "Installing NPM Dependencies and Building the Web UI"
|
||||||
|
+# COMMAND bash -c \"npm install && SUNSHINE_BUILD_HOMEBREW=${NPM_BUILD_HOMEBREW} SUNSHINE_SOURCE_ASSETS_DIR=${NPM_SOURCE_ASSETS_DIR} SUNSHINE_ASSETS_DIR=${NPM_ASSETS_DIR} npm run build\") # cmake-lint: disable=C0301
|
@ -51,7 +51,19 @@ let
|
|||||||
|
|
||||||
global_prep_cmd=[{"do":"${pkgs.bash}/bin/bash -c \"${resolutionScript}/bin/resolution.sh ''${SUNSHINE_CLIENT_WIDTH} ''${SUNSHINE_CLIENT_HEIGHT} ''${SUNSHINE_CLIENT_FPS}\""}]
|
global_prep_cmd=[{"do":"${pkgs.bash}/bin/bash -c \"${resolutionScript}/bin/resolution.sh ''${SUNSHINE_CLIENT_WIDTH} ''${SUNSHINE_CLIENT_HEIGHT} ''${SUNSHINE_CLIENT_FPS}\""}]
|
||||||
'';
|
'';
|
||||||
sunshinePkg = (pkgs.unstablePkgs.sunshine.override { cudaSupport = true; });
|
sunshinePkg = (pkgs.unstablePkgs.sunshine.override { cudaSupport = true; }).overrideAttrs (old: {
|
||||||
|
version = "0.22.2-fix";
|
||||||
|
src = pkgs.fetchFromGitHub {
|
||||||
|
owner = "gschintgen";
|
||||||
|
repo = "Sunshine";
|
||||||
|
rev = "985561c5cfe0934662a90f9b6c406e3f3e981d59";
|
||||||
|
sha256 = "sha256-APfwDkVG1uYvfqxNjNxGEofDd4H0QAk5fzAKG6IW+CI=";
|
||||||
|
fetchSubmodules = true;
|
||||||
|
};
|
||||||
|
patches = [./sunshine-ui.patch];
|
||||||
|
|
||||||
|
buildInputs = old.buildInputs ++ [pkgs.python311];
|
||||||
|
});
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
boot.kernelModules = [ "uinput" ];
|
boot.kernelModules = [ "uinput" ];
|
||||||
|
@ -30,7 +30,6 @@
|
|||||||
home-manager.users.${name}.imports = [
|
home-manager.users.${name}.imports = [
|
||||||
(mkHomeRole "common")
|
(mkHomeRole "common")
|
||||||
(mkHomeRole "zsh")
|
(mkHomeRole "zsh")
|
||||||
(mkHomeRole "aichat")
|
|
||||||
] ++ roles_mod;
|
] ++ roles_mod;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -1,34 +0,0 @@
|
|||||||
{ pkgs, ... }:
|
|
||||||
let
|
|
||||||
aichatConfigDir = "$HOME/.config/aichat";
|
|
||||||
aichatConfig = ''
|
|
||||||
model: ollama
|
|
||||||
clients:
|
|
||||||
- type: ollama
|
|
||||||
api_base: https://ollama.giugl.io
|
|
||||||
api_key: null
|
|
||||||
models:
|
|
||||||
- name: pino
|
|
||||||
max_input_tokens: null
|
|
||||||
- name: code-commenter
|
|
||||||
max_input_tokens: null
|
|
||||||
- name: git-commit-message
|
|
||||||
max_input_tokens: null
|
|
||||||
|
|
||||||
- type: claude
|
|
||||||
api_key: null
|
|
||||||
|
|
||||||
- type: openai
|
|
||||||
api_key: null
|
|
||||||
api_base: https://api.openai.com/v1
|
|
||||||
'';
|
|
||||||
in
|
|
||||||
{
|
|
||||||
home = {
|
|
||||||
sessionVariables = {
|
|
||||||
AICHAT_CONFIG_DIR = aichatConfigDir;
|
|
||||||
};
|
|
||||||
packages = [ pkgs.unstablePkgs.aichat ];
|
|
||||||
file.".config/aichat/config.yaml".text = aichatConfig;
|
|
||||||
};
|
|
||||||
}
|
|
@ -1,8 +1,13 @@
|
|||||||
{ pkgs, ... }:
|
{ pkgs, lib, stdenv, ... }:
|
||||||
|
|
||||||
let
|
let
|
||||||
actualPkgs = pkgs.unstablePkgs;
|
actualPkgs = pkgs.unstablePkgs;
|
||||||
|
|
||||||
|
pythonPkgs = with actualPkgs.python3Packages; [
|
||||||
|
python-lsp-server
|
||||||
|
python-lsp-ruff
|
||||||
|
pylsp-mypy
|
||||||
|
];
|
||||||
nodePkgs = with actualPkgs.nodePackages; [
|
nodePkgs = with actualPkgs.nodePackages; [
|
||||||
vscode-langservers-extracted
|
vscode-langservers-extracted
|
||||||
typescript
|
typescript
|
||||||
@ -12,6 +17,37 @@ let
|
|||||||
bash-language-server
|
bash-language-server
|
||||||
pyright
|
pyright
|
||||||
];
|
];
|
||||||
|
aichatConfigDir = "$HOME/.config/aichat";
|
||||||
|
aichatConfig = ''
|
||||||
|
model: ollama
|
||||||
|
clients:
|
||||||
|
- type: ollama
|
||||||
|
api_base: https://ollama.giugl.io
|
||||||
|
api_key: null
|
||||||
|
models:
|
||||||
|
- name: pino-coder-fast
|
||||||
|
max_input_tokens: null
|
||||||
|
- name: pino-coder
|
||||||
|
max_input_tokens: null
|
||||||
|
- name: pino-fast
|
||||||
|
max_input_tokens: null
|
||||||
|
- name: pino
|
||||||
|
max_input_tokens: null
|
||||||
|
- name: code-commenter
|
||||||
|
max_input_tokens: null
|
||||||
|
- name: git-commit-message
|
||||||
|
max_input_tokens: null
|
||||||
|
|
||||||
|
- type: claude
|
||||||
|
api_key: null
|
||||||
|
|
||||||
|
- type: openai
|
||||||
|
api_key: null
|
||||||
|
api_base: https://api.openai.com/v1
|
||||||
|
|
||||||
|
- type: gemini
|
||||||
|
api_key: null
|
||||||
|
'';
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
home = {
|
home = {
|
||||||
@ -30,11 +66,12 @@ in
|
|||||||
shfmt
|
shfmt
|
||||||
gopls
|
gopls
|
||||||
aichat
|
aichat
|
||||||
|
# ] ++ pythonPkgs ++ nodePkgs;
|
||||||
] ++ nodePkgs;
|
] ++ nodePkgs;
|
||||||
|
|
||||||
sessionVariables = {
|
sessionVariables = {
|
||||||
EDITOR = "hx";
|
EDITOR = "hx";
|
||||||
VISUAL = "hx";
|
VISUAL = "hx";
|
||||||
|
AICHAT_CONFIG_DIR = aichatConfigDir;
|
||||||
};
|
};
|
||||||
|
|
||||||
file = {
|
file = {
|
||||||
@ -60,13 +97,13 @@ in
|
|||||||
[editor.statusline]
|
[editor.statusline]
|
||||||
left = ["mode", "spinner"]
|
left = ["mode", "spinner"]
|
||||||
center = ["file-name"]
|
center = ["file-name"]
|
||||||
|
|
||||||
|
[keys.select.l]
|
||||||
|
c = ":pipe ${pkgs.unstablePkgs.aichat}/bin/aichat -m ollama:pino-coder-fast -c -r comment"
|
||||||
|
C = ":pipe ${pkgs.unstablePkgs.aichat}/bin/aichat -m ollama:pino-coder -c -r comment"
|
||||||
'';
|
'';
|
||||||
|
|
||||||
".config/helix/languages.toml".text = ''
|
".config/aichat/config.yaml".text = aichatConfig;
|
||||||
[[language]]
|
|
||||||
name = "nix"
|
|
||||||
formatter = { command = "nixpkgs-fmt" }
|
|
||||||
'';
|
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user