Skip to content

fix: surface WhatsApp quote-reply text for agent context - #38382

Closed
kirikatiya wants to merge 1 commit into
NousResearch:mainfrom
kirikatiya:fix/whatsapp-quote-reply-context
Closed

fix: surface WhatsApp quote-reply text for agent context#38382
kirikatiya wants to merge 1 commit into
NousResearch:mainfrom
kirikatiya:fix/whatsapp-quote-reply-context

Conversation

@kirikatiya

Copy link
Copy Markdown

Bridge now extracts quotedText from contextInfo.quotedMessage and whatsapp.py maps it to MessageEvent reply_to fields, enabling the gateway's existing reply-context injection for WhatsApp quote-replies.

Bridge now extracts quotedText from contextInfo.quotedMessage and
whatsapp.py maps it to MessageEvent reply_to fields, enabling the
existing gateway reply-context injection for WhatsApp replies.
@alt-glitch alt-glitch added type/bug Something isn't working P3 Low — cosmetic, nice to have platform/whatsapp WhatsApp Business adapter comp/gateway Gateway runner, session dispatch, delivery labels Jun 3, 2026
IsuruGunarathne pushed a commit to IsuruGunarathne/hermes-agent that referenced this pull request Jun 6, 2026
Pull the standalone getQuotedText() pattern from @kirikatiya's upstream
PR NousResearch#38382 — cleaner, testable, separated from the message loop. Keep our
broader message-type coverage on top: audio/ptt, sticker, location, and
contact all return descriptive placeholders where the upstream PR
returns null. Also add documentMessage.fileName as a fallback.
@teknium1

Copy link
Copy Markdown
Contributor

Thanks for the focused WhatsApp reply-context fix. The requested behavior is already implemented on current main.

  • Automated hermes-sweeper review verified scripts/whatsapp-bridge/bridge_helpers.js:317 extracts quotedText from contextInfo.quotedMessage.
  • plugins/platforms/whatsapp/adapter.py:1443-1455 and :1514-1515 map that text and quoted ID into MessageEvent reply-context fields.
  • gateway/run.py:10592-10606 injects the structured context for the agent; tests/gateway/test_whatsapp_native_delivery.py:95-121 covers the mapping.
  • This shipped in 11627fdcb92a0ad57c9b637538f8fbea39142272 (feat(whatsapp): native Baileys polls, clarify-as-poll, locations, and rich inbound metadata), included in v2026.7.7.

The cross-referenced PR #44614 concerns the same behavior; this PR's old gateway/platforms/whatsapp.py target has since moved to the bundled WhatsApp plugin.

@teknium1 teknium1 closed this Jul 13, 2026
@teknium1 teknium1 added the sweeper:implemented-on-main Sweeper: behavior already present on current main label Jul 13, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

comp/gateway Gateway runner, session dispatch, delivery P3 Low — cosmetic, nice to have platform/whatsapp WhatsApp Business adapter sweeper:implemented-on-main Sweeper: behavior already present on current main type/bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants