Skip to content

Keep each reply's live reasoning apart in every SDK - #1051

Merged
martinmitrevski merged 3 commits into
acceleratefrom
accelerate-live-reasoning-per-reply
Oct 21, 2026
Merged

martinmitrevski merged 3 commits into
acceleratefrom
accelerate-live-reasoning-per-reply

Conversation

@martinmitrevski

Copy link
Copy Markdown

Why

The router names a reply's reasoning steps r1, r2, ... per reply, so every reply has an r1. LiveReasoning looked a step up by its id alone, so a later reply's live thinking mixed with an earlier reply's. When its round was shorter than the earlier one's, it was dropped as already held. When it was longer, it was joined onto the earlier text. Either way, the earlier reply's thinking showed in the later reply's step.

Changes

  • A step is read by its reply and its id in every SDK that has a LiveReasoning:
    • Swift: reasoning[message: message.id, step: step.id]
    • JS: reasoning.get(message.id, step.id)
    • Kotlin: reasoning[message.id, step.id], and add takes the message id before the step id
    • Dart: reasoning[(message: message.id, step: step.id)]
  • read takes the message id from the message it reads, so apps that only call read change only their lookups.
  • The Swift and Android demos look steps up this way.
  • Tests in each SDK for replies whose first rounds are shorter and longer than an earlier reply's.
  • README, the sdk and sdk-swift skills, and the changelog.

🤖 Generated with Claude Code

LiveReasoning looked a step up by its id alone, and every reply numbers its
steps from r1, so a later reply's live thinking was dropped when its round
was shorter than an earlier reply's, or ran on after it when longer. A step
is now read by its reply and its id in the Swift, JS, Kotlin and Dart SDKs,
and the demos read it that way.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
martinmitrevski and others added 2 commits October 20, 2026 17:41
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@martinmitrevski
martinmitrevski merged commit ca0d7d2 into accelerate Oct 21, 2026
11 checks passed
@martinmitrevski
martinmitrevski deleted the accelerate-live-reasoning-per-reply branch October 21, 2026 08:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant