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] gemini-1.5-pro-latest 模型无法使用 #2847

Closed
3 of 17 tasks
jrr997 opened this issue Jun 11, 2024 · 14 comments
Closed
3 of 17 tasks

[Bug] gemini-1.5-pro-latest 模型无法使用 #2847

jrr997 opened this issue Jun 11, 2024 · 14 comments
Labels
🐛 Bug Something isn't working | 缺陷

Comments

@jrr997
Copy link
Contributor

jrr997 commented Jun 11, 2024

📦 部署环境

  • Official
  • Official Preview
  • Vercel / Zeabur / Sealos
  • Docker
  • Other

📌 软件版本

我用的是PWA

💻 系统环境

  • Windows
  • macOS
  • Ubuntu
  • Other Linux
  • iOS
  • Android
  • Other

🌐 浏览器

  • Chrome
  • Edge
  • Safari
  • Firefox
  • Other

🐛 问题描述

gemini-1.5-pro-latest model 接口错误[400 Bad Request]

📷 复现步骤

  1. Language Model 中 Connectivity Check 通过。
image
  1. 在 Just Chat 中输入 'hello' 后接口报错,错误信息如下:
{
  "error": {
    "message": "[GoogleGenerativeAI Error]: Error fetching from https://generativelanguage.googleapis.com/v1beta/models/gemini-1.5-pro-latest:streamGenerateContent?alt=sse: [400 Bad Request] Invalid JSON payload received. Unknown name \"maxItems\" at 'tools[0].function_declarations[0].parameters.properties[0].value': Cannot find field.\nInvalid JSON payload received. Unknown name \"minItems\" at 'tools[0].function_declarations[0].parameters.properties[0].value': Cannot find field.\nInvalid JSON payload received. Unknown name \"default\" at 'tools[0].function_declarations[0].parameters.properties[1].value': Cannot find field.\nInvalid JSON payload received. Unknown name \"default\" at 'tools[0].function_declarations[0].parameters.properties[3].value': Cannot find field.\nInvalid JSON payload received. Unknown name \"default\" at 'tools[0].function_declarations[0].parameters.properties[4].value': Cannot find field. [{\"@type\":\"type.googleapis.com/google.rpc.BadRequest\",\"fieldViolations\":[{\"field\":\"tools[0].function_declarations[0].parameters.properties[0].value\",\"description\":\"Invalid JSON payload received. Unknown name \\\"maxItems\\\" at 'tools[0].function_declarations[0].parameters.properties[0].value': Cannot find field.\"},{\"field\":\"tools[0].function_declarations[0].parameters.properties[0].value\",\"description\":\"Invalid JSON payload received. Unknown name \\\"minItems\\\" at 'tools[0].function_declarations[0].parameters.properties[0].value': Cannot find field.\"},{\"field\":\"tools[0].function_declarations[0].parameters.properties[1].value\",\"description\":\"Invalid JSON payload received. Unknown name \\\"default\\\" at 'tools[0].function_declarations[0].parameters.properties[1].value': Cannot find field.\"},{\"field\":\"tools[0].function_declarations[0].parameters.properties[3].value\",\"description\":\"Invalid JSON payload received. Unknown name \\\"default\\\" at 'tools[0].function_declarations[0].parameters.properties[3].value': Cannot find field.\"},{\"field\":\"tools[0].function_declarations[0].parameters.properties[4].value\",\"description\":\"Invalid JSON payload received. Unknown name \\\"default\\\" at 'tools[0].function_declarations[0].parameters.properties[4].value': Cannot find field.\"}]}]"
  },
  "provider": "google"
}

🚦 期望结果

接口不要报错

📝 补充信息

No response

@jrr997 jrr997 added the 🐛 Bug Something isn't working | 缺陷 label Jun 11, 2024
@lobehubbot
Copy link
Member

👀 @jrr997

Thank you for raising an issue. We will investigate into the matter and get back to you as soon as possible.
Please make sure you have given us as much context as possible.
非常感谢您提交 issue。我们会尽快调查此事,并尽快回复您。 请确保您已经提供了尽可能多的背景信息。

@xingpingcn
Copy link

你的key估计被谷歌限制了,你所在地区用不了,或者请求过多了

@lobehubbot
Copy link
Member

Bot detected the issue body's language is not English, translate it automatically. 👯👭🏻🧑‍🤝‍🧑👫🧑🏿‍🤝‍🧑🏻👩🏾‍🤝‍👨🏿👬🏿


Your key is probably restricted by Google and cannot be used in your area, or there are too many requests.

@xingpingcn
Copy link

你用vercel部署,然后在环境变量里填上你的key,这样子就能用vercel的服务器帮你请求(选一个没有被限制的区域部署,例如美国)

@lobehubbot
Copy link
Member

Bot detected the issue body's language is not English, translate it automatically. 👯👭🏻🧑‍🤝‍🧑👫🧑🏿‍🤝‍🧑🏻👩🏾‍🤝‍👨🏿👬🏿


You use vercel to deploy, and then fill in your key in the environment variable, so that you can use vercel's server to help you request (choose an unrestricted region for deployment, such as the United States)

@jrr997
Copy link
Contributor Author

jrr997 commented Jun 11, 2024

你的key估计被谷歌限制了,你所在地区用不了,或者请求过多了

看接口返回应该不是这个问题。我刚刚在 chatbox 上测试了我的 key,是可以正常使用的。

@lobehubbot
Copy link
Member

Bot detected the issue body's language is not English, translate it automatically. 👯👭🏻🧑‍🤝‍🧑👫🧑🏿‍🤝‍🧑🏻👩🏾‍🤝‍👨🏿👬🏿


Your key is probably restricted by Google and cannot be used in your area, or there are too many requests.

Judging from the interface return, this should not be the problem. I just tested my key on chatbox and it works fine.

@xingpingcn
Copy link

你的key估计被谷歌限制了,你所在地区用不了,或者请求过多了

看接口返回应该不是这个问题。我刚刚在 chatbox 上测试了我的 key,是可以正常使用的。

如果你用的官网preview,然后你的代理软件并没有代理preview的话,那请求Gemini就是直连的。

刚刚测试我的Gemini在最新版没有问题,而且也不太应该出问题,lobe用的官方sdk

@lobehubbot
Copy link
Member

Bot detected the issue body's language is not English, translate it automatically. 👯👭🏻🧑‍🤝‍🧑👫🧑🏿‍🤝‍🧑🏻👩🏾‍🤝‍👨🏿👬🏿


Your key is probably restricted by Google and cannot be used in your area, or there are too many requests.

Judging from the interface return, this should not be the problem. I just tested my key on chatbox and it works fine.

If you use the official website for preview, and your proxy software does not proxy preview, then requesting Gemini will be directly connected.

I just tested my Gemini and there is no problem in the latest version, and it is unlikely to have problems. The official sdk used by lobe

@sxjeru
Copy link
Contributor

sxjeru commented Jun 11, 2024

请检查插件是否全部关闭。

@lobehubbot
Copy link
Member

Bot detected the issue body's language is not English, translate it automatically. 👯👭🏻🧑‍🤝‍🧑👫🧑🏿‍🤝‍🧑🏻👩🏾‍🤝‍👨🏿👬🏿


Please check if all plug-ins are closed.

@jrr997
Copy link
Contributor Author

jrr997 commented Jun 12, 2024

请检查插件是否全部关闭。

谢谢,是插件的问题。我把 Dalle 3 插件关了就好了。感觉插件应该要有检查模型是否合适的机制。

@lobehubbot
Copy link
Member

Bot detected the issue body's language is not English, translate it automatically. 👯👭🏻🧑‍🤝‍🧑👫🧑🏿‍🤝‍🧑🏻👩🏾‍🤝‍👨🏿👬🏿


Please check if all plug-ins are closed.

Thank you, it's a plug-in problem. I just turned off the Dalle 3 plugin. I feel that the plug-in should have a mechanism to check whether the model is suitable.

@arvinxx arvinxx closed this as completed Jul 7, 2024
@lobehubbot
Copy link
Member

@jrr997

This issue is closed, If you have any questions, you can comment and reply.
此问题已经关闭。如果您有任何问题,可以留言并回复。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🐛 Bug Something isn't working | 缺陷
Projects
Archived in project
Development

No branches or pull requests

5 participants