Something went wrong. Try again.
Nix Packages collection & NixOS github.com/NixOS/nixpkgs
Something went wrong. Try again.
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475{ lib, buildPythonPackage, fetchFromGitHub,
# build-system poetry-core,
# dependencies fastavro, httpx, pydantic, pydantic-core, requests, tokenizers, types-requests, typing-extensions,
# optional-dependencies aiohttp, httpx-aiohttp, oci,}:
buildPythonPackage rec { pname = "cohere"; version = "7.0.4"; pyproject = true;
src = fetchFromGitHub { owner = "cohere-ai"; repo = "cohere-python"; tag = version; hash = "sha256-iFqzWuWOKbJcvmGFEI0jt0fkBlZHlzmzZXZO7tIn638="; };
build-system = [ poetry-core ];
dependencies = [ fastavro httpx pydantic pydantic-core requests tokenizers types-requests typing-extensions ];
pythonRelaxDeps = [ "pydantic-core" ];
optional-dependencies = { aiohttp = [ aiohttp httpx-aiohttp ]; oci = [ oci ]; };
# tests require CO_API_KEY doCheck = false;
pythonImportsCheck = [ "cohere" ];
meta = { description = "Simplify interfacing with the Cohere API"; homepage = "https://docs.cohere.com/docs"; changelog = "https://github.com/cohere-ai/cohere-python/releases/tag/${src.tag}"; license = lib.licenses.mit; maintainers = with lib.maintainers; [ natsukium ]; };}