Keywords modification and Skip invalid template