spaCy/spacy/tests/doc
Adriane Boyd d5bbd1f94f
Handle partial entities in Span.as_doc (#8055)
* Handle partial entities in Span.as_doc

In `Span.as_doc` replace partial entities at the beginning or end of the
span with missing entity annotation.

Fixes a bug where invalid entity annotation (no initial `B`) was
returned for an initial partial entity.

* Check for empty span in ents conversion

Note: `Span.as_doc()` will still fail on an empty span due to failures
in `Span.vector`.
2021-05-11 17:10:16 +02:00
..
__init__.py Revert #4334 2019-09-29 17:32:12 +02:00
test_add_entities.py begin_training -> initialize 2020-09-28 21:35:09 +02:00
test_array.py introduce token.has_head and refer to MISSING_DEP_ (WIP) 2021-01-12 17:17:06 +01:00
test_creation.py Add Lemmatizer and simplify related components (#5848) 2020-08-07 15:27:13 +02:00
test_doc_api.py Fix Docs.from_docs for all empty docs (#8009) 2021-05-05 18:44:14 +02:00
test_graph.py Tidy up and auto-format 2021-01-15 11:57:36 +11:00
test_morphanalysis.py Tidy up and auto-format 2020-10-03 17:20:18 +02:00
test_pickle_doc.py Drop Python 2.7 and 3.5 (#4828) 2019-12-22 01:53:56 +01:00
test_retokenize_merge.py Keep sent starts without parse in retokenization (#7424) 2021-03-29 22:32:00 +11:00
test_retokenize_split.py introduce token.has_head and refer to MISSING_DEP_ (WIP) 2021-01-12 17:17:06 +01:00
test_span.py Handle partial entities in Span.as_doc (#8055) 2021-05-11 17:10:16 +02:00
test_to_json.py Fix morph in Doc.to_json 2020-10-08 14:44:35 +02:00
test_token_api.py Tidy up and auto-format 2021-01-15 11:57:36 +11:00
test_underscore.py Merge branch 'master' into tmp/sync 2020-03-26 13:38:14 +01:00