You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
(mostly due to inputs needing to be replaced by text in the python client, but it's not limited to that)
here are some examples of some of my findings
text-classification
this does not work
as for the hub implementation
from huggingface_hub import InferenceClient
client = InferenceClient(
provider="hf-inference",
+ model="ProsusAI/finbert",+ provider="hf-inference",
api_key="hf_xxxxxxxxxxxxxxxxxxxxxxxx"
)
result = client.text_classification(
- model="ProsusAI/finbert",- inputs="I like you. I love you",- provider="hf-inference",+ text="I like you. I love you",
)
print(result)
translation
python
from huggingface_hub import InferenceClient
client = InferenceClient(
+ model="facebook/mbart-large-50-many-to-many-mmt",
provider="hf-inference",
api_key="hf_xxxxxxxxxxxxxxxxxxxxxxxx"
)
result = client.translation(
- model="facebook/mbart-large-50-many-to-many-mmt",- inputs="Меня зовут Вольфганг и я живу в Берлине",+ text ="Меня зовут Вольфганг и я живу в Берлине", + src_lang="ru_RU",+ tgt_lang ="en_XX"- provider="hf-inference",
)
print(result)
(mostly due to inputs needing to be replaced by text in the python client, but it's not limited to that)
here are some examples of some of my findings
this does not work
as for the hub implementation
The text was updated successfully, but these errors were encountered: