BeWe11 / rasa_composite_entities

A Rasa NLU component for composite entities.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Add support for nested composites

BeWe11 opened this issue · comments

It would be nice if shorter composites could be included in larger ones in some way.

Example:

I am looking for brown shoes with red stripes

This sentence might contains the entities @color = brown, @article = shoe, @color = red and @pattern = stripes.

A user might define the composite entities @product = @color @article and @appearance = @color @pattern.

I can think of two ways in which a user might want to further group these entities:

  1. A user might define a composite entity referencing other composite entities: @product = @article @appearance. This is currently not implemented. Right now, composite entities only consider base entities.
  2. A user might define a composite entity referencing base entities: @product = @color @article @color @pattern. The user might then want the sub-entities to be grouped again based on his other shorter composite patterns. This is currently not implemented. Right now, longer composite entities always take precedence over shorter ones

@BeWe11 This PR adds support for nested composites too: #17.