add script to generate py file