Spaces:
Sleeping
Sleeping
File size: 442 Bytes
95908f1 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 |
import gradio as gr
import os
import subprocess
# Chạy cài espeak-ng nếu chưa có
subprocess.run("apt update && apt install -y espeak-ng", shell=True)
def tts_lezgian(text):
os.system(f'espeak-ng -v lez "{text}" -w output.wav')
return "output.wav"
gr.Interface(fn=tts_lezgian,
inputs=gr.Textbox(label="Nhập văn bản tiếng Lezgian"),
outputs=gr.Audio(label="Giọng đọc Lezgian")).launch() |