Reorganized scripts to framework