Spaces:
Sleeping
Sleeping
Update modules/semantic/semantic_interface.py
Browse files
modules/semantic/semantic_interface.py
CHANGED
@@ -52,7 +52,7 @@ def display_semantic_interface(lang_code, nlp_models, semantic_t):
|
|
52 |
key=f"semantic_file_uploader_{st.session_state.semantic_state['analysis_count']}"
|
53 |
)
|
54 |
|
55 |
-
# Verificar si hay un archivo cargado y un an谩lisis pendiente
|
56 |
if uploaded_file is not None and st.session_state.semantic_state.get('pending_analysis', False):
|
57 |
try:
|
58 |
with st.spinner(semantic_t.get('processing', 'Processing...')):
|
@@ -205,7 +205,7 @@ def display_semantic_results(semantic_result, lang_code, semantic_t):
|
|
205 |
|
206 |
# Gr谩fico de conceptos
|
207 |
# st.subheader(semantic_t.get('concept_graph', 'Concepts Graph'))
|
208 |
-
#Colocar aqu铆 el bloque de c贸digo
|
209 |
if 'concept_graph' in analysis and analysis['concept_graph'] is not None:
|
210 |
try:
|
211 |
# Container para el grafo con estilos mejorados
|
@@ -228,7 +228,7 @@ def display_semantic_results(semantic_result, lang_code, semantic_t):
|
|
228 |
""",
|
229 |
unsafe_allow_html=True
|
230 |
)
|
231 |
-
#Colocar aqu铆 el bloque de c贸digo
|
232 |
|
233 |
with st.container():
|
234 |
st.markdown('<div class="graph-container">', unsafe_allow_html=True)
|
@@ -242,10 +242,10 @@ def display_semantic_results(semantic_result, lang_code, semantic_t):
|
|
242 |
)
|
243 |
|
244 |
# Leyenda del grafo
|
245 |
-
st.caption(semantic_t.get(
|
246 |
-
|
247 |
-
|
248 |
-
))
|
249 |
|
250 |
st.markdown('</div>', unsafe_allow_html=True)
|
251 |
|
|
|
52 |
key=f"semantic_file_uploader_{st.session_state.semantic_state['analysis_count']}"
|
53 |
)
|
54 |
|
55 |
+
# 2.1 Verificar si hay un archivo cargado y un an谩lisis pendiente
|
56 |
if uploaded_file is not None and st.session_state.semantic_state.get('pending_analysis', False):
|
57 |
try:
|
58 |
with st.spinner(semantic_t.get('processing', 'Processing...')):
|
|
|
205 |
|
206 |
# Gr谩fico de conceptos
|
207 |
# st.subheader(semantic_t.get('concept_graph', 'Concepts Graph'))
|
208 |
+
#Colocar aqu铆 el bloque de c贸digo
|
209 |
if 'concept_graph' in analysis and analysis['concept_graph'] is not None:
|
210 |
try:
|
211 |
# Container para el grafo con estilos mejorados
|
|
|
228 |
""",
|
229 |
unsafe_allow_html=True
|
230 |
)
|
231 |
+
#Colocar aqu铆 el bloque de c贸digo
|
232 |
|
233 |
with st.container():
|
234 |
st.markdown('<div class="graph-container">', unsafe_allow_html=True)
|
|
|
242 |
)
|
243 |
|
244 |
# Leyenda del grafo
|
245 |
+
#st.caption(semantic_t.get(
|
246 |
+
# 'graph_description',
|
247 |
+
# 'Visualizaci贸n de relaciones entre conceptos clave identificados en el texto.'
|
248 |
+
#))
|
249 |
|
250 |
st.markdown('</div>', unsafe_allow_html=True)
|
251 |
|