Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support Use of LLM's Deployed in Azure Open AI #20

Open
wants to merge 6 commits into
base: main
Choose a base branch
from

Conversation

chartsNgraphs
Copy link

Summary

While the package abstracts away the llm connections in a very useful way, being unable to uniquely configure the langchain llm instantiation means that Azure OpenAI can't be used. The reason for this is that in lanchain, Azure deployed LLM's require different arguments than standard openai llm's do.

This Fix

This fix introduces bare minimum functionality to allow promptimize to work with Azure OpenAI. LangChain accepts the OPENAI_API_TYPE=='azure' environment variable, but when this is present it expects at least a deployment name to accompany the modelname. base url and key are passed via environment variables the same as a non-azure deployment.
With this fix, Azure users can simply provide the api type of 'azure' accompanies by an environment variable of AZURE_DEPLOYMENT_NAME, and the promptimize tests will work for them like they do for OpenAI deployments.

Benefits to Maintainers

Issues raised by Azure users will have a clear path to resolution after this merge. In addition, this unlocks individual and corporate adoption for Azure users, a large cohort of the LLM consumption community.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant