Diaa-Zaher commited on
Commit
fbfdb61
·
1 Parent(s): b3b44e9

update application file

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -121,9 +121,9 @@ def spell_check(original_input_text):
121
  suggestions = get_suggestions(misspelled_words, dict)
122
  Suggested_input = print_suggested_input(suggestions, original_input_text, misspelled_words)
123
  if misspelled_words: # because if the input is right, then dont print Did You Mean
124
- return '\nSuggested Text:', f'"{Suggested_input}"'
125
  else :
126
- return 'Your input is: ', higlight_misspelled(preprocessed_text, misspelled_words),print_suggestions(suggestions, misspelled_words)
127
 
128
 
129
  interface = gr.Interface(fn= spell_check,
 
121
  suggestions = get_suggestions(misspelled_words, dict)
122
  Suggested_input = print_suggested_input(suggestions, original_input_text, misspelled_words)
123
  if misspelled_words: # because if the input is right, then dont print Did You Mean
124
+ return 'Corrected Text:', f'"{Suggested_input}"'
125
  else :
126
+ return 'No misspelled words detected'
127
 
128
 
129
  interface = gr.Interface(fn= spell_check,