Install
openclaw skills install matrix-mentions-patchFix OpenClaw Matrix plugin mention detection bug. Use when OpenClaw doesn't respond to @mentions in Matrix group rooms despite correct configuration. The bug is that buildMentionRegexes() is called without agentId, causing mention patterns to not be built correctly.
openclaw skills install matrix-mentions-patchOpenClaw Matrix plugin doesn't respond to @mentions in group rooms even when:
requireMention: true@runwheezy:matrix.biochao.cc)In /home/bot/.openclaw/extensions/matrix/src/matrix/monitor/index.ts, the buildMentionRegexes function is called WITHOUT passing agentId:
// BUG: Missing agentId parameter
const mentionRegexes = core.channel.mentions.buildMentionRegexes(cfg);
Without agentId, the function can't resolve agent-specific mention patterns from config, causing mentions to never be detected.
Edit /home/bot/.openclaw/extensions/matrix/src/matrix/monitor/index.ts:
Find line ~298:
const mentionRegexes = core.channel.mentions.buildMentionRegexes(cfg);
Change to:
const mentionRegexes = core.channel.mentions.buildMentionRegexes(cfg, "main");
Replace "main" with your actual agent ID if different.
openclaw gateway restartThe fix loads immediately - no rebuild needed since the extension is loaded dynamically.