Switching models depend upon user context in rasa x project

i am trying to find out how to switch models depend upon user context basically i have three different agents… please help me out from this topic

Hey @avinash6063

Sorry, I didn’t quite understand the question, could you please explain what your expectation is step by step?

Thanks!

Hey @degiz

  1. In my rasa project there are two different trained models one is employee information and second one is department information when user having conversion with fist model (employee model) and this is default model with all necessary files(story,nlu,domain.yml) if in between user wants to talk with department model so in the rasa project model has to change as per user request (mean need to switch the agents).

HI … below conversation will indicate what i am trying to achieve

  • user input: hello
  • agent_1: hello, how can i help?
  • user input: i would like to place an order
  • agent_1 asks for specifics
  • user replies back with the order details
  • user asks a question that only agent_2 can reply to
  • now agent_2: replies
  • agent 2 engages in a conversation with the user before switching back to agent_1

Now the user should not be aware that there’s more than one agent handling the conversation so the transition between agents should be smooth.

Hey @avinash6063

Ok, I see. But why would you like to use two separate models for that? If you’re concerned about some database security, IMO you can still find a way to make sure that employees have restricted access to the information in your actions.py.

If you want to keep two models, IMO it’s fine to have some common training data for both of them instead of swapping it on the flight.

Or you want to still swap the models, you can use this REST endpoint for Rasa Open Source or this one for Rasa X.

@degiz Instead of having large training data so i though can create separate models for each agents