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
I'm using huggingface.chatCompletion and need to be able to provide some cookies to the InferenceClient. I don't see a way to pass that in via create(), which is where the client is instantiated. I also looked at the huggingface_hub implementation, but didn't see a way to set it via module member or environment variable.
The approach I landed on was adding a module-level client_args dictionary, similar to huggingface.api_key and .prompt_builder, and passing anything defined in there when the client is instantiated. If that makes sense and you want to support this, I'm happy to open a PR. Or if you see issues or have suggestions to improve, let me know.
The text was updated successfully, but these errors were encountered:
I'm using
huggingface.chatCompletion
and need to be able to provide some cookies to theInferenceClient
. I don't see a way to pass that in viacreate()
, which is where the client is instantiated. I also looked at thehuggingface_hub
implementation, but didn't see a way to set it via module member or environment variable.The approach I landed on was adding a module-level
client_args
dictionary, similar tohuggingface.api_key
and.prompt_builder
, and passing anything defined in there when the client is instantiated. If that makes sense and you want to support this, I'm happy to open a PR. Or if you see issues or have suggestions to improve, let me know.The text was updated successfully, but these errors were encountered: