Skip to content

[GH-324] Fix bold markdown adjacency in Telegram and WhatsApp#326

Merged
milosmns merged 1 commit intomainfrom
claude/issue-324-20260309-1033
Mar 9, 2026
Merged

[GH-324] Fix bold markdown adjacency in Telegram and WhatsApp#326
milosmns merged 1 commit intomainfrom
claude/issue-324-20260309-1033

Conversation

@milosmns
Copy link
Contributor

@milosmns milosmns commented Mar 9, 2026

Fixes #324

Changes

  • Telegram: Fix single-asterisk bold regex in escape_markdown to use word-boundary lookbehind/lookahead instead of whitespace constraints, so *bold*, and *bold*. are preserved
  • WhatsApp: Update chat_whatsapp prompt in the prompt library to explicitly instruct the bot never to use double asterisks (**) and always use WhatsApp's native single-asterisk bold format
  • Add punctuation-adjacency test cases to Telegram markdown utils tests

Generated with Claude Code

- Telegram: fix single-asterisk bold regex to use word-boundary lookbehind/lookahead
  instead of whitespace constraints, so *bold*, and *bold*. are preserved
- WhatsApp: update chat_whatsapp prompt to explicitly disallow double asterisks (**),
  instructing the bot to always use WhatsApp's native single-asterisk bold format
- Add punctuation-adjacency test cases to Telegram markdown utils tests

Co-authored-by: Milos Marinkovic <milosmns@users.noreply.github.com>
@milosmns milosmns self-assigned this Mar 9, 2026
@github-actions
Copy link
Contributor

github-actions bot commented Mar 9, 2026

Build 22852099785 complete for 63a1aa4.

# Valid until a new build
docker pull appifyhub/the-agent:latest_pr
docker pull appifyhub/the-agent:5.0.21.pr_326

@milosmns milosmns merged commit e8cf611 into main Mar 9, 2026
3 checks passed
@milosmns milosmns deleted the claude/issue-324-20260309-1033 branch March 9, 2026 15:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[BUG] Markdown Bold Breaks When Asterisks Are Adjacent to Punctuation in Telegram & WhatsApp Outputs

1 participant