From 4acde4b7fdef88cc02ca12cf38c9020b05ed96ac Mon Sep 17 00:00:00 2001 From: Igor Monadical Date: Tue, 3 Feb 2026 16:05:16 -0500 Subject: [PATCH] fix: increase TIMEOUT_MEDIUM from 2m to 5m for LLM tasks (#843) Topic detection was timing out on longer transcripts when LLM responses are slow. This affects detect_chunk_topic and other LLM-calling tasks that use TIMEOUT_MEDIUM. Co-authored-by: Igor Loskutov --- server/reflector/hatchet/constants.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/server/reflector/hatchet/constants.py b/server/reflector/hatchet/constants.py index 209d1bd1..b3810ad6 100644 --- a/server/reflector/hatchet/constants.py +++ b/server/reflector/hatchet/constants.py @@ -35,7 +35,9 @@ LLM_RATE_LIMIT_PER_SECOND = 10 # Task execution timeouts (seconds) TIMEOUT_SHORT = 60 # Quick operations: API calls, DB updates -TIMEOUT_MEDIUM = 120 # Single LLM calls, waveform generation +TIMEOUT_MEDIUM = ( + 300 # Single LLM calls, waveform generation (5m for slow LLM responses) +) TIMEOUT_LONG = 180 # Action items (larger context LLM) TIMEOUT_AUDIO = 720 # Audio processing: padding, mixdown TIMEOUT_HEAVY = 600 # Transcription, fan-out LLM tasks