diff --git a/InsightEngine/llms/base.py b/InsightEngine/llms/base.py index 48a5157..090c10c 100644 --- a/InsightEngine/llms/base.py +++ b/InsightEngine/llms/base.py @@ -83,7 +83,6 @@ class LLMClient: return self.validate_response(response.choices[0].message.content) return "" - @with_retry(LLM_RETRY_CONFIG) def stream_invoke(self, system_prompt: str, user_prompt: str, **kwargs) -> Generator[str, None, None]: """ 流式调用LLM,逐步返回响应内容 @@ -131,6 +130,7 @@ class LLMClient: logger.error(f"流式请求失败: {str(e)}") raise e + @with_retry(LLM_RETRY_CONFIG) def stream_invoke_to_string(self, system_prompt: str, user_prompt: str, **kwargs) -> str: """ 流式调用LLM并安全地拼接为完整字符串(避免UTF-8多字节字符截断) diff --git a/MediaEngine/llms/base.py b/MediaEngine/llms/base.py index 4cbb3ca..888b0a5 100644 --- a/MediaEngine/llms/base.py +++ b/MediaEngine/llms/base.py @@ -86,7 +86,6 @@ class LLMClient: return self.validate_response(response.choices[0].message.content) return "" - @with_retry(LLM_RETRY_CONFIG) def stream_invoke(self, system_prompt: str, user_prompt: str, **kwargs) -> Generator[str, None, None]: """ 流式调用LLM,逐步返回响应内容 @@ -134,6 +133,7 @@ class LLMClient: logger.error(f"流式请求失败: {str(e)}") raise e + @with_retry(LLM_RETRY_CONFIG) def stream_invoke_to_string(self, system_prompt: str, user_prompt: str, **kwargs) -> str: """ 流式调用LLM并安全地拼接为完整字符串(避免UTF-8多字节字符截断) diff --git a/QueryEngine/llms/base.py b/QueryEngine/llms/base.py index 399ab65..8acc6cf 100644 --- a/QueryEngine/llms/base.py +++ b/QueryEngine/llms/base.py @@ -83,7 +83,6 @@ class LLMClient: return self.validate_response(response.choices[0].message.content) return "" - @with_retry(LLM_RETRY_CONFIG) def stream_invoke(self, system_prompt: str, user_prompt: str, **kwargs) -> Generator[str, None, None]: """ 流式调用LLM,逐步返回响应内容 @@ -131,6 +130,7 @@ class LLMClient: logger.error(f"流式请求失败: {str(e)}") raise e + @with_retry(LLM_RETRY_CONFIG) def stream_invoke_to_string(self, system_prompt: str, user_prompt: str, **kwargs) -> str: """ 流式调用LLM并安全地拼接为完整字符串(避免UTF-8多字节字符截断) diff --git a/ReportEngine/llms/base.py b/ReportEngine/llms/base.py index 64e34ac..29723c5 100644 --- a/ReportEngine/llms/base.py +++ b/ReportEngine/llms/base.py @@ -76,7 +76,6 @@ class LLMClient: return self.validate_response(response.choices[0].message.content) return "" - @with_retry(LLM_RETRY_CONFIG) def stream_invoke(self, system_prompt: str, user_prompt: str, **kwargs) -> Generator[str, None, None]: """ 流式调用LLM,逐步返回响应内容 @@ -118,6 +117,7 @@ class LLMClient: logger.error(f"流式请求失败: {str(e)}") raise e + @with_retry(LLM_RETRY_CONFIG) def stream_invoke_to_string(self, system_prompt: str, user_prompt: str, **kwargs) -> str: """ 流式调用LLM并安全地拼接为完整字符串(避免UTF-8多字节字符截断)