jeremierostan commited on
Commit
def97c6
1 Parent(s): 4363711

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +9 -5
app.py CHANGED
@@ -140,9 +140,14 @@ assistant_logo = os.getenv('LOGO')
140
 
141
  # Gradio interface using Blocks
142
  with gr.Blocks(theme=isp_theme, css=custom_css) as iface:
143
- gr.HTML(f"<img id='logo-img' src='{assistant_logo}' alt='Assistant Logo'>")
144
- gr.Markdown(f"# {assistant_title}")
145
- gr.Markdown("Chat with a Historical Figure")
 
 
 
 
 
146
 
147
  chatbot = gr.Chatbot(
148
  height=500,
@@ -175,7 +180,6 @@ with gr.Blocks(theme=isp_theme, css=custom_css) as iface:
175
  inputs=msg
176
  )
177
 
178
- disclaimer_text = "You are chatting with an AI assistant. Make sure to evaluate the accuracy of its answers."
179
- gr.HTML(f"<div id='disclaimer-footer'>{disclaimer_text}</div>")
180
 
181
  iface.launch(auth=(username, password))
 
140
 
141
  # Gradio interface using Blocks
142
  with gr.Blocks(theme=isp_theme, css=custom_css) as iface:
143
+ with gr.Row():
144
+ logo_html = f"""
145
+ <img id='logo-img' src='{assistant_logo}' alt='Assistant Logo' onerror="this.style.display='none';document.getElementById('logo-error').style.display='block';">
146
+ <div id='logo-error' style='display:none;'>Logo not found</div>
147
+ """
148
+ gr.HTML(logo_html)
149
+ gr.Markdown(f"# {assistant_title}", elem_classes="title")
150
+ gr.Markdown("Chat with a Historical Figure")
151
 
152
  chatbot = gr.Chatbot(
153
  height=500,
 
180
  inputs=msg
181
  )
182
 
183
+ gr.Markdown("You are chatting with an AI assistant. Make sure to evaluate the accuracy of its answers.")
 
184
 
185
  iface.launch(auth=(username, password))