# Collection Processing Engine Configurator User's Guide

CPE Configurator User's Guide

A Collection Processing Engine (CPE) processes collections of artifacts (documents) through the combination of the following components: a Collection Reader, Analysis Engines, and CAS Consumers.

Earlier versions of UIMA supported another component, the CAS Initializer, but this component is now deprecated in UIMA Version 2.

The Collection Processing Engine Configurator(CPE Configurator) is a graphical tool that allows you to assemble and run CPEs.

For an introduction to Collection Processing Engine concepts, including developing the components that make up a CPE, read . This chapter is a user's guide for using the CPE Configurator tool, and does not describe UIMA's Collection Processing Architecture itself.

## Limitations of the CPE Configurator

The CPE Configurator only supports basic CPE configurations.

It only supports Integrated deployments (although it will connect to remotes if particular CAS Processors are specified with remote service descriptors). It doesn't support configuration of the error handling. It doesn't support Sofa Mappings; it assumes all Single-View components are operating with the _InitialView Sofa. Multi-View components will not have their names mapped. It sets up a fixed-sized CAS Pool.

To set these additional options, you must edit the CPE Descriptor XML file directly. See for the syntax. You may then open the CPE Descriptor in the CPE Configurator and run it. The changes you applied to the CPE Descriptor will be respected, although you will not be able to see them or edit them from the GUI.

## Starting the CPE Configurator

The CPE Configurator tool can be run using the `cpeGui` shell script, which is located in the `bin` directory of the UIMA SDK. If you've installed the example Eclipse project (see , you can also run it using the UIMA CPE GUI run configuration provided in that project.

If you are planning to build a CPE using components other than the examples included in the UIMA SDK, you will first need to update your CLASSPATH environment variable to include the classes needed by these components.

When you first start the CPE Configurator, you will see the main window shown here:

CPE Configurator main GUI window

## Selecting Component Descriptors

The CPE Configurator's main window is divided into three sections, one each for the Collection Reader, Analysis Engines, and CAS Consumers.

There is also a fourth pane, for the CAS Initializer, but it is hidden by default. To enable it click the `View → CAS Initializer Panel` menu item.

In each section of the CPE Configurator, you can select the component(s) you want to use by browsing to (or typing the location of) their XML descriptors. You must select a Collection Reader, and at least one Analysis Engine or CAS Consumer.

When you select a descriptor, the configuration parameters that are defined in that descriptor will then be displayed in the GUI; these can be modified to override the values present in the descriptor.

For example, the screen shot below shows the CPE Configurator after the following components have been chosen:

    examples/descriptors/collectionReader/FileSystemCollectionReader.xml
    examples/descriptors/analysis_engine/NamesAndPersonTitles_TAE.xml
    examples/descriptors/cas_consumer/XmiWriterCasConsumer.xml

CPE Configurator after components chosen

## Running a Collection Processing Engine

After selecting each of the components and providing configuration settings, click the play (forward arrow) button at the bottom of the screen to begin processing. A progress bar should be displayed in the lower left corner. (Note that the progress bar will not begin to move until all components have completed their initialization, which may take several seconds.) Once processing has begun, the pause and stop buttons become enabled.

If an error occurs, you will be informed by an error dialog. If processing completes successfully, you will be presented with a performance report.

## The File Menu

The CPE Configurator's File Menu has the following options:

- Open CPE Descriptor

- Save CPE Descriptor

- Save Options (submenu)

- Refresh Descriptors from File System

- Clear All

- Exit

Open CPE Descriptor will allow you to select a CPE Descriptor file from disk, and will read in that CPE Descriptor and configure the GUI appropriately.

Save CPE Descriptor will create a CPE Descriptor file that defines the CPE you have constructed. This CPE Descriptor will identify the components that constitute the CPE, as well as the configuration settings you have specified for each of these components. Later, you can use Open CPE Descriptor to restore the CPE Configurator to the state. Also, CPE Descriptors can be used to easily run a CPE from a Java program – see .

CPE Descriptors also allow specifying operational parameters, such as error handling options that are not currently available for configuration through the CPE Configurator. For more information on manually creating a CPE Descriptor, see .

The Save Options submenu has one item, "Use <import>". If this item is checked (the default), saved CPE descriptors will use the `<import>` syntax to refer to their component descriptors. If unchecked, the older `<include>` syntax will be used for new components that you add to your CPE using the GUI. (However, if you open a CPE descriptor that used <import>, these imports will not be replaced.)

Refresh Descriptors from File System will reload all descriptors from disk. This is useful if you have made a change to the descriptor outside of the CPE Configurator, and want to refresh the display.

Clear All will reset the CPE Configurator to its initial state, with no components selected.

Exit will close the CPE Configurator. If you have unsaved changes, you will be prompted as to whether you would like to save them to a CPE Descriptor file. If you do not save them, they will be lost.

When you restart the CPE Configurator, it will automatically reload the last CPE descriptor file that you were working with.

## The Help Menu

The CPE Configurator's Help menu provides About information and some very simple instructions on how to use the tool.