add node template and preprocessing