minor update to standard voice naming.

This commit is contained in:
erew123 authored and GitHub committed 2023-12-25 21:53:40 +00:00
1 parent be9862d0b0
commit 5bed68a963
1 file changed
+7 -2
+7 -2
View File
@@ -576,9 +576,14 @@ def output_modifier(string, state):
)
cleaned_part = html.unescape(processed_string)
# Process the part and give it a non-character name if being used vai API or standalone.
output_filename = get_output_filename(state)
if "character_menu" in state:
output_file = Path(f'{params["output_folder_wav"]}/{state["character_menu"]}_{int(time.time())}.wav')
else:
output_file = Path(f'{params["output_folder_wav"]}/TTSOUT_{int(time.time())}.wav')
output_file_str = output_file.as_posix()
output_file = get_output_filename(state)
generate_response = send_generate_request(
cleaned_part, params["voice"], language_code, output_filename
cleaned_part, params["voice"], language_code, output_file_str
)
audio_path = generate_response.get("data", {}).get("audio_path")
final_output_file = audio_path