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

Google Gemini配置正确但无法使用 #5255

Closed
shog86 opened this issue Jan 1, 2025 · 12 comments
Closed

Google Gemini配置正确但无法使用 #5255

shog86 opened this issue Jan 1, 2025 · 12 comments
Labels
🐛 Bug Something isn't working | 缺陷

Comments

@shog86
Copy link

shog86 commented Jan 1, 2025

📦 Environment

Vercel

📌 Version

1.42.3

💻 Operating System

macOS, iOS

🌐 Browser

Chrome, Safari

🐛 Bug Description

好长时间了,其他工具这个key都可以用的,但在LobeChat配置了Gemini以及OpenRouter之后,会返回以下错误

Gemini:
{
"error": {
"message": "[GoogleGenerativeAI Error]: Error fetching from https://generativelanguage.googleapis.com/v1beta/models/gemini-exp-1206:streamGenerateContent?alt=sse: [400 ] * GenerateContentRequest.tools[0].function_declarations[0].parameters.properties[_requestBody].properties[data].items.items.type: must be specified when not using one_of\n"
},
"provider": "google"
}

OpenRouter:
{
"message": "Provider returned error",
"provider": "openrouter",
"errorType": "ProviderBizError"
}

📷 Recurrence Steps

No response

🚦 Expected Behavior

No response

📝 Additional Information

No response

@shog86 shog86 added the 🐛 Bug Something isn't working | 缺陷 label Jan 1, 2025
@github-project-automation github-project-automation bot moved this to Roadmap - Chat 1.x in Lobe Chat Routine Jan 1, 2025
@lobehubbot
Copy link
Member

👀 @shog86

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。我们会尽快调查此事,并尽快回复您。 请确保您已经提供了尽可能多的背景信息。

Copy link

dosubot bot commented Jan 1, 2025

Hey @shog86! I'm here to help you with any bugs, questions, or contributions you have. Let's work together to solve this issue.

A similar issue was discussed in a closed issue titled "[Bug] Gemini-1.5-Pro not found," which was resolved by a pull request that added support for displaying the model list [1]. The error you're encountering with the Google Gemini configuration might be related to the JSON schema requirements, as the Gemini 1.5 Pro model does not support certain fields like maxItems, minItems, and default in the JSON payload, leading to a "400 Bad Request" error [2].

For the OpenRouter error, it seems to be a generic provider error, but specific details on handling such errors in LobeChat are not available in the current context. You might want to check if there are any updates or patches related to these issues in the repository.

To continue talking to Dosu, mention @dosu.


Help Dosu learn! Give it feedback: Great Response | Irrelevant Answer | Incorrect Sources | Too Verbose | Hallucination | Other

@SpeedupMaster
Copy link
Contributor

Function call的问题,关掉插件就好了

@shog86
Copy link
Author

shog86 commented Jan 1, 2025

Function call的问题,关掉插件就好了

但我都用的默认模型,不是自定义的,支持function call,应该是能用插件的呀,关了不就用不了了?

@lobehubbot
Copy link
Member

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


Function call problem, just turn off the plug-in and it will be fine

But the default model I use is not customized. It supports function call and should be able to use plug-ins. If it is turned off, won’t it be unusable?

@shog86
Copy link
Author

shog86 commented Jan 1, 2025

关了表格助手和时间助手,Google的Gemini调用可以了

关了全部插件,OpenRouter的Gemini还是不行

@lobehubbot
Copy link
Member

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


After turning off the form assistant and time assistant, Google's Gemini can be called

After turning off all plug-ins, OpenRouter’s Gemini still doesn’t work.

@SpeedupMaster
Copy link
Contributor

关了表格助手和时间助手,Google的Gemini调用可以了

关了全部插件,OpenRouter的Gemini还是不行

#4555 openrouter的不清楚,Gemini只用过谷歌的

@lobehubbot
Copy link
Member

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


After turning off the form assistant and time assistant, Google's Gemini call can be used

After turning off all plug-ins, OpenRouter’s Gemini still doesn’t work.

#4555 I don’t know about openrouter. Gemini has only used Google’s.

@arvinxx
Copy link
Contributor

arvinxx commented Jan 2, 2025

重复 #4555

@arvinxx arvinxx closed this as completed Jan 2, 2025
@github-project-automation github-project-automation bot moved this from Roadmap - Chat 1.x to Done in Lobe Chat Routine Jan 2, 2025
@lobehubbot
Copy link
Member

@shog86

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

@lobehubbot
Copy link
Member

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


Duplicate #4555

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
Status: Done
Development

No branches or pull requests

4 participants