Using slot for telegram

username = tracker.get_slot(‘username’) "SELECT * FROM customer WHERE CAST(username AS int)= ‘+username+’ "

I have query database and tracker like that, i can access slot in local but when I using telegram, model cann’t get slot.

Welcome back @desims :slight_smile:

Can you check the debug logs from running it in local vs running it in telegram to see whether the slot is being picked up correctly in both cases?

I get error when run action

this my stories

  • affirmative
    • utter_username
  • enter_data{“username”: “IN2JKT02”}
    • slot{“username”: “IN2JKT02”}
    • action_username
    • slot{“username”: “IN2JKT02”}

Hm, did you make sure to train the bot after adding that story? Because it looks like your trained model has never seen that slot in the stories it was trained on. As a side note, it looks like you are running quite old versions of rasa, have you considered upgrading?

i have train stories

  • affirmative
    • utter_username
  • enter_data{“username”: “IN2JKT02”}
    • slot{“username”: “IN2JKT02”}
    • action_username
    • slot{“username”: “IN2JKT02”}

yes, I am using old version. it’s not problem right?

It’s work when running in local but its not work when in server (linux)