Reactive, Contextual, and Salesforce Q&A AI agents in Jitterbit Harmony
Overview
Jitterbit provides the following agents to all customers through Jitterbit Marketplace. These agents are designed for learning purposes to help organizations easily adopt AI:
-
Reactive Agent: A basic AI agent that lacks memory and context.
-
Contextual Agent: A basic AI agent with memory and context.
-
Salesforce Q&A Agent: A basic AI agent with memory and context that uses a specific tool to address particular questions regarding Salesforce account details.
Each agent is designed for Q&A interactions but varies in its complexity, ranging from the simplest AI agent without memory or context, to one that uses Retrieval-Augmented Generation (RAG). They use Slack as a mechanism to interact with, but they can be used with your choice of interface, whether it is a chat application (such as Microsoft Teams), microservices, SaaS apps (such as Salesforce), or an application built using Jitterbit App Builder.
This document explains the setup and operation of these learning agents. It first covers the architecture and prerequisites, next gives example prompts to show what the agents can do, and then provides steps to install, configure, and operate the agents.
AI agent architecture
The following diagram depicts the architecture implemented in the Reactive, Contextual, and Salesforce Q&A agents:
Azure AI] JB_AI_AGENT_PROJ@{ shape: diamond, label: "
Jitterbit Studio
AI agent
project" } JB_CUSTOM_API@{ shape: diamond, label: "
Jitterbit API Manager
custom API" } QA_CHAT_IF[fab:fa-slack
Q&A chat
interface] JB_AI_AGENT_PROJ--REST call--> AZURE_AI AZURE_AI--Response--> JB_AI_AGENT_PROJ JB_AI_AGENT_PROJ --> QA_CHAT_IF QA_CHAT_IF--Sends question--> JB_CUSTOM_API JB_CUSTOM_API--Triggers Slack API
request handler --> JB_AI_AGENT_PROJ
Prerequisites
To use these agents, the following components are required or assumed in the design of the agent.
Harmony components
You must have a Jitterbit Harmony license with access to the following components:
- Jitterbit Integration Studio
- Jitterbit API Manager
- Jitterbit Cloud Datastore (optional) (Applicable only to the Contextual and Salesforce Q&A agents)
Azure resources
You must have a Microsoft Azure subscription with permissions to create and manage Azure OpenAI with a deployed gpt-4o model.
Tip
To select pricing tiers based on your specific requirements and anticipated usage, see Azure OpenAI pricing.
Supported endpoints
The following endpoints are incorporated into the agent's design.
LLM
Azure OpenAI is used as the large language model (LLM).
Chat interface
The agent's design incorporates Slack as the chat interface for interacting with the AI agent.
Example prompts
Here are example prompts the agent can handle:
- "What is the capital of the USA?"
- "Who was the first president of India?"
If you are using the Salesforce Q&A Agent to get account details for a customer:
- "Can you give me details for customer 'ABC Inc.'?"
Installation, configuration, and operation
Follow these steps to install, configure, and operate this AI agent:
- Download customizations and install the Integration Studio project.
- Review project workflows.
- Create Microsoft Azure resources.
- Prepare Jitterbit Cloud Datastore.
- Configure project variables.
- Test connections.
- Deploy the project.
- Create the Jitterbit custom API.
- Create the Slack app, test the Slack connection, and re-deploy the project.
Download customizations and install the project
Follow these steps to download customization files and install the Integration Studio project for the AI agent:
-
Log in to the Harmony portal at https://login.jitterbit.com and open Marketplace.
-
Based on your need, locate one of these agents:
- Reactive Agent
- Contextual Agent
- Salesforce Q&A Agent
To locate the agent, you can use the search bar or, in the Filters pane under Type, select AI Agent to limit the display to the available AI agents.
-
Click the AI agent's Documentation link to open its documentation in a separate tab. Keep the tab open to refer back to after starting the project.
-
Click Start Project to open a two-step configuration dialog to download customizations and import the AI agent as an Integration Studio project.
-
In configuration step 1, Download Customizations, the following file can be used to create the Slack app. Select the file and click Download Files:
-
Slack app manifest file
slack_app_manifest.json
Tip
The configuration dialog includes a warning not to import the template before applying endpoint customizations. That warning does not apply to this AI agent and can be ignored. Follow the recommended order of steps in this documentation.
Click Next.
-
-
In configuration step 2, Create a New Project, select an environment where the Integration Studio project will be created, then click Create Project.
-
A progress dialog will be displayed. Once it indicates the project is created, use the dialog link Go to Integration Studio or open the project directly from the Integration Studio Projects page.
Review project workflows
In the open Integration Studio project, review the workflows along with the descriptions below to understand what they do.
-
Main Entry - Slack API Request Handler
This workflow manages incoming Slack bot requests. It is triggered via a Jitterbit custom API each time your team interacts with the Slack bot chat UI (that is, sends a Slack message to it). Configuration of the custom Jitterbit API is described in Create the Jitterbit custom API later on this page.
-
Main - AI Agent Tools Logic
This workflow handles user queries received from the
Main Entry - Slack API Request Handler, managing requests to the large language model (LLM) and capturing its responses. -
Utility - Bot Chat Cloud Datastore
(Applicable only to the Contextual and Salesforce Q&A agents.)
This workflow manages the storage of bot chat history, which is essential for providing memory context to LLMs. It leverages Jitterbit Cloud Datastore for this purposes.
-
Tool - Get SalesForce Account Details
(Applicable only to the Salesforce Q&A Agent.)
This workflow is designed to retrieve specific Salesforce account details when a tool call is initiated.
Create Microsoft Azure resources
Create the following Microsoft Azure resources and retain the following information for configuring the AI agent. To create and manage these resources, you must have a Microsoft Azure subscription with the appropriate permissions.
Azure OpenAI resource
You must create an Azure OpenAI resource and deploy a gpt-4o model via the Azure AI Foundry portal.
You'll need the deployment name, Azure OpenAI endpoint URL, and API key to determine the values of the Azure OpenAI project variables. To find these values:
- In the Azure AI Foundry portal, open the specific OpenAI resource.
-
The values to use for the endpoint URL (
azure_openai_base_url) and API key (azure_openai_api_key) are displayed on the landing page for the resource:
-
In the navigation menu under Shared resources, select Deployments. The deployment name (
Azure_OpenAI_Deployment_Name) is displayed.
Prepare Jitterbit Cloud Datastore
(Applicable only to the Contextual and Salesforce Q&A agents.)
Create two key storages in Jitterbit Cloud Datastore, askjb_user_session and askjb_q_and_a, whose fields have the names and types listed in the tables below.
As you add custom fields, use the tables below to determine whether each field should be toggled to Required in the Cloud Datastore user interface. The AlternativeKey and Value fields are default fields that cannot be removed or toggled.
You can leave blank the values of fields whose values are auto-populated or not used.
askjb_user_session
This key storage is used to maintain sessions for users.
| Name | Type | Required | Value definition | Description |
|---|---|---|---|---|
Key |
Text | Yes | Auto-populated | The email address of the user. This will be auto-generated during execution. No manual entry is required. |
AlternativeKey |
Text | No | Auto-populated | The session for the user will be auto-generated during execution. No manual entry is required. |
Value |
Text | No | Not used | Not used. |
askjb_q_and_a
This key storage retains a bot's chat history to provide memory context for the LLM. It is used by the integration to store question and answer history. All data is entered automatically during the interaction run.
| Name | Type | Required | Value definition | Description |
|---|---|---|---|---|
Key |
Text | Yes | Auto-populated | Specifies the unique identifier assigned to a message by the system. |
AlternativeKey |
Text | No | Auto-populated | Specifies the unique identifier assigned to a chat session by the system. |
Value |
Text | No | Not used | Not used. |
slackChannel |
Text | Yes | Auto-populated | The Slack channel ID from which the message is sent. |
User |
Text | Yes | Auto-populated | The Slack username of the user who sends the message. |
FirstName |
Text | No | Auto-populated | First name of the user who sends the message. |
LastName |
Text | No | Auto-populated | Last name of the user who sends the message. |
Email |
Text | Yes | Auto-populated | Email address of the user who sends the message. |
MessageTimestampText |
Text | Yes | Auto-populated | The timestamp text of the message. |
UserQuestion |
Big Text | Yes | Auto-populated | The question or message submitted by the user to the AI agent. |
AIAnswer |
Big Text | Yes | Auto-populated | The response generated by the AI agent to the user's question. |
ai_reformulate_question |
Big Text | No | Auto-populated | The user's question after being reformulated or rephrased by the AI to improve understanding. |
Configure project variables
In the Integration Studio project installed earlier via Marketplace, you must set values for the following project variables.
This can be done using the project's actions menu to select Project Variables to open a drawer along the bottom of the page where you can review and set the values.
Cloud Datastore
(Applicable only to the Contextual and Salesforce Q&A agents.)
| Variable name | Description |
|---|---|
Cloud_Datastore_Access_Token |
Cloud Datastore access token, generated in the Management Console Access tokens page. |
Salesforce
(Applicable only to the Salesforce Q&A Agent.)
| Variable name | Description |
|---|---|
SF_Login_URL |
Server Host in the Salesforce connection |
SF_Password |
Password in the Salesforce connection |
SF_Security_Token |
Security token in the Salesforce connection |
SF_User_Name |
Username in the Salesforce connection |
Azure OpenAI
| Variable name | Description |
|---|---|
top_p |
Controls how much of the probability mass the model considers when generating text. Default value: 0.95.
|
temperature |
Controls the randomness of model output. Default value: 0.2 for deterministic answers.
|
Azure_OpenAI_Deployment_Name |
The name of the Azure OpenAI deployment used to access the model. |
azure_openai_base_url |
The base URL for accessing the Azure OpenAI service. Example: https://<your-resource-name>.openai.azure.com. |
azure_openai_api_key |
The API key used to authenticate requests to the Azure OpenAI service. |
Generic_System_Prompt |
The input text or instruction provided to the AI model that guides how it should generate a response. For example, "You are an AI assistant that helps users find accurate and relevant information." |
Slack
| Variable name | Description |
|---|---|
bot_oauth_user_token |
The Slack bot token that is obtained after creating the Slack app, used for the Bot user OAuth access token in the Slack connection. |
Note
The Slack app is created in a later step. For now, you can leave this variable blank.
Test connections
Test the endpoint configurations to verify connectivity using the defined project variable values.
This can be done from the design component palette's Project endpoints and connectors tab by hovering on each endpoint and clicking Test.
Deploy the project
Deploy the Integration Studio project. This can be done using the project's actions menu to select Deploy.
Create the Jitterbit custom API
Create a custom API for the Slack Bot Request operation in the Main Entry - Slack API Request Handler workflow. This can be done directly in Integration Studio using the operation's actions menu to select Publish as an API or select Publish as an API using AI.
Keep the default settings except for the following:
- Method:
POST - Response Type:
System Variable
Retain the service URL of the published API for use in creating the Slack app. The service URL can be found in the API details drawer on the Services tab by hovering on the service's Actions column and clicking Copy API service URL.
Create the Slack app, test the connection, and re-deploy the project
To create the AI agent chat interface in Slack, create a Slack app using the Slack app manifest file provided with this AI agent's customization files. Or, create it from scratch.
If using the provided Slack app manifest file (slack_app_manifest.json), you must replace the following placeholders with your own configuration values:
| Placeholder | Description |
|---|---|
{{Replace with Slack bot name}} |
The name you want your Slack bot to have, as displayed to users. There are two places in the manifest where you must replace this value. |
{{Replace with Jitterbit API URL}} |
The service URL of the Jitterbit custom API you created in Create the Jitterbit custom API. |
After installing the Slack app, obtain its bot token.
Re-open the project variables configuration and enter the bot token for the bot_oauth_user_token project variable value.
Once the bot token is set, test the Slack connection and re-deploy the project.
Trigger the project workflows
The main workflow, Main Entry - Slack API Request Handler, is triggered by the Jitterbit custom API. This workflow is triggered from Slack via the Slack Bot API Request Handler custom API. Sending a direct message to the Slack app will initiate the custom API trigger.
All other workflows are triggered by other operations and are downstream of that listed above. They are not intended to be run by themselves.
Troubleshooting
Review API logs and operation logs for detailed troubleshooting information.
For additional assistance, contact Jitterbit support.