From 6b7ceb4a7b9af143317c4c0294f44ddb6a86eaf9 Mon Sep 17 00:00:00 2001 From: David Marx Date: Sun, 9 Oct 2022 15:36:52 -0700 Subject: [PATCH] fix prompt lag w override --- Video_Killed_The_Radio_Star_Defusion.ipynb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Video_Killed_The_Radio_Star_Defusion.ipynb b/Video_Killed_The_Radio_Star_Defusion.ipynb index 78caf2e..fd70dc3 100644 --- a/Video_Killed_The_Radio_Star_Defusion.ipynb +++ b/Video_Killed_The_Radio_Star_Defusion.ipynb @@ -795,7 +795,7 @@ " \n", " if prompt_lag and (idx > 0):\n", " rec_prev = prompt_starts[idx -1]\n", - " prev_prompt = rec_prev['override_prompt']\n", + " prev_prompt = rec_prev.get('override_prompt','').strip()\n", " if not prev_prompt:\n", " prev_prompt = rec_prev['prompt']\n", " prompt = f\"{prev_prompt}, {prompt}\"\n", @@ -1062,7 +1062,7 @@ "try:\n", " from prefetch_generator import BackgroundGenerator\n", "except:\n", - " !pip install prefetch_generator \n", + " !pip install prefetch_generator\n", " from prefetch_generator import BackgroundGenerator\n", "\n", "from vktrs.tsp import (\n",