vishnun commited on
Commit
aa1d224
1 Parent(s): ec81302

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +7 -5
app.py CHANGED
@@ -33,13 +33,14 @@ if submit:
33
  num_return_sequences=3
34
  )
35
 
36
- st.subheader("Most probables: ")
 
 
37
  for y in outputs:
38
-
 
39
  out_text = ttokenizer.decode(y, skip_special_tokens=True)
40
  st.success(out_text.capitalize())
41
-
42
- st.markdown("#### Highlighter on edits:")
43
  c_text = ""
44
  for x in out_text.lower().split(" "):
45
  if x in input_text.lower().split(" "):
@@ -48,4 +49,5 @@ if submit:
48
  c_text = c_text + '<span style="font-weight:bold; color:rgb(150,255,100);">' + x + '</span>' + " "
49
 
50
  ct = c_text.capitalize()
51
- st.markdown(str(ct), unsafe_allow_html=True)
 
 
33
  num_return_sequences=3
34
  )
35
 
36
+ st.subheader("Most probable: ")
37
+
38
+ i = 0
39
  for y in outputs:
40
+ i = i + 1
41
+ st.info(str(int(i))
42
  out_text = ttokenizer.decode(y, skip_special_tokens=True)
43
  st.success(out_text.capitalize())
 
 
44
  c_text = ""
45
  for x in out_text.lower().split(" "):
46
  if x in input_text.lower().split(" "):
 
49
  c_text = c_text + '<span style="font-weight:bold; color:rgb(150,255,100);">' + x + '</span>' + " "
50
 
51
  ct = c_text.capitalize()
52
+ st.markdown(str(ct), unsafe_allow_html=True)
53
+