Python scripts for raw text process