Slot value setting as None

Hi, I am facing a problem while setting slots as custom actions. The type of my slot is float but the slot value is always set as None.

from typing import Any, Text, Dict, List from import SlotSet from rasa_sdk import Action, Tracker from rasa_sdk.executor import CollectingDispatcher

class ActionHelloWorld(Action):

def name(self) -> Text:
     return "action_hello_world"

def run(self, dispatcher: CollectingDispatcher,
         tracker: Tracker,
         domain: Dict[Text, Any]) -> List[Dict[Text, Any]]:

    parameter = tracker.get_slot('parameter')
    float_parameter= parameter
    if float_parameter:

       dispatcher.utter_message(text='The mutation rate is:' '%f' %float_parameter)

         dispatcher.utter_message(text= "No mutation rate")

    return []



type: float

min_value: -100.0

max_value: 100.0


- type: custom

The file is just printing None and the if loop only executes the else part.

I am new in Rasa, I really need help.