use kwargs to get context data for the rendered graph

The graph could use a little context from the kwargs. This context data can be used to handle certain events on the graph.