updating app
Browse files
app.py
CHANGED
|
@@ -80,7 +80,6 @@ def main():
|
|
| 80 |
|
| 81 |
else:
|
| 82 |
st.session_state['text'] = txt
|
| 83 |
-
st.session_state['graph'] = None
|
| 84 |
|
| 85 |
# preprocess
|
| 86 |
sentence = ie.preprocess(txt)
|
|
@@ -107,6 +106,7 @@ def main():
|
|
| 107 |
|
| 108 |
st.session_state['graph'] = graph
|
| 109 |
|
|
|
|
| 110 |
st.divider()
|
| 111 |
st.write("Does this prediction look correct?")
|
| 112 |
collector.st_feedback(
|
|
@@ -121,6 +121,9 @@ def main():
|
|
| 121 |
single_submit=False
|
| 122 |
)
|
| 123 |
|
|
|
|
|
|
|
|
|
|
| 124 |
|
| 125 |
if __name__ == '__main__':
|
| 126 |
main()
|
|
|
|
| 80 |
|
| 81 |
else:
|
| 82 |
st.session_state['text'] = txt
|
|
|
|
| 83 |
|
| 84 |
# preprocess
|
| 85 |
sentence = ie.preprocess(txt)
|
|
|
|
| 106 |
|
| 107 |
st.session_state['graph'] = graph
|
| 108 |
|
| 109 |
+
if st.session_state['graph'] is not None:
|
| 110 |
st.divider()
|
| 111 |
st.write("Does this prediction look correct?")
|
| 112 |
collector.st_feedback(
|
|
|
|
| 121 |
single_submit=False
|
| 122 |
)
|
| 123 |
|
| 124 |
+
st.session_state['text'] = ''
|
| 125 |
+
st.session_state['graph'] = None
|
| 126 |
+
|
| 127 |
|
| 128 |
if __name__ == '__main__':
|
| 129 |
main()
|