databricks-ml-examples icon indicating copy to clipboard operation
databricks-ml-examples copied to clipboard

02_mlflow_logging_inference.py fails to create Endpoint (cannot import name 'cached_download' from 'huggingface_hub')

Open bryn-baritompa-db opened this issue 1 year ago • 0 comments

Issue

Running llm-models/embedding/bge/bge-m3/02_mlflow_logging_inference.py fails to create a Model Serving Endpoint.
The Endpoint log shows the following error: ImportError: cannot import name 'cached_download' from 'huggingface_hub'

Cause

Breaking changes in huggingface_hub v0.26.0

Temporary workaround

Pin the versions as follows here

pip_requirements=[
      "mlflow==2.11.2",
      "sentence-transformers==2.7.0",
      "torch==2.2.1",
      "transformers==4.41.2",
      "huggingface-hub==0.24.6"
],

bryn-baritompa-db avatar Nov 01 '24 01:11 bryn-baritompa-db