divide pre-parsing processes into indivitual functions