hermes-agent/gateway/platforms
Teknium 15b1a3aa69
fix: improve WhatsApp UX — chunking, formatting, streaming (#8723)
Three changes that address the poor WhatsApp experience reported by users:

1. Reclassify WhatsApp from TIER_LOW to TIER_MEDIUM in display_config.py
   — enables streaming and tool progress via the existing Baileys /edit
   bridge endpoint. Users now see progressive responses instead of
   minutes of silence followed by a wall of text.

2. Lower MAX_MESSAGE_LENGTH from 65536 to 4096 and add proper chunking
   — send() now calls format_message() and truncate_message() before
   sending, then loops through chunks with a small delay between them.
   The base class truncate_message() already handles code block boundary
   detection (closes/reopens fences at chunk boundaries). reply_to is
   only set on the first chunk.

3. Override format_message() with WhatsApp-specific markdown conversion
   — converts **bold** to *bold*, ~~strike~~ to ~strike~, headers to
   bold text, and [links](url) to text (url). Code blocks and inline
   code are protected from conversion via placeholder substitution.

Together these fix the two user complaints:
- 'sends the whole code all the time' → now chunked at 4K with proper
  formatting
- 'terminal gets interrupted and gets cooked' → streaming + tool progress
  give visual feedback so users don't accidentally interrupt with
  follow-up messages
2026-04-12 19:20:13 -07:00
..
__init__.py Enhance CLI with multi-platform messaging integration and configuration management 2026-02-02 19:01:51 -08:00
ADDING_A_PLATFORM.md docs: finish cron terminology cleanup 2026-03-14 19:20:58 -07:00
api_server.py fix(gateway): reject known-weak placeholder credentials at startup 2026-04-12 18:05:41 -07:00
base.py fix(telegram): use UTF-16 code units for message length splitting (#8725) 2026-04-12 19:06:20 -07:00
bluebubbles.py refactor: extract shared helpers to deduplicate repeated code patterns (#7917) 2026-04-11 13:59:52 -07:00
dingtalk.py refactor: extract shared helpers to deduplicate repeated code patterns (#7917) 2026-04-11 13:59:52 -07:00
discord.py fix(discord): decouple readiness from slash sync 2026-04-11 19:22:14 -07:00
email.py fix(gateway): validate Slack image downloads before caching 2026-04-10 03:53:09 -07:00
feishu.py feat(feishu): add scan-to-create onboarding for Feishu / Lark 2026-04-12 13:05:56 -07:00
helpers.py refactor: extract shared helpers to deduplicate repeated code patterns (#7917) 2026-04-11 13:59:52 -07:00
homeassistant.py fix(gateway): add request timeouts to HA, Email, Mattermost, SMS adapters (#3258) 2026-03-26 14:36:07 -07:00
matrix.py fix(matrix): trust m.mentions.user_ids as authoritative mention signal 2026-04-12 18:05:41 -07:00
mattermost.py refactor: extract shared helpers to deduplicate repeated code patterns (#7917) 2026-04-11 13:59:52 -07:00
signal.py refactor: extract shared helpers to deduplicate repeated code patterns (#7917) 2026-04-11 13:59:52 -07:00
slack.py refactor: extract shared helpers to deduplicate repeated code patterns (#7917) 2026-04-11 13:59:52 -07:00
sms.py remove unused import and fix misleading log 2026-04-11 14:05:38 -07:00
telegram.py fix(telegram): use UTF-16 code units for message length splitting (#8725) 2026-04-12 19:06:20 -07:00
telegram_network.py fix(gateway): replace assertions with proper error handling in Telegram and Feishu 2026-04-10 03:52:00 -07:00
webhook.py feat(gateway): add WeCom callback-mode adapter for self-built apps 2026-04-11 15:22:49 -07:00
wecom.py fix(weixin,wecom,matrix): respect system proxy via aiohttp trust_env 2026-04-12 18:03:16 -07:00
wecom_callback.py feat(gateway): add WeCom callback-mode adapter for self-built apps 2026-04-11 15:22:49 -07:00
wecom_crypto.py feat(gateway): add WeCom callback-mode adapter for self-built apps 2026-04-11 15:22:49 -07:00
weixin.py fix(weixin,wecom,matrix): respect system proxy via aiohttp trust_env 2026-04-12 18:03:16 -07:00
whatsapp.py fix: improve WhatsApp UX — chunking, formatting, streaming (#8723) 2026-04-12 19:20:13 -07:00