vluz commited on
Commit
50fc5c2
1 Parent(s): c4f0f79

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -24,14 +24,14 @@ st.title("Toxic Comment Test")
24
  st.divider()
25
  model = load_model()
26
  vectorizer = load_vectorizer()
27
- default_prompt = "I love you man, but fuck you!"
28
  input_text = st.text_area("Comment:", default_prompt, height=150).lower()
29
  if st.button("Test"):
30
  if not input_text:
31
  st.write("⚠ Warning: Empty prompt.")
32
  elif len(input_text) < 15:
33
  st.write("⚠ Warning: Model is far less accurate with a small prompt.")
34
- if input_text == default_prompt.lower():
35
  st.write("Expected results from default prompt are positive for 0 and 2")
36
  with st.spinner("Testing..."):
37
  inputv = vectorizer([input_text])
 
24
  st.divider()
25
  model = load_model()
26
  vectorizer = load_vectorizer()
27
+ default_prompt = "love you man, but fuck you"
28
  input_text = st.text_area("Comment:", default_prompt, height=150).lower()
29
  if st.button("Test"):
30
  if not input_text:
31
  st.write("⚠ Warning: Empty prompt.")
32
  elif len(input_text) < 15:
33
  st.write("⚠ Warning: Model is far less accurate with a small prompt.")
34
+ if input_text == default_prompt:
35
  st.write("Expected results from default prompt are positive for 0 and 2")
36
  with st.spinner("Testing..."):
37
  inputv = vectorizer([input_text])