add english version

This commit is contained in:
samiabat 2025-04-29 01:11:23 +03:00
parent 367cebca33
commit 1089cfd2b5
8 changed files with 6 additions and 2 deletions

8
api.py
View File

@ -1103,8 +1103,12 @@ async def tts_endpoint(
sample_steps: int = 32, sample_steps: int = 32,
if_sr: bool = False if_sr: bool = False
): ):
refer_wav_path = f"idols/{character}/{character}.wav" if text_language == "en" and character == "saotome":
inp_refs = [f"idols/{character}/refs/{file}" for file in os.listdir(f"idols/{character}/refs") if file.endswith('.wav')] refer_wav_path = f"idols/{character}_eng/{character}.wav"
inp_refs = [f"idols/{character}_eng/refs/{file}" for file in os.listdir(f"idols/{character}_eng/refs") if file.endswith('.wav')]
else:
refer_wav_path = f"idols/{character}/{character}.wav"
inp_refs = [f"idols/{character}/refs/{file}" for file in os.listdir(f"idols/{character}/refs") if file.endswith('.wav')]
print(f"the base path is {refer_wav_path}") print(f"the base path is {refer_wav_path}")

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.