Something went wrong. Try again.
Nix Packages collection & NixOS github.com/NixOS/nixpkgs
Something went wrong. Try again.
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101{ lib, buildPythonPackage, fetchFromGitHub,
# build-system pdm-backend,
# dependencies anyio, httpx, httpx-ws, msgspec, typing-extensions,
# tests pytest-asyncio, pytestCheckHook,}:
buildPythonPackage (finalAttrs: { pname = "lmstudio"; version = "1.6.0b1"; pyproject = true; __structuredAttrs = true;
src = fetchFromGitHub { owner = "lmstudio-ai"; repo = "lmstudio-python"; tag = finalAttrs.version; hash = "sha256-QJNVlkSmwinoJ/cMCDpYzYDmd6Q8AGiLHHdk36Fqtk8="; };
build-system = [ pdm-backend ];
dependencies = [ anyio httpx httpx-ws msgspec typing-extensions ];
pythonImportsCheck = [ "lmstudio" ];
nativeCheckInputs = [ pytest-asyncio pytestCheckHook ];
pytestFlags = [ # pytest.PytestRemovedIn10Warning: Passing a non-Collection iterable to parametrize is deprecated "-Wignore::pytest.PytestRemovedIn10Warning" ];
disabledTests = [ # lmstudio.LMStudioRuntimeError: Local API host port is not yet resolved. "test_session_disconnected_async" ];
disabledTestPaths = [ # ModuleNotFoundError: No module named 'pytest_subtests' "tests/async/test_model_catalog_async.py" "tests/sync/test_model_catalog_sync.py" "tests/test_inference.py"
# lmstudio.LMStudioRuntimeError: Local API host port is not yet resolved. "tests/async/test_embedding_async.py" "tests/async/test_images_async.py" "tests/async/test_inference_async.py" "tests/async/test_llm_async.py" "tests/async/test_model_handles_async.py" "tests/async/test_repository_async.py" "tests/async/test_sdk_bypass_async.py" "tests/sync/test_embedding_sync.py" "tests/sync/test_images_sync.py" "tests/sync/test_inference_sync.py" "tests/sync/test_llm_sync.py" "tests/sync/test_model_handles_sync.py" "tests/sync/test_repository_sync.py" "tests/sync/test_sdk_bypass_sync.py" "tests/test_convenience_api.py" "tests/test_logging.py" "tests/test_plugin_examples.py" "tests/test_sessions.py" "tests/test_timeouts.py" ];
__darwinAllowLocalNetworking = true;
meta = { description = "LM Studio Python SDK"; homepage = "https://github.com/lmstudio-ai/lmstudio-python"; changelog = "https://github.com/lmstudio-ai/lmstudio-python/releases/tag/${finalAttrs.src.tag}"; license = lib.licenses.mit; maintainers = with lib.maintainers; [ GaetanLepage ]; };})