python3Packages.llm-deepseek: init at 0.1.6

This commit is contained in:
Philip Taron
2025-05-31 20:22:52 -07:00
parent 31d4b6f6cd
commit d8b57ca3c2
4 changed files with 70 additions and 0 deletions
+3
View File
@@ -4,6 +4,7 @@
enable-llm-anthropic ? false,
enable-llm-cmd ? false,
enable-llm-command-r ? false,
enable-llm-deepseek ? false,
enable-llm-gemini ? false,
enable-llm-grok ? false,
enable-llm-groq ? false,
@@ -22,6 +23,7 @@ let
llm-anthropic
llm-cmd
llm-command-r
llm-deepseek
llm-gemini
llm-gguf
llm-grok
@@ -41,6 +43,7 @@ toPythonApplication (
++ lib.optionals enable-llm-anthropic [ llm-anthropic ]
++ lib.optionals enable-llm-cmd [ llm-cmd ]
++ lib.optionals enable-llm-cmd [ llm-command-r ]
++ lib.optionals enable-llm-deepseek [ llm-deepseek ]
++ lib.optionals enable-llm-gemini [ llm-gemini ]
++ lib.optionals enable-llm-gguf [ llm-gguf ]
++ lib.optionals enable-llm-grok [ llm-grok ]
@@ -0,0 +1,43 @@
{
lib,
callPackage,
buildPythonPackage,
fetchFromGitHub,
setuptools,
llm,
groq,
}:
buildPythonPackage rec {
pname = "llm-deepseek";
version = "0.1.6";
pyproject = true;
src = fetchFromGitHub {
owner = "abrasumente233";
repo = "llm-deepseek";
tag = version;
hash = "sha256-yrNvIGnU9Q/0H786DsM0wGEwfxZYIk8IXhqC4mWaQAA=";
};
build-system = [
setuptools
llm
];
dependencies = [ ];
pythonImportsCheck = [ "llm_deepseek" ];
passthru.tests = {
llm-plugin = callPackage ./tests/llm-plugin.nix { };
};
meta = {
description = "LLM plugin providing access to Deepseek models.";
homepage = "https://github.com/abrasumente233/llm-deepseek";
changelog = "https://github.com/abrasumente233/llm-deepseek/releases/tag/${version}/CHANGELOG.md";
license = lib.licenses.asl20;
maintainers = with lib.maintainers; [ philiptaron ];
};
}
@@ -0,0 +1,22 @@
{
runCommand,
python,
yq,
}:
let
venv = python.withPackages (ps: [
ps.llm
ps.llm-deepseek
]);
in
runCommand "llm-deepseek-test-llm-plugin"
{
nativeBuildInputs = [
venv
yq
];
}
''
llm plugins | yq --exit-status 'any(.name == "llm-deepseek")'
touch "$out"
''
+2
View File
@@ -8300,6 +8300,8 @@ self: super: with self; {
llm-command-r = callPackage ../development/python-modules/llm-command-r { };
llm-deepseek = callPackage ../development/python-modules/llm-deepseek { };
llm-gemini = callPackage ../development/python-modules/llm-gemini { };
llm-gguf = callPackage ../development/python-modules/llm-gguf { };