diff --git a/spacy/sv/language_data.py b/spacy/sv/language_data.py index a4a657c33..324351d06 100644 --- a/spacy/sv/language_data.py +++ b/spacy/sv/language_data.py @@ -5,12 +5,14 @@ from .. import language_data as base from ..language_data import update_exc, strings_to_exc from .stop_words import STOP_WORDS +from .tokenizer_exceptions import TOKENIZER_EXCEPTIONS, ORTH_ONLY STOP_WORDS = set(STOP_WORDS) - -TOKENIZER_EXCEPTIONS = strings_to_exc(base.EMOTICONS) +TOKENIZER_EXCEPTIONS = dict(TOKENIZER_EXCEPTIONS) +update_exc(TOKENIZER_EXCEPTIONS, strings_to_exc(ORTH_ONLY)) +update_exc(TOKENIZER_EXCEPTIONS, strings_to_exc(base.EMOTICONS)) update_exc(TOKENIZER_EXCEPTIONS, strings_to_exc(base.ABBREVIATIONS)) diff --git a/spacy/sv/tokenizer_exceptions.py b/spacy/sv/tokenizer_exceptions.py index d8d4e8823..b9705c39c 100644 --- a/spacy/sv/tokenizer_exceptions.py +++ b/spacy/sv/tokenizer_exceptions.py @@ -107,7 +107,6 @@ ORTH_ONLY = [ "p.g.a.", "ref.", "resp.", - "s.", "s.a.s.", "s.k.", "st.",