compressCluster.gvpr is a gvpr program that can be used as either
a preprocessor - feeding its output into dot
or
a postprocessor - taking dot output and modifying the output
It takes a list of 1 or more cluster names and the dot file name and replaces the named clusters with simple nodes. All nodes and edges that are internal to the listed clusters are deleted.
compressCluster.gvpr can be found here: compressCluster.gvpr - replace a Graphviz cluster (and contents) with a single node · GitHub
A very small example:
This:
Becomes: