Upd parser

This commit is contained in:
Matthew Honnibal 2021-01-25 19:17:41 +11:00
parent af0b3bc4d8
commit 70bcc1f48e

View File

@ -604,6 +604,8 @@ cdef class Parser(TrainablePipe):
for state, eg, history in zip(all_states, examples, oracle_histories):
if not history:
continue
if not self.moves.has_gold(eg):
continue
gold = self.moves.init_gold(state, eg)
if len(history) < max_length:
states.append(state)