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

[Feature Request] Support Azure OpenAI models #231

Open
2 tasks done
lightaime opened this issue Jul 24, 2023 · 3 comments · May be fixed by #499
Open
2 tasks done

[Feature Request] Support Azure OpenAI models #231

lightaime opened this issue Jul 24, 2023 · 3 comments · May be fixed by #499
Assignees
Labels
enhancement New feature or request

Comments

@lightaime
Copy link
Member

lightaime commented Jul 24, 2023

Required prerequisites

Motivation

People are interested in setting up Azure OpenAI models. We can add Azure OpenAI models to https://github.com/camel-ai/camel/tree/master/camel/models.

Solution

No response

Alternatives

No response

Additional context

No response

@lightaime lightaime added the enhancement New feature or request label Jul 24, 2023
@lightaime lightaime assigned lightaime and unassigned lightaime Jul 24, 2023
@lightaime
Copy link
Member Author

@hammoudhasan can you take this issue? It is related to what we will do.

@qiviut
Copy link

qiviut commented Oct 27, 2023

@lightaime, @hammoudhasan: I think the code needs to be changed in 3 places, but I do not understand the code well enough to implement it in a nice way and create a PR for it. I got it to work by hard-coding values in each location.

In apps/agents/agents.py and camel/models/openai_model.py, openai.api_key = ... needs to be complemented with openai.api_base = "https://<example-endpoint>.openai.azure.com". In camel/configs.py, the ChatGPTConfig class needs to be extended with the variable deployment_id: str = "<name of the deployment>".

Adding openai.api_type = ... and openai.api_version = ... was not necessary.

@L4zyy
Copy link

L4zyy commented Dec 6, 2023

Hi, @lightaime , I have integrated Azure OpenAI API into Camel and updated the corresponding files. Would it be okay for me to make a pull request?

@L4zyy L4zyy linked a pull request Apr 4, 2024 that will close this issue
12 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
4 participants