Spaces:
Runtime error
Runtime error
Victoria Slocum
commited on
Commit
•
2d3407c
1
Parent(s):
0c1cf8c
fix: tab box
Browse files
app.py
CHANGED
@@ -33,7 +33,6 @@ def get_all_models():
|
|
33 |
models.append(model)
|
34 |
return models
|
35 |
|
36 |
-
|
37 |
models = get_all_models()
|
38 |
|
39 |
def download_svg(svg):
|
@@ -202,34 +201,33 @@ with demo:
|
|
202 |
gr.Markdown("")
|
203 |
|
204 |
button = gr.Button("Generate", variant="primary")
|
205 |
-
with gr.
|
206 |
-
with gr.
|
207 |
-
|
208 |
-
|
209 |
-
|
210 |
-
|
211 |
-
|
212 |
-
with gr.
|
213 |
-
|
214 |
-
|
215 |
-
|
216 |
-
|
217 |
-
|
218 |
-
|
219 |
-
|
220 |
-
|
221 |
-
|
222 |
-
|
223 |
-
|
224 |
-
|
225 |
-
|
226 |
-
|
227 |
-
|
228 |
-
with gr.
|
229 |
-
|
230 |
-
|
231 |
-
|
232 |
-
dep_download_button = gr.HTML(value=download_svg(depen_output.value))
|
233 |
|
234 |
|
235 |
|
|
|
33 |
models.append(model)
|
34 |
return models
|
35 |
|
|
|
36 |
models = get_all_models()
|
37 |
|
38 |
def download_svg(svg):
|
|
|
201 |
gr.Markdown("")
|
202 |
|
203 |
button = gr.Button("Generate", variant="primary")
|
204 |
+
with gr.Box():
|
205 |
+
with gr.Column():
|
206 |
+
gr.Markdown(
|
207 |
+
"## [Dependency Parser](https://spacy.io/usage/visualizers#dep)")
|
208 |
+
gr.Markdown(
|
209 |
+
"The dependency visualizer shows part-of-speech tags and syntactic dependencies.")
|
210 |
+
with gr.Row():
|
211 |
+
with gr.Column():
|
212 |
+
col_punct = gr.Checkbox(
|
213 |
+
label="Collapse Punctuation", value=True)
|
214 |
+
col_phrase = gr.Checkbox(
|
215 |
+
label="Collapse Phrases", value=True)
|
216 |
+
compact = gr.Checkbox(label="Compact", value=False)
|
217 |
+
with gr.Column():
|
218 |
+
bg = gr.Textbox(
|
219 |
+
label="Background Color", value=DEFAULT_COLOR)
|
220 |
+
with gr.Column():
|
221 |
+
text = gr.Textbox(
|
222 |
+
label="Text Color", value="black")
|
223 |
+
|
224 |
+
depen_output = gr.HTML(value=dependency(
|
225 |
+
DEFAULT_TEXT, True, True, False, DEFAULT_COLOR, "black", DEFAULT_MODEL)[0])
|
226 |
+
with gr.Row():
|
227 |
+
with gr.Column():
|
228 |
+
dep_button = gr.Button("Generate Dependency Parser", variant="primary")
|
229 |
+
with gr.Column():
|
230 |
+
dep_download_button = gr.HTML(value=download_svg(depen_output.value))
|
|
|
231 |
|
232 |
|
233 |
|