From 45a4a6b6dab65b206085e954c0696e8d17241dd8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=8D=A2=E5=B0=8F=E8=BE=89?= Date: Fri, 5 Sep 2025 15:23:21 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=E7=BB=99=E6=B7=BB=E5=8A=A0=20edge=5Ftt?= =?UTF-8?q?s=20=E6=96=B0=E5=A2=9E=20rate,=20volume,=20pitch=20=E5=8F=82?= =?UTF-8?q?=E6=95=B0=20(#2625)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * 修复python执行器文件上传qq提示参数错误问题,修改策略为本地url * 给edge_tts 添加3个默认参数,方便通过ui配置 --- astrbot/core/config/default.py | 3 +++ packages/python_interpreter/main.py | 8 ++++---- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/astrbot/core/config/default.py b/astrbot/core/config/default.py index e3f12b777..b1ee275e4 100644 --- a/astrbot/core/config/default.py +++ b/astrbot/core/config/default.py @@ -866,6 +866,9 @@ CONFIG_METADATA_2 = { "provider_type": "text_to_speech", "enable": False, "edge-tts-voice": "zh-CN-XiaoxiaoNeural", + "rate": "+0%", + "volume": "+0%", + "pitch": "+0Hz", "timeout": 20, }, "GSV TTS(本地加载)": { diff --git a/packages/python_interpreter/main.py b/packages/python_interpreter/main.py index eec98607f..b63885634 100644 --- a/packages/python_interpreter/main.py +++ b/packages/python_interpreter/main.py @@ -463,11 +463,11 @@ class Main(star.Star): yield event.image_result(image_path) elif match.group(1) == "FILE": file_path = os.path.join(workplace_path, match.group(2)) - logger.debug(f"Sending file: {file_path}") - file_s3_url = await self.file_upload(file_path) - logger.info(f"文件上传到 AstrBot 云节点: {file_s3_url}") + # logger.debug(f"Sending file: {file_path}") + # file_s3_url = await self.file_upload(file_path) + # logger.info(f"文件上传到 AstrBot 云节点: {file_s3_url}") file_name = os.path.basename(file_path) - chain = [File(name=file_name, file=file_s3_url)] + chain = [File(name=file_name, file=file_path)] yield event.set_result(MessageEventResult(chain=chain)) elif "Traceback (most recent call last)" in log or "[Error]: " in log: