remove unneeded imports, move RecordBasedStage and PassThroughStage