Copy and paste Modules across bots

Here, we’ll provide an explanation of how to copy Modules from one bot to another. This can be very useful when you have multiple bots that perform similar functions and you do not wish to manually recreate the same Module content over again.

We'll discuss the following below: 

Effect of copy and paste on connections

When using this feature, all Module connections will be copied over along with the Module content. This includes:

  • all connection types (response to, AI understands, custom variable, A/B testing, users filter, channel, Jinja2 template)
    Display of all available Module connection types
  • all action types (Set Variable, Webhook, Go to)
    Display of all available Module connection action types

Please note that there are a few connection-specific limitations you'll want to be aware of. Below, we'll address the expected behavior of these connections and how it affects your use of the copy and paste feature.

Important considerations regarding the effect on connections

There are some key points to keep in mind about the impact of copy and paste on these specific connection types:

AI connections

For copied AI-based connections to work, the same Intents that were activated in the origin bot must also be active in the trained AI model of the destination bot. As an example, imagine a connection in Module A looks like this:

Connection showing "If AI understands EN Common Smalltalk: No at this module with high confidence and it has the Highest AI Confidence then go to 762660 Module B"

If the destination bot that Module A is copied to does not also have the Intent "EN Common Smalltalk: No" activated and trained in the AI Manager, the connection will be inactive and appear as such: 

Connection showing as inactive because there is no active NLU intent to select

Once the Intent is activated and the bot is trained, the AI connection will automatically update and work as expected.

Activated Intent toggled on in AI Manager

Outgoing Go to connections

If any Module containing an outgoing "Go to" connection is copied and pasted, but the destination Module for that connection is not copied and pasted with it, the connection will be deleted.

In the following bot configuration, the Origin Module has outgoing "Go to" connections to the Destination A and Destination B Modules:

Modules in bot canvas showing Origin Module with outgoing connections to Destination A and Destination B Modules

The Origin Module content contains "Destination A" and "Destination B" Suggested Replies. Here are its connections:

Module Connections of Origin Module showing if the response to that module contains the name of Destination A or B Modules, then go to them respectively

Consider that the Origin and Destination A Modules are copied to another bot, but the Destination B Module is not included in the same copied selection. In this case, the outgoing "Go to" connection to Destination B will no longer exist in the Origin Module copy once pasted in the destination bot:

Copied Origin Module showing outgoing connection to Destination A module

Note that in the example above, the Origin Module still contains a Suggested Reply of "Destination B", but the "Go to" connection to the Destination B Module has been removed. If the Destination B Module were copied over at another time, this connection would have to be manually reestablished in the destination bot to function the same as in the origin bot.

How to copy and paste Modules across bots

Before you attempt to copy and paste Modules, remember to check that you've saved all previous changes made to your bot. In this section, we'll explain how to do the following:

Copy the Modules

First, we'll address how to copy the Modules from your origin bot. 

  1. Open the bot that contains the Modules youd like to replicate. Click the zoom-out symbol (-) in the Navigation bar at the top of the Certainly Platform until you can see all the Modules youd like to copy.  

  2. Then, click into the canvas near the outermost Module you want to copy and drag your cursor over all Modules you're replicating. If it's not possible to select all desired Modules at once due to the bot's layout, consider working in batches.

    Every Module touched by the dotted rectangle that appears will be selected. When you have selected all the desired Modules for this batch, release your mouse or touchpad button. All the selected Modules will now appear bolded. 
    Text of selected Modules bolded
    If youd like to make changes to your selection, youll need to repeat this step until you've chosen the correct Modules to copy. To remove your selection, simply click into any empty space on the canvas.

  3. Once the correct Modules are selected, use Ctrl+C (or ⌘ Command+C on a Mac) to copy them. A pop-up will appear indicating the Modules have been copied. This message will disappear automatically and requires no action. 
    Pop-up message indicating "Selected modules are copied in your browser's memory"

Paste the Modules

These next steps show the process of pasting the Modules into your destination bot.

  1. Head over to the bot where you would like to paste the copied modules.  

  2. Next, use Ctrl+V (or ⌘ Command+V on a Mac) to paste the Modules. The copied Modules should appear in this chatbot. These Modules can now be moved, edited, and connected to other Modules.  

  3. As always, remember to save your changes before exiting the Certainly Platform.

For your edits to be reflected in a live bot, you must also select Publish after saving.

Work in batches

If you're unable to select all the desired Modules at one time due to the layout of the bot, it's possible to work in batches. You can complete the copy-and-paste process as many times as needed to transfer the desired Modules to the destination bot. 

However, be aware that this may require significant edits in the destination bot to function in the same way as the origin bot. We recommend that you first refer to the section above in which we discuss some important points to consider.

Want to copy many Modules and/or Modules with many connections? It may be better to simply clone the bot and then delete the Modules you do not need.