Skip to content

fix(backends): clean host context from Claude session titles - #4022

Merged
schlessera merged 12 commits into
mainfrom
fix/3789-claude-session-title
Nov 15, 2026
Merged

schlessera merged 12 commits into
mainfrom
fix/3789-claude-session-title

Conversation

@schlessera

@schlessera schlessera commented Nov 15, 2026 •

Copy link
Copy Markdown
Owner

Closes #3789

What changed

Claude sessions without a custom title or SDK summary now display the user's first prompt without its complete trailing host-context block. New archives store the cleaned fallback, and existing archive titles are cleaned only when listed.

Why this shape

The shared internal helper lives beside the delimiter definitions and preserves unmatched opening text and original whitespace. Provider prompts and stored transcripts remain unchanged. Pi already takes the first line before the appended block, so it needs no change.

Proof

{"version":1,"kind":"brain-check-pr-receipt","head":"1a76037241a9429b8193e1ef37386611fdef760a","base":"origin/main","mode":"focused","startedAt":"2026-11-15T17:02:22.730Z","finishedAt":"2026-11-15T17:03:43.542Z","checks":[{"name":"all lint and leakage gates","categories":["changeset"],"outcome":"passed","elapsedMs":15478.836812000001},{"name":"environment documentation","categories":["changeset"],"outcome":"passed","elapsedMs":135.2996209999983},{"name":"pending changeset package names","categories":["changeset"],"outcome":"passed","elapsedMs":97.45734200000152},{"name":"contribution changeset","categories":["changeset"],"outcome":"passed","elapsedMs":24.451062000000093},{"name":"affected fast invariants","categories":["verify","unit"],"outcome":"passed","elapsedMs":65058.365203}]}

Checklist

  • Focused local preflight and failing-first/mutation receipts passed; complete selected hosted proof is required by integration confirmation.
  • Acceptance criteria are covered by live-list, new/archive-index/old-manifest and helper tests.
  • PR and issue target release 0.45.0, matching the assigned release commitment after 0.44.0.
  • A patch changeset is included.
  • No personal data in the diff; leakage gate passed.
  • No machine contract changed; the helper is internal.
  • Session context documentation reflects title display cleanup.
  • No fail-closed guard changed.
  • Provider bytes remain unchanged; the local provider-history probe was attempted and compared with the base failure.

Anything left open

Nothing in the implementation scope. Native runtime verification is subject to hosted post-merge proof under the repository's hybrid CI policy.

@schlessera schlessera added this to the 0.45.0 milestone Nov 15, 2026
@schlessera schlessera added type: fix Something is broken and must behave the way it is documented. area: ui-sdk Wire protocol, runtime schemas, the server and client SDK surfaces. area: backends AgentBackend implementations and the seam they share. labels Nov 15, 2026
@schlessera

Copy link
Copy Markdown
Owner Author

Collision check for head 2250f2a13795e914dc67ae450f9c77145e562253: closure overlap with #3054, #4022; closure overlap with #3056, #4022; closure overlap with #3059, #4022; closure overlap with #3069, #4022; closure overlap with #3116, #4022; closure overlap with #3437, #4022; closure overlap with #3581, #4022; closure overlap with #3622, #4022; closure overlap with #3806, #4022; closure overlap with #4002, #4022; closure overlap with #4008, #4022; closure overlap with #4012, #4022; closure overlap with #4013, #4022; closure overlap with #4016, #4022; closure overlap with #4018, #4022; closure overlap with #4020, #4022; closure overlap with #4021, #4022.
The cited-path check additionally identified #4018 on packages/ui-backend-claude/src/history.ts; its failure normalization changes are separate from this PR's title fallback. Reconcile and revalidate if that work lands first. Shared confirmation is currently held by #4020; this PR remains draft while waiting for the lease.

@schlessera

Copy link
Copy Markdown
Owner Author

Refreshed head d7ec61502ae9e5de8e65a244d6fcccc6aec6a138 merges main c6f98e8d9d2f63d144ff82d6d1d6ff0db128547c. The six base-change files are CI native-proof/logging support and do not overlap the title/helper/docs changes; the recorded local receipt retains its original tested identity. Current-head collision scan reports closure overlap with #3054, #3056, #3059, #3069, #3116, #3437, #3581, #3622, #3806, #4002, #4008, #4012, #4013, #4016, #4018, #4021. The separately assessed #4018 history normalization overlap remains distinct from title selection. No unknown collision report.

@schlessera

Copy link
Copy Markdown
Owner Author

Current head 7ffeb0535d79764c7599c56da5c8eb5f748d4391 merges main 3988a9bf9aab8c3730ca8e1228a63c169d17cab8 (#4016). Its eight policy-proposal/frontmatter files do not overlap this title fix; the original local receipt remains recorded at its actual tested identity. Current-head collision scan: closure overlap with #3054, #3056, #3059, #3069, #3116, #3437, #3581, #3622, #3806, #4002, #4008, #4012, #4013, #4018, #4021. No unknown report. #4018 remains the separately assessed history normalization neighbour. Shared lease is now held by #4013.

@schlessera

Copy link
Copy Markdown
Owner Author

Current head 298a3b1ed255b7236389111bcf961f2eec8eacd0 merges main 7e36fdc899408b12bb3774902a09a09c3eab146a (#4013). Its twelve CI incident/timing-reporting files do not overlap the title fix; the retained local receipt keeps its original tested identity. Current-head collision scan: closure overlap with #3054, #3056, #3059, #3069, #3116, #3437, #3581, #3622, #3806, #4002, #4008, #4012, #4018, #4021, #4023. No unknown report. #4018 is still the separately assessed history normalization neighbour. The shared lease is currently held by #4012.

@schlessera

Copy link
Copy Markdown
Owner Author

Current head 91130d0f8 merges main 388feb483751e8a7550f908de6f0a518eda03117 (#4012). Its thirteen observation timing/journal files do not overlap this display-only title change; the retained local receipt keeps its original tested identity. Current-head collision scan: closure overlap with #3054, #3056, #3059, #3069, #3116, #3437, #3581, #3622, #3806, #4002, #4008, #4018, #4021, #4023. No unknown report. The #4018 history normalization neighbour remains separately assessed. The lease was acquired by #4023 before this confirmation attempt.

@schlessera

Copy link
Copy Markdown
Owner Author

Current head 1a76037241a9429b8193e1ef37386611fdef760a merges main 4035f977e0cc471a5fbe795f447237c15890d3dd (#4023). The archive overlap merged cleanly; focused tests pass (32 tests, 123 assertions), and a fresh check:pr passed with its replacement receipt in the body. Current-head collision scan: closure overlap with #3054, #3056, #3059, #3069, #3116, #3437, #3581, #3622, #3806, #4002, #4008, #4018, #4021, #4024, #4025. No unknown report. #4018 remains the separately assessed history normalization neighbour. Shared lease is held by #4021.

@schlessera

Copy link
Copy Markdown
Owner Author

Current head 5b58cf4329eae744eebc4fd86baf2baea54baab0 merges main 23d6af880 (#4027), the declared fix for red-main incident #4026. Its three Apify CLI/test/changeset files do not overlap the title fix; the most recent local receipt remains recorded at its actual tested head 1a7603724. Current-head collision scan: closure overlap with #3054, #3056, #3059, #3069, #3116, #3437, #3581, #3622, #3806, #4002, #4008, #4018, #4021, #4024, #4025, #4028. No unknown report. #4018 remains the separately assessed history normalization neighbour. Confirmation is paused until the incident recovery main run clears the record.

@schlessera

Copy link
Copy Markdown
Owner Author

Current head ea983492a2d01a7e6d29310b3e118a95635048ce merges main eb3c53ac2 (#4025). Its ten file-scope/journal files do not overlap the title fix; the most recent local receipt retains its actual tested identity. Current-head collision scan: closure overlap with #3054, #3056, #3059, #3069, #3116, #3437, #3581, #3622, #3806, #4002, #4008, #4018, #4021, #4024, #4028, #4030. No unknown report. The #4018 history normalization overlap remains separately assessed. Main recovered from #4026 through #4027 and run 43745190044.

@schlessera

Copy link
Copy Markdown
Owner Author

Current head ae8727ad5788c54ac80c3b2508872ebe0155a263 merges main ed4eb5a0c (#4021). Its seven worker-tool configuration/test files do not overlap the display-only title fix; the most recent local receipt retains its actual tested identity. Current-head collision scan: closure overlap with #3054, #3056, #3059, #3069, #3116, #3437, #3581, #3622, #3806, #4002, #4008, #4018, #4024, #4028, #4030, #4032. No unknown report. #4018 remains the separately assessed history normalization neighbour.

@schlessera

Copy link
Copy Markdown
Owner Author

Refreshed head 94d1f686b2f7b6a773d64e3b6ec65a8be9e060e0 merges main 2702e2bdd (#4030). The only added base files are scripts/native-proof/Dockerfile and tests/native-prerequisites.test.ts, which do not overlap or alter the title/helper diff. Retaining the preflight receipt at its actual tested head and the collision assessment recorded for ae8727ad5788c54ac80c3b2508872ebe0155a263; the title-fix paths and patch are unchanged by this base refresh. The recorded #4018 history normalization overlap is still separate from title selection.

@schlessera

Copy link
Copy Markdown
Owner Author

Refreshed head 31338c7631beddda3fa1f2363e2412e907b1d77e merges main e1ce188d7 (#4008). The 27 module-repository files do not overlap the title/helper diff. Retaining the preflight receipt at its actual tested head and the recorded collision assessment for ae8727ad5788c54ac80c3b2508872ebe0155a263; the title-fix paths and patch are unchanged by this base refresh. #4018 remains the separately assessed history normalization neighbour.

@schlessera

Copy link
Copy Markdown
Owner Author

Candidate confirmation passed on run 43758006657, head 31338c7631beddda3fa1f2363e2412e907b1d77e, base e1ce188d79dd47c88a4478359d38277098444a21, merge checkout e5665b8607fb07a8ca1030d35d14ec127b59454b, tree 5221359a249376353f6fd4939f4076596517c87f.

Squash a9bcdbd6734c1733390570e2a68c10afde3b00a9 is on remote main. Its parent is the recorded candidate base and its tree exactly matches the tested merge checkout. #3789 is closed; the issue and PR both retain milestone 0.45.0. Automatic main push run 43760470794 is in progress; complete main proof is not yet claimed.

@schlessera

Copy link
Copy Markdown
Owner Author

Automatic main push run 43760470794 passed at squash a9bcdbd6734c1733390570e2a68c10afde3b00a9. All 17 jobs passed, including verification, packed consumers, four unit shards, runtime, host runtime, three browser shards, two layout shards, captures, endurance, and the final proof aggregate.

Read each of the 16 executing jobs' checkout logs: every git log -1 --format=%H observation is the squash SHA above. Job receipts:

  • changeset: 132953906545 — success, checkout matches squash
  • verify: 132954226584 — success, checkout matches squash
  • pack: 132954226586 — success, checkout matches squash
  • runtime: 132954226592 — success, checkout matches squash
  • runtime_host: 132954226595 — success, checkout matches squash
  • layout (1): 132954226636 — success, checkout matches squash
  • unit (3): 132954226641 — success, checkout matches squash
  • endurance: 132954226642 — success, checkout matches squash
  • browser (2): 132954226671 — success, checkout matches squash
  • unit (2): 132954226681 — success, checkout matches squash
  • browser (1): 132954226686 — success, checkout matches squash
  • unit (1): 132954226692 — success, checkout matches squash
  • browser (3): 132954226713 — success, checkout matches squash
  • layout (2): 132954226723 — success, checkout matches squash
  • captures: 132954226755 — success, checkout matches squash
  • unit (4): 132954226895 — success, checkout matches squash
  • integrated or exhaustive proof: 132960252045 — success (aggregate)

The squash parent/tree match candidate proof as recorded above. #3789 is closed, both issue and PR retain milestone 0.45.0, and the closed issue assignment remains as claim history. No follow-up issue was filed for this change.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area: backends AgentBackend implementations and the seam they share. area: ui-sdk Wire protocol, runtime schemas, the server and client SDK surfaces. type: fix Something is broken and must behave the way it is documented.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

backends: a Claude session titled from its first prompt shows the appended host-context block

1 participant