Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -292,22 +292,24 @@ def create_interface():
|
|
292 |
personalities_explanation = re.search(r"Explanation:(.*?)(?=Sentence:|$)", personalities, re.DOTALL)
|
293 |
personalities_sentence = re.search(r"Sentence:(.*?)$", personalities, re.DOTALL)
|
294 |
|
295 |
-
return
|
296 |
-
|
297 |
-
|
298 |
-
|
299 |
-
|
300 |
-
|
301 |
-
|
302 |
-
attachments_explanation
|
303 |
-
attachments_sentence
|
304 |
-
|
305 |
-
|
306 |
-
bigfive_explanation
|
307 |
-
bigfive_sentence
|
308 |
-
|
309 |
-
|
310 |
-
|
|
|
|
|
311 |
|
312 |
input_file.upload(
|
313 |
fn=process_input,
|
@@ -322,9 +324,4 @@ def create_interface():
|
|
322 |
personalities_output, personalities_chart, personalities_explanation, personalities_sentence]
|
323 |
)
|
324 |
|
325 |
-
return iface
|
326 |
-
|
327 |
-
iface = create_interface()
|
328 |
-
|
329 |
-
# Launch the app
|
330 |
-
iface.launch()
|
|
|
292 |
personalities_explanation = re.search(r"Explanation:(.*?)(?=Sentence:|$)", personalities, re.DOTALL)
|
293 |
personalities_sentence = re.search(r"Sentence:(.*?)$", personalities, re.DOTALL)
|
294 |
|
295 |
+
return [
|
296 |
+
status,
|
297 |
+
exec_time,
|
298 |
+
lang,
|
299 |
+
info,
|
300 |
+
attachments,
|
301 |
+
attachments_chart_img,
|
302 |
+
attachments_explanation.group(1).strip() if attachments_explanation else "",
|
303 |
+
attachments_sentence.group(1).strip() if attachments_sentence else "",
|
304 |
+
bigfive,
|
305 |
+
bigfive_chart_img,
|
306 |
+
bigfive_explanation.group(1).strip() if bigfive_explanation else "",
|
307 |
+
bigfive_sentence.group(1).strip() if bigfive_sentence else "",
|
308 |
+
personalities,
|
309 |
+
personalities_chart_img,
|
310 |
+
personalities_explanation.group(1).strip() if personalities_explanation else "",
|
311 |
+
personalities_sentence.group(1).strip() if personalities_sentence else ""
|
312 |
+
]
|
313 |
|
314 |
input_file.upload(
|
315 |
fn=process_input,
|
|
|
324 |
personalities_output, personalities_chart, personalities_explanation, personalities_sentence]
|
325 |
)
|
326 |
|
327 |
+
return iface
|
|
|
|
|
|
|
|
|
|