diff --git a/tests/pipelines/test_pipelines_token_classification.py b/tests/pipelines/test_pipelines_token_classification.py index 1d71529cdfee..bc4eaef06255 100644 --- a/tests/pipelines/test_pipelines_token_classification.py +++ b/tests/pipelines/test_pipelines_token_classification.py @@ -284,9 +284,9 @@ def test_dbmdz_english(self): self.assertEqual( nested_simplify(output), [ - {"entity": "I-PER", "score": 0.997, "word": "En", "start": 0, "end": 2, "index": 1}, - {"entity": "I-PER", "score": 0.996, "word": "##zo", "start": 2, "end": 4, "index": 2}, - {"entity": "I-ORG", "score": 0.999, "word": "UN", "start": 22, "end": 24, "index": 7}, + {"entity": "I-PER", "score": 0.998, "word": "En", "start": 0, "end": 2, "index": 1}, + {"entity": "I-PER", "score": 0.997, "word": "##zo", "start": 2, "end": 4, "index": 2}, + {"entity": "I-ORG", "score": 0.999, "word": "UN", "start": 18, "end": 20, "index": 6}, ], ) @@ -295,8 +295,8 @@ def test_dbmdz_english(self): self.assertEqual( nested_simplify(output), [ - {"entity_group": "PER", "score": 0.996, "word": "Enzo", "start": 0, "end": 4}, - {"entity_group": "ORG", "score": 0.999, "word": "UN", "start": 22, "end": 24}, + {"entity_group": "PER", "score": 0.997, "word": "Enzo", "start": 0, "end": 4}, + {"entity_group": "ORG", "score": 0.999, "word": "UN", "start": 18, "end": 20}, ], ) @@ -305,8 +305,8 @@ def test_dbmdz_english(self): self.assertEqual( nested_simplify(output[:3]), [ - {"entity_group": "PER", "score": 0.997, "word": "Enzo", "start": 0, "end": 4}, - {"entity_group": "ORG", "score": 0.999, "word": "UN", "start": 22, "end": 24}, + {"entity_group": "PER", "score": 0.998, "word": "Enzo", "start": 0, "end": 4}, + {"entity_group": "ORG", "score": 0.999, "word": "UN", "start": 18, "end": 20}, ], ) @@ -315,8 +315,8 @@ def test_dbmdz_english(self): self.assertEqual( nested_simplify(output[:3]), [ - {"entity_group": "PER", "score": 0.997, "word": "Enzo", "start": 0, "end": 4}, - {"entity_group": "ORG", "score": 0.999, "word": "UN", "start": 22, "end": 24}, + {"entity_group": "PER", "score": 0.998, "word": "Enzo", "start": 0, "end": 4}, + {"entity_group": "ORG", "score": 0.999, "word": "UN", "start": 18, "end": 20}, ], ) @@ -325,8 +325,8 @@ def test_dbmdz_english(self): self.assertEqual( nested_simplify(output), [ - {"entity_group": "PER", "score": 0.996, "word": "Enzo", "start": 0, "end": 4}, - {"entity_group": "ORG", "score": 0.999, "word": "UN", "start": 22, "end": 24}, + {"entity_group": "PER", "score": 0.997, "word": "Enzo", "start": 0, "end": 4}, + {"entity_group": "ORG", "score": 0.999, "word": "UN", "start": 18, "end": 20}, ], )