gpt4all: improvements and mkl

This commit is contained in:
Simon Gardling 2024-10-03 11:33:44 -04:00
parent e82e944cc2
commit a5d96bd1a2
Signed by: titaniumtown
GPG Key ID: 9AB28AC10ECE533D
2 changed files with 21 additions and 1 deletions

View File

@ -34,6 +34,7 @@
targets = [ "thumbv7m-none-eabi" ];
}
))
cargo-expand
#find typos in code
typos
@ -129,6 +130,8 @@
age
git-crypt
clang
];
home.file.".cargo/config.toml".text = ''

View File

@ -73,6 +73,22 @@ let
sha256 = "vzAfWLyljR0Cg6pCeeyQJZNeOJh5xOILlbJnwDWu62o=";
};
cmakeFlags = old.cmakeFlags ++ [
"-DGGML_VULKAN=ON"
"-DGGML_KOMPUTE=ON"
"-DGGML_BLAS=ON"
"-DGGML_VENDOR=Intel"
];
nativeBuildInputs = old.nativeBuildInputs ++ [
pkgs.pkg-config
];
buildInputs = old.buildInputs ++ [
pkgs.mkl
pkgs.blas
];
patches = old.patches ++ [
./gpt4all-HEAD-disable-settings-err.patch
];
@ -89,6 +105,7 @@ let
);
in
{
nixpkgs.config.allowUnfree = true;
home.packages = [
gpt4all_package
];
@ -96,7 +113,7 @@ in
home.file = lib.recursiveUpdate {
".config/nomic.ai/GPT4All.ini".text =
let
system_prompt = "You are an expert LLM who is thoughtful and works step-by-step from first principles derive an answer to the user's prompt. For each step, provide a title that describes what you're doing in that step, along with the content, then decide if your work is comprehensive and if you're ready to provide your final answer. Make sure to exhaust ALL POSSIBILITIES before answering. While your reasoning is not shown to the user, it is under high levels of scrutiny to ensure high-quality reasoning. INTERNAL REASONING STEPS ARE NOT SHOWN TO THE USER, ONLY A \"Final Answer\" SECTION WILL BE SHOWN TO THE USER.
system_prompt = "You are an expert LLM who is thoughtful and works step-by-step from first principles derive an answer to the user's prompt. For each step, title the step and begin showing your work, then decide if your work is comprehensive and if you're ready to provide your final answer. Make sure to exhaust ALL POSSIBILITIES before answering. While your reasoning is not shown to the user, it is under high levels of scrutiny to ensure high-quality reasoning. INTERNAL REASONING STEPS ARE NOT SHOWN TO THE USER, ONLY A \"Final Answer\" SECTION WILL BE SHOWN TO THE USER.
USE AS MANY REASONING STEPS AS POSSIBLE. AT LEAST 3. EXPLORE ALTERNATE ANSWERS AND CONSIDER THAT YOUR ANSWER MAY BE WRONG. IDENTIFY POSSIBLE ERRORS IN YOUR REASONING AND WHERE SUCH ERRORS MAY BE. FULLY TEST ALL OTHER POSSIBILITIES. YOU CAN BE WRONG. WHEN YOU SAY YOU ARE RE-EXAMINING, ACTUALLY RE-EXAMINE, AND USE ANOTHER APPROACH TO DO SO. BE VERBOSE IN YOUR REASONING AND RE-EXAMINING.";
in
''