RunDecisionPlanForBlocksCC
For both page type identification and data import purposes, creates page variables by using rule-based classification. The classification is based on a specified list of page text blocks that indicate the page text to use.
Member of namespace
CCSyntax
bool RunDecisionPlanForBlocksCC(string blockTypes)
Parameters
- blockTypes
- A comma-separated list of one or more of the following block types:
- Block
- Table
- Header
- Footer
- Title
- H1
- H2
- H3
- Barcode
For general information about block types, see DocumentAnalytics actions.
Important:- Block types must be defined as input fields in the decision plan. For example, to use the Barcode block type, a Barcode input field must be defined in the decision plan. For information about adding input fields to a decision plan and mapping XML nodes to them, see Configuring rule-based classification by using a decision plan.
- Depending on the version of IBM® Content Classification that you installed, you might need to make some XML configuration file changes. These changes are required to ensure that the IBM Content Classification server properly parses text blocks. For more information, see Configuring content classification for XML layout block parsing.
Smart parameters are supported.
Returns
True if the action completes successfully. Otherwise, this action returns False.Level
Page level.Details
| Item | Description |
|---|---|
| Page variables | Based on the specified block types and the page’s XML layout file, a portion of the page’s text is run against the decision plan. (The decision plan is specified by the SetDecisionPlanCC action). For example, suppose that the blockTypes parameter specifies the following block type only: Table . In this case, the page’s text that is run against the decision plan consists of those page text blocks that belong to the block type Table . Page text in other text blocks is ignored. Page variables are created in accordance with the SetDecisionPlanFieldsCC setting and the rules of the decision plan. For more information, see IBM Content Classification: Category and rule-based classification. |
| Match variables | Some variables are set to contain category match data. For more information, see Category match variables. |
- Example
-
// Mandatory prerequisite: An action that performs OCR for the page // The OCR action must create an XML layout file (such as OCR_SR/recognize or OCR_A/recognize) Recognize() // Mandatory settings SetListenerURLCC("http://localhost:18087") SetKnowledgeBaseCC("Mortgage") SetDecisionPlanCC("Mortgage") SetDecisionPlansFieldsCC("Title,Loan,Loan Type") // Run decision plan RunDecisionPlanForBlocksCC("Table,Block")