How to specify an entity extractor to extract only specific entities

Lets say

I want spacy to extract user_name slot via PERSON I want RegexEntityEx to extract restaurant_id, user_id, booking_id (I have defined regexes)

how to achieve this by modifying the configs?

also when i use rasa test the results for spacy entity extractor is not available why is that happening.

below is my pipeline

recipe: default.v1

NLU Pipeline

language: en

pipeline:

  • name: SpacyNLP model: en_core_web_trf
  • name: SpacyTokenizer
  • name: RegexFeaturizer
  • name: SpacyFeaturizer
  • name: LexicalSyntacticFeaturizer
  • name: CountVectorsFeaturizer
  • name: CountVectorsFeaturizer analyzer: char_wb min_ngram: 1 max_ngram: 4
  • name: RegexEntityExtractor case_sensitive: False use_word_boundaries: True use_lookup_tables: True use_regexes: True
  • name: SpacyEntityExtractor dimensions: [“PERSON”]
  • name: DIETClassifier epochs: 100 constrain_similarities: true

Hi there! Were you able to find out how to do this @KalpaD98? I’ve spent some time now looking for this answer and I haven’t found any documentations about it nor examples that could lead to the solution for version 3.0.

I am particularly needing to use CRFEntityExtractor for entity1 from lookup tables, Duckling for entity2 and the rest of them are fine with DIET. I have seen official Rasa3.# videos mentioning that extractors can be assigned to specific entities but the implementation is nowhere to be found.

source

What is the solution for this

I haven’t found a straight forward solution but a workaround is to use a slot validation action. It is not ideal as we would rather assign an extractor to a specific slot, however the validation action can enforce that a specific slot is only updated with values coming from certain extractor.