Hugging Face
Models
Datasets
Spaces
Posts
Docs
Enterprise
Pricing
Log In
Sign Up
Spaces:
palondomus
/
CaesarAI
like
0
Sleeping
App
Files
Files
Community
b2e71f3
CaesarAI
/
CaesarVoice.py
CaesarCloudSync
CaesarAI Deployed
9d3162f
over 1 year ago
raw
Copy download link
history
blame
Safe
216 Bytes
from
gtts
import
gTTS
import
os
class
CaesarVoice
:
@classmethod
def
synthesise
(
self,text,filename=
"temp.wav"
,lang=
'en'
):
caesargtts = gTTS(text=text, lang=lang)
caesargtts.save(
f"
{filename}
"
)