use less memory to do text preprocessing.