      cpdef int train(self, Tokens tokens, gold_classes):
          cdef Pool mem = Pool()
          cdef State* s = init_state(mem, tokens.length)
          cdef Move* golds = <Move*>mem.alloc(len(gold_classes), sizeof(Move))
          for i, clas in enumerate(gold_classes):
              golds[i] = self.moves[clas - 1]
              assert golds[i].id == clas
          cdef Move* guess
          while s.i < tokens.length:
              fill_context(self._context, s.i, tokens)
              self.extractor.extract(self._feats, self._values, self._context, NULL)
              self.model.score(self._scores, self._feats, self._values)
 
</s> remove     cpdef int train(self, Tokens tokens, gold_classes):
 </s> add     cpdef int train(self, Tokens tokens, gold_classes) except -1: </s> remove     cpdef int train(self, Tokens tokens, golds)
 </s> add     cpdef int train(self, Tokens tokens, golds) except -1 </s> remove     cdef weight_t score = scores[first_accept]
 </s> add     cdef weight_t score = scores[first_accept-1]
        for tok_i, clas in enumerate(gold_classes):
            golds[tok_i] = self._moves[clas]
            assert golds[tok_i].clas == clas, '%d vs %d' % (golds[tok_i].clas, clas)
      cpdef int train(self, Tokens tokens, gold_classes):
          cdef Pool mem = Pool()
          cdef State* s = init_state(mem, tokens.length)
          cdef Move* golds = <Move*>mem.alloc(len(gold_classes), sizeof(Move))
        for tok_i, clas in enumerate(gold_classes):
            golds[tok_i] = self._moves[clas]
            assert golds[tok_i].clas == clas, '%d vs %d' % (golds[tok_i].clas, clas)
        for tok_i, clas in enumerate(gold_classes):
            golds[tok_i] = self._moves[clas]
            assert golds[tok_i].clas == clas, '%d vs %d' % (golds[tok_i].clas, clas)
        for tok_i, clas in enumerate(gold_classes):
            golds[tok_i] = self._moves[clas]
            assert golds[tok_i].clas == clas, '%d vs %d' % (golds[tok_i].clas, clas)
          cdef Move* guess
          while s.i < tokens.length:
              fill_context(self._context, s.i, tokens)
              self.extractor.extract(self._feats, self._values, self._context, NULL)
              self.model.score(self._scores, self._feats, self._values)
keep keep keep keep replace replace replace keep keep keep keep keep
 * Fixed greedy NER parsing. With static oracle, replicates accuracy from tagger. 
spacy/ner/greedy_parser.pyx