mirror of
https://github.com/xinnan-tech/xiaozhi-esp32-server.git
synced 2026-07-26 09:03:54 +08:00
去除无用代码,修复插入语句id缺失
This commit is contained in:
@@ -1 +0,0 @@
|
|||||||
INSERT INTO `sys_params` (param_code, param_value, value_type, param_type, remark) VALUES ('system_error_response', '主人,小智现在有点忙,我们稍后再试吧。', 'string', 1, '系统错误时的回复');
|
|
||||||
@@ -0,0 +1 @@
|
|||||||
|
INSERT INTO `sys_params` (id, param_code, param_value, value_type, param_type, remark) VALUES (502, 'system_error_response', '主人,小智现在有点忙,我们稍后再试吧。', 'string', 1, '系统错误时的回复');
|
||||||
@@ -509,9 +509,9 @@ databaseChangeLog:
|
|||||||
encoding: utf8
|
encoding: utf8
|
||||||
path: classpath:db/changelog/202601261730.sql
|
path: classpath:db/changelog/202601261730.sql
|
||||||
- changeSet:
|
- changeSet:
|
||||||
id: 202601291552
|
id: 202602021555
|
||||||
author: shengzhou1216
|
author: shengzhou1216
|
||||||
changes:
|
changes:
|
||||||
- sqlFile:
|
- sqlFile:
|
||||||
encoding: utf8
|
encoding: utf8
|
||||||
path: classpath:db/changelog/202601291552.sql
|
path: classpath:db/changelog/202602021555.sql
|
||||||
|
|||||||
@@ -137,7 +137,6 @@ class ConnectionHandler:
|
|||||||
self.current_language_tag = None # 存储当前ASR识别的语言标签
|
self.current_language_tag = None # 存储当前ASR识别的语言标签
|
||||||
|
|
||||||
# llm相关变量
|
# llm相关变量
|
||||||
self.llm_finish_task = True
|
|
||||||
self.dialogue = Dialogue()
|
self.dialogue = Dialogue()
|
||||||
|
|
||||||
# tts相关变量
|
# tts相关变量
|
||||||
@@ -801,7 +800,6 @@ class ConnectionHandler:
|
|||||||
|
|
||||||
# 为最顶层时新建会话ID和发送FIRST请求
|
# 为最顶层时新建会话ID和发送FIRST请求
|
||||||
if depth == 0:
|
if depth == 0:
|
||||||
self.llm_finish_task = False
|
|
||||||
self.sentence_id = str(uuid.uuid4().hex)
|
self.sentence_id = str(uuid.uuid4().hex)
|
||||||
self.dialogue.put(Message(role="user", content=query))
|
self.dialogue.put(Message(role="user", content=query))
|
||||||
self.tts.tts_text_queue.put(
|
self.tts.tts_text_queue.put(
|
||||||
@@ -935,7 +933,6 @@ class ConnectionHandler:
|
|||||||
content_type=ContentType.ACTION,
|
content_type=ContentType.ACTION,
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
self.llm_finish_task = True
|
|
||||||
return
|
return
|
||||||
# 处理function call
|
# 处理function call
|
||||||
if tool_call_flag:
|
if tool_call_flag:
|
||||||
@@ -1017,7 +1014,6 @@ class ConnectionHandler:
|
|||||||
content_type=ContentType.ACTION,
|
content_type=ContentType.ACTION,
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
self.llm_finish_task = True
|
|
||||||
# 使用lambda延迟计算,只有在DEBUG级别时才执行get_llm_dialogue()
|
# 使用lambda延迟计算,只有在DEBUG级别时才执行get_llm_dialogue()
|
||||||
self.logger.bind(tag=TAG).debug(
|
self.logger.bind(tag=TAG).debug(
|
||||||
lambda: json.dumps(
|
lambda: json.dumps(
|
||||||
|
|||||||
@@ -76,7 +76,6 @@ class LLMProvider(LLMProviderBase):
|
|||||||
if value is not None:
|
if value is not None:
|
||||||
request_params[key] = value
|
request_params[key] = value
|
||||||
|
|
||||||
# raise ValueError("model_name is required")
|
|
||||||
responses = self.client.chat.completions.create(**request_params)
|
responses = self.client.chat.completions.create(**request_params)
|
||||||
|
|
||||||
is_active = True
|
is_active = True
|
||||||
|
|||||||
Reference in New Issue
Block a user