Translating a Rules-Based Einstein Chatbot with the Language IO API Plugin
You can use the Language IO API plugin for Salesforce to translate Einstein bot dialogs, including messages and questions.
Install the Language IO API Plugin
- Install the Language IO API Plugin.
- If you haven't already, create a Named Credential.
Note: You will need the Name of your Named Credential for the next step.
Set Language IO API Plugin Custom Settings
- Go to Setup > Custom Settings > Language IO API Public Settings > Manage.
- Click "New".
(Click to expand) - Set:
- Named Credential: Name of the Named Credential you already have or created earlier.
- Proportionate to the size of your bot, you may need to increase these values:
- Translation Slices: Recommend 3 or more to decrease the size of each translated chunk.
- Deployment Slices: Recommend 3 or more to decrease the size of each translated bot deployment.
- Save.
Create a Bot Translation Lightning Component Tab
- Go to Setup > Tabs > Lightning Component Tabs.
- Click "New".
- Select "Lio:botTranslation" as the Lightning Component.
- Set a Label (e.g "Language IO Bot Translation").
- Choose a Tab Style.
- Click "Next".
- Give tab visibility to Profiles that will translate your bots.
- Save.
Enable Additional Bot Languages
Note: Only languages enabled in Setup > Translation Workbench > Translation Language Settings will be available as additional bot languages.
- Click to "Edit" your Einstein bot and open the Overview.
(Click to expand) - Find Conversation Languages and click "Add" to add additional languages.
(Click to expand)
Run the Translation Process
- Open your "Language IO Bot Translation" tab.
- Select your bot and bot version to translate from the available dropdowns.
- Click "Get Bot Version Language". This can take up to two minutes.
- Select the languages you want to translate the bot into.
-
Finally, click "Translate Bot Version Content". You might not see any visible change to the page, but the translation process has started. This can take up to 15 minutes.
Important: This process translates the entire the bot, not only the parts that were updated since the last translation.
Check the Bot Translation Status
- Go to Setup > Deployment Status.
- The following screenshot shows that translation is complete and deployment is pending.
(Click to expand) - When deployment is complete, your Deployment Status page should look like this:
(Click to expand) - To verify that translation is completed, open your Einstein bot and compare the source and target text from the Dialog Translations tab for each Dialog text.
(Click to expand)
Best Practices and Known Limitations
Our app uses Deployments to update bot translations. Occasionally, Deployment conflicts may result in bots being partially translated or not translated. If this occurs:
- Try restarting the bot translation with fewer (max. 3) target languages selected.
- Go to Setup > Custom Settings > Language IO API Public Settings and, if "Deployment Slices" is set higher than 3, decrease the "Deployment Slices" value before restarting the bot translation.