Skip to content

Commit

Permalink
python312Packages.llm-gguf: init at 0.2 (#364926)
Browse files Browse the repository at this point in the history
  • Loading branch information
GaetanLepage authored Dec 13, 2024
2 parents ae599fb + 1780cbb commit 79439ea
Show file tree
Hide file tree
Showing 2 changed files with 51 additions and 0 deletions.
49 changes: 49 additions & 0 deletions pkgs/development/python-modules/llm-gguf/default.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
{
lib,
buildPythonPackage,
fetchFromGitHub,

# build-system
setuptools,

# dependencies
httpx,
llama-cpp-python,
llm,
}:

buildPythonPackage rec {
pname = "llm-gguf";
version = "0.2";
pyproject = true;

src = fetchFromGitHub {
owner = "simonw";
repo = "llm-gguf";
tag = version;
hash = "sha256-ihMOiQnTfgZKICVDoQHLOMahrd+GiB+HwWFBMyIcs0A=";
};

build-system = [
setuptools
];

dependencies = [
httpx
llama-cpp-python
llm
];

pythonImportsCheck = [ "llm_gguf" ];

# Tests require internet access (downloading models)
doCheck = false;

meta = {
description = "Run models distributed as GGUF files using LLM";
homepage = "https://github.com/simonw/llm-gguf";
changelog = "https://github.com/simonw/llm-gguf/releases/tag/${src.tag}";
license = lib.licenses.asl20;
maintainers = with lib.maintainers; [ GaetanLepage ];
};
}
2 changes: 2 additions & 0 deletions pkgs/top-level/python-packages.nix
Original file line number Diff line number Diff line change
Expand Up @@ -7584,6 +7584,8 @@ self: super: with self; {

llm = callPackage ../development/python-modules/llm { };

llm-gguf = callPackage ../development/python-modules/llm-gguf { };

llmx = callPackage ../development/python-modules/llmx { };

llvmlite = callPackage ../development/python-modules/llvmlite {
Expand Down

0 comments on commit 79439ea

Please sign in to comment.