question: public Stream < InteractionWord > process ( List < PatternReference > patterns ) { final Set < Word > terms = gatherTerms ( patterns ) ; monitor . info ( "Gathered {} terms" , terms . size ( ) ) ; calculateTermFrequencies ( patterns , terms ) ; monitor . info ( "Calculated frequencies" ) ; sort ( patterns ) ; monitor . info ( "Sorted patterns by frequency" ) ; final List < ClusteredPatterns > clusters = cluster ( patterns ) ; monitor . info ( "Patterns clustered into {} clusters" , clusters . size ( ) ) ; filterClusters ( clusters ) ; monitor . info ( "Patterns filtered to {} clusters" , clusters . size ( ) ) ; monitor . info ( "Finding interaction words" ) ; return extractInteractionWords ( clusters ) ; }
target:  Process the pattern references and extract the list of distinct interaction words.