Raphael Mitsch
28dbed64cb
Update alias/mention usage in doc(strings).
2023-03-14 13:33:05 +01:00
Raphael Mitsch
be858981e6
Update docstrings related to prior_prob.
2023-03-13 17:01:20 +01:00
Raphael Mitsch
4a921766f1
Remove prior_prob from supported properties in Candidate. Introduce KnowledgeBase.supports_prior_probs().
2023-03-13 16:54:38 +01:00
Raphael Mitsch
6adc15178f
Partially fix alias/mention terminology usage. Convert Candidate to interface.
2023-03-13 14:26:14 +01:00
Raphael Mitsch
649c146e2c
Move attributes out of Candidate.
2023-03-13 09:21:08 +01:00
Raphael Mitsch
ce23942320
Merge branch 'refactor/el-candidates' of github.com:rmitsch/spaCy into refactor/el-candidates
2023-03-10 09:04:10 +01:00
Raphael Mitsch
348dd1c87e
Update docstrings.
2023-03-10 09:03:41 +01:00
Raphael Mitsch
27053912da
Drop unused InMemoryCandidate._entity_hash.
2023-03-10 09:00:30 +01:00
Raphael Mitsch
6fc7997c06
Fix entity_id refactoring problems in docstrings.
2023-03-10 08:55:32 +01:00
Raphael Mitsch
34e092e4e5
Update spacy/kb/candidate.pxd
...
Co-authored-by: Sofie Van Landeghem <svlandeg@users.noreply.github.com>
2023-03-09 16:15:39 +01:00
Raphael Mitsch
c61654eef8
Drop storing mention.
2023-03-09 15:04:10 +01:00
Raphael Mitsch
b0ee34185d
Add abstract class check.
2023-03-09 14:56:44 +01:00
Raphael Mitsch
b476041417
Port Candidate and InMemoryCandidate to Cython.
2023-03-09 14:44:41 +01:00
Raphael Mitsch
1c937db3af
Rename 'alias' to 'mention'.
2023-03-09 12:06:15 +01:00
Raphael Mitsch
cea58ade89
Simplify interface for int/str representations.
2023-03-07 14:35:38 +01:00
Raphael Mitsch
f8a02f7fef
Updated error code.
2023-03-07 13:58:42 +01:00
Raphael Mitsch
082992aebb
Update spacy/kb/candidate.py
...
Co-authored-by: Sofie Van Landeghem <svlandeg@users.noreply.github.com>
2023-03-07 13:54:11 +01:00
Raphael Mitsch
8dbb74c9c0
Merge branch 'v4' into refactor/el-candidates
2023-03-07 09:06:51 +01:00
Raphael Mitsch
2ac586fdb5
Update error code in line with v4 convention.
2023-03-05 14:43:32 +01:00
Raphael Mitsch
670e1ca7c5
Fix mypy error.
2023-03-05 14:33:32 +01:00
Raphael Mitsch
5f40b3e523
Format.
2023-03-05 14:14:16 +01:00
Raphael Mitsch
38dce966e5
Refacor Candidate attributes and their usage.
2023-03-05 13:49:13 +01:00
Raphael Mitsch
94e57d0ed5
Refactor Candidate attribute names. Update docs and tests accordingly.
2023-03-03 11:08:17 +01:00
Raphael Mitsch
46fe069f87
Rename alias -> mention.
2023-03-03 10:29:53 +01:00
Raphael Mitsch
9bd498cdae
Fix docstring and docs.
2023-03-01 15:09:24 +01:00
Raphael Mitsch
257bca3959
Format.
2023-03-01 14:54:03 +01:00
Raphael Mitsch
fa390618c8
Adjust Candidate to support and mandate numerical entity IDs.
2023-03-01 14:50:58 +01:00
Raphael Mitsch
49abf4fb3a
Rename Candidate to InMemoryCandidate, BaseCandidate to Candidate.
2023-03-01 14:27:50 +01:00
Raphael Mitsch
417e8fea8b
Update spacy/kb/candidate.py
...
Co-authored-by: Sofie Van Landeghem <svlandeg@users.noreply.github.com>
2023-03-01 13:51:33 +01:00
Raphael Mitsch
21fa22de08
Merge branch 'refactor/el-candidates' of github.com:rmitsch/spaCy into refactor/el-candidates
2023-03-01 13:48:46 +01:00
Raphael Mitsch
3da0712582
Update doc string of BaseCandidate.__init__().
2023-03-01 13:15:38 +01:00
Raphael Mitsch
0680958476
Update spacy/kb/candidate.py
...
Co-authored-by: Sofie Van Landeghem <svlandeg@users.noreply.github.com>
2023-03-01 12:42:08 +01:00
Sofie Van Landeghem
74cae47bf6
rely on is_empty property instead of __len__ ( #12347 )
2023-03-01 12:06:07 +01:00
Raphael Mitsch
cd98ab4e95
Convert Candidate from Cython to Python class.
2023-02-28 13:49:52 +01:00
Adriane Boyd
3b8918e166
API docs: Rename kb_in_memory to inmemorylookupkb, add to sidebar ( #12128 )
...
* API docs: Rename kb_in_memory to inmemorylookupkb, add to sidebar
* adjust to mdx
* linkout to InMemoryLookupKB at first occurrence in kb.mdx
* fix links to docs
* revert Azure trigger setting (I'll make a separate PR)
Co-authored-by: svlandeg <svlandeg@github.com>
2023-01-19 13:29:17 +01:00
Raphael Mitsch
1f23c615d7
Refactor KB for easier customization ( #11268 )
...
* Add implementation of batching + backwards compatibility fixes. Tests indicate issue with batch disambiguation for custom singular entity lookups.
* Fix tests. Add distinction w.r.t. batch size.
* Remove redundant and add new comments.
* Adjust comments. Fix variable naming in EL prediction.
* Fix mypy errors.
* Remove KB entity type config option. Change return types of candidate retrieval functions to Iterable from Iterator. Fix various other issues.
* Update spacy/pipeline/entity_linker.py
Co-authored-by: Paul O'Leary McCann <polm@dampfkraft.com>
* Update spacy/pipeline/entity_linker.py
Co-authored-by: Paul O'Leary McCann <polm@dampfkraft.com>
* Update spacy/kb_base.pyx
Co-authored-by: Paul O'Leary McCann <polm@dampfkraft.com>
* Update spacy/kb_base.pyx
Co-authored-by: Paul O'Leary McCann <polm@dampfkraft.com>
* Update spacy/pipeline/entity_linker.py
Co-authored-by: Paul O'Leary McCann <polm@dampfkraft.com>
* Add error messages to NotImplementedErrors. Remove redundant comment.
* Fix imports.
* Remove redundant comments.
* Rename KnowledgeBase to InMemoryLookupKB and BaseKnowledgeBase to KnowledgeBase.
* Fix tests.
* Update spacy/errors.py
Co-authored-by: Sofie Van Landeghem <svlandeg@users.noreply.github.com>
* Move KB into subdirectory.
* Adjust imports after KB move to dedicated subdirectory.
* Fix config imports.
* Move Candidate + retrieval functions to separate module. Fix other, small issues.
* Fix docstrings and error message w.r.t. class names. Fix typing for candidate retrieval functions.
* Update spacy/kb/kb_in_memory.pyx
Co-authored-by: Sofie Van Landeghem <svlandeg@users.noreply.github.com>
* Update spacy/ml/models/entity_linker.py
Co-authored-by: Sofie Van Landeghem <svlandeg@users.noreply.github.com>
* Fix typing.
* Change typing of mentions to be Span instead of Union[Span, str].
* Update docs.
* Update EntityLinker and _architecture docs.
* Update website/docs/api/entitylinker.md
Co-authored-by: Paul O'Leary McCann <polm@dampfkraft.com>
* Adjust message for E1046.
* Re-add section for Candidate in kb.md, add reference to dedicated page.
* Update docs and docstrings.
* Re-add section + reference for KnowledgeBase.get_alias_candidates() in docs.
* Update spacy/kb/candidate.pyx
* Update spacy/kb/kb_in_memory.pyx
* Update spacy/pipeline/legacy/entity_linker.py
* Remove canididate.md. Remove mistakenly added config snippet in entity_linker.py.
Co-authored-by: Paul O'Leary McCann <polm@dampfkraft.com>
Co-authored-by: Sofie Van Landeghem <svlandeg@users.noreply.github.com>
2022-09-08 10:38:07 +02:00