at master 970 B view raw
1{ 2 lib, 3 buildPythonPackage, 4 fetchFromGitHub, 5 6 # build-system 7 setuptools, 8 9 # dependencies 10 httpx, 11 llama-cpp-python, 12 llm, 13 llm-gguf, 14}: 15 16buildPythonPackage rec { 17 pname = "llm-gguf"; 18 version = "0.2"; 19 pyproject = true; 20 21 src = fetchFromGitHub { 22 owner = "simonw"; 23 repo = "llm-gguf"; 24 tag = version; 25 hash = "sha256-ihMOiQnTfgZKICVDoQHLOMahrd+GiB+HwWFBMyIcs0A="; 26 }; 27 28 build-system = [ setuptools ]; 29 30 dependencies = [ 31 httpx 32 llm 33 llama-cpp-python 34 ]; 35 36 pythonImportsCheck = [ "llm_gguf" ]; 37 38 # Tests require internet access (downloading models) 39 doCheck = false; 40 41 passthru.tests = llm.mkPluginTest llm-gguf; 42 43 meta = { 44 description = "Run models distributed as GGUF files using LLM"; 45 homepage = "https://github.com/simonw/llm-gguf"; 46 changelog = "https://github.com/simonw/llm-gguf/releases/tag/${src.tag}"; 47 license = lib.licenses.asl20; 48 maintainers = with lib.maintainers; [ GaetanLepage ]; 49 }; 50}