How to extract username & password entities from text?

Hi everyone!

I’m building a chatbot to take the username and password from a user and use them to login to a platform.

How to I train Rasa NLU to pick up a username? Theoretically speaking, there are infinitely many usernames and passwords. So I don’t know how to train NLU as there is no specified format.

Chatbot example:

Chatbot: May I please have your username? User could respond with “username”, or “My username is …”, or “It is …”, or “it’s …” etc.

Chatbot: Thanks, may I please have your password too? User could respond with “password”, or “My password is …”, or “It is …”, or “it’s …” etc.

Can someone please help me with how to train NLU to pick up these credentials?

Also please tell me how to save them to slots, so I can call a custom action to log the user in.

If I’m doing anything wrong, please let me know!

Thanks!

1 Like

Hi @alihejazi, check out this reply to my similar request. You should use a form action and then extract those unique fields from the user’s last response.

2 Likes

@jabberlope Thank you very much for the help. Took quite a while for me to understand because there’s lots of reading, but it works now.

Glad I could help @alihejazi!

1 Like

Hi all,

I want get the username from the chat conversations

example:- bot:- Hi user:- Hi Bot: May i know your name? User: I am Karthik Bot : Thanks for providing details Karthik

Like the above example i have call the user with there name can anybody please help

can u describe or provide the source code please ?