Package: guix-patches;
Reported by: Andy Tai <atai <at> atai.org>
Date: Mon, 14 Aug 2023 12:11:02 UTC
Severity: normal
Tags: patch
To reply to this bug, email your comments to 65287 AT debbugs.gnu.org.
Toggle the display of automated, internal messages from the tracker.
View this report as an mbox folder, status mbox, maintainer mbox
guix-patches <at> gnu.org
:bug#65287
; Package guix-patches
.
(Mon, 14 Aug 2023 12:11:02 GMT) Full text and rfc822 format available.Andy Tai <atai <at> atai.org>
:guix-patches <at> gnu.org
.
(Mon, 14 Aug 2023 12:11:02 GMT) Full text and rfc822 format available.Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):
From: Andy Tai <atai <at> atai.org> To: guix-patches <at> gnu.org Cc: Andy Tai <atai <at> atai.org> Subject: [PATCH] gnu: Add gpt4all-backend Date: Mon, 14 Aug 2023 05:09:47 -0700
* gnu/packages/machine-learning.scm (gpt4all-backend): New variable --- gnu/packages/machine-learning.scm | 51 +++++++++++++++++++++++++++++++ 1 file changed, 51 insertions(+) diff --git a/gnu/packages/machine-learning.scm b/gnu/packages/machine-learning.scm index c32180615b..4c9d56fbe2 100644 --- a/gnu/packages/machine-learning.scm +++ b/gnu/packages/machine-learning.scm @@ -4801,3 +4801,54 @@ (define-public oneapi-dnnl "OneAPI Deep Neural Network Library (oneDNN) is a cross-platform performance library of basic building blocks for deep learning applications.") (license license:asl2.0))) + + +(define-public gpt4all-backend + (let ((commit "108d950874e457ced4d5d1f0569dfb43bbd25734") + (version "0.3.0") + (revision "1")) + (package + (name "gpt4all-backend") + (version (git-version version revision commit)) + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/nomic-ai/gpt4all") + (commit commit) + (recursive? #t))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "1x2w3x5abqkwjp043ijqfsmsm72783a245y5bri9bs1cpfyr0xyr")))) + (build-system cmake-build-system) + ;; (inputs (list llama-cpp)) + ;; TODO: when upstream supports using system installed llama-cpp, use it + (outputs '("out")) + (arguments + (list #:tests? #f ;no test target + #:configure-flags #~(list (string-append + "-DCMAKE_INSTALL_PREFIX=" + #$output)) + #:phases #~(modify-phases %standard-phases + (add-after 'unpack 'chdir + (lambda _ + (chdir "gpt4all-backend"))) + (add-after 'chdir 'fix-install-path + (lambda _ + (substitute* "CMakeLists.txt" + (("CMAKE_INSTALL_PREFIX") + "CMAKE_INSTALL_PREFIX_ignored")))) + (replace 'install + (lambda _ + (mkdir-p #$output) + (invoke "cmake" "-P" "cmake_install.cmake")))))) + (home-page "https://gpt4all.io/index.html") + (synopsis "C/C model backend used by GPT4All for inference on the CPU") + (description + "GPT4All backend acts as a universal library/wrapper for all models that +the GPT4All ecosystem supports. Language bindings are built on top of this universal +library. The native GPT4all Chat application directly uses this library for all +inference.") + (license license:expat)))) + + base-commit: b15381460ed74e72792ff182dd2ca7a06ba59b0c -- 2.41.0
guix-patches <at> gnu.org
:bug#65287
; Package guix-patches
.
(Mon, 14 Aug 2023 12:57:02 GMT) Full text and rfc822 format available.Message #8 received at 65287 <at> debbugs.gnu.org (full text, mbox):
From: Andy Tai <atai <at> atai.org> To: 65287 <at> debbugs.gnu.org Cc: Andy Tai <atai <at> atai.org> Subject: [PATCH v2] gnu: Add gpt4all-backend Date: Mon, 14 Aug 2023 05:56:37 -0700
* gnu/packages/machine-learning.scm (gpt4all-backend): New variable --- gnu/packages/machine-learning.scm | 56 +++++++++++++++++++++++++++++++ 1 file changed, 56 insertions(+) diff --git a/gnu/packages/machine-learning.scm b/gnu/packages/machine-learning.scm index c32180615b..7af7ba8b5f 100644 --- a/gnu/packages/machine-learning.scm +++ b/gnu/packages/machine-learning.scm @@ -4801,3 +4801,59 @@ (define-public oneapi-dnnl "OneAPI Deep Neural Network Library (oneDNN) is a cross-platform performance library of basic building blocks for deep learning applications.") (license license:asl2.0))) + + +(define-public gpt4all-backend + (let ((commit "108d950874e457ced4d5d1f0569dfb43bbd25734") + (version "0.3.0") + (revision "1")) + (package + (name "gpt4all-backend") + (version (git-version version revision commit)) + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/nomic-ai/gpt4all") + (commit commit) + (recursive? #t))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "1x2w3x5abqkwjp043ijqfsmsm72783a245y5bri9bs1cpfyr0xyr")))) + (build-system cmake-build-system) + ;; (inputs (list llama-cpp)) + ;; TODO: when upstream supports using system installed llama-cpp, use it + (arguments + (list #:tests? #f ;no test target + #:configure-flags #~(list (string-append + "-DCMAKE_INSTALL_PREFIX=" + #$output)) + #:phases #~(modify-phases %standard-phases + (add-after 'unpack 'chdir + (lambda _ + (mkdir-p #$output) ;ensure it exists + (chdir "gpt4all-backend"))) + (add-after 'chdir 'fix-install-path + (lambda _ + (substitute* "CMakeLists.txt" + (("CMAKE_INSTALL_PREFIX") + "CMAKE_INSTALL_PREFIX_ignored")))) + (replace 'install + (lambda* (#:key outputs #:allow-other-keys) + (let* ((out #$output) + (lib (string-append out "/lib"))) + (mkdir-p lib) + ;; Install the .so targets. + (for-each (lambda (file) + (install-file file lib)) + (find-files "." "\\.so")))))))) + (home-page "https://gpt4all.io/index.html") + (synopsis "C/C model backend used by GPT4All for inference on the CPU") + (description + "GPT4All backend acts as a universal library/wrapper for all models that +the GPT4All ecosystem supports. Language bindings are built on top of this universal +library. The native GPT4all Chat application directly uses this library for all +inference.") + (license license:expat)))) + + base-commit: b15381460ed74e72792ff182dd2ca7a06ba59b0c -- 2.41.0
guix-patches <at> gnu.org
:bug#65287
; Package guix-patches
.
(Mon, 14 Aug 2023 13:02:01 GMT) Full text and rfc822 format available.Message #11 received at 65287 <at> debbugs.gnu.org (full text, mbox):
From: Andy Tai <atai <at> atai.org> To: 65287 <at> debbugs.gnu.org Cc: Andy Tai <atai <at> atai.org> Subject: [PATCH v3] gnu: Add gpt4all-backend Date: Mon, 14 Aug 2023 06:00:59 -0700
* gnu/packages/machine-learning.scm (gpt4all-backend): New variable --- gnu/packages/machine-learning.scm | 56 +++++++++++++++++++++++++++++++ 1 file changed, 56 insertions(+) diff --git a/gnu/packages/machine-learning.scm b/gnu/packages/machine-learning.scm index c32180615b..6ba78f35c6 100644 --- a/gnu/packages/machine-learning.scm +++ b/gnu/packages/machine-learning.scm @@ -4801,3 +4801,59 @@ (define-public oneapi-dnnl "OneAPI Deep Neural Network Library (oneDNN) is a cross-platform performance library of basic building blocks for deep learning applications.") (license license:asl2.0))) + + +(define-public gpt4all-backend + (let ((commit "108d950874e457ced4d5d1f0569dfb43bbd25734") + (version "0.3.0") + (revision "1")) + (package + (name "gpt4all-backend") + (version (git-version version revision commit)) + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/nomic-ai/gpt4all") + (commit commit) + (recursive? #t))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "1x2w3x5abqkwjp043ijqfsmsm72783a245y5bri9bs1cpfyr0xyr")))) + (build-system cmake-build-system) + ;; (inputs (list llama-cpp)) + ;; TODO: when upstream supports using system installed llama-cpp, use it + (arguments + (list #:tests? #f ;no test target + #:configure-flags #~(list (string-append + "-DCMAKE_INSTALL_PREFIX=" + #$output)) + #:phases #~(modify-phases %standard-phases + (add-after 'unpack 'chdir + (lambda _ + (mkdir-p #$output) ;ensure it exists + (chdir "gpt4all-backend"))) + (add-after 'chdir 'fix-install-path + (lambda _ + (substitute* "CMakeLists.txt" + (("CMAKE_INSTALL_PREFIX") + "CMAKE_INSTALL_PREFIX_ignored")))) + (replace 'install + (lambda* (#:key outputs #:allow-other-keys) + (let* ((out #$output) + (lib (string-append out "/lib"))) + (mkdir-p lib) + ;; Install the .so targets. + (for-each (lambda (file) + (install-file file lib)) + (find-files "." "\\.so")))))))) + (home-page "https://gpt4all.io/index.html") + (synopsis "C/C++ model backend used by GPT4All for inference on the CPU") + (description + "GPT4All backend acts as a universal library/wrapper for all models that +the GPT4All ecosystem supports. Language bindings are built on top of this universal +library. The native GPT4all Chat application directly uses this library for all +inference.") + (license license:expat)))) + + base-commit: b15381460ed74e72792ff182dd2ca7a06ba59b0c -- 2.41.0
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.