databricks-ml-examples
databricks-ml-examples copied to clipboard
02_mlflow_logging_inference.py fails to create Endpoint (cannot import name 'cached_download' from 'huggingface_hub')
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"
],