add pre-processing