Adds documentation for the interaction graph interface.
Initial in situ refactoring of the pruning method.
Second level of refactoring of the pruning, removing main logic from the graph objects.