Spaces:
Sleeping
Sleeping
Update Gradio_UI.py
Browse files- Gradio_UI.py +9 -12
Gradio_UI.py
CHANGED
|
@@ -91,30 +91,28 @@ def continue_conversation(user_input):
|
|
| 91 |
|
| 92 |
# === Gradio Interface ===
|
| 93 |
with gr.Blocks(title="Regulatory Compliance Generator") as demo:
|
| 94 |
-
# GDPR
|
| 95 |
gr.Markdown("""
|
| 96 |
### 🔒 GDPR Notice
|
| 97 |
This assistant does not store any personal data.
|
| 98 |
All responses are processed temporarily to generate your document.
|
| 99 |
You are responsible for the accuracy and legality of the information submitted.
|
| 100 |
-
"""
|
| 101 |
|
| 102 |
-
#
|
| 103 |
gr.HTML("""
|
| 104 |
<style>
|
| 105 |
footer,
|
| 106 |
-
.
|
| 107 |
-
|
| 108 |
-
|
| 109 |
-
.
|
| 110 |
-
.
|
| 111 |
display: none !important;
|
| 112 |
}
|
| 113 |
</style>
|
| 114 |
""")
|
| 115 |
|
| 116 |
-
gr.Markdown("## 📑 Regulation Document Generator")
|
| 117 |
-
|
| 118 |
with gr.Row():
|
| 119 |
reg_dropdown = gr.Dropdown(
|
| 120 |
choices=list(DOCUMENT_TO_MODULE.keys()),
|
|
@@ -147,5 +145,4 @@ with gr.Blocks(title="Regulatory Compliance Generator") as demo:
|
|
| 147 |
user_input.submit(continue_conversation, inputs=user_input, outputs=[chatbox, pdf_output])
|
| 148 |
user_input.submit(lambda: "", None, user_input)
|
| 149 |
|
| 150 |
-
|
| 151 |
-
demo.launch(show_api=False)
|
|
|
|
| 91 |
|
| 92 |
# === Gradio Interface ===
|
| 93 |
with gr.Blocks(title="Regulatory Compliance Generator") as demo:
|
| 94 |
+
# GDPR Notice
|
| 95 |
gr.Markdown("""
|
| 96 |
### 🔒 GDPR Notice
|
| 97 |
This assistant does not store any personal data.
|
| 98 |
All responses are processed temporarily to generate your document.
|
| 99 |
You are responsible for the accuracy and legality of the information submitted.
|
| 100 |
+
""")
|
| 101 |
|
| 102 |
+
# Custom CSS to hide Gradio/HF UI elements
|
| 103 |
gr.HTML("""
|
| 104 |
<style>
|
| 105 |
footer,
|
| 106 |
+
.absolute.bottom-4.right-4,
|
| 107 |
+
a[href*="gradio.app"],
|
| 108 |
+
a[href*="huggingface.co"],
|
| 109 |
+
.svelte-drgfjz[data-testid="clear-button"],
|
| 110 |
+
.svelte-1ipelgc[data-testid="block-settings-button"] {
|
| 111 |
display: none !important;
|
| 112 |
}
|
| 113 |
</style>
|
| 114 |
""")
|
| 115 |
|
|
|
|
|
|
|
| 116 |
with gr.Row():
|
| 117 |
reg_dropdown = gr.Dropdown(
|
| 118 |
choices=list(DOCUMENT_TO_MODULE.keys()),
|
|
|
|
| 145 |
user_input.submit(continue_conversation, inputs=user_input, outputs=[chatbox, pdf_output])
|
| 146 |
user_input.submit(lambda: "", None, user_input)
|
| 147 |
|
| 148 |
+
demo.launch()
|
|
|