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

Option to return the flair entity types in the response body #4

Closed
chriskamphuis opened this issue Mar 6, 2020 · 3 comments
Closed
Assignees

Comments

@chriskamphuis
Copy link
Contributor

chriskamphuis commented Mar 6, 2020

FLAIR labels the detected mentions with an entity type. We could return these "for free", instead of requiring an extra join against DBPedia / Wikidata.

@KDercksen
Copy link
Contributor

If the API is still compatible with Gerbil while returning extra fields in the response, I would just make this the default to be honest. No reason to make this optional when the entity type is available anyway, at least in the case where the default NER from Flair is being used. I suppose a custom NER model might only do mention detection without types, but even in that case we could just return a standard ENTITY type or something similar.

I could add this if @hasibi / @mickvanhulst agree (and can tell me if extra fields matter for Gerbil)?

@mickvanhulst
Copy link
Collaborator

I would agree with this.

Next to changing the fields in our Python code, we would also need to change the Gerbil middleware. At the moment this is expecting a certain JSON response, so if we can make it so that it ignores the remainder of the unnecessary fields, we are already there :).

Would be nice if you could work on this @KDercksen !

@KDercksen
Copy link
Contributor

I don't have rights to close the issue myself, but I think this is done :)

arjenpdevries added a commit that referenced this issue Mar 11, 2020
add entity tag info to response (see #4)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants