hotfix(timeout): increase llm call timeout to 1800s

This commit is contained in:
ghmark675
2025-11-03 22:25:44 +08:00
committed by BaiFu
parent 5d8a56605b
commit 62fac9ee2e
4 changed files with 8 additions and 8 deletions
+2 -2
View File
@@ -41,11 +41,11 @@ class LLMClient:
self.base_url = base_url
self.model_name = model_name
self.provider = model_name
timeout_fallback = os.getenv("LLM_REQUEST_TIMEOUT") or os.getenv("MEDIA_ENGINE_REQUEST_TIMEOUT") or "180"
timeout_fallback = os.getenv("LLM_REQUEST_TIMEOUT") or os.getenv("MEDIA_ENGINE_REQUEST_TIMEOUT") or "1800"
try:
self.timeout = float(timeout_fallback)
except ValueError:
self.timeout = 300.0
self.timeout = 1800.0
client_kwargs: Dict[str, Any] = {
"api_key": api_key,