Skip to content

Commit c90d76c

Browse files
authored
Update usage type terms to match UI updates (#11246)
* Update usage type terminology to match UI * Proofread
1 parent 651b15c commit c90d76c

1 file changed

Lines changed: 17 additions & 16 deletions

File tree

content/en/docs/marketplace/genai/reference-guide/agent-commons.md

Lines changed: 17 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,10 @@ weight: 20
99
## Introduction
1010

1111
The [Agent Commons](https://marketplace.mendix.com/link/component/240371) module enables users to develop, test, and optimize their GenAI use cases by creating effective agents that interact with large language models (LLMs).
12+
1213
With the Agent Commons module, you can use the Agent Builder interface within your app to define agents at runtime and manage multiple versions over time.
1314

14-
You can wire up prompts, microflows (as tools), knowledge bases, and large language models to build agentic patterns that support your business logic. The Agent Builder also allows you to define variables that act as placeholders for data from the app session context, which are replaced with actual values when the end user interacts with the app.
15+
You can wire up prompts, microflows (as tools), knowledge bases, and large language models to build agentic patterns that support your business logic. Agent Builder also allows you to define variables that act as placeholders for data from the app session context, which are replaced with actual values when the end user interacts with the app.
1516

1617
The Agent Commons module includes the necessary data model, pages, and snippets to seamlessly integrate the agent builder interface into your app and start using agents within your app logic.
1718

@@ -31,7 +32,7 @@ The Agent Commons module offers the following features:
3132

3233
* Agent Builder UI components and data model for managing, storing, and rapidly iterating on agent versions at runtime. No app deployment is required to update an agent.
3334

34-
* Drag and drop operations for calling both single-call and conversational agents from microflows and workflows.
35+
* Drag-and-drop operations for calling both task and chat agents from microflows and workflows.
3536

3637
* Adding tools and knowledge bases to enhance the agent's capabilities
3738

@@ -100,13 +101,13 @@ To interact with LLMs using Agent Commons, you need at least one GenAI connector
100101

101102
### Defining the Agent {#define-agent}
102103

103-
When the app is running, a user with the `AgentAdmin` role can set up agents, write prompts, link microflows or MCP servers as tools, and provide access to knowledge bases. Once an agent version is associated with a deployed model, it can be tested in an isolated environment, separate from the rest of the app’s logic, to effectively validate its behavior.
104+
When the app is running, a user with the `AgentAdmin` role can set up agents, write prompts, link microflows or MCP servers as tools, and provide access to knowledge bases. Once an agent version is associated with a deployed model, it can be tested in an isolated environment, separate from the rest of the app’s logic, to validate its behavior.
104105

105106
Users can create two types of agents:
106107

107-
* **Conversational Agent**: Intended for scenarios where the end user interacts through a chat interface, or where the agent is called conversationally by another agent.
108+
* **Chat Agent**: Intended for scenarios where the end user interacts through a chat interface, or where the agent is called conversationally by another agent.
108109

109-
* **Single-Call Agent**: Designed for isolated agentic patterns such as background processes, subagents in an Agent-as-Tool setup, or any use case that doesn't require a conversational interface with historical context.
110+
* **Task Agent**: Designed for isolated agentic patterns such as background processes, subagents in an Agent-as-Tool setup, or any use case that doesn't require a conversational interface with historical context.
110111

111112
{{< figure src="/attachments/appstore/platform-supported-content/modules/genai/agentcommons/agentbuilderUI.png" >}}
112113

@@ -134,12 +135,12 @@ To allow your agent to act dynamically and autonomously or to access specific da
134135

135136
For more technical details, see the [Function Calling](/appstore/modules/genai/function-calling/) documentation.
136137

137-
##### Adding tools from MCP servers
138+
##### Adding Tools from MCP Servers
138139

139-
Besides microflow tools, tools exposed by MCP servers are also supported. To add MCP tools to an agent version, select an MCP server configuration from the [MCP client module](/appstore/modules/genai/mcp-modules/mcp-client/). You can then choose one of two to add MCP tools:
140+
Besides microflow tools, tools exposed by MCP servers are also supported. To add MCP tools to an agent version, select an MCP server configuration from the [MCP client module](/appstore/modules/genai/mcp-modules/mcp-client/). You can then choose one of two ways to add MCP tools:
140141

141-
* **Use all available tools**: imports the entire server, including all tools it provides. This also means less control over individual tools and if tools are added in the future, that they get added automatically on agent execution.
142-
* **Select Tools**: allows you to import specific tools from the server and changing specific fields for individual tools.
142+
* **Use all available tools**: Imports the entire server, including all tools it provides. This also means less control over individual tools, and if tools are added in the future, they get added automatically on agent execution.
143+
* **Select Tools**: Lets you import specific tools from the server and change specific fields for individual tools.
143144

144145
#### Adding Knowledge Bases
145146

@@ -150,13 +151,13 @@ For supported knowledge bases registered in your app, you can connect them to ag
150151
* [OpenAI Connector](/appstore/modules/genai/reference-guide/external-connectors/openai/#azure-ai-search)
151152
* [PgVector Knowledge Base](/appstore/modules/genai/reference-guide/external-connectors/pgvector/#general-configuration)
152153

153-
To allow an agent to perform semantic searches, add the knowledge base to the agent definition and configure the retrieval parameters, such as the number of chunks to retrieve, and the threshold similarity. Multiple knowledge bases can be added to the agent to pick from. Give each knowledge base a name and description (in human language) so that the model can decide which retrieves are necessary based on the input it gets.
154+
To allow an agent to perform semantic searches, add the knowledge base to the agent definition and configure the retrieval parameters, such as the number of chunks to retrieve, and the threshold similarity. Multiple knowledge bases can be added to the agent to pick from. Give each knowledge base a name and description (in human language) so that the model can decide which retrievals are necessary based on the input it gets.
154155

155156
Note that [user access approval](/appstore/modules/genai/genai-for-mx/commons/#enum-useraccessapproval) can only be set to `HiddenForUser` or `VisibleForUser` for knowledge base retrievals.
156157

157158
#### Testing and Refining the Agent
158159

159-
While writing the system prompt (for both conversational and single-call types) or the user prompt (only for the single-call type), the prompt engineer can include variables by enclosing them in double braces, for example, `{{variable}}`. The actual values of these placeholders are typically known at runtime based on the user's page context.
160+
While writing the system prompt (for both chat and task types) or the user prompt (only for the task type), the prompt engineer can include variables by enclosing them in double braces, for example, `{{variable}}`. The actual values of these placeholders are typically known at runtime based on the user's page context.
160161
To test the behavior of the prompts, a test can be executed. The prompt engineer must provide test values for all variables defined in the prompts. Additionally, multiple sets of test values for the variables can be defined and run in bulk. Based on the test results, the prompt engineer can add, remove, or rephrase certain parts of the prompt.
161162

162163
### Using the Agent in the App Logic {#app-logic}
@@ -165,16 +166,16 @@ After a few quick iterations, the first version of the agent is typically ready
165166

166167
#### Creating a Version
167168

168-
New agents will be created in the draft status by default, meaning they are still being worked on and can be tested using the agent commons module only. Once an agent is ready to be integrated into the app logic (i.e., logic triggered by end users), it must be saved as a version. This will store a snapshot of the prompt texts and the configured microflows as tools and knowledge bases. To select the active version for the agent, use the three-dot ({{% icon name="three-dots-menu-horizontal" %}}) menu option on the agent overview and click **Select Version in use**.
169+
New agents will be created in the draft status by default, meaning they are still being worked on and can be tested using the agent commons module only. Once an agent is ready to be integrated into the app logic (that is, logic triggered by end users), it must be saved as a version. This will store a snapshot of the prompt texts and the configured microflows as tools and knowledge bases. To select the active version for the agent, use the three-dot ({{% icon name="three-dots-menu-horizontal" %}}) menu option on the agent overview and click **Select Version in use**.
169170

170171
#### Calling the Agent from a Microflow {#call-agent-microflow}
171172

172173
For most use cases, a `Call Agent` microflow activity can be used. You can find these actions in Studio Pro **Toolbox**, under the **Agents Kit** category while editing a microflow. Take a look at the table below if you are unsure which action to use based on your [agent type](#define-agent):
173174

174175
| Toolbox action name | Supported agent types | Description |
175176
|---|---|---|
176-
| [Call Agent with History](#call-agent-with-history) | Single-Call, Conversational | This action returns the assistant response for a single user message or based on a conversation history. The user message or an alternating chat history of the user and assistant message needs to be added to the request before calling this action. See [Add Message to Request](/appstore/modules/genai/genai-for-mx/commons/#chat-add-message-to-request) <br> This operation is designed for conversational agents, but will work for single-call agents as well; note that in that case, the user prompt defined on the agent version is ignored. |
177-
| [Call Agent without History](#call-agent-without-history) | Single-Call | This action returns the assistant response for a single user message. For Single-Call agents, the user message is already part of the agent version and thus does not need to be passed explicitly or added to the optional request. |
177+
| [Call Agent with History](#call-agent-with-history) | Task, Chat | This action returns the assistant response for a single user message or based on a conversation history. The user message or an alternating chat history of the user and assistant message needs to be added to the request before calling this action. See [Add Message to Request](/appstore/modules/genai/genai-for-mx/commons/#chat-add-message-to-request) <br> This operation is designed for chat agents, but will work for task agents as well; note that in that case, the user prompt defined on the agent version is ignored. |
178+
| [Call Agent without History](#call-agent-without-history) | Task | This action returns the assistant response for a single user message. For Task agents, the user message is already part of the agent version and thus does not need to be passed explicitly or added to the optional request. |
178179

179180
##### Call Agent with History {#call-agent-with-history}
180181

@@ -188,15 +189,15 @@ To use it:
188189
4. Optional: For more specific use cases, a context object can be passed for variable replacement. This object needs to be of the entity that was selected while [defining the agent](#define-context-entity).
189190
5. Pass both the `Request`, Agent, and optionally the context object to the `Call Agent with History` activity.
190191

191-
For a conversational agent, the chat context can be created based on the agent in one convenient operation. Use the `New Chat for Agent` operation from the **Toolbox** under the **Agents Kit** category. Retrieve the agent (for example, by name) and pass it with your custom context object to the operation. Note that this sets the system prompt for the chat context, making it applicable to the entire (future) conversation. Similar to other chat context operations, an action microflow needs to be selected for this microflow action. For more information, see the [Creating a Custom Action Microflow](/appstore/modules/genai/genai-for-mx/conversational-ui/#action-microflow) section of Conversational UI.
192+
For a chat agent, the chat context can be created based on the agent in one convenient operation. Use the `New Chat for Agent` operation from the **Toolbox** under the **Agents Kit** category. Retrieve the agent (for example, by name) and pass it with your custom context object to the operation. Note that this sets the system prompt for the chat context, making it applicable to the entire (future) conversation. Similar to other chat context operations, an action microflow needs to be selected for this microflow action. For more information, see the [Creating a Custom Action Microflow](/appstore/modules/genai/genai-for-mx/conversational-ui/#action-microflow) section of Conversational UI.
192193

193194
{{% alert color="info" %}}
194195
Download the [Agent Builder Starter App](https://marketplace.mendix.com/link/component/240369) from the Marketplace for a detailed example of how to use the **Call Agent** activity in an action microflow of a chat interface.
195196
{{% /alert %}}
196197

197198
##### Call Agent without History {#call-agent-without-history}
198199

199-
This action is only supported by Single-call agents which have a user prompt defined as part of the agent version. It uses all defined settings, including the selected model, system prompt, user prompt, tools, knowledge base, and model parameters to call the agent by executing a `Chat Completions` operation. If any of the parameters (system prompt, temperature, top P, or max tokens) should be overwritten or you want to pass an additional knowledge base or tool that is not already defined with the agent. You can do this by creating a request and adding these properties before passing it as `OptionalRequest` to the operation. If a context entity was configured, the corresponding context object must be passed so that variables in the system prompt can be replaced. The operation returns a `Response` object containing the assistant’s final message, similar to the chat completions operations from GenAI Commons. If there are tool calls requested by the model and set for visibility to the user, the response will contain those instead, see [Human in the loop](/appstore/modules/genai/genai-for-mx/conversational-ui/#human-in-the-loop), for more information.
200+
This action is only supported by Task agents which have a user prompt defined as part of the agent version. It uses all defined settings, including the selected model, system prompt, user prompt, tools, knowledge base, and model parameters to call the agent by executing a `Chat Completions` operation. If any of the parameters (system prompt, temperature, top P, or max tokens) should be overwritten or you want to pass an additional knowledge base or tool that is not already defined with the agent, you can do this by creating a request and adding these properties before passing it as `OptionalRequest` to the operation. If a context entity was configured, the corresponding context object must be passed so that variables in the system prompt can be replaced. The operation returns a `Response` object containing the assistant’s final message, similar to the chat completions operations from GenAI Commons. If there are tool calls requested by the model and set for visibility to the user, the response will contain those instead, see [Human in the loop](/appstore/modules/genai/genai-for-mx/conversational-ui/#human-in-the-loop), for more information.
200201

201202
To use it:
202203

0 commit comments

Comments
 (0)