-
-
Notifications
You must be signed in to change notification settings - Fork 39.9k
Open
Labels
enhancementNew feature or requestNew feature or request
Description
Problem
When a Signal message is edited, signal-cli provides an editMessage envelope containing:
targetSentTimestamp— the original message timestamp being editeddataMessage— the new message content
Currently, OpenClaw treats edited messages as entirely new messages, which:
- Creates duplicate context in the session
- Can trigger duplicate responses
- Loses the connection between original and edited content
Use Case
In group chats, users frequently edit messages to fix typos or clarify. The agent sees both versions as separate messages, cluttering context and potentially responding to outdated content.
Proposed Solution
- Detect edits: Check for
envelope.editMessagein incoming Signal messages - Mark as edit: Add
[edited]marker or metadata to the message context - Optional dedup: Replace the original message in the transcript with the edited version (using
targetSentTimestampto match) - Skip re-triggering: Don't trigger a new response for edits unless the user explicitly @mentions
Technical Reference
signal-cli already provides the metadata:
// src/main/java/org/asamk/signal/json/JsonEditMessage.java
record JsonEditMessage(long targetSentTimestamp, JsonDataMessage dataMessage)JSON envelope example:
{
"envelope": {
"editMessage": {
"targetSentTimestamp": 1234567890,
"dataMessage": { "message": "corrected text", ... }
}
}
}Affected Code
- Signal plugin message receiver
- Message envelope parsing
- Session transcript handling
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or request