Spaces:
Runtime error
Runtime error
Commit
·
5bd775a
1
Parent(s):
871bf2e
fix issue
Browse files
app.py
CHANGED
|
@@ -28,7 +28,7 @@ def main():
|
|
| 28 |
("t5-base-wikisplit","t5-v1_1-base-wikisplit", "byt5-base-wikisplit","t5-large-wikisplit"))
|
| 29 |
|
| 30 |
change_example = st.sidebar.button("Try Different Example")
|
| 31 |
-
|
| 32 |
st.sidebar.write('''
|
| 33 |
## Applications:
|
| 34 |
* Sentence Simplification
|
|
@@ -48,8 +48,10 @@ def main():
|
|
| 48 |
"The East London Line closed on 22 December 2007 and reopened on 27 April 2010 , becoming part of the new London Overground system ."
|
| 49 |
]
|
| 50 |
example = examples[random.randint(0, len(examples)-1)]
|
| 51 |
-
|
|
|
|
| 52 |
example = examples[random.randint(0, len(examples)-1)]
|
|
|
|
| 53 |
input_complex_sentence = st.text_area("Please type a Complex Sentence to split",example)
|
| 54 |
|
| 55 |
if st.button('Split✂️'):
|
|
|
|
| 28 |
("t5-base-wikisplit","t5-v1_1-base-wikisplit", "byt5-base-wikisplit","t5-large-wikisplit"))
|
| 29 |
|
| 30 |
change_example = st.sidebar.button("Try Different Example")
|
| 31 |
+
|
| 32 |
st.sidebar.write('''
|
| 33 |
## Applications:
|
| 34 |
* Sentence Simplification
|
|
|
|
| 48 |
"The East London Line closed on 22 December 2007 and reopened on 27 April 2010 , becoming part of the new London Overground system ."
|
| 49 |
]
|
| 50 |
example = examples[random.randint(0, len(examples)-1)]
|
| 51 |
+
previous_example = example
|
| 52 |
+
while change_example and example==previous_example:
|
| 53 |
example = examples[random.randint(0, len(examples)-1)]
|
| 54 |
+
previous_example = example
|
| 55 |
input_complex_sentence = st.text_area("Please type a Complex Sentence to split",example)
|
| 56 |
|
| 57 |
if st.button('Split✂️'):
|