Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add entity linking task #241

Merged
merged 105 commits into from
Nov 16, 2023
Merged

Add entity linking task #241

merged 105 commits into from
Nov 16, 2023

Conversation

rmitsch
Copy link
Collaborator

@rmitsch rmitsch commented Aug 3, 2023

Description

Add entity linking task.

Corresponding documentation PR

explosion/spaCy#12988

Types of change

Checklist

  • I confirm that I have the right to submit this contribution under the project's MIT license.
  • I ran all tests in tests and usage_examples/tests, and all new and existing tests passed. This includes
    • all external tests (i. e. pytest ran with --external)
    • all tests requiring a GPU (i. e. pytest ran with --gpu)
  • My changes don't require a change to the documentation, or if they do, I've added all required information.

@rmitsch rmitsch added feat/new New feature tests Everything related to the test suite feat/task Feature: tasks labels Aug 3, 2023
@rmitsch rmitsch self-assigned this Aug 3, 2023
@rmitsch rmitsch changed the base branch from main to develop August 3, 2023 11:44
Copy link
Member

@svlandeg svlandeg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This will be great to have :-)

I have yet to play around with it more and I haven't reviewed the unit tests yet, but I figured I'd already send my first batch of review comments.

rmitsch added 11 commits August 22, 2023 09:41
# Conflicts:
#	.github/workflows/test_gpu.yml
#	spacy_llm/tasks/__init__.py
#	spacy_llm/tasks/builtin_task.py
#	spacy_llm/tasks/lemma/registry.py
#	spacy_llm/tasks/lemma/util.py
#	spacy_llm/tasks/ner/registry.py
#	spacy_llm/tasks/ner/util.py
#	spacy_llm/tasks/rel/registry.py
#	spacy_llm/tasks/rel/util.py
#	spacy_llm/tasks/sentiment/registry.py
#	spacy_llm/tasks/sentiment/util.py
#	spacy_llm/tasks/spancat/registry.py
#	spacy_llm/tasks/spancat/util.py
#	spacy_llm/tasks/summarization/registry.py
#	spacy_llm/tasks/summarization/util.py
#	spacy_llm/tasks/textcat/registry.py
#	spacy_llm/tasks/textcat/util.py
#	spacy_llm/ty.py
Copy link
Member

@svlandeg svlandeg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think the recent refactors have really improved the usability of this feature :-)

I'm not done reviewing yet, but need to break here for a bit, so sending my first batch of comments/suggestions.

Co-authored-by: Sofie Van Landeghem <[email protected]>
Copy link
Member

@svlandeg svlandeg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looking really good! This now works nicely with the NIL option, and the unit tests look great. I was able to get it to output different identifiers for the city of New York, the state, or using the string "New York" in a totally different context - it outputted NIL in that case. Nice!

Comments are only nitpicks.

One final issue to discuss is how to best support in-code experimenting with nlp.add_pipe("llm_entitylinker") and to add a unit test for that, too.

@rmitsch rmitsch removed the Test external Run external tests label Nov 14, 2023
@rmitsch rmitsch added the Test external Run external tests label Nov 14, 2023
@rmitsch
Copy link
Collaborator Author

rmitsch commented Nov 14, 2023

One final issue to discuss is how to best support in-code experimenting with nlp.add_pipe("llm_entitylinker") and to add a unit test for that, too.

Added a unit test in a631278.

Copy link
Member

@svlandeg svlandeg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great! Let's get this merged 🎉

@svlandeg svlandeg merged commit ea471bb into develop Nov 16, 2023
@svlandeg svlandeg deleted the feat/el branch November 16, 2023 21:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feat/new New feature feat/task Feature: tasks Test external Run external tests tests Everything related to the test suite
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants