From d2df324f298a02c71892cfdff16a5370081f2b17 Mon Sep 17 00:00:00 2001 From: Mike Seese Date: Mon, 5 Jan 2026 11:49:52 -0800 Subject: [PATCH] fix some bugs after testing changes --- src/pipecat/services/hathora/stt.py | 10 +++++----- src/pipecat/services/hathora/tts.py | 12 ++++++------ 2 files changed, 11 insertions(+), 11 deletions(-) diff --git a/src/pipecat/services/hathora/stt.py b/src/pipecat/services/hathora/stt.py index 3f3dee6f7..0608cb39e 100644 --- a/src/pipecat/services/hathora/stt.py +++ b/src/pipecat/services/hathora/stt.py @@ -37,14 +37,14 @@ class HathoraSTTService(SegmentedSTTService): Parameters: language: Language code (if supported by model). - model_config: Some models support additional config, refer to + config: Some models support additional config, refer to [docs](https://models.hathora.dev) for each model to see what is supported. base_url: Base API URL for the Hathora STT service. """ language: Optional[str] = None - model_config: Optional[list[ConfigOption]] = None + config: Optional[list[ConfigOption]] = None base_url: str = "https://api.models.hathora.dev/inference/v1/stt", def __init__( @@ -76,7 +76,7 @@ class HathoraSTTService(SegmentedSTTService): self._settings = { "language": params.language, - "model_config": params.model_config, + "config": params.config, } self.set_model_name(model) @@ -117,9 +117,9 @@ class HathoraSTTService(SegmentedSTTService): if self._settings["language"] is not None: payload["language"] = self._settings["language"] - if self._settings["model_config"] is not None: + if self._settings["config"] is not None: payload["model_config"] = [ - {"name": option.name, "value": option.value} for option in self._settings["model_config"] + {"name": option.name, "value": option.value} for option in self._settings["config"] ] base64_audio = base64.b64encode(audio).decode("utf-8") diff --git a/src/pipecat/services/hathora/tts.py b/src/pipecat/services/hathora/tts.py index efc412d07..749cb46c8 100644 --- a/src/pipecat/services/hathora/tts.py +++ b/src/pipecat/services/hathora/tts.py @@ -56,14 +56,14 @@ class HathoraTTSService(TTSService): Parameters: speed: Speech speed multiplier (if supported by model). - model_config: Some models support additional config, refer to + config: Some models support additional config, refer to [docs](https://models.hathora.dev) for each model to see what is supported. base_url: Base API URL for the Hathora TTS service. """ speed: Optional[float] = None - model_config: Optional[list[ConfigOption]] = None + config: Optional[list[ConfigOption]] = None base_url: str = "https://api.models.hathora.dev/inference/v1/tts", def __init__( @@ -97,7 +97,7 @@ class HathoraTTSService(TTSService): self._settings = { "speed": params.speed, - "model_config": params.model_config, + "config": params.config, } self.set_model_name(model) @@ -125,7 +125,7 @@ class HathoraTTSService(TTSService): await self.start_processing_metrics() await self.start_ttfb_metrics() - url = f"{self.base_url}" + url = f"{self._base_url}" payload = {"model": self._model, "text": text} @@ -133,9 +133,9 @@ class HathoraTTSService(TTSService): payload["voice"] = self._voice_id if self._settings["speed"] is not None: payload["speed"] = self._settings["speed"] - if self._settings["model_config"] is not None: + if self._settings["config"] is not None: payload["model_config"] = [ - {"name": option.name, "value": option.value} for option in self._settings["model_config"] + {"name": option.name, "value": option.value} for option in self._settings["config"] ] yield TTSStartedFrame()