[4:37 PM, 1/21/2026] Juan Pablo: Please check the logs of this situation. Why did you trigger? DO NOT MAKE UP, TELL ME THE TRUTH 00:34:44 [whatsapp] Inbound message 13128749154-1570324886@g.us -> +13128749154 (group, 5223 chars) 00:34:44 [whatsapp] Inbound body: [Chat messages since your last reply - for context] [WhatsApp 13128749154-1570324886@g.us 2026-01-22T00:25Z] Andrea Estrada (+12069285687): Holaaaaaaa [message_id: 3A0AE5D576EEFCF01B0D] [WhatsApp 13128749154-1570324886@g.us 2026-01-22T00:25Z] Andrea Estrada (+12069285687): como va todooo? [message_id: 3A6FFE0279FECBE7DEB9] [WhatsApp 13128749154-1570324886@g.us 2026-01-22T00:25Z] Andrea Estrada (+1… (truncated 4823 chars) 00:34:44 [agent/embedded] embedded run start: runId=90ce9314-9a76-416a-94c6-b54446eaca9f sessionId=0f52e2cb-ab7b… [4:38 PM, 1/21/2026] Juan Pablo: [ClawdBot] Looking at the logs, here's what I can see: *What triggered me:* - At 00:34:44, WhatsApp sent a large batch of messages (5223 chars) labeled as [Chat messages since your last reply - for context] - This immediately triggered an *embedded agent run* (embedded run start) - The agent then generated a response and sent it at 00:34:59 *The truth:* I don't have full visibility into WHY the embedded run started - that happens at the gateway/configuration level. The logs show: - No explicit mention of me in the messages shown - Other group messages were correctly marked as Group message stored for context (no mention detected) - But this large context dump triggered an active run anyway *What I don't know:* - The exact WhatsApp gateway configuration (mention … [4:45 PM, 1/21/2026] Juan Pablo: Ok great. I want to report this to the dev team. Please give me some more technical description of times, events, triggers, messages, etc. [4:46 PM, 1/21/2026] Juan Pablo: [ClawdBot] Here's a technical incident report you can share: --- ## Bug Report: Unwanted Embedded Agent Run from WhatsApp Context Dump ### Incident Summary Embedded agent auto-replied to a WhatsApp group chat without an explicit mention, triggered by a "context dump" message containing historical chat messages. ### Timeline | Time (UTC) | Event | Details | |------------|-------|---------| | 00:34:44.000 | WhatsApp Inbound Message | Source: 13128749154-1570324886@g.us → +13128749154. Size: *5223 chars* | | 00:34:44.000 | Message Body | [Chat messages since your last reply - for context] followed by batch of historical messages from Andrea Estrada (+12069285687) | | 00:34:44.000 | *Embedded Run Start* | runId=90ce9314-9a76-416a-94c6-b54446eaca9f, sessionId=0f52e2cb-ab7b-401f-bb76-66f518a85108 | | 00:34:44.000 | Embedded Run Config | provider=zai, model=glm-4.7, thinking=low, messageChannel=whatsapp | | 00:34:44.000 | Lifecycle Event | ws → event agent, stream=lifecycle, phase=start, aseq=1 | | 00:34:49.000 | Self-Chat Filter | Skipping read receipt (message 3BD3C9AD488F369F49F8) | | 00:34:50.000 | Other Group Context | Group message stored for context (no mention detected) in group 12068808141-1596659278@g.us | | 00:34:54.000 | Same Group Context | Group message stored for context (no mention detected) in target group 13128749154-1570324886@g.us: "me derritoooooo byeee" | | 00:34:59.000 | *Assistant Response Sent* | ws → event agent, stream=assistant, aseq=14, text: "🤖 ¡FELICIDADES FAMILIA! 🎉..." | ### Key Observations 1. *Context Dump Triggered Run:* The message [Chat messages since your last reply - for context] appears to be a WhatsApp gateway metadata message, not actual user input. This triggered an embedded run when it shouldn't have. 2. *Mention Detection Working Elsewhere:* Other group messages were correctly identified as no mention detected and only stored for context. But the large context dump bypassed this filter. 3. *No Explicit Mention:* Reviewing the visible message fragments from Andrea Estrada ("Holaaaaaaa", "como va todooo?"), there's no mention pattern (e.g., "@ClawdBot" or similar). 4. *Gateway Behavior:* The gateway immediately initiated an embedded run upon receiving the 5223-char context dump, without checking if it should process it. ### Expected Behavior - Messages labeled [Chat messages since your last reply - for context] should be treated as metadata and stored for context only, never trigger an embedded run. - Mention detection should be applied consistently, including to context dumps. ### Root Cause (Suspected) The WhatsApp inbound handler may be treating large message batches with the [Chat messages since your last reply - for context] prefix as regular user messages, bypassing the mention detection filter. --- Let me know if you need any additional details!