Skip to main content

Implement Data Cloud for Agentforce

Learning Objectives

After completing this unit, you’ll be able to:

  • Explain how to prepare data for Agentforce.
  • Describe how to create an agent built on unified and transformed data from Data Cloud.

Understand Data Requirements

Before you implement Data Cloud, you need to understand your project’s data requirements. It’s helpful to review the data preparation steps and the questions to consider.

Data Prep Steps

Questions to Consider

  1. Identify what data is needed for your use case, and define the type of data.
  • Do you need CRM records, such as leads or cases?
  • Do you need unstructured or structured data?
  • Do you need to upload files?
  1. Locate the source of the data, and determine how to connect it to Data Cloud.
  • If you need CRM records, which org are they currently in?
  • Is your data in an external data warehouse? If so, you need to use a zero-copy data federation connector.
  • Do you need real-time access to this data?
  1. Outline data processing requirements. This can include identity resolution, transforms, or insights.
  • Does the data have quality issues? What type of issues? Are the issues widespread?
  • Do you need to unify the data? This means running identity resolution to link it to unified profiles.

This table isn’t comprehensive. Learn more in the Prepare Your Data unit of the AI + Data: Project Planning module.

In the next section, follow NTO as the company identifies, connects, and processes data for its Agentforce project.

Configure Data Cloud for Agents

NTO wants to build an agent that responds to questions about product issues. NTO plans to ground its prompts with advanced Data Cloud RAG. Follow along with Pia, NTO’s enterprise architect, as she configures Data Cloud and builds an agent, starting with data preparation. Here are the initial steps she takes.

  1. Enables and provision Data Cloud in an org
  2. Sets up Data Cloud users
  3. Finds data about customer cases and identifies its source

In Service Cloud, NTO stores customer case data. Here are some example cases from different customers.

  • Case 1: Pants style 1068 is too short
  • Case 2: Pants style 2000 is too long
  • Case 3: Fitness watch doesn’t charge quickly
  1. Now, it’s time to create a data stream that ingests the case data from Service Cloud into Data Cloud. Case data is stored in the Case data lake object (DLO).
  2. Pia uses a batch data transform to resolve data issues such as inconsistent names and formats. Transformed data is stored in the Cleaned Case DLO.
  3. Then, she adds mappings between the Cleaned Case (DLO) and Case data model object (DMO).
  4. Now it’s time to create and run an identity resolution ruleset to link the cases with the customer’s unified profile.

Now Pia knows more context about each case. For example, Pia sees that Case 1, about pants being too short, comes from Rachel Rodriguez. Rachel’s unified profile includes her height, 170 cm. Pia also sees that Case 2, about pants being too long, comes from a customer with height 165 cm. This context will help the agent give more relevant and effective answers.

With their data ingested, transformed, and unified, Pia is ready to set up RAG.

  1. She creates a search index from the Case DMO and a search index from the Unified Individual DMO.

These indexes will be used to power RAG in their agent. Data Cloud automatically creates a retriever for each index, which serves as the bridge between search indexes and prompt templates.

Optionally, Pia could create an ensemble retriever. Learn more in Create an Ensemble Retriever.

  1. Now, Pia creates a prompt template that calls the ensemble retriever or both individual retrievers.

The retriever populates the prompt with the most relevant information. Pia’s prompt template analyzes the customer’s question and uses its knowledge base (existing case data and unified profiles) to formulate an answer.

It’s time to use the prompt template in an agent. Pia:

  1. Creates a new agent from an Agentforce Service Agent template.
  2. Creates a permission set that includes access to Prompt Builder, the Case DMO, and the Unified Individual DMO. Then she assigns the permission set to the agent user.
  3. Creates an agent action named Answer Questions with Case that uses the prompt template.
  4. Adds a topic to the agent user.
  5. Adds the Answer Questions with Case action to the topic.
  6. Activates and tests the agent.

For example, Pia asks the agent, “I have long legs and I’m 170 cm tall. Which pant styles do you recommend and not recommend? ” The agent answers, “Customers with similar heights report that style 1068 is too short. Customers report that style 2000 is longer. I recommend style 2000, and I don’t recommend style 1068.”

After a few more rounds of testing and tweaking the prompt, Pia and team are satisfied with its performance. NTO deploys and operationalizes its agent by adding it to customer channels. After deployment, the team makes sure to consistently monitor and refine it. Remember that after you start using your agent, follow these best practices.

  • Monitor the audit trail and give feedback on your agents.
  • Edit prompts to address critical feedback.
  • Monitor performance with Agentforce Analytics dashboards.
  • Update your RAG implementation to keep your agents’ data sources current.

Wrap Up

In this module, you learned how Data Cloud supports Agentforce capabilities and the difference between enabling and implementing Data Cloud. While enabling Data Cloud unlocks some capabilities such as the Trust Layer and RAG with the Agentforce Data Library, implementing Data Cloud is the crucial next step given all its benefits.

Implemented Data Cloud provides agents with a unified data foundation that extends their knowledge across Salesforce and beyond. Also, RAG solutions built on Data Cloud have context from unified profiles; use preprocessed, transformed data; and support diverse data types and sources. When Data Cloud is implemented, agents unlock real-time capabilities and access to external zero-copy data, further expanding their potential.

You followed NTO prepare its data, implement Data Cloud for Agentforce, and build a service agent that uses unified profiles to give effective responses. Now you’re ready to implement Data Cloud for Agentforce in your business too!

Resources

Compartilhe seu feedback do Trailhead usando a Ajuda do Salesforce.

Queremos saber sobre sua experiência com o Trailhead. Agora você pode acessar o novo formulário de feedback, a qualquer momento, no site Ajuda do Salesforce.

Saiba mais Continue compartilhando feedback