Modify generate script to take variables as parameters.
Add example and remove commented code from generate.py