def degree_max_repetition(recpat_bag:list):
    """
    Computes the degree of maximal repetition from a bag of
    recurring patterns -- a list of ngram tuples.
    """
    return max([len(recpat) for recpat in recpat_bag])