From e6d86d86e4bd724850b4d65a58a3ae6fc5921b3d Mon Sep 17 00:00:00 2001 From: Pol Dellaiera Date: Sat, 2 Nov 2024 22:18:23 +0100 Subject: [PATCH] python312Packages.deepsearch-toolkit: init at 1.1.1 --- .../deepsearch-toolkit/default.nix | 97 +++++++++++++++++++ pkgs/top-level/python-packages.nix | 2 + 2 files changed, 99 insertions(+) create mode 100644 pkgs/development/python-modules/deepsearch-toolkit/default.nix diff --git a/pkgs/development/python-modules/deepsearch-toolkit/default.nix b/pkgs/development/python-modules/deepsearch-toolkit/default.nix new file mode 100644 index 000000000000..4e9bec5413dc --- /dev/null +++ b/pkgs/development/python-modules/deepsearch-toolkit/default.nix @@ -0,0 +1,97 @@ +{ + lib, + buildPythonPackage, + fetchFromGitHub, + poetry-core, + certifi, + docling-core, + platformdirs, + pluggy, + pydantic, + pydantic-settings, + python-dateutil, + python-dotenv, + requests, + six, + tabulate, + tqdm, + typer, + urllib3, + anyio, + fastapi, + uvicorn, + pytestCheckHook, +}: + +buildPythonPackage rec { + pname = "deepsearch-toolkit"; + version = "1.1.1"; + pyproject = true; + + src = fetchFromGitHub { + owner = "DS4SD"; + repo = "deepsearch-toolkit"; + rev = "refs/tags/v${version}"; + hash = "sha256-7XiI/VtXX4lRMreqUh6hJvdIULGvsCEdrd+zV5Jrne0="; + }; + + build-system = [ + poetry-core + ]; + + dependencies = [ + certifi + docling-core + platformdirs + pluggy + pydantic + pydantic-settings + python-dateutil + python-dotenv + requests + six + tabulate + tqdm + typer + urllib3 + ]; + + pythonRelaxDeps = [ + "urllib3" + ]; + + optional-dependencies = { + all = [ + anyio + fastapi + uvicorn + ]; + api = [ + anyio + fastapi + uvicorn + ]; + }; + + pythonImportsCheck = [ + "deepsearch" + ]; + + nativeCheckInputs = [ + pytestCheckHook + ]; + + disabledTests = [ + # Tests require the creation of a deepsearch profile + "test_project_listing" + "test_system_info" + ]; + + meta = { + changelog = "https://github.com/DS4SD/deepsearch-toolkit/blob/${src.rev}/CHANGELOG.md"; + description = "Interact with the Deep Search platform for new knowledge explorations and discoveries"; + homepage = "https://github.com/DS4SD/deepsearch-toolkit"; + license = lib.licenses.mit; + maintainers = with lib.maintainers; [ drupol ]; + }; +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 9ff6dfc69d1e..da3fc9ee636c 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -3058,6 +3058,8 @@ self: super: with self; { deepmerge = callPackage ../development/python-modules/deepmerge { }; + deepsearch-toolkit = callPackage ../development/python-modules/deepsearch-toolkit { }; + deeptoolsintervals = callPackage ../development/python-modules/deeptoolsintervals { }; deepwave = callPackage ../development/python-modules/deepwave { };