Skip to content

Conversation

@iancarrasco-b10
Copy link

@iancarrasco-b10 iancarrasco-b10 commented Feb 6, 2026

Summary

  • Adds a SynthesizeStream class implementing the BaseTen WebSocket protocol for real-time streaming TTS (word-by-word text input, binary PCM audio output)
  • New ws_url parameter (or BASETEN_WS_URL env var) enables streaming; existing HTTP model_endpoint path is fully preserved
  • Streaming capability is auto-detected: capabilities.streaming=True when ws_url is provided, False otherwise

Test plan

  • Verify existing HTTP synthesis still works with only model_endpoint set
  • Test WebSocket streaming with a BaseTen model that supports the WS protocol (e.g. Orpheus)
  • Confirm stream() raises a clear error when ws_url is not configured
  • Confirm synthesize() raises a clear error when model_endpoint is not configured

🤖 Generated with Claude Code


Open with Devin

Implements SynthesizeStream using the BaseTen WebSocket protocol
(word-by-word text input, binary PCM audio output) to enable
real-time streaming TTS. The existing HTTP ChunkedStream path is
preserved for non-streaming use. Streaming is auto-enabled when
a ws_url is provided.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@CLAassistant
Copy link

CLAassistant commented Feb 6, 2026

CLA assistant check
All committers have signed the CLA.

Copy link
Contributor

@devin-ai-integration devin-ai-integration bot left a comment

Choose a reason for hiding this comment

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

Devin Review found 1 potential issue.

View 4 additional findings in Devin Review.

Open in Devin Review

…n/tts.py

Co-authored-by: devin-ai-integration[bot] <158243242+devin-ai-integration[bot]@users.noreply.github.com>
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.

2 participants