语音识别上游参数改为随请求带入,init.sh 不再绑定平台
- mcp_asr 不再从容器 env 读 key/base_url/model,改为逐请求 header (Authorization / X-ASR-Base-Url / X-ASR-Model),容器不存任何平台密钥 - core 的 /api/asr 从 config.yml 的 mcp_servers[asr].headers 取值转发, /status 增加 reason(未接线时前端 console 直接打印原因) - init.sh 只自动启用模型平台与 web_search;image_task / video_task / asr 改为带默认 url 与 header 名的注释模板,删掉 ASR_API_* 输入与 BIGMODEL_KEY 复用 - docker-compose 去掉 mcp_asr 的三个上游 env - 同步 README / AGENTS / app/config.example.yml / mcp 文档
This commit is contained in:
@@ -544,10 +544,11 @@
|
||||
console.info('[voice] 语音入口未启用:没有 window.AgentNative,且当前不是安全上下文(需 HTTPS,或由套壳 App 注入原生桥)');
|
||||
return;
|
||||
}
|
||||
// 服务端没接线(core 的 ASR_URL 为空)就不给入口;探测失败则照常启用
|
||||
// 服务端没接线(core 的 ASR_URL 为空,或 config.yml 里没有可用的 asr 段)就不给入口;
|
||||
// 探测失败则照常启用(不因一次探测失败就永久藏掉入口)。
|
||||
req('GET', '/api/asr/status').then(function (s) {
|
||||
if (s && s.enabled === false) {
|
||||
console.info('[voice] 语音入口未启用:服务端未配置语音识别(agent-core 的 ASR_URL 为空)');
|
||||
console.info('[voice] 语音入口未启用:' + ((s && s.reason) || '服务端未配置语音识别'));
|
||||
return;
|
||||
}
|
||||
available = true;
|
||||
|
||||
Reference in New Issue
Block a user