Hello everyone, have you encountered the problem of entity nesting? For example: Where is Peking University? I have defined the entity location and school, how do I label it? [Peking University] Where is (school)? Where is [Beijing大学](school)?
You can read more about entity annotations here.
The university example should be rewritten:
Where is [Peking University](school)?
Let me know if you run into any specific errors?
@anca Hi, This query and question are tricky and even I’m also a bit confused.
Where is Beijing大学? as stated
Now, this Beijing also lies as location and Beijing also lies as a school. If the use case demands both then how do we annotate such scenarios?
Where is [Beijing大学](school)? or
Where is [Beijing大学](location)?
Or I overthink this query, I can be totally wrong on this apologies in advance.
can you please share some more examples, do you required both location and school entities in same intent example as you mentioned in the query? and If I can ask what is your project is all about? Thanks.
I am glad to discuss this issue with you! I recently considered using rasa to extract some entities. The initial consideration is to implement the labeling of nlu, but the problem of nesting of different entities is often encountered when labeling. E.g: “It’s good to listen to Lao Tan telling stories at night, and it will be broadcast on Hangzhou News Radio” Among them, “Lao Tan tells stories” is marked as broadcast. “Lao Tan” is marked as a radio host. I don’t know if I should consider finding other entity extraction methods, and I’m waiting for your good news.
hi @suckseed5 Nested entity annotations as you just described in your
radio host example are not currently supported by Rasa, we might add support for this at a later date.
@nik202 Your case is best handled by entity roles, e.g.
location_or_school entity with roles
school - training examples will need to be provided for both cases, as well as for when no role should be assigned.
@anca many thanks for the clarity luckily I never encountered such use case, but good to know.