Working prototype of script / template compliation