working clean function and outline of process method