<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
  <channel>
    <title>Streaming on Margrop Blog</title>
    <link>https://blog.margrop.net/en/tag/streaming/</link>
    <description>Recent content in Streaming on Margrop Blog</description>
    <generator>Hugo -- gohugo.io</generator>
    <language>en-US</language>
    <lastBuildDate>Tue, 02 Jun 2026 10:42:00 +0800</lastBuildDate>
    <atom:link href="https://blog.margrop.net/en/tag/streaming/index.xml" rel="self" type="application/rss+xml" />
    <item>
      <title>OpenClaw TUI Keeps Repeating Itself? A Temporary Patch for Duplicate Thinking and Replies</title>
      <link>https://blog.margrop.net/en/post/openclaw-tui-duplicate-thinking-stream-patch/</link>
      <pubDate>Tue, 02 Jun 2026 10:42:00 +0800</pubDate>
      <guid>https://blog.margrop.net/en/post/openclaw-tui-duplicate-thinking-stream-patch/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;&lt;strong&gt;The short version&lt;/strong&gt;&lt;/p&gt;&#xA;&lt;p&gt;If OpenClaw TUI shows the same thinking block twice and repeats the final answer, do not immediately delete every session or rebuild every model provider. In many OpenAI-compatible setups, the real issue is a streaming compatibility edge case: the upstream stream emits normal &lt;code&gt;delta&lt;/code&gt; chunks and then an extra full &lt;code&gt;message&lt;/code&gt; tail. Some OpenClaw paths may aggregate both, so the TUI and the persisted session both end up with duplicated content.&lt;/p&gt;&#xA;&lt;p&gt;The practical temporary fix is to back up the local OpenClaw installation, add a conservative dedupe guard in the OpenClaw aggregation layer, restart the gateway, and verify with a unique marker that both the visible reply and the session file contain only one copy.&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;p&gt;This is a privacy-safe incident note. All endpoints, model names, tokens, internal addresses, and session identifiers are replaced by placeholders. Use your own installation path and model identifiers when applying the workaround.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Double-Consumed Streaming: Debugging a NewAPI v1.0.0-rc.10 MiniMax Proxy Bug</title>
      <link>https://blog.margrop.net/en/post/newapi-streaming-duplicate-content-debugging/</link>
      <pubDate>Sun, 31 May 2026 18:00:00 +0800</pubDate>
      <guid>https://blog.margrop.net/en/post/newapi-streaming-duplicate-content-debugging/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;&lt;strong&gt;TL;DR&lt;/strong&gt;&lt;/p&gt;&#xA;&lt;p&gt;An AI Agent was producing duplicated replies in DingTalk — not two separate messages, but a single message whose content appeared twice. The root cause traced back to a streaming bug in NewAPI (the QuantumNous fork of OneAPI) v1.0.0-rc.10: when proxying MiniMax through the OpenAI Chat Completions protocol, the finish chunk contained &lt;strong&gt;both &lt;code&gt;delta.content&lt;/code&gt; and &lt;code&gt;message.content&lt;/code&gt;&lt;/strong&gt; with identical values. The Agent&amp;rsquo;s stream handler consumed both as &amp;ldquo;visible text,&amp;rdquo; concatenating the content twice. The fix was straightforward: switch the OpenClaw provider protocol from &lt;code&gt;openai-completions&lt;/code&gt; to &lt;code&gt;anthropic-messages&lt;/code&gt;, which OneAPI natively supports and where streaming behaves correctly.&lt;/p&gt;&#xA;&lt;p&gt;No internal IPs, tokens, model IDs, or private paths appear in this article. All configuration snippets have been sanitized.&lt;/p&gt;&#xA;&lt;/blockquote&gt;</description>
    </item>
  </channel>
</rss>
