MCPcopy Create free account
hub / github.com/OpenMOSS/MOSS-TTS / _resolve_reference_audio_path

Function _resolve_reference_audio_path

clis/moss_tts_app.py:80–87  ·  view source on GitHub ↗
(language: str, index: int)

Source from the content-addressed store, hash-verified

78
79
80def _resolve_reference_audio_path(language: str, index: int) -> Path | None:
81 stem_candidates = [f"reference_{language}_{index}"]
82 for stem in stem_candidates:
83 for ext in (".wav", ".mp3"):
84 audio_path = REFERENCE_AUDIO_DIR / f"{stem}{ext}"
85 if audio_path.exists():
86 return audio_path
87 return None
88
89
90def build_example_rows() -> list[tuple[str, str, str]]:

Callers 1

build_example_rowsFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected