Let nlp.update handles Doc type inputs.
@@ -85,6 +85,7 @@ class TransformersLanguage(Language):
if isinstance(doc, str):
doc = self.make_doc(doc)
doc = sentencizer(doc)
+ if doc._.get(ATTRS.word_pieces) is None:
doc = wp(doc)
if not isinstance(gold, GoldParse):
gold = GoldParse(doc, **gold)
