Hi all,
I would like to set a slot using SlotSet() from one of the form validation methods. However this needs to be defined as a dictionary. How can I do it? This is what I have and does not work:
def validate_slot1(
self,
slot_value: Text,
dispatcher: CollectingDispatcher,
tracker: Tracker,
domain: DomainDict,
) -> Dict[Text, Any]:
a = tracker.slots.get("CARDINAL")
if a is None:
return {SlotSet("test", "value"), "slot1": 'none'}
else:
a = some operation
print('Check sys 3', sys)
return {SlotSet("test", "value"), "slot1": 'a')
This returns a TypeError
TypeError: unhashable type: ‘dict’