From b31321c7797ef4ce658fdd86f703d8d5ca4e8f8c Mon Sep 17 00:00:00 2001 From: oobabooga <112222186+oobabooga@users.noreply.github.com> Date: Wed, 26 Jul 2023 07:26:37 -0700 Subject: [PATCH] Define visible_text before applying chat_input extensions --- modules/chat.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/modules/chat.py b/modules/chat.py index 0e0e416c..f684768b 100644 --- a/modules/chat.py +++ b/modules/chat.py @@ -175,10 +175,8 @@ def chatbot_wrapper(text, state, regenerate=False, _continue=False, loading_mess # Preparing the input if not any((regenerate, _continue)): + visible_text = text text, visible_text = apply_extensions('chat_input', text, visible_text, state) - if visible_text is None: - visible_text = text - text = apply_extensions('input', text, state) # *Is typing...*