Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -115,7 +115,7 @@ model_type = st.selectbox(
|
|
115 |
|
116 |
def highlight_obscene_words(text, model_type):
|
117 |
if model_type=="fasttext":
|
118 |
-
label,_=
|
119 |
if label[0]=='__label__positive':
|
120 |
st.markdown(
|
121 |
"<span style='background:#47916B;'>{}|приемлемо</span>".format(text),
|
|
|
115 |
|
116 |
def highlight_obscene_words(text, model_type):
|
117 |
if model_type=="fasttext":
|
118 |
+
label,_=model_fasttext.predict(text.lower())
|
119 |
if label[0]=='__label__positive':
|
120 |
st.markdown(
|
121 |
"<span style='background:#47916B;'>{}|приемлемо</span>".format(text),
|