Skip to content

Studio: replace reasoning pagination with a continuous transcript - #11522

Merged
oobabooga merged 11 commits into
unslothai:mainfrom
wasimysaid:fix/reasoning-inline-transcript
Sep 22, 2026
Merged

oobabooga merged 11 commits into
unslothai:mainfrom
wasimysaid:fix/reasoning-inline-transcript

Conversation

@wasimysaid

@wasimysaid wasimysaid commented Sep 22, 2026 •

Copy link
Copy Markdown
Collaborator

Summary

Replace paginated reasoning with a continuous, windowed transcript. Long thinking stays readable while streaming without mounting the entire trace.

Related: #10717, #11423, #11433.

Synced PRs: upstream #11522 · fork review mirror #208. Both track the same head branch; the mirror base is pinned to the upstream base without changing the fork's main branch.

  • Remove Earlier / Newer / Latest, character counters, and the oversized-code truncation panel.
  • Render nearby prose and code fragments; highlight code in a worker and retain full-source copy.
  • Preserve the reading passage while tokens arrive, the transcript becomes windowed, and the viewport narrows.
  • Keep saved and live collapse/reopen anchored at the header; reopening exposes the beginning. Scroll-to-bottom resumes following.
  • Reuse the existing toggle scroll lock in both directions to prevent native browser anchoring from moving a reopened header after a long prompt.
  • Delete the superseded paginator, its tests, and obsolete streaming height-cap state.
  • Preserve document-scoped reference links and continued list/quote formatting across bounded fragments, without repeating list markers or changing canonical copy/export.

Live Studio demo

20-second refreshed live Studio recording: accelerated reasoning, live reopen, and code controls

New MP4 video · New measurements · Recording notes

Fresh real EC2 Studio recording at 897839187, Qwen3.8-27B-UD-Q4_K_XL, Extra High reasoning, original Tesla-coil prompt. Captured 93,005 reasoning characters. Approximately 204 seconds of real streaming become eight seconds at 25.6×, followed by eight seconds of normal-speed live reading/collapse/reopen/resume-following and a separate four-second code copy/download shot. Code clipboard and download matched (1,001 characters). Live reopen header drift was 0 px; the reading-position sampler did not obtain an anchor in this run, so no numeric reading-drift result is claimed.

GIF playback is 6 FPS for attachment size; MP4 is 30 FPS. Neither is measured app FPS. Studio and its model were stopped afterward, releasing this test's GPU allocation. Media lives on the separate evidence branch, not in the code diff; no credentials or auth state are published. This recording predates the three review fixes finalized at 899dccfbc; those have separate production-browser regression checks, not a new GPU recording.

Earlier recording and comparison benchmark data at 044e4e77b remain available as historical evidence.

Performance

Measured separately from video recording using browser rAF intervals and long-task observations. Local headless Chromium at approximately 60 Hz accessed the EC2 production build through an SSH tunnel. Same cached Qwen model, B200, actual context 262144; no mocked token stream.

Scenario Average FPS p95 frame time Notes
Fresh 897839187: Extra High, before recording 60.0 16.7 ms 73 seconds; no >50 ms frames or long tasks
High reasoning: following / reading / windowed 60.0 16.7–16.8 ms 65,828 reasoning characters; no >50 ms frames in these intervals
Extra High reasoning: following / reading / windowed 60.0 16.7–16.8 ms 118,756 reasoning characters; no >50 ms frames in these intervals
High answer: isolated intervals 59.2–59.8 16.8 ms Occasional spikes, worst 400.1 ms
Extra High answer: clean follow interval 59.9 16.7 ms 279 seconds; worst 366.6 ms

Threshold activation moved the real reading passage by less than 0.35 px. Live desktop-to-mobile reflow retained the same passage with 47.6 px vertical drift and no horizontal overflow. Saved/live long-prompt reopen regressions pass; the final real recording measured 0 px live header drift.

Five paired production synthetic runs were comparable in total render duration: baseline/new 677.3/644.5 ms for 100K mixed text and 1373.7/1329.0 ms for 250K. The 140K code case increased 3.3% in total duration (816.7/843.4 ms), while p95 frame time improved from 100 to 83.4 ms. This is a UX fix with bounded rendering, not a claim of a universal speedup.

Targeted Codex-review regression at f3cbf84f0: a synthetic 250K-character live code fence (512-character appends) mounted 4,932 characters across nine rows; p95 frame time was 16.8 ms, worst 133.3 ms. The worker received one initial 16,787-character source, then deltas no larger than 512 characters. Five paired index-only runs reduced median append time from approximately 0.71 to 0.13 ms; this is not a browser FPS comparison. Review regression data.

Validation

  • 8,358 frontend tests
  • Typecheck, production build, strict translation parity
  • Production browser checks: bounded content, no pagination, full-source copy, saved/live collapse and reopen, threshold/streaming/resize anchors, selection retention, resume following, narrow code, light/dark, reference links, nested/quoted list continuation markers
  • Codex regression checks: incremental live fences, continued tables, bounded Mermaid diagrams, tall-paragraph threshold anchor (0 px drift), native long-line selection without false newlines, invisible definition rows
  • Follow-up at 897839187: bounded SVG previews and existing per-fence copy/download controls, including offscreen source; validation data
  • Third review fixes at 899dccfbc: completed large fences enable full-source copy/download while later reasoning streams; bounded SVG aliases (svg, SVG, xml, html) and HTML artifact cards reuse the established renderer; ordinary code retains its optimized rendering geometry
  • Updated obsolete height-cap/toggle Python contracts; eight focused Python checks pass
  • Real High and Extra High Tesla generations; final-build short live mobile regression
  • Superseded implementation removed; no compatibility paginator retained
  • Isolated Studio stopped and GPU released after testing/recording

Reasoning-module lint has no errors (existing TanStack compiler warning remains). The shared code-fence file has two pre-existing ref-during-render lint errors outside the changed lines; full-repository lint also has pre-existing failures. The wider local font-scale test finds an unchanged raw-pixel class in cache storage settings. Fork CPU CI additionally has Docker tests expecting the upstream owner. These unrelated failures are not expanded into this UI PR. Native WebKit FPS validation remains incomplete; Chromium measurements should not be generalized to every device.

The original comparison measurements were captured at 044e4e77b; the refreshed video and labeled 73-second performance sample use 897839187. Three connected Codex review rounds have been triaged: six initial regressions fixed at f3cbf84f0, two SVG/code-action regressions fixed at 897839187, then three fence-compatibility regressions finalized at 899dccfbc. The latest runtime fix deletes the duplicate fallback path and keeps ordinary code on its existing incremental renderer. No new dependencies or paginator compatibility path. Independent scoped Standards and Spec reviews both found no issues; this is not a claim of blanket Codex bot approval.

Latest production-browser synthetic check at 899dccfbc: 250K-character live code, p95 16.8 ms, worst 116.7 ms, 4,932 mounted characters in nine rows. Highlighting transferred one initial 16,787-character source followed by deltas no larger than 512 characters. Native 16,384-character selection and tall-paragraph threshold anchoring (0 px drift) passed. Closed-fence copy/download matched all 44,999 characters while later reasoning was still streaming; open-fence actions remained disabled. Both production-browser suites pass, including long-prompt mobile reflow and saved/live reopening. These are local synthetic regressions, separate from the real Studio video measurements above.

Three review suggestions are explicitly deferred, not claimed fixed: a single equation longer than 8,192 characters, full-history find beyond mounted content, and replacing full-prefix validation with an append/revision protocol. The prefix scan remains linear per update; measured scan p95 was 0.167 ms for 512-character appends to 256K and 0.617 ms for ten-character appends to 250K. The production 250K stream stayed at 16.8 ms p95 frames. This is a documented scope/performance tradeoff, not an O(1) claim. Review threads contain the rationale and measurements; resolving them records triage, not blanket bot approval.

The generated Tesla HTML had separate runtime errors, so its animation FPS is not claimed. Studio's isolated chat-history __LOCALID_... 404s were also observed; those are outside this UI change. Full reasoning was exported before reload. Browser find still covers mounted content, not an added full-trace search index.

@wasimysaid

wasimysaid commented Sep 22, 2026 •

Copy link
Copy Markdown
Collaborator Author

@codex review

@wasimysaid

Copy link
Copy Markdown
Collaborator Author

Codex review mirror (connected installation): wasimysaid#208. Both PRs track the same head branch and currently the same base commit; fixes pushed to the branch update both PRs.

@wasimysaid

wasimysaid commented Sep 22, 2026 •

Copy link
Copy Markdown
Collaborator Author

Refreshed the PR video on 8978391: a new 20-second real EC2 Studio recording with Qwen3.8-27B Extra High and the Tesla prompt. 93,005 reasoning characters; streaming accelerated 25.6×, followed by normal-speed live reopening and code copy/download. Header reopen drift: 0 px. The separate pre-recording 73-second interval measured 60.0 FPS / 16.7 ms p95, with no >50 ms frames. The reading-anchor sampler was unavailable in this run, so no numeric reading-drift claim. Studio/model stopped; our GPU allocation released.

20-second refreshed live Studio demo

MP4 · GIF · Measurements

The fresh Codex review returned three additional comments; those are next to inspect. This media is commit-pinned evidence, not a blanket review clearance.

@oobabooga
oobabooga merged commit 5c63c8f into unslothai:main Sep 22, 2026
6 of 43 checks passed
danielhanchen added a commit to danielhanchen/unsloth-staging-2 that referenced this pull request Sep 22, 2026
…ettings driver (unslothai#11575)

* Keep scrolling to the end of the reasoning transcript in the thread settings driver

Chat UI Tests (extra) fails check_reasoning_transcript on every PR since unslothai#11522,
whose own Chat UI legs were cancelled before they ran. The driver sent one
100000 px wheel and waited for Step 0399. One wheel stops at the bottom of the
height estimated for passages not yet mounted, and measuring those it mounts
grows the transcript under it: locally the first wheel stopped at scrollTop
8468 of 15637 and the second reached the end, with the window still bounded.
CI's retries then waited on a window nothing was going to move.

Wheel until the last passage mounts, bounded at 12. The bounded-mount
assertion after it is unchanged.

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
shaojun pushed a commit to shaojun/unsloth that referenced this pull request Sep 29, 2026
…ettings driver (unslothai#11575)

* Keep scrolling to the end of the reasoning transcript in the thread settings driver

Chat UI Tests (extra) fails check_reasoning_transcript on every PR since unslothai#11522,
whose own Chat UI legs were cancelled before they ran. The driver sent one
100000 px wheel and waited for Step 0399. One wheel stops at the bottom of the
height estimated for passages not yet mounted, and measuring those it mounts
grows the transcript under it: locally the first wheel stopped at scrollTop
8468 of 15637 and the second reached the end, with the window still bounded.
CI's retries then waited on a window nothing was going to move.

Wheel until the last passage mounts, bounded at 12. The bounded-mount
assertion after it is unchanged.

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants