From a57e8ea1f79869192dcf98f6a46dd48cea102574 Mon Sep 17 00:00:00 2001 From: Daniel McKnight Date: Wed, 12 Feb 2025 10:58:29 -0800 Subject: [PATCH] Troubleshoot returned audio file handling --- neon_audio/tts/neon.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/neon_audio/tts/neon.py b/neon_audio/tts/neon.py index a2ac76b..ec26d2f 100644 --- a/neon_audio/tts/neon.py +++ b/neon_audio/tts/neon.py @@ -31,6 +31,7 @@ import os from os.path import dirname +from pathlib import Path from time import time from typing import List @@ -340,8 +341,7 @@ def get_multiple_tts(self, message, **kwargs) -> dict: tx_sentence = sentence kwargs['speaker'] = request audio_obj, phonemes = self.synth(tx_sentence, **kwargs) - wav_file = audio_obj.path - + wav_file = str(audio_obj) # If this is the first response, populate translation and phonemes responses.setdefault(tts_lang, {"sentence": tx_sentence, "translated": tx_sentence != sentence,