spaCy/spacy/es/tokenizer_exceptions.py

84 lines
1.3 KiB
Python
Raw Normal View History

2017-03-12 15:07:28 +03:00
# coding: utf8
2016-12-18 18:54:19 +03:00
from __future__ import unicode_literals
from ..symbols import *
from ..language_data import PRON_LEMMA, DET_LEMMA
2016-12-18 18:54:19 +03:00
TOKENIZER_EXCEPTIONS = {
"pal": [
{ORTH: "pa", LEMMA: "para"},
2017-06-02 20:00:01 +03:00
{ORTH: "l", LEMMA: DET_LEMMA, NORM: "el"}
2016-12-18 18:54:19 +03:00
],
"pala": [
{ORTH: "pa", LEMMA: "para"},
{ORTH: "la", LEMMA: DET_LEMMA, NORM: "la"}
],
"aprox.": [
{ORTH: "aprox.", LEMMA: "aproximadamente"}
],
"dna.": [
{ORTH: "dna.", LEMMA: "docena"}
],
"esq.": [
{ORTH: "esq.", LEMMA: "esquina"}
],
"pág.": [
{ORTH: "pág.", LEMMA: "página"}
],
"p.ej.": [
{ORTH: "p.ej.", LEMMA: "por ejemplo"}
],
"Ud.": [
{ORTH: "Ud.", LEMMA: PRON_LEMMA, NORM: "usted"}
],
"Vd.": [
{ORTH: "Vd.", LEMMA: PRON_LEMMA, NORM: "usted"}
],
"Uds.": [
{ORTH: "Uds.", LEMMA: PRON_LEMMA, NORM: "ustedes"}
],
"Vds.": [
{ORTH: "Vds.", LEMMA: PRON_LEMMA, NORM: "ustedes"}
2016-12-18 18:54:19 +03:00
]
}
ORTH_ONLY = [
"a.C.",
"a.J.C.",
"apdo.",
"Av.",
"Avda.",
"Cía.",
"etc.",
"Gob.",
"Gral.",
"Ing.",
"J.C.",
"Lic.",
"m.n.",
"no.",
"núm.",
"P.D.",
"Prof.",
"Profa.",
"q.e.p.d."
"S.A.",
"S.L.",
"s.s.s.",
"Sr.",
"Sra.",
"Srta."
2016-12-18 18:54:19 +03:00
]