rasa_sdk/forms.py
async def validate(
        self,
        dispatcher: "CollectingDispatcher",
        tracker: "Tracker",
        domain: "DomainDict",
    ) -> List[EventType]:
        """Validate slots by calling a validation function for each slot.

        Args:
            dispatcher: the dispatcher which is used to
                send messages back to the user.
            tracker: the conversation tracker for the current user.
            domain: the bot's domain.
        Returns:
            `SlotSet` events for every validated slot.
        """
        slots: Dict[Text, Any] = tracker.slots_to_validate()

        for slot_name, slot_value in list(slots.items()):
            function_name = f"validate_{slot_name.replace('-','_')}"
            validate_func = getattr(self, function_name, None)

            if not validate_func:
                logger.debug(
                    f"Skipping validation for `{slot_name}`: there is no validation function specified."
                )
                continue

            if utils.is_coroutine_action(validate_func):
                validation_output = await validate_func(
                    slot_value, dispatcher, tracker, domain
                )
            else:
                validation_output = validate_func(
                    slot_value, dispatcher, tracker, domain
                )

            if validation_output:
                slots.update(validation_output)
            else:
                warnings.warn(
                    f"Cannot validate `{slot_name}`: make sure the validation function returns the correct output."
                )

        return [SlotSet(slot, value) for slot, value in slots.items()]
Validate slots by calling a validation function for each slot.

        Args:
            dispatcher: the dispatcher which is used to
                send messages back to the user.
            tracker: the conversation tracker for the current user.
            domain: the bot's domain.
        Returns:
            `SlotSet` events for every validated slot.
        
Validate slots by calling a validation function for each slot.
Validate slots by calling a validation function for each slot .
async def validate(
        self,
        dispatcher: "CollectingDispatcher",
        tracker: "Tracker",
        domain: "DomainDict",
    ) -> List[EventType]:
        slots: Dict[Text, Any] = tracker.slots_to_validate()
        for slot_name, slot_value in list(slots.items()):
            function_name = f"validate_{slot_name.replace('-','_')}"
            validate_func = getattr(self, function_name, None)
            if not validate_func:
                logger.debug(
                    f"Skipping validation for `{slot_name}`: there is no validation function specified."
                )
                continue
            if utils.is_coroutine_action(validate_func):
                validation_output = await validate_func(
                    slot_value, dispatcher, tracker, domain
                )
            else:
                validation_output = validate_func(
                    slot_value, dispatcher, tracker, domain
                )
            if validation_output:
                slots.update(validation_output)
            else:
                warnings.warn(
                    f"Cannot validate `{slot_name}`: make sure the validation function returns the correct output."
                )
        return [SlotSet(slot, value) for slot, value in slots.items()]
async def validate ( self , dispatcher : "CollectingDispatcher" , tracker : "Tracker" , domain : "DomainDict" , ) -> List [ EventType ] : slots : Dict [ Text , Any ] = tracker . slots_to_validate ( ) for slot_name , slot_value in list ( slots . items ( ) ) : function_name = f"validate_{slot_name.replace('-','_')}" validate_func = getattr ( self , function_name , None ) if not validate_func : logger . debug ( f"Skipping validation for `{slot_name}`: there is no validation function specified." ) continue if utils . is_coroutine_action ( validate_func ) : validation_output = await validate_func ( slot_value , dispatcher , tracker , domain ) else : validation_output = validate_func ( slot_value , dispatcher , tracker , domain ) if validation_output : slots . update ( validation_output ) else : warnings . warn ( f"Cannot validate `{slot_name}`: make sure the validation function returns the correct output." ) return [ SlotSet ( slot , value ) for slot , value in slots . items ( ) ]
Validate slots by calling a validation function for each slot.
Validate slots by calling a validation function for each slot .
"""Validate slots by calling a validation function for each slot.

        Args:
            dispatcher: the dispatcher which is used to
                send messages back to the user.
            tracker: the conversation tracker for the current user.
            domain: the bot's domain.
        Returns:
            `SlotSet` events for every validated slot.
        """
`SlotSet` events for every validated slot.
` SlotSet ` events for every validated slot .
self
dispatcher
"CollectingDispatcher"
the dispatcher which is used to
send messages back to the user.
the dispatcher which is used to send messages back to the user .
tracker
"Tracker"
the conversation tracker for the current user.
the conversation tracker for the current user .
domain
"DomainDict"
the bot's domain.
the bot ' s domain .