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] API Key is required when linking independent deployed large language models. #2404

Closed
xulai1001 opened this issue Feb 26, 2025 · 3 comments
Assignees

Comments

@xulai1001
Copy link

xulai1001 commented Feb 26, 2025

Contact Information

wx: viktorromansky

MaxKB Version

社区版 1.10.0-lts build 50f2c96

Problem Description

模型设置里添加本地部署的OpenAI协议模型接口时,不能把API Key置空(服务配置时没有指定API key)
建议增加允许留空的配置

It is not allowed to leave the "API Key" empty for LLMs in the "Model Settings". In some local LLM setups, the API key can be empty (unspecified). MaxKB cannot connect to such LLMs.

Steps to Reproduce

系统设置 - 模型设置 - 添加模型 - DeepSeek / OpenAI / vLLM等设置项中,API Key一项均不允许为空。

The expected correct result

允许API Key留空

Related log output

Additional Information

No response

@shaohuzhang1 shaohuzhang1 changed the title [Bug] 链接独立部署的大语言模型时不能不提供API Key [Bug] API Key is required when linking independent deployed large language models. Feb 26, 2025
@Shenguobin0102
Copy link

你好,对接本地模型时API Key 确实是不需要的,但是在对接在线模型服务是这个是必填的,如果不设置必填校验,会造成这部分用户的体验不好,所以这里保留了必填校验。对接本地模型时,可以填入任意字符避开校验即可。

@shaohuzhang1
Copy link
Contributor

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


Hello, API Key is indeed not required when connecting to local models, but this is required when connecting to online model services. If the required verification is not set, it will cause the experience of this part of users to be bad, so it is retained here Required verification. When connecting to the local model, you can fill in any character to avoid verification.

@xulai1001
Copy link
Author

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

Hello, API Key is indeed not required when connecting to local models, but this is required when connecting to online model services. If the required verification is not set, it will cause the experience of this part of users to be bad, so it is retained here Required verification. When connecting to the local model, you can fill in any character to avoid verification.

我重新测试了一下,本地模型没有指定API Key时确实可以通过任意key连接,之前无法连接的情况是因为我这边的网络因素导致的。感谢您的及时回复!

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

4 participants