Adding graph to query UI