Adding enrichments to a field

You can add enrichments to the fields that you created.

About this task

You can edit your document type later in the project creation process to ensure that all fields that you want to extract data from are included.

Procedure

To add fields to a document type:

  1. From the project overview page, click the Enrich tile.
  2. Click the Document types tile.
    A list of document types displays.
  3. Select the document type that you want to edit.
    A list of the fields that are associated with the document type is displayed.
  4. Click Add field.
  5. In the General Settings page, enter a unique display name, which can be in any language and any Unicode character.
  6. Enter a symbolic name for this field. This name is used to reference this project in the code, and cannot be changed. It cannot have spaces or special characters.
  7. Choose a Field type.
    You can create simple fields, composite fields, or table fields. If you select an existing composite or table field, the existing subfields are automatically added and you can review them in step 15. To create a new table, select Local table type.
  8. Optional: Add a description and provide other possible names for the field.
  9. Enter alternative names, or aliases, for your field.

    In a document, the same field can be identified by different names, case, or phrasing, for example Purchase order number, PO number, and PO#. In the Alias section, you can add any alternative name that might come up for your field.

  10. Set whether the field is required.
  11. Set whether the field is sensitive.
  12. Optional: In the Field patterns page, set the patterns for the field.

    Field patterns and extractors are regular expressions that can be associated with a field to help identify and extract fields and values. A regular expression is a sequence of characters that define a search pattern. The use of regular expression patterns and extractors is optional. Regular expression patterns can provide extra information to potentially improve the accuracy in extracting the correct fields and values. Python syntax is used for defining the regular expressions. For more information, see Regular expression operations.

    Field patterns
    For a specific field, if the possible names can differ, you can define multiple field names. You can also specify a single field pattern that can match all the variations of your field names. For example, if the field's other possible names can be Email or Email Address, you can create two separate optional names or create just one field pattern that matches the variances in the field.
    Extractors
    For a specific field, if the potential values follow a rule that can be expressed in a regular expression, you can specify an extractor. This pattern can match all the variations of your values. For example, the expected value for a Start Date field might be in a date format. You can create a regular expression pattern for US Date and then associate the extractor of US Date to your field.

    Also, sometimes you want to extract a value that does not have a corresponding key in the document, but you know the pattern of the value. You can define the extractor and denote that the value might be anywhere in the document without attaching to the field name. This designation allows for the presence of a field name to be optional. For example, you want to extract the employee ID number, which can be described with a regular expression pattern. However, some documents show the employee number with a field name Employee ID, while other documents show the employee number without a corresponding field. You can specify the Extractor and be able to extract the employee ID number in both types of documents.

    Back-end search for field and value pairs
    The back-end search for field and value pairs that use regular expression patterns is independent of other field and value pair functions.
    • If you do not define any patterns for a field, the project uses only user-defined names to find field and value pairs for that document type.
    • If you do define patterns or extractors with a regular expression for a field, note the following dependencies that help to ensure that the project has sufficient information to search and find field and value pairs:
      • If you define a field pattern, you must also define an extractor with a regular expression.
      • If you define an extractor with a regular expression, you can optionally define a field pattern.
    Note: The extractors are configured from Value settings for the field. You can either create your custom extractor or use the one defined on the field type of the field.
  13. In the Value settings page, configure validators and field enrichments such as extractors, formatters, and converters.
    In addition to the extractors that are described in step 12, you can also configure the formatters, converters, and validators for your field. You can either create your own custom formatters, converters, and validators for the field or use the one that is defined on the field type of the field.

    When converters or formatters are inherited from a field type, you can modify their settings on the field. As a result, the field has a copy of the converter or formatter from the field type, with different settings. To add a new converter or formatter to a field, you can select between the different types that are available for the field type. The Map and Clean up converters are available for all types, whereas other converters are specific to a type, such as the Decimal converter.

    1. Optional: Test your enrichments.
      1. From Value Settings > Value format, click Edit.
      2. Select the Extractors, Formatters, or Converters tab, and enter a value in the testing panel.
      3. Click Test. For formatters and converters, the returned results show how the input field value is modified by the enrichment. For extractors, the returned result always shows the same data that was entered, but with the extracted value highlighted. If nothing is highlighted, then the extractor did not extract anything for this field.

        You can test all formatters at once, and all converters at once, but you must test one extractor at a time.

    2. Optional: Test your validator.
      1. In Value validators, select your validator and enter a value in the testing panel.
      2. Click Test. If your test string matches the validator, the test is successful. If your test string does not match, the results show the error message that you defined.

        You cannot test required value validators and low confidence validators. You must test one validator at a time.

  14. If you selected a composite or table field in step 7, add subfields in the Subfields page.
    1. If you created a Local table type, you have a new table and you must create the table headers, and optionally summary data and additional data. For more information about creating table fields, see Creating a table field.
    2. If you created a table or composite field from an existing table or composite field, subfields are automatically populated with the attributes of your existing field type. You can select each subfield and edit some of its settings or delete it (unless it is a required field).
  15. Click Create.