- Overview
- UiPath GenAI Activities
- Release notes
- About the UiPath GenAI Activities package
- Project compatibility
- Content Generation
- Update Context Grounding Index
- Context Grounding Search
- Summarize Text
- PII Filtering
- Translate
- Detect Language
- Rewrite
- Generate Email
- Categorize
- Named Entity Recognition
- Image Analysis
- Detect Object
- Signature Similarity
- Sentiment Analysis
- Reformat
- Semantic Similarity
- Image Comparison
- Image Classification
- Working with UiPath GenAI activities
- Supported models
- Frequently asked questions
- Act! 365
- ActiveCampaign
- Adobe Acrobat Sign
- Adobe PDF Services
- Amazon Bedrock
- Amazon Connect
- Amazon Polly
- Amazon SES
- Amazon Transcribe
- Anthropic Claude
- Asana
- AWeber
- Azure AI Document Intelligence
- Azure Maps
- BambooHR
- Box
- Release notes
- About the Box activity package
- Project compatibility
- Add Shared Link to File
- Add Shared Link to Folder
- Search for Content
- Cancel Sign Request
- List Sign Requests
- Create Sign Request
- Resend Sign Request
- Upload File Version
- Copy File
- Delete File
- Download File
- Get File Info
- Get Folder Items
- Upload File
- Copy Folder
- Create Folder
- Delete Folder
- Delete Record
- Get Record
- Insert Record
- Replace Record
- List All Records
- Brevo
- Calendly
- Campaign Monitor
- Cisco Webex Teams
- Citrix ShareFile
- Clearbit
- Confluence Cloud
- Constant Contact
- Coupa
- Customer.io
- Datadog
- Deputy
- Discord - Preview
- DocuSign
- Drip
- Dropbox
- Dropbox Business
- Egnyte
- Eventbrite
- Exchangerates
- Expensify
- Facebook
- Freshbooks
- Freshdesk
- Freshsales
- Freshservice
- GetResponse
- GitHub
- Google Maps
- Google Speech-to-Text
- Google Text-to-Speech
- Google Vertex
- Google Vision - Preview
- GoToWebinar
- Release Notes
- About the GoToWebinar activity package
- Project compatibility
- Delete Webinar
- Get Webinar
- Get Webinar Meeting Times
- Get Webinar Registrant
- Get Webinar Start URL
- List Account Webinars
- List All In Session Webinars
- List All Webinar Attendees
- List All Webinar Registrants
- List All Webinars
- Quick Create Webinar
- Quick Update Webinar
- Search Recording Assets
- Delete Record
- Get Record
- Insert Record
- List All Records
- List Records
- API References
- Greenhouse
- Hootsuite
- HTTP Webhook
- Hubspot CRM
- HubSpot Marketing
- Icertis - Preview
- iContact
- Insightly CRM
- Intercom
- Jina.ai
- Jira
- Release notes
- About the Jira activity package
- Project compatibility
- Create Issue
- Add Issue Attachment
- Download Issue Attachment
- Get Instance Details
- Add Comment
- Get Comments
- Get Issue
- Search Issues by JQL
- Update Issue
- Update Issue Assignee
- Find User by Email Address or Display Name
- Update Issue Status
- Delete Record
- Get Record
- Insert Record
- List All Records
- Replace Record
- Upsert Record
- Invoke Operation
- Delete Issue
- Event Trigger
- Keap
- Klaviyo
- LinkedIn
- Mailchimp
- Mailjet
- MailerLite
- Mailgun
- Marketo
- Microsoft Azure OpenAI
- Microsoft Dynamics CRM
- Microsoft Sentiment
- Microsoft Teams
- Release Notes
- About the Microsoft Teams activity package
- Project compatibility
- Create Channel
- Invite Member to Channel
- List All Channels
- Send Individual Chat Message
- Reply to Channel Message
- Create Online Teams Meeting
- Send Channel Message
- Send Group Chat Message
- Get Channel by Name
- Get Individual Chat
- Get Team by Name
- Invite User to Team
- List All Channel Messages
- List All Chat Messages
- List All Team Members
- Get Online Teams Meeting
- List All Recordings
- List All Transcripts
- Download Meeting Transcript/Recording
- List All Records
- Insert Record
- Update Record
- Get Record
- Delete Record
- Technical references
- Microsoft Translator
- Microsoft Vision
- Miro
- Okta
- OpenAI
- Release Notes
- About the OpenAI activity package
- Project compatibility
- Generate Chat Completion
- Generate Text Completion
- Oracle Eloqua
- Oracle NetSuite
- PagerDuty
- Paypal
- PDFMonkey
- Pinecone
- Pipedrive
- QuickBooks Online
- Quip
- Salesforce
- Release Notes
- About the Salesforce activity package
- Project compatibility
- Create Account
- Update Account
- Create Contact
- Update Contact
- Create Lead
- Update Lead
- Create Opportunity
- Upload File
- Download File
- Search Records
- Get Opportunity
- Get Lead
- Get Contact
- Get Account
- Add File to Record
- Create Bulk Upload Job
- Get Bulk Job Info
- Starts or Aborts Bulk Job
- Download SOQL Bulk Job Results
- Download Unprocessed Records of Bulk Upload
- Create Bulk Download Job Using SOQL
- Search Using String
- Get Object Fields
- Insert Record
- Get Record
- Delete Record
- Update Record
- List All Records
- Salesforce Marketing Cloud
- SAP BAPI - Preview
- SAP Cloud for Customer
- SAP Concur
- SAP OData - Preview
- SendGrid
- ServiceNow
- Release Notes
- About the ServiceNow activity package
- Project compatibility
- Troubleshooting
- Create New Incident
- Create Incident Task
- List All Incidents
- Update Incident
- Add Attachment
- Download Attachment
- Get Incident Task
- Get Attachment
- List All Attachments
- List All Incident Tasks
- Update Incident Task
- When an Event Happens
- Delete Attachment
- Delete Record
- Get Record
- Insert Record
- List All Records
- Update Record
- Incident Created
- Incident Updated
- Incident Task Created
- Incident Task Updated
- Record Created
- Record Updated
- Shopify
- Slack
- Release Notes
- About the Slack activity package
- Project compatibility
- Create Channel
- Invite Users to Channel
- Remove User from Channel
- Send File to Channel
- Send Message to Channel
- Send Message to User
- Send Reply
- Send Button Response
- Create User Group
- Get User
- List All User Groups
- List All Users
- Set Channel Topic
- Join Channel
- Archive Channel
- Create Group Direct Message
- Get Channel Info
- Button Clicked
- Troubleshooting
- SmartRecruiters
- Smartsheet
- Release notes
- About the Smartsheet activity package
- Project compatibility
- Attach URL to Sheet
- Add Column
- Update Column
- Add Row
- Update Row
- Get Sheet
- List All Sheets
- Attach File to Comment
- Search Everything
- Update Sheet
- Create Sheet from Template
- Send Sheet Via Email
- List All Folders
- Download Attachment
- Attach File to Row
- Attach URL to Row
- Attach File to Sheet
- List All Workspaces
- List All Attachments
- Delete Row
- Download Sheet
- Search Sheets
- Insert Record
- Get Record
- List All Records
- Delete Record
- Snowflake
- Stripe
- Sugar Enterprise
- Sugar Professional
- Sugar Sell
- Sugar Serve
- TangoCard
- Todoist
- Trello
- Twilio
- IBM WatsonX
- WhatsApp Business
- WooCommerce
- Workable
- Workday
- Workday REST
- X (formerly Twitter)
- Xero
- Release notes
- About the Xero activity package
- Project compatibility
- Create Contact
- List All Contacts
- Add Attachment to Contact
- Get Balance Sheet Report
- Get BAS Report
- Get GST Report
- Get Bank Summary Report
- Get Aged Receivables by Contact Report
- Get Attachments of a Contact
- Get Budget Summary Report
- Get Profit and Loss Report
- Get Trial Balance Report
- Get Executive Summary Report
- Get Aged Payables by Contact Report
- List Reports
- Delete Record
- List All Records
- Get Record
- Insert Record
- Replace Record
- Youtube
- Zendesk
- Zoho Campaigns
- Zoho Desk
- Zoho Mail
- Zoom
- ZoomInfo
Integration Service Activities
Generate Chat Completion
UiPath.OpenAI.IntegrationService.Activities.GenerateChatCompletion
Given a user prompt and additional options like instruction (that may include conversation history), this activity generates a text completion response. This activity defaults to the GPT-3.5-Turbo model, but also allows access to GPT-4. Both of these models are optimized for chat, hence the name of the activity. Read more about the Chat Completions API.
Please note that this activity, while giving users the ability to add conversation history, does not actually keep previous requests and responses from the model in memory. It is state-less. Each OpenAI Chat activity would require the user to provide the full dialogue history as context in the prompt.
-
Connection ID - The connection established in Integration Service. Access the dropdown menu to choose, add, or manage connections.
- Model name - The large language model (LLM) to use for the chat completion. Select one of the available options from the drop-down list: GPT-4, GPT-3.5, GPT-4V. Default value is GPT-4. You can read more on the differences between these models in the OpenAI documentation.
- Prompt - The prompt you want to use for the generation of the chat completion. Read more about prompt engineering.
- Image type - The type of image to send
along with a message if image analysis is needed. This field is displayed if you
select the GPT-4V model. Select one of the available options: Image file, Image
URL. Supported file formats: PNG (.png), JPEG (.jpeg and .jpg), WEBP (.webp),
and non-animated GIF (.gif)
- Image file -
Select an image file using a variable. This field supports
IResource
type input. - Image URL - The
image URL to send along with a message if image analysis is needed. This
field supports
String
type input.
- Image file -
Select an image file using a variable. This field supports
Manage Properties
Use the Manage Properties wizard to configure or use any of the object's standard or custom fields. You can select fields to add them to the activity canvas. The added standard or custom fields are available in the Properties panel (in Studio Desktop) or under Show additional properties (in Studio Web).
Additional properties
- Instruction - Instructions on how you want the AI to generate the chat completion response. This is the equivalent of the system role discussed in the OpenAI docs. The Assistant role is not currently available in this activity.
- Model Name - The large language model (LLM) to use for the chat completion. You can choose between
gpt-3.5-turbo
andgpt-4
.By default,gpt-4
is selected. - Max Tokens - The maximum number of tokens allowed for the prompt and generated answer. Fewer tokens are less expensive. Most models support a maximum of 4096 tokens, however, some models support only 2048. Default value is 1920. Read more about tokens.
- N - The number of completion choices you want the AI to return. The minimum value of this field is
1
. Default value is1
. - Temperature - A number between 0 and 2. Higher values like
0.8
make the output more random, while lower values like0.2
make it more focused and deterministic. Default value is1
. - Top P - A number between 0 and 1. The lower the number, the fewer tokens are considered. Defaults to
1
. - Stream - Specifies whether to stream back partial progress. If set, tokens are sent as data-only server-sent events as they become
available, with the stream terminated by a
data:[DONE]
message. Defaults tofalse
. - Stop - Up to 4 sequences where the API stops generating further tokens. The returned text does not contain the stop sequence.
Defaults to
null
. - Presence Penalty - A number between -2.0 and 2.0. Positive values penalize new tokens based on whether they appear in the text so far, increasing
the model’s likelihood to talk about new topics. Defaults to
0
. - Frequency Penalty - Number between -2.0 and 2.0. Positive values penalize new tokens based on their existing frequency in the text so far,
decreasing the model’s likelihood to repeat the same line verbatim. Defaults to
0
. - User - A unique identifier representing your end-user, which can help OpenAI to monitor and detect abuse. Defaults to
null
.
Output
- Top Generated Text - The top generated chat completion string. If you are interested in only returning a single response (i.e., N=1, which is
the default), this will be the output you most likely will want to use. It is a
Text
data type which is easy to assign a variable to and use directly in other activities/text inputs. - Generate Chat Completion - Automatically generated output variable. The top generated chat completion string. If you are interested in only returning
a single response (i.e., N=1, which is the default), this will be the output you most likely will want to use. It is a ‘Text’
data type which is easy to assign a variable to and use directly in other activities/text inputs.
-
Choices - or responses from the model. You can set the total number of responses that you want back from the model using the ‘N’ field in the additional options of the activity which defaults to 1. This will return as an array with the first object starting at 0. Ex. Referencing a single object in an array within a For Each control:
Response.Choices(0).Text
. For more information, see the Chat Completion object documentation.
-