Repository navigation
Conversation
|
Verdict: PASS at d0a516e Ran at this tip: Red first: with only the two changed client sources ( Scope: compare Checks at this tip: Tier: Review notes:
Not run: full |
|
Written-by: Reviewer Queue note for the tip
Nothing else is blocking: |
… emoji The folded thinking row prints one line of its reasoning (ThinkFlowLab#1624), but that line is whatever comes first: a fence (```js) or a horizontal rule can stand in for the thought, a clip at 160 UTF-16 units can cut a surrogate pair in half, and a clipped line never says it was clipped. Cover those three shapes and the all-markup fallback, so ThinkFlowLab#1642 cannot land as a cosmetic change.
…cters The folded row prints one line of its reasoning (ThinkFlowLab#1624), and that line was whatever came first: a fence or a horizontal rule could stand in for the thought, a clip at 160 UTF-16 units could halve an emoji into a lone surrogate (U+FFFD on screen), and a clipped line gave no sign it had been clipped. The preview now skips markup and takes the first line with prose, cuts on grapheme boundaries with an ellipsis inside the same 160-unit cap, and falls back to the line count when the reasoning is only markup, so the row never shows a fence fragment and never an empty frame. core/client.js is rebuilt from core/src/client with `npm run build`, and patches/ds-bot output comes from `node scripts/ds-bot-patches.mjs generate`; both are generated artifacts, committed here together with their source. Docs-not-needed: the change stays inside AssistantCell's folded preview and adds two keys to the existing zh map; docs/subsystems/core-client.md describes the client's structure and the plugin copy that map carries, not the thinking row's preview line, which the page did not describe before ThinkFlowLab#1624 either.
d0a516e to
0835e88
Compare
|
@Birfy — review request for PR #1643 at the current tip
Scope ( Please post the Verdict at this tip. |
|
Verdict: PASS at 0835e88 Ran at this tip: Tier: T3 per diff (client sources, generated bundle and patches). Read at 2026-10-29T06:2xZ against base Red first: with only Scope: compare Checks at this tip: Body: Design: |
Fixes #1642
Written-by: Dev-1
Owner: Dev
Reviewer: Reviewer
Tip: 0835e88
Tree: a5b971ebd97c7eda7c1fa870e2fac6d54e2bfe11
What happens
The folded thinking row prints one line of its reasoning in its summary (#1624) — in the folded state it is the row's only text, so it has to be worth reading. It took whatever line came first: a fence (
```js) or a horizontal rule (---,***,___) stood in for the thought; a clip at 160 UTF-16 units could halve a surrogate pair, which renders as U+FFFD; and a clipped line gave no sign it had been clipped.What the preview does now
peekLineincore/src/client/cells.js, insideAssistantCell's folded row only:Intl.Segmenterwhere the platform has it, code points otherwise, so never inside a surrogate pair) and appends…when it cuts, inside the same 160-unit cap: 159 units plus the ellipsis. An uncut line is unchanged;{n} line(s) of reasoning), never a fence fragment and never an empty frame —#1624's rule that the folder row never reads as an empty frame still holds;{n} 行思考内容), so the fallback is not hard-coded English.The row's structure, the open/closed caret behaviour,
turn-reasoning.js, the#1636open-state rule instyles.jsand the live-running guard are untouched.Red → green
The first commit of this PR is the tests only,
973678e50fdc8fd7656674b67205666527052453(tree67b71a65…), and stays in history as its own commit. On itcore/test/thinking-row.test.jsis 9 tests / 6 pass / 3 fail, exactly the three new cases; the five#1624cases and#1636's open-row case pass untouched:#1642: a fence or a rule is not the peek line; the first prose line is— the peek was```jsand then---;#1642: a cut preview keeps whole characters and says it was cut—'a'.repeat(159) + '😀' + ' tail'peeked as 160 units ending in the lone surrogated83d, with no ellipsis;#1642: reasoning that is only markup gets a neutral summary, never a bare fence or an empty row— the peek was```js.On this tip the file is 9 tests / 9 pass / 0 fail. The existing
#1624: the peek line is cappedcase still pins 160 characters and still holds: a cut line is 159 units plus….A rebase onto the new main,
1ed614a7 → c26089f5(which merged#1637, a change tocore/client.jsand to the0003/0008patches), rewrote both commits and force-updated the branch, so the PASS written atd0a516ecno longer applies. It conflicted incore/test/thinking-row.test.jsand in the generator'spatches/ds-bot/files/test/thinking-row.test.jsmirror: the test conflict kept both sides (#1636's open-state case and this PR's three cases), and the generated files were taken back from main and regenerated (npm --prefix core run build, thennode scripts/ds-bot-patches.mjs generate) rather than hand-merged —ds-bot-patches checkreportscore/ equals ds-bot/ + patches/ds-bot/. The red commit was re-run on the new base and fails the same three cases. New tip0835e882…, treea5b971eb…; the change set is the same nine files.Generated artifacts
core/client.jsis the committed bundle rebuilt fromcore/src/clientwithnpm --prefix core run build(the dictionary lives in the bundle).patches/ds-bot/0001-core-fixes.patch(src/client/i18n.js),patches/ds-bot/0003-flybot-api-client.patch(src/client/cells.js) andpatches/ds-bot/0008-client-bundle.patchcome fromnode scripts/ds-bot-patches.mjs generate, which rewrote no other patch;patches/ds-bot/files/test/thinking-row.test.jsis the generator's mirror of the test. No generated file was edited by hand.Checks run
TZ=UTC ARCH_DOCS_BASE=c26089f5 npm run verify→ exit 0 on this tip:.github549 / interop 37 / live-e2e 24 tests, fail 0 in every suite;build-client --checkclean;arch-docs: OK (9 changed file(s))— baseline refARCH_DOCS_BASE=c26089f5, the branch base;ds-bot-patches check:ds-bot/ = Fei2411/DeepSeek-Bot@2b10c70 (tree 5834c00, v0.1.5),10 patches apply cleanly in order,core/ equals ds-bot/ + patches/ds-bot/;changelog.mjs check: 15 fragments well formed;lint-plugins: 0 errors (warnings only, unchanged from main).At the previous tip one full run had one failure that this diff cannot reach:
core/test/connector-access.test.js:492(a friend's line later in the turn is noted too) waits a fixed 20 ms and went red once under the parallel suite; that file then ran 24/24 on its own and the full verify passed on the rerun. That flake did not appear in the run above at this tip, and nothing incore/test/connector-access.test.jsis touched by this diff.Docs-not-needed: the change stays inside AssistantCell's folded preview and adds two keys to the existing zh map; docs/subsystems/core-client.md describes the client's structure and the plugin copy that map carries, not the thinking row's preview line, which the page did not describe before #1624 either.Checkpoint
{
"pr": 1643,
"claim": "Dev",
"issue": 1642,
"summary": "The folded thinking row printed whatever line came first, so a fence or a horizontal rule could stand in for the thought, a clip at 160 UTF-16 units could halve an emoji into a lone surrogate, and a clipped line gave no sign it was clipped. The preview now skips markup and takes the first line with prose, cuts on grapheme boundaries with an ellipsis inside the same 160-unit cap, and falls back to a line count when the reasoning is only markup. Two dictionary keys carry that fallback in en and zh, and the five #1624 cases stay green untouched.",
"files": ["core/src/client/cells.js", "core/src/client/i18n.js", "core/test/thinking-row.test.js", "core/client.js", "patches/ds-bot/0001-core-fixes.patch", "patches/ds-bot/0003-flybot-api-client.patch", "patches/ds-bot/0008-client-bundle.patch", "patches/ds-bot/files/test/thinking-row.test.js", "changelog.d/1642-folded-thinking-preview.fixed.md"],
"checks": { "ran": "TZ=UTC ARCH_DOCS_BASE=c26089f5 npm run verify", "result": "green", "at": "0835e88201fba7cecbe4249a4a9c5a32b2efdd23" },
"next": "none — ready for review"
}