I am using AzureOpenAIEncoder in a closed network which can only access the openai resources using httpx proxy. In the AzureOpenAIEncoder class, there is no way to provide that http_client.
Example how I am using Azure openai services:
embedding= AzureOpenAIEmbeddings(model = model name, http_client=htpx.Client())
Note: I am defining all the other credentials as environmental variables like endpoint, api key, version and http proxy.
I have checked the AzureOpenAIEncoder class code and I saw it doesn't have any way to provide the above or similar parameter. There can be one fix, by including the openai client in the constructor of the class. This way I can give the azureopenai client as a parameter to this class.
Please guide me if I am missing something or there is any workaround.
Do let me know if you need more information. I really appreciate the help 🙏
Hi @singh-kun we currently don't have a workaround for this, beyond possibly setting this attribute after initializing the encoder instance, we're happy if you want to contribute this as a feature though
I am using AzureOpenAIEncoder in a closed network which can only access the openai resources using httpx proxy. In the AzureOpenAIEncoder class, there is no way to provide that http_client.
Example how I am using Azure openai services: embedding= AzureOpenAIEmbeddings(model = model name, http_client=htpx.Client())
Note: I am defining all the other credentials as environmental variables like endpoint, api key, version and http proxy.
I have checked the AzureOpenAIEncoder class code and I saw it doesn't have any way to provide the above or similar parameter. There can be one fix, by including the openai client in the constructor of the class. This way I can give the azureopenai client as a parameter to this class.
Please guide me if I am missing something or there is any workaround.
Do let me know if you need more information. I really appreciate the help 🙏