generate_graph has been added