2023-08-04 22:07:22 +00:00
|
|
|
{ lib
|
|
|
|
, buildPythonPackage
|
|
|
|
, fetchFromGitHub
|
2023-10-09 19:29:22 +00:00
|
|
|
, freezegun
|
2023-08-04 22:07:22 +00:00
|
|
|
, poetry-core
|
|
|
|
, pydantic
|
|
|
|
, pytest-asyncio
|
2023-08-22 20:05:09 +00:00
|
|
|
, pytestCheckHook
|
|
|
|
, pythonOlder
|
|
|
|
, requests
|
2023-08-04 22:07:22 +00:00
|
|
|
}:
|
|
|
|
|
2023-08-22 20:05:09 +00:00
|
|
|
buildPythonPackage rec {
|
2023-08-04 22:07:22 +00:00
|
|
|
pname = "langsmith";
|
2024-01-25 14:12:00 +00:00
|
|
|
version = "0.0.83";
|
|
|
|
pyproject = true;
|
2023-08-04 22:07:22 +00:00
|
|
|
|
2023-08-22 20:05:09 +00:00
|
|
|
disabled = pythonOlder "3.8";
|
|
|
|
|
2023-08-04 22:07:22 +00:00
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "langchain-ai";
|
2023-08-22 20:05:09 +00:00
|
|
|
repo = "langsmith-sdk";
|
|
|
|
rev = "refs/tags/v${version}";
|
2024-01-25 14:12:00 +00:00
|
|
|
hash = "sha256-WRrwekh4pcn3I0U/A2Q91ePrRx2RUC3XX+z4bez0BzU=";
|
2023-08-04 22:07:22 +00:00
|
|
|
};
|
|
|
|
|
2023-08-22 20:05:09 +00:00
|
|
|
sourceRoot = "${src.name}/python";
|
2023-08-04 22:07:22 +00:00
|
|
|
|
|
|
|
nativeBuildInputs = [
|
|
|
|
poetry-core
|
|
|
|
];
|
|
|
|
|
|
|
|
propagatedBuildInputs = [
|
|
|
|
pydantic
|
|
|
|
requests
|
|
|
|
];
|
|
|
|
|
|
|
|
nativeCheckInputs = [
|
2023-10-09 19:29:22 +00:00
|
|
|
freezegun
|
2023-08-04 22:07:22 +00:00
|
|
|
pytest-asyncio
|
|
|
|
pytestCheckHook
|
|
|
|
];
|
|
|
|
|
|
|
|
disabledTests = [
|
2023-08-22 20:05:09 +00:00
|
|
|
# These tests require network access
|
2023-08-04 22:07:22 +00:00
|
|
|
"integration_tests"
|
2023-11-16 04:20:00 +00:00
|
|
|
# due to circular import
|
|
|
|
"test_as_runnable"
|
|
|
|
"test_as_runnable_batch"
|
|
|
|
"test_as_runnable_async"
|
|
|
|
"test_as_runnable_async_batch"
|
2024-01-25 14:12:00 +00:00
|
|
|
# requires git repo
|
|
|
|
"test_git_info"
|
2023-11-16 04:20:00 +00:00
|
|
|
];
|
|
|
|
|
|
|
|
disabledTestPaths = [
|
|
|
|
# due to circular import
|
|
|
|
"tests/integration_tests/test_client.py"
|
2023-08-04 22:07:22 +00:00
|
|
|
];
|
|
|
|
|
2023-08-22 20:05:09 +00:00
|
|
|
pythonImportsCheck = [
|
|
|
|
"langsmith"
|
|
|
|
];
|
2023-08-04 22:07:22 +00:00
|
|
|
|
2023-11-16 04:20:00 +00:00
|
|
|
__darwinAllowLocalNetworking = true;
|
|
|
|
|
2023-08-04 22:07:22 +00:00
|
|
|
meta = with lib; {
|
|
|
|
description = "Client library to connect to the LangSmith LLM Tracing and Evaluation Platform";
|
2023-08-22 20:05:09 +00:00
|
|
|
homepage = "https://github.com/langchain-ai/langsmith-sdk";
|
|
|
|
changelog = "https://github.com/langchain-ai/langsmith-sdk/releases/tag/v${version}";
|
2023-08-04 22:07:22 +00:00
|
|
|
license = licenses.mit;
|
|
|
|
maintainers = with maintainers; [ natsukium ];
|
|
|
|
};
|
|
|
|
}
|