|
|
@ -35,9 +35,9 @@ class StreamlabsPolly:
|
|
|
|
if random_voice:
|
|
|
|
if random_voice:
|
|
|
|
voice = self.randomvoice()
|
|
|
|
voice = self.randomvoice()
|
|
|
|
else:
|
|
|
|
else:
|
|
|
|
if not os.getenv("VOICE"):
|
|
|
|
if not os.getenv("STREAMLABS_VOICE"):
|
|
|
|
return ValueError(
|
|
|
|
return ValueError(
|
|
|
|
f"Please set the environment variable VOICE to a valid voice. options are: {voices}"
|
|
|
|
f"Please set the environment variable STREAMLABS_VOICE to a valid voice. options are: {voices}"
|
|
|
|
)
|
|
|
|
)
|
|
|
|
voice = str(os.getenv("STREAMLABS_VOICE")).capitalize()
|
|
|
|
voice = str(os.getenv("STREAMLABS_VOICE")).capitalize()
|
|
|
|
body = {"voice": voice, "text": text, "service": "polly"}
|
|
|
|
body = {"voice": voice, "text": text, "service": "polly"}
|
|
|
|