Repository navigation
Conversation
|
Codex review: needs maintainer review before merge. Reviewed July 3, 2026, 5:19 PM ET / 21:19 UTC. Summary PR surface: Source +9, Tests +31. Total +40 across 2 files. Reproducibility: yes. Current main's exact matcher rejects punctuation-wrapped token-only replies by source inspection, and Mantis Telegram Desktop proof shows a baseline Review metrics: 1 noteworthy metric.
Root-cause cluster Members:
Proposal only: this assessment does not dispatch repair, suppress jobs, mutate sibling items, close, or merge anything. Merge readiness Overall follows the weaker of proof and patch quality, so missing proof can cap an otherwise strong patch. Rank-up moves:
Risk before merge
Maintainer options:
Next step before merge
Security Review detailsBest possible solution: Land one coordinated shared matcher policy, preferably by accepting this broader edge-punctuation behavior or folding it with the narrower open PR, while preserving substantive-reply guards and exact custom-token matches. Do we have a high-confidence way to reproduce the issue? Yes. Current main's exact matcher rejects punctuation-wrapped token-only replies by source inspection, and Mantis Telegram Desktop proof shows a baseline Is this the best way to solve the issue? Yes for the implementation boundary: the shared classifier is the right place, and the patch preserves substantive-reply and exact custom-token guards. The unresolved part is maintainer acceptance of the exported helper contract and coordination with the overlapping open PR. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against 7d593bb9ae54. Label changesLabel changes:
Label justifications:
Evidence reviewedPR surface: Source +9, Tests +31. Total +40 across 2 files. View PR surface stats
What I checked:
Likely related people:
What the crustacean ranks mean
Shiny media proof means a screenshot, video, or linked artifact directly shows the changed behavior. Runtime, network, CSP, and security claims still need visible diagnostics. How this review workflow works
|
|
@clawsweeper re-review |
|
🦞🧹 I asked ClawSweeper to review this item again. |
|
@clawsweeper re-review |
|
🦞🧹 I asked ClawSweeper to review this item again. |
|
@clawsweeper re-review |
|
🦞🧹 I asked ClawSweeper to review this item again. |
Mantis Telegram Desktop ProofSummary: Mantis captured native Telegram Desktop before/after GIFs showing main leaking .NO_REPLY and this PR suppressing it.
Motion-trimmed clips: |
…en detection When the model emits .NO_REPLY or *NO_REPLY* instead of bare NO_REPLY, isSilentReplyText() failed to detect it because the regex requires the text to consist only of the token with optional whitespace. Add stripEdgeNonAlnum() that strips leading/trailing non-letter, non-number characters (Unicode-aware) before the regex test. This catches stray punctuation while preserving the existing safeguard against suppressing mixed-content text. Related to openclaw#98166 Co-Authored-By: Claude <[email protected]>
Change stripEdgeNonAlnum to stripEdgePunct: strip only punctuation (\p{P}) instead of all non-letter/non-number characters. Emoji would be stripped by the former, causing false silent-reply on mixed content.
Related to openclaw#98166
Co-Authored-By: Claude <[email protected]>
…zation Try exact regex match first, then fall back to stripEdgePunct. This preserves exact matching for custom tokens whose first/last character is punctuation (e.g. *SILENT*, #QUIET#), while still catching the common case of NO_REPLY wrapped in stray punctuation. Add regression test for punctuation-edged custom tokens. ClawSweeper: openclaw#98224 (comment) Related to openclaw#98166 Co-Authored-By: Claude <[email protected]>
Trim whitespace before stripping edge punctuation in the fallback path so variants like " .NO_REPLY " and "NO_REPLY. " are also caught by the silent-reply detector. Add regression coverage for whitespace-wrapped edge punctuation. ClawSweeper: openclaw#98224 (comment) Related to openclaw#98166 Co-Authored-By: Claude <[email protected]>
4099eb6 to
2541bf7
Compare
|
Land-ready proof for exact head
No remaining proof gaps found. Ready to merge. |
|
Merged via squash.
|
…tection (openclaw#98224) * [AI] fix(auto-reply): strip stray punctuation before silent-reply token detection When the model emits .NO_REPLY or *NO_REPLY* instead of bare NO_REPLY, isSilentReplyText() failed to detect it because the regex requires the text to consist only of the token with optional whitespace. Add stripEdgeNonAlnum() that strips leading/trailing non-letter, non-number characters (Unicode-aware) before the regex test. This catches stray punctuation while preserving the existing safeguard against suppressing mixed-content text. Related to openclaw#98166 Co-Authored-By: Claude <[email protected]> * [AI] fix: strip only punct not emoji before silent-reply detection Change stripEdgeNonAlnum to stripEdgePunct: strip only punctuation (\p{P}) instead of all non-letter/non-number characters. Emoji would be stripped by the former, causing false silent-reply on mixed content. Related to openclaw#98166 Co-Authored-By: Claude <[email protected]> * [AI] fix: preserve exact custom-token match before edge-punct normalization Try exact regex match first, then fall back to stripEdgePunct. This preserves exact matching for custom tokens whose first/last character is punctuation (e.g. *SILENT*, #QUIET#), while still catching the common case of NO_REPLY wrapped in stray punctuation. Add regression test for punctuation-edged custom tokens. ClawSweeper: openclaw#98224 (comment) Related to openclaw#98166 Co-Authored-By: Claude <[email protected]> * [AI] fix: handle whitespace-wrapped punctuation in silent-reply fallback Trim whitespace before stripping edge punctuation in the fallback path so variants like " .NO_REPLY " and "NO_REPLY. " are also caught by the silent-reply detector. Add regression coverage for whitespace-wrapped edge punctuation. ClawSweeper: openclaw#98224 (comment) Related to openclaw#98166 Co-Authored-By: Claude <[email protected]> * test(auto-reply): tighten silent-token boundaries --------- Co-authored-by: Claude <[email protected]> Co-authored-by: Peter Steinberger <[email protected]>
…tection (#98224) * [AI] fix(auto-reply): strip stray punctuation before silent-reply token detection When the model emits .NO_REPLY or *NO_REPLY* instead of bare NO_REPLY, isSilentReplyText() failed to detect it because the regex requires the text to consist only of the token with optional whitespace. Add stripEdgeNonAlnum() that strips leading/trailing non-letter, non-number characters (Unicode-aware) before the regex test. This catches stray punctuation while preserving the existing safeguard against suppressing mixed-content text. Related to #98166 Co-Authored-By: Claude <[email protected]> * [AI] fix: strip only punct not emoji before silent-reply detection Change stripEdgeNonAlnum to stripEdgePunct: strip only punctuation (\p{P}) instead of all non-letter/non-number characters. Emoji would be stripped by the former, causing false silent-reply on mixed content. Related to #98166 Co-Authored-By: Claude <[email protected]> * [AI] fix: preserve exact custom-token match before edge-punct normalization Try exact regex match first, then fall back to stripEdgePunct. This preserves exact matching for custom tokens whose first/last character is punctuation (e.g. *SILENT*, #QUIET#), while still catching the common case of NO_REPLY wrapped in stray punctuation. Add regression test for punctuation-edged custom tokens. ClawSweeper: openclaw/openclaw#98224 (comment) Related to #98166 Co-Authored-By: Claude <[email protected]> * [AI] fix: handle whitespace-wrapped punctuation in silent-reply fallback Trim whitespace before stripping edge punctuation in the fallback path so variants like " .NO_REPLY " and "NO_REPLY. " are also caught by the silent-reply detector. Add regression coverage for whitespace-wrapped edge punctuation. ClawSweeper: openclaw/openclaw#98224 (comment) Related to #98166 Co-Authored-By: Claude <[email protected]> * test(auto-reply): tighten silent-token boundaries --------- Co-authored-by: Claude <[email protected]> Co-authored-by: Peter Steinberger <[email protected]>
…tection (#98224) * [AI] fix(auto-reply): strip stray punctuation before silent-reply token detection When the model emits .NO_REPLY or *NO_REPLY* instead of bare NO_REPLY, isSilentReplyText() failed to detect it because the regex requires the text to consist only of the token with optional whitespace. Add stripEdgeNonAlnum() that strips leading/trailing non-letter, non-number characters (Unicode-aware) before the regex test. This catches stray punctuation while preserving the existing safeguard against suppressing mixed-content text. Related to #98166 Co-Authored-By: Claude <[email protected]> * [AI] fix: strip only punct not emoji before silent-reply detection Change stripEdgeNonAlnum to stripEdgePunct: strip only punctuation (\p{P}) instead of all non-letter/non-number characters. Emoji would be stripped by the former, causing false silent-reply on mixed content. Related to #98166 Co-Authored-By: Claude <[email protected]> * [AI] fix: preserve exact custom-token match before edge-punct normalization Try exact regex match first, then fall back to stripEdgePunct. This preserves exact matching for custom tokens whose first/last character is punctuation (e.g. *SILENT*, #QUIET#), while still catching the common case of NO_REPLY wrapped in stray punctuation. Add regression test for punctuation-edged custom tokens. ClawSweeper: openclaw/openclaw#98224 (comment) Related to #98166 Co-Authored-By: Claude <[email protected]> * [AI] fix: handle whitespace-wrapped punctuation in silent-reply fallback Trim whitespace before stripping edge punctuation in the fallback path so variants like " .NO_REPLY " and "NO_REPLY. " are also caught by the silent-reply detector. Add regression coverage for whitespace-wrapped edge punctuation. ClawSweeper: openclaw/openclaw#98224 (comment) Related to #98166 Co-Authored-By: Claude <[email protected]> * test(auto-reply): tighten silent-token boundaries --------- Co-authored-by: Claude <[email protected]> Co-authored-by: Peter Steinberger <[email protected]>




What Problem This Solves
When a model emits
.NO_REPLYor*NO_REPLY*instead of bareNO_REPLY, the silent-reply sentinel leaks as visible prose because the regex only matches token-only text with optional whitespace.NO_REPLY(e.g..NO_REPLY,*NO_REPLY*,.NO_REPLY) bypassesisSilentReplyText(), causing the sentinel to leak to the channel as visible content.\p{P}(Unicode punctuation) to avoid stripping emoji. Preserves exact custom-token semantics.src/auto-reply/tokens.ts(newstripEdgePunct()helper + exact-first-then-fallback),src/auto-reply/tokens.test.ts(new test cases)Change Type (select all)
Scope (select all)
Linked Issue/PR
Motivation
The NO_REPLY sentinel is used by auto-reply to suppress silent model output. When the model adds stray punctuation — a common hallucination pattern — the sentinel leaks as visible text, causing user confusion.
Evidence
fix/no-reply-sentinel-punctuation-98166Root Cause (if applicable)
In
src/auto-reply/tokens.ts,getSilentExactRegex()generates/^\s*NO_REPLY(?:\s+NO_REPLY)*\s*$/iwhich requires token-only text with optional whitespace. Any stray punctuation causes the match to fail.User-visible / Behavior Changes
Fewer false negatives: model output consisting only of NO_REPLY with stray punctuation is now correctly suppressed instead of leaking.
Security Impact (required)
Best-fix Verdict
[^\p{L}\p{N}]— rejected because emoji would be stripped; direct regex modification — rejected due to pattern proliferation.AI Assistance 🤖
Risks and Mitigations
isSilentReplyTextis in plugin-sdk/reply-chunking) behavior broadens slightly.Related to #98166