UnarineLeo
commited on
Update app.py
Browse files
app.py
CHANGED
@@ -112,18 +112,13 @@ with col1:
|
|
112 |
warnings.append(f"Warning: No ':' token found in sentence: {sentence} in line {i}")
|
113 |
|
114 |
if st.button("Submit",use_container_width=True):
|
115 |
-
|
116 |
-
|
117 |
-
st.warning(warning)
|
118 |
-
st.session_state['warnings'].clear()
|
119 |
-
else:
|
120 |
-
result, warnings = fill_mask(input_sentences)
|
121 |
-
st.session_state['warnings'] = warnings
|
122 |
|
123 |
-
|
124 |
-
|
125 |
-
|
126 |
-
|
127 |
|
128 |
st.markdown("Example")
|
129 |
st.code(sample_sentence, wrap_lines=True)
|
|
|
112 |
warnings.append(f"Warning: No ':' token found in sentence: {sentence} in line {i}")
|
113 |
|
114 |
if st.button("Submit",use_container_width=True):
|
115 |
+
result, warnings = fill_mask(input_sentences)
|
116 |
+
st.session_state['warnings'] = warnings
|
|
|
|
|
|
|
|
|
|
|
117 |
|
118 |
+
if st.session_state['warnings']:
|
119 |
+
for warning in st.session_state['warnings']:
|
120 |
+
st.warning(warning)
|
121 |
+
st.session_state['warnings'].clear()
|
122 |
|
123 |
st.markdown("Example")
|
124 |
st.code(sample_sentence, wrap_lines=True)
|