Update app.py
Browse files
app.py
CHANGED
@@ -171,8 +171,32 @@ def process_report(agent, file, messages: List[Dict[str, str]]) -> Tuple[List[Di
|
|
171 |
return messages, None
|
172 |
|
173 |
def create_ui(agent):
|
174 |
-
with gr.Blocks(
|
175 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
176 |
with gr.Row():
|
177 |
with gr.Column(scale=3):
|
178 |
chatbot = gr.Chatbot(label="Assistant", height=700, type="messages")
|
@@ -198,4 +222,4 @@ if __name__ == "__main__":
|
|
198 |
ui.launch(server_name="0.0.0.0", server_port=7860, allowed_paths=["/data/hf_cache/reports"], share=False)
|
199 |
except Exception as err:
|
200 |
print(f"Startup failed: {err}")
|
201 |
-
sys.exit(1)
|
|
|
171 |
return messages, None
|
172 |
|
173 |
def create_ui(agent):
|
174 |
+
with gr.Blocks(css="""
|
175 |
+
html, body, .gradio-container {
|
176 |
+
background-color: #ffffff;
|
177 |
+
font-family: 'Inter', sans-serif;
|
178 |
+
color: #000000;
|
179 |
+
}
|
180 |
+
.gr-button.primary {
|
181 |
+
background-color: #1e88e5;
|
182 |
+
color: white;
|
183 |
+
font-weight: 600;
|
184 |
+
border-radius: 6px;
|
185 |
+
padding: 0.6em 1.2em;
|
186 |
+
}
|
187 |
+
.gr-button.primary:hover {
|
188 |
+
background-color: #1565c0;
|
189 |
+
}
|
190 |
+
.gr-chatbot, .gr-file-upload, .gr-markdown {
|
191 |
+
border-radius: 10px;
|
192 |
+
border: 1px solid #ccc;
|
193 |
+
background-color: #f9f9f9;
|
194 |
+
}
|
195 |
+
""") as demo:
|
196 |
+
gr.Markdown("""
|
197 |
+
<h2 style='color:#1e88e5'>🩺 Clinical Report Assistant</h2>
|
198 |
+
<p style='color:#333;'>Upload a clinical Excel file to receive a structured diagnostic summary.</p>
|
199 |
+
""")
|
200 |
with gr.Row():
|
201 |
with gr.Column(scale=3):
|
202 |
chatbot = gr.Chatbot(label="Assistant", height=700, type="messages")
|
|
|
222 |
ui.launch(server_name="0.0.0.0", server_port=7860, allowed_paths=["/data/hf_cache/reports"], share=False)
|
223 |
except Exception as err:
|
224 |
print(f"Startup failed: {err}")
|
225 |
+
sys.exit(1)
|