mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-06-13 21:25:30 +03:00
python3Packages.llm-tools-quickjs: init at 0.1
This commit is contained in:
parent
2074fa159b
commit
7438a10a79
3 changed files with 55 additions and 1 deletions
|
@ -0,0 +1,50 @@
|
||||||
|
{
|
||||||
|
lib,
|
||||||
|
buildPythonPackage,
|
||||||
|
fetchFromGitHub,
|
||||||
|
setuptools,
|
||||||
|
quickjs,
|
||||||
|
llm,
|
||||||
|
llm-tools-quickjs,
|
||||||
|
llm-echo,
|
||||||
|
pytestCheckHook,
|
||||||
|
writableTmpDirAsHomeHook,
|
||||||
|
}:
|
||||||
|
|
||||||
|
buildPythonPackage rec {
|
||||||
|
pname = "llm-tools-quickjs";
|
||||||
|
version = "0.1";
|
||||||
|
pyproject = true;
|
||||||
|
|
||||||
|
src = fetchFromGitHub {
|
||||||
|
owner = "simonw";
|
||||||
|
repo = "llm-tools-quickjs";
|
||||||
|
tag = version;
|
||||||
|
hash = "sha256-Si3VcHnRUj8Q/N8pRhltPOM6K64TX9DBH/u4WQxQJjQ=";
|
||||||
|
};
|
||||||
|
|
||||||
|
build-system = [
|
||||||
|
setuptools
|
||||||
|
llm
|
||||||
|
];
|
||||||
|
|
||||||
|
dependencies = [ quickjs ];
|
||||||
|
|
||||||
|
nativeCheckInputs = [
|
||||||
|
llm-echo
|
||||||
|
pytestCheckHook
|
||||||
|
writableTmpDirAsHomeHook
|
||||||
|
];
|
||||||
|
|
||||||
|
pythonImportsCheck = [ "llm_tools_quickjs" ];
|
||||||
|
|
||||||
|
passthru.tests = llm.mkPluginTest llm-tools-quickjs;
|
||||||
|
|
||||||
|
meta = {
|
||||||
|
description = "JavaScript execution as a tool for LLM";
|
||||||
|
homepage = "https://github.com/simonw/llm-tools-quickjs";
|
||||||
|
changelog = "https://github.com/simonw/llm-tools-quickjs/releases/tag/${version}/CHANGELOG.md";
|
||||||
|
license = lib.licenses.asl20;
|
||||||
|
maintainers = with lib.maintainers; [ philiptaron ];
|
||||||
|
};
|
||||||
|
}
|
|
@ -82,6 +82,7 @@ let
|
||||||
llm-sentence-transformers ? false,
|
llm-sentence-transformers ? false,
|
||||||
llm-templates-fabric ? false,
|
llm-templates-fabric ? false,
|
||||||
llm-templates-github ? false,
|
llm-templates-github ? false,
|
||||||
|
llm-tools-quickjs ? false,
|
||||||
llm-venice ? false,
|
llm-venice ? false,
|
||||||
llm-video-frames ? false,
|
llm-video-frames ? false,
|
||||||
...
|
...
|
||||||
|
@ -162,7 +163,8 @@ let
|
||||||
patches = [ ./001-disable-install-uninstall-commands.patch ];
|
patches = [ ./001-disable-install-uninstall-commands.patch ];
|
||||||
|
|
||||||
postPatch = ''
|
postPatch = ''
|
||||||
substituteInPlace llm/cli.py --replace-fail "@listOfPackagedPlugins@" "$(< ${listOfPackagedPlugins})"
|
substituteInPlace llm/cli.py \
|
||||||
|
--replace-fail "@listOfPackagedPlugins@" "$(< ${listOfPackagedPlugins})"
|
||||||
'';
|
'';
|
||||||
|
|
||||||
dependencies = [
|
dependencies = [
|
||||||
|
|
|
@ -8334,6 +8334,8 @@ self: super: with self; {
|
||||||
|
|
||||||
llm-templates-github = callPackage ../development/python-modules/llm-templates-github { };
|
llm-templates-github = callPackage ../development/python-modules/llm-templates-github { };
|
||||||
|
|
||||||
|
llm-tools-quickjs = callPackage ../development/python-modules/llm-tools-quickjs { };
|
||||||
|
|
||||||
llm-venice = callPackage ../development/python-modules/llm-venice { };
|
llm-venice = callPackage ../development/python-modules/llm-venice { };
|
||||||
|
|
||||||
llm-video-frames = callPackage ../development/python-modules/llm-video-frames { };
|
llm-video-frames = callPackage ../development/python-modules/llm-video-frames { };
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue