Example only using free Hugging Face inference and embeddings #211
-
Pls. create a working example which only uses free Hugging Face endpoints for both embeddings and completion. |
Beta Was this translation helpful? Give feedback.
Replies: 3 comments 1 reply
-
Hi @vanetreg, thank you for suggestion! I will definetely update our examples according your suggestion :) For quick solution, you can set your
also you might need to set your os.environ['HUGGINGFACE_API_KEY'] = ... Hope it helps. If you have any more suggestions or questions please share them as well. |
Beta Was this translation helpful? Give feedback.
-
Hi @SeeknnDestroy , The code used last time is:
So the main problems were:
So finally I'll generate a HF space and keep testing it there... |
Beta Was this translation helpful? Give feedback.
-
worked, though embedding triggered a rate limit error, which I think should be handled properly for every inference, not only for HF.
I have a free HF token, but considering HF Pro (9 USD / month), if eg. AutoLLM works with HF models well. |
Beta Was this translation helpful? Give feedback.
Hi @vanetreg, thank you for suggestion! I will definetely update our examples according your suggestion :)
For quick solution, you can set your
llm_model
andembed_model
parameters as Hugging Face models and you are good to go! If you have hosted it on Huggingface, you also should give thellm_api
parameter as your hosted url:also you might need to set your
HUGGINGFACE_API_KEY
env variable:Hope it helps. If you have any more suggestions or questions ple…