def testMatchingSentencesWithRepetitions(self):
    """Token frequencies should not matter if we only consider unigrams."""
    input_sentence = [3, 1, 4]
    output = [3, 3, 1, 1, 1, 4]
    references = [[3, 3, 3, 1, 1, 4, 4]]
    score, _, _, _ = sari_hook.get_sari_score(input_sentence, output,
                                              references, max_gram_size=1)
    self.assertEqual(1, score)
Token frequencies should not matter if we only consider unigrams.
tensor2tensor/utils/sari_hook_test.py