Skip to content

[Widget] Show first message in text mode for Text & Voice agents - #970

Merged
giannagerton merged 2 commits into
mainfrom
gianna/widget-text-mode-first-message
Aug 21, 2026
Merged

[Widget] Show first message in text mode for Text & Voice agents#970
giannagerton merged 2 commits into
mainfrom
gianna/widget-text-mode-first-message

Conversation

@giannagerton

@giannagerton giannagerton commented Aug 20, 2026

Copy link
Copy Markdown
Contributor

Summary

Fixes ACF-55
Slack thread

conversation.tsx drops the first message for any text conversation that has a first_message configured, since it arrives after the user's opening message and would render out of order. Sheet compensated by rendering it locally — but only for agents configured text-only, so Text & Voice agents got neither copy.

Sheet now renders the local copy for any agent that supports text mode and has the text input enabled: as a preview before connecting, and through a text conversation. Voice conversations are untouched.

Behavior (text input turned on, transcript off)

Before no first message when opening the widget via the chat button
before-first-message

After first message shows, ability to switch to voice
after

@cursor

cursor Bot commented Aug 20, 2026

Copy link
Copy Markdown
Contributor

PR Summary

Low Risk
UI-only transcript preview logic in the widget sheet; no auth, session, or server protocol changes. Layout of the open-but-disconnected sheet shifts because the transcript is no longer empty.

Overview
Text & Voice agents now show the locally rendered welcome message in text mode (preview and chat), not only text-only widgets. The server first message is still dropped in text conversations because it arrives after the user’s opener; voice calls keep the server copy so it is never duplicated.

The local copy also shows first-message rich content (e.g. greeting buttons) and strips TTS audio tags when strip_audio_tags is on. Opening the disconnected sheet with a greeting now has a non-empty transcript, so the compact layout (corner avatar, call button in the action row, resize) appears immediately.

Reviewed by Cursor Bugbot for commit 3d81426. Bugbot is set up for automated code reviews on this repo. Configure here.

@giannagerton
giannagerton force-pushed the gianna/widget-text-mode-first-message branch from 4d615ee to d933657 Compare August 20, 2026 20:03

@cursor cursor Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes using default effort and found 1 potential issue.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, have a team admin enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit d933657. Configure here.

Comment thread packages/convai-widget-core/src/widget/Sheet.tsx
@giannagerton
giannagerton force-pushed the gianna/widget-text-mode-first-message branch 3 times, most recently from 87b04e4 to ea67b9b Compare August 20, 2026 21:22

@kamilk-11 kamilk-11 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice!

Comment thread packages/convai-widget-core/src/widget/Sheet.tsx Outdated
Gianna Gerton and others added 2 commits August 21, 2026 11:01
@giannagerton
giannagerton force-pushed the gianna/widget-text-mode-first-message branch from 28f29eb to 3d81426 Compare August 21, 2026 15:01
@giannagerton
giannagerton merged commit ba87df2 into main Aug 21, 2026
5 checks passed
@giannagerton
giannagerton deleted the gianna/widget-text-mode-first-message branch August 21, 2026 15:06
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.

3 participants