- Visão geral
- Contratos de Processamento de Documentos
- Notas de versão
- Sobre os Contratos de Processamento de Documentos
- Classe Box
- Interface IPersistedActivity
- Classe PrettyBoxConverter
- Interface IClassifierActivity
- Interface IClassifierCapabilitiesProvider
- Classe ClassifierDocumentType
- Classe ClassifierResult
- Classe ClassifierCodeActivity
- Classe ClassifierNativeActivity
- Classe ClassifierAsyncCodeActivity
- Classe ClassifierDocumentTypeCapability
- ContentValidationData Class
- EvaluatedBusinessRulesForFieldValue Class
- EvaluatedBusinessRuleDetails Class
- Classe ExtractorAsyncCodeActivity
- Classe ExtractorCodeActivity
- Classe ExtractorDocumentType
- Classe ExtractorDocumentTypeCapabilities
- Classe ExtractorFieldCapability
- Classe ExtractorNativeActivity
- Classe ExtractorResult
- FieldValue Class
- FieldValueResult Class
- Interface ICapabilitiesProvider
- Interface IExtractorActivity
- Classe ExtractorPayload
- Enumeração DocumentActionPriority
- Classe DocumentActionData
- Enumeração DocumentActionStatus
- Enumeração DocumentActionType
- Classe DocumentClassificationActionData
- Classe DocumentValidationActionData
- Classe UserData
- Classe Document
- Classe DocumentSplittingResult
- Classe DomExtensions
- Classe Page
- Classe PageSection
- Classe Polígono
- Classe PolygonConverter
- Classe de metadados
- Classe WordGroup
- Classe Word
- Enumeração ProcessingSource
- Classe ResultsTableCell
- Classe ResultsTableValue
- Classe ResultsTableColumnInfo
- Classe ResultsTable
- Enumeração Rotation
- Rule Class
- RuleResult Class
- RuleSet Class
- RuleSetResult Class
- Enumeração SectionType
- Enumeração WordGroupType
- Interface IDocumentTextProjection
- Classe ClassificationResult
- Classe ExtractionResult
- Classe ResultsDocument
- Classe ResultsDocumentBounds
- Classe ResultsDataPoint
- Classe ResultsValue
- Classe ResultsContentReference
- Classe ResultsValueTokens
- Classe ResultsDerivedField
- Enumeração ResultsDataSource
- Classe ResultConstants
- Classe SimpleFieldValue
- Classe TableFieldValue
- Classe DocumentGroup
- Classe DocumentTaxonomy
- Classe DocumentType
- Classe Field
- Enumeração FieldType
- FieldValueDetails Class
- Classe LanguageInfo
- Classe MetadataEntry
- Enumeração de tipo de texto
- Classe TypeField
- Interface ITrackingActivity
- Interface ITrainableActivity
- Interface ITrainableClassifierActivity
- Interface ITrainableExtractorActivity
- Classe TrainableClassifierAsyncCodeActivity
- Classe TrainableClassifierCodeActivity
- Classe TrainableClassifierNativeActivity
- Classe TrainableExtractorAsyncCodeActivity
- Classe TrainableExtractorCodeActivity
- Classe TrainableExtractorNativeActivity
- BasicDataPoint Class
- BasicValue Class
- ComponentCollectionFacade Class
- DataPointFacadeBase Class
- ExtractionResultHandler Class
- FieldGroupDataPoint Class
- FieldGroupValue Class
- FieldLookupBase Class
- FieldRedactionSettings Class
- RedactionOptions Class (Preview)
- RedactionType Enum
- ResultsValueFacadeBase Class
- TableDataPoint Class
- TableRow Class
- TableValue Class
- WildcardDataPoint Class
- WildcardDataPointCollection Class
- Document Understanding ML
- Document Understanding OCR Local Server
- Document Understanding
- Notas de versão
- Sobre o pacote de atividades Document Understanding
- Compatibilidade do projeto
- Configuração da conexão externa
- Document Understanding coded automation APIs (preview)
- Definir Senha do PDF
- Merge PDFs
- Get PDF Page Count
- Extract PDF Text
- Extract PDF Images
- Extract PDF Page Range
- Extract Document Data
- Criar tarefa de validação e aguardar
- Aguarde a tarefa de validação e retome
- Create Validation Task
- Create Document Validation Artifacts
- Recuperar artefatos de validação de documento
- Classificar Documento
- Create Classification Validation Task
- Create Classification Validation Task and Wait
- Aguardar a tarefa de Validação de Classificação e retomar
- IntelligentOCR
- Notas de versão
- Sobre o pacote de atividades IntelligentOCR
- Compatibilidade do projeto
- Carregar Taxonomia
- Digitize Document
- Classificar Escopo do Documento
- Classificador baseado em palavra-chave
- Document Understanding Project Classifier
- Intelligent Keyword Classifier
- Create Document Classification Action
- Create Document Validation Artifacts
- Recuperar artefatos de validação de documento
- Aguardar ação de classificação do documento e retomar
- Train Classifiers Scope
- Instrutor de Classificador Baseado em Palavra-chave
- Intelligent Keyword Classifier Trainer
- Escopo da Extração de Dados
- Document Understanding Project Extractor
- Document Understanding Project Extractor Trainer
- Regex Based Extractor
- Form Extractor
- Intelligent Form Extractor
- Rasurar documento
- Create Document Validation Action
- Wait For Document Validation Action And Resume
- Escopo de Extratores de Treinamento
- Exportar Resultados da Extração
- Machine Learning Extractor
- Machine Learning Extractor Trainer
- Machine Learning Classifier
- Machine Learning Classifier Trainer
- Classificador Generativo
- Extrator Generativo
- Configuração da autenticação
- Validação de documentos com ações de aplicativos
- Validação manual para digitalizar documentos
- Extração de dados baseada em âncora usando a atividade Intelligent Form Extractor
- Validation Station
- Atividades generativas — Boas práticas
- Extrator generativo — boas práticas
- Classificador generativo — Boas práticas
- Serviços de ML
- OCR
- Contratos de OCR
- Notas de versão
- Sobre os Contratos OCR
- Compatibilidade do projeto
- Interface IOCRActivity
- Classe OCRAsyncCodeActivity
- Classe OCRCodeActivity
- Classe OCRNativeActivity
- Character Class
- Classe OCRResult
- Classe Word
- Enumeração FontStyles
- Enumeração OCRRotation
- Classe OCRCapabilities
- Classe OCRScrapeBase
- Classe OCRScrapeFactory
- Classe ScrapeControlBase
- Enumeração ScrapeEngineUsages
- ScrapeEngineBase
- Classe ScrapeEngineFactory
- Classe ScrapeEngineProvider
- OmniPage
- PDF
- [Não listado] Abbyy
- [Não listado] Abbyy Embedded
Coded automation APIs for the Document Understanding activities package, covering document classification, data extraction, and validation artifacts.
UiPath.DocumentUnderstanding.Activities
Coded workflow API for classifying documents, extracting structured data, and creating and retrieving document validation artifacts. These APIs are available when designing coded automations. For an introduction to coded automations and how to design them using APIs, see Coded Automations.
- Acessador de serviço:
du(tipoIDocumentUnderstandingService) - Pacote obrigatório:
"UiPath.DocumentUnderstanding.Activities": "*"nas dependênciasproject.json.
Namespaces importados automaticamente
The following namespaces are automatically available in coded workflows when the Document Understanding package is installed:
UiPath.DocumentUnderstanding.Activities.ApiUiPath.Platform.ResourceHandlingUiPath.DocumentProcessing.Contracts.ActionsUiPath.IntelligentOCR.StudioWeb.Activities.DataExtractionUiPath.IntelligentOCR.StudioWeb.Activities.DocumentClassification
Visão geral do serviço
The du service exposes each Document Understanding operation as a direct method call. There is no connection or scope to open. Call methods on the service accessor directly:
var extracted = du.ExtractDocumentData(@"C:\invoices\invoice.pdf", "Invoices", "Production", "invoice");
var extracted = du.ExtractDocumentData(@"C:\invoices\invoice.pdf", "Invoices", "Production", "invoice");
The service mirrors the Studio Web Classify Document, Extract Document Data, Create Document Validation Artifacts, and Retrieve Document Validation Artifacts activities.
Project version or tag
The projectVersionOrTag parameter maps to Studio's single Version dropdown. Pass either a version name (for example, v3) or a tag (for example, Production, Staging, live). The runtime resolves whichever kind matches the project. For the Predefined project, use Production.
Common parameters
timeoutMs(Int) - Timeout in milliseconds for classification and extraction. Defaults to3600000(1 hour).docType(String) - The document type id. Pass the document type name for projects with multiple document types, or an empty string for IXP-style projects that have a single extractor per version.
Classificação
DocumentData ClassifyDocument(string documentPath, string projectName, string projectVersionOrTag, int timeoutMs = 3600000)
Classifies a document from a local file path against a Document Understanding project. Returns a DocumentData object, including the predicted document type.
DocumentData ClassifyDocument(IResource file, string projectName, string projectVersionOrTag, int timeoutMs = 3600000)
Classifies the supplied document resource. Accepts any IResource, such as the output of the Path Exists or Get Local File or Folder activity.
Extração de Dados
IDocumentData<DictionaryData> ExtractDocumentData(string documentPath, string projectName, string projectVersionOrTag, string docType, int timeoutMs = 3600000)
Extracts structured data from a document at a local file path. Returns the extracted fields as IDocumentData<DictionaryData>.
IDocumentData<DictionaryData> ExtractDocumentData(IResource file, string projectName, string projectVersionOrTag, string docType, int timeoutMs = 3600000)
Extracts structured data from the supplied document resource.
IDocumentData<DictionaryData> ExtractDocumentData(DocumentData classifiedDocument, string projectName, string projectVersionOrTag, string docType = null, int timeoutMs = 3600000)
Extracts structured data from a document already classified with ClassifyDocument, which avoids re-digitizing the file. When docType is null, it is derived from the classified document's document type.
Validation artifacts
ContentValidationData CreateDocumentValidationArtifacts(IDocumentData<DictionaryData> automaticExtractionResults, string orchestratorFolderName, string orchestratorBucketName = null)
Uploads extraction results to Orchestrator storage and returns a ContentValidationData handle. Use the handle to create a validation action, or to retrieve the results later with RetrieveDocumentValidationArtifacts. When orchestratorBucketName is null, the default bucket is used.
IDocumentData<DictionaryData> RetrieveDocumentValidationArtifacts(ContentValidationData contentValidationData, object completedAppAction = null, bool removeDataFromStorage = false, bool returnAutomaticExtractionResults = false)
Retrieves validated extraction results from storage. When removeDataFromStorage is true, the storage artifacts are deleted after retrieval. When returnAutomaticExtractionResults is true, the original automatic extraction results are returned instead of the validated ones.
Relacionamento com as atividades
The coded API and the Document Understanding XAML activities run on the same runtime, so a coded workflow reaches the same classification, extraction, and validation-artifact behavior as the Extract Document Data and Classify Document activities. The difference is the call shape: the service takes plain file paths or IResource inputs and returns Document Data objects directly, and you use ordinary try/catch instead of the activity Continue On Error option.
Padrões comuns
Classify, then extract
This pattern classifies a document and then reuses the classified result to extract data, which avoids digitizing the file a second time.
[Workflow]
public void Execute()
{
var classified = du.ClassifyDocument(@"C:\docs\file.pdf", "MyProject", "Production");
Log($"Document type: {classified.DocumentType.DisplayName}");
// Reuses the classified document, so the file is not digitized again.
var extracted = du.ExtractDocumentData(classified, "MyProject", "Production");
}
[Workflow]
public void Execute()
{
var classified = du.ClassifyDocument(@"C:\docs\file.pdf", "MyProject", "Production");
Log($"Document type: {classified.DocumentType.DisplayName}");
// Reuses the classified document, so the file is not digitized again.
var extracted = du.ExtractDocumentData(classified, "MyProject", "Production");
}
Extract and prepare data for app tasks containing the validation control
This pattern extracts data, uploads it to storage as validation artifacts for review in an app task, and retrieves the validated results after the action completes.
[Workflow]
public void Execute()
{
var extracted = du.ExtractDocumentData(@"C:\docs\invoice.pdf", "Invoices", "Production", "invoice");
// Upload the results so they can be reviewed in Action Center.
var artifacts = du.CreateDocumentValidationArtifacts(extracted, "Shared");
// After the Action Center validation action completes, retrieve the validated results.
var validated = du.RetrieveDocumentValidationArtifacts(artifacts, removeDataFromStorage: true);
}
[Workflow]
public void Execute()
{
var extracted = du.ExtractDocumentData(@"C:\docs\invoice.pdf", "Invoices", "Production", "invoice");
// Upload the results so they can be reviewed in Action Center.
var artifacts = du.CreateDocumentValidationArtifacts(extracted, "Shared");
// After the Action Center validation action completes, retrieve the validated results.
var validated = du.RetrieveDocumentValidationArtifacts(artifacts, removeDataFromStorage: true);
}
- Namespaces importados automaticamente
- Visão geral do serviço
- Project version or tag
- Common parameters
- Classificação
DocumentData ClassifyDocument(string documentPath, string projectName, string projectVersionOrTag, int timeoutMs = 3600000)DocumentData ClassifyDocument(IResource file, string projectName, string projectVersionOrTag, int timeoutMs = 3600000)- Extração de Dados
IDocumentData<DictionaryData> ExtractDocumentData(string documentPath, string projectName, string projectVersionOrTag, string docType, int timeoutMs = 3600000)IDocumentData<DictionaryData> ExtractDocumentData(IResource file, string projectName, string projectVersionOrTag, string docType, int timeoutMs = 3600000)IDocumentData<DictionaryData> ExtractDocumentData(DocumentData classifiedDocument, string projectName, string projectVersionOrTag, string docType = null, int timeoutMs = 3600000)- Validation artifacts
ContentValidationData CreateDocumentValidationArtifacts(IDocumentData<DictionaryData> automaticExtractionResults, string orchestratorFolderName, string orchestratorBucketName = null)IDocumentData<DictionaryData> RetrieveDocumentValidationArtifacts(ContentValidationData contentValidationData, object completedAppAction = null, bool removeDataFromStorage = false, bool returnAutomaticExtractionResults = false)- Relacionamento com as atividades
- Padrões comuns
- Classify, then extract
- Extract and prepare data for app tasks containing the validation control