Reader small image

You're reading from  Architecting AI Solutions on Salesforce

Product typeBook
Published inNov 2021
PublisherPackt
ISBN-139781801076012
Edition1st Edition
Concepts
Right arrow
Author (1)
Lars Malmqvist
Lars Malmqvist
author image
Lars Malmqvist

Lars Malmqvist is a 32x certified Salesforce CTA and has spent the past 15 years in the Salesforce ecosystem building advanced solutions on the platform. Currently, he works as a partner in the management consultancy, Implement Consulting Group, focusing on supporting large Nordic Salesforce clients in their transformation journeys. He has published two books, Architecting AI Solutions on Salesforce and Salesforce Anti-Patterns, both with Packt publishing.
Read more about Lars Malmqvist

Right arrow

Preface

Salesforce is one of the world's leading enterprise software platforms. Businesses across the world rely on it to run increasingly critical parts of their business. Artificial Intelligence (AI), principally in the shape of machine learning models of ever-increasing scale and complexity, is equally becoming influential in many areas of business operations and strategic decision-making.

The Einstein platform is Salesforce's answer to how to marry the core functionality of their product offerings with the need for sophisticated AI-based solutions to improve, automate, and enlighten business processes. In this book, we will explore this platform in terms of what it can and what it can't achieve, so that you as an architect can make the right decision for your stakeholders about how to implement AI solutions on Salesforce.

We start by surveying the big picture in the introduction. Then, in the following four chapters, we dive deep into the Einstein functionality embedded into the various Salesforce clouds. We start with Sales, then move on to Service, followed by Marketing and Commerce, ending up with a look across the industry clouds.

Having learned how to use the built-in offerings, we will proceed to explore your options for when the out-of-the-box features just won't cut it. We will start by looking at declarative options, then move on to various programmatic ones, starting with those provided by Salesforce and moving on to three examples of using third-party services in your Salesforce solution.

After mastering how to build custom AI solutions on the Salesforce platform, we will end the book by condensing our learning into a decision guide. Then we will draw some final lessons and give some pointers to where you might go to deepen your mastery of the topics at hand.

Architecting AI solutions is different from traditional architecture, but it will increasingly become part and parcel of your work as an architect. I hope this book helps you to do this work well.

Who this book is for

This book is for existing and aspiring technical and functional architects, technical decision-makers working on the Salesforce ecosystem, and those responsible for designing AI solutions in their Salesforce ecosystem. Lead and senior Salesforce developers who want to start their Salesforce architecture journey will also find this book helpful. Working knowledge of the Salesforce platform is necessary to get the most out of this book.

What this book covers

Chapter 1, AI Solutions on the Salesforce Einstein Platform, starts by clarifying why it is a good idea to build AI solutions on Salesforce and what business and technical benefits this approach can have. It will then present a bird's-eye view of the various components that will be discussed throughout the book, present a basic architectural view of Salesforce Einstein, and then continue with a discussion of how architecting AI solutions is different from architecting traditional solutions. The chapter ends by previewing the structure of the parts and chapters to come and giving a preview of the Pickled Plastics Ltd. scenario that will be expanded throughout.

Chapter 2, Salesforce AI for Sales, covers the core Sales-related AI options in Salesforce. It will go through Einstein Lead and Opportunity Scoring, Einstein Forecasting, Einstein Activity Capture, and Einstein Conversational Insights, and covers the main features and configuration options. For each topic, there will also be a discussion of the pros and cons and what options an architect has if the limits of the feature are reached. As part of each feature discussion, it will reference the scenario that is used throughout the book to give a real-world grounding.

Chapter 3, Salesforce AI for Service, covers the core Service-related AI options in Salesforce. It will go through Einstein Bots, Case Classification and Routing, Einstein Article Recommendations, and Einstein Reply Recommendations, and covers the main features and configuration options. For each topic, there will also be a discussion of the pros and cons and what options an architect has if the limits of the feature are reached.

Chapter 4, Salesforce AI for Marketing and Commerce, starts by going through the integration architecture between core Salesforce, Marketing, and Commerce clouds to show how one needs to think differently about architecting across multiple clouds. It will then focus on the features of first Marketing Cloud Einstein and then Commerce Cloud Einstein. These will be covered in slightly less depth than the Sales and Service features due to the large number of features to cover, but will still be covered in sufficient depth to make an architectural assessment of their potential inclusion in a solution.

Chapter 5, Salesforce AI for Industry Clouds, covers how Einstein has been brought into Salesforce's various industry clouds, including the Health, Financial Services, Manufacturing, Consumer Goods, Education, and Non-profit clouds. As most of these features have been created using other elements rather than being unique, this is more a showcase for how Einstein features can be used than a discussion of new technical material.

Chapter 6, Declarative Customization Options, shows how you can use generic Einstein declarative features to create your own solutions, as well as discussing when that can be the right approach. It will first show some of the many ways you can embed and configure Einstein Next Best Action, then walk the user through making a good prediction with Prediction Builder, and finish with creating a story using Einstein Discovery.

Chapter 7, Building AI Features with Einstein Platform Services, will take you through three examples of using the Einstein Platform Services APIs to create custom AI solutions for the platform. Along the way, it will also discuss the architectural choices and trade-offs involved. The examples will move from an image classifier to a form text recognizer to a sentiment analysis application, all integrated into a normal Salesforce Sales or Service workflow.

Chapter 8, Integrating Third-Party AI Services, takes you through three examples of custom development, in this case using external third-party services as part of normal Sales/Service workflows on Salesforce. For each example, the architectural setup and the relevant choices in relation thereto will be discussed. The first example will show automated translations with the Google Translation API, the second will extract information from documents attached to a Case, and the third will train a custom prediction model using Amazon SageMaker.

Chapter 9, A Salesforce AI Decision Guide, presents a summary of all the key architectural decisions and trade-offs that are relevant to the technologies discussed in the book. It will start by introducing the guide and how to use it, then move on to a discussion of common use cases for AI technologies. For each use case, it will make architectural suggestions based on the key dimensions of the particular use case. It will then do a similar thing, but focusing instead on common technical requirements and constraints that may impact the architectural choice to be made.

Chapter 10, Conclusion, summarizes the main points of the preceding section. First, it will remake the case for using out-of-the-box declarative features when this is possible and summarize the substantial architectural benefits of doing so. Then it will revisit the key considerations for going above and beyond these features and the ways this can be done. It will end by giving some hints for other resources that can be consulted should the reader wish to go further in various directions.

To get the most out of this book

This book assumes you are familiar with the basics of using the Salesforce web application. You need to be working on a recent version of a modern browser such as Chrome or Edge to do the exercises. You can find a full list of recommendations and considerations here: https://help.salesforce.com/s/articleView?id=sf.getstart_browser_recommendations.htm&type=5.

You will need to sign up for a fresh Tableau CRM-Enabled Developer Edition Org to follow most of the examples in this book. You can find instructions for getting access to one of those by using the following link: https://trailhead.salesforce.com/content/learn/projects/quick-start-einstein-analytics/sign-up-for-an-analytics-org.

If you are using the digital version of this book, we advise you to type the code yourself or access the code from the book's GitHub repository (a link is available in the next section). Doing so will help you avoid any potential errors related to the copying and pasting of code.

Download the example code files

The code for the chapter can be found here:

https://github.com/PacktPublishing/Architecting-AI-Solutions-on-Salesforce

We have other code bundles from our rich catalog of books and videos available at https://github.com/PacktPublishing/. Check them out!

Code in Action

The Code in Action videos for this book can be viewed at https://bit.ly/3DerU2h.

Download the color images

We also provide a PDF file that has color images of the screenshots and diagrams used in this book. You can download it here: https://static.packt-cdn.com/downloads/9781801076012_ColorImages.pdf.

Conventions used

There are a number of text conventions used throughout this book.

Code in text: Indicates code words in text, database table names, folder names, filenames, file extensions, pathnames, dummy URLs, user input, and Twitter handles. Here is an example: "Also create a text variable named recordId, available for input, to receive the ID of the context case."

A block of code is set as follows:

#train/test split
train_data, test_data = np.split(model_data.sample(frac=1, random_state=432), [int(0.8 * len(model_data))])
print(train_data.shape, test_data.shape)

Bold: Indicates a new term, an important word, or words that you see onscreen. For instance, words in menus or dialog boxes appear in bold. Here is an example: "Now go to flows and create a Record-Triggered Flow. Set the object to Case Comment and run the flow after creation, as shown in the following screenshot."

Tips or important notes

Appear like this.

Get in touch

Feedback from our readers is always welcome.

General feedback: If you have questions about any aspect of this book, email us at customercare@packtpub.com and mention the book title in the subject of your message.

Errata: Although we have taken every care to ensure the accuracy of our content, mistakes do happen. If you have found a mistake in this book, we would be grateful if you would report this to us. Please visit www.packtpub.com/support/errata and fill in the form.

Piracy: If you come across any illegal copies of our works in any form on the internet, we would be grateful if you would provide us with the location address or website name. Please contact us at copyright@packt.com with a link to the material.

If you are interested in becoming an author: If there is a topic that you have expertise in and you are interested in either writing or contributing to a book, please visit authors.packtpub.com.

Share Your Thoughts

Once you've read Architecting AI Solutions on Salesforce, we'd love to hear your thoughts! Please click here to go straight to the Amazon review page for this book and share your feedback.

Your review is important to us and the tech community and will help us make sure we're delivering excellent quality content.

lock icon
The rest of the chapter is locked
You have been reading a chapter from
Architecting AI Solutions on Salesforce
Published in: Nov 2021Publisher: PacktISBN-13: 9781801076012
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
undefined
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at €14.99/month. Cancel anytime

Author (1)

author image
Lars Malmqvist

Lars Malmqvist is a 32x certified Salesforce CTA and has spent the past 15 years in the Salesforce ecosystem building advanced solutions on the platform. Currently, he works as a partner in the management consultancy, Implement Consulting Group, focusing on supporting large Nordic Salesforce clients in their transformation journeys. He has published two books, Architecting AI Solutions on Salesforce and Salesforce Anti-Patterns, both with Packt publishing.
Read more about Lars Malmqvist