replaced generate_name with generate_string