Skip to content

Bug in DucklingPlugin's activate_latent_entities. #124

@keshav47

Description

@keshav47

Describe the bug
In DucklingPlugin, once self.activate_latent_entities is set True, there is no option to make it False in the consecutive turns/states where I don't want latent entities.

Following logic in DucklingPlugin contributes to this behavior.

self.activate_latent_entities = use_latent or self.activate_latent_entities

here

To Reproduce
Steps to reproduce the behavior:

  1. set activate_latent_entities=false , while defining DucklingPlugin inside processors.
  2. Set state wise latent_entities in Input Class. eg latent_entities=False for capture_date_state and latent_entities=True for capture_time_state
  3. print(activate_latent_entities) variable inside Dialogy DucklingPlugin Base Class.
  4. curl request slu with payload's context['current_state'] in the following sequence capture_date_state -> capture_time_state -> capture_date_state
  5. activate_latent_entities will be printed in this sequence False -> True -> True

Expected behavior
Whereas it should have been:
False -> True -> False

Screenshots
Na

Desktop (please complete the following information):

  • OS: Ubuntu
  • Python version: 3.9

Additional context
Na

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions