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

[Request] 支持 Azure OpenAI #131

Closed
libli opened this issue Aug 30, 2023 · 5 comments · Fixed by #177
Closed

[Request] 支持 Azure OpenAI #131

libli opened this issue Aug 30, 2023 · 5 comments · Fixed by #177
Assignees
Labels
🌠 Feature Request New feature or request | 特性与建议 released

Comments

@libli
Copy link

libli commented Aug 30, 2023

🥰 需求描述 | Feature Description

希望支持azure openai。它也支持function call。而且申请及支付azure的账号更容易。

🧐 解决方案 | Proposed Solution

curl "ENDPOINT/openai/deployments/MODELNAME/chat/completions?api-version=2023-07-01-preview" \ -H "Content-Type: application/json" \ -H "api-key: YOUR_API_KEY" \ -d "{ \"messages\": [], \"max_tokens\": 800, \"temperature\": 0.7, \"frequency_penalty\": 0, \"presence_penalty\": 0, \"top_p\": 0.95, \"stop\": null }"

调用方式如上,需要提供一个ENDPOINT url、自定义的MODELNAME、api-key。

📝 补充信息 | Additional Information

No response

@libli libli added the 🌠 Feature Request New feature or request | 特性与建议 label Aug 30, 2023
@arvinxx
Copy link
Contributor

arvinxx commented Aug 31, 2023

试试配置 OPENAI_PROXY_URL 这个环境变量行不行?

@libli
Copy link
Author

libli commented Aug 31, 2023

azure的鉴权是在header中的api-key这个值。

@libli
Copy link
Author

libli commented Aug 31, 2023

可以支持两个header看看。同时设置bearer token和api-key。

@arvinxx
Copy link
Contributor

arvinxx commented Aug 31, 2023

ok,我加下

@github-project-automation github-project-automation bot moved this to Todo - Chat in Lobe Chat Routine Sep 4, 2023
@canisminor1990 canisminor1990 changed the title [Request] 支持azure openai [Request] 支持 Azure OpenAI Sep 5, 2023
@arvinxx arvinxx mentioned this issue Sep 6, 2023
9 tasks
@arvinxx arvinxx self-assigned this Sep 6, 2023
@arvinxx arvinxx moved this from Todo - Chat to In Progress in Lobe Chat Routine Sep 9, 2023
@github-project-automation github-project-automation bot moved this from In Progress to Done in Lobe Chat Routine Sep 10, 2023
@lobehubbot
Copy link
Member

🎉 This issue has been resolved in version 0.73.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

skylinemusiccds referenced this issue in skylinemusiccds/BrainWeaver-development May 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🌠 Feature Request New feature or request | 特性与建议 released
Projects
Archived in project
Development

Successfully merging a pull request may close this issue.

3 participants