Skip to content

feat(assemblyai): add universal-3-5-pro (now default) and Voice Focus streaming params#6119

Open
dlange-aai wants to merge 1 commit into
livekit:mainfrom
dlange-aai:feat/assemblyai-u3-5-pro-voice-focus
Open

feat(assemblyai): add universal-3-5-pro (now default) and Voice Focus streaming params#6119
dlange-aai wants to merge 1 commit into
livekit:mainfrom
dlange-aai:feat/assemblyai-u3-5-pro-voice-focus

Conversation

@dlange-aai

Copy link
Copy Markdown
Contributor

Summary

  • universal-3-5-pro: new streaming model, now the plugin default (was universal-streaming-english). It joins the u3-rt-pro parameter family, so it accepts the full u3-pro parameter set (prompt, agent_context, previous_context_n_turns, continuous_partials, interruption_delay) and inherits the family's connect-time defaults (continuous_partials=True, language_detection=True, punctuation-based turn detection).
  • voice_focus: new connect-time parameter (u3-rt-pro family only) — "near-field" for headsets/handsets/close-talking mics, "far-field" for conference rooms/laptop mics. Isolates the primary voice and suppresses background noise before audio reaches the model. See https://www.assemblyai.com/docs/streaming/voice-focus.
  • voice_focus_threshold: new connect-time parameter (u3-rt-pro family only) — float in [0.0, 1.0] controlling how aggressively background audio is suppressed.
  • Consolidated the per-parameter u3-rt-pro-family validation into a single loop so the ValueError lists the actual supported models (it previously named only u3-rt-pro, now misleading since universal-3-5-pro is the default).

Behavior change: because the default model is now a u3-rt-pro-family model, a bare STT() now defaults to continuous_partials=True, language_detection=True, and punctuation-based turn detection (min_turn_silence=100, max_turn_silence=min). Callers who relied on the previous universal-streaming-english default should set model="universal-streaming-english" explicitly.

Test Plan

  • uv run pytest --plugin assemblyai — 51 tests (default-model assertions, u3-rt-pro-family gating + acceptance across all family models, voice_focus/voice_focus_threshold plumbing, connect-config forwarding incl. voice_focus_threshold=0.0, update_options exclusion). 5 existing gating tests were updated to pin model="universal-streaming-english" since the default now joins the family.
  • ruff format + lint + mypy clean on touched files.

… params

Add universal-3-5-pro as a u3-rt-pro-family streaming model and make it the
plugin default. It inherits the full u3-rt-pro parameter set (prompt,
agent_context, previous_context_n_turns, continuous_partials,
interruption_delay) and the family connect-time defaults.

Add Voice Focus support via the voice_focus ("near-field" / "far-field") and
voice_focus_threshold connection parameters, gated to the u3-rt-pro family and
set at connect time only.

Consolidate the per-parameter u3-rt-pro-family validation into a single loop so
the error message lists the actual supported models (it previously named only
'u3-rt-pro', now misleading since universal-3-5-pro is the default).
@dlange-aai dlange-aai requested a review from a team as a code owner June 16, 2026 02:50

@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: No Issues Found

Devin Review analyzed this PR and found no bugs or issues to report.

Open in Devin Review

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.

1 participant