From 52ab963bdd4b794f1523e614d359af9d7cacf92d Mon Sep 17 00:00:00 2001 From: Thanos Apollo Date: Thu, 25 Jul 2024 16:57:57 +0300 Subject: packages: new module: Add ollama. --- hecate/packages/ollama.scm | 38 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 38 insertions(+) create mode 100644 hecate/packages/ollama.scm diff --git a/hecate/packages/ollama.scm b/hecate/packages/ollama.scm new file mode 100644 index 0000000..cb1eb94 --- /dev/null +++ b/hecate/packages/ollama.scm @@ -0,0 +1,38 @@ +(define-module (hecate packages ollama) + #:use-module (guix packages) + #:use-module (guix download) + #:use-module (nonguix build-system binary) + #:use-module ((guix licenses) + #:prefix license:) + #:use-module (gnu packages gcc) + #:use-module (gnu packages base)) + +(define-public ollama-linux-amd64 + (package + (name "ollama-linux-amd64") + (version "0.2.8") + (source + (origin + (method url-fetch) + (uri (string-append + "https://github.com/ollama/ollama/releases/download/v" version + "/ollama-linux-amd64")) + (sha256 + (base32 "0hyc4bwgagbcf95ds3ckslgnpnnk2fq6nwg4b971y1z7p6a3y9rf")))) + (build-system binary-build-system) + (supported-systems (list "x86_64-linux")) + (arguments + `(#:strip-binaries? #f + #:patchelf-plan `(("ollama-linux-amd64" ("glibc" "gcc"))) + #:install-plan `(("ollama-linux-amd64" "bin/ollama")) + #:phases (modify-phases %standard-phases + (add-after 'binary-unpack 'chmod-to-allow-patchelf + (lambda _ + (chmod "ollama-linux-amd64" #o755)))))) + (inputs (list (list gcc "lib") glibc)) + (home-page "https://ollama.com") + (synopsis "Get up and running with large language models") + (description + "Get up and running with large language models. +Run Llama 2, Code Llama, and other models. Customize and create your own.") + (license license:expat))) -- cgit v1.2.3