Skip to content

Conversation

@sgonorov
Copy link
Contributor

@sgonorov sgonorov commented Nov 3, 2025

Migrate dependency management to UV

This PR migrates the project from pip/requirements.txt to UV for faster and more reliable dependency management.

Changes:

  • Added GitHub Actions for UV setup and sync workflows
  • Migrated dependencies from requirements.txt files to pyproject.toml with UV workspace configuration
  • Added pyproject.toml files for tools: cacheviz, llm_bench, and who_what_benchmark
  • Removed legacy requirements.txt files and setup.py files
  • Updated README files to recommend UV installation over pip
  • Updated Dependabot configuration for UV

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR migrates the project from pip-based dependency management to UV for improved performance and reliability. The migration consolidates various requirement files into structured pyproject.toml configurations with UV workspace support.

  • Removed all requirements.txt and setup.py files across tools and tests
  • Added UV workspace configuration with three workspace members: llm_bench, who_what_benchmark, and cacheviz
  • Updated documentation to recommend UV installation and usage over pip commands

Reviewed Changes

Copilot reviewed 23 out of 24 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
tools/who_what_benchmark/ Converted from setup.py/requirements.txt to pyproject.toml with optional dependencies for GPTQ
tools/llm_bench/ Migrated multiple requirement files to consolidated pyproject.toml with conversion and GPTQ extras
tools/cacheviz/ Simple conversion from requirements.txt to pyproject.toml
tests/python_tests/ Removed requirements.txt, dependencies moved to main pyproject.toml
samples/ Removed requirement files, dependencies consolidated into main pyproject.toml dependency groups
pyproject.toml Added UV workspace config, dependency groups, and custom index sources
README files Updated installation instructions to recommend UV over pip
.github/ Added UV setup/sync actions and updated Dependabot for UV support

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These 3 files are included into openvino genai archive describing what needs to be installed in this case. I think they should stay

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

So for now don't remove any requirements.txt from the project?

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's OK to remove tests/python_tests/requirements.txt and requirements-build.txt

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Validation team isn't ready for that change probably. @sbalandi can this change be kept?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

let's discuss it with validation team, I will write letter

packages=find_packages(),
install_requires=required,
entry_points={"console_scripts": ["wwb=whowhatbench.wwb:main"]},
package_data={"whowhatbench": ["prompts/*.yaml"]}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Are there also prompts in the package, when wwb is installed with UV?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, missed this one. Fixed 👍

@@ -0,0 +1,30 @@
name: 'Setup UV'
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

uv provided install/setup actions - https://docs.astral.sh/uv/guides/integration/github/

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed

@@ -0,0 +1,61 @@
name: 'UV Sync Dependencies'
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

that sync should be done by dependabot

runs:
using: "composite"
steps:
- name: Install local wheels
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why do we need one more action, please use .github/actions/install_wheel

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed

testing = ["pytest>=6.0"]

[dependency-groups]
samples = [
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks, like those dependencies should be in the [project.optional-dependencies] section

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Moved them 👍

@mryzhov
Copy link
Contributor

mryzhov commented Nov 4, 2025

Did you check that dependabot updates all requirements from the uv.lock file? Previously it didn't and we decided to use poetry instead.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I believe we still use it in Jenkins

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants