Unverified Commit 588e0099 authored by Aleksana's avatar Aleksana Committed by GitHub
Browse files

python3Packages.langchain-fireworks: init at 0.3.0 (#403131)

parents 1376aefd 804880c2
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -10,6 +10,7 @@ declare -ar packages=(
    langchain-chroma
    langchain-community
    langchain-core
    langchain-fireworks
    langchain-groq
    langchain-huggingface
    langchain-mistralai
+79 −0
Original line number Diff line number Diff line
{
  lib,
  buildPythonPackage,
  fetchFromGitHub,
  nix-update-script,

  # build-system
  pdm-backend,

  # dependencies
  aiohttp,
  fireworks-ai,
  langchain-core,
  openai,
  pydantic,

  # tests
  langchain-tests,
  pytest-asyncio,
  pytestCheckHook,
}:

buildPythonPackage rec {
  pname = "langchain-fireworks";
  version = "0.3.0";
  pyproject = true;

  src = fetchFromGitHub {
    owner = "langchain-ai";
    repo = "langchain";
    tag = "langchain-fireworks==${version}";
    hash = "sha256-OZou323FAk2I4YuQV7sllbzDwFQWy/90FK3gIHnEBd0=";
  };

  sourceRoot = "${src.name}/libs/partners/fireworks";

  build-system = [ pdm-backend ];

  dependencies = [
    aiohttp
    fireworks-ai
    langchain-core
    openai
    pydantic
  ];

  pythonRelaxDeps = [
    # Each component release requests the exact latest core.
    # That prevents us from updating individual components.
    "langchain-core"
  ];

  nativeCheckInputs = [
    langchain-tests
    pytest-asyncio
    pytestCheckHook
  ];

  pytestFlagsArray = [ "tests/unit_tests" ];

  pythonImportsCheck = [ "langchain_fireworks" ];

  passthru.updateScript = nix-update-script {
    extraArgs = [
      "--version-regex"
      "langchain-fireworks==([0-9.]+)"
    ];
  };

  meta = {
    changelog = "https://github.com/langchain-ai/langchain/releases/tag/langchain-fireworks==${version}";
    description = "Build LangChain applications with Fireworks";
    homepage = "https://github.com/langchain-ai/langchain/tree/master/libs/partners/fireworks";
    license = lib.licenses.mit;
    maintainers = [
      lib.maintainers.sarahec
    ];
  };
}
+2 −0
Original line number Diff line number Diff line
@@ -7538,6 +7538,8 @@ self: super: with self; {
  langchain-core = callPackage ../development/python-modules/langchain-core { };
  langchain-fireworks = callPackage ../development/python-modules/langchain-fireworks { };
  langchain-groq = callPackage ../development/python-modules/langchain-groq { };
  langchain-huggingface = callPackage ../development/python-modules/langchain-huggingface { };