For the complete documentation index, see llms.txt.
Skip to main content
Version: 8.10 (unreleased)

Example AI Agent Sub-process connector integration

This worked example demonstrates how to use the AI Agent Sub-process connector applied to an ad-hoc sub-process to model an AI Agent agent loop for tools and response interaction.

Create an AI Agent element​

As the AI Agent Sub-process implementation implicitly creates an agent loop for tools, you only need to add an ad-hoc sub-process with an applied AI Agent connector template to the process.

info

For more information on how to model the tools available to the AI agent, see tool definitions.

AI Agent Sub-process

After adding the element, open the properties panel to configure the connection to your model provider, and modify the system and user prompts as required.

Response follow-up​

Separately from the agent loop for tools, a response follow-up acting on the agent response can be added by re-entering the AI Agent connector with new information. You must model your user prompt so that it adds the follow-up data instead of the initial request.

For example, your User Prompt field could contain the following FEEL expression to make sure it acts upon follow-up input:

=if (is defined(followUpInput)) then followUpInput else initialUserInput

With the AI Agent Sub-process implementation, the follow-up needs to be modeled to loop back to the AI Agent ad-hoc sub-process:

AI Agent Sub-process with response follow-up

note

How you model this type of follow-up greatly depends on your specific use case.

  • The example follow-up expects a simple feedback action based on a user task, but this could also interact with other process flows or another agent process.
  • Instead of the user task, you could also use another LLM connector to verify the response of the AI Agent. For an example of this pattern, see the fraud detection example.

Additional resources​

  • The connectors repository contains a set of ready-made examples using the AI Agent Sub-process connector.