File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 6262 "provider_tts_settings" : {
6363 "enable" : False ,
6464 "provider_id" : "" ,
65+ "dual_output" : False ,
6566 },
6667 "provider_ltm_settings" : {
6768 "group_icl_enable" : False ,
11081109 "type" : "string" ,
11091110 "hint" : "文本转语音提供商 ID。如果不填写将使用载入的第一个提供商。" ,
11101111 },
1112+ "dual_output" : {
1113+ "description" : "启用语音和文字双输出" ,
1114+ "type" : "bool" ,
1115+ "hint" : "启用后,Bot 将同时输出语音和文字消息。" ,
1116+ "obvious_hint" : True ,
1117+ },
11111118 },
11121119 },
11131120 "provider_ltm_settings" : {
Original file line number Diff line number Diff line change @@ -184,6 +184,8 @@ async def process(
184184 new_chain .append (
185185 Record (file = audio_path , url = audio_path )
186186 )
187+ if (self .ctx .astrbot_config ["provider_tts_settings" ]["dual_output" ]):
188+ new_chain .append (comp )
187189 else :
188190 logger .error (
189191 f"由于 TTS 音频文件没找到,消息段转语音失败: { comp .text } "
You can’t perform that action at this time.
0 commit comments