feat(channels): batch 3 producers drop media placeholder bodies#111800
Merged
Conversation
Media-placeholder program batch 3: iMessage, Signal, and WhatsApp stop minting <media:kind> placeholder bodies. Primary bodies carry captions only with one aligned structured fact per native attachment (type-only for missing/rejected/oversized). Echo, quote, and pending-history records gain structured media facts so dedupe and previews work without rendered text. Signal media-only outbound sends drop the placeholder body entirely (signal-cli accepts attachment-only sends; recipients now see just the media). WhatsApp audio preflight de-stringed; qa-lab sticker recognizer moved to structured facts; WhatsApp gif maps to video (presentation mode, no behavioral consumer).
steipete
marked this pull request as ready for review
July 20, 2026 11:00
Contributor
Author
|
Merged via squash.
|
This was referenced Jul 20, 2026
github-actions Bot
pushed a commit
to Desicool/openclaw
that referenced
this pull request
Jul 21, 2026
…claw#111800) * feat(channels): batch 3 producers drop media placeholder bodies Media-placeholder program batch 3: iMessage, Signal, and WhatsApp stop minting <media:kind> placeholder bodies. Primary bodies carry captions only with one aligned structured fact per native attachment (type-only for missing/rejected/oversized). Echo, quote, and pending-history records gain structured media facts so dedupe and previews work without rendered text. Signal media-only outbound sends drop the placeholder body entirely (signal-cli accepts attachment-only sends; recipients now see just the media). WhatsApp audio preflight de-stringed; qa-lab sticker recognizer moved to structured facts; WhatsApp gif maps to video (presentation mode, no behavioral consumer). * test(whatsapp): keep media classifier private
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What Problem This Solves
Batch 3 of the media-placeholder elimination program (PR1 #111315; batches #111447, #111665). iMessage, Signal, and WhatsApp still minted
<media:kind>bodies — and, distinctively, cached rendered placeholder text in echo/dedupe, quote-preview, and pending-history records, losing the media fact once stored.Why This Change Was Made
{kind, contentType}(additive, no store version bump; kind-level fallback tolerates MIME transcoding, explicit message-ID conflicts prevent false drops); Signal durable reply-author records addmedia[]; WhatsApp reply contexts and quote-cache metadata add one fact. Text renders only where text is the carrier, viaformatMediaPlaceholderText(Signal deliberately keeps its established multi-attachment[N … attached]form).c26e0632c51, SendCommand.java:158-174/242-263 + JSON-RPC man page) shows attachment-only sends withmessage: ""are valid — the outbound placeholder body is dropped entirely, so remote Signal recipients now see just the media instead of literal<media:image>text.audio/*plus exact<media:audio>body (Feishu batch-2 pattern). WhatsAppgifmaps tovideo(GIF playback is a presentation mode; nothing consumes gif-ness — no kind-union growth). The qa-lab mock-openai<media:sticker>recognizer moves to structured sticker facts per the audit's assignment.User Impact
Media-only messages from these three channels no longer show placeholder text anywhere; captions are exactly what users typed. Signal media-only sends from OpenClaw no longer deliver literal
<media:image>text to recipients. Echo/dedupe and quote previews keep working through the structured records.Evidence
node scripts/run-vitest.mjs(one file per invocation) across iMessage (send, behavior, media-policy, inbound-processing, self-chat-dedupe, deliver), Signal (event-handler, media-text, reply-authors), WhatsApp (extract, monitor-inbox suites, on-message/process-message preflight), qa-lab, and core consumers.check:changedexit 0 on Blacksmith Testbox (run 29735312394): typechecks, lint, formatting, max-lines, SDK API baseline, plugin boundaries, dependency guards, import cycles.git diff --checkclean; zero<media:*>production literals remain in the three channels.extractMediaPlaceholderre-export — consciously rejected: zero references remain in-tree, it was never exposed viaopenclaw/plugin-sdk/*(the only supported external import surface), bundled-pluginruntime-api.tsbarrels are internal core↔bundled seams, and batch 2 (feat(channels): batch 2 producers drop media placeholder bodies #111665) deletedbuildDiscordMediaPayloadfrom the same barrel class. Two implementation-side compat suggestions (12-hour transient echo-cache recognizer; same export) were likewise rejected under the program's hard-delete policy — transient caches are rebuildable state.