work on template language grammar