Spaces:
Sleeping
Sleeping
File size: 126 Bytes
cf59e1e |
1 2 3 4 5 6 |
import re
def preprocess_text(text: str) -> str:
text = text.strip()
text = re.sub(r"\s+", " ", text)
return text |