From 63d9dae18b0bbc1f25bb5816a695c2a605293e21 Mon Sep 17 00:00:00 2001 From: Sakura-RanChen <1908198662@qq.com> Date: Thu, 5 Feb 2026 15:42:23 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A2=9E=E5=8A=A0asr=E5=88=9D=E5=A7=8B?= =?UTF-8?q?=E5=8C=96ID=E5=88=A4=E6=96=AD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- main/xiaozhi-server/core/utils/util.py | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/main/xiaozhi-server/core/utils/util.py b/main/xiaozhi-server/core/utils/util.py index 256c2bae..9b056c66 100644 --- a/main/xiaozhi-server/core/utils/util.py +++ b/main/xiaozhi-server/core/utils/util.py @@ -454,6 +454,12 @@ def check_asr_update(before_config, new_config): update_asr = False current_asr_module = before_config["selected_module"]["ASR"] new_asr_module = new_config["selected_module"]["ASR"] + + # 如果模块名称不同,就需要更新 + if current_asr_module != new_asr_module: + return True + + # 如果模块名称相同,再比较类型 current_asr_type = ( current_asr_module if "type" not in before_config["ASR"][current_asr_module]