labeled edge implementation, better visualization