Update app.py
Browse files
app.py
CHANGED
@@ -25,11 +25,7 @@ st.write("Expand your query by leveraging various models")
|
|
25 |
default_value = "بيعت الأسلحة في السوق"
|
26 |
# sent is the variable holding the user's input
|
27 |
sent = st.text_area("Input", default_value, height=30)
|
28 |
-
|
29 |
-
text_st = sent[-20:]
|
30 |
-
text_st += ' <mask>'
|
31 |
-
else:
|
32 |
-
text_st = sent+ ' <mask>'
|
33 |
|
34 |
pipe = pipeline("fill-mask", tokenizer=tokenizer, model=model)
|
35 |
dict_next_words = next_word(text_st, pipe)
|
|
|
25 |
default_value = "بيعت الأسلحة في السوق"
|
26 |
# sent is the variable holding the user's input
|
27 |
sent = st.text_area("Input", default_value, height=30)
|
28 |
+
text_st = sent+ ' <mask>'
|
|
|
|
|
|
|
|
|
29 |
|
30 |
pipe = pipeline("fill-mask", tokenizer=tokenizer, model=model)
|
31 |
dict_next_words = next_word(text_st, pipe)
|