Skip to content

Studio: make the rule closing a thinking trace readable - #11424

Merged
shimmyshimmer merged 1 commit into
mainfrom
studio/reasoning-rule-contrast
Sep 21, 2026
Merged

shimmyshimmer merged 1 commit into
mainfrom
studio/reasoning-rule-contrast

Conversation

@shimmyshimmer

Copy link
Copy Markdown
Member

The rule closing a thinking trace, just above the answer, was border-border/60. Measured against the real backgrounds by compositing it and reading the pixels back:

dark, on rgb(24,24,24) contrast light, on rgb(254,254,253) contrast
/60 (before) rgb(38,38,38), 14/255 1.173 rgb(235,240,237), 19/255 1.142
full (after) rgb(48,48,48), 24/255 1.345 rgb(223,231,227), 31/255 1.248

14 and 19 steps out of 255 is close enough to the background to read as an artefact rather than a divider, which is the whole job of the line.

Changes

Both places that draw it take the full token: ReasoningEndRule in reasoning.tsx, and the copy in tool-group.tsx that draws the same rule when tool calls are folded into Thinking. About 1.7x the separation in both modes, and the same --border every other border in the app already uses, so nothing new is introduced to keep in sync.

/80 was the other candidate and sits between the two, but it keeps the line off the token for no gain.

Testing

Compared /60, /80 and the full token side by side on bg-background in both themes against the built stylesheet, and the contrast figures above are read off a canvas rather than computed by hand. Typecheck clean, thinking-fold passes (22 tests). The stylesheet is byte-identical, since both utilities already existed; only the two class strings changed.

The line between the last trace and the answer was --border at 60%, which lands
14/255 off the dark background and 19/255 off the light one. It reads as an
artefact rather than a divider, in both modes.

Full --border in both places that draw it: 24/255 in dark and 31/255 in light,
about 1.7x the separation, and the same token every other border in the app
uses.
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Sep 21, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-09-21T07:03:00.043785Z 1e81de6 PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@shimmyshimmer
shimmyshimmer merged commit b69bcdf into main Sep 21, 2026
40 of 43 checks passed
@shimmyshimmer
shimmyshimmer deleted the studio/reasoning-rule-contrast branch September 21, 2026 07:29
shaojun pushed a commit to shaojun/unsloth that referenced this pull request Sep 29, 2026
)

The line between the last trace and the answer was --border at 60%, which lands
14/255 off the dark background and 19/255 off the light one. It reads as an
artefact rather than a divider, in both modes.

Full --border in both places that draw it: 24/255 in dark and 31/255 in light,
about 1.7x the separation, and the same token every other border in the app
uses.

Co-authored-by: Unsloth <[email protected]>
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.

1 participant