at master 1.1 kB view raw
1{ 2 lib, 3 buildPythonPackage, 4 fetchFromGitHub, 5 setuptools, 6 llm, 7 llm-gemini, 8 httpx, 9 ijson, 10 pytestCheckHook, 11 pytest-recording, 12 pytest-asyncio, 13 nest-asyncio, 14 writableTmpDirAsHomeHook, 15}: 16buildPythonPackage rec { 17 pname = "llm-gemini"; 18 version = "0.26"; 19 pyproject = true; 20 21 src = fetchFromGitHub { 22 owner = "simonw"; 23 repo = "llm-gemini"; 24 tag = version; 25 hash = "sha256-Blkes0d7pVpltP2Vj8ngFRpNYnb9Z/m6O6UByAjrdfw="; 26 }; 27 28 build-system = [ setuptools ]; 29 30 dependencies = [ 31 httpx 32 ijson 33 llm 34 ]; 35 36 nativeCheckInputs = [ 37 pytestCheckHook 38 pytest-recording 39 pytest-asyncio 40 nest-asyncio 41 writableTmpDirAsHomeHook 42 ]; 43 44 pythonImportsCheck = [ "llm_gemini" ]; 45 46 passthru.tests = llm.mkPluginTest llm-gemini; 47 48 meta = { 49 description = "LLM plugin to access Google's Gemini family of models"; 50 homepage = "https://github.com/simonw/llm-gemini"; 51 changelog = "https://github.com/simonw/llm-gemini/releases/tag/${src.tag}"; 52 license = lib.licenses.asl20; 53 maintainers = with lib.maintainers; [ 54 josh 55 philiptaron 56 ]; 57 }; 58}