spaCy/spacy/tests/doc
adrianeboyd 3d2c308906
Add Doc init from list of words and text (#5251)
* Add Doc init from list of words and text

Add an option to initialize a `Doc` from a text and list of words where
the words may or may not include all whitespace tokens. If the text and
words are mismatched, raise an error.

* Fix error code

* Remove all whitespace before aligning words/text

* Move words/text init to util function

* Update error message

* Rename to get_words_and_spaces

* Fix formatting
2020-04-14 19:15:52 +02:00
..
__init__.py Revert #4334 2019-09-29 17:32:12 +02:00
test_add_entities.py Fix test imports 2019-09-29 17:34:56 +02:00
test_array.py Tidy up and auto-format 2020-03-25 12:28:12 +01:00
test_creation.py Add Doc init from list of words and text (#5251) 2020-04-14 19:15:52 +02:00
test_doc_api.py Bugfix/get doc (#5049) 2020-03-02 11:49:28 +01:00
test_morphanalysis.py Revert #4334 2019-09-29 17:32:12 +02:00
test_pickle_doc.py Revert #4334 2019-09-29 17:32:12 +02:00
test_retokenize_merge.py Skip duplicate spans in Doc.retokenize (#4339) 2019-09-30 12:43:48 +02:00
test_retokenize_split.py Fix realloc in retokenizer.split() (#4606) 2019-11-11 16:26:46 +01:00
test_span.py Sync Span __eq__ and __hash__ (#5005) 2020-02-16 17:20:36 +01:00
test_to_json.py Revert #4334 2019-09-29 17:32:12 +02:00
test_token_api.py Improve token head verification (#5079) 2020-03-03 21:44:51 +01:00
test_underscore.py use clean_underscore fixture 2020-02-23 15:49:20 +01:00