format dep tree explicitly into a list of edges