UiPath Documentation
activities
latest
false
重要 :
请注意,此内容已使用机器翻译进行了部分本地化。 新发布内容的本地化可能需要 1-2 周的时间才能完成。
UiPath logo, featuring letters U and I in white

Document Understanding 活动

上次更新日期 2026年4月22日

验证站点

本页说明如何创建包含“数字化文档”“数据提取作用域”“显示验证站点”等活动的工作流。

要从相同类型的文档中自动提取和验证数据时,可以使用这些活动。发票或采购订单非常适合此类任务。

以下工作流重点关注对发票使用“数字化文档”活动,然后使用“显示验证站点”活动来验证信息。为此工作流选择的 OCR 引擎是“UiPath™ 文档 OCR” ,但您可以将其替换为我们的任何其他 OCR 引擎。系统将使用根据所选发票单据创建的简单分类。请访问分类概述,查看如何创建分类。

创建工作流

  1. 打开 Studio,并新建一个默认命名为“主要”的“流程”

  2. Drag a Sequence container into the Workflow Designer.

  3. 选择“序列”容器并创建以下变量:

    1. Variable Name: taxonomy;
    2. 变量类型文档分类
    3. 默认值:无。
  4. “序列”容器中添加“加载分类”活动。

    Add the variable taxonomy in the Taxonomy field.

  5. “加载分类”活动之后的“序列”容器内添加“遍历循环”活动。

    • Add the expression doc in the ForEach field.
    • Add the expression directory.GetFiles("TestData\InputDocs\") in the In field.
    • In the Properties panel, select the option String from the TypeArgument dropdown list.
  6. 选择“遍历循环”活动的“正文”容器,并创建下表中显示的变量:

    表格 1. 要创建的变量

    变量类型默认值
    docName泛型值不适用
    dom文档不适用
    text字符串不适用
    extractionResults提取结果不适用
    validatedResults提取结果不适用
  7. Add an Assign activity inside the Body container.

    • 在“收件人”字段中添加“docName”变量。
    • 在“值”字段添加表达式 System.IO.Path.GetFileNameWithoutExtension(doc)
  8. Add a Write Line activity after the Assign activity.

    在“文本”字段中添加表达式 "Digitizing "+docName

  9. “写入行”活动之后添加“数字化文档”活动。

    • Set the DocumentPath as doc.
    • Add the variable text in the DocumentText field.
    • Add the variable dom in the DocumentObjectModel field.
  10. Drag an OCR engine into the Digitize Document activity. UiPath Document OCR is used for this example.

  11. Add a Write Line activity after the Digitize Document activity.

    在“文本”字段中添加表达式 docName+" was digitized."

  12. Add a Write Line activity after the Write Line activity.

    在“文本”字段中添加表达式 "Opening the Validation Station"

  13. Add a Try Catch activity after the Write Line activity.

  14. Add a Sequence container in the Try section.

  15. Add a Present Validation Station activity inside the Sequence container.

    • Add doc as value in the DocumentPath field.
    • Add the variable text in the DocumentText field.
    • Add the variable dom in the DocumentObjectMOdel field.
    • Add the variable taxonomy in the Taxonomy field.
    • Add the variable extractedResults in the AutomaticExtractionResults field.
    • Add the variable validatedResults in the ValidatedExtractionResults field.
  16. Add a Write Text File activity after the Present Validation Station activity.

  17. 运行流程。 机器人自动提取数据,对文档进行分类,提取特定字段,准备数据以进行验证,并显示提取的文档。

请访问以下链接,下载示例的ZIP存档:示例

使用“验证站点”

Running the workflow opens the Validation Station wizard. Here you can verify the extracted information or extract it yourself by using the Tokens or Custom Area options. If you set a field in the taxonomy as multi-value, then multiple values can be extracted for that field. This can be useful for documents with multiple addresses, different currencies, etc.

  • 创建工作流
  • 使用“验证站点”

此页面有帮助吗?

连接

需要帮助? 支持

想要了解详细内容? UiPath Academy

有问题? UiPath 论坛

保持更新