- 入门指南
- Studio Web 中的 UiPath 智能体
- Agent Builder 中的 UiPath 智能体
- UiPath 编码智能体

智能体用户指南
智能体使用工具如下:
-
工具选择:智能体根据系统提示中提供的名称、描述和上下文选择工具。
-
工具执行:智能体使用工具中已定义的输入架构以及提示中的任何使用示例提供输入参数,从而推断格式和值。
-
输出解释:执行后,智能体会使用提示中的上下文和示例解释输出。
如果没有提供足够的上下文,智能体可能会错误地推断出如何向工具提供参数或如何解释工具中的结果。 您可以通过在工具配置、使用示例和护栏中应用多种设计策略,提高可靠性。
您可以将现有工作流发布为流程或将其导入 Studio Web 解决方案,将其用作工具。 查看输入和输出参数,确保它们使用支持的类型。不受支持的参数类型可能会导致智能体无法调用流程。
在工具描述中包含以下详细信息,有助于智能体和其他开发者在智能体流程中有效地使用此工具:
-
该工具的功能?
-
该工具有哪些副作用?
-
工具是否修改其环境?
-
工具是否会对记录系统执行破坏性更新?
-
反复调用工具是否会产生额外效果?
-
调用工具后,智能体是否能够以非结构化方式与其他智能体、用户或系统交互? 这可能会带来额外的风险,并可能需要相应增加监管力度。
描述应保持简洁但信息丰富,并以支持智能体推理的浅显语言编写。
在系统提示符中包含一个示例,以演示如何使用工具并解释其输出,可以显著提高工具的准确性。
例如,智能体想要使用 RPA 工作流检查内部系统中发票的状态。 在智能体的系统提示中,您可以提供以下使用示例:
Example Usage of ValidateInvoiceStatus Tool
Input:
{
"InvoiceNumber": "INV-2024-1837" // the unique invoice identifier
}
Output:
{
"IsValid": true, // boolean indicating if the invoice exists
"PaymentStatus": "Paid", // payment status of the invoice
"DueDate": "2025-06-30" // when payment is due (if unpaid)
}
Interpreting the Results:
Result Condition Agent Interpretation
IsValid = true, PaymentStatus = Paid "Invoice INV-2024-1837 is valid and has already been paid."
IsValid = true, PaymentStatus = Unpaid "Invoice INV-2024-1837 is valid but unpaid. It is due by June 30, 2025."
IsValid = false "There's not a valid invoice with number INV-2024-1837 in the system."
Example Usage of ValidateInvoiceStatus Tool
Input:
{
"InvoiceNumber": "INV-2024-1837" // the unique invoice identifier
}
Output:
{
"IsValid": true, // boolean indicating if the invoice exists
"PaymentStatus": "Paid", // payment status of the invoice
"DueDate": "2025-06-30" // when payment is due (if unpaid)
}
Interpreting the Results:
Result Condition Agent Interpretation
IsValid = true, PaymentStatus = Paid "Invoice INV-2024-1837 is valid and has already been paid."
IsValid = true, PaymentStatus = Unpaid "Invoice INV-2024-1837 is valid but unpaid. It is due by June 30, 2025."
IsValid = false "There's not a valid invoice with number INV-2024-1837 in the system."
工具防护栏使您可以对提供给代理工具的输入和从代理工具接收的输出强制执行策略,从而允许人工审核工具使用情况、完全阻止工具等。阅读有关工具防护栏的更多信息。
您可以直接添加许多 Integration Service 连接器活动作为代理的工具。要使用尚未直接支持的连接器和活动,请执行以下操作:
-
在 Studio Web 中创建新的工作流。
-
添加连接器活动。
-
定义匹配的输入和输出参数。
-
将工作流发布为流程。
-
将流程添加为工具,并在提示符中描述其用法。
使用此方法,您能够以可靠的结构化方式将任何连接器或 API 调用披露给智能体。