Does rel_component take into account the tokens between the entities in a relationship, and their wider context in the document? #13857
Unanswered
jjsmclaughlin
asked this question in
Help: Model Advice
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hi! :) I have been experimenting with the rel_component tutorial (https://github.com/explosion/projects/tree/v3/tutorials/rel_component) and I have a question which I couldn't quite figure out from the docs and blog post:
Does rel_component take into account the tokens between the entities in a relationship, and their wider context in the document?
I ask because the docs and blog post suggest that only the tokens from the entities themselves are added to the tensor which is evaluated for each relationship. Also in my own tests I find that the rel_extractor has trouble determining which entities should be related to which if there are multiple instances of the same type of relationship in a document.
For example, in:
Tim smith resides in Hove, Rebecca Jones is from Watford.
Where the gold relationships are:
Tim Smith -> Hove (label: LIVES_IN)
Rebecca Jones -> Watford (label: LIVES_IN)
rel_extractor will always predict that both people LIVE_IN both places. I don't seem able to make it predict correctly in such cases. I have tried increasing the number of training examples, and even naively fiddling with the rel_component code to forcibly append the connecting tokens to the tokens which are evaluated, but (predictably, since I don't really know what I'm doing) rather than helping, this harms the results.
Am I expecting rel_component to do something it isn't designed to do?
Beta Was this translation helpful? Give feedback.
All reactions