2024-06-14 15:27:06 +00:00
|
|
|
load("@rules_python//python:py_library.bzl", "py_library")
|
2025-05-30 16:42:57 +00:00
|
|
|
load("@rules_python//python/entry_points:py_console_script_binary.bzl", "py_console_script_binary")
|
2025-06-23 09:13:43 +00:00
|
|
|
load("@rules_python//python/uv:lock.bzl", uv_lock = "lock")
|
2025-05-30 16:42:57 +00:00
|
|
|
load("@rules_uv//uv:pip.bzl", "pip_compile")
|
2024-06-14 15:27:06 +00:00
|
|
|
|
|
|
|
|
py_library(
|
|
|
|
|
name = "zml_utils",
|
|
|
|
|
srcs = ["zml_utils.py"],
|
|
|
|
|
visibility = ["//visibility:public"],
|
|
|
|
|
)
|
2025-05-30 16:42:57 +00:00
|
|
|
|
|
|
|
|
py_console_script_binary(
|
|
|
|
|
name = "hf",
|
|
|
|
|
script = "hf",
|
|
|
|
|
pkg = "@huggingface_hub//huggingface_hub:pkg",
|
|
|
|
|
visibility = ["//visibility:public"],
|
|
|
|
|
)
|
|
|
|
|
|
|
|
|
|
pip_compile(
|
|
|
|
|
name = "hf_update_requirements",
|
|
|
|
|
args = [
|
|
|
|
|
"--generate-hashes",
|
|
|
|
|
"--emit-index-url",
|
|
|
|
|
"--emit-find-links",
|
|
|
|
|
"--no-strip-extras",
|
|
|
|
|
"--index-strategy=unsafe-best-match",
|
|
|
|
|
"--upgrade",
|
|
|
|
|
],
|
|
|
|
|
requirements_in = "hf_requirements.in",
|
|
|
|
|
requirements_txt = "hf_requirements.lock.txt",
|
|
|
|
|
tags = [
|
|
|
|
|
"manual",
|
|
|
|
|
],
|
|
|
|
|
)
|