Use a graph identifier when generating diagrams