improve the script.