From 2cfa2ff274231b39612a220a19fc3375b072e424 Mon Sep 17 00:00:00 2001 From: Gaetan Lepage Date: Tue, 16 Jul 2024 18:04:04 +0200 Subject: [PATCH] python311Packages.cohere: 5.5.8 -> 5.6.0; fix Diff: https://github.com/cohere-ai/cohere-python/compare/5.5.8...5.6.0 Changelog: https://github.com/cohere-ai/cohere-python/releases/tag/5.6.0 --- .../python-modules/cohere/default.nix | 30 ++++++++++++------- 1 file changed, 20 insertions(+), 10 deletions(-) diff --git a/pkgs/development/python-modules/cohere/default.nix b/pkgs/development/python-modules/cohere/default.nix index 46aed51be299..3a94a3e70cb3 100644 --- a/pkgs/development/python-modules/cohere/default.nix +++ b/pkgs/development/python-modules/cohere/default.nix @@ -1,12 +1,18 @@ { lib, buildPythonPackage, - fetchPypi, - poetry-core, pythonOlder, + fetchFromGitHub, + + # build-system + poetry-core, + + # dependencies + boto3, fastavro, httpx, httpx-sse, + parameterized, pydantic, requests, tokenizers, @@ -16,22 +22,26 @@ buildPythonPackage rec { pname = "cohere"; - version = "5.5.8"; + version = "5.6.0"; pyproject = true; - disabled = pythonOlder "3.7"; + disabled = pythonOlder "3.8"; - src = fetchPypi { - inherit pname version; - hash = "sha256-hM52Zv+PvfT0H7X2ykUqsmOaUUvIiWeihUqbG4INbqA="; + src = fetchFromGitHub { + owner = "cohere-ai"; + repo = "cohere-python"; + rev = "refs/tags/${version}"; + hash = "sha256-zv4zSUQzt2jjuKumaV5vI3GbhZWKEjALohfuxQp6i7Q="; }; build-system = [ poetry-core ]; dependencies = [ + boto3 fastavro httpx httpx-sse + parameterized pydantic requests tokenizers @@ -44,11 +54,11 @@ buildPythonPackage rec { pythonImportsCheck = [ "cohere" ]; - meta = with lib; { + meta = { description = "Simplify interfacing with the Cohere API"; homepage = "https://docs.cohere.com/docs"; changelog = "https://github.com/cohere-ai/cohere-python/releases/tag/${version}"; - license = licenses.mit; - maintainers = with maintainers; [ natsukium ]; + license = lib.licenses.mit; + maintainers = with lib.maintainers; [ natsukium ]; }; }