NihalGazi commited on
Commit
1455081
·
verified ·
1 Parent(s): 1c74f1e

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -43,10 +43,10 @@ def introduce_typos(text, typo_probability=0.03):
43
  # Create a list to hold the characters with typos
44
  typo_text = []
45
 
46
- if(random.random > typo_probability):
47
  text = text.replace("o", "oo")
48
 
49
- if(random.random > typo_probability):
50
  text = text.replace("?", "??")
51
 
52
  for char in characters:
 
43
  # Create a list to hold the characters with typos
44
  typo_text = []
45
 
46
+ if(random.random() > typo_probability):
47
  text = text.replace("o", "oo")
48
 
49
+ if(random.random() > typo_probability):
50
  text = text.replace("?", "??")
51
 
52
  for char in characters: