如何在Go中表示实体之间的关系?

There is a large project on Golang which divided into many packages. I want to visualize the relationship between its entities to better understand the structure of the project. The first thing that comes to mind - the dependency graph classes. How to build it?

PS: And I want find all unused method's / structures

The tool closest to what you search (but without the diagram feature though) would be go oracle

It can be embedded in:

I also like to use test cases in order to compute a code coverage, which also helps to pinpoint unused methods.