Files
hapi/cli/src
01da312458 fix(claude): use native ai-title for remote session titles (#2207)
* fix(claude): use native ai-title for remote session titles

Remote mode talks to Claude over the SDK stream, which never carries the
ai-title Claude Code writes to its transcript, so the first-result fallback
titled the session from the formatted prompt. With an attachment that prompt
starts with "@/tmp/hapi-blobs/..." and the 80-char cut left only the path.

On the first result, read the latest ai-title from the transcript; fall back
to the first prompt as typed, without attachment @paths.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* fix(claude): derive fallback title from the delivered prompt

Recording the first enqueued text could title the session from a prompt
that was cancelled or edited before delivery. Strip the upload @path
references from the prompt actually delivered instead; upload filenames
have whitespace replaced, so each reference is a single token.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-28 11:01:57 +08:00
..
2025-12-16 15:03:50 +08:00