mirror of
https://github.com/explosion/spaCy.git
synced 2025-01-26 01:04:34 +03:00
Fix conllu2json n_sents and raw text (#4728)
Update conllu2json converter to include raw text in final batch.
This commit is contained in:
parent
79ba1a3b92
commit
68f711b409
|
@ -42,7 +42,7 @@ def conllu2json(input_data, n_sents=10, use_morphology=False, lang=None, **_):
|
||||||
raw = ""
|
raw = ""
|
||||||
sentences = []
|
sentences = []
|
||||||
if sentences:
|
if sentences:
|
||||||
doc = create_doc(sentences, i)
|
doc = create_doc(raw, sentences, i)
|
||||||
docs.append(doc)
|
docs.append(doc)
|
||||||
return docs
|
return docs
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user