Skip to content

fix(slack): recognize MiniMax mm: namespaced reasoning tags in monitor preview#93874

Merged
vincentkoc merged 1 commit into
openclaw:mainfrom
Alix-007:fix/slack-monitor-mm-reasoning-tag
Jun 17, 2026
Merged

fix(slack): recognize MiniMax mm: namespaced reasoning tags in monitor preview#93874
vincentkoc merged 1 commit into
openclaw:mainfrom
Alix-007:fix/slack-monitor-mm-reasoning-tag

Conversation

@Alix-007

Copy link
Copy Markdown
Contributor

Summary

#93767 added MiniMax mm: namespace support to reasoning-tag handling across 9 files, and its description explicitly noted the same antml:-only / no-namespace pattern is duplicated in "the slack/imessage/matrix monitors". The src-side paths were since covered (#93806, merged) and the iMessage monitor too (#93820), but the Slack monitor reasoning-tag regex was still missed:

  • extensions/slack/src/monitor/message-handler/dispatch.ts:125SLACK_REASONING_TAG_RE, which feeds extractSlackReasoningTagText → the streaming "Reasoning" progress preview (normalizeSlackReasoningProgressLine / pushReasoningProgress).

Result: when a MiniMax model inlines its chain-of-thought as <mm:think>…</mm:think>, the regex doesn't match, extractSlackReasoningTagText returns empty, and the shared stripReasoningTagsFromText (already mm:-aware) strips the whole block — so the MiniMax reasoning never shows up in Slack's streaming Reasoning progress indicator (a functional parity gap, not a leak).

Changes

  • SLACK_REASONING_TAG_RE: (?:think(?:ing)?|thought|antthinking)(?:(?:antml:|mm:)?(?:think(?:ing)?|thought)|antthinking), aligning with src/shared/text/reasoning-tags.ts and fix(reasoning-tags): strip MiniMax mm: namespaced reasoning tags #93767's pattern. The (?:antml:|mm:)? prefix is added to think/thought only; antthinking and the open/close capture group are untouched. +27/-1 across 2 files (one is the test).

Real behavior proof

Behavior addressed: MiniMax mm:-namespaced reasoning tags are now recognized by the Slack monitor preview extractor, matching antml:/bare behavior (and the already-merged Telegram/iMessage monitors).

Test (real exported function): added an end-to-end case in dispatch.preview-fallback.test.ts that drives the real exported dispatchPreparedSlackMessage — streaming a reasoning entry <mm:think>Reading\nChecking</mm:think> and asserting the final Slack progress draft preview contains • Reading Checking (the extracted reasoning), not an empty/stripped line. A bare <think> case is retained as a no-regression control.

Negative control (logic): pre-fix, SLACK_REASONING_TAG_RE does not match <mm:think>extractSlackReasoningTagText returns "" → the fallback stripReasoningTagsFromText (mm-aware) removes the whole block → the preview shows no reasoning; post-fix the regex matches → the reasoning is extracted into the preview.

What was not run locally: the test was not executed in this worktree (fresh worktree without node_modules; skipped pnpm install to avoid a heavy monorepo install). CI runs the added test.

Scope / context

Narrow follow-up to #93767 (whose own description named the slack monitor as a missed spot), in the same series as merged #93806 (src paths) and #93820 (iMessage monitor). Slack and Matrix were the two remaining monitors; this covers Slack. Not intended to close the umbrella issue #89473 — purely the narrow mm: recognition fix that #93767 established the precedent for.

@openclaw-barnacle openclaw-barnacle Bot added channel: slack Channel integration: slack size: XS triage: needs-real-behavior-proof Candidate: external PR needs after-fix proof from a real setup. labels Jun 17, 2026
@vincentkoc vincentkoc self-assigned this Jun 17, 2026
@vincentkoc vincentkoc added proof: override Maintainer override for the external PR real behavior proof gate. and removed triage: needs-real-behavior-proof Candidate: external PR needs after-fix proof from a real setup. labels Jun 17, 2026
@vincentkoc
vincentkoc force-pushed the fix/slack-monitor-mm-reasoning-tag branch from 632ac89 to acad095 Compare June 17, 2026 03:14
@vincentkoc
vincentkoc force-pushed the fix/slack-monitor-mm-reasoning-tag branch from acad095 to 6e48113 Compare June 17, 2026 03:36
@vincentkoc

Copy link
Copy Markdown
Member

Maintainer verification completed.

  • Aligns Slack's preview extractor with the shared mm:/antml: thinking-tag grammar. The shared visible-text stripper is intentionally not reused here because the progress preview must retain the reasoning content.
  • Blacksmith Testbox via Crabbox (tbx_01kv9t87vwewfab0p0vvjc39j5): pnpm test extensions/slack/src/monitor/message-handler/dispatch.preview-fallback.test.ts passed 76/76 on rebased head 6e4811310c.
  • Fresh autoreview: clean, no accepted/actionable findings.
  • Full GitHub CI is green on this rebased head. The earlier snapshot drift was repaired on main in 2a02746bd7.

Ready to land.

@vincentkoc
vincentkoc merged commit d2bf67f into openclaw:main Jun 17, 2026
158 checks passed
karmafeast added a commit to karmaterminal/openclaw that referenced this pull request Jun 17, 2026
…5651) (#1038)

* refactor(agents): hide update plan gating helper

* fix(e2e): keep live plugin pack paths local

* refactor(agents): drop mcp fetch type re-export

* refactor(agents): hide mcp oauth redirect classifier

* refactor(agents): remove catalog browse timer test hooks

* refactor(agents): hide execution contract resolver

* fix(e2e): reject unsafe Docker pack names

* clawdbot-d02.1.9.1.31: add sessions.create lifecycle seam (openclaw#93691)

* refactor(agents): hide assistant stream delivery types

* refactor(agents): hide message handler helpers

* fix: clean agent lint failures

* refactor(agents): hide compaction reconcile wrapper

* refactor(agents): hide context cache reset helper

* refactor(agents): hide copilot routing constants

* refactor(agents): hide subagent outcome helpers

* refactor(agents): hide tool mutation helpers

* refactor(agents): hide transport error extractor

* refactor(agents): remove video task status wrappers

* refactor(agents): hide custom api source id helper

* refactor(agents): hide docs path helpers

* fix(codex): sync app-server dynamic tool protocol

* refactor(agents): hide timeout seconds helper

* fix(gemini): bridge OAuth profiles into CLI runtime

* fix: persist Gemini CLI auth homes

* fix: preserve Gemini CLI project binding

* fix: scope CLI auth epochs to agent stores

* fix: fail closed on unstaged Gemini profiles

* fix: preserve runtime auth alias scope

* fix: keep CLI auth fallback scoped

* fix: accept Google API keys for Gemini CLI

* fix: honor Google auth order for Gemini CLI

* test: type Gemini CLI auth refresh mock

* fix: forward pinned Gemini CLI auth for validation

* fix: bind Gemini CLI epochs to profile homes

* fix: keep CLI prepare credentials private

* fix: ignore stale auto auth for Gemini CLI

* fix: stage resolved Gemini OAuth profiles

* fix: clear ambient Google ADC for Gemini CLI

* fix: stage adopted Gemini OAuth credentials

* fix: isolate Gemini CLI system auth settings

* fix: enforce Gemini CLI profile auth precedence

* fix: keep Gemini CLI system settings per run

* fix: clean Gemini bundle settings on prepare failure

* fix: preserve ambient Gemini system auth

* fix: honor inherited Gemini auth policy

* test: fix Gemini CLI auth test types

* test: narrow Gemini CLI setup agent dir

* fix: pass prepared CLI env to spawned process

* fix: expose CLI runtime env diagnostics

* fix: load staged Gemini CLI auth profiles

* fix: log Gemini CLI runtime env activation

* fix: select CLI auth profile for runtime prep

* fix: keep CLI env diagnostics opt-in

* fix: align Gemini CLI home path

* fix: add CLI empty response diagnostics

* fix: parse Gemini CLI stream output

* fix: allow Gemini CLI file edits

* docs: update Gemini CLI backend defaults

* fix: use OpenClaw temp root for Gemini CLI settings

* fix: clean up Gemini CLI backend checks

* fix: keep Gemini CLI auth out of warmup

* refactor(agents): hide cleanup timeout helpers

* refactor(agents): hide stale run cutoff

* refactor(agents): hide compaction timeout internals

* refactor(agents): remove stale compaction grace helper

* refactor(agents): hide idle timeout default

* refactor(plugins): hide cleanup timeout internals

* refactor(qqbot): hide response timeout default

* refactor(feishu): hide timeout config type

* refactor(browser): hide cdp reachability defaults

* docs: add Gemini CLI auth changelog entry

* refactor(agents): hide context window thresholds

* refactor(agents): hide fallback skip cache internals

* fix(agents): tolerate uncloneable adjusted tool params

* refactor(cli): hide compile cache and media internals

* fix(slack): preserve completed native progress titles

* refactor(acp): hide test helper internals

* refactor(tests): hide helper-only types

* refactor(tests): hide gateway state helper types

* fix(deps): remediate Dependabot alerts (openclaw#93857)

Merged via squash.

Prepared head SHA: 51ece24
Co-authored-by: vincentkoc <[email protected]>
Co-authored-by: vincentkoc <[email protected]>
Reviewed-by: @vincentkoc

* refactor(commands): hide doctor harness mocks

* refactor(commands): hide doctor e2e mock internals

* refactor(commands): hide doctor service install mock

* refactor(commands): hide gateway readiness types

* refactor(commands): hide health summary internals

* refactor(commands): trim health type reexports

* refactor(commands): trim migrate option reexports

* refactor(commands): trim backup type exports

* test(codex): refresh dynamic tool snapshots

* refactor(commands): hide onboarding install result

* fix(ui): harden chromium test runner

* refactor(commands): hide status task helper types

* refactor(commands): trim setup type reexports

* fix(slack): recognize MiniMax mm: namespaced reasoning tags in monitor preview (openclaw#93874)

* refactor(commands): hide doctor repair helper types

* feat(providers): add ClawRouter managed proxy

* docs(providers): document ClawRouter integration

* chore(providers): align ClawRouter package version

* fix(providers): preserve ClawRouter native replay policies

* chore(deps): register ClawRouter workspace

* fix(providers): consume canonical ClawRouter catalog field

* fix(providers): restore ClawRouter native runtime routes

* fix(providers): isolate ClawRouter runtime credentials

* fix(providers): cover ClawRouter runtime auth paths

* fix(providers): preserve ClawRouter catalog model ids

* fix(providers): require runnable ClawRouter Gemini routes

* fix(providers): route ClawRouter direct streams

* fix(providers): apply wrappers to direct streams

* fix(providers): wrap direct fallback streams

* fix(providers): compose ClawRouter native auth

* fix(providers): align ClawRouter package boundary

* fix(sdk): refresh plugin api baseline

* refactor(commands): hide doctor utility types

* refactor(commands): hide doctor state helper types

* refactor(commands): trim doctor probe type exports

* refactor(commands): trim setup barrel type exports

* fix(macos): preserve approvals migration data (openclaw#93880)

Merged via squash.

Prepared head SHA: a8a0dd0
Co-authored-by: vincentkoc <[email protected]>
Co-authored-by: vincentkoc <[email protected]>
Reviewed-by: @vincentkoc

* refactor(flows): hide setup helper types

* refactor(commands): trim custom provider type reexports

* fix(cron): reject invalid absolute timestamps (openclaw#93903)

* fix(cron): reject invalid absolute timestamps

* fix(cron): preserve ISO end of day

---------

Co-authored-by: Vincent Koc <[email protected]>

* refactor(commands): hide custom provider helper types

* fix(update): use configured npm registry for update metadata (openclaw#93879)

Merged via squash.

Prepared head SHA: ae8bbb0
Co-authored-by: vincentkoc <[email protected]>
Co-authored-by: vincentkoc <[email protected]>
Reviewed-by: @vincentkoc

* refactor(commands): trim status type exports

* refactor(commands): hide doctor helper types

* refactor(commands): hide migrate helper types

* refactor(config): hide local helper types

* revert(providers): remove ClawRouter provider

* refactor(config): hide session helper types

* refactor(gateway): hide local helper types

* refactor(gateway): hide websocket helper types

* refactor(infra): hide local helper types

---------

Co-authored-by: Vincent Koc <[email protected]>
Co-authored-by: Josh Lehman <[email protected]>
Co-authored-by: Shakker <[email protected]>
Co-authored-by: Jason O'Neal <[email protected]>
Co-authored-by: Vincent Koc <[email protected]>
Co-authored-by: Alix-007 <[email protected]>
Co-authored-by: ronan-dandelion-cult <[email protected]>
Co-authored-by: Claude Opus 4.8 (1M context) <[email protected]>
github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Jun 17, 2026
@Alix-007

Copy link
Copy Markdown
Contributor Author

Thanks for working through so many of these today, @vincentkoc — really appreciate the review time.

crh-code pushed a commit to crh-code/openclaw that referenced this pull request Jun 18, 2026
zhangguiping-xydt added a commit to zhangguiping-xydt/openclaw that referenced this pull request Jun 20, 2026
…or replies

Mirrors openclaw#93874 (slack monitor) for the matrix extension. The matrix
reply delivery path checks shouldSuppressReasoningReplyText to drop
reasoning-only payloads before they reach the Matrix room; the
THINKING_TAG_RE / THINKING_BLOCK_RE patterns only matched bare,
antml:, or antthinking variants, so MiniMax <mm:think>…</mm:think>
payloads were treated as ordinary replies and the reasoning text was
sent into the Matrix room (a reasoning leak, not just a missed preview).

Align the regexes with src/shared/text/reasoning-tags.ts and openclaw#93767's
precedent by adding an optional (?:antml:|mm:)? prefix on
think/thinking/thought; antthinking is left unprefixed.

Adds a regression test that streams three mm: namespaced reasoning-only
replies and asserts only the visible answer reaches sendMessageMatrix.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

channel: slack Channel integration: slack proof: override Maintainer override for the external PR real behavior proof gate. size: XS

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants