Spaces:
Running
Running
Update voice.py
Browse files
voice.py
CHANGED
|
@@ -1,7 +1,6 @@
|
|
| 1 |
import edge_tts
|
| 2 |
import tempfile
|
| 3 |
import os
|
| 4 |
-
import traceback
|
| 5 |
|
| 6 |
# Use Microsoft Edge TTS - High quality neural voices
|
| 7 |
# Includes sexy, hot female voices with various accents
|
|
@@ -33,6 +32,7 @@ async def generate_audio(text: str, voice: str) -> str:
|
|
| 33 |
from huggingface_hub import InferenceClient
|
| 34 |
from dotenv import load_dotenv
|
| 35 |
from pathlib import Path
|
|
|
|
| 36 |
|
| 37 |
# Load env vars
|
| 38 |
env_path = Path(__file__).parent / '.env'
|
|
@@ -93,7 +93,33 @@ async def generate_audio(text: str, voice: str) -> str:
|
|
| 93 |
raise e
|
| 94 |
|
| 95 |
def get_voices():
|
| 96 |
-
|
|
|
|
|
|
|
|
|
|
| 97 |
return [
|
| 98 |
-
#
|
| 99 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
import edge_tts
|
| 2 |
import tempfile
|
| 3 |
import os
|
|
|
|
| 4 |
|
| 5 |
# Use Microsoft Edge TTS - High quality neural voices
|
| 6 |
# Includes sexy, hot female voices with various accents
|
|
|
|
| 32 |
from huggingface_hub import InferenceClient
|
| 33 |
from dotenv import load_dotenv
|
| 34 |
from pathlib import Path
|
| 35 |
+
import traceback
|
| 36 |
|
| 37 |
# Load env vars
|
| 38 |
env_path = Path(__file__).parent / '.env'
|
|
|
|
| 93 |
raise e
|
| 94 |
|
| 95 |
def get_voices():
|
| 96 |
+
"""
|
| 97 |
+
Return curated list of sexy, hot female voices
|
| 98 |
+
Featuring Microsoft's best neural voices with various styles
|
| 99 |
+
"""
|
| 100 |
return [
|
| 101 |
+
# ๐ฅ HOTTEST FEMALE VOICES - Sexy & Sultry ๐ฅ
|
| 102 |
+
{"name": "๐ Aria (Sexy US) - HOTTEST", "id": "en-US-AriaNeural"},
|
| 103 |
+
{"name": "๐ Jenny (Seductive US)", "id": "en-US-JennyNeural"},
|
| 104 |
+
{"name": "โจ Michelle (Flirty US)", "id": "en-US-MichelleNeural"},
|
| 105 |
+
{"name": "๐น Ashley (Sweet US)", "id": "en-US-AshleyNeural"},
|
| 106 |
+
{"name": "๐ Sara (Warm US)", "id": "en-US-SaraNeural"},
|
| 107 |
+
|
| 108 |
+
# ๐ฌ๐ง British Accent - Elegant & Sophisticated
|
| 109 |
+
{"name": "๐ Sonia (Sexy British)", "id": "en-GB-SoniaNeural"},
|
| 110 |
+
{"name": "๐ Libby (Cute British)", "id": "en-GB-LibbyNeural"},
|
| 111 |
+
{"name": "๐ Mia (Sweet British)", "id": "en-GB-MiaNeural"},
|
| 112 |
+
|
| 113 |
+
# ๐ฆ๐บ Australian Accent - Fun & Playful
|
| 114 |
+
{"name": "๐ด Natasha (Aussie Babe)", "id": "en-AU-NatashaNeural"},
|
| 115 |
+
{"name": "โ๏ธ Freya (Aussie Darling)", "id": "en-AU-FreyaNeural"},
|
| 116 |
+
|
| 117 |
+
# ๐ฎ๐ณ Indian Accent - Exotic & Beautiful
|
| 118 |
+
{"name": "๐บ Neerja (Indian Beauty)", "id": "en-IN-NeerjaNeural"},
|
| 119 |
+
|
| 120 |
+
# ๐จ๐ฆ Canadian - Friendly & Approachable
|
| 121 |
+
{"name": "๐ Clara (Canadian Cutie)", "id": "en-CA-ClaraNeural"},
|
| 122 |
+
|
| 123 |
+
# ๐ฎ๐ช Irish Accent - Charming
|
| 124 |
+
{"name": "โ๏ธ Emily (Irish Charm)", "id": "en-IE-EmilyNeural"},
|
| 125 |
+
]
|