ttsroute

package
v0.48.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 28, 2026 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Overview

Package ttsroute holds the single source of truth that maps a Voice-Output profile ID (e.g. "tts.google.studio-o") to the provider name the TTS routers use internally (e.g. "google").

It is a zero-dependency leaf package so that both the framework kernel (internal/tts) and the public embeddable surface (pkg/speechkit/tts) can share one mapping without violating the OSS boundary (pkg/** must not import internal/*). Keep the prefixes in sync with the TTS catalog entries.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func PreferredProvider

func PreferredProvider(profileID string) string

PreferredProvider maps a Voice-Output profile ID to the provider name. It returns the empty string when the profile is unknown or unset — callers should treat that as "no preference, use default strategy ordering".

Mapping:

tts.openai.*                        → "openai"
tts.google.*                        → "google"
tts.deepgram.*                      → "deepgram"
tts.huggingface.*                   → "huggingface"
tts.openedai.* / tts.kokoro.*       → "kokoro"            (OpenAI-compatible self-hosted endpoint)
tts.local.kokoro*                   → "kokoro_local"      (ONNX in-process)
tts.local.supertonic*              → "supertonic_local"  (ONNX in-process, multilingual)
tts.local.chatterbox*              → "chatterbox_local"  (ONNX in-process, voice-clone)
tts.local.piper / tts.local.piper-* → "piper"             (Piper subprocess)

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL