Files
nixpkgs/pkgs/development/python-modules/langchain-fireworks/default.nix
2026-06-09 16:58:00 -07:00

89 lines
1.7 KiB
Nix

{
lib,
buildPythonPackage,
fetchFromGitHub,
# build-system
hatchling,
# dependencies
aiohttp,
fireworks-ai,
langchain-core,
openai,
pydantic,
# tests
langchain-tests,
pytest-asyncio,
pytestCheckHook,
# passthru
gitUpdater,
}:
buildPythonPackage (finalAttrs: {
pname = "langchain-fireworks";
version = "1.4.2";
pyproject = true;
__structuredAttrs = true;
strictDeps = true;
src = fetchFromGitHub {
owner = "langchain-ai";
repo = "langchain";
tag = "langchain-fireworks==${finalAttrs.version}";
hash = "sha256-d0Pd44/+YX+eOZ9a5P3V9cBASTEW/vvLUv5Kt5nWI8w=";
};
sourceRoot = "${finalAttrs.src.name}/libs/partners/fireworks";
build-system = [ hatchling ];
dependencies = [
aiohttp
fireworks-ai
langchain-core
openai
pydantic
];
pythonRelaxDeps = [
"fireworks-ai"
"langchain-core"
];
nativeCheckInputs = [
langchain-tests
pytest-asyncio
pytestCheckHook
];
enabledTestPaths = [ "tests/unit_tests" ];
disabledTests = [
# Fails when langchain-core gets ahead of this package
"test_serdes"
];
pythonImportsCheck = [ "langchain_fireworks" ];
passthru = {
# python updater script sets the wrong tag
skipBulkUpdate = true;
updateScript = gitUpdater {
rev-prefix = "langchain-fireworks==";
};
};
meta = {
changelog = "https://github.com/langchain-ai/langchain/releases/tag/${finalAttrs.src.tag}";
description = "Build LangChain applications with Fireworks";
homepage = "https://github.com/langchain-ai/langchain/tree/master/libs/partners/fireworks";
license = lib.licenses.mit;
maintainers = with lib.maintainers; [
sarahec
];
};
})