From c93c317bb8b8f45a569be7a97aae11b1dff86807 Mon Sep 17 00:00:00 2001 From: Abubakar Abid Date: Thu, 20 Jul 2023 07:05:46 -0400 Subject: [PATCH] chat interface example code fix (#4984) --- guides/04_chatbots/01_creating-a-chatbot-fast.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/guides/04_chatbots/01_creating-a-chatbot-fast.md b/guides/04_chatbots/01_creating-a-chatbot-fast.md index a6c08e516e..0b307537f9 100644 --- a/guides/04_chatbots/01_creating-a-chatbot-fast.md +++ b/guides/04_chatbots/01_creating-a-chatbot-fast.md @@ -105,7 +105,7 @@ If you want to customize the `gr.Chatbot` or `gr.Textbox` that compose the `Chat import gradio as gr def yes_man(message, history): - if messages.endswith("?"): + if message.endswith("?"): return "Yes" else: return "Ask me anything!" @@ -113,7 +113,7 @@ def yes_man(message, history): gr.ChatInterface( yes_man, chatbot=gr.Chatbot(height=300), - textbox=gr.Textbox(placeholder="Ask me a yes or no question") + textbox=gr.Textbox(placeholder="Ask me a yes or no question", container=False, scale=7), title="Yes Man", description="Ask Yes Man any question", theme="soft",