UiPath Documentation
getting-started
latest
false
入门开发者指南
  • 概述
    • 概述
  • UiPath 智能体入门
  • 开始使用 UiPath 智能体(采用 LangGraph)
  • 在 Studio Web 中构建低代码智能体
  • 向 UiPath 智能体添加工具
    • 简介
    • 构建 API 工作流
    • 连接到您的智能体
    • 进行端到端测试
重要 :
请注意,此内容已使用机器翻译进行了本地化。 新发布内容的本地化可能需要 1-2 周的时间才能完成。

简介

Extend a low-code UiPath agent with an API Workflow tool that queries the 5e SRD at runtime.

This lab builds part of UiPathfinder, an RPG Adventure system built on UiPath for a fictional Adventurer's Guild. It extends an agent built in the Getting Started with UiPath Agents lab. You build a live API connector that searches the 5e SRD (System Reference Document), then give your Monster Selector agent that connector as a tool. The agent uses it autonomously at runtime: deciding what to search for, calling the API, and selecting the best match from the results.

最后,您将拥有UiPathfinder.QuestParser :一个智能体,该智能体仅接收任务描述,决定搜索内容,调用脚本查询工具,并返回所选脚本的关键字段,而无需预填充列表。

如果没有工具,智能体将依赖于调用者来预取候选对象并将其作为数据传递。添加工具将改变:智能体在运行时决定搜索内容、调用 API 并对实时结果进行推理。这是大多数生产智能体工作流背后的模式;智能体的价值来自于它的获取和推理能力,而不仅仅是对交给的东西进行分类。

您将执行以下操作:

  1. Build a Monster Query API Workflow that calls the 5e SRD.
  2. 将其作为工具连接到 Monitor Selector 智能体。
  3. 更新智能体合同以反映新功能。
  4. 使用端到端工具对完整的智能体进行测试。

预计时间: 30-45 分钟

您要构建的内容

组件详细信息
API 工作流Accepts searchName (string), calls the Open5e 5e SRD API, returns monsterResults array
智能体输入: questDescriptionstring;任务说明。智能体通过该工具获取自己的候选对象
智能体输出: monsterIndexstring; the API's key identifier for the selected monster, for example srd_goblin
智能体输出: monsterNamestring;所选模型的显示名称
智能体输出: monsterTypestring; creature type (for example, beast, undead, dragon). The API returns this as an object, so the agent reads type.name
智能体输出: monsterCrstring; challenge rating. The API returns a number, such as 0.25, which the agent renders as text
智能体输出: monsterReasoningstring;智能体对选择此生物来执行任务的原因的解释

先决条件

  • Studio Web - 在您的浏览器中运行;无需安装桌面。开始之前,请在 Chrome、Edge 或 Firefox 中打开Studio Web
  • UiPath 帐户- 开始之前,请注册或登录UiPath Automation Cloud
  • Node.js 18+ - 安装 UiPath CLI 所必需的。如有需要,请从nodejs.org安装。
  • UiPath CLI v1.198.0+ - required to deploy the starter. Check with uip --version; install or upgrade with npm install -g @uipath/cli.
  • Studio Web 中的 Unattended Selector 智能体- 该实验室以UiPath 智能体入门中的智能体为基础构建。如果您完成了该实验,则表示您的智能体已就绪。如果没有,请部署入门版:
git clone https://github.com/cliff-simpkins/UiPath-Workshops.git
cd UiPath-Workshops/starters/monster-selector
uip login
uip solution upload .
git clone https://github.com/cliff-simpkins/UiPath-Workshops.git
cd UiPath-Workshops/starters/monster-selector
uip login
uip solution upload .

在开始第 1 步之前,打开Studio Web并确认Unattended 选取器显示在您的工作区中。

  • 您要构建的内容
  • 先决条件

此页面有帮助吗?

连接

需要帮助? 支持

想要了解详细内容? UiPath Academy

有问题? UiPath 论坛

保持更新