Deploying Patches

Introduction

Your Appian installation likely includes different environments, such as development, staging, and production.

When you install Intelligent Document Processing (IDP) or update the pre-installed application, you will likely be doing this in a source environment, such as development. You will also likely use this source environment to fine-tune your application before deploying it to a target environment, such as staging or production.

It is best practice for each environment to use its own classification model and data extraction training. Because of this, in order to deploy changes to a target environment, you will have to take certain steps.

This page provides instructions for deploying changes to target environments, while making sure that each environment contains its own classification model and data extraction training.

See also: The Deploying Apps pages in the Appian Designer documentation for more information about deploying patches in Appian.

Deploying Dependent Applications and Patches

If you are using IDP in a subprocess or with external systems, then you are likely also deploying a new application or deploying a patch for an existing application. In this scenario, it is recommended that you first complete the deployment for IDP and then complete the deployment for the dependent application or patch.

Prerequisites

After you have installed or updated your pre-installed application in your source environment, customize the application using the resources mentioned in the Customizing IDP section of the Intelligent Document Processing Overview page.

Before you continue with deploying changes to a target environment, make sure that you have followed the instructions in the Installing IDP page to either install IDP or update the pre-installed application in your target environment.

If you are using Compare and Deploy, you may deploy the patch and the associated SQL at the same time.

Deploying modified fields for a document type

If you add or remove a field from a document type in your source environment, to update the document type in the target environment, you will need to make the following changes:

  1. In your target environment, run the SQL command to update the table for the document type that you are modifying.
    • To add a column, use the SQL command from the DDL file that you downloaded when you verified the data store in the source environment.
    • To remove a column, use the SQL command you used to delete the column in the source environment.
  2. Deploy a patch from your source environment to your target environment with the modified CDT.

The updated CDT will only display in new process instances. It will not display in any process instances that were started before you deployed the modified document type.

Deploying a new document type

If you add a new document type in your source environment, it is best practice to use a new classification model in your target environment. This is because you will likely be uploading test documents in your source environment, and you don't want the classification model for your real world documents to be affected by test documents.

In order to use a new classification model in the target environment, you will need to set the status for the new document to Inactive. This is because you will need to run the IDP configuration in the target environment to train the classification model. During the configuration, the status wil be updated to Active.

To deploy a new document type to a target environment:

  1. In your source environment database, from the dudoctype table, export the data for the new document type. This will generate the INSERT commands to add the document types to the table in the target environment. Alternatively, you can write your own SQL commands to insert the new rows into the table.
  2. To reset the status of the document type, in the exported data, modify the data insertion statement by updating doctypestatus to Inactive.
    • See the following for an example SQL command. Note that this example uses MySQL syntax.

      1
      
      INSERT INTO `dudoctype` (`doctypeid`, `doctypename`, `choiceindex`, `doctypestatus`, `isinvalidtype`, `channelid`) VALUES (NULL, 'Medical Device License', '5', 'Inactive', '0', '1');
      
  3. Using the exported data, insert the new document type into the dudoctype table of your target database.
  4. Deploy a patch from your source environment to your target environment that includes the following:
    • The new CDT.
    • The new data store entity constant.
    • The updated DU Data Store.
    • The updated DU_returnDataTypeForChoiceIndex rule.
    • Updated DU_returnDataStoreEntityForChoiceIndex expression rule.
  5. To train the classification model in the target environment with the new document type, configure IDP.

After the model is trained, you can start uploading documents for the new document type.

Deploying a new document channel

If you add a new document channel in your source environment, it is best practice to use a new classification model in your target environment. This is because you will likely be uploading test documents in your source environment, and you don't want the classification model for your real-world documents to be affected by test documents.

In order to use a new classification model in the target environment, you will need to reset the model training values for the new document channel in the target environment. You will also have to deploy the new document types that were created for the new document channel and train the classification model.

To deploy a new document channel to a target environment:

  1. In your source environment database, from the dudocchannel table, export the data for the new document channel. This will generate the INSERT commands to add the document channel to the table in the target environment. Alternatively, you can write your own SQL commands to insert the new rows into the table.
  2. To reset the model training values, in the exported data, modify the data insertion statement by updating the following values for the new document channel:
    • modelid: NULL
    • modeltrainedon: NULL
    • numdocsusedfortraining: 0
    • invalidtypeincludedinmodel: 0
    • Example:

      1
      
      INSERT INTO `dudocchannel` (`channelid`, `channelname`, `modelid`, `modeltrainedon`, `minclassifierconf`, `minextractionconf`, `numdocsforretraining`, `numdocsusedfortraining`, `invalidtypeincludedinmodel`) VALUES (2, 'Legal', NULL, NULL, 0.85, 0.5, 100, 0, 0);
      
  3. Using the exported data, insert the new document channel into the dudocchannel table of your target database.
  4. Follow the steps for deploying a new document type to deploy the new document types for the document channel and train the classification model. When creating the patch, include the groups that were created for the document channel.
Open in Github Built: Wed, Aug 16, 2023 (04:37:39 PM)

On This Page

FEEDBACK