Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -63,7 +63,7 @@ def generate_response(user_query, relevant_segment):
|
|
63 |
Generate a response emphasizing the bot's capability in providing chess information.
|
64 |
"""
|
65 |
try:
|
66 |
-
system_message = "You are a celebrity chatbot specialized in
|
67 |
user_message = f"Here's the information on chess: {relevant_segment}"
|
68 |
messages = [
|
69 |
{"role": "system", "content": system_message},
|
@@ -118,7 +118,7 @@ placeholder = """
|
|
118 |
|
119 |
# Setup the Gradio Blocks interface with custom layout components
|
120 |
with gr.Blocks(theme='Taithrah/Minimal') as demo:
|
121 |
-
gr.Image("craiyon_140344_Generic_Handsome_celebrity_man_face.png", show_label = False, show_share_button = False, show_download_button = False)
|
122 |
gr.Markdown(welcome_message) # Display the formatted welcome message
|
123 |
with gr.Row():
|
124 |
with gr.Column():
|
@@ -129,7 +129,7 @@ with gr.Blocks(theme='Taithrah/Minimal') as demo:
|
|
129 |
gr.Markdown(placeholder)
|
130 |
submit_button = gr.Button("Submit")
|
131 |
gr.Markdown(placeholder)
|
132 |
-
answer = gr.Textbox(label="CelebrityFinder Response", placeholder="CelebrityFinder will
|
133 |
submit_button.click(fn=query_model, inputs=question, outputs=answer)
|
134 |
|
135 |
|
|
|
63 |
Generate a response emphasizing the bot's capability in providing chess information.
|
64 |
"""
|
65 |
try:
|
66 |
+
system_message = "You are a celebrity chatbot with a coy, sassy attitude specialized in creating shorts lists of the names of celebrities that match the all of the physical characteristics provided by the user."
|
67 |
user_message = f"Here's the information on chess: {relevant_segment}"
|
68 |
messages = [
|
69 |
{"role": "system", "content": system_message},
|
|
|
118 |
|
119 |
# Setup the Gradio Blocks interface with custom layout components
|
120 |
with gr.Blocks(theme='Taithrah/Minimal') as demo:
|
121 |
+
gr.Image("craiyon_140344_Generic_Handsome_celebrity_man_face.png", show_label = False, show_share_button = False, show_download_button = False, width=250, height=250)
|
122 |
gr.Markdown(welcome_message) # Display the formatted welcome message
|
123 |
with gr.Row():
|
124 |
with gr.Column():
|
|
|
129 |
gr.Markdown(placeholder)
|
130 |
submit_button = gr.Button("Submit")
|
131 |
gr.Markdown(placeholder)
|
132 |
+
answer = gr.Textbox(label="CelebrityFinder Response", placeholder="CelebrityFinder will give you some celebs that match your description here", interactive=False, lines=10)
|
133 |
submit_button.click(fn=query_model, inputs=question, outputs=answer)
|
134 |
|
135 |
|