AI Agent
Provides a generic AI agent implementation handling the feedback loop between user requests, tool calls and LLM responses. Compatible with 8.8.0-alpha6 or later.
Required inputs
| Key | Label | Type |
|---|---|---|
provider.anthropic.authentication.apiKey | Anthropic API key | secret |
provider.bedrock.region | Region | FEEL expression |
provider.bedrock.authentication.accessKey | Access key | secret |
provider.bedrock.authentication.secretKey | Secret key | secret |
provider.openai.authentication.apiKey | OpenAI API key | secret |
provider.anthropic.model.model | Model | FEEL expression |
provider.bedrock.model.model | Model | FEEL expression |
provider.openai.model.model | Model | FEEL expression |
data.systemPrompt.prompt | System prompt | FEEL expression |
data.userPrompt.prompt | User prompt | FEEL expression |
data.agentContext | Agent context | FEEL expression |
Optional inputs
| Key | Label | Type |
|---|---|---|
provider.type | Provider | string |
provider.bedrock.authentication.type | Authentication | string |
provider.openai.authentication.organizationId | Organization ID | FEEL expression |
provider.openai.authentication.projectId | Project ID | FEEL expression |
provider.openai.endpoint | Custom API endpoint | FEEL expression |
provider.openai.headers | Custom headers | FEEL expression |
provider.anthropic.model.parameters.maxTokens | Maximum tokens | secret |
provider.anthropic.model.parameters.temperature | Temperature | FEEL expression |
provider.anthropic.model.parameters.topP | top P | FEEL expression |
provider.anthropic.model.parameters.topK | top K | FEEL expression |
provider.bedrock.model.parameters.maxTokens | Maximum tokens | secret |
provider.bedrock.model.parameters.temperature | Temperature | FEEL expression |
provider.bedrock.model.parameters.topP | top P | FEEL expression |
provider.openai.model.parameters.maxCompletionTokens | Maximum completion tokens | secret |
provider.openai.model.parameters.temperature | Temperature | FEEL expression |
provider.openai.model.parameters.topP | top P | FEEL expression |
data.systemPrompt.parameters | System prompt parameters | FEEL expression |
data.userPrompt.parameters | User prompt parameters | FEEL expression |
data.userPrompt.documents | Documents | FEEL expression |
data.tools.containerElementId | Ad-hoc sub-process ID | FEEL expression |
data.tools.toolCallResults | Tool call results | FEEL expression |
data.memory.storage.type | Memory storage type | string |
data.memory.storage.timeToLive | Document TTL | FEEL expression |
data.memory.storage.customProperties | Custom document properties | FEEL expression |
data.memory.contextWindowSize | Context window size | string |
data.limits.maxModelCalls | Maximum model calls | string |
data.response.format.type | Response format | string |
data.response.format.parseJson | Parse text as JSON | string |
data.response.format.schema | Response JSON schema | FEEL expression |
data.response.format.schemaName | Response JSON schema name | FEEL expression |
data.response.includeAssistantMessage | Include assistant message | string |
resultVariable | Result variable | string |
resultExpression | Result expression | FEEL expression |
errorExpression | Error expression | FEEL expression |
retryCount | Retries | FEEL expression |
retryBackoff | Retry backoff | string |
Apply this connector with @bpmnkit/connectors
import { applyConnectorTemplate } from "@bpmnkit/connectors"
const result = applyConnectorTemplate("io.camunda.connectors.agenticai.aiagent.v1", {
"provider.anthropic.authentication.apiKey": "<your anthropic api key>",
"provider.bedrock.region": "= ...",
"provider.bedrock.authentication.accessKey": "<your access key>",
"provider.bedrock.authentication.secretKey": "<your secret key>",
"provider.openai.authentication.apiKey": "<your openai api key>",
"provider.anthropic.model.model": "= claude-3-5-sonnet-20240620",
"provider.bedrock.model.model": "= anthropic.claude-3-5-sonnet-20240620-v1:0",
"provider.openai.model.model": "= gpt-4o",
"data.systemPrompt.prompt": "= You are **TaskAgent**, a helpful, generic chat agent that can handle a wide variety of customer requests using your own domain knowledge **and** any tools explicitly provided to you at runtime.
If tools are provided, you should prefer them instead of guessing an answer. You can call the same tool multiple times by providing different input values. Don't guess any tools which were not explicitely configured. If no tool matches the request, try to generate an answer. If you're not able to find a good answer, return with a message stating why you're not able to.
Wrap minimal, inspectable reasoning in *exactly* this XML template:
<thinking>
<context>…briefly state the customer’s need and current state…</context>
<reflection>…list candidate tools, justify which you will call next and why…</reflection>
</thinking>
Reveal **no** additional private reasoning outside these tags.
",
"data.userPrompt.prompt": "= ...",
"data.agentContext": "= =agent.context",
"provider.type": "anthropic",
"provider.bedrock.authentication.type": "defaultCredentialsChain",
})