From ec751ae680d52db62ebda3785144cee5d2c04c96 Mon Sep 17 00:00:00 2001 From: Tony Wu <28306721+tonywu71@users.noreply.github.com> Date: Sun, 5 Jul 2026 00:35:06 +0100 Subject: [PATCH 1/4] build: drop speculative upper bounds on runtime and optional deps MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - Floor-only `torch`, `triton`, `pylate`, `colpali-engine` so downstream envs can resolve them freely; caps on a published wheel can't be overridden by installers and can conflict with torch's own triton pin - `patch_pylate()` / `patch_colpali_engine()` already no-op above the native-LIK cutoff, so no future major reaches the monkeypatched internals - Keep dev-tool caps (`pytest`, `ruff`, `ty`, `numpy`) — dev extras never reach downstream installers --- CHANGELOG.md | 11 +++++++++++ pyproject.toml | 12 ++++++------ uv.lock | 16 ++++++++-------- 3 files changed, 25 insertions(+), 14 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 2b2ef32..b74aece 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,17 @@ All notable changes to this project will be documented here. Format follows [Keep a Changelog](https://keepachangelog.com/en/1.1.0/) and the project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +## [Unreleased] + +### Changed + +- Dropped the speculative upper bounds on runtime and optional dependencies + (`torch`, `triton`, `pylate`, `colpali-engine`): they are floor-only now, so + a downstream env can resolve them freely. `patch_pylate()` / `patch_colpali_engine()` + already no-op above the native-LIK cutoff (`pylate>=1.5.1`, `colpali-engine>=0.3.17`), + so no future major can reach the monkeypatched internals. Dev-tool caps + (`pytest`, `ruff`, `ty`, `numpy`) stay — they never reach downstream installers. + ## [0.4.4] - 2026-06-10 ### Fixed diff --git a/pyproject.toml b/pyproject.toml index 6e32213..4550d58 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -41,9 +41,9 @@ classifiers = [ dependencies = [ # Torch index (CPU/CUDA) is selected by the `torch-cpu`/`torch-cuda` extras; # plain `uv sync` without an extra falls back to PyPI's default wheel. - "torch>=2.5,<3", + "torch>=2.5", # Triton only ships on Linux CUDA wheels; macOS/Windows use the pure-PyTorch reference. - "triton>=3.0,<4; platform_system=='Linux'", + "triton>=3.0; platform_system=='Linux'", ] [project.optional-dependencies] @@ -60,7 +60,7 @@ dev = [ # handles both module layouts: `pylate.scores.scores` (<=1.4) and # `pylate.scores.colbert` + the ColBERTScores loss routing (>=1.5). On # >=1.5.1 PyLate has native LIK support and the patch is a deprecated no-op. -pylate = ["pylate>=1.3.3,<2"] +pylate = ["pylate>=1.3.3"] # colpali_engine drop-in (`patch_colpali_engine()`). >=0.3.10: first release # with the patched-API surface (the ColbertLoss family + the # `BaseVisualRetrieverProcessor.score_multi_vector` helper). On >=0.3.17 @@ -69,10 +69,10 @@ pylate = ["pylate>=1.3.3,<2"] # colpali_engine's torchvision/transformers tree conflicts with the cu124 # torch wheel, so it's never co-activated with `torch-cuda` (the GPU parity # tests install it out-of-band — see scripts/sky_colpali_compat_test.yaml). -colpali = ["colpali-engine>=0.3.10,<1"] +colpali = ["colpali-engine>=0.3.10"] # Mutually exclusive wheel sources; CI uses `torch-cpu`, GPU dev uses `torch-cuda`. -torch-cpu = ["torch>=2.5,<3"] -torch-cuda = ["torch>=2.5,<3"] +torch-cpu = ["torch>=2.5"] +torch-cuda = ["torch>=2.5"] [project.urls] Homepage = "https://github.com/hcompai/late-interaction-kernels" diff --git a/uv.lock b/uv.lock index cfce006..b645d76 100644 --- a/uv.lock +++ b/uv.lock @@ -859,17 +859,17 @@ torch-cuda = [ [package.metadata] requires-dist = [ - { name = "colpali-engine", marker = "extra == 'colpali'", specifier = ">=0.3.10,<1" }, + { name = "colpali-engine", marker = "extra == 'colpali'", specifier = ">=0.3.10" }, { name = "numpy", marker = "extra == 'dev'", specifier = ">=1.21,<3" }, - { name = "pylate", marker = "extra == 'pylate'", specifier = ">=1.3.3,<2" }, + { name = "pylate", marker = "extra == 'pylate'", specifier = ">=1.3.3" }, { name = "pytest", marker = "extra == 'dev'", specifier = ">=7,<10" }, { name = "ruff", marker = "extra == 'dev'", specifier = ">=0.4,<1" }, - { name = "torch", specifier = ">=2.5,<3" }, - { name = "torch", marker = "sys_platform == 'darwin' and extra == 'torch-cpu'", specifier = ">=2.5,<3" }, - { name = "torch", marker = "sys_platform != 'darwin' and extra == 'torch-cpu'", specifier = ">=2.5,<3", index = "https://download.pytorch.org/whl/cpu", conflict = { package = "late-interaction-kernels", extra = "torch-cpu" } }, - { name = "torch", marker = "sys_platform == 'linux' and extra == 'torch-cuda'", specifier = ">=2.5,<3", index = "https://download.pytorch.org/whl/cu124", conflict = { package = "late-interaction-kernels", extra = "torch-cuda" } }, - { name = "torch", marker = "sys_platform != 'linux' and extra == 'torch-cuda'", specifier = ">=2.5,<3" }, - { name = "triton", marker = "sys_platform == 'linux'", specifier = ">=3.0,<4" }, + { name = "torch", specifier = ">=2.5" }, + { name = "torch", marker = "sys_platform == 'darwin' and extra == 'torch-cpu'", specifier = ">=2.5" }, + { name = "torch", marker = "sys_platform != 'darwin' and extra == 'torch-cpu'", specifier = ">=2.5", index = "https://download.pytorch.org/whl/cpu", conflict = { package = "late-interaction-kernels", extra = "torch-cpu" } }, + { name = "torch", marker = "sys_platform == 'linux' and extra == 'torch-cuda'", specifier = ">=2.5", index = "https://download.pytorch.org/whl/cu124", conflict = { package = "late-interaction-kernels", extra = "torch-cuda" } }, + { name = "torch", marker = "sys_platform != 'linux' and extra == 'torch-cuda'", specifier = ">=2.5" }, + { name = "triton", marker = "sys_platform == 'linux'", specifier = ">=3.0" }, { name = "ty", marker = "extra == 'dev'", specifier = ">=0.0.20,<0.1" }, ] provides-extras = ["colpali", "dev", "pylate", "torch-cpu", "torch-cuda"] From a3c98b8e0c9b02632e1be222ff5e9c786e053634 Mon Sep 17 00:00:00 2001 From: Tony Wu <28306721+tonywu71@users.noreply.github.com> Date: Sun, 5 Jul 2026 00:38:00 +0100 Subject: [PATCH 2/4] docs: prepare CHANGELOG for the 0.4.5 release --- CHANGELOG.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index b74aece..2554a34 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,7 +4,7 @@ All notable changes to this project will be documented here. Format follows [Keep a Changelog](https://keepachangelog.com/en/1.1.0/) and the project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). -## [Unreleased] +## [0.4.5] - 2026-07-05 ### Changed From de59aeb16446d5cb25847b1ff415814aca819cdb Mon Sep 17 00:00:00 2001 From: Tony Wu <28306721+tonywu71@users.noreply.github.com> Date: Sun, 5 Jul 2026 09:59:08 +0100 Subject: [PATCH 3/4] docs: tighten the 0.4.5 changelog entry --- CHANGELOG.md | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 2554a34..b8c5428 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -8,12 +8,9 @@ project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). ### Changed -- Dropped the speculative upper bounds on runtime and optional dependencies - (`torch`, `triton`, `pylate`, `colpali-engine`): they are floor-only now, so - a downstream env can resolve them freely. `patch_pylate()` / `patch_colpali_engine()` - already no-op above the native-LIK cutoff (`pylate>=1.5.1`, `colpali-engine>=0.3.17`), - so no future major can reach the monkeypatched internals. Dev-tool caps - (`pytest`, `ruff`, `ty`, `numpy`) stay — they never reach downstream installers. +- Dropped the upper bounds on `torch`, `triton`, `pylate`, and `colpali-engine` + so downstream envs resolve them freely. Dev-tool caps (`pytest`, `ruff`, `ty`, + `numpy`) stay, since they never reach downstream installers. ## [0.4.4] - 2026-06-10 From 09fb21eddc8329e60c92008212fbdb966e6b8fec Mon Sep 17 00:00:00 2001 From: Tony Wu <28306721+tonywu71@users.noreply.github.com> Date: Sun, 5 Jul 2026 14:58:55 +0200 Subject: [PATCH 4/4] docs: tighten pyproject dependency comments --- pyproject.toml | 36 +++++++++++++++--------------------- 1 file changed, 15 insertions(+), 21 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index 4550d58..abc38ef 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -39,38 +39,32 @@ classifiers = [ "Topic :: Scientific/Engineering :: Artificial Intelligence", ] dependencies = [ - # Torch index (CPU/CUDA) is selected by the `torch-cpu`/`torch-cuda` extras; - # plain `uv sync` without an extra falls back to PyPI's default wheel. + # Wheel source comes from the `torch-cpu`/`torch-cuda` extras; bare install uses PyPI's default. "torch>=2.5", - # Triton only ships on Linux CUDA wheels; macOS/Windows use the pure-PyTorch reference. + # Triton ships Linux-only wheels; elsewhere we use the PyTorch reference path. "triton>=3.0; platform_system=='Linux'", ] [project.optional-dependencies] -# Everything needed to run tests and linting locally. +# Local test + lint stack. Dev-only caps never reach downstream installers. dev = [ "numpy>=1.21,<3", "pytest>=7,<10", "ruff>=0.4,<1", - # ty is alpha; every 0.0.z can break — cap below 0.1 and revisit each bump. + # ty is alpha; any 0.0.z can break. Revisit the cap on each bump. "ty>=0.0.20,<0.1", ] -# PyLate drop-in (`patch_pylate()`). >=1.3.3: first release with the -# `(queries_mask, documents_mask)` signature we patch against. The patch -# handles both module layouts: `pylate.scores.scores` (<=1.4) and -# `pylate.scores.colbert` + the ColBERTScores loss routing (>=1.5). On -# >=1.5.1 PyLate has native LIK support and the patch is a deprecated no-op. +# `patch_pylate()` target. Floor is the first release with the mask signature we +# patch; no upper cap because the patch no-ops on PyLate >=1.5.1 (native LIK), so +# a future major never reaches our monkeypatch of PyLate internals. pylate = ["pylate>=1.3.3"] -# colpali_engine drop-in (`patch_colpali_engine()`). >=0.3.10: first release -# with the patched-API surface (the ColbertLoss family + the -# `BaseVisualRetrieverProcessor.score_multi_vector` helper). On >=0.3.17 -# colpali-engine has native LIK support and the patch is a deprecated no-op. -# CPU-only extra: -# colpali_engine's torchvision/transformers tree conflicts with the cu124 -# torch wheel, so it's never co-activated with `torch-cuda` (the GPU parity -# tests install it out-of-band — see scripts/sky_colpali_compat_test.yaml). +# `patch_colpali_engine()` target. Floor is the first release with the API we patch; +# no upper cap because the patch no-ops on colpali-engine >=0.3.17 (native LIK). +# Kept CPU-only: its torchvision/transformers tree conflicts with the cu124 torch +# wheel, so it's never co-activated with `torch-cuda` (GPU parity tests install it +# out-of-band, see scripts/sky_colpali_compat_test.yaml). colpali = ["colpali-engine>=0.3.10"] -# Mutually exclusive wheel sources; CI uses `torch-cpu`, GPU dev uses `torch-cuda`. +# Mutually exclusive wheel sources: CI uses `torch-cpu`, GPU dev uses `torch-cuda`. torch-cpu = ["torch>=2.5"] torch-cuda = ["torch>=2.5"] @@ -91,8 +85,8 @@ select = ["E", "F", "I", "B", "UP"] # B023: benchmark closures intentionally capture loop vars. ignore = ["E501", "B008", "E741", "B023"] -# Per-extra wheel source: `--extra torch-cpu` for CI/CPU, `--extra torch-cuda` for GPU. -# PyPI's default torch supports MPS on macOS; pytorch-cpu has no Darwin wheels. +# The two extras are mutually exclusive wheel sources. macOS uses PyPI's default +# torch for MPS; pytorch-cpu has no Darwin wheels. [tool.uv] conflicts = [[{ extra = "torch-cpu" }, { extra = "torch-cuda" }]]