When a user replies to an agent's message in Telegram groups, it is now treated as a direct mention (SOWA FULL response). Implementation: - Detect reply_to_message.from.is_bot in Gateway webhook handler - Verify bot_id matches this agent's token (multi-agent safe) - Pass is_reply_to_agent=True to detect_explicit_request() and analyze_message() (SOWA v2.2) - Add is_reply_to_agent to Router metadata for analytics SOWA already had Priority 3 logic for reply_to_agent → FULL, it was just never wired up (had TODO placeholders with False). Edge cases handled: - Only triggers when reply is to THIS agent's bot (not other bots) - Reply to forwarded messages: won't trigger (from.is_bot would be the original sender, not the bot) - Works alongside existing DM, mention, and training group rules Co-authored-by: Cursor <cursoragent@cursor.com>
162 KiB
162 KiB