diff --git a/astrbot/core/pipeline/result_decorate/stage.py b/astrbot/core/pipeline/result_decorate/stage.py index 3d4b2629b..31e284765 100644 --- a/astrbot/core/pipeline/result_decorate/stage.py +++ b/astrbot/core/pipeline/result_decorate/stage.py @@ -18,7 +18,6 @@ class ResultDecorateStage: self.reply_prefix = ctx.astrbot_config['platform_settings']['reply_prefix'] self.reply_with_mention = ctx.astrbot_config['platform_settings']['reply_with_mention'] self.reply_with_quote = ctx.astrbot_config['platform_settings']['reply_with_quote'] - self.use_tts = ctx.astrbot_config['provider_tts_settings']['enable'] self.t2i_word_threshold = ctx.astrbot_config['t2i_word_threshold'] try: self.t2i_word_threshold = int(self.t2i_word_threshold) @@ -68,7 +67,7 @@ class ResultDecorateStage: result.chain = new_chain # TTS - if self.use_tts and result.is_llm_result(): + if self.ctx.astrbot_config['provider_tts_settings']['enable'] and result.is_llm_result(): tts_provider = self.ctx.plugin_manager.context.provider_manager.curr_tts_provider_inst new_chain = [] for comp in result.chain: diff --git a/astrbot/core/star/context.py b/astrbot/core/star/context.py index 068cd1f75..18b5200fe 100644 --- a/astrbot/core/star/context.py +++ b/astrbot/core/star/context.py @@ -1,5 +1,5 @@ from asyncio import Queue -from typing import List, TypedDict, Union +from typing import List, Union from astrbot.core import sp from astrbot.core.provider.provider import Provider, TTSProvider, STTProvider