Documentation
¶
Overview ¶
Package ttswiring resolves a config.Config into the neutral tts.EnabledProviders input consumed by tts.BuildRouter. It is the single config→provider-options resolution path shared by the Device-Target (cmd/speechkit) and the Server-Target (internal/server/core), which previously each carried a near-identical copy.
Secret resolution and per-provider default policy live here; router assembly and model_selection pinning stay in tts.BuildRouter.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ResolveEnabledProviders ¶
func ResolveEnabledProviders(cfg *config.Config) (tts.EnabledProviders, []string)
ResolveEnabledProviders inspects cfg.TTS and returns the providers that are both enabled and have a usable credential/config, plus human-readable notes for the startup log (callers that don't log notes can ignore them).
Provider default policy is the union of what the two targets previously did, so neither regresses:
- OpenAI model: TTS.OpenAI.Model → Providers.OpenAI.TTSModel → "tts-1"
- OpenAI voice: TTS.OpenAI.Voice → Providers.OpenAI.TTSVoice → TTS.Voice → "nova"
- Google voice: TTS.Google.Voice → TTS.Voice → Google default
- HF model: TTS.HuggingFace.Model → Qwen3-TTS Base default
The OpenAI/Google literal defaults match the provider constructors, so they are equivalent to passing the empty string; they are spelled out here only so the returned notes carry the effective voice/model.
Types ¶
This section is empty.