style: Format code for consistency and readability across TTS modules

This commit is contained in:
JSC
2025-09-21 18:05:20 +02:00
parent 50eeae4c62
commit d3b6e90262
11 changed files with 36 additions and 27 deletions

View File

@@ -2,4 +2,4 @@
from .gtts import GTTSProvider
__all__ = ["GTTSProvider"]
__all__ = ["GTTSProvider"]

View File

@@ -31,6 +31,7 @@ class GTTSProvider(TTSProvider):
Returns:
MP3 audio data as bytes
"""
lang = options.get("lang", "en")
tld = options.get("tld", "com")
@@ -60,7 +61,7 @@ class GTTSProvider(TTSProvider):
"lv", "mk", "ml", "mr", "ms", "mt", "my", "ne", "nl", "no", "pa",
"pl", "pt", "pt-br", "pt-pt", "ro", "ru", "si", "sk", "sl", "sq",
"sr", "su", "sv", "sw", "ta", "te", "th", "tl", "tr", "uk", "ur",
"vi", "yo", "zh", "zh-cn", "zh-tw", "zu"
"vi", "yo", "zh", "zh-cn", "zh-tw", "zu",
]
def get_option_schema(self) -> dict[str, Any]:
@@ -70,11 +71,11 @@ class GTTSProvider(TTSProvider):
"type": "string",
"default": "en",
"description": "Language code",
"enum": self.get_supported_languages()
"enum": self.get_supported_languages(),
},
"slow": {
"type": "boolean",
"default": False,
"description": "Speak slowly"
}
}
"description": "Speak slowly",
},
}