Disable Hosted inference API

Hi,

How can I disable the hosted inference API for my model in HF?

Thanks

I don’t know if you can. Out of curiosity, what is your use-case that you do not want that the widget? If you want to private models you’ll need to get a paid subscription AFAIK.

I’d like to disable the widget because the example is misleading.

My model is a text classification model on scientific papers allenai/longformer-scico · Hugging Face while the example is I like you. I love you. Also, my model uses global attention for some tokens and there is no way to add preprocessing in the widget.

Hi,

Yes you can disable it, or you change the default text that is in there.

To disable it, you can add the following to the top of the README:

---
inference: false
---

To change the default text, you can add the following to the README:

---
widget:
- text: 'hello this is an example'
---
2 Likes

Note: this can be found in the documentation of the hub: Model Repos docs

1 Like