
    h
                     B    S SK JrJr  SSKJr  SSKJr   " S S\5      rg)    )ListTuple   )
Lemmatizer)Tokenc                      ^  \ rS rSr\S\S\\\   \\   4   4U 4S jj5       rS\	S\\   4S jr
S\	S\\   4S jrSrU =r$ )	DutchLemmatizer   modereturnc                 >   > US:X  a  / SQnU/ 4$ [         TU ]  U5      $ )Nrule)lemma_lookuplemma_rules	lemma_exclemma_index)superget_lookups_config)clsr   required	__class__s      R/home/james-whalen/.local/lib/python3.13/site-packages/spacy/lang/nl/lemmatizer.pyr   "DutchLemmatizer.get_lookups_config   s)    6>RHb>!7-d33    tokenc                     U R                   R                  S0 5      nUR                  R                  5       nUR	                  X35      /$ )zOverrides parent method so that a lowercased version of the string
is used to search the lookup table. This is necessary because our
lookup table consists entirely of lowercase keys.r   )lookups	get_tabletextlowerget)selfr   lookup_tablestrings       r   lookup_lemmatize DutchLemmatizer.lookup_lemmatize   s@     ||--nbA!!#  011r   c                 p   UR                   UR                  4nX R                  ;   a  U R                  U   $ UR                  nUR                  R                  5       nUS;   a!  UR                  5       /nXPR                  U'   U$ U R
                  R                  S0 5      nU R
                  R                  S0 5      nU R
                  R                  S0 5      nUR                  U0 5      n	UR                  U0 5      n
UR                  U0 5      nUR                  5       nUS;  a  U/nXPR                  U'   U$ UR                  U0 5      nX<;   a  U/nXPR                  U'   U$ U R
                  R                  S0 5      nUR                  U0 5      n
 X   S   /nXPR                  U'   U$ ! [         a     Of = fU R
                  R                  S0 5      nUR                  U5      nU(       a  X;   a  U/nXPR                  U'   U$ U R
                  R                  S0 5      n/ nU Hp  u  nnUR                  U5      (       d  M  US [        U5      [        U5      -
   U-   nU(       d  MD  UU	;   a  U/nXPR                  U'   Us  $ UR                  U5        Mr     [        [        R                  U5      5      nU(       aN  U H  nUU
;   d  M  U/nXPR                  U'   Us  $    U(       a  U/nXPR                  U'   U$ XPR                  U'   U$ U(       a  U/nXPR                  U'   U$ U/nXPR                  U'   U$ )N) eolspacer   r   r   )	nounverbauxadjadvprondetadpnumr   r   )r    poscacher   pos_r   r   r!   KeyErrorendswithlenappendlistdictfromkeys)r"   r   	cache_keyr$   univ_posformsindex_table	exc_tablerules_tableindex
exceptionsrulesr   r#   looked_up_lemma	oov_formsoldnewforms                      r   rule_lemmatizeDutchLemmatizer.rule_lemmatize   s    [[%)),	

"::i((::##%++\\^$E$)JJy!Lll,,]B?LL**;;	ll,,]B?"-]]8R0
"- 

 

 HE$)JJy!L!ooh3 HE$)JJy!LLL**;;	]]8R0
	'*+E$)JJy!L 		 ||--nbA&**62=$%E$)JJy!Lll,,]B?	HCs##6Fc#h 67#=U]!FE,1JJy) L$$T*  T]]9-.:%!FE,1JJy) L	 
 ()(-

9%(-

9%$%E$)JJy!LHE$)JJy!Ls   F( (
F54F5 )__name__
__module____qualname____firstlineno__classmethodstrr   r   r   r   r%   rL   __static_attributes____classcell__)r   s   @r   r	   r	      sl    4c 4eDItCy4H.I 4 42e 2S	 2aE ad3i a ar   r	   N)typingr   r   pipeliner   tokensr   r	   rN   r   r   <module>rZ      s     " sj sr   