Add tool to reduce graph to the specified number of nodes.