Spaces:
Running
on
CPU Upgrade
Running
on
CPU Upgrade
More logging + timeout if model is not loaded + url not needed
#4
by
Wauplin
HF staff
- opened
Hey @merve ๐ค
Suggesting a couple of changes in how to use huggingface_hub
. Feel free to ignore if you prefer the way it was:
- Enable more logging using
logging.set_verbosity_info()
=> this will help in case you need to debug something not work. Typically if the endpoint is not available. - Add
timeout=60
to the client => by default theInferenceClient
will retry indefinitely until the model is ready. You might want to set a timeout here instead. - When using the InferenceAPI, no need to paste the full url. Setting
model="meta-llama/Llama-2-7b-chat-hf"
is enough (pasting the full URL is not wrong btw)