template folder and main.py changes