UiPath Documentation
activities
latest
false
Document Understanding 活动
重要 :
请注意,此内容已使用机器翻译进行了部分本地化。 新发布内容的本地化可能需要 1-2 周的时间才能完成。

分类文档

通过 Studio Web 工作流的“分类文档”活动,使用选定的分类器对文档进行分类。

UiPath.IntelligentOCR.StudioWeb.Activities.ClassifyDocument

描述​

您可以通过选择所需的分类器和一个要分类的文档,使用此活动对多个文档进行分类。

备注:

“分类文档”活动使用公共端点。

生成式模型支持的语言与所使用的 OCR 引擎相同。有关更多信息,请查看“OCR 支持的语言”页面。

除非此活动是属于 Studio 工作流的第一个 Document Understanding 活动,否则输入应为文档数据。只有当活动是属于 Studio 工作流的第一个 Document Understanding 活动时,才应将文件用作输入。

已知限制​

“生成式预定义”项目类型和相应的提取程序在 Automation Suite 中不可用。

项目兼容性​

Windows | 跨平台

配置​

设计器面板​

  • Input - Provide the input file or the Document Data object. This field is required.
    重要提示:

    一个文件最多可包含 500 页。超出此限制的文件将无法分类。

    提示:

    如果您的文件未存储为IResource类型变量,则可以选择执行转换。为此,请在“输入”属性字段中使用LocalResource.FromPath(<reference_to_the_file>) 。考虑您使用“遍历循环”活动遍历文件列表的场景。假设currentItem是您的迭代变量。要将currentItem转换为IResource ,请将LocalResource.FromPath(currentItem)粘贴到“输入”字段中。

  • Document Understanding project - Requires you to select your Document Understanding project from the drop-down menu. This field is required. The available options are:
    • 预定义 - 使用建议用于标准场景的预训练专用模型的项目。
    • 生成式预定义 - 使用预训练的生成式模型的项目,接受指令作为输入,以便对文档数据进行分类或提取。
    • Predefined Non-Latin Languages - Project that uses pre-trained models for non-Latin document processing scenarios.
    • 您连接的租户和文件夹中的现有项目
    • 您可以通过选择 + 图标来创建新项目。
      备注:

      如果您在租户上创建的项目超过 500 个,并使用“分类文档”活动,则 UiPath Studio 或 Studio Web 将不会显示最初 500 个项目之后的任何项目。因此,您不能使用这些项目。

  • Classifier - Appears when you select the Generative Predefined project. The only available option is Generative Classifier. This field is required.
    备注:

    系统会将发送到生成式分类器的数据发送到未公开可用的 LLM 模型实例,不会离开该实例,并且一旦处理完毕,系统不会存储该数据或将该数据用于训练。

    • Document Type Details - Instructions to identify Document Types, provided as key-value pairs, where the key represents the name of the Document Type and the value a description for it, helping the classifier identify such documents.
      • 文档类型 - 提供要用作分类结果的文档类型的名称(不得超过 30 个字符)。
      • 说明- 要求您为生成式分类器提供有关如何识别文档类型的说明。允许的最大字符数为 1000。
  • Version - For the Predefined project, select the version, and the activity displays the list of supported document types. Use this property when using an existing Document Understanding modern project. Select the tag that corresponds to the project version from which you want to process data. For instance, if you choose the Production tag assigned to Version 3, the activity processes data from Version 3 of your project in the production environment. The default value for Version is Staging. If the Staging tag doesn't exist in your selected project, then the default value is Production. After selecting a tag, the activity displays a list of supported document types for that version. This field is required.

属性面板​

高级选项​
  • Minimum confidence - Specify the minimum confidence threshold based on which a document type is assigned during classification. If a document's confidence score falls below this threshold, its Document Type is reported as "unknown". The default value is 50.
    提示:

    大多数文档类型都会生成具有置信度的预测。设置此属性后,可通过仅考虑置信度高于阈值的预测来防止误报。例如,您可以通过测试工作流中的各种文档来确定最佳置信度,并将结果记录在 Excel 电子表格中,然后分析哪个阈值最准确。

外部连接​

The external connection allows you to use Document Understanding resources from a different tenant or from on-premises robots. Before configuring these properties, ensure you have fulfilled the prerequisites mentioned in the Configuring runtime external connection page.

  • Credentials Asset - Use this field when you need to access Document Understanding resources while the robot is connected to a local Orchestrator, or from a different tenant. You can choose to enter a Credential Asset, for authentication purposes, in one of the following ways:
    • 从下拉列表中,从 UiPath™ Robot 连接到的 Orchestrator 中选择所需的凭据资产。

    • 如果您在 Orchestrator 凭据资产中存储了用于访问项目的外部应用程序凭据,请手动输入 Orchestrator 凭据资产的路径。

      路径的格式应为: <OrchestratorFolderName>/<AssetName> 。

  • Tenant URL - Use this field, alongside the Credentials Asset field. Enter the URL of the tenant that the robot connects to in order to execute the classification. The URL should be in the following format: https://<baseURL>/<OrganizationName>/<TenantName>.
  • Connect to tenant - Connects to the Document Understanding instance of the specified tenant.
输入​
  • Timeout (seconds) - Maximum execution time (in seconds) for the call to the generative model. If the operation exceeds this timeout, it is automatically terminated to prevent delays or hangs. The default value is 3600. This field is required.
输出​
  • Document data - Results of the classification. May contain multiple subdocuments if document splitting is enabled.

使用生成式分类器​

要快速开始使用“分类文档”活动的生成式功能,请执行以下步骤:

  1. 添加“分类文档”活动
  2. From the Document Understanding project dropdown list, select Generative Predefined.
  3. 对于“分类器” ,选择“生成式分类器” 。“文档类型详细信息”属性将显示在活动的主体中。
  4. 在“文档类型详细信息”集合中,以“字典键值对”的形式提供您的说明,其中:
    • 密钥表示文档类型(示例:CV)。

    • 值表示生成式提示:生成式分类器用于识别文档类型的说明。例如,请查看下表中的键值对示例:

      表格 1. 用作生成式分类器提示词的键值对

      密钥值
      计算机视觉“查找常见的简历关键字,例如“教育背景”、“技能”和“经验”。”
      发票“查找常见字段名称,例如“发票编号”、“收款人”或“总金额”。”

      图 1. 用作生成式分类器提示词的键值对

  • 描述​
  • 已知限制​
  • 项目兼容性​
  • 配置​
  • 设计器面板​
  • 属性面板​
  • 使用生成式分类器​

此页面有帮助吗?

连接

需要帮助? 支持(opens in new window)

想要了解详细内容? UiPath Academy(opens in new window)

有问题? UiPath 论坛(opens in new window)

保持更新