4.4 Feature Constraints

Creating a feature-value pair

A node can be specified by an arbitrary number of feature-value pairs (cf. section 3, chapter III). To create a feature-value pair click into the inner node specification area. A box comprising three menus appears (see image below). If the current corpus supports more than one phrase or token feature, the upper menu (the feature selection menu) opens automatically.

Figure: Creating feature-value pairs and toggling between conjunction and disjunction.

To create another feature-value pair you have to click into the inner node specification area, left or right of the existing feature-value pair. By default, these feature-value pairs are connected by conjunction. To toggle between conjunction and disjunction, click on the corresponding symbol.

1. Feature selection menu

The feature selection menu is primarily used to choose the feature, but can also be used to delete or negate the feature-value pair (visualized by a red line from lower left to upper right).

Figure: Feature selection menu (left) and negated feature-value pair (right).

2. Operator selection menu

Figure: The operator selection menu.

The is operator is selected by default. The following operators are available:

is
The feature must agree with the specified value.

isn't
The feature must not agree with the specified value.

contains
The feature value must contain the given string.

doesn't contain
The feature value must not contain the given string.

begins with
The feature value must begin with the given string.

ends with
The feature value must end with the given string.

is regular expression
The given pattern must match the feature value.

isn't regular expression
The given pattern must not match the feature value.

is equal to
The feature value is equal to the feature value of another node (cf. paragraph below).

The operators contains, doesn't contain, begins with, and ends with do not have a textual equivalent. They are converted to regular expressions (cf. subsection 3.5, chapter III). For example begins with 'abc' will be converted to /abc.*/.

3. Value specification

By selecting the operator is or isn't, the feature value can be specified by one or more values or types. In this case the third item of the feature-value pair is a field, such as the inner node specification area. By clicking at the left or right of the existing primary value/type, further values/types can be created. You can switch between disjunction and conjunction by a mouse click on the connector.

Figure: One or more values/types can be used to specify a feature value.

The first item of a value/type menu is used for deleting.

Please note: If there is only one value/type, the delete function does not work.

The second menu item is for negation, also visualized by a red line from lower left to upper right.
Types are marked by the symbol and (by convention) type names are written in small letters. All possible feature values are listed, marked by the symbol . If there is no feature value list available e.g. for the word feature), there is an input field you can type in a value (see figure below).

Figure: Input field (left) and menu for selecting a value or type (right).

Equality

To specify a feature value to be equal to a feature value of another node, variables are used (cf. subsection 7.2, chapter III). To create such a variable you have to select the operator is equal to. The mouse cursor will change into an arrow . Now click either into a free space of an inner node specification area of another node or on the same feature-value pair of another node (see figure below).

Figure: A click into an inner node specification area will create a new feature-value pair.

Figure: A click on an existing feature-value pair will set its value equal to the source feature value.

If you want to delete a feature-value pair which is used as a reference for an is equal to feature value, the following dialog will appear:

Figure: Deleting a variable specification, which is referenced by another feature-value pair, is not allowed.