Skip to content

Commit 124c788

Browse files
authored
Merge pull request #171 from Ikaros-521/owner
去除edge-tts部分,对合成内容空格转逗号,英语方面兼容性会好一些
2 parents 576f315 + d854b29 commit 124c788

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

utils/audio.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -398,7 +398,7 @@ async def voice_change_and_put_to_queue(voice_tmp_path):
398398
try:
399399
voice_tmp_path = './out/' + self.common.get_bj_time(4) + '.mp3'
400400
# 过滤" '字符
401-
message["content"] = message["content"].replace('"', '').replace("'", '').replace(" ", ',')
401+
message["content"] = message["content"].replace('"', '').replace("'", '')
402402
# 使用 Edge TTS 生成回复消息的语音文件
403403
communicate = edge_tts.Communicate(text=message["content"], voice=message["data"]["voice"], rate=message["data"]["rate"], volume=message["data"]["volume"])
404404
await communicate.save(voice_tmp_path)

0 commit comments

Comments
 (0)