1{ lib 2, buildPythonPackage 3, pythonOlder 4, fetchFromGitHub 5, poetry-core 6, pyyaml 7, requests 8}: 9let 10 pname = "prompthub-py"; 11 version = "4.0.0"; 12in 13buildPythonPackage { 14 inherit version pname; 15 format = "pyproject"; 16 17 # Pypi source package doesn't contain tests 18 src = fetchFromGitHub { 19 owner = "deepset-ai"; 20 repo = pname; 21 rev = "v${version}"; 22 hash = "sha256-FA4IfhHViSL1u4pgd7jh40rEcS0BldSFDwCPG5irk1g="; 23 }; 24 25 disabled = pythonOlder "3.8"; 26 27 nativeBuildInputs = [ 28 poetry-core 29 ]; 30 31 propagatedBuildInputs = [ 32 pyyaml 33 requests 34 ]; 35 36 meta = with lib; { 37 description = "A simple client to fetch prompts from Prompt Hub using its REST API."; 38 homepage = "https://github.com/deepset-ai/prompthub-py"; 39 changelog = "https://github.com/deepset-ai/prompthub-py/releases/tag/v${version}"; 40 license = licenses.asl20; 41 maintainers = with maintainers; [ happysalada ]; 42 }; 43}