Defining Classification Rules

A classification rule uses the presence/absence/combination of annotations to determine the classification of documents.

Example: I have annotated all the malfunctions mentioned in maintenance logs in the Annotate module. I created a concept malfunction with different sub concepts (leak, break, warning light, etc.).

I can now create a classification rule in the Classify module as follows:

  • if the log contains at least one malfunction, I want to classify this log entry in the category malfunction detected (and display the details as subcategory)
  • if the log does not contain any malfunction, I want to classify this log entry in the category no malfunction

The table below displays the query language that you can use when creating classification rules. You can combine the operators described below.

If your project contains metadata, you can use metadata as x or y. Example: meta:/Country:.*/ allows you to find all the documents that have this metadata, whatever the value.

Query Description Results and examples
x && y Search for x if y is present in the document.

#Malfunction && #VehiclePart

Classify in a category all the documents that contain at least one malfunction annotation and at least one vehicle part annotation in the document (no matter the distance between these 2 annotations).

The goal is to identify only the documents that mentioned a malfunction related to a specific vehicle part.

x OR y

x || y

Search for x or y in the document

#Malfunction OR #InjuryType

Classify in a category all the documents that contain at least one malfunction annotation or at least one injury type annotation in the document.

The goal is to identify all the documents in which a technical issue or a human injury appears.

x &&! y Search for x if y is not present in the document

#Malfunction &&! #InjuryType

Classify in a category all the documents that contain at least one malfunction annotation only if there is no injury type annotation in the same document.

The goal is to identify all the documents in which a technical issue appears without human injury.

!x Search for the documents that do not contain x

!#Malfunction

Classify in a category all the documents that do not contain malfunction annotation.

The goal is to identify all the documents where no technical issue appears.

!!x Search for x when it is present only once in the document

!!#Malfunction

Classify in a category all the documents that contain only once malfunction annotation.

The goal is to identify the documents with only one technical issue (for a prioritization need for example)