mirror of
https://github.com/explosion/spaCy.git
synced 2024-12-25 17:36:30 +03:00
Move EnglishDefaults class out of English
This commit is contained in:
parent
a1ba20e2b1
commit
61fe55efba
|
@ -15,10 +15,7 @@ from ...attrs import LANG
|
|||
from ...util import update_exc
|
||||
|
||||
|
||||
class English(Language):
|
||||
lang = 'en'
|
||||
|
||||
class Defaults(Language.Defaults):
|
||||
class EnglishDefaults(Language.Defaults):
|
||||
lex_attr_getters = dict(Language.Defaults.lex_attr_getters)
|
||||
lex_attr_getters[LANG] = lambda text: 'en'
|
||||
lex_attr_getters.update(LEX_ATTRS)
|
||||
|
@ -33,4 +30,10 @@ class English(Language):
|
|||
sytax_iterators = dict(SYNTAX_ITERATORS)
|
||||
|
||||
|
||||
__all__ = ['English']
|
||||
class English(Language):
|
||||
lang = 'en'
|
||||
|
||||
Defaults = EnglishDefaults
|
||||
|
||||
|
||||
__all__ = ['English', 'EnglishDefaults']
|
||||
|
|
Loading…
Reference in New Issue
Block a user