A Guide To Building Scalable Ai Agents

Sedang Trending 1 bulan yang lalu

Things tin unravel quickly erstwhile nan correct accusation doesn’t scope nan correct personification astatine nan correct time. These moments move chaotic erstwhile systems aren’t built to respond successful existent time. Automating this benignant of acquisition requires much than conscionable alerts aliases notifications; it requires connected data, smart flows and secure, time-sensitive decision-making.

This guideline will locomotion you done building real-time decision-making systems utilizing Salesforce Agentforce and Heroku AppLink. It will show really Agentforce’s AI-driven workflows respond to unrecorded events and really Heroku’s AI Platform arsenic a Service (PaaS) tin widen those flows pinch customized actions and APIs. The consequence is simply a personalized acquisition that helps group confidently entree nan information they request to make decisions successful nan moment.

What Is Salesforce Agentforce?

Agentforce is an always-on exertion model that leverages AI on pinch an organization’s Salesforce information to proactively execute tasks astatine scale. By intelligently utilizing nan information already successful your Salesforce ecosystem, Agentforce tin build powerful automations that are amended customized to your usage cases. Since nan AI that powers Agentforce is wrong your Salesforce environment, you don’t request to beryllium concerned astir information information aliases it leaking customers’ backstage data.

One celebrated attack to moving pinch AI agents is to build flows — workflows that nan AI agents travel while processing and handling tasks automatically. Here is an illustration workflow:

An illustration of Agentforce flow.

An illustration of an Agentforce flow.

In this workflow, nan supplier is tasked pinch scheduling a meeting, and if location is availability, nan supplier will schedule a gathering for each nan participants.

Customizing Workflows With Agentforce and Heroku

There are galore automation devices disposable successful nan marketplace, but sharing customer information crossed institution boundaries produces opportunities for information to go compromised. Keeping nan agentic AI wrong Salesforce helps protect nan information of companies’ data.

Many communal functions are prebuilt, trained and included successful Agentforce. Using these workflow tasks doesn’t require immoderate coding; they tin beryllium added into nan travel to velocity loop and building of agentic flows. But companies often request customized flows for definite usage cases aliases verticals.

This is wherever integrating Agentforce pinch Heroku becomes valuable. Heroku’s powerful AI PaaS tin widen Agentforce workflows pinch customized actions and APIs that enable fast and easy app deployment into nan cloud. Heroku is portion of nan Salesforce family, and nan tight integration of Salesforce and Heroku makes it easier to build Agentforce applications.

Heroku AppLink exposes services built connected Heroku’s AI PaaS as APIs to beryllium utilized successful Salesforce Agentforce flows. AppLink enforces Salesforce’s permissions and rules, ensuring that nan information processed successful nan Heroku exertion remains unafraid successful nan Salesforce ecosystem.

Build an AI Workflow

To spot really it works, let’s build an aerial recreation travel pinch Agentforce. When passengers onshore astatine their destination, they request to cognize wherever to spell next. Here’s a travel that could beryllium built successful Agentforce:

  • Get nan rider manifest for nan flight.
  • For each passenger, query nan adjacent steps. For simplicity, presume 2 options:
    • If nan rider has a connecting flight: Query formation instrumentality for departure time/gate accusation specifications connected nan adjacent flight.
    • If this is nan passenger’s last destination: Get nan baggage declare carousel number.
  • For either process, estimate nan stepping clip from nan gross to nan destination.
  • Identify nan direction: Will passengers move near aliases correct aft exiting nan jetway?
    • If location is time, upsell java on nan way.
    • If location is not capable time, bespeak that they should not delay.
  • Look up nan passenger’s telephone number successful Salesforce.
  • Text each rider customized specifications connected their adjacent steps to navigate nan airport.

Rather than formation attendants announcing a twelve connections (that nary 1 tin perceive anyway: “Flight 614 to Chicago will depart from gross <inaudible owed to static>”) aliases passengers racing to nan screens to find their adjacent flight, nan basal accusation is calmly delivered to nan rider via matter erstwhile nan level lands.

Build nan App

Now that we person nan workflow, we tin usage it to build a customized exertion successful Agentforce, utilizing a customized Heroku app to powerfulness agentic AI and Heroku AppLink to expose your Heroku app arsenic an API work successful Salesforce.

1. Define nan Data Sources

Let’s make a fewer assumptions astir our information sources:

  • All of nan customer information is stored successful Salesforce: name, address, mobile telephone and email.
  • Customer formation reservations are besides stored successful a Salesforce array and cross-indexed to nan customer’s data.
    • If this information is successful different information repository, it will require a small spot much processing, but nan wide travel will beryllium similar.
  • There’s an existing dataset of each gates, baggage claims and important locations wrong each airport, pinch approximate distances betwixt locations.
    • The dataset of airdrome accusation was antecedently created and deployed successful Heroku arsenic an API.

2. Create nan Data Flow

To footwear disconnected nan information flow, we will usage a Heroku eventing service. Heroku eventing is simply a aviator programme that tin beryllium utilized to invoke Heroku applications — aliases successful this case, an agentic flow. A Heroku app pinch eventing enabled behaves likewise to webhooks: services that perceive for a circumstantial arena successful nan ecosystem. Another automated travel moving during nan formation process tin occurrence a “landing” arena arsenic a formation progresses done nan air. The exertion receives this arena and starts moving nan flow.

When nan travel begins, nan supplier retrieves nan formation manifest for each passenger. It processes nan formation manifest to get nan presence gross and each passenger’s adjacent steps. It tin tally wrong nan Heroku application, aliases successful a prebuilt agentic travel exertion that makes and processes SQL calls successful Salesforce.

Once nan rider information is collected and parsed, we request to find nan locomotion clip wrong nan airport. To get this information, we will build a customized exertion successful Heroku that interacts pinch nan flow.

3. Build nan Heroku Application

Our Heroku exertion will beryllium exposed to Agentforce done AppLink. AppLink turns your Heroku app into a civilization API that useful only wrong nan Salesforce ecosystem. Applications utilizing AppLink are provisioned and securely connected to your Salesforce statement to guarantee information integrity. This exertion tin link pinch aggregate Salesforce organizations, but it must beryllium provisioned successful each statement individually.

Because this exertion is built connected Heroku’s AI PaaS, nan dev squad does not request to negociate immoderate infrastructure aliases DevOps. It is each included successful nan box. This makes it easier for developers to adopt powerful, analyzable cloud autochthonal technologies specified arsenic Kubernetes.

Heroku-integrated apps must travel nan OpenAPI specifications to beryllium decently integrated. Let’s presume 4 pieces of information are sent into this API: airdrome code, presence gate, destination and clip of adjacent flight.

Only nan first 3 parameters are required (passengers heading to baggage declare will not person a clip of adjacent flight). Our exertion will incorporate an OpenAPI spec (often called a Swagger JSON) that will beryllium consumed by nan flow.

For each rider connected nan flight, nan Heroku exertion is called to process their travel done nan airport. It mightiness usage Google Maps to clip a stepping travel aliases usage an airdrome mapping work pinch real-time data. How nan information is processed and evaluated is not captious here. What is important is that nan Heroku exertion securely handles nan airline’s customer data, truthful it ne'er leaves nan Salesforce organization.

The Heroku application’s output is data: How agelong of a locomotion nan transportation will be, and a personalized statement connected really quickly nan rider needs to make nan transfer. This will beryllium returned arsenic a JSON entity to nan Agentforce flow.

4. Complete nan Flow

In nan last step, nan supplier composes a short SMS connection to nan passenger. Using prompts, we tin nonstop nan supplier to create an due connection welcoming each rider and providing them pinch up-to-date accusation connected nan adjacent steps successful their travel.

If nan AI determines that it is simply a tight connection, location could beryllium encouragement not to delay.

“Welcome to New York JFK. Your connecting formation to Boston leaves Gate B10 astatine 3:20, and nan boarding doors adjacent astatine 3:00. It is simply a 10-minute walk. Please proceed to nan gross immediately.”

If location is time, possibly nan AI could cross-sell a extremity astatine a java shop on nan way.

“Welcome to Chicago O’Hare! Your connecting formation to Cleveland leaves astatine 6:20 p.m. from Gate B12. That’s astir a 15-minute walk, truthful you’ll person plentifulness of time.”

Flying Is a Breeze

Using agentic flows wrong Salesforce tin thief airlines make airdrome transfers a breeze. Using customer information from Salesforce and a customized Heroku AppLink integration, an agentic travel sends each rider a customized matter connection upon landing. Private customer information ne'er leaves nan Salesforce ecosystem, and nan customized Heroku exertion provides a personalized experience. With agentic flows successful Agentforce, customers tin beryllium informed successful existent clip of changes and really urgently they request to grip nan change.

When AI agents tin grip notifying customers of itinerary changes, airlines tin attraction connected different parts of nan customer experience, helping to make nan full recreation acquisition little stressful for everyone.

YOUTUBE.COM/THENEWSTACK

Tech moves fast, don't miss an episode. Subscribe to our YouTube channel to watercourse each our podcasts, interviews, demos, and more.

Group Created pinch Sketch.

Selengkapnya