Update app.py
Browse files
app.py
CHANGED
@@ -4,6 +4,14 @@ import json
|
|
4 |
from bs4 import BeautifulSoup
|
5 |
import requests
|
6 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
7 |
def extract_text_from_webpage(html_content):
|
8 |
soup = BeautifulSoup(html_content, 'html.parser')
|
9 |
for tag in soup(["script", "style", "header", "footer"]):
|
@@ -122,5 +130,7 @@ demo = gr.ChatInterface(
|
|
122 |
textbox=gr.Textbox(),
|
123 |
multimodal=False,
|
124 |
concurrency_limit=200,
|
|
|
|
|
125 |
)
|
126 |
demo.launch(share=True)
|
|
|
4 |
from bs4 import BeautifulSoup
|
5 |
import requests
|
6 |
|
7 |
+
css = '''
|
8 |
+
.gradio-container{max-width: 1000px !important}
|
9 |
+
h1{text-align:center}
|
10 |
+
footer {
|
11 |
+
visibility: hidden
|
12 |
+
}
|
13 |
+
'''
|
14 |
+
|
15 |
def extract_text_from_webpage(html_content):
|
16 |
soup = BeautifulSoup(html_content, 'html.parser')
|
17 |
for tag in soup(["script", "style", "header", "footer"]):
|
|
|
130 |
textbox=gr.Textbox(),
|
131 |
multimodal=False,
|
132 |
concurrency_limit=200,
|
133 |
+
css=css,
|
134 |
+
theme="allenai/gradio-theme",
|
135 |
)
|
136 |
demo.launch(share=True)
|