aseifert commited on
Commit
70fa8a8
β€’
1 Parent(s): 6681add

Upload app.py

Browse files
Files changed (1) hide show
  1. app.py +9 -3
app.py CHANGED
@@ -58,17 +58,23 @@ def main():
58
  args = TTSettings(num_beams=5, min_length=1, max_length=1024)
59
 
60
  default_text = "A dog is bigger then mouse."
61
- default_text = "what be the reason for everyone leave the comapny"
62
  input_text = st.text_area(
63
  label="Original text",
64
  value=default_text,
65
  )
66
 
 
67
  if st.button("✍️ Check"):
68
  start = time.time()
69
  output(model, args, annotator, input_text)
70
- st.write("---")
71
- st.text(f"Built by Team Writing Assistant ❀️ – prediction took {time.time() - start:.2f}s")
 
 
 
 
 
72
 
73
 
74
  if __name__ == "__main__":
 
58
  args = TTSettings(num_beams=5, min_length=1, max_length=1024)
59
 
60
  default_text = "A dog is bigger then mouse."
61
+ default_text = "it gives him many apprtunites in the life, and i think that being knowledge person is a very wouderful thing to have so we can spend our lives in a successful way and full of happenis."
62
  input_text = st.text_area(
63
  label="Original text",
64
  value=default_text,
65
  )
66
 
67
+ start = None
68
  if st.button("✍️ Check"):
69
  start = time.time()
70
  output(model, args, annotator, input_text)
71
+
72
+ st.write("---")
73
+ st.markdown(
74
+ f"Built by [@aseifert](https://twitter.com/therealaseifert) during the HF community event – [GitHub repo](https://github.com/aseifert/hf-writing-assistant) – Team Writing Assistant"
75
+ )
76
+ if start is not None:
77
+ st.text(f"prediction took {time.time() - start:.2f}s")
78
 
79
 
80
  if __name__ == "__main__":