openclaw - 💡(How to fix) Fix [BUG] Image URL loop concatenation causes infinite output when model outputs image markdown

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…

When the model generates output containing image markdown (e.g. ![image](url)), the text gets repeatedly concatenated with the URL string, causing a loop that produces hundreds of _image)**_image)**_image)... tokens until the session is aborted.

Root Cause

When the model generates output containing image markdown (e.g. ![image](url)), the text gets repeatedly concatenated with the URL string, causing a loop that produces hundreds of _image)**_image)**_image)... tokens until the session is aborted.

Code Example

![image](https://cdn.minimaxi.com/photo/2026-05-19/060601.jpg)_image)**_image)**_image)..._image)**

---

![image](https://cdn.minimaxi.com/photo/2026-05-19/060601.jpg)
RAW_BUFFERClick to expand / collapse

Description

When the model generates output containing image markdown (e.g. ![image](url)), the text gets repeatedly concatenated with the URL string, causing a loop that produces hundreds of _image)**_image)**_image)... tokens until the session is aborted.

Steps to Reproduce

  1. Send a message to OpenClaw that causes the model to return an inline image (e.g. ![image](https://cdn.minimaxi.com/photo/2026-05-19/060601.jpg))
  2. Observe the assistant response — instead of a single image reference, the text _image)** gets repeated dozens of times

Actual Result

![image](https://cdn.minimaxi.com/photo/2026-05-19/060601.jpg)_image)**_image)**_image)..._image)**

(session ultimately gets aborted or hits token limit)

Expected Result

![image](https://cdn.minimaxi.com/photo/2026-05-19/060601.jpg)

Should render as a single image without loop.

Environment

  • Model: minimax/MiniMax-M2.7 (confirmed via session_history)
  • Channel: webchat
  • Runtime: agent=main on Exo-Service (Mac Mini M4 16GB)

Session ID

agent:main:dashboard:b27d76be-4946-4e1b-b8e2-6f2b0958cd71

Additional Context

The issue was reproduced in the main dashboard session on 2026-05-19. The loop stopped when the session was aborted. This appears to be a text rendering/markdown processing bug where the closing ) of the image URL triggers repeated concatenation of the _image)** fragment.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING

openclaw - 💡(How to fix) Fix [BUG] Image URL loop concatenation causes infinite output when model outputs image markdown