summaryrefslogtreecommitdiff
path: root/Omni/Agent/Telegram/IncomingQueue.hs
AgeCommit message (Collapse)Author
6 daysfeat: add Telegram topic (message_thread_id) supportBen Sima
- Parse message_thread_id from incoming messages - Include thread_id in sendMessage API calls - Pass thread_id through message queue system - Replies now go to the correct topic in supergroups
6 daysAdd incoming message queue for Telegram botBen Sima
Batches incoming messages by chat_id with a 3-second sliding window before processing. This prevents confusion when messages arrive simultaneously from different chats. - New IncomingQueue module with STM-based in-memory queue - Messages enqueued immediately, offset acked on enqueue - 200ms tick loop flushes batches past deadline - Batch formatting: numbered messages, sender attribution for groups, media stubs, reply context - Media from first message in batch still gets full processing