From 65bdcede6298c05c7d9187e0c4864942e07f09c1 Mon Sep 17 00:00:00 2001 From: Yixiao Zhang Date: Mon, 26 Jun 2023 17:48:13 +0900 Subject: [PATCH] hot fix --- melodytalk/main.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/melodytalk/main.py b/melodytalk/main.py index 60de21e..e5c9eec 100644 --- a/melodytalk/main.py +++ b/melodytalk/main.py @@ -186,7 +186,7 @@ def run_text(self, text, state): res['output'] = res['output'].replace("\\", "/") state = state + [(text, res['output'])] if len(res['intermediate_steps']) > 0: - audio_filename = res['intermediate_steps'][0][1] + audio_filename = res['intermediate_steps'][-1][1] state = state + [(None,(audio_filename,))] print(f"\nProcessed run_text, Input text: {text}\nCurrent state: {state}\n" f"Current Memory: {self.agent.memory.buffer}")