Spaces:
Sleeping
Sleeping
Update app.py
Browse files33 unmodified lines3435363738394033 unmodified linesdef correct_text(text):spell = SpellChecker(language='es') # Usamos espa帽ol para la correcci贸nwords = text.split() # Separar el texto en palabrascorrected_words = [spell.correction(word) for word in words] # Corregir las palabrascorrected_text = " ".join(corrected_words) # Volver a unir las palabrasreturn corrected_text33 unmodified lines343536373839404142434445464733 unmodified linesdef correct_text(text):spell = SpellChecker(language='es') # Usamos espa帽ol para la correcci贸nwords = text.split() # Separar el texto en palabrascorrected_words = []for word in words:corrected = spell.correction(word)if corrected is None: # Si no se encuentra correcci贸n, dejamos la palabra originalcorrected = wordcorrected_words.append(corrected)corrected_text = " ".join(corrected_words) # Volver a unir las palabrasreturn corrected_text
app.py+8-1