Skip to content

feat(expressive): expose expressive mode and add expressive_agent example - #6698

Merged
tinalenguyen merged 15 commits into
mainfrom
theo/expose-expressive-mode
Aug 7, 2026
Merged

feat(expressive): expose expressive mode and add expressive_agent example#6698
tinalenguyen merged 15 commits into
mainfrom
theo/expose-expressive-mode

Conversation

@theomonnom

Copy link
Copy Markdown
Member

No description provided.

@theomonnom
theomonnom requested a review from a team as a code owner August 4, 2026 20:53
@CLAassistant

CLAassistant commented Aug 4, 2026

Copy link
Copy Markdown

CLA assistant check
All committers have signed the CLA.

devin-ai-integration[bot]

This comment was marked as resolved.

@theomonnom
theomonnom force-pushed the theo/expose-expressive-mode branch 2 times, most recently from 0b0c069 to 1e8e69c Compare August 4, 2026 21:59
@theomonnom
theomonnom force-pushed the theo/expose-expressive-mode branch from 1e8e69c to 3937959 Compare August 4, 2026 22:17
@theomonnom
theomonnom force-pushed the theo/expose-expressive-mode branch 4 times, most recently from 52f7dff to cafd3ef Compare August 5, 2026 00:03
@theomonnom
theomonnom force-pushed the theo/expose-expressive-mode branch from cafd3ef to 866399f Compare August 5, 2026 00:10
@theomonnom
theomonnom force-pushed the theo/expose-expressive-mode branch from 4b64172 to a41675a Compare August 5, 2026 04:11
devin-ai-integration[bot]

This comment was marked as resolved.

@theomonnom
theomonnom force-pushed the theo/expose-expressive-mode branch from 777a7c2 to d06ec89 Compare August 5, 2026 18:58
theomonnom and others added 4 commits August 5, 2026 18:01
…the persona

The delivery guide teaches contractions, but it is injected only when
expressive mode is on — so an `expressive=False` run, which is half the
demo's comparison, lost the guidance entirely and read stiffer for a
reason unrelated to delivery. Word choice belongs to the persona; tone
and pacing stay in the guide.
…e-mode

Conflicted only on the _provider_format import block: this branch added
`_mood.match_mood` while main expanded the markup_utils import for the
tag-stripping space fix (#6717). Both are additive, so the resolution is
the union.

@devin-ai-integration devin-ai-integration 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.

Devin Review found 1 new potential issue.

View 3 additional findings in Devin Review.

Open in Devin Review

Comment on lines +952 to +953
payload = {"expression": expression, "mood": match_mood(expression)}
return {ATTRIBUTE_TRANSCRIPTION_EXPRESSION: json.dumps(payload, separators=(",", ":"))}

@devin-ai-integration devin-ai-integration Bot Aug 6, 2026

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.

🟡 Frontends reading the agent's mood label stop working after this change

The published delivery-label payload is rewritten to a new shape (json.dumps(payload...) at livekit-agents/livekit/agents/tts/_provider_format.py:952-953), dropping the previously published key, so any app already reading the old key sees nothing.
Impact: Existing clients that display the agent's emotion lose it silently after upgrading.

Wire-format change of the lk.expression transcription attribute

expression_attribute() previously emitted {"value": "<label>"} under the lk.expression attribute (livekit-agents/livekit/agents/types.py:11). It now emits {"expression": "<label>", "mood": "<normalized>"}. Any client SDK/frontend parsing payload["value"] gets a KeyError/undefined. The attribute is published on both the opening (livekit-agents/livekit/agents/voice/room_io/_output.py:499-501) and closing (:557) transcription stream headers. If backward compatibility matters, keeping value alongside the two new keys would be a non-breaking superset.

Open in Devin Review

Was this helpful? React with 👍 or 👎 to provide feedback.

Emotions grow 9 -> 19 and sounds 3 -> 8 (with steering governance and
alias salvage), every emotion mapping to a non-fallback mood so
lk.expression stays meaningful. Fish's tone controls (whispering, soft,
shouting, hurried) land as wrapping prosody that lowers to its native
prefix markers. All labels from the documented Fish s2 vocabulary.
devin-ai-integration[bot]

This comment was marked as resolved.

@tinalenguyen
tinalenguyen merged commit 404a3b7 into main Aug 7, 2026
23 of 24 checks passed
@tinalenguyen
tinalenguyen deleted the theo/expose-expressive-mode branch August 7, 2026 22:20
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