def _annotate_bifurcated_extend_data(self, row, smaller, larger, tokenize,
                                         join):
        """Returns `row` annotated with whether it should be deleted or not.

        An n-gram is marked for deletion if:

        * its label count is 1 and its constituent (n-1)-grams also
          have a label count of 1; or

        * there is a containing (n+1)-gram that has the same label
          count.

        :param row: row of witness n-grams to annotate
        :type row: `pandas.Series`
        :param smaller: rows of (n-1)-grams for this witness
        :type smaller: `pandas.DataFrame`
        :param larger: rows of (n+1)-grams for this witness
        :type larger: `pandas.DataFrame`
        :param tokenize: function to tokenize an n-gram
        :param join: function to join tokens
        :rtype: `pandas.Series`

        """
        lcf = constants.LABEL_COUNT_FIELDNAME
        nf = constants.NGRAM_FIELDNAME
        ngram = row[constants.NGRAM_FIELDNAME]
        label_count = row[constants.LABEL_COUNT_FIELDNAME]
        if label_count == 1 and not smaller.empty:
            # Keep a result with a label count of 1 if its
            # constituents do not also have a count of 1.
            ngram_tokens = tokenize(ngram)
            sub_ngram1 = join(ngram_tokens[:-1])
            sub_ngram2 = join(ngram_tokens[1:])
            pattern = FilteredWitnessText.get_filter_ngrams_pattern(
                [sub_ngram1, sub_ngram2])
            if smaller[smaller[constants.NGRAM_FIELDNAME].str.match(pattern)][
                    constants.LABEL_COUNT_FIELDNAME].max() == 1:
                row[DELETE_FIELDNAME] = True
        elif not larger.empty and larger[larger[nf].str.contains(
                ngram, regex=False)][lcf].max() == label_count:
            # Remove a result if the label count of a containing
            # n-gram is equal to its label count.
            row[DELETE_FIELDNAME] = True
        return row
Returns `row` annotated with whether it should be deleted or not.

        An n-gram is marked for deletion if:

        * its label count is 1 and its constituent (n-1)-grams also
          have a label count of 1; or

        * there is a containing (n+1)-gram that has the same label
          count.

        :param row: row of witness n-grams to annotate
        :type row: `pandas.Series`
        :param smaller: rows of (n-1)-grams for this witness
        :type smaller: `pandas.DataFrame`
        :param larger: rows of (n+1)-grams for this witness
        :type larger: `pandas.DataFrame`
        :param tokenize: function to tokenize an n-gram
        :param join: function to join tokens
        :rtype: `pandas.Series`