improve some funcion and variable name and package them all together