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

[Bug] 2.10.1 版中使用 OpenAI 协议访问 One API 的 gemini-pro 模型时被强制成了 Google Vertex AI API 的协议 #3693

Closed
1 of 3 tasks
ShinChven opened this issue Dec 29, 2023 · 3 comments

Comments

@ShinChven
Copy link

Describe the bug

One API 代理的 google-gemini 模型的协议与 OpenAI 的一致(好像很多其他的开源服务也用的这个协议)。而我更新了2.10.1版以后发现无论是否选择 Google 为模型服务商,只要模型名称为gemini-pro都会被强制使用 google从而导致无法从 One API 中调用 Google Gemini Pro 模型。

One API 是一个好用的模型接口管理合集,用户可以使用一套自定义域名和密钥通过 OpenAI 的协议访问不同厂商的模型接口,非常方便好用。借用 One API,在之前版本的 ChatGPT Next 中我可以非常方便地通过切换模型来访问不同厂商的模型接口,而不需要更改密钥和地址,它也解决了 Google 等厂商的模型无法直连的问题。

希望能进行的修改

在选择 OpenAI模型服务商时,严格以 OpenAI 的协议发送请求,而不是根据模型名称来调用协议。

To Reproduce
Steps to reproduce the behavior:

  1. 选择 OpenAI模型服务商
  2. 填写 OneAPI 的代理地址和密钥
  3. 填写自定义模型名称gemini-pro
  4. 发送消息

Expected behavior
以 OpenAI 的协议发送请求

Screenshots
If applicable, add screenshots to help explain your problem.

Deployment

  • Docker
  • Vercel
  • Server

Desktop (please complete the following information):

  • OS: [e.g. iOS]
  • Browser [e.g. chrome, safari]
  • Version [e.g. 22]

Smartphone (please complete the following information):

  • Device: [e.g. iPhone6]
  • OS: [e.g. iOS8.1]
  • Browser [e.g. stock browser, safari]
  • Version [e.g. 22]

Additional Logs
Add any logs about the problem here.

@Issues-translate-bot
Copy link

Bot detected the issue body's language is not English, translate it automatically.


Title: [Bug] In version 2.10.1, when using the OpenAI protocol to access the gemini-pro model of One API, it was forced to use the Google Vertex API protocol. When calling the usage version

@ShinChven ShinChven changed the title [Bug] 2.10.1 版中使用 OpenAI 协议访问 One API 的 gemini-pro 模型时被强制成了 Google Vertex API 的协议,调用使用版 [Bug] 2.10.1 版中使用 OpenAI 协议访问 One API 的 gemini-pro 模型时被强制成了 Google Vertex AI API 的协议 Dec 29, 2023
@ShinChven
Copy link
Author

我目前的方案是在 One API 中建了一个 google-gemini-pro 的模型名称,然后重定向到 gemini-pro

@Issues-translate-bot
Copy link

Bot detected the issue body's language is not English, translate it automatically.


My current solution is to create a model name of google-gemini-pro in One API, and then redirect to gemini-pro

@fredliang44 fredliang44 closed this as not planned Won't fix, can't repro, duplicate, stale Dec 29, 2023
This issue was closed.
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

No branches or pull requests

3 participants