Refactor the web graph to be more concise