This article is intended for Salesforce administrators responsible for installing and configuring the Language I/O Response 2 add-in for automated case translation.
Install the Package
- Contact Language I/O Support at firstname.lastname@example.org to get an account setup for your company. You will be sent a set of API credentials that you will add to the named credential as shown in the next section.
- Language I/O will need the username, password, and security token for an account with permissions allowing the user to modify cases and objects used by cases such as case comments and email drafts. This set of credentials will require API access at a minimum for translations to be pushed from the Language I/O server back into Salesforce, but once app installation is complete, regular login permissions can be removed from these credentials for security purposes.
- Install the package from the latest URL below depending on whether you are using a Sandbox or Production org. Begin by logging into the instance of Salesforce you wish to use. Visit the install link in the same browser and select "Install for all users". The latest version is Release 2.4.
- Production Org: https://login.salesforce.com/packaging/installPackage.apexp?p0=04t0H000000kvFT
- Sandbox Org: https://test.salesforce.com/packaging/installPackage.apexp?p0=04t0H000000kvFT
Create a Named Credential
If you don’t have Named Credentials set up, please contact Language I/O.
General App Setup & Customization
- If you don't already have a predefined locale or language field for cases in your org, add a custom field to the case object by going to Setup > Customize > Cases > Fields. Name this field something intuitive like "locale" or "language." This will be the field used for setting the language/locale for the case via a defined workflow or by Language I/O through language auto-detection. If you do not setup a workflow to populate this field on your side, the Language I/O server will set it automatically when that field is left empty during a translation request to the Language I/O service.
- If you need to setup an HTML form to test case creation in a test org, you can enable Case Feed by going to Customize > Self Service > Web-To-Case and enable it.
- If email drafts are not already enabled on the site, enable email drafts in the case feed by navigating to Setup and entering "Support Settings" in the Quick Find box. Select Support Settings and click Edit. Select Enable Email Drafts and click Save.
- User permissions for the API user Language I/O uses to connect must have permissions to access the following: All objects installed with Language I/O, Account, Case, CaseComment, EmailMessage, Name, OpenActivity, Task. Also Email to Case for some features.
From Setup/Custom Settings, an system administor creates the Default Organization Level Values for Language I/O Response Public Settings.
Enter “Custom Settings” in quick find box. Click “Manage” to the left of Language I/O Response Public Settings.
Click New to create a Default Organization Level Value.
The following is an example settings as a reference.
Custom Settings Configuration
The section describes each configuration item in the Language I/O Response Public Settings.
- Comment Translation Type: For configurations that involve an agent posting to communities and forums, the Language I/O comment widget has to be used for the agent's response translations. Either machine or human must be entered into this field to tell the service whether to employ machine or human translation of the agent's response when it is entered as a comment. This configuration field is separate from the field that is used for agent responses from the standard visual editor, LinguistNowEmailDraftHumanOrMachine.
- Consumer Id: This field is deprecated and exists for backwards-compatibility. Do not enter a value here if you are not provided with one.
- Description/Activity Tranlation Type: This field tells the service whether to employ human or machine translation services for incoming customer content. For security reasons, this should always be set to machine unless your company is comfortable with the risk that human linguists will be translating customer generated content, which is far more likely than agent-generated content to contain embedded personal data. Review the Language I/O policy on personal data embedded in CRM content before you switch this field to human.
- Email Draft Translation Type:This value can be set to either human or machine and will tell the app which of these types of translation services to employ for translation of agent responses entered into the standard email visual editor on the feed tab. Because agent responses can be controlled by the company and can always exclude personal data, it is safer to employ human translation services for agent response translation. Review the Language I/O policy on personal data embedded in CRM content before you switch this field to human.
- Email Content Type: This field lets Language I/O know whether to expect HTML tags in the email content for translation. Enter html in this field if tags will be embedded in the content and enter text if no tags will be embedded in the content.
- Locale Field Name: Enter the field name of the custom field you have chosen to store the language of the case. Ensure that __c is appended to the end as shown in the screenshot.
- Status On Pending: If a custom status message is entered here, this is the status that will display in the standard case status field when a translation has been requested but the translation is still pending. A value such as "Translation pending" would be appropriate.
- Status On Update: If a custom status messages is entered here, this is the status that will display in the standard case status field when a requested translation has been pushed back into the case. A value such as "Translation complete" would be appropriate.
- Language I/O Endpoint: This is the url of the Language I/O server that this app is configured to hit. Unless otherwise instructed, this field should be set to https://golinguist.com/linguistnow/resources/
- Re-translate Type: This field tells the service whether to employ human or machine translation services for retranslation requests of customer content. For security reasons, this should always be set to machine2 unless your company is comfortable with the risk that human linguists will be translating customer generated content, which is far more likely than agent-generated content to contain embedded personal data. Review the Language I/O policy on personal data embedded in CRM content before you switch this field to human. But if this field is set to machine2, the Language I/O service will use a secondary machine translation engine - not the one that was used for the original translation of the customer thread. This allows the agent to see a different translation, without taking the risk of sending customer-generated content to human linguists.
- Post Comments Translation Type: The Language I/O case app can include a widget where the agent can generate a post that will be displayed in communities. Enter human if you want all agent posts translated by human linguists and enter machine if you want agent posts to be machine translated.
- Auto-Send Email Draft: When the Language I/O service pushes a machine translation of the agent response back into Salesforce, the translation will be automatically emailed back to the customer if this box is selected. If the box is not selected, the translation will remain in draft form in the case until an agent manually sends it to the customer.
- Custom Status Field: The Language I/O server will push detailed translation status messages into the case and store them in this custom field if the custom field name is entered here. Ensure that __c is appended to the end.
- Email Draft Divider: To ensure that a long history of emails are not sent to the Language I/O server for translation, when requesting translation of an incoming customer email, a string can be entered into this field that is used as a delimiter to ensure that the Language I/O app only retrieves the email text that was added after the delimiter string entered here for translation via the Language I/O service. Common delimiter strings would contain a portion of the shared email signature that is populated by Salesforce.
- Disable Retranslate: When this box is checked, the Retranslate action will not be available in the Language I/O activity table where agents translate incoming customer emails.
- Human Word Count Field Name: If you want the accumulated word count of human translated words to be stored in the case, enter the custom field name here where the word count should be tallied by the app. Ensure that __c is appended to the end of the custom field name.
- Update Status Only On Human: If this box is checked, the regular case status field and the custom case status field (if a value is provided in the Custom Status Field box) will only be updated in relation to human translation requests. No status update will be provided for machine translation requests.
- Machine Word Count Field Name: If you want the accumulated word count of machine translated words to be stored in the case, enter the custom field name here where the word count should be tallied by the app. Ensure that __c is appended to the end of the custom field name.
- Hide Email Options: If this box is checked, the agent will not see the option next to the visual editor that lets them decide whether their response to the customer will be translated via human or machine translation services. Rather the value set in the configuration field labeled Email Draft Translation Type will always be used. If this box is not selected, the agent will see a toggle next to the visual editor where they can determine whether to have their response to the customer translated via human or machine translation services.
- Treat Comment As Foreign: In scenarios where customer questions and responses are pushed into a case as a comment - as happens in communities - this box should be selected. This tells the Language I/O app that when translation of a comment is requested, the app should assume that the comment is in the language of the case/customer. Not the language of the agent.
- Only Show Translations In Plugin: When this box is checked, translations of customer questions or translations of agent responses before they are sent will not be duplicated as comments in the case, rather they will only be stored in custom object fields that are displayed in the Language I/O activity table. This is important for support organizations where the number of comments in a case counts against the agent's overall productivity score. If this box is not checked, translation of customer emails and translation of agent responses will be stored in case comments as well as in the Language I/O custom object.
- Show Subject: If this box is checked, the agent will have the option to translate the subject of the case. If it is not checked, the case subject will not be made available for translation.
- Post Comments Are Public: If this box is selected, when an agent uses the Language I/O post comment widget to translate and post to the case, the translated post will be made public as soon as it is pushed into the case. If this box is not selected, the agent will need to manually make the translated comments public.
- Post Comments Label: This is the label that will be displayed as the placeholder hint in the text editor of the Language I/O post comment widget which is used when the agent needs to push a thread to the case that is of type comment.
- Hide Post Options: When this box is checked, the agent will not get to decide whether to have comments they add to the comments box translated via human or machine translation services. Rather the value that is entered into the Post Comments Translation Type configuration field will always be used. If this box is not checked, the agent will get the option to decide whether a human or machine translation service will be used to translate their case comments.
Create a Quick Action
Create a quick action to be used in a case layout as a sub tab in the feed tab. From Setup, enter Case. Select Buttons, Links, and Actions. Then click New Action.
Select Custom Visualforce as the Action Type. Choose “LIO Case Translation” as the Visualforce Page. Enter 300px as the Height. You can enter anything you like for Label. Name will be generated based on the Label you entered. Click “Save” button.
Edit Page Layouts
From Setup > Customize > Cases > Page Layouts, click "Edit" link to the left of the layout you want to add Language I/O add-ins.
Click on Quick Actions, drag LIO Case Translation into the section named “Quick Actions in the Salesforce Classic Publisher”. Then click “Quick Save”.
To add the email draft control to the feed view, click “Feed View” at the top. Scroll down to where “Other Tools and Components” is.
- Click “Add a Visualforce page”
- Select Lio_TranslateDraftPlugin
- Move the Lio_TranslateDraftPlugin component from the Hidden column to the Right Column by clicking the right arrow button.
Scroll back up to the top and click “Save”. Then Click “Save” again.
Follow the same steps above to edit Case (Support) Layout, or other applicable layouts.
You are done for classic mode.
Lightning Experience Setup
Switch to Lightning Experience. Click on Gear Icon at the top then Setup. Click on “Object Manager” then Case.
Click on “Lightning Record Page” and then click on the record page associated with the case, e.g., LIO Case, as illustrated below:
From the left pane, drag the Custom or Custom Managed component “EmailDraftTranslation" and drop it to where you want it to appear on the page
Click on the empty area in the title bar of the center page and click “Add Tab”.
To change the label of the tab: click on Details tab just above the “Add Tab” button. Then click Details Tab Label. Change to Custom type (the very first one). Then enter a custom label, e.g., “Language I/O".
From the center pane, click on “Language I/O” tab. Drag a Visualforce component from the left pane and drop it within the Language I/O tab. Change Visualforce Page Name to “LIO Case Translation”. Check off “Show Label”.
Click “Save” and you are done with the Response for Lightning Experience installation.