Add Record Merge Fields to a Sales Email Prompt Template
Merge fields are critical to scaling a sales email prompt template for multiple
customers and products. They connect your prompt templates to Salesforce record fields, such as
from sales or service records. In a prompt template, a merge field acts like a placeholder. After
you run the template, the LLM replaces the merge field with your actual data.
Required Editions
Available in: Lightning Experience
Available in: Enterprise, Performance, and Unlimited
Editions with the Einstein for Platform, or Einstein or Agentforce for Sales or
Service add-on, or Agentforce Foundations
User Permissions Needed
To create and manage prompt templates in Prompt Builder:
Prompt Template Manager permission set
Manage Prompt Templates
Execute Prompt Templates
OR
Customize Application permission set
To add a merge field to a prompt template in Prompt Builder, click the Insert
Resource selector and select a resource from the dropdown menu of placeholder
values for your CRM data.
Let’s look at a sales email prompt template that uses merge fields. Say you sales team
spends a significant amount of time writing introduction emails from scratch for leads or
contacts.
Using an LLM to write these descriptions is more efficient, and the LLM can use your
up-to-the-minute data to create content. To get started, create a prompt template.
In the Prompt Template Type dropdown, select Sales Email.
For the Prompt Template Name, enter Draft an Introduction
Email.
For the Recipient Type, select Contact.
Leave the Template Description and Object fields empty.
Click Next.
In the Example Prompt
Template Library, find the sales email prompt template titled: Draft an
introduction email for a new lead or contact. Copy and paste this template into the Prompt
Template Workspace.
This example contains placeholder text for prompt template resources. Before you can
run this template in Prompt Builder, in the Prompt section, click Insert
Resource. The search field appears the first time you click this option.
Use the search bar to replace the placeholders with real merge fields. When the
template is resolved into a prompt, the merge fields are replaced with the real email
sender’s name and the recipient’s name and company.
To run the prompt template and see the LLM-generated email draft:
Click the Preview Settings button.
Under Inputs, enter a contact name in the Recipient search bar and select it. This
selection defines the recipient of the LLM-generated email draft.
In the Configure Response and Display sections, verify that Generate Response,
Display Prompt, and Display Resolution are selected or deselected based on what you
want to test.
Click Save & Preview, and review the resolved prompt and
the response.
Did this article solve your issue?
Let us know so we can improve!
Loading
Salesforce Help | Article
Cookie Consent Manager
Cookie Consent Manager
General Information
Required Cookies
Functional Cookies
Advertising Cookies
General Information
We use three kinds of cookies on our websites: required, functional, and advertising. You can choose whether functional and advertising cookies apply. Click on the different cookie categories to find out more about each category and to change the default settings.
Privacy Statement
Required Cookies
Always Active
Required cookies are necessary for basic website functionality. Some examples include: session cookies needed to transmit the website, authentication cookies, and security cookies.
Functional Cookies
Functional cookies enhance functions, performance, and services on the website. Some examples include: cookies used to analyze site traffic, cookies used for market research, and cookies used to display advertising that is not directed to a particular individual.
Advertising Cookies
Advertising cookies track activity across websites in order to understand a viewer’s interests, and direct them specific marketing. Some examples include: cookies used for remarketing, or interest-based advertising.